/* KinetIQ base styles (shared look with Grounded Baseball Development): aqua, white, black. One font, sizes 12/14/17/32, weights 500/700, 8 point spacing. */
:root {
  --aqua: #00C2B2;
  --ink: #0D0D0D;
  --white: #FFFFFF;
  --t80: rgba(255,255,255,.8);
  --t72: rgba(255,255,255,.72);
  --t62: rgba(255,255,255,.62);
  --t40: rgba(255,255,255,.4);
  --line: rgba(255,255,255,.14);
  --fill: #1A1A1A;
  --card: rgba(13,13,13,.94);
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: var(--ink); color: var(--white); font-family: Montserrat, system-ui, sans-serif; font-weight: 500; -webkit-font-smoothing: antialiased; }
button { font-family: inherit; cursor: pointer; }
a { color: var(--aqua); }

/* Fixed logo background that stays still while the page scrolls */
.bg { position: fixed; inset: 0; z-index: 0; pointer-events: none; display: flex; align-items: center; justify-content: center; }
.bg img { width: min(296px, 76vw); height: auto; transform: translateY(-48px); }
.bg .dim { position: absolute; inset: 0; background: var(--ink); opacity: .9; transition: opacity .3s; }
/* Welcome: crisp logo at the top of the page, nothing behind the text */
body.welcome .bg { display: none; }
.hero-logo { display: block; width: min(240px, 60vw); height: auto; margin: 32px auto 0; }
h1.hero { font-size: 32px; line-height: 1.1; }
h1.hero span { color: var(--aqua); }
.credit { margin: 24px 0 0; font-size: 12px; line-height: 1.6; color: var(--t62); text-align: center; }
.credit a { color: var(--t80); text-decoration: underline; text-underline-offset: 2px; }

/* Welcome intro: the G pitches, the batter hits it back into the G (intro.js) */
.intro { position: fixed; inset: 0; z-index: 5; cursor: pointer; }
.intro canvas { display: block; }
.intro-skip { position: absolute; right: 20px; top: calc(20px + env(safe-area-inset-top)); font-size: 12px; font-weight: 700; letter-spacing: 1px; color: var(--t40); transition: opacity .3s; }

.app { position: relative; z-index: 1; max-width: 480px; margin: 0 auto; min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; padding: 16px 24px 32px; }
.top { display: flex; align-items: center; gap: 16px; min-height: 44px; margin-left: -12px; }
.back { width: 44px; height: 44px; border: 0; background: transparent; display: flex; align-items: center; justify-content: center; color: var(--white); }
.progress { flex: 1; display: flex; gap: 8px; }
.progress span { flex: 1; height: 4px; border-radius: 2px; background: rgba(255,255,255,.16); }
.progress span.on { background: var(--aqua); }
.brandbar { display: flex; align-items: center; justify-content: space-between; min-height: 44px; }
.brandbar img { height: 32px; }

.eyebrow { font-size: 12px; font-weight: 700; letter-spacing: 2px; color: var(--aqua); text-transform: uppercase; }
h1 { margin: 24px 0 8px; font-size: 32px; font-weight: 700; line-height: 1.15; text-wrap: balance; }
.eyebrow + h1 { margin-top: 8px; }
h2 { margin: 32px 0 16px; font-size: 17px; font-weight: 700; }
.sub { margin: 0 0 32px; font-size: 14px; line-height: 1.5; color: var(--t62); }
.body { font-size: 17px; line-height: 1.5; color: var(--t80); }
.small { font-size: 12px; line-height: 1.5; color: var(--t62); }
.stack { display: flex; flex-direction: column; gap: 16px; }
.row2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.grow { flex: 1; min-height: 32px; }

label { display: flex; flex-direction: column; gap: 8px; font-size: 14px; color: var(--t72); }
input, textarea { width: 100%; height: 56px; border: 1px solid var(--line); border-radius: 12px; padding: 0 16px; font: 500 17px Montserrat, system-ui, sans-serif; color: var(--white); background: var(--fill); }
input::placeholder { color: var(--t40); }
input:focus { outline: none; border-color: var(--aqua); }
input[type=date] { color-scheme: dark; }
.label { font-size: 14px; color: var(--t72); }

