/* ============================================================
   SANDY ESPORTS - design system
   ============================================================ */
@font-face { font-family: "Barlow Condensed"; font-weight: 900; font-style: italic; src: url("../fonts/BarlowCondensed-BlackItalic.ttf"); font-display: swap; }
@font-face { font-family: "Barlow Condensed"; font-weight: 800; font-style: italic; src: url("../fonts/BarlowCondensed-ExtraBoldItalic.ttf"); font-display: swap; }
@font-face { font-family: "Barlow Condensed"; font-weight: 600; font-style: normal; src: url("../fonts/BarlowCondensed-SemiBold.ttf"); font-display: swap; }
@font-face { font-family: "Inter"; font-weight: 500; src: url("../fonts/inter-500-normal.woff2"); font-display: swap; }
@font-face { font-family: "Inter"; font-weight: 600; src: url("../fonts/inter-600-normal.woff2"); font-display: swap; }
@font-face { font-family: "Inter"; font-weight: 600; src: url("../fonts/inter-700-normal.woff2"); font-display: swap; }
@font-face { font-family: "Mono"; font-weight: 500; src: url("../fonts/jetbrains-mono-latin-500-normal.woff2"); font-display: swap; }

:root {
  --bg: #09090c; --bg2: #0e0e13; --panel: #121218; --panel2: #18181f; --line: #24242d; --line2: #2f2f3a;
  --text: #ededf0; --muted: #a1a1aa; --dim: #85858f;
  --accent: #ff7a00; --accent2: #ffa133; --accent-ink: #120800;
  --win: #4cc38a; --loss: #e5484d; --live: #ff3b3b;
  --r: 16px; --r-sm: 8px;
  --head: "Barlow Condensed", "Arial Narrow", sans-serif; --body: "Inter", system-ui, sans-serif; --mono: "Mono", ui-monospace, monospace;
  --shadow: 0 12px 40px rgba(0,0,0,.45);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--text); font: 500 15px/1.6 var(--body); -webkit-font-smoothing: antialiased; }
