/* کوشی — استایل — RTL، موبایل‌فرست، بدون وابستگی خارجی */

@font-face{font-family:'Vazirmatn';src:url('fonts/Vazirmatn-Regular.woff2') format('woff2');font-weight:400;font-display:swap}
@font-face{font-family:'Vazirmatn';src:url('fonts/Vazirmatn-Medium.woff2') format('woff2');font-weight:500;font-display:swap}
@font-face{font-family:'Vazirmatn';src:url('fonts/Vazirmatn-Bold.woff2') format('woff2');font-weight:700;font-display:swap}
@font-face{font-family:'Morabba';src:url('fonts/Morabba-Bold.woff2') format('woff2');font-weight:700;font-display:swap}

:root{
  --porcelain:#ECF1F1; --surface:#FFFFFF; --ink:#0D4145; --teal:#17797E; --teal-soft:#E3EEEE;
  --saffron:#C8890F; --saffron-soft:#FBF0DC; --muted:#6E8B8D; --line:rgba(13,65,69,.10);
  --danger:#B3261E; --danger-soft:#FBE9E7; --ok:#2E7D32; --ok-soft:#E7F2E8;
  --r-lg:20px; --r-md:14px; --r-sm:9px;
  --nav-h:64px;
}

*{box-sizing:border-box}
html,body{margin:0;padding:0;overscroll-behavior-y:contain;overscroll-behavior-x:none}
html{height:100%}
body{
  font-family:'Vazirmatn',Tahoma,'Segoe UI',sans-serif;
  background:var(--porcelain); color:var(--ink);
  font-size:15px; line-height:1.8; -webkit-tap-highlight-color:transparent;
}
button,input,select,textarea{font-family:inherit;font-size:inherit;color:inherit}
button{cursor:pointer;border:none;background:none}
a{color:var(--teal);text-decoration:none}
h1,h2,h3{font-family:'Morabba','Vazirmatn',Tahoma,sans-serif;margin:0;font-weight:700;line-height:1.5}
.num{font-variant-numeric:tabular-nums}

/* ---------------- چیدمان ---------------- */
.app{max-width:960px;margin:0 auto;padding:0 14px calc(var(--nav-h) + 26px)}
.topbar{
  position:sticky;top:0;z-index:30;background:var(--porcelain);
  display:flex;align-items:center;gap:10px;padding:14px 2px 10px;
}
.topbar .brand{font-family:'Morabba','Vazirmatn';font-size:20px;font-weight:700}
.topbar .date{color:var(--muted);font-size:12.5px;margin-inline-start:6px}
.topbar #btn-home svg{stroke-width:1.8}
.topbar #btn-home:active{background:var(--teal-soft)}
.icon-btn{width:38px;height:38px;border-radius:12px;background:var(--surface);border:1px solid var(--line);
  display:grid;place-items:center}
.icon-btn svg{width:19px;height:19px;stroke:var(--ink);fill:none;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}

.card{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg);padding:16px;margin-bottom:12px}
.card.tight{padding:12px}
.card-head{display:flex;align-items:center;gap:8px;margin-bottom:12px}
.card-head h3{font-size:16px}
.card-head .sub{color:var(--muted);font-size:12.5px;margin-inline-start:auto}

.row{display:flex;align-items:center;gap:10px}
.spread{display:flex;align-items:center;justify-content:space-between;gap:10px}
.muted{color:var(--muted)}
.small{font-size:12.5px}
.center{text-align:center}
.hidden{display:none !important}

/* ---------------- حلقه کالری ---------------- */
.hero{display:flex;align-items:center;gap:18px}
.ring{position:relative;width:132px;height:132px;flex:0 0 132px}
.ring svg{transform:rotate(-90deg)}
.ring .track{stroke:var(--teal-soft)}
.ring .bar{stroke:var(--teal);transition:stroke-dashoffset .5s ease}
.ring.over .bar{stroke:var(--saffron)}
.ring .val{position:absolute;inset:0;display:grid;place-content:center;text-align:center}
.ring .val b{display:block;font-size:27px;font-family:'Morabba','Vazirmatn';line-height:1.2}
.ring .val span{font-size:11.5px;color:var(--muted)}
.hero-side{flex:1;min-width:0}
.kv{display:flex;justify-content:space-between;font-size:13px;padding:3px 0}
.kv b{font-weight:500}