.btn { height: 56px; width: 100%; border: 0; border-radius: 12px; font-size: 17px; font-weight: 700; background: var(--aqua); color: var(--ink); box-shadow: inset 0 1px 0 rgba(255,255,255,.35); }
.btn:disabled { background: rgba(255,255,255,.08); color: var(--t40); box-shadow: none; cursor: default; }
.btn.ghost { background: transparent; color: var(--white); border: 1px solid rgba(255,255,255,.24); box-shadow: none; }
.btn.outline { background: var(--card); color: var(--aqua); border: 1px solid var(--aqua); box-shadow: none; }
.btn.sm { height: 48px; font-size: 14px; }
.link { min-height: 44px; border: 0; background: transparent; padding: 0; color: var(--aqua); font-size: 14px; font-weight: 700; align-self: flex-start; }
.link.muted { color: var(--t62); font-weight: 500; align-self: center; }
.buttons { display: flex; flex-direction: column; gap: 8px; }

.check { display: flex; align-items: center; gap: 16px; border: 0; background: transparent; padding: 0; min-height: 44px; text-align: left; color: var(--t80); font-size: 14px; margin-top: 24px; }
.check .box { width: 24px; height: 24px; flex: none; border-radius: 6px; border: 2px solid var(--t40); display: flex; align-items: center; justify-content: center; }
.check.on .box, .checkbox.on .box { background: var(--aqua); border-color: var(--aqua); }
/* the terms row: the box is its own button so the Terms and Privacy links are not inside it */
div.check { cursor: default; }
div.check > span { cursor: pointer; }
.checkbox { display: flex; align-items: center; min-height: 44px; border: 0; background: transparent; padding: 0; flex: none; }

.codes { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; }
.codes input { height: 64px; padding: 0; text-align: center; font-size: 32px; font-weight: 700; }

.choice { display: flex; align-items: center; gap: 16px; text-align: left; padding: 24px; border-radius: 16px; border: 2px solid var(--line); background: var(--card); color: var(--white); width: 100%; }
.choice.on { border-color: var(--aqua); background: rgba(0,194,178,.10); }
.choice .icon { width: 48px; height: 48px; flex: none; border-radius: 12px; background: rgba(0,194,178,.12); display: flex; align-items: center; justify-content: center; }
.choice .t { display: block; font-size: 17px; font-weight: 700; }
.choice .d { display: block; margin-top: 4px; font-size: 14px; line-height: 1.4; color: var(--t62); }

.seg { display: flex; padding: 4px; border-radius: 12px; background: var(--fill); }
.seg button { flex: 1; height: 44px; border: 0; border-radius: 8px; background: transparent; color: var(--white); font-size: 14px; font-weight: 700; }
.seg button.on { background: var(--aqua); color: var(--ink); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips button { min-width: 64px; height: 44px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--card); color: var(--white); font-size: 14px; font-weight: 700; }
.chips button.on { background: var(--aqua); border-color: var(--aqua); color: var(--ink); }

.card { border: 1px solid var(--line); border-radius: 16px; padding: 24px; background: var(--card); }
.card + .card { margin-top: 16px; }
.waiver { max-height: 240px; overflow-y: auto; border: 1px solid var(--line); border-radius: 12px; padding: 16px; font-size: 14px; line-height: 1.6; color: var(--t80); background: rgba(13,13,13,.6); }
/* the participation waiver: shown in full, with its title, headings and numbered sections */
.waiver.doc { max-height: none; overflow: visible; padding: 24px; font-size: 15px; overflow-wrap: break-word; }
.waiver.doc .org { margin: 0; font-size: 12px; font-weight: 700; letter-spacing: 2px; color: var(--aqua); }
.waiver.doc h2 { margin: 8px 0 16px; font-size: 20px; line-height: 1.3; color: var(--white); }
.waiver.doc h3 { margin: 24px 0 8px; font-size: 15px; font-weight: 700; color: var(--white); }
.waiver.doc p { margin: 0; }
@media (max-width: 400px) { .waiver.doc { padding: 16px; } }

