/* League on the web iOS kit (src/ioskit/ios.css): system grey lists and a pitch-green tint. The fixture list, table and
   bracket drawings are js/html.js VIEW_CSS (the shared page, printing and the search pages use the same ones); this
   file maps their colours to the kit's and styles the editor's own pieces. */
:root { --canvas: #f2f2f7; --grouped: #f2f2f7; --tint: #12733c; --forest: #12733c; --coral: #12733c; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --canvas: #000; --grouped: #000; --tint: #30d158; --forest: #30d158; --coral: #1f9d4a; } }
:root[data-theme="dark"] { --canvas: #000; --grouped: #000; --tint: #30d158; --forest: #30d158; --coral: #1f9d4a; }
.c-tint { color: var(--tint); }
.lg-page { max-width: 760px; }
.lg-page-wide { max-width: 1120px; }
@media (min-width: 900px) { .lg-page-mid { max-width: 980px; } }
.starter + .group { margin-top: 4px; }
.lg-host { --lg-ink: var(--text); --lg-sub: var(--text2); --lg-line: var(--sep); --lg-card: var(--row); --lg-soft: color-mix(in srgb, var(--tint) 14%, transparent); margin: 0 0 8px; }
.lg-host .lg-table, .lg-host .lg-fx { border-radius: 26px; }
.lg-host .lg-table th, .lg-host .lg-table td { padding-top: 13px; padding-bottom: 13px; }
.lg-host .lg-table .lg-pos { padding-left: 18px; }
.lg-host .lg-table .lg-pts { padding-right: 18px; }
.lg-host .lg-note { margin: 10px 20px 0; }
/* the name and the tabs */
.lg-head { padding: 2px 4px 12px; }
.lg-title { font: 700 30px/1.12 var(--sys); letter-spacing: -0.02em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lg-sub { color: var(--text2); font-size: 15px; line-height: 20px; margin-top: 3px; }
.lg-tabs { padding: 0 0 16px; }
.lg-foot { margin: 4px 20px 18px; font-size: 13px; line-height: 18px; color: var(--text2); }
.lg-tabs + .group, .lg-tabs + .lg-rounds > .group:first-child { margin-top: 2px; }
.lg-rounds > .group:first-child { margin-top: 24px; }
/* a fixture row: home, score, away, with the time and pitch above */
.lg-rhead { display: flex; align-items: baseline; gap: 10px; color: var(--text); }
.lg-rhead span { color: var(--text2); font-weight: 400; font-size: 15px; }
.fx-row { padding-top: 9px; padding-bottom: 9px; }
.fx-row .row-main { display: block; }
.fx { display: grid; grid-template-columns: minmax(0, 1fr) 64px minmax(0, 1fr); align-items: center; gap: 2px 8px; width: 100%; font-variant-numeric: tabular-nums; }
.fx-when { grid-column: 1 / -1; text-align: center; font-size: 12.5px; line-height: 16px; color: var(--text2); }
.fx-h { text-align: right; } .fx-h, .fx-a { font-size: 16px; line-height: 20px; overflow-wrap: anywhere; min-width: 0; }
.fx-win { font-weight: 700; }
.fx-sc { display: flex; align-items: center; justify-content: center; gap: 4px; min-height: 30px; border-radius: 9px; background: var(--fill2); font-weight: 700; font-size: 17px; }
.fx-sc i { font-style: normal; opacity: .45; font-weight: 500; }
.fx-sc.fx-v { font-weight: 500; font-size: 14px; color: var(--text2); background: none; box-shadow: inset 0 0 0 1px var(--sep); }
/* round headings: every result in, or next up */
.lg-rtag { margin-left: auto; align-self: center; font-size: 12px !important; line-height: 20px; font-weight: 600 !important; padding: 0 8px; border-radius: 10px; color: var(--tint) !important; background: color-mix(in srgb, var(--tint) 14%, transparent); }
.lg-vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.lg-rtag-done { display: grid; place-items: center; width: 22px; height: 22px; padding: 0; border-radius: 50%; font-size: 13px !important; }
/* the row just saved */
@keyframes lg-flash { from { background: color-mix(in srgb, var(--tint) 22%, transparent); } }
.fx-flash { animation: lg-flash 1.4s ease-out; }
@media (prefers-reduced-motion: reduce) { .fx-flash { animation: none; } }
/* the table: a team's row opens its fixtures */
.lg-trow { cursor: pointer; -webkit-tap-highlight-color: transparent; }
.lg-trow:active th, .lg-trow:active td { background: var(--fill2); }
@media (hover: hover) { .lg-trow:hover th, .lg-trow:hover td { background: color-mix(in srgb, var(--fill2) 60%, transparent); } }
.lg-trow .lg-team:focus-visible { outline: 3px solid var(--tint); outline-offset: -3px; }
.lg-host .lg-why { margin: 12px 20px 0; }
.lg-champ-card { display: flex; align-items: center; gap: 14px; margin: 0 0 16px; padding: 16px 18px; border-radius: 22px; color: #fff; background: linear-gradient(160deg, #2bb673, #0e6b39); box-shadow: 0 8px 20px rgba(14, 107, 57, .22); }
.lg-champ-card b { display: block; font: 700 20px/1.2 var(--sys); }
.lg-champ-card span span { font-size: 14px; opacity: .9; }
.lg-champ-ic { flex: none; width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; background: rgba(255,255,255,.18); font-size: 24px; }
@media (min-width: 900px) { .lg-rounds { display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px; align-items: start; } }
/* the bracket in the editor */
.lg-kohost { margin-bottom: 10px; }
.lg-kohost .lg-bracket { padding: 4px 4px 14px; }
.lg-kohost .lg-bm { border-radius: 14px; }
.lg-kohost .lg-side { padding-top: 9px; padding-bottom: 9px; font-size: 15px; }
.lg-tap { cursor: pointer; transition: transform .15s var(--ease), box-shadow .15s; -webkit-tap-highlight-color: transparent; }
.lg-tap:not(.lg-done) { box-shadow: 0 0 0 1.5px var(--tint); }
.lg-tap:active { transform: scale(.97); }
.lg-tap:focus-visible { outline: 3px solid var(--tint); outline-offset: 2px; }
.lg-kohost .lg-champ { margin: 4px 20px 0; font-size: 17px; }
/* the result sheet */
.rs-row { gap: 12px; padding-top: 8px; padding-bottom: 8px; }
.rs-name { flex: 1 1 auto; min-width: 0; font-weight: 600; overflow-wrap: anywhere; }
.rs-name small { display: block; font-size: 13px; line-height: 17px; font-weight: 400; color: var(--text2); }
.rs-ctl { flex: none; display: flex; align-items: center; gap: 6px; }
.rs-b { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--fill2); color: var(--text); font-size: 18px; }
.rs-b:disabled { color: var(--text3); }
.rs-b:active:not(:disabled) { opacity: .5; }
.rs-n { width: 58px; height: 48px; border: 0; border-radius: 12px; background: var(--fill2); color: var(--text); text-align: center; font: 700 24px/1 var(--rounded); font-variant-numeric: tabular-nums; outline: none; -webkit-appearance: none; appearance: none; }
.rs-n:focus { box-shadow: 0 0 0 2px var(--tint); }
.rs-n::placeholder { color: var(--text3); font-weight: 500; }
/* teams */
.team-row { padding-right: 6px; }
.team-x { flex: none; width: 44px; height: 44px; display: grid; place-items: center; color: var(--text3); font-size: 20px; }
.team-x:active { opacity: .5; }
.team-seed .fl-label { width: 22px; color: var(--text2); font-variant-numeric: tabular-nums; }
.comp-ic { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; flex: none; color: #fff; background: linear-gradient(160deg, #2bb673, #0e6b39); font-size: 20px; }
/* welcome and empty states */
.starter { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 10px 4px 22px; }
.starter-art { width: 64px; height: 64px; border-radius: 18px; display: grid; place-items: center; color: #fff; font-size: 32px; background: linear-gradient(160deg, #2bb673, #0e6b39); margin-bottom: 8px; box-shadow: 0 8px 20px rgba(14, 107, 57, .25); }
.starter h2 { font: 700 28px/1.12 var(--sys); letter-spacing: -0.02em; margin: 0; }
.starter p { color: var(--text2); font-size: 16px; line-height: 22px; margin: 0 0 8px; max-width: 560px; }
.starter-acts { display: flex; flex-direction: column; gap: 10px; width: 100%; max-width: 420px; }
:root:root #app .starter-acts .btn-primary, :root:root #app .starter-acts .btn-bordered { min-height: 50px; border-radius: 16px; }
/* sharing */
.qr-box { display: grid; place-items: center; padding: 18px; }
.qr-box canvas { width: 240px; height: 240px; image-rendering: pixelated; background: #fff; border-radius: 16px; padding: 14px; box-shadow: 0 6px 20px rgba(0,0,0,.1); }
.url-box { font: 13px/1.45 ui-monospace, "SF Mono", Menlo, monospace; color: var(--text2); overflow-wrap: anywhere; max-height: 5.8em; overflow: hidden; }
.row-btn.dim { opacity: .5; }
.st-bars { display: flex; align-items: flex-end; gap: 2px; height: 80px; width: 100%; } .st-bars i { flex: 1; background: var(--tint); border-radius: 2px 2px 0 0; min-height: 2px; }
.st-big { display: flex; gap: 0; } .st-big > div { flex: 1; text-align: center; } .st-big b { display: block; font: 700 24px/1.2 var(--rounded); } .st-big span { font-size: 12px; color: var(--text2); }
/* printing: only #print, black on white */
#print { display: none; }
@media print {
  @page { margin: 14mm; }
  html, body { height: auto !important; overflow: visible !important; background: #fff !important; }
  body > *:not(#print) { display: none !important; }
  #print { display: block !important; }
}