/* background: the Sandy Esports logo as thin outlines (assets/code/logo-background.js) */
.lbg { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.lbg-tilt { position: absolute; left: 50%; top: 54%; height: min(84vh, 112vw); aspect-ratio: 675 / 796; transform: translate(-50%, -50%); will-change: transform; }
.lbg-tilt svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.lbg-tilt path { vector-effect: non-scaling-stroke; }
.lbg-base { color: rgba(255,255,255,.075); }
.lbg-base path { stroke-width: 1.3px; }
/* draw-in when the page opens: outer edge first, then the frame, the S, the letters */
.lbg-base path { stroke-dasharray: 1000; stroke-dashoffset: 1000; animation: lbgDraw 2.2s cubic-bezier(.6,.05,.25,1) forwards; }
.lbg .lo-frame path { animation-delay: .25s; } .lbg .lo-s path { animation-delay: .5s; } .lbg .lo-letters path { animation-delay: .85s; animation-duration: 1.6s; }
@keyframes lbgDraw { to { stroke-dashoffset: 0; } }
.lbg-still .lbg-base path { animation: none; stroke-dashoffset: 0; } 
body::after { content: ""; position: fixed; inset: 0; pointer-events: none; z-index: -1;
  background: radial-gradient(ellipse at center, transparent 55%, rgba(0,0,0,.4) 100%); }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
::selection { background: var(--accent); color: var(--accent-ink); }
.wrap { width: min(1440px, 100% - clamp(32px, 6vw, 112px)); margin-inline: auto; }

/* ---------- type ---------- */
.h1, .h2, .h3 { font-family: var(--head); font-style: italic; font-weight: 900; text-transform: uppercase; letter-spacing: .5px; line-height: .95; margin: 0; }
.h1 { font-size: clamp(44px, 5.4vw, 100px); }
.h2 { font-size: clamp(28px, 3.6vw, 40px); }
.h3 { font-size: 24px; }
.eyebrow { font: 500 13px var(--mono); color: var(--accent); }
.muted { color: var(--muted); } .dim { color: var(--dim); }
.mono { font-family: var(--mono); }
.num { font-variant-numeric: tabular-nums; }

/* ---------- nav ---------- */
.nav { position: sticky; top: 0; z-index: 50; background: rgba(9,9,12,.82); backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.nav .wrap { display: flex; align-items: center; gap: 28px; height: 64px; }
.brand { display: flex; align-items: center; gap: 12px; font: italic 900 22px var(--head); letter-spacing: 1px; text-transform: uppercase; }
.brand img { width: 38px; height: 44px; object-fit: contain; }
.brand span b { color: var(--accent); font-weight: 900; }
.nav-links { display: flex; gap: 8px; margin-left: auto; }
.nav-links a { padding: 8px 16px; border-radius: 8px; color: var(--muted); font-weight: 600; font-size: 14px; transition: color .2s, background .2s; }
.nav-links a:hover { color: var(--text); background: var(--panel); }
.nav-links a.on { color: var(--text); background: var(--panel2); box-shadow: inset 0 0 0 1px var(--line2); }
.live-pill { display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 99px; background: rgba(255,59,59,.12); color: #ff8a8a; font: 500 12px var(--mono); box-shadow: inset 0 0 0 1px rgba(255,59,59,.35); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--live); box-shadow: 0 0 0 0 rgba(255,59,59,.7); animation: pulse 1.6s infinite; flex: none; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255,59,59,.6); } 70% { box-shadow: 0 0 0 9px rgba(255,59,59,0); } 100% { box-shadow: 0 0 0 0 rgba(255,59,59,0); } }
.burger { display: none; width: 40px; height: 40px; border-radius: 10px; background: var(--panel); margin-left: auto; }
.burger i, .burger i::before, .burger i::after { display: block; width: 18px; height: 2px; background: var(--text); margin: auto; position: relative; content: ""; }
.burger i::before { position: absolute; top: -6px; } .burger i::after { position: absolute; top: 6px; }

/* ---------- buttons, badges ---------- */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 24px; border-radius: 10px; font-weight: 600; font-size: 14px; transition: transform .15s, box-shadow .2s, background .2s; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: var(--accent-ink); box-shadow: inset 0 1px 0 rgba(255,255,255,.25); }
.btn-primary:hover { background: var(--accent2); }
.btn-ghost { background: var(--panel); box-shadow: inset 0 0 0 1px var(--line2); }
.btn-ghost:hover { background: var(--panel2); }
.badge { display: inline-flex; align-items: center; gap: 8px; padding: 4px 12px 4px; border-radius: 6px; font: 500 12px var(--mono); white-space: nowrap; }
.badge.live { background: rgba(229,72,77,.14); color: #ff8a8a; }
.badge.upcoming { background: rgba(255,122,0,.12); color: var(--accent2); }
.badge.done { background: rgba(255,255,255,.06); color: var(--muted); }
.badge.game { background: transparent; color: var(--text); box-shadow: inset 0 0 0 1px var(--line2); }
.badge.game i { width: 4px; height: 12px; border-radius: 1px; transform: skewX(-18deg); }
.badge.win { background: rgba(61,220,132,.12); color: var(--win); }
.badge.loss { background: rgba(255,93,93,.1); color: var(--loss); }

/* ---------- team mark (generated badge from team colour + tag) ---------- */
.tm { --c: #888; display: inline-grid; place-items: center; flex: none; width: 40px; height: 40px; border-radius: 10px; font: italic 900 15px var(--head); letter-spacing: .5px; color: #fff;
  background: linear-gradient(145deg, color-mix(in srgb, var(--c) 92%, #fff 8%), color-mix(in srgb, var(--c) 55%, #000 45%));
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.14); text-shadow: 0 1px 2px rgba(0,0,0,.4); }
.tm.sm { width: 28px; height: 28px; border-radius: 7px; font-size: 11px; }
.tm.lg { width: 76px; height: 76px; border-radius: 18px; font-size: 28px; }
.tm.xl { width: 112px; height: 112px; border-radius: 24px; font-size: 40px; }
.tm.tbd { background: var(--panel2); box-shadow: inset 0 0 0 1px var(--line2); color: var(--dim); text-shadow: none; }
.team-line { display: flex; align-items: center; gap: 12px; min-width: 0; }
.team-line .nm { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- sections ---------- */
section { padding: 48px 0; }
.sec-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.sec-head .h2 { display: flex; align-items: center; gap: 12px; }
.sec-head a.more { color: var(--muted); font-weight: 600; font-size: 14px; white-space: nowrap; }
.sec-head a.more:hover { color: var(--accent); }
.slash { display: inline-block; width: 10px; height: 26px; background: var(--accent); transform: skewX(-18deg); border-radius: 2px; }
.grid { display: grid; gap: 16px; }
.g3 { grid-template-columns: repeat(3, 1fr); } .g2 { grid-template-columns: repeat(2, 1fr); } .g4 { grid-template-columns: repeat(4, 1fr); }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); }
.empty { padding: 32px; text-align: center; color: var(--muted); border: 1px dashed var(--line2); border-radius: var(--r); }

/* ---------- hero ---------- */
.hero { position: relative; display: flex; flex-direction: column; min-height: calc(100svh - 64px); padding: 0; overflow: hidden; border-bottom: 1px solid var(--line); }
.hero-main { flex: 1; display: grid; grid-template-columns: 1.2fr .8fr; gap: clamp(40px, 4vw, 80px); align-items: center; padding: 64px 0; }
/* teams strip along the bottom of the hero */
.lineup { border-top: 1px solid var(--line); background: rgba(14,14,19,.6); }
.lineup .wrap { display: flex; align-items: center; gap: 24px; padding: 20px 0; }
.lineup-label { flex: none; font: 500 13px var(--mono); color: var(--muted); }
.lineup-teams { flex: 1; display: flex; gap: 8px 24px; flex-wrap: wrap; min-width: 0; }
.lineup-teams a { display: flex; align-items: center; gap: 8px; color: var(--muted); font-weight: 600; font-size: 14px; transition: color .15s cubic-bezier(.22,1,.36,1); }
.lineup-teams a:hover { color: var(--text); }
.lineup .more { flex: none; color: var(--muted); font-weight: 600; font-size: 14px; } .lineup .more:hover { color: var(--accent); }
.lineup .more .ic { width: 14px; height: 14px; vertical-align: -2px; }
.gteams { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.hero p.lead { font-size: clamp(18px, 1.3vw, 20px); line-height: 1.6; color: var(--muted); max-width: 36rem; margin: 20px 0 32px; }
.hero .cta { display: flex; gap: 12px; flex-wrap: wrap; }
.hero .h1 em { color: var(--accent); font-style: italic; }
.hero-art { position: relative; aspect-ratio: 1; display: grid; place-items: center; }
.hero-art img { position: relative; width: 72%; filter: drop-shadow(0 20px 40px rgba(0,0,0,.6)); }
/* hero result card: the deciding match of the latest tournament */
.hero-final { position: relative; display: block; border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); overflow: hidden; transition: border-color .15s cubic-bezier(.22,1,.36,1); }
.hero-final:hover { border-color: var(--line2); }
.hf-top, .hf-foot { position: relative; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 16px 20px; font: 500 12px var(--mono); color: var(--muted); }
.hf-top { background: var(--bg2); border-bottom: 1px solid var(--line); }
.hf-vs { position: relative; display: grid; grid-template-columns: minmax(0,1fr) auto minmax(0,1fr); align-items: center; gap: 16px; padding: clamp(40px, 4vw, 64px) 24px; }
.hf-vs::before { content: ""; position: absolute; inset: 0; background: radial-gradient(55% 120% at 0% 50%, color-mix(in srgb, var(--ca, #444) 30%, transparent), transparent 72%), radial-gradient(55% 120% at 100% 50%, color-mix(in srgb, var(--cb, #444) 30%, transparent), transparent 72%); pointer-events: none; }
.hf-team { position: relative; display: flex; flex-direction: column; align-items: center; gap: 12px; min-width: 0; text-align: center; }
.hf-team .nm { max-width: 100%; font: italic 900 clamp(22px, 1.8vw, 30px)/1 var(--head); text-transform: uppercase; letter-spacing: .5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hf-team.lose { opacity: .55; }
.hf-score { position: relative; font: italic 900 clamp(72px, 6.4vw, 120px)/.9 var(--head); white-space: nowrap; }
.hf-score .sep { color: var(--dim); margin: 0 8px; } .hf-score .l { color: var(--dim); }
.hf-maps { padding: 0 20px 20px; text-align: center; font: 500 12px var(--mono); color: var(--dim); } .hf-maps b { color: var(--muted); font-weight: 500; }
.hf-foot { border-top: 1px solid var(--line); font: 600 15px var(--body); color: var(--text); }
.hf-foot small { display: block; font: 400 12px var(--body); color: var(--dim); margin-bottom: 4px; }
.hf-champ { display: flex; align-items: center; gap: 12px; } .hf-champ .ic { width: 24px; height: 24px; }
.hf-prize { text-align: right; color: var(--accent); font-variant-numeric: tabular-nums; }
.quiet-note { margin: 0; color: var(--muted); }
.stats { display: flex; gap: 32px; margin-top: 36px; flex-wrap: wrap; }
.stats div b { display: block; font: italic 900 38px/1 var(--head); color: var(--text); }
.stats div span { font: 400 13px var(--body); color: var(--muted); }

/* ---------- live strip ---------- */
.live-strip { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); }
.live-card { position: relative; padding: 20px 20px; border-radius: var(--r); background: var(--panel); border: 1px solid rgba(255,59,59,.3); transition: transform .2s, border-color .2s; }
.live-card:hover { border-color: rgba(255,59,59,.6); }
.live-card .top { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 16px; font-size: 13px; color: var(--muted); }
.vs { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; }
.vs .side { display: flex; align-items: center; gap: 12px; min-width: 0; }
.vs .side.r { flex-direction: row-reverse; text-align: right; }
.vs .score { font: italic 900 42px/1 var(--head); letter-spacing: 1px; white-space: nowrap; }
.vs .score .sep { color: var(--dim); margin: 0 8px; }
.vs .score .w { color: var(--text); } .vs .score .l { color: var(--dim); }
.vs .nm { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vs .sub { font: 400 12px var(--mono); color: var(--dim); }

/* ---------- tournament card ---------- */
.t-card { position: relative; display: flex; flex-direction: column; border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); overflow: hidden; transition: transform .2s, border-color .2s, box-shadow .2s; }
.t-card:hover { border-color: var(--line2); }
.t-cover { position: relative; height: 150px; overflow: hidden; background: var(--bg2); }
.t-cover .art { position: absolute; inset: 0; }
.t-cover .art::before { content: ""; position: absolute; inset: 0; background: linear-gradient(115deg, var(--gc, #ff7a00) 0 34%, transparent 34.2%); opacity: .9; }
.t-cover .gname { position: absolute; left: 18px; top: 16px; font: italic 900 30px/1 var(--head); color: rgba(0,0,0,.82); letter-spacing: 1px; z-index: 1; }
.t-cover .logo { position: absolute; right: 14px; bottom: 10px; width: 78px; z-index: 1; border-radius: 12px; }
.t-cover .badge { position: absolute; left: 18px; bottom: 14px; z-index: 1; }
.t-body { padding: 16px 20px 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.t-body .ttl { font: italic 900 26px/1 var(--head); text-transform: uppercase; letter-spacing: .4px; }
.t-body .ttl small { display: block; font: 400 12px var(--mono); color: var(--dim); margin-top: 8px; font-style: normal; text-transform: none; }
.t-meta { display: flex; flex-wrap: wrap; gap: 8px 16px; color: var(--muted); font-size: 13px; }
.t-meta b { color: var(--text); font-weight: 600; }
.t-foot { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.stack { display: flex; } .stack .tm { margin-left: -8px; box-shadow: 0 0 0 2px var(--panel); } .stack .tm:first-child { margin-left: 0; }
.prize { font: 600 20px/1 var(--body); color: var(--accent); font-variant-numeric: tabular-nums; }
.prize small { display: block; font: 400 12px var(--body); color: var(--dim); margin-bottom: 4px; text-align: right; }

/* ---------- tabs / filters ---------- */
.tabs { display: flex; gap: 8px; padding: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; overflow-x: auto; scrollbar-width: none; }
.tabs button, .tabs a { padding: 8px 16px; border-radius: 8px; color: var(--muted); font-weight: 600; font-size: 14px; white-space: nowrap; transition: background .2s, color .2s; }
.tabs button:hover, .tabs a:hover { color: var(--text); }
.tabs .on { background: var(--accent); color: var(--accent-ink); }
.tabs .count { opacity: .7; margin-left: 8px; font-family: var(--mono); font-size: 12px; }
.filters { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 24px; }

/* ---------- page header (tournament / team / match) ---------- */
.ph { position: relative; padding: 48px 0 0; overflow: hidden; border-bottom: 1px solid var(--line); background: linear-gradient(180deg, rgba(14,14,19,.72), rgba(9,9,12,.25)); }
.ph::before { content: ""; position: absolute; inset: 0; background: linear-gradient(115deg, var(--gc, #ff7a00) 0 18%, transparent 18.2%); opacity: .1; }
.ph .wrap { position: relative; }
.crumbs { font-size: 13px; color: var(--dim); margin-bottom: 20px; } .crumbs a:hover { color: var(--accent); }
.ph-main { display: flex; gap: 28px; align-items: center; flex-wrap: wrap; }
.ph-main .logo { width: 110px; border-radius: 16px; filter: drop-shadow(0 10px 24px rgba(0,0,0,.5)); }
.ph-info { flex: 1; min-width: 260px; }
.ph-info .badges { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.ph-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; margin-top: 32px; background: var(--line); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.ph-facts div { background: var(--panel); padding: 16px 20px; }
.ph-facts span { display: block; font: 400 13px var(--body); color: var(--muted); }
.ph-facts b { display: block; margin-top: 4px; font-weight: 600; font-size: 15px; font-variant-numeric: tabular-nums; }
.ph-tabs { display: flex; gap: 4px; margin-top: 24px; overflow-x: auto; scrollbar-width: none; }
.ph-tabs a { padding: 16px 20px; color: var(--muted); font-weight: 600; font-size: 14px; border-bottom: 2px solid transparent; white-space: nowrap; }
.ph-tabs a:hover { color: var(--text); }
.ph-tabs a.on { color: var(--text); border-bottom-color: var(--accent); }

/* ---------- match rows ---------- */
.m-list { display: grid; gap: 8px; }
.m-day { font: 500 13px var(--mono); color: var(--muted); margin: 24px 0 4px; }
.m-row { display: grid; grid-template-columns: 72px minmax(0,1fr) auto minmax(0,1fr) 172px; align-items: center; gap: 16px; padding: 16px 20px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; transition: border-color .2s, background .2s; }
.m-row:hover { border-color: var(--line2); background: var(--panel2); }
.m-row.live { border-color: rgba(255,59,59,.35); }
.m-row .when { font: 500 12px var(--mono); color: var(--muted); line-height: 1.4; }
.m-row .when b { display: block; color: var(--text); font-size: 14px; }
.m-row .t { display: flex; align-items: center; gap: 12px; min-width: 0; }
.m-row .t.r { flex-direction: row-reverse; text-align: right; }
.m-row .t .nm { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.m-row .t.lose .nm { color: var(--muted); }
.m-row .sc { font: italic 900 30px/1 var(--head); min-width: 92px; text-align: center; white-space: nowrap; }
.m-row .sc .w { color: var(--text); } .m-row .sc .l { color: var(--dim); }
.m-row .sc.vs-txt { font-size: 18px; color: var(--dim); }
.m-row .meta { min-width: 0; text-align: right; display: flex; flex-direction: column; align-items: end; gap: 4px; font-size: 12px; color: var(--dim); }
.m-row .meta > span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.m-row .meta .mt { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); }

/* ---------- bracket ---------- */
.bracket { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(220px, 1fr); gap: 24px; overflow-x: auto; padding: 8px 2px 20px; }
.b-col { display: flex; flex-direction: column; }
.b-col h4 { margin: 0 0 16px; font: 500 13px var(--mono); color: var(--muted); }
.b-col .b-matches { flex: 1; display: flex; flex-direction: column; justify-content: space-around; gap: 16px; }
.b-match { position: relative; display: block; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; transition: border-color .15s cubic-bezier(.22,1,.36,1); }
.b-match:hover { border-color: var(--accent); }
.b-match.live { border-color: rgba(255,59,59,.45); }
.b-match .bt { display: flex; align-items: center; gap: 8px; padding: 8px 12px; }
.b-match .bt + .bt { border-top: 1px solid var(--line); }
.b-match .bt .nm { flex: 1; font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.b-match .bt .s { font: italic 900 20px/1 var(--head); width: 24px; text-align: center; color: var(--dim); }
.b-match .bt.win .s { color: var(--accent); } .b-match .bt.win .nm { color: var(--text); }
.b-match .bt.lose .nm { color: var(--muted); }
.b-match .bt.win { background: rgba(255,122,0,.06); }
.b-match .bmeta { display: flex; justify-content: space-between; gap: 8px; padding: 8px 12px; font: 400 12px var(--mono); color: var(--muted); background: var(--bg2); border-bottom: 1px solid var(--line); }
.b-match .bmeta .when { color: var(--accent2); }
.b-match.hl { border-color: rgba(255,122,0,.55); }
.b-sec { display: flex; align-items: center; margin: 8px 0 20px; padding: 12px 16px; border-left: 4px solid var(--accent); background: var(--panel); border-radius: 0 8px 8px 0; }
.b-sec span { font: italic 900 22px var(--head); letter-spacing: .5px; text-transform: uppercase; }
.b-sec ~ .b-sec { margin-top: 32px; }
.winbox { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 24px 20px; border-radius: 14px; text-align: center; background: var(--panel); border: 1px solid rgba(76,195,138,.5); }
.winbox .h3 { font-size: 24px; }
.bracket .b-col:not(:last-child) .b-match::after { content: ""; position: absolute; right: -25px; top: 50%; width: 24px; height: 1px; background: var(--line2); }
.champ { display: flex; align-items: center; gap: 16px; padding: 20px; border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); }
.champ .cup { font-size: 34px; }

/* ---------- tables (standings + scoreboards) ---------- */
.tbl-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--panel); }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; padding: 12px 16px; font: 500 12px var(--mono); color: var(--dim); background: var(--bg2); border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: 12px 16px; border-bottom: 1px solid var(--line); white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
tbody tr { transition: background .15s; } tbody tr:hover { background: var(--panel2); }
td.n, th.n { text-align: right; font-variant-numeric: tabular-nums; }
td.rank { width: 56px; font: 600 15px var(--body); color: var(--dim); font-variant-numeric: tabular-nums; }
tr.top1 td.rank { color: #ffc531; } tr.top2 td.rank { color: #cfd5e0; } tr.top3 td.rank { color: #e08a4f; }
tr.top1 { background: rgba(255,197,49,.05); }
td.pts { font-weight: 600; }
.bar-mini { display: inline-block; height: 6px; border-radius: 4px; background: var(--accent); vertical-align: middle; margin-right: 8px; opacity: .85; }
.mvp { color: #ffc531; font: 500 12px var(--mono); margin-left: 8px; }

/* ---------- match page ---------- */
.mh { padding: 40px 0 32px; border-bottom: 1px solid var(--line); background: linear-gradient(180deg, rgba(14,14,19,.72), rgba(9,9,12,.25)); position: relative; overflow: hidden; }
.mh::before { content: ""; position: absolute; inset: 0; background: radial-gradient(45% 140% at 0% 50%, color-mix(in srgb, var(--ca, #444) 24%, transparent), transparent 72%), radial-gradient(45% 140% at 100% 50%, color-mix(in srgb, var(--cb, #444) 24%, transparent), transparent 72%); pointer-events: none; }
.mh .wrap { position: relative; }
.mh-score { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px; margin-top: 20px; }
.mh-team { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; }
.mh-team .nm { font: italic 900 30px/1 var(--head); text-transform: uppercase; letter-spacing: .5px; }
.mh-team.lose { opacity: .55; }
.mh-mid { text-align: center; }
.mh-mid .big { font: italic 900 clamp(64px, 10vw, 110px)/.9 var(--head); letter-spacing: 2px; }
.mh-mid .big .sep { color: var(--dim); margin: 0 16px; }
.mh-mid .info { margin-top: 12px; display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
.maps { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.map-card { padding: 16px; border-radius: 12px; background: var(--panel); border: 1px solid var(--line); cursor: pointer; transition: border-color .2s; text-align: left; width: 100%; }
.map-card:hover { border-color: var(--line2); }
.map-card.on { border-color: var(--accent); }
.map-card .mn { font: italic 900 22px var(--head); text-transform: uppercase; display: flex; justify-content: space-between; align-items: center; }
.map-card .ms { display: flex; justify-content: space-between; align-items: center; margin-top: 12px; font-weight: 600; }
.map-card .ms .s { font: italic 900 28px var(--head); }
.board-head { display: flex; align-items: center; gap: 12px; margin: 24px 0 12px; }
.kda { color: var(--muted); }

/* ---------- team page ---------- */
.roster { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; }
.player { padding: 20px 16px; border-radius: 12px; background: var(--panel); border: 1px solid var(--line); text-align: center; }
.player .av { width: 64px; height: 64px; margin: 0 auto 12px; border-radius: 50%; display: grid; place-items: center; font: italic 900 24px var(--head);
  background: radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--c) 70%, #fff 10%), color-mix(in srgb, var(--c) 40%, #000 60%)); box-shadow: inset 0 0 0 2px rgba(255,255,255,.15); }
.player .ign { font-weight: 600; } .player .role { font: 400 12px var(--mono); color: var(--dim); margin-top: 4px; }
.team-card { display: flex; align-items: center; gap: 16px; padding: 20px; border-radius: var(--r); background: var(--panel); border: 1px solid var(--line); transition: transform .2s, border-color .2s; }
.team-card:hover { border-color: var(--line2); }
.team-card .nm { font: italic 900 22px/1 var(--head); text-transform: uppercase; }
.team-card .sub { font-size: 13px; color: var(--muted); margin-top: 4px; }
.search { display: flex; align-items: center; gap: 8px; padding: 0 16px; height: 44px; border-radius: 10px; background: var(--panel); border: 1px solid var(--line); min-width: 240px; }
.search input { flex: 1; background: none; border: 0; outline: 0; color: var(--text); font: inherit; }
.search:focus-within { border-color: var(--accent); }

/* ---------- info blocks ---------- */
.kv { display: grid; gap: 8px; }
.kv div { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.kv div:last-child { border-bottom: 0; } .kv span { color: var(--muted); } .kv b { text-align: right; }
.prize-list { display: grid; gap: 8px; }
.prize-list div { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-radius: 10px; background: var(--panel2); }
.prize-list div:first-child { box-shadow: inset 2px 0 0 #ffc531; }
.prize-list b { font: 600 17px var(--body); color: var(--accent); font-variant-numeric: tabular-nums; }
.two { display: grid; grid-template-columns: 1.5fr 1fr; gap: 20px; align-items: start; }
.card-pad { padding: 24px; }
.card-pad h3 { margin: 0 0 16px; font: italic 900 22px var(--head); text-transform: uppercase; letter-spacing: .4px; }
.countdown { display: flex; gap: 8px; }
.countdown div { min-width: 64px; padding: 12px 8px; text-align: center; border-radius: 10px; background: var(--panel2); border: 1px solid var(--line); }
.countdown b { display: block; font: 600 28px/1 var(--body); font-variant-numeric: tabular-nums; } .countdown span { font: 400 12px var(--body); color: var(--dim); }

/* ---------- footer ---------- */
footer { margin-top: 64px; border-top: 1px solid var(--line); padding: 32px 0 40px; color: var(--muted); font-size: 14px; }
footer .wrap { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.socials { display: flex; gap: 8px; } .socials:empty { display: none; }
.socials a { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; background: var(--panel); border: 1px solid var(--line); transition: border-color .2s, color .2s; }
.socials a:hover { border-color: var(--accent); color: var(--accent); }
.socials svg { width: 18px; height: 18px; fill: currentColor; }

/* ---------- motion ---------- */
.fade-in { animation: fadeUp .4s cubic-bezier(.22,1,.36,1) both; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* ---------- responsive ---------- */
@media (max-width: 1000px) {
  .g4 { grid-template-columns: repeat(2, 1fr); } .g3 { grid-template-columns: repeat(2, 1fr); }
  .hero-main { grid-template-columns: 1fr; } .hero { min-height: 0; }
  .lineup .wrap { flex-wrap: wrap; } .lineup-teams { order: 3; flex-basis: 100%; } .hero-art { max-width: 340px; margin: 0 auto; order: -1; } .hero-final { max-width: 560px; }
  .two { grid-template-columns: 1fr; } .roster { grid-template-columns: repeat(3, 1fr); }
  .ph-facts { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 720px) {
  .nav-links { display: none; position: absolute; top: 64px; left: 0; right: 0; flex-direction: column; padding: 12px 16px 20px; background: rgba(9,9,12,.98); border-bottom: 1px solid var(--line); }
  .nav-links.open { display: flex; } .burger { display: block; } .nav .live-pill { display: none; }
  .g3, .g2, .g4 { grid-template-columns: 1fr; } .roster { grid-template-columns: repeat(2, 1fr); }
  .m-row { grid-template-columns: 1fr auto 1fr; gap: 8px; padding: 12px; }
  .m-row .when, .m-row .meta { grid-column: 1 / -1; text-align: left; align-items: start; flex-direction: row; justify-content: space-between; }
  .m-row .when { order: -1; } .m-row .when b { display: inline; margin-right: 8px; }
  .m-row .t .tm { width: 30px; height: 30px; font-size: 11px; } .m-row .sc { font-size: 24px; min-width: 64px; }
  .vs .score { font-size: 32px; } .live-strip { grid-template-columns: 1fr; }
  .mh-team .nm { font-size: 18px; } .mh-score { gap: 8px; grid-template-columns: minmax(0,1fr) auto minmax(0,1fr); } .mh-team { min-width: 0; } .tm.xl { width: 58px; height: 58px; font-size: 22px; border-radius: 14px; }
  .mh-mid .big { font-size: 54px; } .mh-mid .big .sep { margin: 0 8px; } .mh-mid .info .badge { white-space: normal; text-align: center; }
  .ph-main .logo { width: 72px; } .stats { gap: 24px; } .hf-score { font-size: 64px; } .hf-team .nm { font-size: 18px; } .hf-team .tm.lg { width: 56px; height: 56px; } section { padding: 32px 0; }
}

tr.out td { opacity: .6; } tr.out td.rank { opacity: .5; }

/* ---------- VODs ---------- */
.vod-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.vod { display: flex; flex-direction: column; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; transition: border-color .2s, transform .2s; }
.vod:hover { border-color: var(--line2); }
.vod-play, .vod-frame { position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; background: #000; overflow: hidden; }
.vod-play img { width: 100%; height: 100%; object-fit: cover; transition: filter .18s cubic-bezier(.22,1,.36,1); filter: brightness(.82); }
.vod-play:hover img { filter: brightness(1); }
.vod-btn { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 62px; height: 62px; border-radius: 50%; display: grid; place-items: center; padding-left: 4px;
  background: rgba(9,9,12,.72); color: var(--text); font-size: 22px; box-shadow: inset 0 0 0 1px rgba(255,255,255,.14); transition: transform .15s cubic-bezier(.22,1,.36,1), background .15s cubic-bezier(.22,1,.36,1), color .15s cubic-bezier(.22,1,.36,1); }
.vod-play:hover .vod-btn { background: var(--accent); color: var(--accent-ink); }
.vod.big .vod-btn { width: 86px; height: 86px; font-size: 30px; }
.vod-play:active .vod-btn { transform: translate(-50%, -50%) scale(.97); }
.vod-dur { position: absolute; right: 12px; bottom: 12px; padding: 2px 8px; border-radius: 6px; background: rgba(0,0,0,.8); font: 500 12px var(--mono); font-variant-numeric: tabular-nums; }
.vod-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.vod-cap { display: flex; flex-direction: column; gap: 4px; padding: 12px 16px 16px; font-size: 14px; position: relative; }
.vod-title { font-weight: 600; padding-right: 74px; } .vod-title:hover { color: var(--accent); }
.vod-sub { font-size: 12px; }
.vod-yt { position: absolute; right: 16px; top: 12px; font: 500 12px var(--body); color: var(--muted); } .vod-yt:hover { color: var(--accent); }
.vod-main { display: grid; grid-template-columns: 1fr; gap: 16px; }
.vod-main:has(.vod-side) { grid-template-columns: 2.4fr 1fr; align-items: start; }
.vod-side { display: grid; gap: 12px; }
.vodtag { display: inline-flex; align-items: center; color: var(--muted); } .vodtag .ic { width: 12px; height: 12px; }
.bvod { color: var(--accent); }
@media (max-width: 1000px) { .vod-grid { grid-template-columns: repeat(2, 1fr); } .vod-main:has(.vod-side) { grid-template-columns: 1fr; } }
@media (max-width: 720px) { .vod-grid { grid-template-columns: 1fr; } }

/* ---------- icons (assets/code/icons.js) - used instead of emojis ---------- */
.ic { width: 1.05em; height: 1.05em; flex: none; display: inline-block; vertical-align: -0.16em; }
.ic.gold, .medal.gold, .champ .cup { color: #ffc531; }
.medal.silver { color: #c9ced6; }
.medal .ic { width: 15px; height: 15px; vertical-align: -2px; }
.champ .cup .ic { width: 32px; height: 32px; }
.vod-btn .ic { width: 42%; height: 42%; margin-left: 6%; }
.mvp .ic { width: 12px; height: 12px; vertical-align: -1px; }
.search .ic { width: 17px; height: 17px; color: var(--dim); }
.t-meta .ic { color: var(--dim); margin-right: 8px; }
.btn .ic { width: 17px; height: 17px; }
.sbtn .ic { width: 14px; height: 14px; vertical-align: -2px; }
.more .ic, .vod-yt .ic { width: 14px; height: 14px; vertical-align: -2px; }
.status .ic, .status .dot { vertical-align: -2px; margin-right: 4px; }
.side a .ic { width: 17px; height: 17px; margin-right: 8px; vertical-align: -3px; opacity: .85; }

/* ---------- satisfying interactions (assets/code/interactions.js) ---------- */
/* cards: soft light under the cursor + a glowing edge that follows it */
.fx { position: relative; }
.fx-fill, .fx-ring { position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .35s ease; z-index: 1; }
.fx-fill { background: radial-gradient(380px circle at var(--mx, 50%) var(--my, 50%), rgba(255,122,0,.08), transparent 50%); }
.fx-ring { padding: 1.4px; background: radial-gradient(320px circle at var(--mx, 50%) var(--my, 50%), rgba(255,150,60,.38), rgba(255,122,0,.1) 30%, transparent 60%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); }
.fx-on > .fx-fill, .fx-on > .fx-ring { opacity: 1; }
/* tilt: follows quickly while you move, springs back with a little bounce when you leave */
.t-card, .live-card, .team-card { transition: transform .45s cubic-bezier(.22,1,.36,1), border-color .15s; will-change: transform; }
.t-card.fx-tilting, .live-card.fx-tilting, .team-card.fx-tilting { transition: transform .12s ease-out, border-color .15s; }
/* buttons: a shine sweeps across on hover; pressing squishes and springs back */
.btn { position: relative; transition: transform .15s cubic-bezier(.22,1,.36,1), background .15s; }
.btn:active { transform: scale(.97); }
.tabs a, .tabs button, .nav-links a, .sbtn, .vod-play { transition: transform .15s cubic-bezier(.22,1,.36,1), background .15s, color .15s; }
.tabs a:active, .tabs button:active, .sbtn:active { transform: scale(.97); }
.m-row:active, .team-card:active, .t-card:active { transform: scale(.99) !important; }
/* a single soft ring where you click */
.click-ring { position: fixed; z-index: 9999; width: 12px; height: 12px; margin: -8px 0 0 -8px; border-radius: 50%; pointer-events: none;
  border: 1.5px solid rgba(255,140,40,.5); animation: clickRing .5s cubic-bezier(.22,1,.36,1) forwards; }
@keyframes clickRing { to { transform: scale(5); opacity: 0; border-width: .3px; } }
@media (prefers-reduced-motion: reduce) { .t-card, .live-card, .team-card { transition: border-color .15s; } }

/* ---------- unslop details ---------- */
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
.btn:focus-visible, .tabs a:focus-visible, .ph-tabs a:focus-visible { outline-offset: 3px; }
.th-sm { text-transform: none; }
.b-match .bmeta { white-space: nowrap; font-size: 11px; }
.b-match .bmeta > span:first-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.b-match .bmeta .when { flex: none; }
/* entrances play only on the first visit (interactions.js / logo-background.js add these classes) */
html.no-enter .fade-in { animation: none; }
.lbg-drawn .lbg-base path { animation: none; stroke-dashoffset: 0; }
/* match rows inside the narrow overview column: round info drops under the teams so names never get cut */
@media (min-width: 721px) {
  .two .m-row { grid-template-columns: 64px minmax(0,1fr) auto minmax(0,1fr); row-gap: 8px; }
  .two .m-row .meta { grid-column: 2 / -1; flex-direction: row; justify-content: center; }
}
.t-cover .badge.done { background: rgba(9,9,12,.78); color: var(--text); }
@media (max-width: 720px) { .lineup-teams span { display: none; } .lineup-teams { gap: 8px; } .hero-main { padding: 40px 0; } }
@media (max-width: 720px) { .hf-team .nm { white-space: normal; overflow: visible; } }
.hf-team .nm { white-space: normal; overflow: visible; text-wrap: balance; }
/* team page header: a soft glow in the team's colour instead of the slanted block */
.team-ph::before { opacity: 1; background: radial-gradient(50% 140% at 0% 50%, color-mix(in srgb, var(--gc, #444) 30%, transparent), transparent 72%), radial-gradient(40% 120% at 100% 30%, color-mix(in srgb, var(--gc, #444) 12%, transparent), transparent 70%); }
