@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@500;600;700;800&family=Vazirmatn:wght@400;500;600;700;800;900&display=swap');
:root{--bg:#312e2b;--bg2:#262421;--panel:#3a3836;--panel2:#45423f;--panel3:#292724;--text:#f1f1f1;--muted:#aaa7a2;--line:#4c4945;--green:#81b64c;--green2:#6ca13b;--gold:#d6a541;--danger:#c84c4c;--light:#eeeed2;--dark:#769656;--last:#f6f669aa;--select:#f6f669;--shadow:0 14px 35px rgba(0,0,0,.28);--board-size:min(calc(100vh - 180px),calc(100vw - 610px),720px)}
body.light{--bg:#efefed;--bg2:#deddd9;--panel:#fff;--panel2:#f4f3f0;--panel3:#e8e7e3;--text:#262421;--muted:#77736e;--line:#d7d4ce;--shadow:0 14px 32px rgba(25,22,18,.12)}
*{box-sizing:border-box}html{background:var(--bg)}body{margin:0;min-height:100vh;background:radial-gradient(circle at 60% 0,rgba(255,255,255,.035),transparent 32%),var(--bg);color:var(--text);font-family:Vazirmatn,Tahoma,sans-serif}button,input,select{font:inherit}.app{display:grid;grid-template-columns:205px minmax(0,1fr);min-height:100vh}.rail{position:sticky;top:0;height:100vh;background:linear-gradient(180deg,#252421,#1f1e1c);padding:18px 12px;display:flex;flex-direction:column;border-left:1px solid #383633;z-index:30}.rail-close{display:none}.logo{height:58px;display:flex;align-items:center;gap:9px;padding:0 8px;color:#fff;text-decoration:none;font-size:22px;font-weight:800}.logo-piece{font-size:39px;color:var(--green)}.rail nav{display:grid;gap:5px;margin-top:14px}.nav{border:0;background:transparent;color:#b8b5b0;text-align:right;border-radius:8px;padding:10px;display:grid;grid-template-columns:31px 1fr;column-gap:7px;cursor:pointer}.nav>span{grid-row:1/3;font-size:22px;align-self:center;text-align:center}.nav b{font-size:14px}.nav small{font-size:10px;opacity:.65}.nav:hover,.nav.active{background:#3b3936;color:#fff}.nav.active{box-shadow:inset -3px 0 var(--green)}.rail-bottom{margin-top:auto;display:grid;gap:5px}.rail-bottom>button{border:0;background:transparent;color:#aaa7a2;padding:9px 11px;border-radius:8px;text-align:right;cursor:pointer}.rail-bottom>button:hover{background:#363431;color:#fff}.mini-user{display:flex;gap:9px;align-items:center;margin-top:9px;padding:10px 8px;border-top:1px solid #3d3a36}.mini-user b,.mini-user small{display:block}.mini-user b{font-size:12px}.mini-user small{font-size:10px;color:#918e89}.avatar{width:42px;height:42px;border-radius:9px;background:linear-gradient(145deg,#8fc857,#638f38);display:grid;place-items:center;color:#fff;font-weight:800}.avatar.bot{background:linear-gradient(145deg,#77726d,#4a4743)}main{min-width:0;padding:0 24px 34px}.topbar{height:72px;display:flex;align-items:center;justify-content:space-between;max-width:1260px;margin:auto}.hamburger{display:none}.online{font-size:12px;color:var(--muted);display:flex;align-items:center;gap:8px}.online i{width:8px;height:8px;border-radius:50%;background:var(--green);box-shadow:0 0 0 4px rgba(129,182,76,.12)}.top-actions{display:flex;gap:8px}.ghost,.primary{border:0;border-radius:7px;padding:9px 15px;cursor:pointer}.ghost{background:var(--panel);color:var(--text);border:1px solid var(--line)}.primary{background:linear-gradient(#8cc653,#75aa42);color:#fff;font-weight:700;box-shadow:0 2px 0 #557e2f}.primary:hover{filter:brightness(1.04)}.view{display:none}.active-view{display:block}.game-shell{display:grid;grid-template-columns:minmax(0,var(--board-size)) 390px;gap:18px;max-width:1160px;margin:0 auto;direction:ltr;align-items:start}.board-column,.game-panel{direction:rtl}.board-column{width:var(--board-size);min-width:0}.player-strip{height:58px;display:grid;grid-template-columns:minmax(0,1fr) auto auto;align-items:center;gap:12px}.player-main{display:flex;align-items:center;gap:9px}.name-line{display:flex;align-items:center;gap:7px}.name-line b{font-size:14px}.name-line span{font-size:9px;border-radius:4px;padding:2px 5px}.flag{background:#57534f;color:#d7d4d0}.status-badge{background:rgba(129,182,76,.16);color:#a9d67d}.player-main small{display:block;color:var(--muted);font-size:10px}.player-main em{font-style:normal;color:var(--text);margin-right:5px}.captured{direction:ltr;min-width:70px;color:#bcb8b2;font-size:17px;letter-spacing:-4px;white-space:nowrap}.clock{direction:ltr;min-width:105px;text-align:center;background:#232220;color:#aaa7a2;font-size:25px;font-weight:800;border-radius:7px;padding:7px 11px;box-shadow:inset 0 -2px rgba(0,0,0,.25)}body.light .clock{background:#d7d5d1;color:#5e5a55}.clock.active{background:#f1f1f1;color:#262421}.board-stage{display:grid;grid-template-columns:18px minmax(0,1fr);gap:5px;direction:ltr}.eval{height:var(--board-size);background:#111;border-radius:4px;position:relative;overflow:hidden}.eval>div{position:absolute;bottom:0;left:0;width:100%;height:50%;background:#f3f3f3;transition:.3s}.eval span{position:absolute;z-index:2;top:5px;left:50%;transform:translateX(-50%) rotate(-90deg);font-size:8px;color:#aaa}.board-frame{width:var(--board-size);height:var(--board-size);position:relative;box-shadow:0 8px 25px rgba(0,0,0,.35);overflow:hidden;border-radius:3px;background:var(--dark)}.chessboard{width:100%;height:100%;display:grid;grid-template-columns:repeat(8,1fr);grid-template-rows:repeat(8,1fr);direction:ltr}.square{border:0;margin:0;padding:0;min-width:0;min-height:0;display:grid;place-items:center;background:none;position:relative;cursor:pointer;font-family:"DejaVu Sans","Arial Unicode MS",sans-serif;font-size:clamp(32px,calc(var(--board-size)/10.6),72px);line-height:1;text-shadow:0 2px 1px rgba(0,0,0,.22);user-select:none}.square.light{background:var(--light)}.square.dark{background:var(--dark)}.square.last{box-shadow:inset 0 0 0 999px var(--last)}.square.selected{box-shadow:inset 0 0 0 999px rgba(246,246,105,.85)}.square.legal:after{content:"";width:24%;height:24%;border-radius:50%;background:rgba(0,0,0,.22);position:absolute}.square.capture:after{content:"";position:absolute;inset:7%;border:6px solid rgba(0,0,0,.22);border-radius:50%}.square:hover{filter:brightness(1.05)}.piece-w{color:#f4f1e9;-webkit-text-stroke:1px #40403d}.piece-b{color:#2f2e2b;-webkit-text-stroke:1px #050505}.coords{position:absolute;pointer-events:none;font:bold 10px Arial,sans-serif}.coords.files{display:grid;grid-template-columns:repeat(8,1fr);left:0;right:0;bottom:2px;text-align:left;padding:0 4px}.coords.files span:nth-child(odd){color:var(--dark)}.coords.files span:nth-child(even){color:var(--light)}.coords.ranks{display:grid;grid-template-rows:repeat(8,1fr);top:3px;bottom:3px;left:4px;align-items:start}.coords.ranks span:nth-child(odd){color:var(--light)}.coords.ranks span:nth-child(even){color:var(--dark)}.game-panel{background:var(--panel);border-radius:9px;box-shadow:var(--shadow);overflow:hidden;min-height:calc(var(--board-size) + 116px);display:flex;flex-direction:column;border:1px solid rgba(255,255,255,.03)}.panel-head{height:62px;padding:12px 15px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--line)}.panel-head b,.panel-head small{display:block}.panel-head b{font-size:15px}.panel-head small{font-size:10px;color:var(--muted);margin-top:3px}.dots{border:0;background:transparent;color:var(--muted);cursor:pointer}.tabs{display:grid;grid-template-columns:repeat(3,1fr);border-bottom:1px solid var(--line)}.tab{height:45px;border:0;background:transparent;color:var(--muted);cursor:pointer;font-size:12px}.tab.active{color:var(--text);box-shadow:inset 0 -2px var(--green)}.tab-page{display:none;flex:1;min-height:0}.tab-page.active{display:flex;flex-direction:column}.turn-card{margin:12px 14px 8px;background:var(--panel2);border:1px solid var(--line);border-radius:7px;padding:10px 11px;display:flex;gap:10px;align-items:center}.turn-card b,.turn-card small{display:block}.turn-card b{font-size:12px}.turn-card small{color:var(--muted);font-size:10px}.pulse{width:9px;height:9px;border-radius:50%;background:var(--green);box-shadow:0 0 0 5px rgba(129,182,76,.12)}.move-head,.move-row{display:grid;grid-template-columns:38px 1fr 1fr;direction:ltr}.move-head{font-size:9px;color:var(--muted);padding:4px 14px 7px}.move-list{height:clamp(190px,calc(var(--board-size) - 350px),390px);overflow:auto;border-block:1px solid var(--line)}.move-row{min-height:34px;align-items:center;font-size:12px}.move-row:nth-child(even){background:rgba(255,255,255,.025)}.move-row>span{color:var(--muted);text-align:center}.move-cell{height:100%;padding:7px 12px;cursor:pointer}.move-cell:hover{background:rgba(129,182,76,.18)}.empty-state{height:100%;display:grid;place-content:center;text-align:center;color:var(--muted)}.empty-state span{font-size:38px;opacity:.35}.empty-state p{margin:5px 0 0;font-size:12px}.empty-state small{font-size:10px}.move-controls{display:grid;grid-template-columns:repeat(4,1fr);border-bottom:1px solid var(--line)}.move-controls button{height:37px;border:0;background:transparent;color:var(--muted);cursor:pointer}.move-controls button:hover{background:var(--panel2);color:var(--text)}.game-actions{display:grid;grid-template-columns:repeat(3,1fr);gap:7px;padding:11px 12px}.game-actions button{border:1px solid var(--line);background:var(--panel2);color:var(--text);border-radius:6px;padding:8px 4px;font-size:10px;cursor:pointer}.game-actions .danger:hover{background:var(--danger);color:#fff}.new-game-box{margin-top:auto;padding:12px;border-top:1px solid var(--line);background:var(--panel3)}.time-presets{display:grid;grid-template-columns:repeat(4,1fr);gap:5px;direction:rtl}.time-presets button{border:1px solid var(--line);background:var(--panel);color:var(--text);border-radius:6px;padding:6px 2px;cursor:pointer;font-size:11px}.time-presets small{display:block;color:var(--muted);font-size:8px}.time-presets button.selected{border-color:var(--green);box-shadow:inset 0 0 0 1px var(--green)}.setup-row{display:grid;grid-template-columns:1fr 1fr;gap:6px;margin:7px 0}.setup-row select{min-width:0;background:var(--panel);color:var(--text);border:1px solid var(--line);border-radius:6px;padding:8px;font-size:10px}.full{width:100%}.coach-hero{display:flex;gap:10px;align-items:center;padding:18px}.coach-icon{width:43px;height:43px;border-radius:12px;background:linear-gradient(145deg,#8fc857,#5f9232);display:grid;place-items:center;font-size:22px}.coach-hero b,.coach-hero small{display:block}.coach-hero small{color:var(--muted);font-size:10px}.coach-message{margin:0 16px;background:var(--panel2);border-right:3px solid var(--green);padding:15px;border-radius:7px;line-height:2;font-size:12px}.analysis-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px;padding:14px 16px 8px}.analysis-grid div{background:var(--panel2);padding:10px;border-radius:7px}.analysis-grid small,.analysis-grid b{display:block}.analysis-grid small{color:var(--muted);font-size:9px}.meter{height:6px;background:var(--panel2);margin:0 16px;border-radius:5px;overflow:hidden}.meter span{display:block;height:100%;background:var(--green);width:0;transition:.3s}.coach-tips{padding:12px 16px;color:var(--muted);font-size:10px;line-height:1.8}.chat-area{flex:1;padding:14px}.system-msg{background:var(--panel2);color:var(--muted);font-size:10px;padding:10px;border-radius:8px;text-align:center}.chat-input{display:grid;grid-template-columns:1fr auto;gap:6px;padding:10px;border-top:1px solid var(--line)}.chat-input input{min-width:0;background:var(--panel2);color:var(--text);border:1px solid var(--line);border-radius:6px;padding:9px}.chat-input button{border:0;background:var(--green);color:#fff;border-radius:6px}.below-grid{max-width:1160px;margin:18px auto 0;display:grid;grid-template-columns:repeat(3,1fr);gap:12px}.below-grid article{background:var(--panel);border:1px solid var(--line);border-radius:9px;padding:14px;display:grid;grid-template-columns:1fr auto;gap:12px;align-items:center}.card-title{display:flex;gap:9px;align-items:center}.card-title b,.card-title small{display:block}.card-title b{font-size:12px}.card-title small{font-size:9px;color:var(--muted)}.icon{width:34px;height:34px;border-radius:8px;display:grid;place-items:center}.icon.green{background:rgba(129,182,76,.18);color:#a7d47d}.icon.orange{background:rgba(214,165,65,.16);color:#e1b75d}.icon.blue{background:rgba(76,147,200,.17);color:#70b3e2}.below-grid article>button{grid-column:1/-1;border:1px solid var(--line);background:var(--panel2);color:var(--text);border-radius:6px;padding:7px;cursor:pointer;font-size:10px}.mini-board{direction:ltr;background:#272522;padding:5px 7px;border-radius:6px;line-height:1.2;color:#ddd}.stat{text-align:center}.stat b,.stat small{display:block}.stat b{font-size:19px}.stat small{font-size:8px;color:var(--muted)}.spark{height:38px;display:flex;align-items:end;gap:3px}.spark i{width:5px;background:var(--green);border-radius:3px}.spark i:nth-child(1){height:20%}.spark i:nth-child(2){height:45%}.spark i:nth-child(3){height:32%}.spark i:nth-child(4){height:68%}.spark i:nth-child(5){height:56%}.spark i:nth-child(6){height:82%}.spark i:nth-child(7){height:100%}.placeholder{min-height:calc(100vh - 100px);place-content:center;text-align:center}.placeholder.active-view{display:grid}.placeholder>span{font-size:72px;color:var(--green)}.placeholder p{color:var(--muted)}.toast{position:fixed;left:22px;bottom:22px;z-index:100;background:#111;color:#fff;padding:11px 15px;border-radius:7px;opacity:0;transform:translateY(12px);transition:.2s;pointer-events:none;box-shadow:var(--shadow);font-size:12px}.toast.show{opacity:1;transform:none}
@media(max-width:1120px){:root{--board-size:min(calc(100vh - 170px),calc(100vw - 510px),650px)}.app{grid-template-columns:75px 1fr}.rail{padding-inline:8px}.logo span:last-child,.nav b,.nav small,.rail-bottom span,.mini-user>div:last-child{display:none}.logo{justify-content:center;padding:0}.nav{grid-template-columns:1fr;padding:11px}.nav>span{grid-row:auto}.mini-user{justify-content:center}.game-shell{grid-template-columns:minmax(0,var(--board-size)) 350px}}
@media(max-width:880px){:root{--board-size:min(calc(100vw - 38px),680px)}.app{display:block}.rail{position:fixed;right:-225px;width:215px;transition:.22s}.rail.open{right:0}.rail-close{display:block;position:absolute;left:10px;top:8px;border:0;background:transparent;color:#aaa;font-size:25px}.logo span:last-child,.nav b,.nav small,.rail-bottom span,.mini-user>div:last-child{display:block}.nav{grid-template-columns:31px 1fr}.nav>span{grid-row:1/3}.mini-user{justify-content:flex-start}.hamburger{display:block;border:1px solid var(--line);background:var(--panel);color:var(--text);border-radius:7px;width:39px;height:39px}.topbar{height:62px}.online{display:none}main{padding-inline:10px}.game-shell{display:block}.board-column{width:var(--board-size);margin:auto}.game-panel{width:var(--board-size);margin:13px auto 0;min-height:540px}.move-list{height:240px}.below-grid{grid-template-columns:1fr;max-width:var(--board-size)}}
@media(max-width:520px){:root{--board-size:calc(100vw - 20px)}main{padding-inline:0}.topbar{padding:0 10px}.ghost{display:none}.board-stage{grid-template-columns:11px 1fr;gap:2px}.eval{border-radius:0}.board-frame{border-radius:0}.square{font-size:calc(var(--board-size)/10.2)}.player-strip{padding-inline:9px;height:53px}.avatar{width:36px;height:36px}.clock{min-width:88px;font-size:21px}.captured{display:none}.game-panel{border-radius:0;border-inline:0}.below-grid{padding:0 10px}.top-actions .primary{padding:8px 10px}.coords{font-size:8px}}
.iran-banner{margin:22px 0;display:flex;align-items:center;justify-content:space-between;gap:20px;padding:26px 30px;border-radius:20px;background:linear-gradient(120deg,#173d33,#2d6f55);color:#fff;box-shadow:0 15px 40px #0003}.iran-banner small{opacity:.8}.iran-banner h2{margin:5px 0 8px;font-size:26px}.iran-banner p{margin:0;opacity:.85}.iran-banner button{border:0;background:#fff;color:#173d33;padding:13px 18px;border-radius:12px;font-weight:900;white-space:nowrap}.community-view{padding:30px}.community-hero{max-width:800px;margin:10px auto 30px;text-align:center}.community-hero h1{font-size:40px;margin:8px 0}.community-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:18px;max-width:1150px;margin:auto}.community-grid article{background:var(--panel);border:1px solid var(--border);border-radius:18px;padding:24px}.community-grid article b{font-size:20px}.community-grid article p{color:var(--muted);min-height:52px}.community-grid button{background:var(--panel2);color:var(--text);border:1px solid var(--border);padding:10px 14px;border-radius:10px;font-weight:700}@media(max-width:850px){.community-grid{grid-template-columns:1fr}.iran-banner{align-items:flex-start;flex-direction:column}.community-hero h1{font-size:30px}}

.auth-shell,.legal-shell{min-height:100vh;display:grid;place-items:center;padding:24px;background:#171715;color:#eee}.auth-card,.legal-card{width:min(760px,100%);background:#262522;border:1px solid #3b3934;border-radius:18px;padding:28px;box-shadow:0 20px 60px #0008}.auth-card form{display:grid;gap:14px}.auth-card label{display:grid;gap:7px}.auth-card input{padding:13px;border-radius:10px;border:1px solid #555;background:#181816;color:#fff}.auth-tabs{display:flex;gap:8px;margin:18px 0}.auth-tabs button.active{background:#81b64c;color:#fff}.primary{display:inline-block;background:#81b64c;color:#fff;border:0;border-radius:10px;padding:12px 18px;text-decoration:none;font-weight:800}.check{display:flex!important;grid-template-columns:auto 1fr;align-items:center}.ok{color:#9be15d}.err{color:#ff8c8c}.legal-card h2{margin-top:28px}.legal-card p,.legal-card li{line-height:2;color:#d2d0c9}.account-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:12px;margin:20px 0}.account-grid div{background:#191917;padding:16px;border-radius:12px;display:grid;gap:8px}
/* Shahmat v0.6 visual identity */
.brand-logo{gap:11px}.brand-logo img{width:46px;height:46px;filter:drop-shadow(0 8px 18px #0006)}.brand-logo>span{display:grid;line-height:1.05}.brand-logo b{font-size:18px;letter-spacing:1.8px}.brand-logo small{font-size:8px;color:var(--muted);margin-top:5px}.top-brand{display:none;align-items:center;gap:9px}.top-brand img{width:36px;height:36px}.top-brand div{display:grid}.top-brand b{letter-spacing:1.2px;font-size:13px}.top-brand small{font-size:8px;color:var(--muted)}
.board-frame{box-shadow:0 22px 65px #0008,0 0 0 1px #ffffff12}.game-panel{box-shadow:0 20px 60px #0005}.player-strip{background:linear-gradient(90deg,transparent,#ffffff05,transparent)}.clock{font-variant-numeric:tabular-nums;box-shadow:inset 0 0 0 1px #ffffff0b}.clock.active{box-shadow:0 0 0 2px #81b64c55,0 8px 24px #81b64c20}.primary{background:linear-gradient(180deg,#8bc451,#6fa33e);box-shadow:0 7px 18px #4c7f273d}.primary:hover{transform:translateY(-1px);filter:brightness(1.06)}
.ai-view{padding:30px;max-width:1320px;margin:auto}.ai-hero{min-height:390px;border:1px solid #ffffff12;border-radius:28px;padding:54px;display:grid;grid-template-columns:1.3fr .7fr;align-items:center;overflow:hidden;position:relative;background:radial-gradient(circle at 82% 25%,#81b64c2c,transparent 31%),linear-gradient(135deg,#171a15,#292d25)}.ai-hero:after{content:"";position:absolute;inset:auto -120px -170px auto;width:520px;height:520px;border:1px solid #81b64c22;border-radius:50%}.eyebrow{color:#9bcf6a;font-weight:800;letter-spacing:1.5px;font-size:11px}.ai-hero h1{font-size:clamp(34px,5vw,67px);max-width:720px;line-height:1.18;margin:12px 0}.ai-hero p{max-width:700px;color:#b8c0b2;line-height:2;font-size:15px}.ai-actions{display:flex;gap:10px;margin-top:24px}.ghost-link{color:#eef5e9;text-decoration:none;border:1px solid #ffffff24;padding:12px 18px;border-radius:10px;font-weight:800}.ai-orb{width:260px;height:260px;margin:auto;position:relative;display:grid;place-items:center;border-radius:50%;background:radial-gradient(circle,#81b64c2c,transparent 65%)}.ai-orb img{width:126px;z-index:2;filter:drop-shadow(0 24px 35px #0009)}.ai-orb i{position:absolute;border:1px solid #9bd36a55;border-radius:50%;animation:orbit 8s linear infinite}.ai-orb i:nth-child(2){inset:20px}.ai-orb i:nth-child(3){inset:0;animation-duration:13s}.ai-orb i:nth-child(4){inset:-24px;animation-duration:18s}@keyframes orbit{to{transform:rotate(360deg)}}
.ai-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:14px;margin:18px 0}.ai-grid article,.bot-cards article{background:linear-gradient(145deg,var(--panel),var(--panel3));border:1px solid var(--line);border-radius:18px;padding:22px;box-shadow:0 12px 28px #0002}.ai-grid article>span{display:grid;place-items:center;width:42px;height:42px;border-radius:12px;background:#81b64c18;color:#a7da77;font-size:20px}.ai-grid h3{margin:16px 0 8px}.ai-grid p,.bot-cards p{color:var(--muted);line-height:1.85;font-size:11px}.ai-grid small{color:#83b558}.bot-roster{margin-top:35px}.section-head{display:flex;align-items:end;justify-content:space-between}.section-head h2{margin:7px 0;font-size:30px}.engine-badge{border:1px solid #81b64c55;color:#a4d77a;background:#81b64c12;padding:8px 11px;border-radius:999px;font-size:10px}.bot-cards{display:grid;grid-template-columns:repeat(4,1fr);gap:14px;margin-top:16px}.bot-cards article>div:nth-child(2){display:grid}.bot-cards small{color:var(--muted);font-size:9px}.bot-face{width:52px;height:52px;border-radius:15px;display:grid;place-items:center;font-size:21px;font-weight:900;margin-bottom:15px}.bot-face.mint{background:#63c8a020}.bot-face.amber{background:#f0b84b24}.bot-face.violet{background:#9c78ea25}.bot-face.red{background:#e65f5f25}
@media(max-width:920px){.top-brand{display:flex}.ai-hero{grid-template-columns:1fr;padding:30px}.ai-orb{display:none}.ai-grid,.bot-cards{grid-template-columns:1fr 1fr}}@media(max-width:560px){.ai-view{padding:10px}.ai-hero{border-radius:16px;padding:24px 18px}.ai-hero h1{font-size:34px}.ai-grid,.bot-cards{grid-template-columns:1fr}.section-head{align-items:flex-start;gap:12px;flex-direction:column}.ai-actions{flex-direction:column}}
.account-strip{min-height:46px;padding:8px 18px;display:flex;align-items:center;justify-content:space-between;gap:12px;background:#171714;border-bottom:1px solid rgba(255,255,255,.08);color:#ddd;position:relative;z-index:20}.account-strip nav{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.account-strip a,.account-strip button{color:#fff;background:#2b2a26;border:1px solid rgba(255,255,255,.1);border-radius:9px;padding:7px 11px;text-decoration:none;font:inherit;cursor:pointer}.auth-brand{display:flex;align-items:center;gap:14px;margin-bottom:18px}.auth-brand img{width:64px;height:64px}.auth-brand h1{margin:0}.auth-brand p{margin:4px 0 0;color:var(--muted,#8f8f88)}.link-button{border:0;background:transparent;color:#8ab4f8;cursor:pointer;margin-top:8px}
@media(max-width:700px){.account-strip{align-items:flex-start;flex-direction:column}.account-strip nav{width:100%}}

/* ===== Shahmat account redesign v0.9 ===== */
.account-page,.auth-page-v2{margin:0;background:#11120f;color:#f3f4ef;font-family:Vazirmatn,system-ui,-apple-system,"Segoe UI",sans-serif}.account-page *,.auth-page-v2 *{box-sizing:border-box}.account-topbar{height:70px;padding:0 clamp(18px,4vw,52px);display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid #ffffff12;background:#171914e8;backdrop-filter:blur(18px);position:sticky;top:0;z-index:50}.account-logo,.auth-logo-v2{display:flex;align-items:center;gap:10px;color:#fff;text-decoration:none;font-weight:900;font-size:20px}.account-logo img,.auth-logo-v2 img{width:38px;height:38px}.account-topbar nav{display:flex;align-items:center;gap:8px}.account-topbar nav a,.top-logout{border:0;background:transparent;color:#c9cdc2;text-decoration:none;padding:10px 12px;border-radius:10px;font:inherit;cursor:pointer}.account-topbar nav a:hover,.top-logout:hover{background:#ffffff0d;color:#fff}.top-logout{color:#ffaaa2}.account-shell-v2{width:min(1180px,calc(100% - 32px));margin:28px auto 64px}.profile-hero-v2{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:20px;padding:26px;border:1px solid #ffffff12;border-radius:24px;background:linear-gradient(135deg,#20251a,#191b17 65%,#24311a);box-shadow:0 22px 60px #0005;overflow:hidden;position:relative}.profile-hero-v2:after{content:"♞";position:absolute;left:22px;bottom:-52px;font-size:190px;color:#ffffff08;transform:rotate(-8deg)}.profile-avatar-v2{width:92px;height:92px;border-radius:22px;display:grid;place-items:center;background:linear-gradient(145deg,#9bc95a,#5f8d35);font-size:38px;font-weight:950;color:#13200d;box-shadow:inset 0 1px #fff8,0 12px 28px #0005}.profile-title-row{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.profile-title-row h1{margin:0;font-size:clamp(25px,3vw,36px)}.role-badge-v2{font-size:12px;padding:6px 10px;border-radius:999px;background:#8fc45222;color:#bce683;border:1px solid #8fc45240}.profile-handle-v2{direction:ltr;text-align:right;color:#91988a;margin-top:4px}.profile-meta-v2{display:flex;gap:14px;flex-wrap:wrap;margin-top:15px;color:#bcc1b5;font-size:13px}.status-online-v2{color:#9bd55f}.profile-actions-v2{display:flex;gap:10px;position:relative;z-index:2}.btn-primary-v2,.btn-ghost-v2{display:inline-flex;justify-content:center;align-items:center;min-height:44px;padding:0 17px;border-radius:12px;text-decoration:none;font-weight:850}.btn-primary-v2{background:#91c94f;color:#17200f;box-shadow:0 8px 22px #79b63c38}.btn-primary-v2:hover{background:#a4da63}.btn-ghost-v2{background:#ffffff09;color:#edf1e8;border:1px solid #ffffff14}.full-v2{width:100%}.rating-grid-v2{display:grid;grid-template-columns:repeat(4,1fr);gap:14px;margin:18px 0}.rating-grid-v2 article{padding:19px;border-radius:18px;background:#1b1d19;border:1px solid #ffffff0e;display:flex;align-items:center;gap:14px}.rating-grid-v2 article.featured-rating-v2{background:linear-gradient(135deg,#26351c,#1d2418);border-color:#87bc4938}.rating-icon-v2{width:45px;height:45px;display:grid;place-items:center;border-radius:13px;background:#ffffff0b;font-size:21px}.rating-grid-v2 span,.rating-grid-v2 small{display:block;color:#9ca294}.rating-grid-v2 strong{display:block;font-size:27px;line-height:1.15;margin:3px 0}.rating-grid-v2 small{font-size:11px}.account-layout-v2{display:grid;grid-template-columns:minmax(0,1fr) 330px;gap:18px}.account-content-v2,.account-side-v2{display:grid;gap:18px;align-content:start}.panel-v2{background:#1a1c18;border:1px solid #ffffff0f;border-radius:20px;padding:21px}.panel-v2 h2{margin:0;font-size:18px}.panel-head-v2{display:flex;align-items:center;justify-content:space-between;gap:16px;padding-bottom:16px;border-bottom:1px solid #ffffff0c}.panel-head-v2 p{margin:5px 0 0;color:#92988c;font-size:13px}.panel-head-v2>a{color:#a9d773;text-decoration:none;font-size:13px}.empty-state-v2{text-align:center;padding:38px 16px 24px}.empty-state-v2>div{font-size:43px;color:#9aca5d}.empty-state-v2 h3{margin:10px 0 5px}.empty-state-v2 p{color:#969d90;margin:0 0 18px}.recent-games-v2{display:grid}.game-row-v2{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:12px;padding:14px 2px;border-bottom:1px solid #ffffff0b}.game-row-v2:last-child{border-bottom:0}.game-row-v2 small{display:block;color:#8f9689;margin-top:4px}.result-dot-v2{width:10px;height:10px;border-radius:99px}.result-dot-v2.win{background:#8bc34a}.result-dot-v2.draw{background:#d0ae5c}.result-dot-v2.loss{background:#d66b62}.info-list-v2{display:grid}.info-list-v2>div{display:grid;grid-template-columns:145px minmax(0,1fr) auto;gap:12px;align-items:center;padding:15px 0;border-bottom:1px solid #ffffff0b}.info-list-v2>div:last-child{border-bottom:0}.info-list-v2 span{color:#92988c}.info-list-v2 strong{overflow:hidden;text-overflow:ellipsis}.info-list-v2 em{font-style:normal;font-size:11px;border-radius:999px;padding:5px 9px}.info-list-v2 em.verified{background:#81b64c20;color:#a9dc72}.info-list-v2 em.pending{background:#d5a74d1d;color:#e7c06c}.info-list-v2 em.neutral{background:#ffffff0b;color:#aeb4aa}.membership-card-v2{padding:23px;border-radius:20px;background:linear-gradient(150deg,#91c94f,#5b8e32);color:#14200c;box-shadow:0 18px 40px #4c752934}.membership-top-v2{display:flex;justify-content:space-between;align-items:center}.membership-top-v2 span{font-size:13px}.membership-top-v2 b{font-size:22px}.membership-card-v2 p{line-height:1.8;margin:18px 0 12px}.membership-card-v2 small{display:block}.membership-card-v2 a{margin-top:18px;display:flex;justify-content:center;padding:12px;border-radius:11px;background:#17210f;color:#fff;text-decoration:none;font-weight:850}.security-card-v2 h2,.mini-stats-v2 h2{margin-bottom:18px}.security-item-v2{display:grid;grid-template-columns:auto 1fr auto;gap:11px;align-items:center;margin-bottom:17px}.security-icon-v2{width:42px;height:42px;border-radius:12px;background:#ffffff0a;display:grid;place-items:center}.security-item-v2 small{display:block;color:#8f9689;margin-top:4px}.security-state-v2{font-size:11px;border-radius:999px;padding:5px 8px}.security-state-v2.on{background:#81b64c20;color:#a9dc72}.security-state-v2.off{background:#d66b621d;color:#f0958d}.mini-stats-v2>div{display:flex;justify-content:space-between;padding:12px 0;border-bottom:1px solid #ffffff0b}.mini-stats-v2>div:last-child{border-bottom:0}.mini-stats-v2 span{color:#959b8e}.auth-layout-v2{min-height:100vh;display:grid;grid-template-columns:minmax(420px,1.1fr) minmax(420px,.9fr);background:#12130f}.auth-showcase-v2{padding:42px clamp(32px,6vw,86px);display:flex;flex-direction:column;justify-content:space-between;position:relative;overflow:hidden;background:radial-gradient(circle at 20% 20%,#526c2b55,transparent 35%),linear-gradient(150deg,#20271a,#12140f)}.auth-showcase-v2:after{content:"";position:absolute;inset:auto -90px -140px auto;width:420px;height:420px;border-radius:50%;border:80px solid #ffffff05}.auth-copy-v2{max-width:660px;position:relative;z-index:2}.eyebrow-v2{display:inline-block;color:#a9d96d;margin-bottom:14px;font-weight:800}.auth-copy-v2 h1{font-size:clamp(38px,5vw,68px);line-height:1.22;margin:0 0 20px;letter-spacing:-1.6px}.auth-copy-v2>p{font-size:17px;line-height:2;color:#b9c0b1;max-width:590px}.auth-benefits-v2{display:grid;gap:13px;margin-top:32px}.auth-benefits-v2>div{display:flex;align-items:center;gap:13px}.auth-benefits-v2 b{width:43px;height:43px;border-radius:13px;display:grid;place-items:center;background:#ffffff0b}.auth-benefits-v2 strong,.auth-benefits-v2 small{display:block}.auth-benefits-v2 small{color:#92998b;margin-top:3px}.auth-board-art-v2{direction:ltr;display:flex;gap:15px;font-size:44px;color:#ffffff22;position:relative;z-index:2}.auth-form-side-v2{display:grid;place-items:center;padding:28px;background:#171814}.auth-card-v2{width:min(470px,100%);padding:34px;border:1px solid #ffffff10;border-radius:24px;background:#1d1f1a;box-shadow:0 24px 70px #0006}.auth-back-v2{color:#a7ada1;text-decoration:none;font-size:13px}.auth-card-title-v2{margin:25px 0 18px}.auth-card-title-v2 h2{font-size:29px;margin:0}.auth-card-title-v2 p{color:#92998d;line-height:1.8;margin:7px 0 0}.auth-tabs-v2{display:grid;grid-template-columns:1fr 1fr;background:#131410;border-radius:12px;padding:4px;margin-bottom:20px}.auth-tabs-v2 button{border:0;background:transparent;color:#93998e;border-radius:9px;padding:11px;font:inherit;font-weight:800;cursor:pointer}.auth-tabs-v2 button.active{background:#2a2e24;color:#fff;box-shadow:0 5px 14px #0005}.auth-form-v2{display:grid;gap:14px}.auth-form-v2 label{display:grid;gap:7px}.auth-form-v2 label>span{font-size:13px;color:#c8cdc2}.auth-form-v2 input:not([type=checkbox]){width:100%;height:48px;border-radius:11px;border:1px solid #ffffff16;background:#12130f;color:#fff;padding:0 14px;font:inherit;outline:none}.auth-form-v2 input:focus{border-color:#8fc653;box-shadow:0 0 0 3px #8fc65318}.auth-submit-v2{height:49px;border:0;border-radius:11px;background:#91c94f;color:#16200f;font:inherit;font-weight:900;cursor:pointer}.auth-submit-v2:hover{background:#a3da61}.auth-link-v2{border:0;background:transparent;color:#a9d673;font:inherit;cursor:pointer}.auth-check-v2{display:flex!important;align-items:flex-start;grid-template-columns:auto 1fr!important;gap:9px!important;line-height:1.7}.auth-check-v2 input{margin-top:4px}.auth-msg-v2{min-height:24px;text-align:center}.auth-legal-v2{text-align:center;color:#666d62;margin:22px 0 0}.auth-legal-v2 a{color:#92998d;text-decoration:none}.auth-legal-v2 span{margin:0 6px}
@media(max-width:960px){.account-layout-v2{grid-template-columns:1fr}.account-side-v2{grid-template-columns:repeat(2,minmax(0,1fr))}.mini-stats-v2{grid-column:1/-1}.auth-layout-v2{grid-template-columns:1fr}.auth-showcase-v2{min-height:430px}.auth-board-art-v2{display:none}}
@media(max-width:700px){.account-topbar{height:auto;min-height:64px;padding:10px 16px}.account-topbar nav a{display:none}.profile-hero-v2{grid-template-columns:auto 1fr;padding:19px}.profile-avatar-v2{width:70px;height:70px;border-radius:18px}.profile-actions-v2{grid-column:1/-1;width:100%}.profile-actions-v2 a{flex:1}.rating-grid-v2{grid-template-columns:repeat(2,1fr)}.account-side-v2{grid-template-columns:1fr}.info-list-v2>div{grid-template-columns:1fr auto}.info-list-v2 strong{grid-column:1/-1;grid-row:2}.auth-showcase-v2{padding:30px 24px;min-height:360px}.auth-copy-v2 h1{font-size:38px}.auth-copy-v2>p,.auth-benefits-v2{display:none}.auth-form-side-v2{padding:16px}.auth-card-v2{padding:25px 20px;border-radius:18px}}

/* v1.2: balanced login actions */
.auth-form-tools-v2{display:flex;justify-content:flex-start;align-items:center;margin-top:-4px;margin-bottom:2px;min-height:22px}
.auth-forgot-link-v2{color:#a9d673;text-decoration:none;font-size:13px;font-weight:750;line-height:1.5;padding:2px 0;transition:color .18s ease,transform .18s ease}
.auth-forgot-link-v2:hover{color:#c2eb91;transform:translateY(-1px)}
.auth-form-v2 .auth-submit-v2{margin-top:2px}
@media(max-width:700px){.auth-form-tools-v2{margin-top:-2px}.auth-card-title-v2{margin:20px 0 16px}.auth-tabs-v2{margin-bottom:17px}}
.reset-login-link{display:flex;align-items:center;justify-content:center;text-decoration:none;margin-top:18px}
.auth-msg-v2:empty{display:none}
.auth-submit-v2:disabled{opacity:.68;cursor:not-allowed;transform:none!important}

/* v1.5: hidden auth tabs must stay hidden */
.auth-form-v2[hidden]{display:none!important}

/* v1.8 password checker */
.auth-register-classic .password-checker{margin-top:-2px;padding:13px 14px;border:1px solid rgba(255,255,255,.09);border-radius:14px;background:rgba(255,255,255,.035)}
.password-strength-head{display:flex;align-items:center;justify-content:space-between;font-size:12px;color:var(--muted,#aeb6c7);margin-bottom:9px}
.password-strength-head strong{font-size:12px;color:#dce3ef}
.password-strength-bar{height:6px;border-radius:999px;background:rgba(255,255,255,.08);overflow:hidden;margin-bottom:11px}
.password-strength-bar i{display:block;width:0;height:100%;border-radius:inherit;transition:width .22s ease,background .22s ease;background:#687286}
.password-strength-bar i.weak{background:#ef6461}.password-strength-bar i.fair{background:#f0ad4e}.password-strength-bar i.good{background:#6ca8ff}.password-strength-bar i.strong{background:#58c78b}
.password-factors{display:flex;flex-wrap:wrap;gap:7px}
.password-factors span{font-size:11px;color:#9199aa;padding:5px 8px;border-radius:999px;background:rgba(255,255,255,.045);transition:.2s}
.password-factors span::before{content:'○';margin-left:5px}.password-factors span.passed{color:#8de0ae;background:rgba(88,199,139,.1)}.password-factors span.passed::before{content:'✓'}
@media(max-width:560px){.password-factors{gap:5px}.password-factors span{font-size:10px}}


/* v1.9 desktop auth refinements */
@media (min-width: 900px){
  .auth-check-v2 a,
  .auth-legal-v2 a{
    color:#b7cf8c !important;
    text-decoration:none;
    border-bottom:1px solid rgba(183,207,140,.32);
    transition:color .18s ease,border-color .18s ease,background .18s ease;
  }
  .auth-check-v2 a:hover,
  .auth-legal-v2 a:hover{
    color:#d9ebb7 !important;
    border-bottom-color:#d9ebb7;
    background:rgba(183,207,140,.06);
  }
  .password-factors{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:7px}
  .password-factors span{text-align:center;white-space:nowrap}
}

/* v2.0 desktop password factor fit + site text selection protection */
html,body,body *{
  -webkit-user-select:none;
  user-select:none;
  -webkit-touch-callout:none;
}
input,textarea,select,[contenteditable="true"]{
  -webkit-user-select:text;
  user-select:text;
  -webkit-touch-callout:default;
}
@media (min-width: 901px){
  .password-factors{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:8px;
  }
  .password-factors span{
    min-width:0;
    width:100%;
    text-align:center;
    white-space:normal;
    line-height:1.5;
    overflow-wrap:anywhere;
    padding:7px 8px;
  }
}

/* v2.1 — stable desktop/laptop layout repair */
.account-strip{
  min-height:44px;
  padding:7px clamp(14px,2vw,26px);
  position:relative;
  z-index:50;
  flex-wrap:nowrap;
  overflow:hidden;
}
.account-strip>span{min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.account-strip nav{flex-wrap:nowrap;flex-shrink:0}
.account-strip a,.account-strip button{white-space:nowrap;padding:6px 10px;font-size:12px}
.app{min-height:calc(100vh - 44px)}
.rail{height:calc(100vh - 44px);top:0;overflow-y:auto;overflow-x:hidden}
.topbar{min-width:0;gap:14px}
.top-brand{min-width:0}
.top-brand img{width:34px;height:34px;flex:0 0 auto}
.top-brand>div{min-width:0}
.top-brand b,.top-brand small{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.game-shell{width:100%;min-width:0}
.board-column,.game-panel,.board-stage,.board-frame,.chessboard{min-width:0}
.game-panel{overflow:hidden}
.panel-head,.tabs,.tab-page,.new-game-box{min-width:0}
.tabs{grid-template-columns:repeat(3,minmax(0,1fr))}
.tabs button{min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.iran-banner,.below-grid{max-width:1160px;margin-inline:auto}

/* Laptop and ordinary desktop widths */
@media (min-width:881px) and (max-width:1399px){
  :root{--board-size:min(calc(100vh - 216px),calc(100vw - 486px),620px)}
  .app{grid-template-columns:82px minmax(0,1fr)}
  .rail{padding:14px 8px}
  .rail .brand-logo{justify-content:center;padding:0;height:52px}
  .rail .brand-logo img{width:46px;height:46px}
  .rail .brand-logo span:last-child,
  .rail .nav b,
  .rail .nav small,
  .rail-bottom button span,
  .mini-user>div:last-child{display:none!important}
  .rail nav{gap:7px;margin-top:10px}
  .rail .nav{display:grid;grid-template-columns:1fr;place-items:center;padding:11px 6px;min-height:48px;text-align:center}
  .rail .nav>span{grid-row:auto;font-size:23px}
  .rail .nav.active{box-shadow:inset -3px 0 var(--green)}
  .rail-bottom>button{text-align:center;padding:10px 4px}
  .mini-user{justify-content:center;padding:10px 0}
  main{padding:0 16px 28px}
  .topbar{height:64px;max-width:1050px}
  .top-brand{display:flex;align-items:center;gap:8px;max-width:210px}
  .top-brand small{font-size:10px;color:var(--muted)}
  .online{margin-inline:auto}
  .top-actions{flex-shrink:0}
  .top-actions .ghost{display:none}
  .game-shell{grid-template-columns:minmax(0,var(--board-size)) minmax(300px,340px);gap:14px;max-width:1000px}
  .game-panel{width:auto;min-height:calc(var(--board-size) + 116px)}
  .player-strip{height:54px;gap:8px}
  .clock{min-width:92px;font-size:22px;padding:6px 8px}
  .captured{min-width:42px;max-width:70px;overflow:hidden}
  .panel-head{padding:14px 15px}
  .tabs button{padding-inline:6px;font-size:12px}
  .tab-page{padding-inline:14px}
  .new-game-box{padding:13px 14px}
  .time-presets{grid-template-columns:repeat(4,minmax(0,1fr))}
  .time-presets button{min-width:0;padding-inline:4px}
  .iran-banner,.below-grid{max-width:1000px}
}

/* Narrow laptop widths: panel moves below board before anything overlaps */
@media (min-width:881px) and (max-width:1060px){
  :root{--board-size:min(calc(100vh - 210px),calc(100vw - 130px),650px)}
  .app{grid-template-columns:72px minmax(0,1fr)}
  main{padding-inline:12px}
  .topbar{max-width:var(--board-size)}
  .online{display:none}
  .top-brand{max-width:180px}
  .game-shell{display:block;max-width:var(--board-size)}
  .board-column{width:var(--board-size);margin-inline:auto}
  .game-panel{width:var(--board-size);min-height:500px;margin:14px auto 0}
  .move-list{height:220px}
  .iran-banner,.below-grid{max-width:var(--board-size)}
}

/* Wide desktop */
@media (min-width:1400px){
  :root{--board-size:min(calc(100vh - 216px),calc(100vw - 650px),700px)}
  .game-shell{grid-template-columns:minmax(0,var(--board-size)) 380px;max-width:1120px}
  .topbar,.iran-banner,.below-grid{max-width:1120px}
}

/* v2.2 optional-account / guest mode */
.account-strip .account-join{background:var(--green,#81b64c);color:#111!important;padding:7px 12px;border-radius:8px;font-weight:800;text-decoration:none}
.guest-login-link{display:inline-flex;align-items:center;justify-content:center;text-decoration:none}
.guest-user{text-decoration:none;color:inherit}
.guest-benefits{display:flex;align-items:center;justify-content:space-between;gap:22px;margin:18px 0;padding:18px 22px;border:1px solid rgba(129,182,76,.28);background:linear-gradient(135deg,rgba(129,182,76,.12),rgba(255,255,255,.025));border-radius:16px}
.guest-benefits div{display:flex;flex-direction:column;gap:5px}.guest-benefits b{font-size:16px}.guest-benefits span{color:var(--muted,#aaa);font-size:13px}.guest-benefits a{flex:0 0 auto;background:var(--green,#81b64c);color:#111;padding:11px 16px;border-radius:10px;font-weight:900;text-decoration:none}
.guest-mode .status-badge{background:rgba(255,193,7,.14);color:#f0c15b;border-color:rgba(255,193,7,.25)}
@media(max-width:900px){.guest-benefits{align-items:flex-start;flex-direction:column}.guest-benefits a{width:100%;text-align:center}.account-strip>span{display:none}}

/* v2.3 — redesigned desktop play workspace */
:root{
  --bg:#141714;
  --bg2:#0f120f;
  --panel:#202420;
  --panel2:#292e29;
  --panel3:#181c18;
  --text:#f4f6f1;
  --muted:#9da69b;
  --line:rgba(255,255,255,.085);
  --green:#95c85b;
  --green2:#78ae3f;
  --shadow:0 24px 70px rgba(0,0,0,.34);
  --board-size:min(calc(100vh - 208px),calc(100vw - 650px),620px);
}
html{background:#0f120f}
body{
  background:
    radial-gradient(circle at 72% -10%,rgba(149,200,91,.12),transparent 30%),
    radial-gradient(circle at 22% 110%,rgba(96,123,77,.08),transparent 35%),
    linear-gradient(135deg,#171a17 0%,#111411 100%);
  color:var(--text);
  -webkit-font-smoothing:antialiased;
  text-rendering:optimizeLegibility;
}
body::before{
  content:"";position:fixed;inset:0;pointer-events:none;opacity:.22;
  background-image:linear-gradient(rgba(255,255,255,.018) 1px,transparent 1px),linear-gradient(90deg,rgba(255,255,255,.018) 1px,transparent 1px);
  background-size:48px 48px;
  mask-image:linear-gradient(to bottom,black,transparent 70%);
}
.account-strip{display:none!important}
.app{grid-template-columns:104px minmax(0,1fr);min-height:100vh;position:relative}
.rail{
  height:100vh;top:0;padding:15px 10px 12px;background:linear-gradient(180deg,rgba(25,29,25,.98),rgba(13,16,13,.98));
  border-left:1px solid rgba(255,255,255,.07);box-shadow:-16px 0 40px rgba(0,0,0,.18);overflow:visible;
}
.brand-logo{height:70px;display:flex;flex-direction:column;justify-content:center;gap:5px;padding:0;border-radius:17px;background:linear-gradient(145deg,rgba(149,200,91,.12),rgba(255,255,255,.025));border:1px solid rgba(149,200,91,.15)}
.brand-mark{width:42px;height:42px;border-radius:13px;display:grid;place-items:center;background:#111511;box-shadow:inset 0 0 0 1px rgba(255,255,255,.04),0 8px 20px rgba(0,0,0,.22)}
.brand-mark img{width:33px;height:33px}
.brand-copy{display:none}
.rail nav{gap:8px;margin-top:15px}
.rail .nav{
  min-height:58px;padding:7px 5px;border-radius:15px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;text-align:center;position:relative;overflow:hidden;
  color:#a8afa5;border:1px solid transparent;transition:.2s ease;
}
.rail .nav>span{font-size:24px;line-height:1;grid-row:auto}
.rail .nav b{display:block!important;font-size:11px;line-height:1.3;font-weight:750}
.rail .nav small{display:none!important}
.rail .nav:hover{background:rgba(255,255,255,.045);color:#fff;transform:translateY(-1px)}
.rail .nav.active{background:linear-gradient(145deg,rgba(149,200,91,.2),rgba(149,200,91,.08));color:#fff;border-color:rgba(149,200,91,.24);box-shadow:none}
.rail .nav.active::after{content:"";position:absolute;right:0;top:15px;bottom:15px;width:3px;border-radius:4px;background:var(--green);box-shadow:0 0 12px rgba(149,200,91,.7)}
.rail-bottom{gap:6px}
.rail-bottom>button{height:39px;padding:0;border-radius:12px;text-align:center;background:rgba(255,255,255,.025);border:1px solid rgba(255,255,255,.04)}
.rail-bottom>button span{display:none!important}
.mini-user{justify-content:center;border-top:0;margin-top:2px;padding:6px 0}
.mini-user>div:last-child{display:none!important}
.mini-user .avatar{width:38px;height:38px;border-radius:12px;box-shadow:0 7px 18px rgba(0,0,0,.25)}
main{padding:0 28px 36px;min-width:0;position:relative}
.topbar{
  height:78px;max-width:1110px;margin:0 auto;display:flex;align-items:center;gap:18px;border-bottom:1px solid rgba(255,255,255,.055);
}
.topbar-main{display:flex;align-items:center;gap:22px;min-width:0}
.top-brand{display:flex;align-items:center;gap:10px;min-width:0}
.top-brand img{width:38px;height:38px;filter:drop-shadow(0 8px 15px rgba(0,0,0,.25))}
.top-brand b{font-size:17px;letter-spacing:-.2px}
.top-brand small{font-size:10px;color:var(--muted);margin-top:2px}
.online{padding:7px 10px;border-radius:999px;background:rgba(255,255,255,.035);border:1px solid rgba(255,255,255,.06)}
.top-actions{margin-right:auto;display:flex;align-items:center;gap:8px;flex-shrink:0}
.icon-action,.logout-icon{
  width:38px;height:38px;border-radius:12px;border:1px solid rgba(255,255,255,.075);background:rgba(255,255,255,.035);color:#c9cfc6;display:grid;place-items:center;cursor:pointer;font-size:22px;transition:.18s ease;
}
.icon-action:hover,.logout-icon:hover{background:rgba(255,255,255,.075);color:#fff;transform:translateY(-1px)}
.new-game-cta{height:40px;padding:0 16px;border-radius:12px;display:flex;align-items:center;gap:7px;background:linear-gradient(180deg,#9fd363,#80b84a);color:#14200f;box-shadow:0 7px 22px rgba(120,174,63,.22),inset 0 1px rgba(255,255,255,.25);font-weight:900}
.new-game-cta span{font-size:20px;line-height:1}
.top-login,.top-register{height:40px;padding:0 15px;border-radius:12px;display:flex;align-items:center;text-decoration:none;font-size:12px;font-weight:800}
.top-login{color:#e7ebe4;border:1px solid rgba(255,255,255,.085);background:rgba(255,255,255,.035)}
.top-register{color:#182014;background:#eef4e8}
.user-chip{height:46px;display:flex;align-items:center;gap:9px;padding:5px 7px 5px 11px;border-radius:14px;text-decoration:none;color:var(--text);background:rgba(255,255,255,.04);border:1px solid rgba(255,255,255,.075)}
.user-chip-avatar{width:34px;height:34px;border-radius:10px;display:grid;place-items:center;font-weight:900;background:linear-gradient(145deg,#9fd363,#6c9b39);color:white}
.user-chip b,.user-chip small{display:block;white-space:nowrap}.user-chip b{font-size:12px}.user-chip small{font-size:9px;color:var(--muted);margin-top:1px}
.game-shell{grid-template-columns:minmax(0,var(--board-size)) minmax(360px,410px);gap:22px;max-width:1110px;margin:18px auto 0;align-items:start}
.board-column{width:var(--board-size)}
.player-strip{
  height:52px;padding:5px 8px 5px 10px;margin:0 0 8px;border-radius:14px;background:linear-gradient(145deg,rgba(255,255,255,.045),rgba(255,255,255,.022));border:1px solid rgba(255,255,255,.065);box-shadow:0 10px 24px rgba(0,0,0,.12)
}
.player-strip.me{margin:8px 0 0}
.player-main .avatar{width:38px;height:38px;border-radius:11px}
.name-line b{font-size:13px}.name-line span{border:1px solid rgba(255,255,255,.08)}
.player-main small{font-size:9px}.clock{min-width:98px;border-radius:11px;padding:6px 10px;font-size:23px;background:#101310;color:#aab1a7;box-shadow:inset 0 0 0 1px rgba(255,255,255,.04),0 7px 16px rgba(0,0,0,.2)}
.clock.active{background:linear-gradient(180deg,#f5f7f2,#dfe5da);color:#172015;box-shadow:0 8px 24px rgba(0,0,0,.25)}
.board-stage{grid-template-columns:12px minmax(0,1fr);gap:6px}
.eval{border-radius:999px;background:#090b09;border:1px solid rgba(255,255,255,.06)}
.eval>div{background:linear-gradient(180deg,#f4f5f1,#d8ddd4)}
.eval span{display:none}
.board-frame{border-radius:16px;border:1px solid rgba(255,255,255,.12);box-shadow:0 28px 70px rgba(0,0,0,.4),0 0 0 6px rgba(255,255,255,.018);overflow:hidden}
.square{font-size:clamp(31px,calc(var(--board-size)/9.85),68px);transition:filter .12s ease,transform .12s ease}
.square:hover{filter:brightness(1.07);z-index:2}
.game-panel{
  height:calc(var(--board-size) + 120px);min-height:0;border-radius:20px;background:linear-gradient(180deg,rgba(35,40,35,.97),rgba(25,29,25,.99));border:1px solid rgba(255,255,255,.08);box-shadow:0 28px 70px rgba(0,0,0,.28);overflow:hidden
}
.panel-head{height:76px;padding:13px 16px;gap:10px;background:linear-gradient(180deg,rgba(255,255,255,.035),transparent);border-bottom:0}
.panel-title{min-width:0}.panel-kicker{display:block;font-size:9px;color:#9fd363;margin-bottom:2px;font-weight:800;letter-spacing:.2px}.panel-title b{font-size:16px}.panel-title small{font-size:10px}
.panel-status{display:flex;align-items:center;gap:5px;margin-right:auto;color:#9ba399;font-size:9px;padding:6px 8px;border-radius:999px;background:rgba(255,255,255,.035)}
.panel-status i{width:6px;height:6px;border-radius:50%;background:#95c85b;box-shadow:0 0 0 4px rgba(149,200,91,.1)}
.dots{width:34px;height:34px;border-radius:10px;background:rgba(255,255,255,.035);font-size:14px}
.tabs{margin:0 14px 10px;padding:4px;border:0;border-radius:12px;background:#171b17;gap:4px}
.tab{height:36px;border-radius:9px;font-size:11px;transition:.18s ease}
.tab.active{color:#fff;background:#2d332d;box-shadow:inset 0 0 0 1px rgba(255,255,255,.06),0 6px 14px rgba(0,0,0,.16)}
.turn-card{margin:0 14px 10px;padding:11px 12px;border-radius:13px;background:linear-gradient(135deg,rgba(149,200,91,.14),rgba(255,255,255,.025));border-color:rgba(149,200,91,.2)}
.move-head{padding-inline:16px}.move-list{height:clamp(140px,calc(var(--board-size) - 345px),320px);border-block-color:rgba(255,255,255,.06)}
.move-row:nth-child(even){background:rgba(255,255,255,.018)}
.move-cell:hover{background:rgba(149,200,91,.13)}
.move-controls{margin:0 14px;border:0;border-radius:10px;overflow:hidden;background:#171b17;grid-template-columns:repeat(4,1fr);gap:1px}
.move-controls button{height:34px;background:rgba(255,255,255,.018)}
.game-actions{padding:10px 14px;gap:8px}.game-actions button{border-radius:10px;background:rgba(255,255,255,.035);border-color:rgba(255,255,255,.07);padding:8px 4px}
.new-game-box{padding:13px 14px 14px;background:#151915;border-top-color:rgba(255,255,255,.06)}
.setup-title{display:flex;align-items:center;justify-content:space-between;margin-bottom:10px}.setup-title b,.setup-title small{display:block}.setup-title b{font-size:12px}.setup-title small{font-size:9px;color:var(--muted);margin-top:2px}.setup-title>span{width:30px;height:30px;border-radius:9px;display:grid;place-items:center;background:rgba(149,200,91,.12);color:#a9da74}
.time-presets{gap:7px}.time-presets button{padding:7px 4px;border-radius:10px;background:#202520;border-color:rgba(255,255,255,.07)}.time-presets button.selected{background:rgba(149,200,91,.13);border-color:rgba(149,200,91,.65);box-shadow:none}.time-presets small{font-size:8px;margin-top:1px}
.setup-row{gap:8px;margin:8px 0}.setup-row select{height:38px;border-radius:10px;background:#202520;border-color:rgba(255,255,255,.07);padding:0 10px}
.new-game-box .full{height:40px;border-radius:11px;color:#172013;font-weight:900}
.guest-benefits,.iran-banner,.below-grid{max-width:1110px;margin-inline:auto}
.guest-benefits{margin-top:20px;border-radius:18px;background:linear-gradient(135deg,rgba(149,200,91,.1),rgba(255,255,255,.02));border-color:rgba(149,200,91,.18)}
.iran-banner{margin-top:20px;background:linear-gradient(120deg,#1b3329,#2e624a);box-shadow:0 24px 60px rgba(0,0,0,.22)}
.below-grid article{border-radius:18px;background:linear-gradient(145deg,rgba(255,255,255,.045),rgba(255,255,255,.02));border:1px solid rgba(255,255,255,.065);box-shadow:0 12px 30px rgba(0,0,0,.12)}

@media (min-width:1000px) and (max-width:1280px){
  :root{--board-size:min(calc(100vh - 205px),calc(100vw - 535px),570px)}
  .app{grid-template-columns:88px minmax(0,1fr)}
  .rail{padding-inline:8px}.rail .nav{min-height:54px}.rail .nav b{font-size:10px}
  main{padding-inline:18px}.topbar{height:72px}.top-brand small{display:none}.online{display:none}
  .game-shell{grid-template-columns:minmax(0,var(--board-size)) minmax(320px,360px);gap:16px;margin-top:14px}
  .game-panel{height:calc(var(--board-size) + 120px)}
  .top-register{display:none}
}
@media (min-width:1281px) and (max-height:820px){
  :root{--board-size:min(calc(100vh - 202px),calc(100vw - 650px),600px)}
}
@media (min-width:1600px){
  .app{grid-template-columns:112px minmax(0,1fr)}
  .game-shell,.topbar,.guest-benefits,.iran-banner,.below-grid{max-width:1160px}
  .game-shell{grid-template-columns:minmax(0,var(--board-size)) 420px}
}
@media (max-width:999px){
  .app{display:block}
  .rail{position:fixed;right:-245px;width:230px;height:100vh;transition:.22s;z-index:100}
  .rail.open{right:0}.rail-close{display:block}
  .brand-copy,.rail .nav small,.mini-user>div:last-child{display:block!important}
  .brand-logo{flex-direction:row;justify-content:flex-start;padding:0 10px}.rail .nav{flex-direction:row;justify-content:flex-start;padding:10px 12px}.rail .nav b{font-size:13px}
  main{padding-inline:12px}.topbar{height:66px}.hamburger{display:grid;place-items:center}.topbar-main .online,.top-brand small,.icon-action,.top-register{display:none}
  .game-shell{display:block;margin-top:10px}.board-column,.game-panel{width:var(--board-size);margin-inline:auto}.game-panel{height:auto;min-height:540px;margin-top:14px}
}
/* v2.3.1 viewport fit correction for short desktop screens */
@media (min-width:1281px) and (max-height:820px){
  :root{--board-size:min(calc(100vh - 228px),calc(100vw - 650px),580px)}
}

/* v2.4 — sidebar brand containment + sharper desktop game typography */
@media (min-width:1000px){
  .rail{overflow:hidden}
  .rail .brand-logo{
    width:100%;
    min-width:0;
    height:88px;
    padding:9px 5px 8px;
    display:grid;
    grid-template-rows:46px 16px;
    align-content:center;
    justify-items:center;
    gap:6px;
    overflow:hidden;
  }
  .rail .brand-mark{
    width:46px;
    height:46px;
    border-radius:14px;
    flex:0 0 auto;
  }
  .rail .brand-mark img{width:34px;height:34px}
  .rail .brand-copy{
    display:block!important;
    width:100%;
    min-width:0;
    max-width:100%;
    overflow:hidden;
    text-align:center;
    line-height:1;
  }
  .rail .brand-copy b{
    display:block;
    width:100%;
    max-width:100%;
    margin:0;
    color:#f7f8f5;
    font-family:Arial,"Segoe UI",sans-serif;
    font-size:11px;
    font-weight:900;
    line-height:1;
    letter-spacing:1.25px;
    white-space:nowrap;
    overflow:hidden;
    text-overflow:clip;
  }
}

.game-panel,
.game-panel button,
.game-panel select,
.game-panel input{
  font-family:"Segoe UI",Tahoma,Arial,sans-serif;
  text-rendering:geometricPrecision;
}
.game-panel{color:#f7f9f5}
.panel-kicker{font-size:10.5px!important;font-weight:800!important;color:#b7e286!important}
.panel-title b{font-size:18px!important;font-weight:900!important;line-height:1.35;color:#fff}
.panel-title small{font-size:12px!important;font-weight:600;color:#bac2b8!important;line-height:1.55}
.panel-status{font-size:10.5px!important;font-weight:700;color:#d0d6ce!important}
.tabs .tab{font-size:13.5px!important;font-weight:800;color:#b8c0b6!important;letter-spacing:-.1px}
.tabs .tab.active{color:#fff!important}
.turn-card b{font-size:14.5px!important;font-weight:900;color:#fff;line-height:1.45}
.turn-card small{font-size:12px!important;font-weight:600;color:#bdc5bb!important;line-height:1.5}
.move-head{font-size:11.5px!important;font-weight:800;color:#c3cac1!important}
.move-row{font-size:14px!important;font-weight:700;color:#f4f6f2}
.move-row>span{font-size:12px;color:#aeb6ac!important}
.move-cell{padding-block:8px;font-weight:750;color:#f5f7f3}
.empty-state{color:#b9c1b7!important}
.empty-state span{opacity:.55!important}
.empty-state p{font-size:14px!important;font-weight:850;color:#eef1eb;margin-top:8px!important}
.empty-state small{font-size:11.5px!important;font-weight:600;color:#abb4a9}
.move-controls button{font-size:15px!important;color:#c7cec5!important}
.game-actions button{font-size:12.5px!important;font-weight:800!important;color:#edf1ea!important;min-height:38px}
.setup-title b{font-size:14px!important;font-weight:900;color:#fff}
.setup-title small{font-size:11px!important;font-weight:600;color:#adb6aa!important;line-height:1.5}
.time-presets button{font-size:12.5px!important;font-weight:850;color:#edf1e9!important;line-height:1.35}
.time-presets small{font-size:9.5px!important;font-weight:650;color:#aab3a8!important}
.setup-row select{font-size:12.5px!important;font-weight:700;color:#f1f4ee!important}
.new-game-box .full{font-size:13.5px!important;font-weight:900}
.coach-hero b{font-size:15px;font-weight:900;color:#fff}
.coach-hero small{font-size:11.5px!important;color:#b4bdb1!important}
.coach-message{font-size:13px!important;font-weight:600;color:#e9ede6;line-height:2.05}
.analysis-grid small{font-size:10.5px!important;color:#b1baae!important}
.analysis-grid b{font-size:15px;font-weight:900;color:#fff}
.coach-tips{font-size:12px!important;color:#bdc5ba!important}
.system-msg{font-size:11.5px!important;color:#c1c8bf!important}
.chat-input input{font-size:12.5px}
.chat-input button{font-size:12.5px;font-weight:850;padding-inline:13px}

@media (min-width:1000px) and (max-width:1280px){
  .rail .brand-logo{height:78px;grid-template-rows:42px 14px;gap:5px}
  .rail .brand-mark{width:42px;height:42px}
  .rail .brand-copy b{font-size:9.5px;letter-spacing:.9px}
  .panel-title b{font-size:16.5px!important}
  .panel-title small{font-size:11px!important}
  .tabs .tab{font-size:12.5px!important}
  .turn-card b{font-size:13.5px!important}
  .turn-card small{font-size:11px!important}
  .move-row{font-size:13px!important}
  .game-actions button{font-size:11.5px!important}
}


/* v2.5 — complete light theme + refined typography */
:root{
  --font-fa:"Vazirmatn","Segoe UI",Tahoma,Arial,sans-serif;
  --font-latin:"Manrope","Segoe UI",Arial,sans-serif;
  --border:var(--line);
}
html,body,button,input,select,textarea{font-family:var(--font-fa)}
body{font-weight:500;letter-spacing:-.12px}
button,input,select,textarea{font-weight:600}
.brand-copy b,.clock,.coords,.captured,.move-head,.move-row,.rating-grid-v2 strong,[dir="ltr"]{font-family:var(--font-latin),var(--font-fa)}
.top-brand b,.panel-title b,.name-line b,.turn-card b,.setup-title b,.card-title b,.nav b{font-weight:800}
.panel-title small,.turn-card small,.player-main small,.setup-title small,.card-title small{font-weight:500}

html.light-theme{background:#eef2e9}
body.light,html.light-theme body{
  --bg:#eef2e9;
  --bg2:#e2e8dc;
  --panel:#ffffff;
  --panel2:#f4f7f1;
  --panel3:#eaf0e5;
  --text:#1b241a;
  --muted:#667063;
  --line:rgba(31,43,28,.13);
  --green:#6fa63c;
  --green2:#5b902e;
  --gold:#a8791e;
  --danger:#c94c4c;
  --shadow:0 22px 58px rgba(47,65,40,.13);
  background:
    radial-gradient(circle at 75% -12%,rgba(112,166,60,.17),transparent 32%),
    radial-gradient(circle at 8% 105%,rgba(93,130,70,.09),transparent 34%),
    linear-gradient(135deg,#f7f9f4 0%,#edf2e8 100%);
  color:var(--text);
}
body.light::before{
  opacity:.42;
  background-image:linear-gradient(rgba(48,68,40,.035) 1px,transparent 1px),linear-gradient(90deg,rgba(48,68,40,.035) 1px,transparent 1px);
}
body.light .rail{
  background:linear-gradient(180deg,rgba(251,253,248,.99),rgba(236,242,231,.99));
  border-left-color:rgba(37,53,32,.11);
  box-shadow:-14px 0 38px rgba(52,72,44,.08);
}
body.light .rail .brand-logo{
  background:linear-gradient(145deg,rgba(111,166,60,.15),rgba(255,255,255,.8));
  border-color:rgba(93,145,48,.23);
}
body.light .rail .brand-mark{background:#f8fbf5;box-shadow:inset 0 0 0 1px rgba(45,70,35,.09),0 8px 20px rgba(55,78,46,.12)}
body.light .rail .brand-copy b{color:#24331f}
body.light .rail .nav{color:#596454}
body.light .rail .nav:hover{background:rgba(56,78,47,.07);color:#1e2b1b}
body.light .rail .nav.active{
  color:#20311b;
  background:linear-gradient(145deg,rgba(111,166,60,.2),rgba(111,166,60,.08));
  border-color:rgba(91,145,47,.25);
}
body.light .rail-bottom>button{background:rgba(40,58,35,.045);border-color:rgba(40,58,35,.08);color:#53604f}
body.light .rail-bottom>button:hover{background:rgba(111,166,60,.13);color:#263620}
body.light .mini-user{color:#24301f}
body.light .mini-user small{color:#697565}
body.light .topbar{border-bottom-color:rgba(31,43,28,.1)}
body.light .top-brand img{filter:drop-shadow(0 7px 13px rgba(53,79,40,.14))}
body.light .online{background:rgba(255,255,255,.72);border-color:rgba(31,43,28,.09);box-shadow:0 5px 18px rgba(45,66,36,.06)}
body.light .icon-action,body.light .logout-icon{
  background:#fff;color:#53604f;border-color:rgba(31,43,28,.12);box-shadow:0 5px 15px rgba(45,66,36,.06)
}
body.light .icon-action:hover,body.light .logout-icon:hover{background:#edf4e8;color:#273720}
body.light .top-login{color:#31402c;background:#fff;border-color:rgba(31,43,28,.13)}
body.light .top-register{color:#fff;background:#2b3827;box-shadow:0 6px 18px rgba(36,50,31,.16)}
body.light .user-chip{color:#253320;background:#fff;border-color:rgba(31,43,28,.12);box-shadow:0 7px 20px rgba(45,66,36,.07)}
body.light .player-strip{
  background:linear-gradient(145deg,rgba(255,255,255,.96),rgba(242,246,238,.92));
  border-color:rgba(31,43,28,.11);
  box-shadow:0 10px 25px rgba(45,66,36,.075)
}
body.light .avatar.bot{background:linear-gradient(145deg,#788173,#555e51)}
body.light .flag{background:#e7ece3;color:#586354;border-color:rgba(31,43,28,.09)}
body.light .status-badge{background:rgba(111,166,60,.15);color:#4f8127;border-color:rgba(83,133,42,.12)}
body.light .captured{color:#667063}
body.light .clock{background:#dfe6da;color:#566151;box-shadow:inset 0 0 0 1px rgba(31,43,28,.07),0 6px 15px rgba(45,66,36,.06)}
body.light .clock.active{background:linear-gradient(180deg,#283523,#1f2b1c);color:#fff;box-shadow:0 8px 22px rgba(31,43,28,.2)}
body.light .eval{background:#263022;border-color:rgba(31,43,28,.12)}
body.light .board-frame{border-color:rgba(31,43,28,.16);box-shadow:0 27px 65px rgba(42,59,35,.19),0 0 0 6px rgba(255,255,255,.55)}
body.light .game-panel{
  color:var(--text);
  background:linear-gradient(180deg,rgba(255,255,255,.98),rgba(244,248,241,.99));
  border-color:rgba(31,43,28,.12);
  box-shadow:0 28px 65px rgba(46,67,37,.13)
}
body.light .panel-head{background:linear-gradient(180deg,rgba(111,166,60,.07),transparent)}
body.light .panel-kicker{color:#5e942f!important}
body.light .panel-title b{color:#1b2818!important}
body.light .panel-title small{color:#687363!important}
body.light .panel-status{color:#596654!important;background:#edf3e8;border:1px solid rgba(31,43,28,.08)}
body.light .dots{background:#eef3e9;color:#667163}
body.light .tabs{background:#e9eee5;border:1px solid rgba(31,43,28,.08)}
body.light .tabs .tab{color:#697465!important}
body.light .tabs .tab.active{color:#21301d!important;background:#fff;box-shadow:inset 0 0 0 1px rgba(31,43,28,.08),0 5px 14px rgba(44,64,36,.08)}
body.light .turn-card{background:linear-gradient(135deg,rgba(111,166,60,.15),rgba(255,255,255,.9));border-color:rgba(83,133,42,.18)}
body.light .turn-card b{color:#22311e!important}
body.light .turn-card small{color:#667262!important}
body.light .move-head{color:#697466!important}
body.light .move-list{border-block-color:rgba(31,43,28,.09)}
body.light .move-row{color:#263422!important}
body.light .move-row:nth-child(even){background:rgba(46,65,39,.035)}
body.light .move-row>span{color:#798476!important}
body.light .move-cell{color:#253321!important}
body.light .move-cell:hover{background:rgba(111,166,60,.14)}
body.light .empty-state{color:#758170!important}
body.light .empty-state p{color:#33412f!important}
body.light .empty-state small{color:#74806f!important}
body.light .move-controls{background:#e9eee5}
body.light .move-controls button{background:rgba(255,255,255,.55);color:#62705e!important}
body.light .move-controls button:hover{background:#fff;color:#24331f!important}
body.light .game-actions button{color:#344230!important;background:#fff;border-color:rgba(31,43,28,.12);box-shadow:0 4px 12px rgba(45,66,36,.045)}
body.light .game-actions button:hover{background:#edf4e8}
body.light .game-actions .danger:hover{background:var(--danger);color:#fff!important}
body.light .new-game-box{background:#edf2e8;border-top-color:rgba(31,43,28,.1)}
body.light .setup-title b{color:#24321f!important}
body.light .setup-title small{color:#687464!important}
body.light .time-presets button{color:#33422e!important;background:#fff;border-color:rgba(31,43,28,.12)}
body.light .time-presets small{color:#73806e!important}
body.light .time-presets button.selected{background:rgba(111,166,60,.16);border-color:#72a743;color:#27421c!important}
body.light .setup-row select,body.light .chat-input input{
  color:#273523!important;background:#fff;border-color:rgba(31,43,28,.13);box-shadow:0 3px 10px rgba(45,66,36,.035)
}
body.light .setup-row select option{background:#fff;color:#273523}
body.light .coach-hero b{color:#263521!important}
body.light .coach-hero small{color:#6b7767!important}
body.light .coach-message{color:#33422e;background:#f0f5ec;border-right-color:#6fa63c}
body.light .analysis-grid div,body.light .system-msg{background:#edf3e9}
body.light .analysis-grid small{color:#6e7b69!important}
body.light .analysis-grid b{color:#263521!important}
body.light .meter{background:#dfe7d9}
body.light .coach-tips,body.light .system-msg{color:#657260!important}
body.light .chat-input{border-top-color:rgba(31,43,28,.1)}
body.light .below-grid article,body.light .community-grid article{
  background:linear-gradient(145deg,#fff,#f4f7f1);border-color:rgba(31,43,28,.11);box-shadow:0 12px 28px rgba(45,66,36,.07)
}
body.light .below-grid article>button,body.light .community-grid button{background:#edf3e9;color:#2b3927;border-color:rgba(31,43,28,.11)}
body.light .mini-board{background:#e7ece2;color:#445140}
body.light .guest-benefits{background:linear-gradient(135deg,rgba(111,166,60,.13),rgba(255,255,255,.82));border-color:rgba(83,133,42,.17)}
body.light .iran-banner{background:linear-gradient(120deg,#dcebd6,#bcd8ae);color:#20371a;box-shadow:0 22px 48px rgba(48,75,37,.12)}
body.light .iran-banner button{background:#20341b;color:#fff}
body.light .placeholder>span{color:#679d35}
body.light .toast{background:#253221;color:#fff;box-shadow:0 16px 40px rgba(35,51,29,.22)}
body.light .hamburger{background:#fff;color:#263521;border-color:rgba(31,43,28,.13)}
body.light ::-webkit-scrollbar-thumb{background:#bdc9b5;border-color:#eef2e9}
body.light ::-webkit-scrollbar-track{background:#e8ede4}

@media (prefers-reduced-motion:reduce){*,*::before,*::after{scroll-behavior:auto!important;transition:none!important;animation:none!important}}

/* v2.5.1 — font consistency and light surfaces outside the play page */
.game-panel,
.game-panel button,
.game-panel select,
.game-panel input,
.account-page,
.auth-page-v2,
.legal-shell,
.pricing-page{
  font-family:var(--font-fa)!important;
}

body.light.account-page,
body.light.auth-page-v2{
  background:#eef2e9;
  color:#1d281a;
}
body.light .account-topbar{
  background:rgba(250,252,247,.94);
  border-bottom-color:rgba(31,43,28,.11);
  box-shadow:0 10px 30px rgba(45,66,36,.06);
}
body.light .account-logo,body.light .auth-logo-v2{color:#23321f}
body.light .account-topbar nav a,body.light .top-logout{color:#586553}
body.light .account-topbar nav a:hover,body.light .top-logout:hover{background:#e9f0e4;color:#263720}
body.light .profile-hero-v2{
  background:linear-gradient(135deg,#fff,#f0f5ec 65%,#e0ecd8);
  border-color:rgba(31,43,28,.11);
  box-shadow:0 22px 55px rgba(48,68,40,.11)
}
body.light .profile-hero-v2:after{color:rgba(47,67,39,.055)}
body.light .profile-handle-v2,body.light .profile-meta-v2{color:#677363}
body.light .btn-ghost-v2{background:#fff;color:#33422e;border-color:rgba(31,43,28,.12)}
body.light .rating-grid-v2 article,body.light .panel-v2{
  background:#fff;border-color:rgba(31,43,28,.1);box-shadow:0 10px 25px rgba(45,66,36,.055)
}
body.light .rating-grid-v2 article.featured-rating-v2{background:linear-gradient(135deg,#edf5e7,#fff);border-color:rgba(103,155,55,.2)}
body.light .rating-icon-v2,body.light .security-icon-v2{background:#edf3e9}
body.light .rating-grid-v2 span,body.light .rating-grid-v2 small,body.light .panel-head-v2 p,body.light .empty-state-v2 p,body.light .game-row-v2 small,body.light .info-list-v2 span,body.light .security-item-v2 small,body.light .mini-stats-v2 span{color:#6b7767}
body.light .panel-head-v2,body.light .game-row-v2,body.light .info-list-v2>div,body.light .mini-stats-v2>div{border-color:rgba(31,43,28,.09)}
body.light .info-list-v2 em.neutral{background:#edf2e9;color:#657160}
body.light .auth-layout-v2{background:#eef2e9}
body.light .auth-showcase-v2{
  background:radial-gradient(circle at 20% 20%,rgba(111,166,60,.24),transparent 36%),linear-gradient(150deg,#e5efdf,#f7faf4)
}
body.light .auth-showcase-v2:after{border-color:rgba(38,56,31,.045)}
body.light .auth-copy-v2 h1{color:#1d2a19}
body.light .auth-copy-v2>p,body.light .auth-benefits-v2 small{color:#647160}
body.light .auth-benefits-v2 b{background:#fff;color:#38502f;box-shadow:0 6px 18px rgba(45,66,36,.07)}
body.light .auth-board-art-v2{color:rgba(39,58,32,.14)}
body.light .auth-form-side-v2{background:#f4f7f1}
body.light .auth-card-v2{background:#fff;border-color:rgba(31,43,28,.11);box-shadow:0 24px 60px rgba(45,66,36,.12)}
body.light .auth-back-v2,body.light .auth-card-title-v2 p{color:#687465}
body.light .auth-tabs-v2{background:#edf2e9}
body.light .auth-tabs-v2 button{color:#687465}
body.light .auth-tabs-v2 button.active{background:#fff;color:#263620;box-shadow:0 5px 14px rgba(45,66,36,.08)}
body.light .auth-form-v2 label>span{color:#445140}
body.light .auth-form-v2 input:not([type=checkbox]){background:#f8faf6;color:#23301f;border-color:rgba(31,43,28,.14)}
body.light .auth-legal-v2{color:#778173}
body.light .auth-legal-v2 a{color:#5d6a58}
body.light .legal-shell{background:#eef2e9;color:#1d281a}
body.light .legal-card{background:#fff;border-color:rgba(31,43,28,.11);box-shadow:0 22px 55px rgba(45,66,36,.11)}
body.light .legal-card p,body.light .legal-card li{color:#4f5d4b}
body.light .legal-card a{color:#5f9334}
body.light .pricing-page{color:#1d281a}
body.light .plan,body.light .fair{background:#fff;border-color:rgba(31,43,28,.11);box-shadow:0 12px 28px rgba(45,66,36,.06)}