.pill { display: inline-block; flex: none; align-self: flex-start; white-space: nowrap; padding: 4px 12px; border-radius: 999px; border: 1px solid var(--aqua); color: var(--aqua); font-size: 12px; font-weight: 700; }
.pill.solid { background: var(--aqua); color: var(--ink); }
.pill.muted { border-color: rgba(255,255,255,.24); color: var(--t62); }

.pass { background: var(--white); color: var(--ink); border-radius: 16px; padding: 24px; display: flex; flex-direction: column; gap: 24px; box-shadow: 0 0 0 1px rgba(0,194,178,.4), 0 16px 48px rgba(0,194,178,.22); }
.pass .head { display: flex; justify-content: space-between; font-size: 12px; font-weight: 700; letter-spacing: 2px; }
.pass .head span + span { color: rgba(13,13,13,.6); }
.pass .main { display: flex; gap: 24px; align-items: center; }
.pass .qr { width: 112px; height: 112px; flex: none; }
.pass .qr svg, .pass .qr img { width: 100%; height: 100%; display: block; }
.pass .name { font-size: 17px; font-weight: 700; }
.pass .meta { margin-top: 8px; font-size: 14px; color: rgba(13,13,13,.72); }
.pass .tag { display: inline-block; margin-top: 8px; padding: 4px 12px; border-radius: 999px; border: 1px solid var(--ink); font-size: 12px; font-weight: 700; }
.pass .tag.ready { background: var(--aqua); }

.list-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 16px 0; border-bottom: 1px solid rgba(255,255,255,.12); }
.list-row:last-child { border-bottom: 0; }
.list-row .t { font-size: 17px; font-weight: 700; }
.list-row .d { margin-top: 4px; font-size: 14px; color: var(--t62); }

.timeline .step { display: flex; gap: 16px; }
.timeline .rail { width: 24px; flex: none; display: flex; flex-direction: column; align-items: center; }
.timeline .dot { width: 24px; height: 24px; flex: none; border-radius: 999px; border: 2px solid rgba(255,255,255,.24); display: flex; align-items: center; justify-content: center; }
.timeline .dot.done { background: var(--aqua); border-color: var(--aqua); }
.timeline .dot.now { border-color: var(--aqua); }
.timeline .line { width: 2px; flex: 1; min-height: 32px; background: rgba(255,255,255,.16); }
.timeline .txt { padding-bottom: 24px; }
.timeline .t { font-size: 17px; font-weight: 700; }
.timeline .d { margin-top: 4px; font-size: 14px; line-height: 1.4; color: var(--t62); }
.timeline .muted .t { color: var(--t62); }

.code-big { font-size: 32px; font-weight: 700; letter-spacing: 4px; color: var(--aqua); }
.error { margin: 16px 0 0; padding: 12px 16px; border-radius: 12px; border: 1px solid rgba(255,255,255,.24); background: rgba(255,255,255,.06); font-size: 14px; color: var(--white); }
.devcode { margin: 0 0 16px; padding: 12px 16px; border-radius: 12px; border: 1px dashed var(--aqua); font-size: 14px; color: var(--aqua); }
.hidden { display: none !important; }

