:root {
  --bg:#080b0f;
  --panel:#0e1319;
  --panel-2:#11171e;
  --panel-3:#151c24;
  --text:#f4f6fa;
  --muted:#93a0b3;
  --line:#202934;
  --line-soft:rgba(255,255,255,.055);
  --accent:#ff6548;
  --accent-2:#ff7959;
  --good:#3fda79;
  --warn:#e8b44b;
  --danger:#ee4c4f;
  --shadow:0 16px 42px rgba(0,0,0,.32);
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{margin:0;min-height:100vh;background:#080b0f;color:var(--text);font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}
button,input{font:inherit} button{color:inherit} button,a{-webkit-tap-highlight-color:transparent}
.app-shell{min-height:100vh}

/* Header: intentionally compact, matching the reference mockup. */
.topbar{position:sticky;top:0;z-index:50;height:54px;display:grid;grid-template-columns:330px 1fr auto;align-items:center;padding:0 52px;border-bottom:1px solid #222a34;background:rgba(9,13,18,.97);backdrop-filter:blur(14px)}
.brand{display:flex;align-items:center;gap:14px;color:var(--text);text-decoration:none;min-width:0;white-space:nowrap}
.brand-mark{display:none}
.brand-title{font-size:30px;line-height:1;font-weight:900;letter-spacing:.04em;color:#d9deea;flex:0 0 auto}
.brand-subtitle{font-size:12px;line-height:1.08;color:#b0bac9;letter-spacing:.015em;flex:0 0 auto}
.nav{height:100%;display:flex;justify-content:center;gap:16px}
.nav-link,.footer-links button{border:0;background:transparent;cursor:pointer}
.nav-link{position:relative;padding:0 8px;color:#c3cad6;font-size:14px;font-weight:650}
.nav-link::after{content:"";position:absolute;left:4px;right:4px;bottom:0;height:2px;background:var(--accent);transform:scaleX(0);transition:transform .18s ease}
.nav-link:hover,.nav-link.active{color:#fff}.nav-link.active::after{transform:scaleX(1)}
.top-actions{display:flex;align-items:center;gap:13px}.icon-button,.menu-button{width:34px;height:34px;border:0;background:transparent;border-radius:9px;cursor:pointer;color:#c5cddb;font-size:23px}.icon-button:hover,.menu-button:hover{background:#141a21}
.status-pill{height:34px;display:inline-flex;align-items:center;gap:8px;padding:0 13px;border:1px solid rgba(62,213,122,.13);border-radius:10px;background:rgba(62,213,122,.075);color:#cfefda;font-size:12px;font-weight:800;cursor:pointer}
.status-dot{width:8px;height:8px;border-radius:50%;background:var(--good);box-shadow:0 0 12px rgba(62,213,122,.75)}.menu-button{display:none}
.page{animation:pageIn .2s ease both}@keyframes pageIn{from{opacity:.55}to{opacity:1}}

/* Hero: same visual density and composition as the supplied reference. */
.hero{position:relative;height:286px;overflow:hidden;border-bottom:1px solid #1e2630;background:#070a0e}
.hero::before{content:"";position:absolute;inset:0;background-image:url('assets/hero-icct.png');background-repeat:no-repeat;background-position:right center;background-size:auto 100%;opacity:1}
.hero::after{content:"";position:absolute;inset:0;background:linear-gradient(90deg,#06090d 0%,rgba(6,9,13,.99) 29%,rgba(6,9,13,.87) 38%,rgba(6,9,13,.44) 53%,rgba(6,9,13,.05) 71%,rgba(6,9,13,.09) 100%);pointer-events:none}
.hero-inner{position:relative;z-index:2;height:100%;max-width:none;margin:0;padding:37px 52px;display:grid;grid-template-columns:minmax(0,585px) 1fr;align-items:center}
.hero-copy{max-width:585px;text-shadow:0 3px 20px rgba(0,0,0,.62)}.hero-art-spacer{min-height:1px}
.eyebrow{color:var(--accent-2);text-transform:uppercase;letter-spacing:.16em;font-weight:850;font-size:11px}
.hero h1{margin:0 0 4px;font-size:64px;line-height:.99;letter-spacing:-.035em;font-weight:900}.hero h1 .accent{color:var(--accent)}
.hero-subtitle{margin:0 0 12px;font-size:25px;line-height:1.1;font-weight:760;color:#fbfbfd}
.hero-description{max-width:560px;margin:0;color:#a8b4c6;font-size:16px;line-height:1.45}
.hero-actions{display:flex;gap:20px;margin-top:18px;flex-wrap:wrap}
.btn{height:50px;padding:0 27px;border:1px solid #45505e;border-radius:8px;background:rgba(13,18,24,.87);font-weight:800;cursor:pointer;transition:transform .14s ease,background .14s ease,border-color .14s ease}.btn:hover{transform:translateY(-1px);background:#151c24;border-color:#596676}.btn.primary{background:var(--accent);border-color:var(--accent);color:#0f0705}.btn.primary:hover{background:#ff7559}.btn.ghost{background:rgba(9,13,18,.88)}

/* Homepage dashboard */
.dashboard{width:100%;max-width:none;margin:0;padding:7px 26px 8px}
.grid-main{display:grid;grid-template-columns:minmax(0,2.25fr) minmax(385px,1fr);gap:8px}
.section-card{border:1px solid #1d2630;background:linear-gradient(180deg,#10151b,#0c1116);border-radius:10px;overflow:hidden;box-shadow:0 9px 25px rgba(0,0,0,.17)}
.section-head{height:45px;padding:0 14px;display:flex;gap:10px;align-items:center;justify-content:space-between;border-bottom:1px solid #1c242d}
.section-title{display:flex;align-items:center;gap:9px;font-size:16px;font-weight:850}.section-title .pulse{width:10px;height:10px;border-radius:50%;background:#ff4e4e;box-shadow:0 0 12px rgba(255,78,78,.72)}
.section-meta{color:var(--muted);font-size:11px;font-weight:500}.link-btn{border:0;background:none;color:var(--accent-2);font-size:11px;font-weight:800;cursor:pointer}.link-btn:hover{color:#ff9a80}
.live-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;padding:8px}
.live-match{height:228px;border:1px solid #27313d;border-radius:9px;background:#0d1218;overflow:hidden}
.match-top{height:30px;padding:0 10px;display:flex;justify-content:space-between;align-items:center;color:#909db0;font-size:11px}.board-chip{display:inline-flex;align-items:center;height:22px;padding:0 11px;border:1px solid rgba(255,101,72,.43);border-radius:999px;background:rgba(255,101,72,.12);color:#ff765b;font-weight:750}
.match-body{display:grid;grid-template-columns:175px minmax(0,1fr);gap:18px;padding:6px 12px 12px 12px;height:calc(100% - 30px)}
.skeleton-board{width:175px;height:175px;background:conic-gradient(#c6976f 25%,#e6c7a3 0 50%,#c6976f 0 75%,#e6c7a3 0) 0/50% 50%;border:1px solid rgba(255,255,255,.09);opacity:.29;filter:saturate(.72)}
.match-info{display:flex;min-width:0;flex-direction:column;justify-content:center}.engine-slot{display:grid;grid-template-columns:14px minmax(0,1fr) 58px;gap:10px;align-items:center;min-height:48px}.engine-dot{width:9px;height:9px;border-radius:50%;background:#e7ebf4}.engine-dot.hollow{background:transparent;border:1px solid #526075}.engine-slot strong{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:14px;color:#d7dde8}.engine-slot small{display:block;margin-top:4px;color:#758195;font-size:11px}.clock{display:grid;place-items:center;height:34px;border:1px solid #34404d;border-radius:8px;background:#11171e;color:#dce1ea;font-size:12px;font-weight:800}.vs{text-align:center;color:#7e8999;font-size:10px;margin:-2px 0}.eval-row{margin-top:11px;display:grid;grid-template-columns:minmax(0,1fr) 34px;gap:10px;align-items:center}.eval-track{height:10px;border-radius:4px;background:#222d38;overflow:hidden}.eval-track span{display:block;width:50%;height:100%;background:#cfd6e3}.eval-row b{font-size:12px;color:#d5dbe5;text-align:right}

.rating-empty{padding:0 9px 8px}.rating-row{min-height:29px;display:grid;grid-template-columns:36px minmax(0,1fr) 72px 60px;gap:8px;align-items:center;padding:4px 6px;border-bottom:1px solid rgba(255,255,255,.045);color:#cbd2dc;font-size:12px}.rating-row.head{height:31px;color:#98a3b2;background:#151b22;font-size:10px;text-transform:none}.empty-line{height:11px;border-radius:3px;background:linear-gradient(90deg,#171f28,#222c37,#171f28);background-size:230% 100%;animation:shimmer 2s linear infinite}@keyframes shimmer{to{background-position:-230% 0}}
.lower-grid{margin-top:7px;display:grid;grid-template-columns:minmax(0,2.25fr) minmax(385px,1fr);gap:8px}.arena-content{padding:7px;display:grid;grid-template-columns:.85fr 1.3fr;gap:8px}.mini-panel{min-height:172px;padding:9px 12px;border:1px solid #1d2630;border-radius:7px;background:#0c1116}.mini-panel h4{margin:0 0 6px;font-size:12px}.empty-list{display:grid}.empty-list .row{min-height:31px;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:5px 3px;border-bottom:1px solid rgba(255,255,255,.045);color:#9aa6b6;font-size:11px}.chart{height:118px;position:relative;overflow:hidden;border:1px solid #27313c;background-image:linear-gradient(rgba(255,255,255,.05) 1px,transparent 1px),linear-gradient(90deg,rgba(255,255,255,.05) 1px,transparent 1px);background-size:100% 25%,16.66% 100%}.chart::after{content:"";position:absolute;left:3%;right:4%;top:52%;height:2px;background:linear-gradient(90deg,#ff6049,#ff6049 26%,#3aa7ef 26%,#3aa7ef 52%,#e8b94f 52%,#e8b94f 76%,#54c88c 76%);transform:rotate(-3deg);opacity:.72}
.tournament-card{padding:7px}.tournament-banner{min-height:82px;border:1px solid #27303b;border-radius:6px;background:url('assets/upcoming-tournament.png') center/cover no-repeat;box-shadow:inset 0 0 0 1px rgba(255,255,255,.015)}.steps{margin-top:10px;display:grid;grid-template-columns:repeat(4,1fr);gap:6px}.step{text-align:center;color:#96a2b1;font-size:10px}.step::before{content:"";display:block;width:13px;height:13px;margin:0 auto 5px;border:2px solid #53606e;border-radius:50%;background:#121820}.step.active{color:#ff7054}.step.active::before{border-color:#ff7054;background:#ff7054;box-shadow:0 0 0 3px rgba(255,101,72,.12)}
.stats-strip{width:100%;max-width:none;margin:0;padding:0 26px 14px;display:grid;grid-template-columns:repeat(4,1fr);gap:0}.stat-box{min-height:65px;padding:9px 18px;display:flex;align-items:center;gap:12px;border-top:1px solid #202934;border-bottom:1px solid #202934;border-right:1px solid #202934;background:#0b1015}.stat-box:first-child{border-left:1px solid #202934;border-radius:8px 0 0 8px}.stat-box:last-child{border-radius:0 8px 8px 0}.stat-icon{font-size:21px}.stat-box strong{display:block;font-size:15px}.stat-box span{display:block;margin-top:2px;color:#8f9bad;font-size:10px}

/* Other tabs */
.page-shell{max-width:1320px;margin:0 auto;padding:44px 26px 70px}.page-hero{display:flex;align-items:flex-end;justify-content:space-between;gap:22px;margin-bottom:22px}.page-hero h1{font-size:clamp(38px,6vw,62px);margin:0 0 7px}.page-hero p{margin:0;color:var(--muted);max-width:700px;line-height:1.7}.toolbar{display:flex;gap:10px;flex-wrap:wrap}.search-input{width:min(100%,380px);background:#0d1218;border:1px solid var(--line);color:#fff;border-radius:10px;padding:12px 13px;outline:none}.search-input:focus{border-color:#536276}.content-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}.info-card{border:1px solid var(--line);border-radius:12px;background:var(--panel);padding:18px}.info-card h3{margin:0 0 8px}.info-card p{color:var(--muted);line-height:1.65;margin:0}.empty-state{min-height:360px;display:grid;place-items:center;padding:36px;border:1px dashed #2a3645;border-radius:14px;background:rgba(255,255,255,.015);text-align:center}.empty-state .big{font-size:54px;opacity:.72}.empty-state h2{margin:15px 0 8px}.empty-state p{max-width:560px;margin:0;color:var(--muted);line-height:1.7}
.rank-legend{display:flex;gap:8px;flex-wrap:wrap;margin-top:18px}.rank-pill{display:inline-flex;align-items:center;justify-content:center;min-height:30px;padding:6px 10px;border:1px solid rgba(255,255,255,.09);border-radius:7px;color:#fff;font-size:12px;font-weight:900;box-shadow:inset 0 1px 0 rgba(255,255,255,.08)}.cm{background:#6940ad}.fm{background:#d28a26}.im{background:#ec7a25}.gm{background:#d43a3d}.sgm{background:#841c25}.lgm{background:linear-gradient(90deg,#050608 0 32%,#d62f34 32% 100%);border-color:#642124;text-shadow:0 1px 2px #000}.lgm span{color:#fff}
.site-footer{min-height:72px;padding:0 28px;display:flex;justify-content:space-between;align-items:center;gap:20px;border-top:1px solid var(--line);background:#090c11;color:var(--muted);font-size:12px}.site-footer strong{margin-right:12px;color:#fff}.footer-links{display:flex;gap:8px}.footer-links button{color:var(--muted)}.footer-links button:hover{color:#fff}
.modal-backdrop{position:fixed;inset:0;z-index:100;display:grid;place-items:center;padding:20px;background:rgba(0,0,0,.7);backdrop-filter:blur(5px)}.modal-backdrop.hidden{display:none}.modal{width:min(560px,100%);overflow:hidden;border:1px solid #2a3440;border-radius:14px;background:#10161e;box-shadow:var(--shadow)}.modal-head{display:flex;justify-content:space-between;align-items:center;padding:16px 18px;border-bottom:1px solid var(--line)}.modal-head h2{margin:0}.modal-body{padding:18px;color:#c3ccd8;line-height:1.7}.toast{position:fixed;right:20px;bottom:20px;z-index:150;padding:12px 14px;border:1px solid #2a3645;border-radius:10px;background:#161d27;color:#fff;box-shadow:var(--shadow);animation:toastIn .25s ease both}@keyframes toastIn{from{opacity:0;transform:translateY(8px)}}

@media(max-width:1200px){.topbar{grid-template-columns:245px 1fr auto;padding:0 22px}.brand-subtitle{display:none}.nav{gap:4px}.nav-link{padding-left:6px;padding-right:6px;font-size:13px}.hero-inner{padding-left:28px;padding-right:28px}.grid-main,.lower-grid{grid-template-columns:1fr}.match-body{grid-template-columns:150px 1fr}.skeleton-board{width:150px;height:150px}}
@media(max-width:820px){.topbar{height:64px;grid-template-columns:1fr auto;padding:0 14px}.brand-title{font-size:26px}.nav{position:fixed;top:70px;left:12px;right:12px;height:auto;display:none;padding:10px;flex-direction:column;border:1px solid var(--line);border-radius:12px;background:#0d1218;box-shadow:var(--shadow)}.nav.open{display:flex}.nav-link{min-height:40px;text-align:left;border-radius:8px}.nav-link::after{display:none}.nav-link.active{background:#161d27}.menu-button{display:block}.status-pill{display:none}.hero{height:365px}.hero::before{background-size:auto 100%;background-position:58% center}.hero::after{background:linear-gradient(90deg,rgba(6,9,13,.98),rgba(6,9,13,.76))}.hero-inner{grid-template-columns:1fr;padding:45px 22px}.hero h1{font-size:54px}.hero-art-spacer{display:none}.live-grid,.arena-content,.content-grid{grid-template-columns:1fr}.live-match{height:auto;min-height:218px}.stats-strip{grid-template-columns:repeat(2,1fr);gap:7px}.stat-box,.stat-box:first-child,.stat-box:last-child{border:1px solid #202934;border-radius:8px}}
@media(max-width:560px){.hero{height:380px}.hero h1{font-size:46px}.hero-subtitle{font-size:20px}.hero-description{font-size:14px}.hero-actions{gap:9px}.btn{height:46px;padding:0 17px}.dashboard,.stats-strip,.page-shell{padding-left:12px;padding-right:12px}.live-grid{grid-template-columns:1fr}.match-body{grid-template-columns:122px minmax(0,1fr);gap:10px}.skeleton-board{width:122px;height:122px}.engine-slot{grid-template-columns:10px minmax(0,1fr) 50px;gap:7px}.engine-slot strong{font-size:12px}.clock{height:30px}.stats-strip{grid-template-columns:1fr}.page-hero{align-items:flex-start;flex-direction:column}.site-footer{padding:20px 16px;flex-direction:column;align-items:flex-start}}

/* ========================= ICCT V2 — Engine data & profiles ========================= */
.muted-copy{color:var(--muted);font-size:12px;margin:10px 0 0}.tournament-banner{position:relative;overflow:hidden}.tournament-overlay{position:absolute;inset:0;display:flex;flex-direction:column;justify-content:center;padding:0 18px;background:linear-gradient(90deg,rgba(6,9,13,.88),rgba(6,9,13,.12) 75%);text-shadow:0 2px 8px #000}.tournament-overlay b{font-size:17px}.tournament-overlay span{font-size:11px;color:#c5ceda;margin-top:2px}
.rating-click{width:100%;border:0;background:transparent;color:inherit;text-align:left;cursor:pointer}.rating-click:hover{background:rgba(255,255,255,.035)}.seed-engine{display:flex;align-items:center;gap:9px;min-width:0}.seed-engine b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.tiny-state{font-size:9px;color:#ff866d;text-transform:uppercase;letter-spacing:.08em}
.engine-avatar{position:relative;display:grid;place-items:center;width:54px;height:54px;flex:0 0 auto;overflow:hidden;padding:4px;border:1px solid color-mix(in srgb,var(--engine-accent) 50%,#fff0);border-radius:15px;background:#0f151d;box-shadow:inset 0 0 24px color-mix(in srgb,var(--engine-accent) 10%,transparent),0 8px 20px rgba(0,0,0,.28);color:#fff;font-weight:900;letter-spacing:-.03em}
.engine-avatar::after{content:"";pointer-events:none;position:absolute;inset:3px;border:1px solid color-mix(in srgb,var(--engine-accent) 22%,transparent);border-radius:11px;z-index:2}
.engine-logo{position:relative;z-index:1;display:block;width:100%;height:100%;object-fit:contain;object-position:center;border-radius:10px;background:transparent}
.engine-initials{position:relative;z-index:1;font-size:18px;text-shadow:0 0 18px var(--engine-accent)}
.engine-avatar.mini{width:26px;height:26px;padding:2px;border-radius:7px}.engine-avatar.mini::after,.engine-avatar.tiny::after{inset:2px;border-radius:5px}.engine-avatar.mini .engine-initials,.engine-avatar.tiny .engine-initials{font-size:9px}.engine-avatar.mini .engine-logo,.engine-avatar.tiny .engine-logo{border-radius:5px}
.engine-avatar.tiny{width:28px;height:28px;padding:2px;border-radius:7px}
.engine-avatar.profile-avatar{width:106px;height:106px;padding:6px;border-radius:25px}.engine-avatar.profile-avatar::after{inset:5px;border-radius:19px}.engine-avatar.profile-avatar .engine-logo{border-radius:18px}.engine-avatar.profile-avatar .engine-initials{font-size:31px}
.engine-avatar.side-avatar{width:90px;height:90px;padding:5px;border-radius:22px}.engine-avatar.side-avatar .engine-logo{border-radius:16px}.engine-avatar.side-avatar .engine-initials{font-size:27px}
.engine-avatar.panel-avatar{width:42px;height:42px;padding:3px;border-radius:11px}.engine-avatar.panel-avatar .engine-logo{border-radius:8px}.engine-avatar.panel-avatar .engine-initials{font-size:12px}

.engine-index-hero{background:radial-gradient(circle at 82% 40%,rgba(255,101,72,.12),transparent 28%),linear-gradient(135deg,#10161e,#0b1016)}.field-hero-stats{display:flex;gap:8px;align-self:stretch}.field-hero-stats div{min-width:98px;display:flex;flex-direction:column;justify-content:center;align-items:center;border-left:1px solid var(--line);padding:0 14px}.field-hero-stats b{font-size:27px}.field-hero-stats span{font-size:10px;color:var(--muted);text-transform:uppercase;letter-spacing:.1em;margin-top:3px}
.engine-toolbar{display:grid;grid-template-columns:minmax(260px,1fr) 190px 190px auto;gap:10px;margin-top:16px;padding:12px;border:1px solid var(--line);border-radius:12px;background:#0d1218}.engine-search-wrap{height:42px;display:flex;align-items:center;gap:10px;padding:0 13px;border:1px solid #2b3541;border-radius:9px;background:#11171e;color:#778398}.engine-search{width:100%;border:0;outline:0;background:transparent;color:#f4f6fa}.select-control{height:42px;border:1px solid #2b3541;border-radius:9px;background:#11171e;color:#dbe1eb;padding:0 11px;outline:none}.btn.compact{height:42px;padding:0 15px}.engine-summary-strip{display:flex;justify-content:space-between;align-items:center;padding:13px 3px 8px;color:var(--muted);font-size:11px}.engine-summary-strip span:first-child{color:#e6eaf1;font-weight:800}
.engine-card-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}.engine-card{position:relative;min-height:280px;overflow:hidden;border:1px solid #222c37;border-radius:14px;background:linear-gradient(155deg,#121820,#0c1117 68%);cursor:pointer;transition:transform .18s ease,border-color .18s ease,box-shadow .18s ease}.engine-card:hover{transform:translateY(-3px);border-color:color-mix(in srgb,var(--engine-accent) 48%,#27313d);box-shadow:0 16px 34px rgba(0,0,0,.28)}.engine-card-glow{position:absolute;width:170px;height:170px;right:-58px;top:-72px;border-radius:50%;background:var(--engine-accent);opacity:.11;filter:blur(20px)}.engine-card-top{position:relative;z-index:2;display:flex;justify-content:space-between;padding:16px 16px 8px}.watch-button{position:relative;z-index:5;width:34px;height:34px;border:1px solid #303a46;border-radius:9px;background:#11171e;color:#718094;cursor:pointer;font-size:17px}.watch-button:hover,.watch-button.active{color:#ffd766;border-color:#796630;background:rgba(255,215,102,.07)}.engine-card-copy{padding:5px 16px 10px}.engine-card-kicker{font-size:9px;color:var(--engine-accent);font-weight:850;letter-spacing:.12em}.engine-card h3{margin:4px 0 5px;font-size:18px;line-height:1.15}.engine-card-copy p{margin:0;min-height:33px;color:#8996a8;font-size:11px;line-height:1.45}.engine-card-badges{display:flex;gap:5px;flex-wrap:wrap;padding:0 16px 12px}.seed-band,.compute-chip,.status-badge,.preseason-tag,.round-chip{display:inline-flex;align-items:center;height:22px;padding:0 8px;border-radius:999px;border:1px solid #303b48;background:#151c24;color:#bcc6d4;font-size:9px;font-weight:800}.seed-band.elite{color:#ff8067;border-color:rgba(255,101,72,.38);background:rgba(255,101,72,.08)}.seed-band.upper{color:#eec465;border-color:rgba(238,196,101,.3)}.seed-band.mid{color:#7fc2ff}.seed-band.challenger{color:#c699ff}.seed-band.underdog{color:#95a0af}.seed-band.tbd{color:#f5aadc}.compute-chip.gpu{color:#73eaa9;border-color:rgba(78,220,143,.3)}.status-badge.testing{color:#ffc875;border-color:rgba(255,190,80,.28)}.status-badge.registered{color:#8dd7aa}.engine-card-metrics{display:grid;grid-template-columns:repeat(3,1fr);border-top:1px solid #202934;border-bottom:1px solid #202934}.engine-card-metrics div{padding:10px 8px;text-align:center;border-right:1px solid #202934}.engine-card-metrics div:last-child{border:0}.engine-card-metrics span{display:block;color:#718094;font-size:8px;text-transform:uppercase;letter-spacing:.08em}.engine-card-metrics b{display:block;margin-top:3px;font-size:12px}.engine-card-footer{display:flex;justify-content:space-between;padding:10px 16px;color:#8794a5;font-size:10px;font-weight:700}.no-engine-results{grid-column:1/-1;min-height:290px;display:grid;place-items:center;text-align:center;border:1px dashed #303a46;border-radius:14px;color:#7d8998}.no-engine-results>div{font-size:32px}.no-engine-results h3{margin:6px 0}.no-engine-results p{margin:0;font-size:12px}
.profile-page{min-height:calc(100vh - 54px);background:#080b0f}.engine-profile-hero{position:relative;min-height:300px;overflow:hidden;border-bottom:1px solid #202934;background:radial-gradient(circle at 78% 26%,color-mix(in srgb,var(--engine-accent) 24%,transparent),transparent 26%),linear-gradient(122deg,#0d131a 0%,#0a0f15 57%,color-mix(in srgb,var(--engine-accent) 11%,#0b1017) 100%)}.engine-profile-hero::after{content:"";position:absolute;inset:0;background:linear-gradient(90deg,transparent 0 67%,rgba(255,255,255,.012) 67% 67.15%,transparent 67.15%),linear-gradient(rgba(255,255,255,.014) 1px,transparent 1px);background-size:100% 100%,100% 38px;opacity:.65}.profile-gridlines{position:absolute;inset:0;background-image:linear-gradient(90deg,rgba(255,255,255,.025) 1px,transparent 1px);background-size:58px 100%;mask-image:linear-gradient(90deg,transparent,#000 55%,#000)}.profile-watermark{position:absolute;right:5%;top:50%;width:min(27vw,330px);height:min(27vw,330px);transform:translateY(-50%);display:grid;place-items:center;font-size:235px;line-height:1;font-weight:950;color:var(--engine-accent);opacity:.055;letter-spacing:-.08em;filter:saturate(.65)}.profile-watermark img{width:100%;height:100%;object-fit:contain;border-radius:24px}.profile-hero-inner{position:relative;z-index:2;max-width:1500px;margin:auto;padding:28px 44px 32px}.back-link{border:0;background:none;color:#8996a8;cursor:pointer;padding:0 0 22px;font-weight:750}.back-link:hover{color:#fff}.profile-identity{display:flex;align-items:center;gap:24px}.profile-kicker{color:var(--engine-accent);font-size:11px;font-weight:850;letter-spacing:.14em}.profile-name h1{margin:5px 0 12px;font-size:45px;letter-spacing:-.03em}.profile-chips{display:flex;gap:7px;flex-wrap:wrap}.profile-actions{position:absolute;right:44px;bottom:33px;display:flex;gap:8px}.btn.watching{border-color:#705d27;color:#ffd56b;background:rgba(255,211,107,.06)}
.profile-body{max-width:1500px;margin:auto;padding:18px 44px 45px;display:grid;grid-template-columns:minmax(0,1fr) 310px;gap:14px}.profile-main{min-width:0}.profile-metric-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin-bottom:10px}.metric-card{min-height:112px;padding:16px;border:1px solid #222c37;border-radius:12px;background:linear-gradient(145deg,#111820,#0d1218)}.metric-card.accent{border-color:color-mix(in srgb,var(--engine-accent) 35%,#222c37);background:radial-gradient(circle at 100% 0,color-mix(in srgb,var(--engine-accent) 16%,transparent),transparent 42%),#10161d}.metric-card span{display:block;color:#7e8a9b;font-size:10px;text-transform:uppercase;letter-spacing:.09em}.metric-card strong{display:block;margin:7px 0 3px;font-size:23px}.metric-card small{color:#6f7b8d;font-size:9px}.profile-panel{border:1px solid #222c37;border-radius:12px;background:linear-gradient(150deg,#10161d,#0c1117);padding:18px;margin-bottom:10px}.panel-title{display:flex;justify-content:space-between;align-items:flex-start}.panel-title h2{margin:3px 0 0;font-size:20px}.panel-mark{display:flex;align-items:center;justify-content:center;color:var(--engine-accent);opacity:.92}.identity-panel>p{max-width:840px;color:#96a3b5;line-height:1.65;font-size:13px}.seed-meter-wrap{margin-top:20px}.seed-meter-label{display:flex;justify-content:space-between;font-size:10px;color:#7f8b9b}.seed-meter-label b{color:#dfe4ec}.seed-meter{height:7px;margin-top:7px;border-radius:999px;background:#202a35;overflow:hidden}.seed-meter span{display:block;height:100%;border-radius:inherit;background:linear-gradient(90deg,color-mix(in srgb,var(--engine-accent) 50%,#536374),var(--engine-accent));box-shadow:0 0 16px color-mix(in srgb,var(--engine-accent) 38%,transparent)}.identity-facts{display:grid;grid-template-columns:repeat(3,1fr);margin-top:17px;border-top:1px solid #202934}.identity-facts div{padding-top:13px}.identity-facts span{display:block;color:#748093;font-size:9px;text-transform:uppercase;letter-spacing:.08em}.identity-facts b{display:block;margin-top:4px;font-size:11px}.profile-chart-empty{position:relative;height:190px;margin-top:15px;border:1px solid #1f2934;border-radius:9px;overflow:hidden;display:grid;place-items:center;text-align:center;background:#0b1016}.chart-lines{position:absolute;inset:0;background-image:linear-gradient(rgba(255,255,255,.04) 1px,transparent 1px),linear-gradient(90deg,rgba(255,255,255,.035) 1px,transparent 1px);background-size:100% 38px,75px 100%;mask-image:linear-gradient(#000,transparent)}.profile-chart-empty>div:last-child{position:relative;z-index:1;display:flex;flex-direction:column}.profile-chart-empty b{font-size:16px}.profile-chart-empty span{margin-top:4px;color:#758195;font-size:10px}.profile-two-col{display:grid;grid-template-columns:1fr 1fr;gap:10px}.compact-panel{margin-bottom:0}.empty-mini,.tournament-mini{min-height:112px;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;color:#7f8b9c}.empty-mini>span{font-size:22px}.empty-mini b,.tournament-mini b{color:#dce1e9;margin-top:5px}.empty-mini small,.tournament-mini small{margin-top:4px}.round-chip{color:#ff8167;border-color:rgba(255,101,72,.3)}.profile-side{min-width:0}.side-profile-card{text-align:center;padding-top:22px}.side-avatar-wrap{display:flex;justify-content:center}.side-profile-card h3{margin:11px 0 2px}.profile-sub{color:#7c899a;font-size:10px}.side-list{margin-top:18px;border-top:1px solid #202934}.side-list div{display:flex;justify-content:space-between;gap:10px;padding:11px 2px;border-bottom:1px solid #1e2731;font-size:10px}.side-list span{color:#748094}.side-list b{text-align:right}.profile-note h3{margin:5px 0}.profile-note p{color:#8895a6;font-size:11px;line-height:1.55}
.rating-hero-badge{min-width:130px;text-align:center;border-left:1px solid var(--line);padding-left:25px}.rating-hero-badge b{display:block;font-size:30px}.rating-hero-badge span{display:block;color:#7f8b9c;font-size:9px;letter-spacing:.1em}.title-system-card{display:flex;align-items:center;justify-content:space-between;gap:20px}.title-system-card h3{margin-bottom:4px}.title-system-card p{margin:0}.rating-layout{display:grid;grid-template-columns:minmax(0,1fr) 280px;gap:12px;margin-top:12px}.seed-table-card{border:1px solid #222c37;border-radius:12px;overflow:hidden;background:#0d1218}.table-title{height:69px;display:flex;align-items:center;justify-content:space-between;padding:0 16px;border-bottom:1px solid #222c37}.table-title h2{margin:2px 0 0;font-size:20px}.table-title>span{font-size:10px;color:#8190a1}.seed-table-row{width:100%;min-height:44px;display:grid;grid-template-columns:45px minmax(220px,1.5fr) 95px 150px 105px;align-items:center;gap:10px;padding:5px 14px;border:0;border-bottom:1px solid #1c242e;background:transparent;color:#cfd6e1;text-align:left}.seed-table-row:not(.header){cursor:pointer}.seed-table-row:not(.header):hover{background:#121922}.seed-table-row.header{min-height:34px;color:#6f7c8e;font-size:9px;text-transform:uppercase;letter-spacing:.07em}.unrated-text{color:#758195;font-size:10px}.rating-side .profile-panel{margin-bottom:12px}.lock-visual{height:100px;display:grid;place-items:center;font-size:35px;opacity:.55}
.tourney-overview{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin-top:14px}.tourney-overview div{padding:16px;text-align:center;border:1px solid #222c37;border-radius:11px;background:#0e141b}.tourney-overview b{display:block;font-size:22px}.tourney-overview span{display:block;margin-top:3px;color:#758195;font-size:9px;text-transform:uppercase;letter-spacing:.08em}.pot-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin-top:10px}.pot-card{border:1px solid #222c37;border-radius:11px;background:#0d1218;overflow:hidden}.pot-title{padding:13px 12px;border-bottom:1px solid #222c37;display:flex;justify-content:space-between;align-items:center}.pot-title span{font-weight:850}.pot-title small{color:#718094}.pot-engine{width:100%;height:42px;display:grid;grid-template-columns:28px 1fr auto;gap:8px;align-items:center;border:0;border-bottom:1px solid #1d2630;background:transparent;color:#cfd6df;text-align:left;cursor:pointer;padding:0 10px}.pot-engine:hover{background:#121922}.pot-engine span{font-size:10px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.pot-engine b{font-size:10px;color:#8d99aa}.tourney-empty{margin-top:10px;min-height:220px}
.global-search .search-input{width:100%}.global-results{margin-top:10px;max-height:340px;overflow:auto}.global-results>p{color:#7f8b9c}.global-result{width:100%;min-height:48px;display:grid;grid-template-columns:28px 1fr auto;gap:10px;align-items:center;border:0;border-bottom:1px solid #222c37;background:transparent;color:#dce2eb;text-align:left;cursor:pointer}.global-result:hover{background:#121922}.global-result span:nth-child(2){display:flex;flex-direction:column}.global-result small{color:#718094;margin-top:2px}

@media (max-width:1200px){.engine-card-grid{grid-template-columns:repeat(3,1fr)}.profile-body{grid-template-columns:1fr}.profile-side{display:grid;grid-template-columns:1fr 1fr;gap:10px}.profile-side .profile-panel{margin-bottom:0}.pot-grid{grid-template-columns:repeat(2,1fr)}}
@media (max-width:900px){.engine-toolbar{grid-template-columns:1fr 1fr}.engine-search-wrap{grid-column:1/-1}.engine-card-grid{grid-template-columns:repeat(2,1fr)}.profile-metric-grid{grid-template-columns:repeat(2,1fr)}.profile-actions{position:static;margin-top:22px}.profile-identity{align-items:flex-start}.rating-layout{grid-template-columns:1fr}.title-system-card{display:block}.rank-legend{margin-top:12px}.seed-table-row{grid-template-columns:38px minmax(160px,1fr) 75px 120px}.seed-table-row>*:last-child{display:none}.tourney-overview{grid-template-columns:repeat(2,1fr)}}
@media (max-width:620px){.field-hero-stats{display:none}.engine-toolbar{grid-template-columns:1fr}.engine-search-wrap{grid-column:auto}.engine-card-grid{grid-template-columns:1fr}.engine-summary-strip{display:block}.engine-summary-strip span{display:block;margin-bottom:5px}.profile-hero-inner{padding:22px 20px 28px}.profile-identity{gap:14px}.engine-avatar.profile-avatar{width:75px;height:75px;border-radius:19px}.profile-name h1{font-size:31px}.profile-body{padding:12px 16px 32px}.profile-metric-grid{grid-template-columns:1fr 1fr}.profile-two-col{grid-template-columns:1fr}.profile-side{grid-template-columns:1fr}.identity-facts{grid-template-columns:1fr}.profile-watermark{width:130px;height:130px;font-size:130px}.seed-table-row{grid-template-columns:30px minmax(130px,1fr) 65px}.seed-table-row>*:nth-child(4){display:none}.pot-grid{grid-template-columns:1fr}.tourney-overview{grid-template-columns:1fr 1fr}}

/* =========================================================
   ICCT V2.3 — unified Elo / title identity layer
   ========================================================= */
.title-name{font:inherit;font-weight:inherit;letter-spacing:inherit;white-space:inherit}
.title-name.cm-name{color:#b47aff}.title-name.fm-name{color:#f0b94e}.title-name.im-name{color:#ff8b38}.title-name.gm-name{color:#ff5055}.title-name.sgm-name{color:#b82032}.title-name.none-name{color:#dfe5ee}
.title-name.lgm-name .lgm-first{color:#030405;font-weight:950;text-shadow:none;-webkit-text-stroke:.65px rgba(238,242,248,.92);paint-order:stroke fill;filter:none}
.title-name.lgm-name .lgm-rest{color:#ef3d43;font-weight:inherit;text-shadow:none}
.title-badge{min-width:43px;height:24px;min-height:24px;padding:0 8px;font-size:9px;border-radius:6px}
.title-badge.none{background:#202832;color:#9aa6b6}.title-badge span{color:#fff}
.provisional-chip{display:inline-flex;align-items:center;height:22px;padding:0 8px;border-radius:999px;border:1px solid rgba(248,190,77,.35);background:rgba(248,190,77,.08);color:#f4bd55;font-size:8px;font-weight:900;letter-spacing:.08em}
.mini-title{display:inline-flex;justify-content:center;align-items:center;min-width:41px;height:20px;padding:0 6px;border-radius:5px;font-size:9px;font-weight:900;color:#fff;background:#303a46}
.mini-title.cm{background:#6940ad}.mini-title.fm{background:#c98222}.mini-title.im{background:#e66d1e}.mini-title.gm{background:#ce3539}.mini-title.sgm{background:#771923}.mini-title.lgm{background:linear-gradient(90deg,#050608 0 32%,#cf3035 32% 100%);border:1px solid #612126}
.engine-card h3 .title-name{font-size:inherit;font-weight:inherit}
.profile-name h1 .title-name{font-size:inherit;font-weight:inherit}
.seed-engine b .title-name{font-weight:850}
.side-profile-card h3 .title-name{font-weight:850}
.global-result b .title-name{font-weight:800}

.elo-overview{display:flex;flex-direction:column;gap:8px;margin-top:8px}.elo-bar-row{display:grid;grid-template-columns:minmax(100px,1fr) 1.4fr 54px;align-items:center;gap:8px;font-size:10px}.elo-bar-row>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.elo-bar-row>b{text-align:right;color:#dbe2eb}.elo-bar-track{height:6px;border-radius:999px;background:#202934;overflow:hidden}.elo-bar-track i{display:block;height:100%;border-radius:inherit;background:var(--bar);box-shadow:0 0 12px color-mix(in srgb,var(--bar) 35%,transparent)}

.title-metric .metric-title{font-size:24px}.metric-title.cm,.side-title.cm{color:#b47aff}.metric-title.fm,.side-title.fm{color:#f0b94e}.metric-title.im,.side-title.im{color:#ff8b38}.metric-title.gm,.side-title.gm{color:#ff5055}.metric-title.sgm,.side-title.sgm{color:#b82032}.metric-title.lgm,.side-title.lgm{color:#ee3f45}
.title-progress-wrap{margin-top:14px}.title-progress-track{height:7px;margin-top:7px;border-radius:999px;background:#202a35;overflow:hidden}.title-progress-track span{display:block;height:100%;border-radius:inherit}.title-progress-track span.cm{background:#8b56db}.title-progress-track span.fm{background:#e1a33a}.title-progress-track span.im{background:#ec7a25}.title-progress-track span.gm{background:#df4145}.title-progress-track span.sgm{background:#8e202b}.title-progress-track span.lgm{background:linear-gradient(90deg,#07080a,#d63036)}

.rating-baseline-board{position:relative;height:205px;margin-top:15px;border:1px solid #1f2934;border-radius:9px;overflow:hidden;background:#0b1016}.rating-baseline-board .chart-lines{position:absolute;inset:0}.baseline-axis{position:absolute;left:14px;right:14px;bottom:13px;display:flex;justify-content:space-between;color:#536071;font-size:8px}.baseline-line{position:absolute;top:28px;bottom:37px;width:1px;background:linear-gradient(transparent,#687687 20%,#687687 80%,transparent)}.baseline-line i{position:absolute;left:50%;top:50%;width:13px;height:13px;border-radius:50%;transform:translate(-50%,-50%);background:var(--engine-accent);box-shadow:0 0 0 5px color-mix(in srgb,var(--engine-accent) 14%,transparent),0 0 22px color-mix(in srgb,var(--engine-accent) 45%,transparent)}.baseline-line b{position:absolute;left:10px;top:calc(50% - 11px);padding:4px 7px;border-radius:6px;background:#141b24;border:1px solid #2b3643;color:#e8edf4;font-size:10px;white-space:nowrap}.baseline-caption{position:absolute;left:16px;top:14px;display:flex;flex-direction:column;gap:2px}.baseline-caption strong{font-size:12px}.baseline-caption span{color:#758295;font-size:9px}

.rating-summary-cards{display:grid;grid-template-columns:repeat(4,1fr);gap:10px;margin:12px 0}.rating-summary-cards>div{min-height:91px;padding:14px 15px;border:1px solid #222c37;border-radius:11px;background:linear-gradient(145deg,#111820,#0d1218);display:flex;flex-direction:column;justify-content:center}.rating-summary-cards span{color:#748093;font-size:9px;text-transform:uppercase;letter-spacing:.09em}.rating-summary-cards b{margin-top:6px;font-size:20px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.rating-summary-cards small{margin-top:3px;color:#7f8b9b;font-size:9px}.rating-summary-cards b .title-name{font-size:16px}
.rating-controls{display:grid;grid-template-columns:minmax(240px,1fr) 170px auto;gap:9px;align-items:center;margin-top:12px}.rating-controls>span{justify-self:end;color:#8390a2;font-size:10px}
.rating-v21-row{grid-template-columns:45px minmax(230px,1.65fr) 90px 90px 100px 80px!important}.rating-v21-row .title-badge{justify-self:start}.record-cell{color:#94a0b0;font-size:10px}.rating-no-results{padding:55px 20px;text-align:center;color:#788597}.rule-stack{display:flex;flex-direction:column;gap:8px;margin-top:16px}.rule-stack span{padding:9px 10px;border:1px solid #222d38;border-radius:8px;background:#0b1117;color:#8795a7;font-size:10px}.rule-stack b{display:inline-block;min-width:34px;color:#e7ebf1}

.game-toolbar{display:grid;grid-template-columns:minmax(260px,1fr) 190px 170px;gap:9px;margin:12px 0}.game-toolbar [disabled]{opacity:.62;cursor:not-allowed}.game-table-card{border:1px solid #222c37;border-radius:12px;overflow:hidden;background:#0d1218}.game-table-row{display:grid;grid-template-columns:140px minmax(180px,1fr) 80px minmax(180px,1fr) 120px 70px;gap:10px;align-items:center;min-height:39px;padding:0 15px;border-bottom:1px solid #1d2630;color:#cdd4df}.game-table-row.header{background:#121922;color:#728094;font-size:9px;text-transform:uppercase;letter-spacing:.08em}.game-empty{min-height:330px;display:flex;flex-direction:column;justify-content:center;align-items:center;text-align:center;color:#778496}.game-empty>div{font-size:33px}.game-empty h3{margin:8px 0 4px;color:#dce2ea}.game-empty p{margin:0;max-width:470px;font-size:11px;line-height:1.6}

@media(max-width:900px){.rating-summary-cards{grid-template-columns:1fr 1fr}.rating-controls{grid-template-columns:1fr 1fr}.rating-controls .engine-search-wrap{grid-column:1/-1}.rating-v21-row{grid-template-columns:38px minmax(160px,1fr) 75px 75px 78px!important}.rating-v21-row>*:last-child{display:none}.game-toolbar{grid-template-columns:1fr 1fr}.game-toolbar .engine-search-wrap{grid-column:1/-1}.game-table-row{grid-template-columns:100px minmax(140px,1fr) 60px minmax(140px,1fr)}.game-table-row>*:nth-child(5),.game-table-row>*:nth-child(6){display:none}}
@media(max-width:620px){.rating-summary-cards{grid-template-columns:1fr 1fr}.rating-controls{grid-template-columns:1fr}.rating-controls .engine-search-wrap{grid-column:auto}.rating-controls>span{justify-self:start}.rating-v21-row{grid-template-columns:30px minmax(125px,1fr) 62px 62px!important}.rating-v21-row>*:nth-child(5),.rating-v21-row>*:nth-child(6){display:none}.elo-bar-row{grid-template-columns:minmax(90px,1fr) 1fr 48px}.game-toolbar{grid-template-columns:1fr}.game-toolbar .engine-search-wrap{grid-column:auto}.game-table-row{grid-template-columns:minmax(120px,1fr) 58px minmax(120px,1fr)}.game-table-row>*:first-child{display:none}}
.metric-title,.side-title{background:transparent!important;border:0!important;padding:0!important}

/* V2.3: crisp Codeforces-inspired LGM name split */
.title-name.lgm-name{display:inline;white-space:inherit}
.title-name.lgm-name .lgm-first,.title-name.lgm-name .lgm-rest{display:inline;letter-spacing:inherit}

/* =========================================================
   ICCT V2.3 — Online database / persistent sync layer
   ========================================================= */
.status-pill.db-online{border-color:rgba(62,213,122,.28);background:rgba(62,213,122,.105);color:#dff7e8}
.status-pill.db-error{border-color:rgba(238,76,79,.35);background:rgba(238,76,79,.10);color:#ffd5d7}
.status-dot.offline{background:#7f8a98;box-shadow:none}
.status-pill.db-error .status-dot{background:#ef5558;box-shadow:0 0 12px rgba(239,85,88,.55)}

.db-modal{display:flex;flex-direction:column;gap:12px}
.db-modal h3{margin:0;font-size:20px}.db-modal p{margin:0;color:#9ba8ba;line-height:1.6;font-size:12px}
.db-modal label,.admin-editor label{display:flex;flex-direction:column;gap:6px;color:#cfd6df;font-size:10px;font-weight:800;letter-spacing:.02em}
.db-modal small{color:#6f7d90;font-size:9px;line-height:1.55}
.db-state{align-self:flex-start;display:inline-flex;align-items:center;height:24px;padding:0 9px;border-radius:999px;font-size:8px;font-weight:900;letter-spacing:.12em}
.db-state.local{border:1px solid #45515f;background:#141a21;color:#aeb8c6}.db-state.online{border:1px solid rgba(61,219,123,.35);background:rgba(61,219,123,.09);color:#6ee197}
.db-actions{display:flex;gap:8px;flex-wrap:wrap}.db-actions .btn{height:40px;padding:0 15px}
.db-facts{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.db-facts>div{padding:12px;border:1px solid #26313d;border-radius:9px;background:#0c1218}.db-facts span{display:block;color:#758297;font-size:8px;text-transform:uppercase;letter-spacing:.08em}.db-facts b{display:block;margin-top:5px;font-size:18px}
.db-login{display:grid;grid-template-columns:1fr 1fr auto;gap:8px}.db-login .btn{height:42px;padding:0 14px}
.db-user{padding:12px;border:1px solid #25303b;border-radius:9px;background:#0c1218}.db-user b,.db-user span{display:block}.db-user span{margin-top:3px;color:#7d8b9d;font-size:10px}

.btn.admin{border-color:rgba(255,101,72,.35);background:rgba(255,101,72,.12);color:#ff8b72}
.admin-editor{display:flex;flex-direction:column;gap:12px}.admin-editor .select-control{width:100%}.check-row{flex-direction:row!important;align-items:center!important;gap:9px!important}.check-row input{accent-color:var(--accent)}
.admin-rule{margin:0;padding:10px 11px;border:1px solid #25303b;border-radius:8px;background:#0d1319;color:#8190a3;font-size:10px;line-height:1.55}

.history-chart{height:235px;margin-top:14px;padding:12px;border:1px solid #202a35;border-radius:10px;background:#0b1016;position:relative}.history-chart-head,.history-chart-foot{display:flex;align-items:center;justify-content:space-between;color:#7e8b9d;font-size:9px}.history-chart-head b{color:#e4eaf2;font-size:14px}.history-chart svg{display:block;width:100%;height:165px;margin-top:6px;overflow:visible}.history-gridline{fill:none;stroke:#26313d;stroke-width:.35}.history-area{stroke:none}.history-line{fill:none;stroke-width:2.2;vector-effect:non-scaling-stroke;filter:drop-shadow(0 0 5px rgba(255,255,255,.08))}.history-chart-foot{margin-top:-2px}

.recent-game-list{display:flex;flex-direction:column}.recent-game-row{display:grid;grid-template-columns:48px minmax(0,1fr) auto;gap:8px;align-items:center;min-height:38px;border-bottom:1px solid rgba(255,255,255,.05);font-size:10px}.recent-game-row:last-child{border-bottom:0}.recent-game-row small{color:#718094}.recent-result{display:inline-flex;align-items:center;justify-content:center;height:22px;border-radius:5px;background:#18212a;color:#e8edf4;font-weight:900}

.game-count{padding:10px 2px;color:#768396;font-size:10px}.pgn-button{height:24px;padding:0 8px;border:1px solid #35414e;border-radius:6px;background:#121922;color:#cbd4e0;cursor:pointer;font-size:9px;font-weight:800}.pgn-button:hover{border-color:#566373;background:#18212b}.pgn-view{max-height:55vh;overflow:auto;white-space:pre-wrap;word-break:break-word;margin:0;padding:12px;border:1px solid #26313d;border-radius:8px;background:#090d12;color:#dce2ea;font:11px/1.6 ui-monospace,SFMono-Regular,Consolas,monospace}

@media(max-width:760px){.db-login{grid-template-columns:1fr}.db-facts{grid-template-columns:1fr 1fr}.history-chart{height:220px}.history-chart svg{height:150px}}

/* =========================================================
   ICCT V3.0 — Worker / Match Queue
   ========================================================= */
.live-v3 { display:grid; gap:18px; }
.v3-summary { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; }
.v3-summary > div { padding:16px 18px; border:1px solid var(--border); border-radius:14px; background:var(--panel); display:flex; flex-direction:column; gap:4px; }
.v3-summary b { font-size:24px; letter-spacing:-.02em; }
.v3-summary span { color:var(--muted); font-size:12px; text-transform:uppercase; letter-spacing:.08em; }
.worker-grid-v3 { display:grid; grid-template-columns:repeat(auto-fit,minmax(235px,1fr)); gap:12px; }
.worker-card { border:1px solid var(--border); border-radius:14px; padding:14px; background:rgba(255,255,255,.018); display:grid; gap:11px; }
.worker-card.online { border-color:rgba(62,201,125,.32); }
.worker-card-head { display:grid; grid-template-columns:auto 1fr auto; gap:10px; align-items:center; }
.worker-card-head > div { min-width:0; display:grid; gap:2px; }
.worker-card-head b { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.worker-card-head small, .worker-card > small { color:var(--muted); }
.worker-dot { width:10px; height:10px; border-radius:50%; background:#646b75; box-shadow:0 0 0 4px rgba(100,107,117,.12); }
.worker-card.online .worker-dot { background:#42cf83; box-shadow:0 0 0 4px rgba(66,207,131,.12); }
.worker-state { font-size:11px; text-transform:uppercase; letter-spacing:.08em; color:var(--muted); }
.worker-card.online .worker-state { color:#72dfa2; }
.worker-facts { display:flex; flex-wrap:wrap; gap:7px; }
.worker-facts span { padding:5px 8px; border-radius:999px; background:rgba(255,255,255,.055); color:var(--muted); font-size:11px; }
.queue-admin-card { border-color:rgba(255,112,70,.28); }
.queue-form-v3 { display:grid; grid-template-columns:1.3fr 1.3fr .8fr .8fr auto auto; gap:10px; align-items:end; }
.queue-form-v3 label { display:grid; gap:6px; color:var(--muted); font-size:12px; }
.queue-form-v3 .check-row { display:flex; align-items:center; gap:7px; min-height:43px; white-space:nowrap; }
.queue-list-v3 { display:grid; gap:8px; }
.queue-row-v3 { display:grid; grid-template-columns:88px minmax(150px,1fr) 48px minmax(150px,1fr) minmax(160px,.9fr) auto; gap:10px; align-items:center; padding:10px 12px; border:1px solid var(--border); border-radius:12px; background:rgba(255,255,255,.014); }
.queue-engine { display:flex; min-width:0; gap:8px; align-items:center; }
.queue-engine b { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:13px; }
.queue-vs { text-align:center; color:var(--muted); font-weight:700; }
.queue-meta-v3 { color:var(--muted); font-size:12px; }
.queue-status { justify-self:start; border-radius:999px; padding:5px 8px; font-size:10px; font-weight:800; text-transform:uppercase; letter-spacing:.07em; background:rgba(255,255,255,.07); color:var(--muted); }
.queue-status.running { color:#7fe6aa; background:rgba(57,190,116,.12); }
.queue-status.completed { color:#8cc7ff; background:rgba(62,142,219,.12); }
.queue-status.failed { color:#ff8d86; background:rgba(227,81,70,.12); }
.queue-status.claimed { color:#ffd48c; background:rgba(222,161,65,.12); }
.queue-status.cancelled { color:#aeb3bd; }
.queue-controls { display:flex; gap:6px; justify-content:flex-end; }
.queue-action { appearance:none; border:1px solid var(--border); background:rgba(255,255,255,.04); color:var(--text); border-radius:8px; padding:6px 8px; cursor:pointer; font-size:11px; }
.queue-action:hover { border-color:rgba(255,255,255,.28); }
.queue-action.danger { color:#ff9a93; }
.queue-action:disabled { opacity:.45; cursor:not-allowed; }
.queue-error { grid-column:2/-1; color:#e78f89; overflow-wrap:anywhere; }
.queue-empty { color:var(--muted); padding:18px; border:1px dashed var(--border); border-radius:12px; text-align:center; }
@media (max-width:1100px) {
  .queue-form-v3 { grid-template-columns:1fr 1fr; }
  .queue-row-v3 { grid-template-columns:82px 1fr 42px 1fr; }
  .queue-meta-v3 { grid-column:2/4; }
  .queue-controls { grid-column:4; grid-row:2; }
  .queue-error { grid-column:1/-1; }
}
@media (max-width:720px) {
  .v3-summary { grid-template-columns:1fr 1fr; }
  .queue-form-v3 { grid-template-columns:1fr; }
  .queue-row-v3 { grid-template-columns:72px 1fr; }
  .queue-vs { display:none; }
  .queue-meta-v3, .queue-controls { grid-column:2; grid-row:auto; justify-content:flex-start; }
  .queue-error { grid-column:1/-1; }
}

/* ==========================================================
   ICCT V3.1 — AUTOMATIC ARENA
========================================================== */
.arena-control-card{border-color:rgba(82,174,255,.25)}
.arena-state{padding:6px 10px;border-radius:999px;font-size:10px;font-weight:900;letter-spacing:.08em;border:1px solid var(--border);color:var(--muted)}
.arena-state.on{color:#78e7a7;background:rgba(57,190,116,.12);border-color:rgba(57,190,116,.28)}
.arena-state.off{color:#c4c9d1;background:rgba(255,255,255,.045)}
.arena-stat-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;padding:14px 16px 0}
.arena-stat-grid>div{display:grid;gap:3px;padding:13px 14px;border:1px solid var(--border);border-radius:12px;background:rgba(255,255,255,.018)}
.arena-stat-grid b{font-size:20px}
.arena-stat-grid span{font-size:10px;text-transform:uppercase;letter-spacing:.08em;color:var(--muted)}
.arena-control-form{display:grid;grid-template-columns:1fr 150px auto auto auto auto;gap:9px;align-items:end;padding:14px 16px 0}
.arena-control-form label{display:grid;gap:6px;color:var(--muted);font-size:12px}
.arena-control-form .check-row{display:flex;align-items:center;gap:7px;min-height:43px;white-space:nowrap}
.arena-control-form .btn{height:42px;padding:0 14px}
.btn.danger{background:rgba(238,76,79,.13);border-color:rgba(238,76,79,.42);color:#ff9e9f}
.btn.danger:hover{background:rgba(238,76,79,.2);border-color:rgba(238,76,79,.62)}
.btn:disabled{opacity:.45;cursor:not-allowed;transform:none}
.arena-rule-note{margin:14px 16px 0;padding:12px 14px;border-left:3px solid rgba(82,174,255,.5);background:rgba(82,174,255,.05);display:grid;gap:4px;border-radius:0 10px 10px 0}
.arena-rule-note b{font-size:12px}
.arena-rule-note span{font-size:11px;line-height:1.55;color:var(--muted)}
.arena-rotation-wrap{margin:14px 16px 16px;border:1px solid var(--border);border-radius:12px;overflow:hidden;max-height:430px;overflow-y:auto}
.arena-rotation-row{display:grid;grid-template-columns:minmax(230px,1.6fr) 80px 70px 65px 85px 100px;gap:9px;align-items:center;min-height:46px;padding:7px 11px;border-bottom:1px solid rgba(255,255,255,.045);font-size:12px}
.arena-rotation-row:last-child{border-bottom:0}
.arena-rotation-row.head{position:sticky;top:0;z-index:2;min-height:36px;background:#10161d;color:var(--muted);font-size:10px;text-transform:uppercase;letter-spacing:.07em;font-weight:800}
.arena-rotation-engine{display:flex;align-items:center;gap:8px;min-width:0}
.arena-rotation-engine b{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.arena-migration{margin:0 16px 16px;padding:18px;border:1px dashed var(--border);border-radius:12px;color:var(--muted)}
.arena-migration b{display:block;color:var(--text);margin-bottom:5px}
.arena-auto-chip{display:inline-flex;align-items:center;margin-right:6px;padding:2px 5px;border-radius:5px;font-size:9px;line-height:1.2;font-weight:900;letter-spacing:.06em;color:#8cc7ff;background:rgba(62,142,219,.12);vertical-align:middle}

@media(max-width:1050px){
  .arena-control-form{grid-template-columns:1fr 140px 1fr 1fr}
  .arena-control-form .check-row{grid-column:auto}
  .arena-rotation-row{grid-template-columns:minmax(190px,1.5fr) 72px 62px 58px 76px 90px}
}
@media(max-width:760px){
  .arena-stat-grid{grid-template-columns:1fr 1fr}
  .arena-control-form{grid-template-columns:1fr 1fr}
  .arena-control-form .btn{width:100%}
  .arena-rotation-wrap{overflow-x:auto}
  .arena-rotation-row{min-width:720px}
}
@media(max-width:520px){
  .arena-control-form{grid-template-columns:1fr}
  .arena-stat-grid{grid-template-columns:1fr 1fr}
}

/* =================== ICCT V4.0 LIVE / REPLAY =================== */
.live-theater{overflow:hidden;padding:0!important;border:1px solid rgba(156,194,175,.24)!important;background:linear-gradient(165deg,rgba(28,46,41,.67),rgba(16,22,25,.96))!important}
.live-theater>.section-head{padding:20px 22px;border-bottom:1px solid rgba(255,255,255,.08);margin:0}
.live-theater .section-title{font-size:1.05rem;letter-spacing:.01em}
.live-stage-hint{color:#a5c7b3;font-size:.72rem;font-weight:700;letter-spacing:.12em}
.live-v4-layout{display:grid;grid-template-columns:250px minmax(0,1fr);min-height:490px}
.live-channel-pane{background:rgba(12,19,22,.61);border-right:1px solid rgba(255,255,255,.07);padding:18px 12px}
.live-channel-pane h4{font-size:.72rem;letter-spacing:.13em;text-transform:uppercase;color:#92a6a0;padding:0 8px;margin:0 0 12px}
.live-channel-list{display:flex;flex-direction:column;gap:5px;max-height:600px;overflow:auto}
.live-channel{display:grid;grid-template-columns:8px minmax(0,1fr) 16px;gap:8px;align-items:center;border:1px solid transparent;background:transparent;text-align:left;color:#dfe9e5;border-radius:11px;min-width:0;padding:11px 8px;cursor:pointer}
.live-channel:hover{background:rgba(183,215,185,.08)}
.live-channel.selected{background:rgba(133,187,148,.14);border-color:rgba(136,193,149,.3)}
.live-channel b{display:block;font-size:.71rem;line-height:1.4;overflow-wrap:anywhere}
.live-channel i{font-weight:400;color:#a2aca8;font-style:normal}
.live-channel small{display:block;color:#819b91;margin-top:4px;font-size:.63rem}
.live-channel-led{background:#6f7980;width:7px;height:7px;border-radius:50%}
.live-channel-led.running{background:#70de9c;box-shadow:0 0 9px rgba(113,223,153,.5)}
.live-channel-arrow{color:#afc2bd}
.live-quiet{font-size:.76rem;color:#95a59e;padding:12px}
.live-empty-stage{text-align:center;display:grid;place-content:center;min-height:480px;color:#a6bcb3;padding:28px}
.live-empty-stage>div{font-size:3rem;color:#7eb08e}.live-empty-stage h3{color:#eff7ef;font-size:1.1rem;margin:5px 0}
.live-stage{padding:20px}.live-stage-top{display:flex;align-items:center;gap:16px;justify-content:space-between;font-size:.73rem;color:#93a8a0;flex-wrap:wrap;padding:0 3px 18px}
.live-broadcast{display:flex;align-items:center;gap:8px;color:#91f8b3;font-weight:900;letter-spacing:.12em}
.live-broadcast i{background:#72eba3;border-radius:50%;width:8px;height:8px;box-shadow:0 0 11px #7aea9b}
.live-broadcast.stale{color:#f6c985}.live-broadcast.stale i{background:#f4ba67;box-shadow:none}
.live-main-grid{display:grid;grid-template-columns:minmax(270px,480px) minmax(250px,1fr);gap:20px;align-items:start}
.live-board-zone{min-width:0}.live-player{display:flex;align-items:center;gap:9px;padding:9px 5px;color:#f5f7ef}
.live-player>div{flex:1;min-width:0}.live-player b{font-size:.79rem;display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.live-player small{display:block;color:#92a99f;font-size:.65rem;margin-top:3px}
.live-player .live-clock{font-variant-numeric:tabular-nums;font-size:1.12rem;letter-spacing:.06em;background:rgba(219,240,223,.07);padding:10px 12px;border-radius:8px;color:#f1f8ed}
.live-brand-logo{width:34px;height:34px;object-fit:contain;border-radius:7px}.live-no-logo{width:34px;height:34px;display:grid;place-items:center}
.live-board-area{position:relative;padding-left:18px}.live-eval-track{position:absolute;left:0;top:0;height:100%;width:11px;background:#222722;border-radius:4px;overflow:hidden;box-shadow:inset 0 0 0 1px rgba(255,255,255,.12)}
.live-eval-fill{position:absolute;bottom:0;left:0;right:0;background:#f4f1e4;transition:height .45s cubic-bezier(.18,.9,.27,1)}
.icct-board{display:grid;grid-template-columns:repeat(8,minmax(0,1fr));aspect-ratio:1;width:100%;overflow:hidden;border-radius:3px;box-shadow:0 10px 36px rgba(0,0,0,.35)}
.icct-square{position:relative;aspect-ratio:1;display:flex;align-items:center;justify-content:center;min-width:0;min-height:0;isolation:isolate}
.icct-square.light{background:#eeecd9;color:#748b7a}.icct-square.dark{background:#7c9b82;color:#f7f5e6}
.icct-square.last.light{background:#f5e598}.icct-square.last.dark{background:#cec06c}
.icct-piece{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;pointer-events:none;filter:drop-shadow(0 1px 1px rgba(0,0,0,.2));z-index:1}
.rank-coord,.file-coord{position:absolute;font-size:clamp(8px,.8vw,11px);font-weight:800;line-height:1;z-index:2;opacity:.89;user-select:none}
.rank-coord{top:3px;left:3px}.file-coord{bottom:3px;right:3px}
.live-commentary{min-width:0}.live-resultbar{display:flex;justify-content:space-between;gap:8px;flex-wrap:wrap;margin-bottom:12px;font-size:.74rem;color:#9dc2ad}
.live-follow{color:#85e5ae;font-weight:800}.live-insight-grid{display:grid;grid-template-columns:1fr;gap:9px}
.live-analysis-card{background:rgba(5,11,12,.35);border:1px solid rgba(176,210,179,.1);border-radius:11px;padding:12px}
.live-info-name{font-size:.64rem;font-weight:800;color:#a3b8b0;letter-spacing:.13em;margin-bottom:11px}
.live-info-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:5px}
.live-info-grid>div{display:flex;flex-direction:column;gap:4px;min-width:0}.live-info-grid small{font-size:.57rem;color:#879c93}
.live-info-grid b{font-size:clamp(.67rem,.85vw,.89rem);font-variant-numeric:tabular-nums;overflow-wrap:anywhere;color:#ecf5ec}
.live-pv{border-top:1px solid rgba(255,255,255,.08);margin-top:12px;padding-top:10px;display:flex;gap:9px;font-size:.74rem;line-height:1.5}
.live-pv small{font-size:.66rem;color:#92bb9c;font-weight:800;flex:none}.live-pv span{color:#dae8dc;overflow-wrap:anywhere}
.live-move-panel{border:1px solid rgba(190,215,198,.12);border-radius:11px;margin-top:12px;background:rgba(7,13,16,.29);overflow:hidden}
.live-move-panel .section-head{padding:11px 13px;display:flex;align-items:center;margin:0;border-bottom:1px solid rgba(255,255,255,.08)}
.live-moves-scroll{height:150px;overflow:auto;padding:9px;scrollbar-color:#436754 transparent}
.live-move-pair{display:grid;grid-template-columns:32px minmax(0,1fr) minmax(0,1fr);gap:4px;align-items:center;margin-bottom:3px}
.live-move-num{color:#889c92;font-variant-numeric:tabular-nums;font-size:.72rem;padding-left:4px}
.live-move{border:0;background:transparent;color:#dcece1;text-align:left;border-radius:5px;padding:6px;font-size:.79rem;cursor:pointer;min-width:0}
.live-move:hover{background:rgba(255,255,255,.09)}.live-move.active{background:#99c3a3;color:#14251b;font-weight:800}
.live-empty-moves{color:#82978c;padding:22px;text-align:center;font-size:.78rem}
.live-nav-buttons{display:flex;flex-wrap:wrap;align-items:center;gap:5px;border-top:1px solid rgba(255,255,255,.09);padding:10px}
.live-nav-buttons button{border:1px solid rgba(255,255,255,.12);background:rgba(176,202,177,.07);padding:5px 10px;border-radius:7px;color:#e3efdf;cursor:pointer}
.live-nav-buttons button:hover{background:rgba(133,192,154,.19)}.live-nav-buttons span{margin-left:auto;color:#9dac9c;font-size:.76rem}
.live-warning{font-size:.75rem;color:#f4bf80;word-break:break-all;margin-top:10px}
.game-clickable{cursor:pointer}.game-clickable:hover{background:rgba(129,194,144,.08)!important}.game-clickable:focus-visible{outline:2px solid #a2d1af;outline-offset:-2px}
#icctPgnReplay{min-width:0}#icctPgnReplay .replay-top{display:flex;justify-content:space-between;color:#99b9a1;margin-bottom:13px;font-size:.78rem}
#icctPgnReplay .replay-grid{display:grid;grid-template-columns:minmax(0,1.12fr) minmax(240px,.88fr);gap:19px}
#icctPgnReplay .replay-board{max-width:490px}#icctPgnReplay .replay-aside{min-width:0;display:flex;flex-direction:column;gap:10px}
#icctPgnReplay .replay-players{font-size:.85rem;color:#e2eee0;line-height:1.6}
#icctPgnReplay .replay-players strong{padding:4px 8px;border-radius:7px;background:#253c31;color:#b7e5bf}
#icctPgnReplay .replay-moves{max-height:280px;height:220px;border:1px solid rgba(200,230,210,.13);border-radius:9px}
#icctPgnReplay details{color:#9fc3a5;font-size:.8rem;max-height:170px;overflow:auto}
#icctPgnReplay .pgn-view{white-space:pre-wrap;overflow-wrap:anywhere;font-size:.72rem}
.modal:has(#icctPgnReplay){width:min(1100px,96vw);max-width:1100px}.modal:has(#icctPgnReplay) .modal-body{max-height:78vh;overflow:auto}
@media(max-width:1180px){.live-v4-layout{grid-template-columns:210px minmax(0,1fr)}.live-main-grid{grid-template-columns:minmax(260px,1fr);gap:12px}.live-insight-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:790px){.live-v4-layout{grid-template-columns:1fr}.live-channel-pane{border-right:0;border-bottom:1px solid rgba(255,255,255,.08)}.live-channel-list{display:flex;flex-direction:row;overflow-x:auto}.live-channel{min-width:210px}.live-main-grid{grid-template-columns:1fr}.live-board-zone{max-width:570px;margin:auto;width:100%}.live-stage{padding:12px}.live-insight-grid{grid-template-columns:1fr}#icctPgnReplay .replay-grid{grid-template-columns:1fr}.modal:has(#icctPgnReplay){width:96vw}}
@media(max-width:430px){.live-info-grid{grid-template-columns:repeat(3,minmax(0,1fr));row-gap:11px}.live-v4-layout{min-width:0}.live-player .live-clock{font-size:.94rem;padding:8px}.live-analysis-card{padding:9px}}

/* ================================================================
   ICCT V4.1 — En Croissant-inspired readable arena theater
   Board theme: warm tan / walnut with high-contrast Staunton outlines.
   The standalone chess assets are separately licensed (see notice).
   ================================================================ */
.page-shell.live-v3{max-width:1920px;padding:18px clamp(12px,2.1vw,38px) 65px;}
.live-v3 .page-hero{margin-bottom:14px;}
.live-v3 .page-hero h1{font-size:clamp(28px,3.5vw,48px)}
.live-v3 .page-hero p{font-size:.86rem;max-width:960px;}
.live-v4-layout{grid-template-columns:minmax(0,1fr) 206px;min-height:720px;}
.live-channel-pane{border-right:none;border-left:1px solid rgba(255,255,255,.1);padding:15px 9px;}
#icctLiveStage{min-width:0;}
.live-stage{padding:clamp(12px,1.45vw,25px);}
.live-main-grid{grid-template-columns:minmax(510px, min(62vw,720px)) minmax(325px,1fr);gap:clamp(16px,1.8vw,32px);align-items:start;justify-content:center;}
.live-board-zone{min-width:0;width:100%;}
.live-board-area{padding-left:20px;}
.live-player{padding:11px 3px;gap:14px;min-height:66px;}
.live-player b{font-size:clamp(.86rem,1.3vw,1.05rem);}
.live-player small{font-size:.73rem;}
.live-player .live-clock{font-size:clamp(1.14rem,1.7vw,1.45rem);font-weight:850;border:1px solid rgba(255,255,255,.14);}
.live-brand-logo{width:43px;height:43px;}
.live-stage-top{padding-bottom:12px;}
.live-stage-actions{margin-left:auto;display:flex;align-items:center;gap:8px;flex-wrap:wrap;}
.live-sound-toggle,.live-theater-toggle{border:1px solid rgba(188,205,185,.3);border-radius:8px;color:#f5f1df;background:#26352b;cursor:pointer;padding:8px 11px;font-size:.73rem;font-weight:750;min-height:35px;}
.live-sound-toggle:hover,.live-theater-toggle:hover{background:#354e3c;}
.live-sound-toggle[aria-pressed="false"]{color:#abb5a9;background:#1b2521;}
.icct-square.light{background:#f0d9b5;color:#956f43;}
.icct-square.dark{background:#b58863;color:#f9e9d3;}
.icct-square.last.light{background:#eddc7a;}
.icct-square.last.dark{background:#d1ac54;}
.icct-square.in-check{background:radial-gradient(ellipse at center,#f36a4e 0%,#d44e3a 35%,#b58863 85%)!important;box-shadow:inset 0 0 0 3px #e43f36;}
.icct-square .icct-piece{width:98%;height:98%;inset:1%;object-fit:contain;filter:drop-shadow(0 2px 1.3px rgba(0,0,0,.26));}
.rank-coord,.file-coord{font-size:clamp(10px,.85vw,13px);font-weight:850;text-shadow:0 0 1px rgba(0,0,0,.09);}
.live-moves-scroll{height:235px;}
.live-insight-grid{gap:12px;}
.live-analysis-card{padding:15px;background:rgba(15,20,18,.53);}
.live-info-grid b{font-size:clamp(.75rem,.9vw,1rem);}
.live-resultbar{font-size:.83rem;}
.live-check-alert{color:#ffe1da;font-weight:900;border-radius:6px;background:#a7392f;padding:3px 7px;}
.live-checkmate-alert{color:#ffedd9;font-weight:900;border-radius:6px;background:#7c2022;padding:3px 7px;}
.live-theater .section-head{padding:15px 19px;}
.live-theater .live-v4-layout{min-height:0;}
.live-channel-list{max-height:580px;}
.live-channel{padding:12px 8px;}
.live-stage:not(:empty){min-height:540px;}
/* A dedicated focus mode similar to chess sites' spectator theater. */
body.icct-theater-mode{overflow:hidden;}
body.icct-theater-mode .live-theater{position:fixed;inset:8px;z-index:9500;overflow:auto;border-radius:14px;box-shadow:0 0 0 30px rgba(0,0,0,.94);}
body.icct-theater-mode .live-v4-layout{min-height:calc(100dvh - 95px);grid-template-columns:minmax(0,1fr) 210px;}
body.icct-theater-mode .live-main-grid{grid-template-columns:minmax(460px,min(77dvh,850px)) minmax(290px,1fr);}
body.icct-theater-mode .live-board-area{max-height:calc(100dvh - 238px);}
body.icct-theater-mode .live-stage{max-width:1700px;margin:auto;}
/* Home LIVE NOW: real board previews rather than static empty skeletons. */
.icct-home-match{display:block;text-align:left;color:inherit;width:100%;padding:0;cursor:pointer;transition:border-color .14s ease, transform .14s ease, box-shadow .14s ease;}
.icct-home-match:hover{border-color:rgba(161,209,168,.75);transform:translateY(-2px);box-shadow:0 5px 24px rgba(0,0,0,.31);}
.icct-home-match:focus-visible{outline:2px solid #c0e9ad;outline-offset:2px;}
.icct-home-match .match-body{grid-template-columns:175px minmax(0,1fr);gap:12px;}
.home-mini-board{width:175px;height:175px;min-width:0;overflow:hidden;border-radius:5px;}
.home-mini-board .icct-board{box-shadow:none;border-radius:0;}
.home-mini-board .icct-square .icct-piece{filter:drop-shadow(0 1px .5px rgba(0,0,0,.3));}
.home-mini-board .rank-coord,.home-mini-board .file-coord{display:none;}
.icct-home-match .match-info{min-width:0;display:flex;flex-direction:column;justify-content:space-between;gap:6px;}
.icct-home-match .engine-slot{display:flex;align-items:center;justify-content:space-between;gap:7px;border:0;min-height:48px;}
.home-identity{display:flex;align-items:center;gap:8px;min-width:0;}
.home-identity strong{font-size:.76rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:130px;}
.home-identity .live-brand-logo{width:28px;height:28px;border-radius:5px;}
.icct-home-match .clock{min-width:51px;max-width:61px;padding:6px 7px;font-variant-numeric:tabular-nums;}
.home-mini-bottom{display:flex;justify-content:space-between;align-items:center;gap:6px;color:#cbd7cb;font-size:.69rem;}
.home-mini-bottom span:last-child{color:#a6e9af;font-weight:850;}
.home-mini-eval{padding:4px 6px;border-radius:4px;background:#17251b;}
.home-live-empty,.home-live-vacant{width:100%;min-height:222px;display:grid;place-items:center;text-align:center;color:#a1b0a8;padding:20px;border:1px dashed #46564f;border-radius:10px;}
#icctPgnReplay .replay-board{max-width:660px;}
.modal:has(#icctPgnReplay){width:min(1370px,98vw);max-width:1370px;}
.modal:has(#icctPgnReplay) .modal-body{max-height:86dvh;}
@media(max-width:1500px){
  .live-main-grid{grid-template-columns:minmax(410px, min(57vw,640px)) minmax(290px,1fr);}
  .live-v4-layout{grid-template-columns:minmax(0,1fr) 185px;}
}
@media(max-width:1200px){
  .live-v4-layout{grid-template-columns:minmax(0,1fr);}
  .live-channel-pane{order:-1;border-left:none;border-bottom:1px solid rgba(255,255,255,.1);}
  .live-channel-list{display:flex;flex-direction:row;overflow-x:auto;max-height:none;}
  .live-channel{min-width:210px;}
  .live-main-grid{grid-template-columns:minmax(0, min(67vw,690px)) minmax(285px,1fr);gap:13px;}
  body.icct-theater-mode .live-v4-layout{grid-template-columns:1fr;}
  body.icct-theater-mode .live-main-grid{grid-template-columns:minmax(0,min(69dvh,740px)) minmax(270px,1fr);}
}
@media(max-width:900px){
  .live-main-grid,body.icct-theater-mode .live-main-grid{grid-template-columns:1fr;}
  .live-board-zone{max-width:min(95vw,700px);margin:auto;}
  .live-insight-grid{grid-template-columns:repeat(2,minmax(0,1fr));}
  .live-stage-top{gap:7px;}
  .live-v4-layout{min-height:0;}
  body.icct-theater-mode .live-theater{inset:0;border-radius:0;}
  body.icct-theater-mode .live-board-area{max-height:none;}
}
@media(max-width:650px){
  .live-stage-actions{width:100%;justify-content:flex-end;}
  .live-insight-grid{grid-template-columns:1fr;}
  .live-moves-scroll{height:180px;}
  #icctHomeLiveNow{grid-template-columns:1fr;}
  .icct-home-match .match-body{grid-template-columns: min(35vw,150px) minmax(0,1fr);}
  .home-mini-board{width:min(35vw,150px);height:min(35vw,150px);}
  .icct-home-match{height:auto;min-height:195px;}
  .icct-home-match .match-body{height:auto;}
  .home-identity strong{max-width:130px;}
}


/* ===== V4.2: Lichess brown + official cburnett silhouette and ICCT title colors ===== */
/* Based on the well-known Lichess 'brown' board palette; no original default
   (non-free) sound assets are redistributed here. */
.icct-square.light{background:#f0d9b5;color:#b58863;}
.icct-square.dark{background:#b58863;color:#f0d9b5;}
.icct-square.last.light{background:#f6f669;color:#b58863;}
.icct-square.last.dark{background:#baca44;color:#f0d9b5;}
.icct-square.in-check{background:radial-gradient(ellipse at center,#ff5454 0%,#e94c4c 38%,rgba(230,53,53,.85) 55%,transparent 100%)!important;box-shadow:none;}
.icct-square .icct-piece{width:100%;height:100%;inset:0;filter:none;image-rendering:auto;}
.home-mini-board .icct-square .icct-piece{filter:none;}
.rank-coord,.file-coord{font-weight:700;text-shadow:none;}
.live-rated-identity{display:inline-flex;align-items:baseline;flex-wrap:wrap;column-gap:6px;row-gap:2px;line-height:1.36;min-width:0;max-width:100%;}
.live-rated-identity .title-name{font-weight:850;letter-spacing:-.012em;white-space:normal;}
.live-rated-identity .live-elo-current{font-weight:650;color:#d7e5da;white-space:nowrap;font-variant-numeric:tabular-nums;}
.live-elo-delta{font-weight:850;font-variant-numeric:tabular-nums;white-space:nowrap;}
.live-elo-delta.positive{color:#7ce5a2;}
.live-elo-delta.negative{color:#ff8d91;}
.live-elo-delta.zero,.live-elo-delta.awaiting{color:#b4bfbb;}
.live-player b{display:block;overflow:visible;text-overflow:clip;white-space:normal;}
.live-player>div{min-width:0;}
.live-channel b{white-space:normal;line-height:1.45;}
.live-channel .live-rated-identity{font-size:.8rem;}
.home-identity{flex-wrap:wrap;align-content:center;}
.home-identity strong{white-space:normal;max-width:none;line-height:1.45;}
.icct-home-match .engine-slot{min-height:50px;align-items:center;}
.icct-home-match .match-info{gap:8px;}
#icctPgnReplay .replay-players{display:flex;flex-wrap:wrap;align-items:center;gap:8px;}
@media(max-width:600px){
 .live-rated-identity{column-gap:4px;}
 .live-player .live-elo-current{font-size:.8em;}
 .live-player{gap:8px;}
 .home-identity .live-rated-identity{font-size:.71rem;}
}

/* V5.0 Season One — scoped. Existing Lichess board & custom sounds unaffected. */
.tourney-v5{max-width:1600px;margin:0 auto}.v50-season-tag{display:inline-flex;border-radius:7px;padding:4px 10px;background:#473823;color:#f6d69a;font-size:.45em;vertical-align:middle;letter-spacing:1px}
.v50-topcard,.v50-controls{display:grid;gap:16px}.v50-select-row{display:flex;gap:18px;justify-content:space-between;align-items:center;flex-wrap:wrap}.v50-select-row label{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.v50-select-row select{max-width:340px}.v50-admin{display:flex;align-items:end;flex-wrap:wrap;gap:9px}.v50-admin label{font-size:.76rem;display:grid;gap:4px}.v50-admin input{min-width:220px}.v50-rule-note{font-size:.81rem;color:var(--text-muted,#aaa);line-height:1.7}
.v50-stats{display:grid;grid-template-columns:repeat(4,1fr);gap:12px}.v50-stats>div{background:#161d26;border:1px solid #344051;border-radius:12px;padding:15px;display:grid;gap:3px}.v50-stats b{font-size:24px;color:#ecf0f4}.v50-stats span{font-size:.78rem;color:#96a6b5}.v50-bracket-guide{color:#9eaebf;font-size:.84rem;margin-top:8px}
.v50-bracket-scroll{overflow-x:auto;overflow-y:visible;scrollbar-color:#647386 #141d25;padding-bottom:14px}.v50-bracket{min-width:1360px;display:grid;grid-template-columns:repeat(5,minmax(250px,1fr));gap:12px;align-items:start}.v50-column{display:grid;gap:12px}.v50-stage-head{display:flex;justify-content:space-between;background:#202d3b;color:#eef3f8;border-radius:9px;padding:13px 12px}.v50-stage-head span{color:#9faebb;font-size:.8rem}.v50-stage-matches{display:grid;gap:9px}.v50-stage-empty{padding:36px 15px;border:1px dashed #46515f;border-radius:10px;text-align:center;color:#8494a6;font-size:.82rem}
.v50-match{padding:11px;border-radius:11px;background:#161f29;border:1px solid #384757}.v50-match.v50-finished{border-color:#6c6141}.v50-match-top{display:flex;justify-content:space-between;font-size:.69rem;color:#abb8c7;letter-spacing:.45px;margin-bottom:7px}.v50-match-top span:last-child{font-weight:750;color:#bcd9de}.v50-match-player{display:flex;align-items:center;gap:5px;border-radius:6px;padding:7px 5px;min-height:37px}.v50-match-player:nth-child(3){border-top:1px solid #263440}.v50-match-player>small{width:19px;color:#8da4b7}.v50-match-player>b{margin-left:auto;color:#f3f3f3}.v50-winner{background:rgba(203,159,60,.13)}.v50-winner>b{color:#f4cb73}.v50-player{display:inline-flex;gap:6px;align-items:center;min-width:0}.v50-player .title-name{max-width:163px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-weight:700}.v50-logo{width:24px;height:24px;object-fit:contain;border-radius:5px;background:rgba(255,255,255,.04);flex-shrink:0}.v50-logo-placeholder{width:24px;text-align:center}.v50-elo{color:#95aaba;font-size:.8em}.v50-match-actions{display:flex;align-items:center;justify-content:space-between;gap:5px;border-top:1px solid #2d3945;margin-top:6px;padding-top:6px;color:#869bac;font-size:.65rem}.v50-match-actions button,.v50-small-link{border:0;background:transparent;color:#a7d8ee;cursor:pointer;text-decoration:underline}.v50-match-games{padding-top:7px}.v50-game-line{border-top:1px solid #2b3743;display:flex;gap:7px;justify-content:space-between;padding:6px 0;font-size:.7rem}.v50-error{color:#fca2a2}
.v50-bronze .v50-column{width:min(100%,360px)}.v50-entry-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(265px,1fr));gap:8px}.v50-entry{display:flex;gap:7px;align-items:center;background:#15202a;border:1px solid #36414e;border-radius:8px;color:inherit;padding:8px;cursor:pointer;text-align:left}.v50-entry>span:nth-child(2){color:#8fa2b3;font-size:.78rem;min-width:22px}.v50-entry .v50-player{margin-left:5px}.v50-entry .v50-player .title-name{max-width:150px}
.v50-medal{min-width:47px;display:inline-flex;align-items:center;justify-content:center;border-radius:7px;height:35px;font-weight:900;letter-spacing:.5px;color:#f1f3f6;background:#596676;border:1px solid rgba(255,255,255,.14);flex-shrink:0}.v50-place-1{color:#3c2700;background:linear-gradient(135deg,#ffe5a1,#d19b2d)}.v50-place-2{color:#263340;background:linear-gradient(135deg,#f1f7fb,#a4b4c2)}.v50-place-3{color:#39230f;background:linear-gradient(135deg,#eec18a,#aa693a)}.v50-place-4{color:#dce4e8;background:linear-gradient(135deg,#596677,#303d4a)}.v50-place-round{background:#3d4854}.v50-pending{color:#98a4b2;background:#222d38}.v50-profile-history{display:grid;gap:7px}.v50-history-row{display:flex;align-items:center;gap:12px;background:#16202b;border:1px solid #364250;color:inherit;border-radius:10px;padding:10px;cursor:pointer;text-align:left;width:100%}.v50-history-info{display:grid;gap:5px;flex:1}.v50-history-info small{color:#9aabba}.v50-chevron{color:#a0bece}.v50-profile-empty{padding:18px;color:#91a4b2}.v50-champion{display:flex;align-items:center;gap:22px;border:1px solid #b89046;background:linear-gradient(105deg,#45341f,#17232e 70%);border-radius:15px;padding:24px}.v50-champ-icon{font-size:54px}.v50-champion h2{font-size:1.6rem}.v50-champion small{color:#edd08c;font-weight:800}
@media(max-width:700px){.v50-stats{grid-template-columns:repeat(2,1fr)}.v50-admin label{width:100%}.v50-bracket{min-width:1260px}.v50-champion{padding:16px}}

.v50-seeding{display:flex;flex-wrap:wrap;align-items:center;gap:12px;background:#15232f;border:1px dashed #687b8b;border-radius:12px;padding:12px}.v50-seeding>b{flex-basis:100%;color:#ccd9e6}.v50-seeding select{max-width:280px}.v50-seeding button{margin-left:auto}

.v50-rule-editor{display:flex;flex-wrap:wrap;gap:10px;align-items:flex-end;border:1px solid #485566;background:#15212e;border-radius:12px;padding:12px}.v50-rule-editor b{flex-basis:100%}.v50-rule-editor label{display:grid;gap:5px;font-size:.72rem;color:#aab8c7}.v50-rule-editor input{max-width:135px}


/* ICCT V6.0 — Rating system additions; legacy visual layout preserved. */
.elo-trends{display:flex;flex-direction:column;gap:6px;margin-top:7px}
.trend-engine{display:grid;grid-template-columns:minmax(65px,.9fr) minmax(70px,1.35fr) minmax(65px,.85fr);gap:9px;align-items:center;min-height:25px}
.trend-engine>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:10px;font-weight:700}
.trend-engine svg{height:29px;width:100%;min-width:0;overflow:visible;border-bottom:1px solid #27313c}
.trend-engine>b{text-align:right;font-size:11px;white-space:nowrap}
.trend-engine>b small{font-size:10px;font-weight:700;opacity:.9}
.trend-engine .up,.elo-delta.positive{color:#55d8a0}
.trend-engine .down,.elo-delta.negative{color:#ff847e}
.trend-engine .flat,.elo-delta.even{color:#acb7c4}
.trend-empty{font-size:10px;color:#768899;text-align:center}
.rating-progress-v6{display:flex;flex-direction:column;gap:7px;margin:12px 0;padding:14px;border:1px solid #314052;border-radius:10px;background:rgba(34,49,66,.25)}
.rating-progress-v6 strong{font-size:13px;color:#f2f5f9}
.rating-progress-v6 span,.rating-progress-v6 small{font-size:11px;color:#b2becb}
.rating-progress-track{height:7px;width:100%;border-radius:30px;background:#243040;overflow:hidden}
.rating-progress-track i{display:block;height:100%;background:linear-gradient(90deg,#e7624b,#ffb168);border-radius:30px}
.elo-delta{font-size:11px;font-weight:800;white-space:nowrap}
.elo-delta.unrated{color:#7d8897;font-size:10px}
.game-rated-tag{display:block;margin-top:3px;font-size:9px;font-weight:500;color:#97a3b3}
.game-rated-tag .elo-delta{font-size:10px}

.trend-link{padding:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-align:left;font-size:10px;font-weight:700;color:inherit;background:transparent;border:0;cursor:pointer}
.trend-link:hover{text-decoration:underline;color:#fff}

/* V6.1: live-update regions must not compete with the reader's scroll position. */
.live-v3 #icctLiveStage,.live-v3 #icctLiveChannels,.live-v3 .live-channel-list,
.live-v3 .live-moves-scroll,.live-v3 .worker-grid-v3,.live-v3 .queue-list-v3{overflow-anchor:none}
.live-v3 #icctLiveStage{min-width:0}

/* ICCT 7.0 — public release: stable bar zero line and readable confirmed Elo axes */
.live-eval-track{isolation:isolate}
.live-eval-track::after{content:"";position:absolute;left:0;right:0;top:50%;z-index:3;height:2px;background:#f4c64e;transform:translateY(-50%);box-shadow:0 0 3px rgba(0,0,0,.85),0 0 2px rgba(255,225,128,.55);pointer-events:none}
.elo-trends{gap:9px}
.trend-engine{grid-template-columns:minmax(82px,.95fr) minmax(140px,1.8fr) minmax(68px,.7fr);min-height:46px;gap:10px;border-bottom:1px solid rgba(255,255,255,.045)}
.trend-engine:last-child{border-bottom:0}
.trend-plot{display:grid;grid-template-columns:43px minmax(0,1fr);column-gap:5px;align-items:stretch;height:42px;min-width:0}
.trend-plot svg{display:block;width:100%;height:42px;min-width:0}
.trend-axis{height:42px;display:flex;flex-direction:column;justify-content:space-between;text-align:right;color:#9cabb9;font-size:9px;line-height:1;font-variant-numeric:tabular-nums;padding:3px 0 2px}
.trend-link{text-align:left;min-width:0}
.trend-current{font-variant-numeric:tabular-nums;text-align:right;font-size:12px;white-space:nowrap}
.trend-empty{color:#8d9aa8;font-size:10px;line-height:1.4;min-width:0}
.trend-empty-all{padding:14px 8px;text-align:center}
.v70-history-chart{height:auto;min-height:254px;padding:14px}
.history-chart-layout{display:grid;grid-template-columns:54px minmax(0,1fr);gap:8px;align-items:stretch;margin-top:8px}
.history-y-axis{height:166px;position:relative;font-size:11px;color:#a9b7c9;font-variant-numeric:tabular-nums}
.history-axis-tick{position:absolute;right:2px;transform:translateY(-50%);white-space:nowrap}
.v70-history-chart .history-chart-layout svg{width:100%;height:166px;margin:0;overflow:visible}
.v70-history-chart .history-chart-foot{margin-top:8px;margin-left:62px;font-size:10px}
.v70-chart-wait{min-height:185px;padding:15px}
.v70-chart-wait>div{max-width:530px;text-align:center}
@media(max-width:1150px){.trend-engine{grid-template-columns:minmax(76px,.9fr) minmax(110px,1.55fr) minmax(60px,.7fr);gap:6px}.trend-plot{grid-template-columns:37px minmax(0,1fr);gap:3px}.trend-axis{font-size:8px}}
@media(max-width:680px){.trend-engine{grid-template-columns:minmax(85px,.9fr) minmax(126px,1.6fr) minmax(60px,.75fr)}.v70-history-chart{padding:10px}.history-chart-layout{grid-template-columns:48px minmax(0,1fr);gap:4px}.v70-history-chart .history-chart-foot{margin-left:52px}.history-y-axis{font-size:10px}}
@media(prefers-reduced-motion:reduce){.live-eval-fill{transition:none}}
