/* Tactics Board – chalk & pitch */
:root { --tbx-ink: #eef6ee; --tbx-dim: #a9c4b0; --tbx-bg: #0c2419; --tbx-card: #123526; --tbx-card2: #17402e; --tbx-line: #24563d; --tbx-lime: #b8f03c; --tbx-lime-dk: #8fc21f; --tbx-red: #ff6b6b; --tbx-gold: #ffd60a; }
.tbx-host { display: block; margin: 18px 0; color: var(--tbx-ink); font-size: 15px; line-height: 1.45; }
.tbx-host *, .tbx-toast { box-sizing: border-box; }
.tbx-host button, .tbx-host input, .tbx-host select { font: inherit; color: inherit; }
.tbx-host button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
.tbx-host select, .tbx-host input[type=text], .tbx-host input[type=search] {
  width: 100%; min-height: 44px; padding: 8px 12px; border: 2px solid var(--tbx-line); border-radius: 10px; background: #0a1e15; color: var(--tbx-ink); font-size: 16px; color-scheme: dark;
}
.tbx-host select:focus, .tbx-host input:focus { outline: none; border-color: var(--tbx-lime); }
.tbx-host button:focus-visible, .tbx-rolepin:focus-visible { outline: 2px dashed var(--tbx-lime); outline-offset: 2px; }
.tbx-card { margin: 12px 0; padding: 14px; border-radius: 16px; background: var(--tbx-card); border: 1px solid var(--tbx-line); }
.tbx-card h3 { margin: 0 0 10px; color: var(--tbx-ink); }
.tbx-card h4 { margin: 12px 0 6px; color: var(--tbx-lime); font-size: 16px; }
.tbx-card ul { margin: 6px 0; padding-left: 20px; }
.tbx-card li { margin: 3px 0; }
.tbx-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; margin: 10px 0; }
.tbx-row > * { flex: 1 1 140px; }
.tbx-row--tight > * { flex: 0 1 auto; }
.tbx-field { display: block; flex: 1 1 140px; font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--tbx-dim); }
.tbx-field select { margin-top: 4px; text-transform: none; letter-spacing: 0; font-weight: 400; }
.tbx-check { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; color: var(--tbx-ink); }
.tbx-check input { width: 20px; height: 20px; accent-color: var(--tbx-lime); }
.tbx-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 42px; padding: 8px 14px; border: 2px solid var(--tbx-line); border-radius: 10px; background: #0f2c1f; color: var(--tbx-ink); font-weight: 700; font-size: 14px; white-space: nowrap; }
.tbx-btn--lime { background: var(--tbx-lime); border-color: var(--tbx-lime); color: #0c2419 !important; }
.tbx-btn--lime:active { background: var(--tbx-lime-dk); }
.tbx-btn--wide { width: 100%; margin-top: 10px; }
.tbx-btn--sm { min-height: 34px; padding: 4px 10px; font-size: 13px; }
.tbx-btn--icon { width: 42px; padding: 0; font-size: 22px; }
.tbx-btn:disabled { opacity: .5; cursor: default; }
.tbx-x { width: 32px; height: 32px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .07); color: var(--tbx-dim); font-size: 18px; }
.tbx-seg { display: flex; gap: 4px; padding: 4px; border-radius: 12px; background: #0a1e15; width: 100%; }
.tbx-seg button { flex: 1; min-height: 40px; border: 0; border-radius: 9px; background: transparent; color: var(--tbx-dim); font-weight: 700; font-size: 13px; white-space: nowrap; }
.tbx-seg button.is-on { background: var(--tbx-lime); color: #0c2419; }
.tbx-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.tbx-chips button { min-height: 36px; padding: 0 12px; border: 2px solid var(--tbx-line); border-radius: 999px; background: transparent; font-size: 13px; font-weight: 700; color: var(--tbx-ink); }
.tbx-chips button.is-on, .tbx-chips button.is-fav { background: var(--tbx-lime); border-color: var(--tbx-lime); color: #0c2419; }
.tbx-note { margin: 8px 0; font-size: 13px; color: var(--tbx-dim); }
.tbx-hint { margin: 6px 0; font-size: 12px; color: var(--tbx-dim); text-align: center; }
.tbx-empty { list-style: none; padding: 10px; color: var(--tbx-dim); font-size: 14px; text-align: center; }

/* pitch */
.tbx-stage { margin: 10px auto; max-width: 420px; border-radius: 14px; overflow: hidden; box-shadow: 0 10px 26px rgba(0, 0, 0, .4); background: #1c6b37; }
.tbx-stage--mini { max-width: 300px; }
.tbx-pitch { display: block; width: 100%; height: auto; touch-action: none; user-select: none; -webkit-user-select: none; }
.tbx-stripe-a { fill: #2a8344; }
.tbx-stripe-b { fill: #2f8f4a; }
.tbx-lines { stroke: rgba(255, 255, 255, .9); stroke-width: .35; }
.tbx-goal, .tbx-spot { fill: #fff; }
.tbx-chip__disc { stroke: #fff; stroke-width: .45; }
.tbx-chip--home .tbx-chip__disc { fill: #b8f03c; }
.tbx-chip--keep .tbx-chip__disc { fill: #ffd60a; }
.tbx-chip--opp .tbx-chip__disc { fill: #e8eef5; }
.tbx-chip--okeep .tbx-chip__disc { fill: #6b7280; }
.tbx-chip__txt { font: 700 2.9px system-ui, sans-serif; fill: #0c2419; pointer-events: none; }
.tbx-chip__txt--sm { font-size: 2.2px; }
.tbx-chip--okeep .tbx-chip__txt { fill: #fff; }
.tbx-chip__name { font: 700 2.2px system-ui, sans-serif; fill: #fff; paint-order: stroke; stroke: #0c2419; stroke-width: .6px; pointer-events: none; }
.tbx-chip--anim { transition: transform .6s cubic-bezier(.45, .05, .25, 1); }
.tbx-pitch[data-mode=move] [data-team] { cursor: grab; }
.tbx-pitch[data-mode=run], .tbx-pitch[data-mode=pass] { cursor: crosshair; }
.tbx-pitch[data-mode=erase] .tbx-line { cursor: pointer; }
.tbx-chip.is-drag .tbx-chip__disc { stroke: #0c2419; stroke-width: .8; }
.tbx-ball circle { fill: #fff; stroke: #111; stroke-width: .3; }
.tbx-ball .tbx-ball__dot { fill: #111; stroke: none; }
.tbx-line { fill: none; stroke-width: .6; stroke-linecap: round; stroke-linejoin: round; }
.tbx-line--run { stroke: #fff; stroke-dasharray: 1.6 1.2; }
.tbx-line--pass { stroke: #b8f03c; }
.tbx-pitch[data-mode=erase] .tbx-line { stroke-width: 1.4; }
.tbx-ah--run { fill: #fff; }
.tbx-ah--pass { fill: #b8f03c; }
.tbx-block { fill: rgba(184, 240, 60, .14); stroke: rgba(184, 240, 60, .6); stroke-width: .3; stroke-dasharray: 1 .8; transition: all .4s; }
.tbx-plan h4 { margin-top: 4px; }

/* board */
.tbx-board .tbx-row--tight { justify-content: center; }
.tbx-steps { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px; margin: 8px 0; padding: 8px; border-radius: 12px; background: var(--tbx-card); }
.tbx-steplabel { min-width: 84px; text-align: center; font-weight: 700; font-variant-numeric: tabular-nums; }
.is-playing .tbx-steps .tbx-btn:not(.tbx-btn--lime) { opacity: .4; pointer-events: none; }
.tbx-panel { margin: 10px 0; border-radius: 14px; background: var(--tbx-card); border: 1px solid var(--tbx-line); }
.tbx-panel > summary { padding: 14px; cursor: pointer; font-weight: 700; list-style: none; }
.tbx-panel > summary::after { content: '+'; float: right; color: var(--tbx-lime); }
.tbx-panel[open] > summary::after { content: '−'; }
.tbx-panel > :not(summary) { margin-left: 14px; margin-right: 14px; }
.tbx-panel[open] { padding-bottom: 12px; }
.tbx-names { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.tbx-name { display: grid; grid-template-columns: 42px 1fr; align-items: center; gap: 6px; }
.tbx-name b { font-size: 12px; color: var(--tbx-lime); text-align: center; }
.tbx-saved { list-style: none; margin: 8px 0; padding: 0; }
.tbx-saved li { display: grid; grid-template-columns: 1fr auto auto; gap: 8px; align-items: center; padding: 8px 0; border-top: 1px solid var(--tbx-line); }
.tbx-saved small { display: block; color: var(--tbx-dim); font-size: 12px; }

/* widgets */
.tbx-verdict { list-style: none; padding: 0 !important; }
.tbx-verdict li { padding: 8px 10px; margin: 6px 0; border-radius: 10px; background: #0f2c1f; font-size: 14px; }
.tbx-two { display: grid; grid-template-columns: 1fr; gap: 0 14px; }
@media (min-width: 560px) { .tbx-two { grid-template-columns: 1fr 1fr; } }
.tbx-rolepin rect { fill: rgba(12, 36, 25, .85); stroke: #b8f03c; stroke-width: .35; }
.tbx-rolepin text { font: 700 2.6px system-ui, sans-serif; fill: #b8f03c; }
.tbx-rolepin { cursor: pointer; }
.tbx-rolepin.is-on rect { fill: #b8f03c; }
.tbx-rolepin.is-on text { fill: #0c2419; }
.tbx-rolecard { padding: 4px 2px; }
.tbx-badge { display: inline-block; padding: 1px 8px; border-radius: 6px; background: var(--tbx-lime); color: #0c2419; }
.tbx-q { margin: 10px 0; font-size: 17px; font-weight: 700; }
.tbx-answers { display: grid; gap: 8px; }
.tbx-answers .tbx-btn { justify-content: flex-start; white-space: normal; text-align: left; min-height: 48px; font-weight: 600; }
.tbx-answers .is-right { background: rgba(184, 240, 60, .2); border-color: var(--tbx-lime); }
.tbx-answers .is-wrong { background: rgba(255, 107, 107, .18); border-color: var(--tbx-red); }
.tbx-feedback p { margin: 12px 0 8px; font-size: 14px; }
.tbx-result { font-size: 18px; }
.tbx-result b { color: var(--tbx-lime); }
.tbx-quizbar { display: flex; justify-content: space-between; font-size: 13px; color: var(--tbx-dim); font-weight: 700; }
.tbx-progress { height: 6px; margin: 8px 0; border-radius: 3px; background: #0a1e15; overflow: hidden; }
.tbx-progress i { display: block; height: 100%; background: var(--tbx-lime); transition: width .3s; }
.tbx-quizend { text-align: center; }
.tbx-big { margin: 6px 0; font-size: 44px; font-weight: 800; color: var(--tbx-lime); }
.tbx-stepslist { margin: 8px 0; padding-left: 22px; }
.tbx-stepslist li { padding: 4px 6px; border-radius: 8px; transition: background .3s; }
.tbx-stepslist li.is-on { background: rgba(184, 240, 60, .16); color: #fff; }
.tbx-slider { display: block; margin: 12px 0 4px; font-size: 14px; }
.tbx-slider > span { display: flex; justify-content: space-between; font-weight: 700; }
.tbx-slider b { color: var(--tbx-lime); font-size: 13px; }
.tbx-slider input { width: 100%; margin: 6px 0 0; accent-color: var(--tbx-lime); }
.tbx-slider small { display: flex; justify-content: space-between; font-size: 11px; color: var(--tbx-dim); }
.tbx-today { border-color: var(--tbx-lime); }
.tbx-today small { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .1em; color: var(--tbx-lime); }
.tbx-today b { display: block; font-size: 20px; margin: 2px 0; }
.tbx-terms { list-style: none; margin: 0; padding: 0 !important; }
.tbx-terms li { display: grid; grid-template-columns: 1fr auto; gap: 8px; padding: 10px 0; margin: 0 !important; border-top: 1px solid var(--tbx-line); }
.tbx-terms p { margin: 2px 0 0; font-size: 14px; color: var(--tbx-dim); }
.tbx-tag { margin-left: 8px; padding: 1px 7px; border-radius: 999px; background: #0f2c1f; font-size: 11px; color: var(--tbx-lime); }
.tbx-star { width: 40px; height: 40px; border: 0; background: none; font-size: 22px; color: var(--tbx-gold); }
.tbx-search { margin-bottom: 4px; }
.tbx-toast { position: fixed; left: 50%; bottom: 90px; z-index: 99999; transform: translate(-50%, 12px); padding: 10px 16px; border-radius: 10px; background: var(--tbx-lime); color: #0c2419; font-weight: 700; font-size: 14px; opacity: 0; transition: .25s; pointer-events: none; box-shadow: 0 8px 20px rgba(0, 0, 0, .35); }
.tbx-toast.is-in { opacity: 1; transform: translate(-50%, 0); }
/* page content helpers */
.tbx-fig { margin: 18px 0; }
.tbx-fig img { display: block; width: 100%; height: auto; border-radius: 14px; }
.tbx-fig figcaption { margin-top: 6px; font-size: 13px; color: var(--tbx-dim); text-align: center; }
.tbx-keys { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 16px 0; }
.tbx-keys div { padding: 12px 6px; border-radius: 12px; background: var(--tbx-card); border-top: 3px solid var(--tbx-lime); text-align: center; }
.tbx-keys b { display: block; font-size: 24px; color: var(--tbx-lime); }
.tbx-keys span { font-size: 12px; color: var(--tbx-dim); }
.tbx-callout { margin: 14px 0; padding: 12px 14px; border-radius: 12px; background: rgba(184, 240, 60, .08); border: 1px dashed var(--tbx-lime); font-size: 14px; }
.tbx-callout a, .tbx-links a { color: var(--tbx-lime) !important; text-decoration: underline; text-underline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { .tbx-chip--anim, .tbx-block { transition: none; } }