/* Training, trainer and nav pieces */
textarea { height: auto; padding: 16px; line-height: 1.5; resize: vertical; }
textarea:focus, select:focus { outline: none; border-color: var(--aqua); }
select { width: 100%; height: 56px; border: 1px solid var(--line); border-radius: 12px; padding: 0 16px; font: 500 17px Montserrat, system-ui, sans-serif; color: var(--white); background: var(--fill); color-scheme: dark; }
input[type=time] { color-scheme: dark; }
/* From and To stack on phones so the whole time (with AM/PM) shows */
@media (max-width: 440px) { .row2.times { grid-template-columns: 1fr; } }
input:disabled { color: var(--t40); }
.tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 5; display: flex; justify-content: center; gap: 48px; padding: 8px 24px calc(8px + env(safe-area-inset-bottom)); background: rgba(13,13,13,.96); border-top: 1px solid var(--line); }
.tabbar button { min-width: 88px; min-height: 48px; border: 0; background: transparent; color: var(--t62); display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 12px; font-weight: 700; }
.tabbar button.on { color: var(--aqua); }
.catgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.catgrid .choice { flex-direction: column; align-items: flex-start; padding: 16px; }
.catgrid .choice.wide { grid-column: 1 / -1; flex-direction: row; align-items: center; padding: 24px; }
.avatar { width: 48px; height: 48px; flex: none; border-radius: 999px; background: rgba(0,194,178,.16); color: var(--aqua); display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 700; }
.avatar.big { width: 80px; height: 80px; font-size: 32px; margin-top: 16px; box-shadow: 0 0 0 2px var(--aqua); }
.choice.radio { padding: 16px; border-width: 1px; }
.choice.radio .dot { width: 20px; height: 20px; flex: none; border-radius: 999px; border: 2px solid var(--t40); }
.choice.radio.on .dot { border: 6px solid var(--aqua); }
.daystrip { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 8px; margin-bottom: 16px; }
.daystrip button { flex: none; width: 56px; height: 72px; border-radius: 12px; border: 1px solid var(--line); background: var(--card); color: var(--white); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; font-size: 17px; font-weight: 700; }
.daystrip button.on { background: var(--aqua); border-color: var(--aqua); color: var(--ink); }
.daystrip button.on .small { color: rgba(13,13,13,.72); }
.slots { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.slots button { min-height: 64px; border-radius: 12px; border: 1px solid var(--line); background: var(--card); color: var(--white); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; font-size: 14px; font-weight: 700; }
.slots button.on { border: 2px solid var(--aqua); background: rgba(0,194,178,.10); }
.toast { position: fixed; left: 50%; bottom: 96px; transform: translateX(-50%); z-index: 20; padding: 12px 24px; border-radius: 999px; background: var(--white); color: var(--ink); font-size: 14px; font-weight: 700; box-shadow: 0 8px 32px rgba(0,0,0,.5); }
.avatar.photo { overflow: hidden; padding: 0; background: var(--fill); }
.avatar.photo img { width: 100%; height: 100%; object-fit: cover; object-position: center top; display: block; }
.card.hl { border-color: var(--aqua); }
.planlist { list-style: none; margin: 16px 0 24px; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.planlist li { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; line-height: 1.5; color: var(--t80); }
.planlist li svg { flex: none; margin-top: 3px; }
.planlist li.no { color: var(--t62); }

/* Four parent tabs fit on small phones */
.tabbar button { position: relative; }
@media (max-width: 480px) { .tabbar { gap: 0; padding-left: 8px; padding-right: 8px; justify-content: space-around; } .tabbar button { min-width: 64px; flex: 1; } }
.tabbar .badge { position: absolute; top: 0; left: calc(50% + 6px); min-width: 18px; height: 18px; padding: 0 4px; border-radius: 999px; background: var(--aqua); color: var(--ink); font-size: 12px; font-style: normal; line-height: 18px; text-align: center; }

/* Messages between a parent and a trainer */
.msgs { display: flex; flex-direction: column; gap: 8px; margin: 16px 0 24px; }
.msg { align-self: flex-start; max-width: 85%; min-width: 0; padding: 12px 16px; border-radius: 16px 16px 16px 4px; background: var(--fill); border: 1px solid var(--line); font-size: 14px; line-height: 1.5; }
.msg.mine { align-self: flex-end; border-radius: 16px 16px 4px 16px; background: rgba(0,194,178,.16); border-color: rgba(0,194,178,.4); }
.msg .mbody { white-space: pre-line; overflow-wrap: anywhere; }
.msg .when { display: block; margin-top: 4px; font-size: 12px; color: var(--t62); }
.msg .offer { margin-top: 8px; padding: 16px; border-radius: 12px; border: 1px solid var(--aqua); background: var(--card); }
.msg .mbody + .offer { margin-top: 12px; }
.msg .offer:first-child { margin-top: 0; }
.composer textarea { min-height: 96px; }
.choice .preview { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden; overflow-wrap: anywhere; }

/* safety line at the top of every chat, with the Report button */
.safety { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0 16px; margin: 8px 0 0; padding: 4px 16px; border: 1px solid var(--line); border-radius: 12px; font-size: 12px; line-height: 1.5; color: var(--t62); }
.safety > span:first-child { flex: 1 1 180px; padding: 8px 0; }
.safety .link { min-height: 44px; font-size: 14px; align-self: center; }
.safety .pill { margin: 8px 0; align-self: center; }