.macro{margin-top:10px}
.macro-row{margin-bottom:9px}
.macro-row .spread{font-size:12.5px;margin-bottom:4px}
.bar-bg{height:7px;border-radius:99px;background:var(--teal-soft);overflow:hidden}
.bar-fill{height:100%;border-radius:99px;background:var(--teal);transition:width .4s ease}
.bar-fill.p{background:#17797E}.bar-fill.c{background:#C8890F}.bar-fill.f{background:#5B7F9E}

/* ---------------- وعده‌ها ---------------- */
.slot{border:1px solid var(--line);border-radius:var(--r-md);padding:12px;margin-bottom:10px;background:var(--surface)}
.slot-head{display:flex;align-items:center;gap:8px}
.slot-head .t{font-weight:500}
.slot-head .k{margin-inline-start:auto;font-size:12.5px;color:var(--muted)}
.slot-bar{height:4px;border-radius:99px;background:var(--teal-soft);margin:9px 0 6px;overflow:hidden}
.slot-bar i{display:block;height:100%;background:var(--teal)}
.slot-bar i.over{background:var(--saffron)}
.item{display:flex;align-items:center;gap:8px;padding:7px 0;border-top:1px dashed var(--line);font-size:13.5px}
.item:first-of-type{border-top:none}
.item .n{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.item .q{color:var(--muted);font-size:12px}
.item .c{color:var(--teal);font-weight:500}
.item .x{color:var(--muted);padding:0 4px;font-size:17px;line-height:1}
.item.planned{opacity:.72}

.chip{display:inline-flex;align-items:center;gap:5px;padding:5px 11px;border-radius:99px;
  border:1px solid var(--line);background:var(--surface);font-size:12.5px;white-space:nowrap}
.chip.on{background:var(--teal);border-color:var(--teal);color:#fff}
.chip.sm{padding:3px 9px;font-size:11.5px}
.chips{display:flex;gap:7px;overflow-x:auto;padding-bottom:4px;scrollbar-width:none}
.chips::-webkit-scrollbar{display:none}

.btn{display:inline-flex;align-items:center;justify-content:center;gap:6px;
  padding:11px 16px;border-radius:var(--r-md);background:var(--teal);color:#fff;font-weight:500;font-size:14px}
.btn.ghost{background:var(--surface);color:var(--ink);border:1px solid var(--line)}
.btn.accent{background:var(--saffron)}
.btn.wide{width:100%}
.btn.sm{padding:7px 12px;font-size:13px;border-radius:10px}
.btn:disabled{opacity:.5}
.btn-row{display:flex;gap:8px;flex-wrap:wrap}

.field{margin-bottom:12px}
.field label{display:block;font-size:12.5px;color:var(--muted);margin-bottom:5px}
.field input,.field select{width:100%;padding:11px 12px;border-radius:var(--r-md);
  border:1px solid var(--line);background:var(--surface)}
.field input:focus,.field select:focus{outline:2px solid var(--teal);outline-offset:1px}
.grid2{display:grid;grid-template-columns:1fr 1fr;gap:10px}

/* ---------------- گزارش ---------------- */
.status{display:inline-flex;align-items:center;gap:6px;padding:6px 13px;border-radius:99px;font-weight:500;font-size:13px}
.status.ok{background:var(--ok-soft);color:var(--ok)}
.status.minor{background:var(--saffron-soft);color:var(--saffron)}
.status.major{background:var(--danger-soft);color:var(--danger)}
.finding{border-inline-start:3px solid var(--line);padding:6px 11px;margin-bottom:9px;background:#FAFCFC;border-radius:0 var(--r-sm) var(--r-sm) 0}
.finding.major{border-color:var(--danger)}
.finding.minor{border-color:var(--saffron)}
.finding b{font-size:13.5px;font-weight:500}
.finding p{margin:2px 0 0;font-size:12.5px;color:var(--muted)}
.finding .slotname{font-size:11.5px;color:var(--teal)}

.bars{display:flex;align-items:flex-end;gap:6px;height:120px;padding-top:8px}
.bars .b{flex:1;display:flex;flex-direction:column;justify-content:flex-end;align-items:center;gap:5px;height:100%}
.bars .b i{width:100%;background:var(--teal);border-radius:6px 6px 0 0;min-height:3px}
.bars .b i.over{background:var(--saffron)}
.bars .b i.none{background:var(--teal-soft)}
.bars .b span{font-size:10.5px;color:var(--muted)}

/* ---------------- نوار پایین ---------------- */
.nav{position:fixed;inset-inline:0;bottom:0;z-index:40;height:var(--nav-h);
  background:rgba(255,255,255,.96);border-top:1px solid var(--line);
  display:flex;padding-bottom:env(safe-area-inset-bottom)}
.nav button{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;
  color:var(--muted);font-size:10.5px}
.nav button svg{width:21px;height:21px;stroke:currentColor;fill:none;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.nav button.on{color:var(--teal)}
.nav button.on svg{stroke-width:2.1}

/* ---------------- شیت و مودال ---------------- */
.sheet-bg{position:fixed;inset:0;background:rgba(13,65,69,.35);z-index:50;display:none}
.sheet-bg.on{display:block}
.sheet{position:fixed;inset-inline:0;bottom:0;z-index:51;background:var(--porcelain);
  border-radius:22px 22px 0 0;max-height:88vh;display:flex;flex-direction:column;
  transform:translateY(100%);transition:transform .25s ease}
.sheet.on{transform:translateY(0)}
.sheet-head{padding:14px 16px 10px;display:flex;align-items:center;gap:10px;border-bottom:1px solid var(--line)}
.sheet-head h3{font-size:16px}
.sheet-body{overflow-y:auto;padding:14px 16px calc(20px + env(safe-area-inset-bottom));-webkit-overflow-scrolling:touch}
.handle{width:38px;height:4px;border-radius:99px;background:var(--line);margin:8px auto 0}

.list-row{display:flex;align-items:center;gap:10px;padding:11px 12px;background:var(--surface);
  border:1px solid var(--line);border-radius:var(--r-md);margin-bottom:8px}
.list-row .n{flex:1;min-width:0}
.list-row .n b{display:block;font-weight:500;font-size:14px}
.list-row .n span{font-size:11.5px;color:var(--muted)}
.stepper{display:flex;align-items:center;gap:9px}
.stepper button{width:29px;height:29px;border-radius:9px;background:var(--teal-soft);color:var(--teal);font-size:16px;line-height:1}
.stepper b{min-width:34px;text-align:center;font-weight:500;font-size:13.5px}

.checkline{display:flex;align-items:center;gap:11px}
.checkline .box{width:22px;height:22px;border-radius:7px;border:1.6px solid var(--line);display:grid;place-items:center;flex:0 0 22px}
.checkline.done .box{background:var(--teal);border-color:var(--teal)}
.checkline.done .box::after{content:'✓';color:#fff;font-size:13px;line-height:1}
.checkline.done .n b{text-decoration:line-through;color:var(--muted)}

.toast{position:fixed;bottom:calc(var(--nav-h) + 14px);inset-inline:0;margin:0 auto;width:max-content;max-width:88%;
  background:var(--ink);color:#fff;padding:10px 18px;border-radius:99px;font-size:13px;z-index:80;
  opacity:0;transform:translateY(8px);transition:.2s;pointer-events:none}
.toast.on{opacity:1;transform:translateY(0)}

.empty{text-align:center;padding:26px 16px;color:var(--muted);font-size:13.5px}
.notice{background:var(--saffron-soft);border:1px solid rgba(200,137,15,.28);border-radius:var(--r-md);
  padding:11px 13px;font-size:12.5px;margin-bottom:12px}

/* ---------------- ورود ---------------- */
.auth{max-width:380px;margin:0 auto;padding:56px 18px}
.auth .logo{font-family:'Morabba','Vazirmatn';font-size:32px;text-align:center;margin-bottom:4px}
.auth .tag{text-align:center;color:var(--muted);font-size:13px;margin-bottom:26px}

/* ---------------- دسکتاپ ---------------- */
@media (min-width:900px){
  body{font-size:15.5px}
  .app{padding-bottom:26px;padding-inline-start:96px;max-width:1040px}
  .nav{inset-inline-end:auto;inset-inline-start:0;top:0;bottom:0;height:auto;width:82px;
    flex-direction:column;justify-content:center;gap:6px;border-top:none;border-inline-end:1px solid var(--line)}
  .nav button{flex:0 0 auto;padding:13px 0}
  .cols{display:grid;grid-template-columns:1.15fr .85fr;gap:12px;align-items:start}
  .sheet{inset-inline:auto;inset-inline-start:50%;transform:translate(50%,100%);width:520px;
    border-radius:22px 22px 0 0}
  .sheet.on{transform:translate(50%,0)}
  .toast{bottom:22px}
}
@media (prefers-reduced-motion:reduce){*{transition:none !important}}

/* ---------------- منوی کشویی سمت راست ---------------- */
.drawer-bg{position:fixed;inset:0;background:rgba(13,65,69,.35);z-index:60;display:none}
.drawer-bg.on{display:block}
.drawer{position:fixed;top:0;bottom:0;right:0;left:auto;z-index:61;width:min(360px,86vw);
  background:var(--porcelain);border-left:1px solid var(--line);
  display:flex;flex-direction:column;transform:translateX(100%);transition:transform .25s ease;
  box-shadow:-14px 0 40px rgba(13,65,69,.10)}
.drawer.on{transform:translateX(0)}
.drawer-head{display:flex;align-items:center;gap:10px;padding:16px 16px 12px;border-bottom:1px solid var(--line)}
.drawer-head h3{font-size:17px}
.drawer-body{overflow-y:auto;padding:16px}
.drawer .group{margin-bottom:20px}
.drawer .group>h4{font-size:13px;color:var(--muted);font-weight:400;margin:0 0 9px;
  font-family:'Vazirmatn',Tahoma,sans-serif}
.target-box{background:var(--teal);color:#fff;border-radius:var(--r-lg);padding:15px;margin-bottom:16px}
.target-box b{font-family:'Morabba','Vazirmatn';font-size:29px;display:block;line-height:1.3}
.target-box span{font-size:12.5px;opacity:.85}
.target-box .split{display:flex;gap:14px;margin-top:10px;font-size:12px;opacity:.9}

/* ---------------- ورزش ---------------- */
.session{border:1px solid var(--line);border-radius:var(--r-md);background:var(--surface);
  padding:13px;margin-bottom:10px}
.session-head{display:flex;align-items:baseline;gap:8px;margin-bottom:4px}
.session-head b{font-weight:500}
.session-head span{font-size:11.5px;color:var(--muted)}
.ex{display:flex;align-items:center;gap:8px;padding:7px 0;border-top:1px dashed var(--line);font-size:13.5px}
.ex:first-of-type{border-top:none}
.ex .n{flex:1;min-width:0}
.ex .m{font-size:11.5px;color:var(--muted)}
.ex .s{color:var(--teal);font-weight:500;font-size:12.5px;white-space:nowrap}
.cycle{display:flex;align-items:center;gap:8px;background:var(--saffron-soft);
  border:1px solid rgba(200,137,15,.28);border-radius:var(--r-md);padding:11px 13px;margin-bottom:12px}
.cycle b{font-weight:500;font-size:13.5px}
.cycle p{margin:1px 0 0;font-size:12px;color:var(--muted)}
.dots{display:flex;gap:4px;margin-inline-start:auto}
.dots i{width:8px;height:8px;border-radius:99px;background:var(--line)}
.dots i.on{background:var(--saffron)}

/* ---------------- زیرتب گزارش ---------------- */
.subtabs{display:flex;gap:6px;background:var(--teal-soft);padding:4px;border-radius:var(--r-md);margin-bottom:12px}
.subtabs button{flex:1;padding:9px;border-radius:10px;font-size:13.5px;color:var(--muted)}
.subtabs button.on{background:var(--surface);color:var(--ink);font-weight:500}

/* ---------------- ابزارهای زمان ---------------- */
.clock{text-align:center;padding:14px 0 6px}
.clock .t{font-family:'Morabba','Vazirmatn';font-size:52px;line-height:1.1;letter-spacing:1px;
  font-variant-numeric:tabular-nums}
.clock .lbl{color:var(--muted);font-size:13px;margin-top:2px}
.clock.run .t{color:var(--teal)}
.clock.rest .t{color:var(--saffron)}
.laps{max-height:150px;overflow-y:auto;margin-top:10px}
.laps div{display:flex;justify-content:space-between;font-size:13px;padding:5px 2px;border-top:1px dashed var(--line)}
.presets{display:flex;gap:7px;flex-wrap:wrap;margin-bottom:12px}

/* ---------------- کالری‌سنج ---------------- */
.calc-out{background:var(--teal);color:#fff;border-radius:var(--r-lg);padding:15px;margin:12px 0}
.calc-out b{font-family:'Morabba','Vazirmatn';font-size:30px;display:block;line-height:1.3}
.calc-out .split{display:flex;gap:14px;margin-top:8px;font-size:12px;opacity:.9}

.gbtn{display:flex;align-items:center;justify-content:center;gap:9px;width:100%;padding:12px;
  border-radius:var(--r-md);background:var(--surface);border:1px solid var(--line);font-weight:500;font-size:14px}
.gbtn svg{width:19px;height:19px}

/* ================= حالت پیشرفته: تم سبز و سفید ================= */
body.adv{
  --porcelain:#F2F8F2; --surface:#FFFFFF; --ink:#123A1E; --teal:#2E7D32; --teal-soft:#E3F0E4;
  --saffron:#C8890F; --saffron-soft:#FBF0DC; --muted:#5F7C64; --line:rgba(18,58,30,.11);
}
body.adv .topbar{background:var(--porcelain)}
body.adv .target-box{background:linear-gradient(135deg,#2E7D32,#4C9A51)}
body.coach{--teal:#1B5E20;--teal-soft:#DDEBDE}

.topbar .mode-btn{margin-inline-start:auto}
.mode-btn{display:inline-flex;align-items:center;gap:6px;padding:6px 13px;border-radius:99px;
  border:1.5px solid var(--teal);background:var(--teal-soft);color:var(--teal);
  font-size:12px;font-weight:500;white-space:nowrap;position:relative}
.mode-btn i{width:7px;height:7px;border-radius:99px;background:var(--teal);display:block;opacity:.55}
.mode-btn.on{background:var(--teal);border-color:var(--teal);color:#fff}
.mode-btn.on i{background:#fff;opacity:1}
/* وقتی هنوز حالت ساده است، یک تپش ملایم توجه را جلب می‌کند */
.mode-btn:not(.on)::before{content:'';position:absolute;inset:-3px;border-radius:99px;
  border:2px solid var(--teal);opacity:.55;animation:modepulse 2.4s ease-out infinite}
@keyframes modepulse{
  0%{transform:scale(1);opacity:.5}
  60%{transform:scale(1.16);opacity:0}
  100%{opacity:0}
}
@media (prefers-reduced-motion:reduce){ .mode-btn:not(.on)::before{animation:none;opacity:.35} }

.bell{position:relative}
.bell .badge{position:absolute;top:-3px;inset-inline-start:-3px;min-width:17px;height:17px;padding:0 4px;
  border-radius:99px;background:var(--saffron);color:#fff;font-size:10.5px;line-height:17px;text-align:center}

/* ---------------- کارت‌های بخش پیشرفته ---------------- */
.hub{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-bottom:14px}
.hub button{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg);
  padding:15px 13px;text-align:start;display:flex;flex-direction:column;gap:5px;min-height:92px}
.hub button b{font-weight:500;font-size:14px}
.hub button span{font-size:11.5px;color:var(--muted);line-height:1.7}
.hub button svg{width:21px;height:21px;stroke:var(--teal);fill:none;stroke-width:1.7;
  stroke-linecap:round;stroke-linejoin:round;margin-bottom:2px}

.rank{display:flex;align-items:center;gap:11px;padding:11px 12px;background:var(--surface);
  border:1px solid var(--line);border-radius:var(--r-md);margin-bottom:8px}
.rank .no{width:28px;height:28px;border-radius:9px;background:var(--teal-soft);color:var(--teal);
  display:grid;place-items:center;font-weight:500;font-size:13px;flex:0 0 28px}
.rank.top .no{background:var(--saffron);color:#fff}
.rank.me{border-color:var(--teal);background:var(--teal-soft)}
.rank .n{flex:1;min-width:0}
.rank .n b{display:block;font-weight:500;font-size:14px}
.rank .n span{font-size:11.5px;color:var(--muted)}
.rank .v{font-weight:500;color:var(--teal);white-space:nowrap}

.person{display:flex;align-items:center;gap:11px;padding:11px 12px;background:var(--surface);
  border:1px solid var(--line);border-radius:var(--r-md);margin-bottom:8px}
.person .av{width:36px;height:36px;border-radius:12px;background:var(--teal-soft);color:var(--teal);
  display:grid;place-items:center;font-weight:500;flex:0 0 36px}
.person .n{flex:1;min-width:0}
.person .n b{display:block;font-weight:500;font-size:14px}
.person .n span{font-size:11.5px;color:var(--muted)}
.person .acts{display:flex;gap:6px}
.iconlink{width:33px;height:33px;border-radius:10px;border:1px solid var(--line);display:grid;place-items:center}
.iconlink svg{width:17px;height:17px;stroke:var(--teal);fill:none;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}

.note-area{width:100%;min-height:190px;padding:14px;border-radius:var(--r-lg);border:1px solid var(--line);
  background:var(--surface);line-height:2;font-size:14.5px;resize:vertical}
.note-area:focus{outline:2px solid var(--teal);outline-offset:1px}
.moods{display:flex;gap:7px;margin:10px 0}
.moods button{flex:1;padding:9px;border-radius:12px;border:1px solid var(--line);background:var(--surface);font-size:19px}
.moods button.on{border-color:var(--teal);background:var(--teal-soft)}

/* ---------------- ویزارد ---------------- */
.wiz{position:fixed;inset:0;z-index:90;background:var(--porcelain);overflow-y:auto;padding:26px 18px 40px}
.wiz-inner{max-width:420px;margin:0 auto}
.wiz .step{font-size:12.5px;color:var(--muted);margin-bottom:6px}
.wiz h2{font-size:22px;margin-bottom:6px}
.wiz .lead{color:var(--muted);font-size:13.5px;margin-bottom:20px;line-height:2}
.wiz-dots{display:flex;gap:5px;margin-bottom:20px}
.wiz-dots i{height:4px;flex:1;border-radius:99px;background:var(--line)}
.wiz-dots i.on{background:var(--teal)}
.pick{display:grid;gap:8px;margin-bottom:16px}
.pick button{padding:13px 15px;border-radius:var(--r-md);border:1px solid var(--line);
  background:var(--surface);text-align:start;font-size:14px}
.pick button.on{border-color:var(--teal);background:var(--teal-soft);font-weight:500}
.pick.two{grid-template-columns:1fr 1fr}

@media (min-width:900px){ .hub{grid-template-columns:1fr 1fr 1fr} }

/* ---------------- گفتگو ---------------- */
.chat{display:flex;flex-direction:column;
  /* ارتفاع دقیق را جاوااسکریپت ست می‌کند؛ این‌ها فقط پشتیبان اولیه‌اند */
  height:calc(100dvh - 250px);min-height:260px;max-height:calc(100dvh - 140px)}
@supports not (height: 100dvh){ .chat{height:calc(100vh - 250px)} }
.chat-log{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;
  -webkit-overflow-scrolling:touch;padding:4px 2px 10px;
  display:flex;flex-direction:column;gap:7px}
.bub{max-width:82%;padding:9px 13px;border-radius:16px;font-size:14px;line-height:1.9;
  background:var(--surface);border:1px solid var(--line);align-self:flex-start;
  border-end-start-radius:5px;word-break:break-word}
.bub.me{background:var(--teal);color:#fff;border-color:transparent;align-self:flex-end;
  border-end-start-radius:16px;border-end-end-radius:5px}
.bub .t{display:block;font-size:10.5px;opacity:.65;margin-top:3px}
.chat-day{align-self:center;font-size:11px;color:var(--muted);background:var(--teal-soft);
  padding:3px 11px;border-radius:99px}
.chat-bar{display:flex;gap:8px;align-items:flex-end;padding:9px 0 4px;
  border-top:1px solid var(--line);background:var(--porcelain);
  position:sticky;bottom:0;z-index:2}
.chat-bar textarea{flex:1;max-height:110px;min-height:44px;padding:11px 13px;border-radius:18px;
  border:1px solid var(--line);background:var(--surface);resize:none;line-height:1.8;font-size:14px}
.chat-bar button{width:44px;height:44px;border-radius:50%;background:var(--teal);flex:0 0 44px;
  display:grid;place-items:center}
.chat-bar button svg{width:19px;height:19px;stroke:#fff;fill:none;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
.dot-on{width:8px;height:8px;border-radius:99px;background:#2E7D32;display:inline-block}
.unread{background:var(--saffron);color:#fff;min-width:19px;height:19px;border-radius:99px;
  font-size:11px;line-height:19px;text-align:center;padding:0 5px}

/* ---------------- سطح و چالش ---------------- */
.lvl{display:flex;align-items:center;gap:13px}
.lvl .badge-l{width:52px;height:52px;border-radius:17px;background:var(--teal);color:#fff;
  display:grid;place-items:center;flex:0 0 52px;font-family:'Morabba','Vazirmatn';font-size:21px}
.lvl .n{flex:1;min-width:0}
.lvl .n b{font-weight:500}
.lvl .n .small{color:var(--muted)}
.chal{border:1px dashed var(--saffron);background:var(--saffron-soft);border-radius:var(--r-lg);padding:14px}
.chal.done{border-style:solid;border-color:var(--teal);background:var(--teal-soft)}
.chal b{display:block;font-weight:500;margin-bottom:2px}
.chal p{margin:0 0 10px;font-size:12.5px;color:var(--muted);line-height:1.9}

/* ---------------- آلبوم رویداد ---------------- */
.gal{display:grid;grid-template-columns:1fr 1fr;gap:9px}
.gal figure{margin:0;background:var(--surface);border:1px solid var(--line);border-radius:var(--r-md);overflow:hidden}
.gal img{width:100%;height:132px;object-fit:cover;display:block;background:var(--teal-soft)}
.gal figcaption{padding:8px 10px;font-size:11.5px;line-height:1.7}
.gal figcaption b{display:block;font-weight:500;font-size:12.5px}
.gal figcaption span{color:var(--muted)}
.gal .row{display:flex;gap:6px;padding:0 8px 8px}
@media (min-width:700px){ .gal{grid-template-columns:repeat(3,1fr)} }

/* ---------------- بازی ---------------- */
.gcard{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg);padding:15px;margin-bottom:10px}
.gq{font-size:19px;font-family:'Morabba','Vazirmatn';text-align:center;padding:16px 8px;line-height:1.7}
.gopts{display:grid;gap:8px}
.gopts button{padding:14px;border-radius:var(--r-md);border:1px solid var(--line);
  background:var(--surface);font-size:14.5px;text-align:start}
.gopts button.on{border-color:var(--teal);background:var(--teal-soft);font-weight:500}
.gtimer{height:5px;border-radius:99px;background:var(--teal-soft);overflow:hidden;margin-bottom:12px}
.gtimer i{display:block;height:100%;background:var(--saffron);transition:width 1s linear}
.gscore{display:flex;align-items:center;gap:9px;padding:8px 10px;border-radius:var(--r-sm);font-size:13.5px}
.gscore.me{background:var(--teal-soft)}
.gscore .s{margin-inline-start:auto;font-weight:500;color:var(--teal)}

/* ---------------- ردیف اعلان قابل کلیک ---------------- */
.list-row.notif{cursor:pointer;gap:11px}
.list-row.notif:active{background:var(--teal-soft)}
.list-row.notif .av{width:34px;height:34px;border-radius:11px;background:var(--teal-soft);
  display:grid;place-items:center;flex:0 0 34px}
.list-row.notif .av svg{width:17px;height:17px;stroke:var(--teal);fill:none;stroke-width:1.7;
  stroke-linecap:round;stroke-linejoin:round}
.list-row.notif .n b{display:block;font-weight:500;font-size:14px}
.list-row.notif .n span{display:block;font-size:11.5px;color:var(--muted);
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.list-row.notif .go{color:var(--muted);font-size:20px;line-height:1;transform:scaleX(-1)}

/* ---------------- لوگو و نصب ---------------- */
.brand-logo{width:28px;height:28px;border-radius:9px;flex:0 0 28px}
.auth-logo{display:block;width:96px;height:96px;border-radius:28px;margin:0 auto 14px;
  box-shadow:0 10px 28px rgba(13,65,69,.12)}
.install{display:flex;align-items:center;gap:12px;background:var(--surface);
  border:1px solid var(--line);border-radius:var(--r-lg);padding:13px;margin-bottom:12px}
.install img{width:44px;height:44px;border-radius:13px;flex:0 0 44px}
.install .n{flex:1;min-width:0}
.install .n b{display:block;font-weight:500;font-size:14px}
.install .n span{font-size:11.5px;color:var(--muted);line-height:1.7}

/* ---------------- ویزارد ساده ---------------- */
.simple-cta{display:flex;align-items:center;gap:12px;background:linear-gradient(135deg,var(--teal),#4C9A51);
  color:#fff;border:none;border-radius:var(--r-lg);padding:15px;width:100%;text-align:start;margin-bottom:12px}
.simple-cta b{display:block;font-weight:500;font-size:15px;margin-bottom:2px}
.simple-cta span{font-size:12px;opacity:.9;line-height:1.8}
.simple-cta .arrow{margin-inline-start:auto;font-size:22px;transform:scaleX(-1)}
.privacy{display:flex;gap:9px;background:var(--teal-soft);border-radius:var(--r-md);
  padding:11px 13px;font-size:12.5px;line-height:1.9;margin-bottom:14px}
.privacy svg{width:18px;height:18px;flex:0 0 18px;margin-top:4px;stroke:var(--teal);fill:none;stroke-width:1.7}

/* ---------------- کشوی تنظیمات از لبه چپ ---------------- */
.quick{position:fixed;top:0;bottom:0;left:0;right:auto;z-index:70;
  width:min(330px,84vw);background:var(--surface);
  border-inline-end:1px solid var(--line);border-radius:0 24px 24px 0;
  transform:translateX(-100%);transition:transform .28s cubic-bezier(.22,.9,.3,1);
  box-shadow:14px 0 40px rgba(13,65,69,.16);display:flex;align-items:stretch;direction:rtl}
.quick.on{transform:translateX(0)}
.quick-inner{flex:1;min-width:0;padding:18px 16px 24px;overflow-y:auto;
  overscroll-behavior:contain;-webkit-overflow-scrolling:touch}

/* تنها دستگیره: روی لبه راست کشو می‌نشیند، پس وقتی کشو بسته است
   دقیقاً روی لبه چپ صفحه دیده می‌شود و با باز شدن همراهش حرکت می‌کند */
.quick-grip{position:absolute;top:44%;left:100%;transform:translateY(-50%);
  width:24px;height:96px;background:var(--surface);
  border:1px solid var(--line);border-inline-start:none;border-radius:0 14px 14px 0;
  display:flex;align-items:center;justify-content:center;cursor:pointer;
  box-shadow:5px 0 16px rgba(13,65,69,.12)}
.quick-grip span{width:4px;height:40px;border-radius:99px;background:var(--teal);opacity:.55}
.quick-grip:active span{opacity:1}

/* کشیدن برای تازه‌سازی */
.ptr{position:fixed;top:0;inset-inline:0;z-index:68;display:flex;justify-content:center;
  pointer-events:none;transition:opacity .2s}
.ptr i{display:block;width:34px;height:34px;border-radius:50%;background:var(--surface);
  border:1px solid var(--line);box-shadow:0 4px 14px rgba(13,65,69,.14);
  position:relative;margin-top:6px}
.ptr i::after{content:'';position:absolute;inset:8px;border-radius:50%;
  border:2px solid var(--teal-soft);border-top-color:var(--teal)}
.ptr.spin i::after{animation:ptrspin .7s linear infinite}
@keyframes ptrspin{to{transform:rotate(360deg)}}

.tiles{display:grid;grid-template-columns:1fr 1fr;gap:9px;margin-bottom:14px}
.tile{display:flex;align-items:center;gap:10px;padding:12px;border-radius:var(--r-md);
  border:1px solid var(--line);background:var(--surface);text-align:start}
.tile .ic{width:34px;height:34px;border-radius:11px;display:grid;place-items:center;flex:0 0 34px;
  background:var(--teal-soft)}
.tile .ic svg{width:17px;height:17px;stroke:var(--teal);fill:none;stroke-width:1.8;
  stroke-linecap:round;stroke-linejoin:round}
.tile .n{flex:1;min-width:0}
.tile .n b{display:block;font-weight:500;font-size:13px}
.tile .n span{font-size:10.5px;color:var(--muted)}
.tile.on{border-color:var(--teal);background:var(--teal-soft)}
.tile.on .ic{background:var(--teal)}
.tile.on .ic svg{stroke:#fff}
.tile .sw{width:38px;height:22px;border-radius:99px;background:var(--line);position:relative;flex:0 0 38px}
.tile .sw::after{content:'';position:absolute;top:3px;inset-inline-start:3px;width:16px;height:16px;
  border-radius:50%;background:#fff;transition:.2s}
.tile.on .sw{background:var(--teal)}
.tile.on .sw::after{inset-inline-start:19px}
@media(min-width:700px){ .tiles{grid-template-columns:repeat(3,1fr)} }

/* ---------------- دکمه شناور و گردونه ---------------- */
.fab{position:fixed;inset-inline-start:16px;bottom:calc(var(--nav-h) + 16px);z-index:55;
  width:56px;height:56px;border-radius:50%;background:var(--teal);
  display:grid;place-items:center;box-shadow:0 10px 26px rgba(13,65,69,.28)}
.fab svg{width:25px;height:25px;stroke:#fff;fill:none;stroke-width:1.7;stroke-linecap:round}
.fab.spin svg{animation:tick 6s linear infinite}
@keyframes tick{to{transform:rotate(360deg)}}
@media(min-width:900px){ .fab{inset-inline-start:auto;inset-inline-end:24px;bottom:24px} }

.dial-bg{position:fixed;inset:0;background:rgba(13,65,69,.55);backdrop-filter:blur(4px);
  z-index:75;display:none}
.dial-bg.on{display:block}
.dial{position:fixed;inset:0;z-index:76;display:none;place-items:center;touch-action:none;
  direction:ltr}
.dial.on{display:grid}

.dial-face{position:relative;width:min(92vw,392px);height:min(92vw,392px);border-radius:50%;
  background:var(--surface);border:1px solid var(--line);
  box-shadow:0 24px 60px rgba(13,65,69,.32);touch-action:none;user-select:none}
.dial-face svg.face{position:absolute;inset:0;width:100%;height:100%;pointer-events:none}

.dial-ring{position:absolute;inset:0;will-change:transform}
.dial-item{position:absolute;left:50%;top:50%;
  width:clamp(52px,15.5vw,66px);height:clamp(52px,15.5vw,66px);
  border-radius:20px;background:var(--teal-soft);border:1px solid var(--line);
  display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;
  cursor:pointer;padding:0;transition:background .15s,border-color .15s}
.dial-item svg{width:clamp(16px,4.6vw,20px);height:clamp(16px,4.6vw,20px);
  stroke:var(--teal);fill:none;stroke-width:1.8;
  stroke-linecap:round;stroke-linejoin:round}
.dial-item b{font-size:clamp(8.5px,2.6vw,10.5px);font-weight:500;line-height:1.2;
  text-align:center;max-width:90%;direction:rtl}
.dial-item.hot{background:var(--teal);border-color:var(--teal);
  box-shadow:0 6px 18px rgba(46,125,50,.35)}
.dial-item.hot svg{stroke:#fff}
.dial-item.hot b{color:#fff}

.dial-hub{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);
  width:clamp(86px,26vw,116px);height:clamp(86px,26vw,116px);border-radius:50%;
  background:var(--teal);color:#fff;
  display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;
  box-shadow:0 8px 22px rgba(13,65,69,.3);text-align:center;padding:10px;direction:rtl}
.dial-hub b{font-size:13px;font-weight:500}
.dial-hub span{font-size:9.5px;opacity:.85;line-height:1.5}

.dial-marker{position:absolute;left:50%;top:6px;transform:translateX(-50%);
  width:0;height:0;border-inline-start:7px solid transparent;border-inline-end:7px solid transparent;
  border-top:9px solid var(--saffron)}
.dial-close{position:fixed;bottom:32px;left:0;right:0;margin:0 auto;width:max-content;z-index:77}
@media(min-width:900px){ .dial-face{width:420px;height:420px} }

/* ---------------- جمع‌وجور کردن هدر روی نمایشگر باریک ---------------- */
.topbar{flex-wrap:nowrap}
.topbar .brand{white-space:nowrap}
@media (max-width:430px){
  .topbar .date{display:none}
  .topbar .icon-btn{width:34px;height:34px;border-radius:11px}
  .topbar .icon-btn svg{width:17px;height:17px}
  .topbar .mode-btn{padding:5px 9px;font-size:11px}
  .topbar .brand{font-size:17px}
  .brand-logo{width:25px;height:25px;flex:0 0 25px}
}
@media (max-width:340px){
  .topbar .brand{display:none}
}

@media (min-width:900px){
  .quick{left:82px}
}

/* ---------------- آگهی مربیان ---------------- */
.ad{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg);
  padding:14px;margin-bottom:10px}
.ad-head{display:flex;align-items:flex-start;gap:11px;margin-bottom:9px}
.ad-head .av{width:46px;height:46px;border-radius:15px;background:var(--teal-soft);color:var(--teal);
  display:grid;place-items:center;font-weight:500;font-size:19px;flex:0 0 46px}
.ad-head .n{flex:1;min-width:0}
.ad-head .n b{display:block;font-weight:500;font-size:15px}
.ad-head .n span{font-size:11.5px;color:var(--muted)}
.ad-line{font-size:13px;line-height:1.9;margin:2px 0 10px}
.ad-tags{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:10px}
.ad-tag{font-size:11px;padding:3px 10px;border-radius:99px;background:var(--teal-soft);color:var(--teal)}
.ad-stats{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;
  background:#FAFCFC;border-radius:var(--r-md);padding:10px;margin-bottom:10px}
.ad-stats div{text-align:center}
.ad-stats b{display:block;font-family:'Morabba','Vazirmatn';font-size:18px;line-height:1.3}
.ad-stats span{font-size:10.5px;color:var(--muted)}
.ad-badge{font-size:10.5px;padding:2px 9px;border-radius:99px}
.ad-badge.open{background:var(--ok-soft);color:var(--ok)}
.ad-badge.full{background:var(--danger-soft);color:var(--danger)}
.ad-note{font-size:11.5px;color:var(--muted);line-height:1.9;
  border-inline-start:3px solid var(--line);padding:6px 10px;margin-bottom:10px;background:#FAFCFC}

/* ---------------- تقویم و ساعت ---------------- */
.clockcard{display:flex;align-items:center;gap:14px;background:linear-gradient(135deg,var(--teal),#4C9A51);
  color:#fff;border-radius:var(--r-lg);padding:15px;margin-bottom:12px}
.clockcard .t{font-family:'Morabba','Vazirmatn';font-size:34px;line-height:1;letter-spacing:1px;
  font-variant-numeric:tabular-nums}
.clockcard .n{flex:1;min-width:0}
.clockcard .n b{display:block;font-weight:500;font-size:14.5px}
.clockcard .n span{font-size:11.5px;opacity:.88}

/* ---------------- شعر روز ---------------- */
.quote{background:var(--surface);border:1px solid var(--line);border-inline-start:4px solid var(--saffron);
  border-radius:var(--r-md);padding:13px 15px;margin-bottom:12px}
.quote p{margin:0 0 6px;font-size:14px;line-height:2.1;white-space:pre-line}
.quote span{font-size:11.5px;color:var(--muted)}

/* ---------------- کارها ---------------- */
.todo{display:flex;align-items:flex-start;gap:11px;padding:11px 12px;background:var(--surface);
  border:1px solid var(--line);border-radius:var(--r-md);margin-bottom:8px}
.todo .n{flex:1;min-width:0}
.todo .n b{display:block;font-weight:500;font-size:14px;line-height:1.7}
.todo .n span{font-size:11.5px;color:var(--muted)}
.todo.done .n b{text-decoration:line-through;color:var(--muted)}
.todo.late{border-color:var(--danger)}
.todo.late .n span{color:var(--danger)}

/* ---------------- نمودار روند ---------------- */
.trend{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg);
  padding:14px;margin-bottom:10px}
.trend-head{display:flex;align-items:baseline;gap:8px;margin-bottom:4px}
.trend-head b{font-weight:500}
.trend-head .d{margin-inline-start:auto;font-size:12.5px;font-weight:500}
.trend-head .d.up{color:var(--danger)}
.trend-head .d.down{color:var(--ok)}
.trend svg{width:100%;height:96px;display:block;overflow:visible}
.trend .lbl{display:flex;justify-content:space-between;font-size:10.5px;color:var(--muted);margin-top:4px}

/* ---------------- اعلام نیاز ---------------- */
.need{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg);
  padding:14px;margin-bottom:10px}
.need-head{display:flex;align-items:center;gap:9px;margin-bottom:7px}
.need-head b{font-weight:500;font-size:14.5px;flex:1;min-width:0}
.need .body{font-size:13px;line-height:1.95;color:var(--muted);margin-bottom:9px}
.need .meta{display:flex;flex-wrap:wrap;gap:7px}
.budget{font-size:11.5px;padding:3px 10px;border-radius:99px;background:var(--saffron-soft);color:var(--saffron)}

/* ---------------- جستجوی سراسری ---------------- */
.sr{display:flex;align-items:center;gap:11px;padding:11px 12px;background:var(--surface);
  border:1px solid var(--line);border-radius:var(--r-md);margin-bottom:7px;cursor:pointer}
.sr .ic{width:32px;height:32px;border-radius:10px;background:var(--teal-soft);display:grid;
  place-items:center;flex:0 0 32px}
.sr .ic svg{width:16px;height:16px;stroke:var(--teal);fill:none;stroke-width:1.8;
  stroke-linecap:round;stroke-linejoin:round}
.sr .n{flex:1;min-width:0}
.sr .n b{display:block;font-weight:500;font-size:14px}
.sr .n span{font-size:11px;color:var(--muted)}

/* ---------------- ستاره و نظر ---------------- */
.stars{display:inline-flex;gap:2px;direction:ltr}
.stars svg{width:14px;height:14px;fill:var(--line);stroke:none}
.stars svg.on{fill:var(--saffron)}
.stars.lg svg{width:20px;height:20px}
.rate-row{display:flex;align-items:center;gap:8px}
.rate-row .avg{font-family:'Morabba','Vazirmatn';font-size:22px;line-height:1}
.rate-row .cnt{font-size:11.5px;color:var(--muted)}

.starpick{display:flex;gap:6px;direction:ltr;justify-content:center;margin:6px 0 14px}
.starpick button{padding:4px}
.starpick svg{width:32px;height:32px;fill:var(--line);stroke:none;transition:fill .12s}
.starpick button.on svg{fill:var(--saffron)}

.review{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-md);
  padding:12px;margin-bottom:8px}
.review .h{display:flex;align-items:center;gap:8px;margin-bottom:5px}
.review .h b{font-weight:500;font-size:13.5px}
.review .h .d{margin-inline-start:auto;font-size:11px;color:var(--muted)}
.review p{margin:0;font-size:13px;line-height:1.95}
.review .rep{margin-top:9px;padding:9px 11px;background:var(--teal-soft);border-radius:var(--r-sm);
  font-size:12.5px;line-height:1.9}
.review .rep b{display:block;font-weight:500;margin-bottom:2px;font-size:11.5px;color:var(--teal)}
.dist-row{display:flex;align-items:center;gap:8px;font-size:11.5px;margin-bottom:4px}
.dist-row .bar-bg{flex:1;height:6px}

/* ---------------- مسکات کوشی ---------------- */
.mascot-btn{position:fixed;inset-inline-end:14px;bottom:calc(var(--nav-h) + 84px);z-index:54;
  width:58px;height:58px;border-radius:50%;padding:0;border:2px solid var(--surface);
  box-shadow:0 8px 22px rgba(13,65,69,.26);overflow:visible;background:var(--teal-soft)}
.mascot-btn img{width:100%;height:100%;border-radius:50%;object-fit:cover;display:block}
.mascot-btn .pulse{position:absolute;inset:-4px;border-radius:50%;border:2px solid var(--teal);
  opacity:.5;animation:mpulse 2.8s ease-out infinite;pointer-events:none}
@keyframes mpulse{0%{transform:scale(1);opacity:.45}70%{transform:scale(1.22);opacity:0}100%{opacity:0}}
@media (prefers-reduced-motion:reduce){ .mascot-btn .pulse{animation:none;opacity:.3} }
@media (min-width:900px){ .mascot-btn{inset-inline-end:24px;bottom:92px} }

.mrow{display:flex;gap:10px;align-items:flex-start;margin-bottom:6px}
.mface{width:46px;height:46px;border-radius:50%;object-fit:cover;flex:0 0 46px;
  border:2px solid var(--teal-soft)}
.mbub{flex:1;min-width:0;background:var(--teal-soft);border-radius:18px 18px 18px 5px;
  padding:12px 14px;font-size:13.5px;line-height:2}
.mbub .mx{margin-top:8px;font-size:12px;color:var(--muted)}

.mhero{text-align:center;margin-bottom:12px}
.mhero img{width:150px;height:150px;border-radius:50%;object-fit:cover;
  border:3px solid var(--teal-soft);box-shadow:0 10px 30px rgba(13,65,69,.14)}

.flist{margin-top:14px}
.fitem{display:flex;gap:10px;align-items:flex-start;padding:9px 0;border-top:1px dashed var(--line)}
.fitem:first-child{border-top:none}
.fitem .ic{width:30px;height:30px;border-radius:10px;background:var(--teal-soft);
  display:grid;place-items:center;flex:0 0 30px}
.fitem .ic svg{width:16px;height:16px;stroke:var(--teal);fill:none;stroke-width:1.8;
  stroke-linecap:round;stroke-linejoin:round}
.fitem .n b{display:block;font-weight:500;font-size:13.5px}
.fitem .n span{font-size:11.5px;color:var(--muted);line-height:1.8}

.mgrid{display:grid;grid-template-columns:1fr 1fr;gap:9px;margin-top:14px}
.mcard{position:relative;background:var(--surface);border:1px solid var(--line);
  border-radius:var(--r-md);padding:13px 11px;display:flex;flex-direction:column;
  align-items:center;gap:6px;text-align:center;min-height:86px}
.mcard svg{width:20px;height:20px;stroke:var(--teal);fill:none;stroke-width:1.8;
  stroke-linecap:round;stroke-linejoin:round}
.mcard b{font-weight:500;font-size:12.5px;line-height:1.4}
.mcard.done{border-color:var(--teal);background:var(--teal-soft)}
.mcard .tick{font-size:9.5px;color:var(--teal)}
@media(min-width:700px){ .mgrid{grid-template-columns:repeat(3,1fr)} }

.mdots{display:flex;gap:5px}
.mdots i{height:4px;flex:1;border-radius:99px;background:var(--line)}
.mdots i.on{background:var(--teal)}

.mission{margin-top:16px;background:var(--saffron-soft);
  border:1px dashed var(--saffron);border-radius:var(--r-md);padding:13px}
.mission b{display:block;font-weight:500;font-size:12.5px;color:var(--saffron);margin-bottom:3px}
.mission p{margin:0 0 10px;font-size:13.5px;line-height:1.9}

/* پرسشنامه سلیقه */
.tpick{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.tp{position:relative;background:var(--surface);border:1.5px solid var(--line);
  border-radius:var(--r-md);padding:11px 10px;text-align:start;min-height:58px}
.tp b{display:block;font-weight:500;font-size:13px;line-height:1.5}
.tp span{font-size:10.5px;color:var(--muted)}
.tp .mark{position:absolute;top:7px;inset-inline-end:8px;font-style:normal;font-size:13px}
.tp.love{border-color:var(--teal);background:var(--teal-soft)}
.tp.love .mark::after{content:'♥';color:var(--teal)}
.tp.never{border-color:var(--danger);background:var(--danger-soft);opacity:.85}
.tp.never .mark::after{content:'✕';color:var(--danger)}
.tp.never b{text-decoration:line-through}
@media(min-width:700px){ .tpick{grid-template-columns:repeat(3,1fr)} }

/* ---------------- لوگوی قابل کلیک با نوار فعال ---------------- */
.brandbtn{position:relative;display:inline-flex;align-items:center;gap:7px;
  padding:2px 4px 7px;border-radius:12px;background:none;border:none}
.brandbtn .brand{font-family:'Morabba','Vazirmatn';font-size:20px;font-weight:700;
  line-height:1.4;white-space:nowrap}
.brandbtn .brandbar{position:absolute;bottom:1px;inset-inline:5px;height:3px;border-radius:99px;
  background:linear-gradient(90deg,var(--teal),var(--saffron));
  background-size:200% 100%;animation:brandslide 3.2s ease-in-out infinite}
.brandbtn:active{background:var(--teal-soft)}
@keyframes brandslide{
  0%{background-position:0% 50%;opacity:.55}
  50%{background-position:100% 50%;opacity:1}
  100%{background-position:0% 50%;opacity:.55}
}
@media (prefers-reduced-motion:reduce){ .brandbtn .brandbar{animation:none;opacity:.8} }
@media (max-width:430px){ .brandbtn .brand{font-size:17px} }
@media (max-width:340px){ .brandbtn .brand{display:none} }

/* ---------------- نتیجه پرسشنامه ---------------- */
.tres{display:grid;grid-template-columns:1fr 1fr;gap:9px;margin:14px 0}
.tres div{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-md);
  padding:13px;text-align:center}
.tres b{display:block;font-family:'Morabba','Vazirmatn';font-size:26px;line-height:1.3}
.tres span{font-size:11px;color:var(--muted)}
.tres div.love{border-color:var(--teal);background:var(--teal-soft)}
.tres div.never{border-color:var(--danger);background:var(--danger-soft)}
.tsum{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:12px}
.tsum span{font-size:11px;padding:3px 10px;border-radius:99px;background:var(--teal-soft);color:var(--teal)}
.tsum span.no{background:var(--danger-soft);color:var(--danger)}
.nextup{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg);
  padding:14px;margin-top:14px}
.nextup .h{display:flex;align-items:center;gap:9px;margin-bottom:8px}
.nextup .h svg{width:19px;height:19px;stroke:var(--teal);fill:none;stroke-width:1.8;
  stroke-linecap:round;stroke-linejoin:round}
.nextup .h b{font-weight:500}
.nextup p{margin:0 0 11px;font-size:12.5px;color:var(--muted);line-height:1.9}

/* هنگام باز بودن هر پنجره، دکمه‌های شناور کنار می‌روند تا روی محتوا نیفتند */
.fab, .mascot-btn{transition:opacity .18s ease, transform .18s ease}
body.overlay-on .fab,
body.overlay-on .mascot-btn{opacity:0;transform:scale(.72);pointer-events:none}

/* ---------------- کارت امتیاز مأموریت ---------------- */
.xpcard{display:flex;gap:12px;align-items:stretch;background:var(--surface);
  border:1px solid var(--line);border-radius:var(--r-lg);padding:13px;margin:14px 0}
.xpcard .g{flex:0 0 96px;background:var(--saffron-soft);border-radius:var(--r-md);
  display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;padding:8px}
.xpcard .g b{font-family:'Morabba','Vazirmatn';font-size:26px;line-height:1.1;color:var(--saffron)}
.xpcard .g span{font-size:10px;color:var(--muted);text-align:center;line-height:1.5}
.xpcard .t{flex:1;min-width:0;display:flex;flex-direction:column;justify-content:center}
.xpcard .t b{font-family:'Morabba','Vazirmatn';font-size:19px}

/* کاغذرنگی جشن */
#confetti{position:fixed;inset:0;z-index:95;pointer-events:none}

/* ---------------- حالت تایپ کردن کوشا ---------------- */
.mbub.typing{min-height:44px}
.mbub .dots{display:inline-flex;gap:4px;align-items:center;padding:4px 0}
.mbub .dots i{width:7px;height:7px;border-radius:50%;background:var(--teal);opacity:.35;
  animation:tdot 1.1s ease-in-out infinite}
.mbub .dots i:nth-child(2){animation-delay:.18s}
.mbub .dots i:nth-child(3){animation-delay:.36s}
@keyframes tdot{0%,60%,100%{transform:translateY(0);opacity:.35}
  30%{transform:translateY(-4px);opacity:.9}}
.mbub .caret{display:inline-block;width:2px;height:15px;background:var(--teal);
  vertical-align:-2px;margin-inline-start:2px;animation:tcaret .7s steps(1) infinite}
@keyframes tcaret{0%,50%{opacity:1}51%,100%{opacity:0}}
.mbub.typed{animation:bubin .18s ease-out}
@keyframes bubin{from{transform:scale(.99)}to{transform:scale(1)}}
@media (prefers-reduced-motion:reduce){
  .mbub .dots i, .mbub .caret{animation:none}
  .mbub .caret{display:none}
}

/* ---------------- تقویم شمسی ---------------- */
.jp-bg{position:fixed;inset:0;background:rgba(13,65,69,.42);z-index:84;display:none}
.jp-bg.on{display:block}
.jp-wrap{position:fixed;inset:0;z-index:85;display:none;place-items:center;padding:16px}
.jp-wrap.on{display:grid}
.jp-card{width:min(380px,100%);max-height:88vh;overflow-y:auto;background:var(--surface);
  border-radius:22px;padding:16px;box-shadow:0 24px 60px rgba(13,65,69,.3)}
.jp-bar{display:flex;align-items:center;gap:10px;margin-bottom:12px}
.jp-bar b{font-weight:500;font-size:15px}
.jdate{display:flex;align-items:center;gap:9px;width:100%;padding:11px 12px;
  border-radius:var(--r-md);border:1px solid var(--line);background:var(--surface);
  font-family:inherit;font-size:15px;text-align:start;cursor:pointer}
.jdate .v{flex:1;min-width:0}
.jdate .p{flex:1;min-width:0;color:var(--muted)}
.jdate svg{width:18px;height:18px;stroke:var(--teal);fill:none;stroke-width:1.7;
  stroke-linecap:round;stroke-linejoin:round;flex:0 0 18px}
.jdate:active{background:var(--teal-soft)}

.jp-head{display:flex;align-items:center;gap:10px;margin-bottom:12px}
.jp-title{flex:1;display:flex;gap:7px}
.jp-title select{flex:1;padding:9px 10px;border-radius:12px;border:1px solid var(--line);
  background:var(--surface);font-family:inherit;font-size:14.5px}
.jp-week{display:grid;grid-template-columns:repeat(7,1fr);gap:4px;margin-bottom:5px}
.jp-week span{text-align:center;font-size:11.5px;color:var(--muted);padding:4px 0}
.jp-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:4px}
.jp-grid button{aspect-ratio:1;border-radius:12px;border:1px solid transparent;
  background:var(--surface);font-family:inherit;font-size:14.5px;
  font-variant-numeric:tabular-nums;display:grid;place-items:center}
.jp-grid button:active{background:var(--teal-soft)}
.jp-grid button.today{border-color:var(--saffron);color:var(--saffron);font-weight:500}
.jp-grid button.sel{background:var(--teal);color:#fff;border-color:var(--teal);font-weight:500}
.jp-grid span{aspect-ratio:1}

/* ---------------- کارت معرف در صفحه ثبت‌نام ---------------- */
.refcard{display:flex;align-items:center;gap:12px;background:var(--teal-soft);
  border-radius:var(--r-lg);padding:13px;margin-bottom:14px}
.refcard .av{width:46px;height:46px;border-radius:15px;background:var(--teal);color:#fff;
  display:grid;place-items:center;font-weight:500;font-size:19px;flex:0 0 46px}
.refcard .n b{display:block;font-weight:500;font-size:15px}
.refcard .n span{font-size:12px;color:var(--muted)}
.auth .lead{color:var(--muted);font-size:13.5px;line-height:2;margin:0 0 16px}

/* ---------------- اتاق فرار ---------------- */
.esc-hero{display:flex;align-items:center;gap:14px;border-radius:var(--r-lg);padding:16px;
  margin-bottom:12px;color:#fff;background:linear-gradient(135deg,#123A1E,#2E7D32)}
.esc-hero .lock{font-size:36px}
.esc-hero .n b{display:block;font-weight:500;font-size:16px;margin-bottom:3px}
.esc-hero .n span{font-size:12px;opacity:.9;line-height:1.8}

.esc-bar{display:flex;align-items:center;gap:12px;background:var(--surface);
  border:1px solid var(--line);border-radius:var(--r-md);padding:11px 13px;margin-bottom:10px}
.esc-bar .t{font-family:'Morabba','Vazirmatn';font-size:24px;line-height:1;color:var(--teal)}
.esc-bar .s{font-size:12.5px;color:var(--muted)}

.esc-steps{display:flex;gap:6px;margin-bottom:12px}
.esc-steps i{flex:1;height:5px;border-radius:99px;background:var(--line)}
.esc-steps i.on{background:var(--saffron)}
.esc-steps i.done{background:var(--teal)}

.esc-prompt{font-size:14.5px;line-height:2.1;white-space:pre-line;margin-bottom:10px}
.esc-scene{background:#FAFCFC;border:1px solid var(--line);border-radius:var(--r-md);
  padding:8px;margin-bottom:6px}
.esc-scene svg{width:100%;height:auto;display:block;aspect-ratio:1}

.esc-coded{font-family:'Morabba','Vazirmatn';font-size:30px;text-align:center;
  letter-spacing:6px;padding:16px;background:var(--teal-soft);border-radius:var(--r-md);
  margin-bottom:10px;color:var(--teal)}
.esc-ab{display:grid;grid-template-columns:repeat(8,1fr);gap:4px}
.esc-ab span{background:var(--surface);border:1px solid var(--line);border-radius:9px;
  padding:5px 2px;text-align:center}
.esc-ab b{display:block;font-size:14px;font-weight:500}
.esc-ab i{font-style:normal;font-size:9.5px;color:var(--muted)}

.esc-code{font-family:'Morabba','Vazirmatn';font-size:38px;text-align:center;
  letter-spacing:8px;color:var(--teal);padding:10px 0 4px;direction:ltr}

.esc-role{display:flex;gap:11px;align-items:flex-start;background:var(--saffron-soft);
  border:1px dashed var(--saffron);border-radius:var(--r-md);padding:12px;margin-bottom:10px}
.esc-role .ic{font-size:24px}
.esc-role .n b{display:block;font-weight:500;font-size:14px}
.esc-role .n span{font-size:12px;color:var(--muted);line-height:1.9}

.esc-win{text-align:center;padding:26px 18px;border-radius:var(--r-lg);
  background:linear-gradient(135deg,var(--teal),#4C9A51);color:#fff;margin-bottom:12px}
.esc-win.lose{background:linear-gradient(135deg,#6E8B8D,#93A9AA)}
.esc-win .lock{font-size:48px}
.esc-win b{display:block;font-size:19px;font-weight:500;margin:6px 0}
.esc-win .t{font-family:'Morabba','Vazirmatn';font-size:38px;line-height:1.2}
.esc-win span{font-size:12.5px;opacity:.92}

/* ---------------- نکته گیاهان ---------------- */
.tip{background:var(--surface);border:1px solid var(--line);
  border-inline-start:4px solid #4C9A51;border-radius:var(--r-md);
  padding:12px 14px;margin-bottom:12px}
.tip-herb{border-inline-start-color:#2E7D32}
.tip-plant{border-inline-start-color:#4C9A51}
.tip-props{border-inline-start-color:var(--saffron)}
.tip-props .h b{color:var(--saffron)}
.tip-tabs{display:flex;flex-wrap:wrap;gap:5px;align-items:center;margin-top:9px;
  padding-top:8px;border-top:1px dashed var(--line)}
.tip-tabs button{font-size:10.5px;padding:3px 9px;border-radius:99px;
  background:var(--porcelain);color:var(--muted);border:1px solid transparent}
.tip-tabs button:active{background:var(--teal-soft);color:var(--teal)}
.tip-tabs .all{font-size:10px;color:var(--muted);margin-inline-start:auto}
.tip .h{display:flex;align-items:center;gap:7px;margin-bottom:6px}
.tip .h .ic{font-size:15px}
.tip .h b{font-weight:500;font-size:12.5px;color:var(--teal)}
.tip .h .no{font-size:10.5px;color:var(--muted);margin-inline-start:auto}
.tip .h .next{width:26px;height:26px;border-radius:8px;background:var(--teal-soft);
  color:var(--teal);font-size:14px;line-height:1;display:grid;place-items:center;flex:0 0 26px}
.tip .h .next.spin{animation:tipspin .6s linear infinite}
@keyframes tipspin{to{transform:rotate(360deg)}}
.tip p{margin:0;font-size:13.5px;line-height:2.05}

/* ---------------- آرزوها ---------------- */
.wish-hero{display:flex;gap:13px;align-items:flex-start;border-radius:var(--r-lg);
  padding:16px;margin-bottom:12px;color:#fff;
  background:linear-gradient(135deg,#6A3AB2,#2E7D32)}
.wish-hero .star{font-size:32px;line-height:1}
.wish-hero .n b{display:block;font-weight:500;font-size:15.5px;margin-bottom:4px}
.wish-hero .n span{font-size:12px;opacity:.92;line-height:1.9}

.wish-stats{display:grid;grid-template-columns:repeat(3,1fr);gap:9px;margin-bottom:12px}
.wish-stats div{background:var(--surface);border:1px solid var(--line);
  border-radius:var(--r-md);padding:12px;text-align:center}
.wish-stats b{display:block;font-family:'Morabba','Vazirmatn';font-size:23px;line-height:1.3}
.wish-stats span{font-size:10.5px;color:var(--muted)}
.wish-stats .hot{border-color:var(--saffron);background:var(--saffron-soft)}
.wish-stats .hot b{color:var(--saffron)}
.wish-stats .ok{border-color:var(--teal);background:var(--teal-soft)}
.wish-stats .ok b{color:var(--teal)}

.badges{display:flex;flex-wrap:wrap;gap:6px;margin-top:10px}
.badge{font-size:11px;padding:4px 10px;border-radius:99px;
  background:var(--saffron-soft);color:var(--saffron);border:1px solid var(--saffron)}

.wish{display:flex;gap:11px;background:var(--surface);border:1px solid var(--line);
  border-radius:var(--r-lg);padding:13px;margin-bottom:9px}
.wish.done{border-color:var(--teal);background:var(--teal-soft)}
.wish.doing,.wish.planned{border-color:var(--saffron)}
.wish.pin{box-shadow:0 4px 18px rgba(200,137,15,.16)}
.wish .vote{flex:0 0 50px;display:flex;flex-direction:column;align-items:center;
  justify-content:center;gap:1px;border-radius:14px;border:1px solid var(--line);
  background:var(--porcelain);padding:7px 0;align-self:flex-start}
.wish .vote i{font-style:normal;font-size:11px;color:var(--muted)}
.wish .vote b{font-family:'Morabba','Vazirmatn';font-size:17px}
.wish .vote.on{background:var(--teal);border-color:var(--teal);color:#fff}
.wish .vote.on i{color:#fff}
.wish .n{flex:1;min-width:0}
.wish .t{display:flex;align-items:center;gap:7px}
.wish .t b{font-weight:500;font-size:14.5px;line-height:1.7}
.wish .pinned{font-size:9.5px;padding:2px 7px;border-radius:99px;
  background:var(--saffron-soft);color:var(--saffron)}
.wish p{margin:5px 0 8px;font-size:12.5px;color:var(--muted);line-height:1.95}
.wish .meta{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:8px}
.wstat{font-size:11px;padding:3px 10px;border-radius:99px;background:var(--porcelain)}
.wstat.s3,.wstat.s4{background:var(--saffron-soft);color:var(--saffron)}
.wstat.s5{background:var(--ok-soft);color:var(--ok)}
.wsteps{display:flex;gap:4px;margin-bottom:7px}
.wsteps i{flex:1;height:4px;border-radius:99px;background:var(--line)}
.wsteps i.on{background:var(--teal)}
.vbar{height:4px;border-radius:99px;background:var(--line);overflow:hidden}
.vbar i{display:block;height:100%;border-radius:99px;
  background:linear-gradient(90deg,#6A3AB2,var(--teal))}
.wnote{margin-top:9px;padding:9px 11px;background:var(--teal-soft);border-radius:var(--r-sm);
  font-size:12.5px;line-height:1.9}
.wnote b{display:block;font-weight:500;font-size:11.5px;color:var(--teal);margin-bottom:2px}

/* ---------------- سرمایه و بازار ---------------- */
.up{color:var(--ok)}
.down{color:var(--danger)}
.cap-hero{display:flex;align-items:center;gap:12px;border-radius:var(--r-lg);padding:14px;
  margin-bottom:12px;color:#fff;background:linear-gradient(135deg,#123A1E,#17797E)}
.cap-hero .n{flex:1;min-width:0}
.cap-hero .n b{display:block;font-weight:500;font-size:15px}
.cap-hero .n span{font-size:11.5px;opacity:.9}
.cap-hero .btn{background:rgba(255,255,255,.2);color:#fff}

.quote{display:flex;align-items:center;gap:11px;background:var(--surface);
  border:1px solid var(--line);border-radius:var(--r-md);padding:12px;margin-bottom:8px}
.quote .n{flex:1;min-width:0}
.quote .n b{display:block;font-weight:500;font-size:14px}
.quote .n span{font-size:10.5px;color:var(--muted)}
.quote .spark{width:60px;height:26px;flex:0 0 60px}
.quote .p{text-align:end;flex:0 0 auto}
.quote .p b{display:block;font-family:'Morabba','Vazirmatn';font-size:17px;line-height:1.3}
.quote .p .u{font-size:10px;color:var(--muted)}
.quote .p .ch{display:block;font-size:11px}

.cap-price{text-align:center;padding:6px 0 2px}
.cap-price b{font-family:'Morabba','Vazirmatn';font-size:34px}
.cap-price span{font-size:12px;color:var(--muted);margin-inline-start:6px}
.cap-chg{display:flex;justify-content:center;gap:14px;font-size:12px;margin-bottom:10px}
.cap-chart{width:100%;height:110px;display:block}

.riskbar{display:flex;gap:5px}
.riskbar button{flex:1;height:10px;border-radius:99px;background:var(--line);border:none}

.scen{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-lg);
  padding:14px;margin-bottom:10px}
.scen.safe{border-inline-start:4px solid #2E7D32}
.scen.balanced{border-inline-start:4px solid #C8890F}
.scen.bold{border-inline-start:4px solid #B3261E}
.scen .h{display:flex;align-items:center;gap:9px;margin-bottom:10px}
.scen .h .ic{font-size:20px}
.scen .h b{flex:1;font-weight:500;font-size:15px}
.scen .rk{font-size:10.5px;color:#fff;padding:3px 9px;border-radius:99px}
.sgrid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;margin-bottom:12px}
.sgrid div{background:#FAFCFC;border-radius:var(--r-sm);padding:9px;text-align:center}
.sgrid span{display:block;font-size:10px;color:var(--muted);margin-bottom:3px}
.sgrid b{font-family:'Morabba','Vazirmatn';font-size:16px}
.alloc{margin-bottom:9px}
.alloc .t{display:flex;justify-content:space-between;align-items:baseline;margin-bottom:4px}
.alloc .t b{font-weight:500;font-size:13px}
.alloc .t span{font-size:11px;color:var(--muted)}
.alloc .bar{height:7px;border-radius:99px;background:var(--line);overflow:hidden}
.alloc .bar i{display:block;height:100%;border-radius:99px}
.alloc .pro{margin-top:4px;font-size:10.5px}

.hold{background:var(--surface);border:1px solid var(--line);border-radius:var(--r-md);
  padding:12px;margin-bottom:8px}
.hold.closed{opacity:.72;border-style:dashed}
.hold .h{display:flex;justify-content:space-between;align-items:baseline;gap:8px}
.hold .h b{font-weight:500;font-size:14px}

.news{display:block;background:var(--surface);border:1px solid var(--line);
  border-radius:var(--r-md);padding:12px;margin-bottom:8px;color:inherit;text-decoration:none}
.news .n b{display:block;font-weight:500;font-size:13.5px;line-height:1.8}
.news .n span{font-size:10.5px;color:var(--muted)}
.news .tags{display:flex;flex-wrap:wrap;gap:5px;margin-top:7px}
.news .tags span{font-size:10px;padding:2px 8px;border-radius:99px;
  background:var(--teal-soft);color:var(--teal)}
