@font-face{font-family:Dana;src:url('/font.woff2') format('woff2');font-display:swap}

/* ---------- Tokens (light; dark below) ---------- */
:root{
  color-scheme:light;
  --bg:#f3f5f9;--surface:#ffffff;--surface-2:#edf1f7;--ink:#0b1730;--muted:#55617a;--line:#e0e5ee;--line-strong:#ccd3e1;
  --brand:#081226;--brand-hi:#14305c;--brand-2:#047857;--accent-hover:#065f46;--on-accent:#ffffff;--on-brand:#f5f8ff;--brand-muted:#a9b6d0;--emerald:#10b981;
  --gold:#b45309;--gold-bright:#fbbf24;--gold-soft:#fef3c7;
  --success:#047857;--success-soft:#d1fae5;--warn:#a35a00;--warn-soft:#fdf0d5;--danger:#b42318;--danger-soft:#fde8e6;
  --ring:#059669;--shadow-sm:0 1px 2px #0812260f;--shadow:0 10px 30px #08122614;--shadow-lg:0 30px 80px #08122640;
  --c-math:#b0773c;--c-bio:#4f8a68;--c-physics:#5b7fa8;--c-chem:#9a6f97;--c-general:#a08743;--c-analysis:#b45309;
  --radius:14px;--radius-sm:10px;--tap:44px;--ease:cubic-bezier(.2,.7,.2,1);
  --tabbar-h:64px;
}
@media (prefers-color-scheme:dark){:root{
  color-scheme:dark;
  --bg:#081226;--surface:#0e1c38;--surface-2:#142647;--ink:#e7edf8;--muted:#9aa8c3;--line:#1d3054;--line-strong:#2a4069;
  --brand:#050c1b;--brand-hi:#13305c;--brand-2:#10b981;--accent-hover:#34d399;--on-accent:#04241b;--on-brand:#f2f6ff;--brand-muted:#9aa8c3;--emerald:#10b981;
  --gold:#fbbf24;--gold-bright:#fbbf24;--gold-soft:#3a2c0a;
  --success:#34d399;--success-soft:#0d3329;--warn:#f59e0b;--warn-soft:#3a2a0c;--danger:#f87171;--danger-soft:#3b1518;
  --ring:#34d399;--shadow-sm:none;--shadow:0 10px 30px #0006;--shadow-lg:0 30px 80px #000b;
  --c-math:#d9a066;--c-bio:#7fbd98;--c-physics:#8eaed6;--c-chem:#c9a0c6;--c-general:#cdb36d;--c-analysis:#fbbf24;
}}

/* ---------- Base ---------- */
*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0;background:var(--bg);color:var(--ink);font-family:Dana,Tahoma,sans-serif;font-size:15px;line-height:1.8;-webkit-font-smoothing:antialiased}
button,input,select,textarea{font:inherit;color:inherit}
button{cursor:pointer;border:0;background:none;padding:0}
button:disabled{cursor:not-allowed}
a{color:inherit}
button,a,input,textarea,select,label{touch-action:manipulation;-webkit-tap-highlight-color:transparent}
:focus-visible{outline:2px solid var(--ring);outline-offset:2px}
h1,h2,h3,p{margin:0}
h1{font-size:30px;line-height:1.45;font-weight:800;letter-spacing:-.2px}
h2{font-size:19px;line-height:1.6;font-weight:700}
h3{font-size:16px;line-height:1.7;font-weight:700}
small,.muted{color:var(--muted)}
.icon{width:20px;height:20px;flex:none;stroke:currentColor;fill:none;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
.icon.sm{width:16px;height:16px}
.icon.lg{width:24px;height:24px}
.num{font-variant-numeric:tabular-nums}
.hidden{display:none!important}
.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}

/* ---------- Loading ---------- */
.loading{min-height:100vh;min-height:100dvh;display:grid;place-content:center;justify-items:center;gap:10px;text-align:center;font-size:24px;font-weight:800;padding:24px}
.loading small{font-size:14px;font-weight:400}
.loading:before{content:'';width:40px;height:40px;border-radius:50%;border:3px solid var(--line);border-top-color:var(--brand-2);animation:spin 1s linear infinite}
@keyframes spin{to{transform:rotate(360deg)}}

/* ---------- Buttons ---------- */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:var(--tap);padding:0 18px;border-radius:12px;background:var(--brand-2);color:var(--on-accent);font-size:14px;font-weight:700;white-space:nowrap;transition:background-color .18s var(--ease),transform .12s var(--ease),box-shadow .18s var(--ease);box-shadow:var(--shadow-sm)}
.btn:hover{background:var(--accent-hover)}
.btn:active{transform:scale(.97)}
.btn:disabled{opacity:.45;transform:none}
.btn.light{background:var(--surface);color:var(--ink);border:1px solid var(--line-strong);box-shadow:none}
.btn.light:hover{background:var(--surface-2)}
.btn.gold{background:var(--gold-bright);color:#1f1400}
.btn.danger{background:var(--danger);color:#fff}
.btn.ghost{background:transparent;color:var(--ink);box-shadow:none}
.btn.ghost:hover{background:var(--surface-2)}
.btn.small{min-height:38px;padding:0 13px;font-size:13px;border-radius:10px}
.btn.block{width:100%}
.icon-btn{display:inline-grid;place-items:center;width:var(--tap);height:var(--tap);border-radius:12px;color:var(--ink);transition:background-color .18s var(--ease)}
.icon-btn:hover{background:var(--surface-2)}
.btn.is-busy{position:relative;color:transparent!important}
.btn.is-busy:after{content:'';position:absolute;width:18px;height:18px;border-radius:50%;border:2px solid #fff6;border-top-color:#fff;animation:spin .8s linear infinite}

/* ---------- Badges, callouts ---------- */
.badge{display:inline-flex;align-items:center;gap:4px;font-size:12px;line-height:1.6;padding:2px 10px;border-radius:999px;background:var(--surface-2);color:var(--ink);white-space:nowrap;font-weight:600}
.badge .icon{width:14px;height:14px}
.badge.success{background:var(--success-soft);color:var(--success)}
.badge.amber{background:var(--warn-soft);color:var(--warn)}
.badge.red{background:var(--danger-soft);color:var(--danger)}
.badge.now{background:var(--brand-2);color:var(--on-accent)}
.callout{display:flex;gap:12px;align-items:flex-start;background:var(--gold-soft);border:1px solid color-mix(in srgb,var(--gold) 25%,transparent);color:var(--ink);border-radius:var(--radius-sm);padding:13px 16px;font-size:14px;margin-bottom:14px}
.callout .icon{color:var(--gold);margin-top:3px}
.callout.alert{background:var(--danger-soft);border-color:color-mix(in srgb,var(--danger) 25%,transparent)}
.callout.alert .icon{color:var(--danger)}
.callout.info{background:var(--surface-2);border-color:var(--line)}
.callout.info .icon{color:var(--muted)}
.eyebrow{font-size:13px;color:var(--gold);font-weight:700;margin-bottom:2px}
.note{font-size:13px;color:var(--muted);line-height:1.9}
.section-gap{margin-top:20px}
.source-link{display:inline-flex;align-items:center;gap:6px;font-size:13px;color:var(--gold);text-decoration:none;font-weight:600;min-height:var(--tap)}
.source-link:hover{text-decoration:underline}

/* ---------- Shell ---------- */
.shell{display:grid;grid-template-columns:256px minmax(0,1fr);min-height:100vh}
.sidebar{background:var(--brand);color:var(--on-brand);padding:28px 18px;position:sticky;top:0;height:100vh;display:flex;flex-direction:column}
.brand{font-size:25px;font-weight:800;line-height:1.4}
.brand span{color:var(--gold-bright)}
.brand-sub{font-size:12px;color:var(--brand-muted);margin-top:2px}
.profile{display:flex;align-items:center;gap:12px;margin:26px 0 20px;padding:16px 0;border-top:1px solid #ffffff1c;border-bottom:1px solid #ffffff1c}
.avatar{display:grid;place-items:center;width:44px;height:44px;flex:none;background:var(--gold-bright);color:#1f1400;border-radius:50%;font-size:20px;font-weight:800}
.profile strong{font-size:15px;display:block;line-height:1.5}
.nav{display:grid;gap:4px}
.nav button{display:flex;align-items:center;gap:12px;min-height:46px;padding:0 14px;border-radius:12px;color:var(--brand-muted);text-align:right;font-weight:600;transition:background-color .18s var(--ease),color .18s var(--ease)}
.nav button:hover{background:#ffffff10;color:var(--on-brand)}
.nav button.active{background:#ffffff1a;color:var(--on-brand);box-shadow:inset -3px 0 0 var(--gold-bright)}
.sidebar-foot{margin-top:auto;color:var(--brand-muted);font-size:12px;line-height:2}
.sidebar-foot button{display:inline-flex;align-items:center;gap:8px;color:var(--on-brand);min-height:var(--tap);margin-top:6px;font-weight:600}
.main{padding:28px 40px 48px;max-width:1440px;width:100%;margin:0 auto}
.topbar{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:22px}
.date-pill{display:inline-flex;align-items:center;gap:8px;font-size:14px;color:var(--muted);font-weight:600}
.online{width:8px;height:8px;background:var(--success);border-radius:50%;box-shadow:0 0 0 4px var(--success-soft)}
.top-actions{display:flex;gap:6px;align-items:center}
.mobile-brand{display:none}
.tabbar{display:none}

/* ---------- Page intro & day navigator ---------- */
.intro{display:flex;justify-content:space-between;align-items:flex-end;gap:20px;margin-bottom:20px}
.intro p{color:var(--muted);margin-top:4px}
.day-tools{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.day-nav{display:inline-flex;align-items:center;gap:2px;background:var(--surface);border:1px solid var(--line);border-radius:14px;padding:3px}
.day-nav .icon-btn{width:40px;height:40px}
.day-nav .day-range{padding:0 10px;font-size:13px;font-weight:700;color:var(--muted);white-space:nowrap}

/* ---------- Focus card (now / next) ---------- */
.focus{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:16px;background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);padding:18px 20px;margin-bottom:16px;box-shadow:var(--shadow)}
.focus-icon{display:grid;place-items:center;width:48px;height:48px;border-radius:14px;background:var(--success-soft);color:var(--success)}
.focus.alert .focus-icon{background:var(--danger-soft);color:var(--danger)}
.focus.next .focus-icon{background:var(--gold-soft);color:var(--gold)}
.focus h2{font-size:18px}
.focus p{font-size:14px;color:var(--muted)}
.focus .progress{margin:10px 0 0}

/* ---------- Hero ---------- */
.hero{background:linear-gradient(135deg,var(--brand) 0%,var(--brand-hi) 100%);color:var(--on-brand);border-radius:var(--radius);padding:22px 26px;display:grid;grid-template-columns:1fr auto;gap:22px;align-items:center;position:relative;overflow:hidden;margin-bottom:16px}
.hero:after{content:'';position:absolute;width:260px;height:260px;border:1px solid #ffffff14;border-radius:50%;left:-90px;top:-110px;pointer-events:none}
.hero .eyebrow{color:var(--gold-bright)}
.hero p{font-size:17px;line-height:2;max-width:900px}
.hero-stat{text-align:center;padding-right:22px;border-right:1px solid #ffffff26;min-width:110px}
.hero-stat strong{display:block;font-size:40px;line-height:1.1;font-weight:800}
.hero-stat small{color:var(--brand-muted);font-size:12px}

/* ---------- Metrics ---------- */
.metrics{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;margin-bottom:20px}
.metric{display:flex;gap:12px;align-items:flex-start;background:var(--surface);border:1px solid var(--line);border-radius:var(--radius-sm);padding:14px 16px}
.metric-icon{display:grid;place-items:center;width:36px;height:36px;border-radius:10px;background:var(--surface-2);color:var(--gold);flex:none}
.metric .label{font-size:12px;color:var(--muted);font-weight:600}
.metric .value{font-size:22px;font-weight:800;line-height:1.5}
.metric .value small{font-size:12px;font-weight:600}
.metric > div > small{font-size:12px;display:block;line-height:1.6}

/* ---------- Panels ---------- */
.workspace{display:grid;grid-template-columns:minmax(0,1.65fr) minmax(280px,1fr);gap:20px;align-items:start}
.panel{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);padding:20px;margin-bottom:18px;box-shadow:var(--shadow)}
.panel-header{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:16px}
.panel-header h2{font-size:18px}
.list-row{padding:13px 0;border-bottom:1px solid var(--line);font-size:14px}
.list-row:last-child{border-bottom:0}
.list-row .row-head{display:flex;justify-content:space-between;align-items:center;gap:10px}
.empty{text-align:center;padding:28px 10px;color:var(--muted)}
.empty .icon{width:32px;height:32px;color:var(--line-strong);margin-bottom:6px}
.empty h3{color:var(--ink);margin-bottom:4px}
.father-message{font-size:16px;line-height:2.1;margin:8px 0}
.signature{display:flex;align-items:center;gap:6px;color:var(--gold);font-size:13px;font-weight:700}
.grid2{display:grid;grid-template-columns:1fr 1fr;gap:20px;align-items:start}

/* ---------- Timeline ---------- */
.timeline{display:grid}
.task{display:grid;grid-template-columns:62px 1fr;gap:14px;position:relative;padding-bottom:12px}
.time{font-size:14px;text-align:center;padding-top:14px;font-weight:700;line-height:1.5}
.time small{display:block;font-size:12px;font-weight:500}
.task-card{--color:var(--gold);padding:14px 16px;background:var(--surface);border:1px solid var(--line);border-inline-start:4px solid var(--color);border-radius:12px;transition:border-color .18s var(--ease),box-shadow .18s var(--ease)}
[data-subject=math]{--color:var(--c-math)}[data-subject=bio]{--color:var(--c-bio)}[data-subject=physics]{--color:var(--c-physics)}[data-subject=chem]{--color:var(--c-chem)}[data-subject=general]{--color:var(--c-general)}[data-subject=analysis]{--color:var(--c-analysis)}
.task-card.complete{background:var(--success-soft)}
.task-card.overdue{border-color:color-mix(in srgb,var(--danger) 45%,var(--line));border-inline-start-color:var(--danger)}
.task-card.current{box-shadow:0 0 0 2px var(--color),var(--shadow)}
.task-head{display:flex;justify-content:space-between;align-items:center;gap:10px}
.task-head h3{display:flex;align-items:center;gap:8px}
.dot{width:9px;height:9px;border-radius:50%;background:var(--color);flex:none}
.task-body{font-size:13px;color:var(--muted);margin:6px 0 8px;line-height:1.9}
.task-foot{display:flex;justify-content:space-between;align-items:center;gap:8px}
.task-foot > small{display:inline-flex;align-items:center;gap:5px;font-size:12px}
.log-note{font-size:13px;background:var(--surface-2);border-radius:9px;padding:8px 11px;margin:4px 0 10px;line-height:1.9}
.break{display:flex;align-items:center;gap:8px;font-size:12px;color:var(--muted);padding:0 76px 12px 0}
.break:after{content:'';flex:1;height:1px;background:repeating-linear-gradient(to left,var(--line-strong) 0 5px,transparent 5px 10px)}
.close-day{width:100%;margin-top:8px}
.progress{height:8px;background:var(--surface-2);border-radius:99px;overflow:hidden;margin:10px 0}
.progress span{display:block;height:100%;background:var(--success);border-radius:99px;transition:width .4s var(--ease)}
.subject-row{display:flex;justify-content:space-between;font-size:14px;margin-top:14px}

/* ---------- Calendar ---------- */
.month-tools{display:flex;justify-content:space-between;align-items:center;margin-bottom:16px;gap:8px}
.month-tools h2{font-size:19px}
.calendar{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:8px}
.calendar-head{text-align:center;font-size:12px;color:var(--muted);padding:6px 0;font-weight:700}
.calendar-cell{position:relative;background:var(--surface);border:1px solid var(--line);border-radius:12px;min-height:96px;text-align:right;padding:10px;display:flex;flex-direction:column;align-items:flex-start;gap:4px;transition:border-color .18s var(--ease),transform .12s var(--ease)}
.calendar-cell:hover{border-color:var(--line-strong)}
.calendar-cell:active{transform:scale(.97)}
.calendar-cell strong{font-size:20px;line-height:1.3}
.calendar-cell small{font-size:12px;line-height:1.5}
.calendar-cell.before{background:transparent;opacity:.55}
.calendar-cell.selected{box-shadow:0 0 0 2px var(--brand-2)}
.calendar-cell.today{background:var(--success-soft);border-color:color-mix(in srgb,var(--success) 40%,transparent)}
.calendar-cell.exam{border-color:var(--gold)}
.kind-dot{display:inline-block;width:8px;height:8px;border-radius:50%;background:var(--muted);margin-left:4px;vertical-align:middle}
.kind-study{background:var(--c-math)}.kind-test{background:var(--c-physics)}.kind-review{background:var(--c-bio)}.kind-catchup{background:var(--warn)}.kind-rest{background:var(--line-strong)}.kind-exam{background:var(--gold)}
.cal-flag{position:absolute;top:8px;left:8px;display:grid;place-items:center;width:20px;height:20px;border-radius:50%;background:var(--success);color:#fff}
.cal-flag .icon{width:12px;height:12px;stroke-width:3}
.legend{display:flex;flex-wrap:wrap;gap:6px 16px;font-size:13px;color:var(--muted);margin-top:14px}

/* ---------- Forms ---------- */
.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px}
.field{display:grid;gap:6px;align-content:start}
.field.full{grid-column:1/-1}
.field label{font-size:13px;color:var(--muted);font-weight:600}
input,select,textarea{width:100%;min-height:var(--tap);border:1px solid var(--line-strong);background:var(--surface);border-radius:11px;padding:9px 12px;color:var(--ink);min-width:0;font-size:16px;transition:border-color .18s var(--ease),box-shadow .18s var(--ease)}
input:focus,select:focus,textarea:focus{outline:0;border-color:var(--ring);box-shadow:0 0 0 3px color-mix(in srgb,var(--ring) 28%,transparent)}
input[type=time],input[type=number],input[type=date]{direction:ltr;text-align:right}
input[type=checkbox]{width:20px;height:20px;min-height:0;accent-color:var(--brand-2)}
textarea{min-height:84px;resize:vertical;line-height:1.8}
.form-actions{display:flex;gap:10px;margin-top:20px;justify-content:flex-end}
.error{color:var(--danger);font-size:14px;min-height:0;margin-top:10px;font-weight:600}
.error:empty{margin:0}
.check-row{display:flex;gap:10px;align-items:center;font-size:14px;min-height:var(--tap);cursor:pointer}
.check-row input{width:20px}
.extras-row{display:grid;grid-template-columns:1fr 1.5fr 90px 1fr 1fr auto;gap:8px;margin-bottom:10px;padding-bottom:10px;border-bottom:1px dashed var(--line)}
.mistake-row{border:1px solid var(--line);background:var(--surface);padding:14px;border-radius:12px;margin:12px 0}
.sleep-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}
.unregistered{color:var(--danger)}
.pw-wrap{position:relative}
.pw-wrap input{padding-left:50px}
.pw-wrap .icon-btn{position:absolute;left:2px;top:50%;transform:translateY(-50%);color:var(--muted)}

/* ---------- Auth ---------- */
.auth{max-width:440px;margin:8vh auto;padding:34px;background:var(--surface);border:1px solid var(--line);border-radius:20px;box-shadow:var(--shadow)}
.auth-mark{display:grid;place-items:center;width:56px;height:56px;border-radius:16px;background:var(--brand-2);color:var(--on-accent);margin:0 auto 16px}
/* The heading block (mark, name, line, title, intro) is centred; the form below stays right-aligned. */
.auth>.brand,.auth>.eyebrow,.auth>h2,.auth>p:not(.note){text-align:center}
.auth .brand{margin-bottom:4px}
.auth h2{margin-top:6px}
.auth p{margin:4px 0 22px;color:var(--muted);font-size:14px}
.auth form{display:grid;gap:14px}
.auth .btn{width:100%;margin-top:6px;min-height:50px;font-size:15px}
.auth .note{margin-top:18px;display:flex;gap:8px;align-items:center}

/* ---------- Dialog ---------- */
dialog{border:0;border-radius:20px;padding:0;width:min(680px,94vw);max-height:90vh;background:var(--bg);color:var(--ink);box-shadow:var(--shadow-lg);overflow:hidden}
dialog[open]{display:flex;flex-direction:column;animation:pop .22s var(--ease)}
dialog::backdrop{background:#081226b3;backdrop-filter:blur(3px)}
@keyframes pop{from{opacity:0;transform:translateY(12px) scale(.98)}}
.dialog-head{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;padding:20px 22px 0}
.dialog-head h2{font-size:19px}
.dialog-body{overflow:auto;padding:4px 22px 22px;overscroll-behavior:contain}
.dialog-sub{color:var(--muted);font-size:13px;margin-bottom:18px;line-height:1.9}
dialog .form-actions{position:sticky;bottom:-22px;margin:20px -22px -22px;padding:14px 22px calc(14px + env(safe-area-inset-bottom));background:var(--bg);border-top:1px solid var(--line)}
dialog .form-actions .btn{flex:1;max-width:320px}

/* ---------- Toast ---------- */
#toast{position:fixed;bottom:24px;left:50%;transform:translate(-50%,16px);max-width:min(92vw,520px);padding:12px 18px;border-radius:14px;color:var(--on-brand);background:var(--brand);z-index:100;font-size:14px;font-weight:600;box-shadow:var(--shadow-lg);opacity:0;pointer-events:none;transition:opacity .2s var(--ease),transform .2s var(--ease)}
#toast.show{opacity:1;transform:translate(-50%,0)}

/* ---------- Reports ---------- */
.report-range{display:flex;align-items:flex-end;flex-wrap:wrap;gap:10px;margin-bottom:18px}
.report-range .field{width:180px}
.segmented{display:inline-flex;background:var(--surface-2);border-radius:12px;padding:3px;gap:2px}
.segmented button{min-height:38px;padding:0 16px;border-radius:9px;font-size:14px;font-weight:700;color:var(--muted);transition:background-color .18s var(--ease),color .18s var(--ease)}
.segmented button.period-active{background:var(--surface);color:var(--ink);box-shadow:var(--shadow-sm)}
.report-table{width:100%;border-collapse:collapse;font-size:14px}
.report-table th,.report-table td{text-align:right;padding:11px 8px;border-bottom:1px solid var(--line);vertical-align:top}
.report-table th{font-weight:600;color:var(--muted);font-size:13px;white-space:nowrap}
.table-wrap{overflow:auto;margin:0 -4px;padding:0 4px}
.chart{display:flex;gap:10px;height:170px;align-items:flex-end;margin:16px 0 10px}
.chart-col{flex:1;text-align:center;font-size:12px;min-width:22px;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;height:100%}
.chart-col span{font-weight:700}
.chart-bar{background:var(--c-bio);border-radius:6px 6px 2px 2px;min-height:3px;margin:4px auto;width:70%;max-width:28px;height:var(--height)}
.chart-col small{font-size:12px}

/* ---------- Exams ---------- */
.exam-row{display:flex;justify-content:space-between;align-items:center;gap:10px;padding:12px 0;border-bottom:1px solid var(--line)}
.exam-row:last-child{border-bottom:0}
.exam-days{font-size:13px;color:var(--muted);white-space:nowrap}

/* ---------- Tablet ---------- */
@media (max-width:1100px){
  .main{padding:24px}
  .shell{grid-template-columns:220px minmax(0,1fr)}
  .workspace{grid-template-columns:1fr}
  .workspace aside{display:grid;grid-template-columns:1fr 1fr;gap:16px}
  .workspace aside .panel{margin-bottom:0}
  .metrics{grid-template-columns:repeat(2,1fr)}
}

/* ---------- Phone ---------- */
@media (max-width:900px){
  body{font-size:15px}
  h1{font-size:24px}
  .shell{display:block}
  .sidebar{display:none}
  .main{padding:0 16px calc(var(--tabbar-h) + 28px + env(safe-area-inset-bottom))}
  .topbar{position:sticky;top:0;z-index:20;margin:0 -16px 16px;padding:10px 16px calc(10px);padding-top:calc(10px + env(safe-area-inset-top));background:color-mix(in srgb,var(--bg) 88%,transparent);backdrop-filter:blur(12px);border-bottom:1px solid var(--line)}
  .mobile-brand{display:block;font-size:17px;font-weight:800;line-height:1.3}
  .mobile-brand span{color:var(--gold)}
  .date-pill{font-size:12px}
  .date-pill .online{display:none}
  .tabbar{display:grid;grid-template-columns:repeat(5,1fr);position:fixed;bottom:0;left:0;right:0;z-index:30;height:calc(var(--tabbar-h) + env(safe-area-inset-bottom));padding-bottom:env(safe-area-inset-bottom);background:color-mix(in srgb,var(--surface) 94%,transparent);backdrop-filter:blur(14px);border-top:1px solid var(--line)}
  .tabbar button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;font-size:12px;font-weight:700;color:var(--muted);transition:color .18s var(--ease)}
  .tabbar button .icon{width:22px;height:22px;padding:0;transition:transform .18s var(--ease)}
  .tabbar button.active{color:var(--success)}
  .tabbar button.active .icon{transform:translateY(-1px);stroke-width:2.3}
  .intro{display:block;margin-bottom:14px}
  .intro p{font-size:14px}
  .day-tools{margin-top:12px}
  .focus{grid-template-columns:auto 1fr;padding:16px}
  .focus .btn{grid-column:1/-1;width:100%}
  .focus-icon{width:42px;height:42px}
  .hero{grid-template-columns:1fr auto;padding:18px;gap:14px}
  .hero p{font-size:15px;line-height:1.95}
  .hero-stat{padding-right:14px;min-width:0}
  .hero-stat strong{font-size:30px}
  .hero-stat small{font-size:12px}
  .metrics{grid-template-columns:1fr 1fr;gap:10px;margin-bottom:16px}
  .metric{padding:12px;gap:10px;flex-direction:column}
  .metric-icon{width:32px;height:32px}
  .metric .value{font-size:20px}
  .workspace aside{display:block}
  .workspace aside .panel{margin-bottom:16px}
  .panel{padding:16px;margin-bottom:16px;border-radius:16px}
  .task{grid-template-columns:48px 1fr;gap:10px}
  .time{font-size:13px;padding-top:12px}
  .time small{font-size:12px}
  .task-card{padding:12px 14px}
  .task-foot{flex-wrap:wrap}
  .task-foot .btn{flex:1}
  .break{padding-right:58px}
  .grid2{grid-template-columns:1fr;gap:0}
  .calendar{gap:4px}
  .calendar-cell{min-height:64px;padding:6px 5px;border-radius:10px;align-items:center;text-align:center}
  .calendar-cell strong{font-size:17px}
  .calendar-cell small{display:none}
  .calendar-cell .kind-dot{margin:0}
  .cal-flag{top:auto;bottom:4px;left:3px;width:14px;height:14px}
  .cal-flag .icon{width:9px;height:9px}
  .calendar-head{font-size:12px;padding:2px 0}
  .calendar-head .long{display:none}
  .month-tools h2{font-size:17px}
  .form-grid{grid-template-columns:1fr 1fr;gap:12px}
  .form-grid > .field:has(textarea),.form-grid > .field:has(select[name=status]){grid-column:1/-1}
  .extras-row{grid-template-columns:1fr 1fr}
  .extras-row input[aria-label="شرح فعالیت"]{grid-column:1/-1;order:-1}
  .auth{margin:5vh 16px;padding:26px 22px}
  .sleep-grid{grid-template-columns:1fr}
  dialog{width:100vw;max-width:100vw;max-height:94vh;max-height:94dvh;margin:auto 0 0;border-radius:22px 22px 0 0}
  dialog[open]{animation:sheet .26s var(--ease)}
  @keyframes sheet{from{transform:translateY(40px);opacity:.4}}
  .dialog-head{padding:18px 18px 0}
  .dialog-body{padding:4px 18px 18px}
  dialog .form-actions{margin:18px -18px -18px;padding:12px 18px calc(12px + env(safe-area-inset-bottom))}
  dialog .form-actions .btn{max-width:none}
  .report-range .field{width:calc(50% - 5px)}
  .report-table{font-size:13px}
  .report-table td,.report-table th{padding:9px 5px}
  #toast{bottom:calc(var(--tabbar-h) + 14px + env(safe-area-inset-bottom))}
}
@media (max-width:360px){.form-grid{grid-template-columns:1fr}.metrics{grid-template-columns:1fr}}

/* ---------- Motion & print ---------- */
@media (prefers-reduced-motion:reduce){*,*:before,*:after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}}
@media print{
  :root{color-scheme:light}
  .sidebar,.topbar,.tabbar,.day-tools,.btn,.report-range,#toast,.segmented{display:none!important}
  .shell{display:block}.main{padding:0}
  .panel{box-shadow:none;break-inside:avoid;border-color:#ccc}
  .hero{color:#0b1730;background:#fff;border:1px solid #ccc}
  body{background:#fff;color:#0b1730;font-size:12px}
  .metrics{grid-template-columns:repeat(4,1fr)}
  .chart-bar{print-color-adjust:exact;-webkit-print-color-adjust:exact}
  .intro h1{font-size:23px}
}
.calendar-head .short{display:none}
@media (max-width:900px){.calendar-head .short{display:inline}}
.auth .brand span{color:var(--gold)}
.form-grid > .field:has(input[name=minutes]){grid-column:1/-1}
.cal-flag.legend-flag,.calendar-cell .cal-flag.legend-flag{position:static;display:inline-grid;width:16px;height:16px;vertical-align:middle;margin-left:4px}
.legend-flag .icon{width:10px;height:10px}

/* ---------- Dashboard charts (palette validated: dataviz validate_palette, light #ffffff / dark #0e1c38) ---------- */
:root{--v-math:#eb6834;--v-bio:#1baf7a;--v-physics:#2a78d6;--v-chem:#e87ba4;--v-general:#eda100;--v-plan:#a9b1ac;
  --h0:#e6ebf3;--h1:#a7f3d0;--h2:#6ee7b7;--h3:#10b981;--h4:#047857}
@media (prefers-color-scheme:dark){:root{--v-math:#d95926;--v-bio:#199e70;--v-physics:#3987e5;--v-chem:#d55181;--v-general:#c98500;--v-plan:#5e6d66;
  --h0:#14264a;--h1:#0f4a3c;--h2:#0f7a5a;--h3:#10b981;--h4:#6ee7b7}}
.s-math{fill:var(--v-math);stroke:var(--v-math)}.s-bio{fill:var(--v-bio);stroke:var(--v-bio)}.s-physics{fill:var(--v-physics);stroke:var(--v-physics)}.s-chem{fill:var(--v-chem);stroke:var(--v-chem)}.s-general{fill:var(--v-general);stroke:var(--v-general)}
.s-plan{fill:var(--v-plan)}.s-mag{fill:var(--brand-2)}.s-sleep{fill:var(--v-physics)}
.chart-box{width:100%;min-height:60px;overflow:hidden}
.chart-svg{display:block;max-width:100%;height:auto;overflow:visible}
.chart-svg text{font-family:inherit}
.chart-svg .grid{stroke:var(--line);stroke-width:1}
.chart-svg .grid.base{stroke:var(--line-strong)}
.chart-svg .axis{fill:var(--muted);font-size:12px}
.chart-svg .axis.strong{fill:var(--ink);font-weight:600}
.chart-svg .value{fill:var(--ink);font-size:11px;font-weight:700}
.chart-svg .line{fill:none;stroke-width:2.5;stroke-linejoin:round;stroke-linecap:round}
.chart-svg .dot{stroke:var(--surface);stroke-width:2;cursor:pointer}
.chart-svg .hit{fill:transparent;cursor:pointer}
.chart-svg [data-tip]{cursor:pointer;transition:opacity .15s var(--ease)}
.chart-svg .bar{stroke:none}
.chart-svg .ref{stroke:var(--gold);stroke-width:1.5;stroke-dasharray:5 4}
.chart-svg .active-mark,.chart-svg g.active-mark .bar{opacity:.75}
.chart-svg .dot.active-mark{opacity:1;stroke:var(--ink)}
.chart-svg.year{max-width:none}
.cell{fill:var(--h0)}.cell.l1{fill:var(--h1)}.cell.l2{fill:var(--h2)}.cell.l3{fill:var(--h3)}.cell.l4{fill:var(--h4)}
.cell.lrest{fill:var(--surface-2)}.cell.lfuture{fill:none;stroke:var(--line-strong);stroke-width:1}.cell.lnone{fill:var(--surface-2);stroke:var(--danger);stroke-width:1.2}
.cell.today{stroke:var(--ink);stroke-width:2}
.year-scroll{overflow-x:auto;padding-bottom:6px;direction:rtl}
.chart-legend{display:flex;flex-wrap:wrap;gap:6px 16px;font-size:13px;color:var(--muted);margin:4px 0 10px}
.chart-legend span{display:inline-flex;align-items:center;gap:6px}
.swatch{width:12px;height:12px;border-radius:3px;display:inline-block}
.swatch.s-math{background:var(--v-math)}.swatch.s-bio{background:var(--v-bio)}.swatch.s-physics{background:var(--v-physics)}.swatch.s-chem{background:var(--v-chem)}.swatch.s-general{background:var(--v-general)}.swatch.s-plan{background:var(--v-plan)}.swatch.s-mag{background:var(--brand-2)}
.swatch.h0{background:var(--h0)}.swatch.h1{background:var(--h1)}.swatch.h2{background:var(--h2)}.swatch.h3{background:var(--h3)}.swatch.h4{background:var(--h4)}.swatch.hnone{background:var(--surface-2);box-shadow:inset 0 0 0 1.2px var(--danger)}
.swatch.line{height:3px;border-radius:2px}
.dash-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px;align-items:start}
.dash-grid .panel{margin-bottom:0}
.dash-section{margin-bottom:18px}
.insight{display:flex;gap:10px;align-items:flex-start;background:var(--surface-2);border-radius:12px;padding:12px 14px;font-size:14px;margin-top:12px}
.insight .icon{color:var(--gold);margin-top:3px}
.panel-sub{font-size:13px;color:var(--muted);margin:-8px 0 12px}
select.compact{width:auto;min-height:38px;font-size:14px;padding:4px 10px}
#chart-tip{position:fixed;z-index:200;max-width:260px;padding:8px 12px;border-radius:10px;background:var(--ink);color:var(--bg);font-size:13px;font-weight:600;line-height:1.7;pointer-events:none;opacity:0;transition:opacity .12s var(--ease);white-space:pre-line}
#chart-tip.show{opacity:1}
@media (max-width:1100px){.dash-grid{grid-template-columns:1fr}}
@media print{.chart-svg .dot,.cell{print-color-adjust:exact;-webkit-print-color-adjust:exact}}
/* One colour per subject everywhere: timeline cards follow the validated chart palette. */
:root{--c-math:var(--v-math);--c-bio:var(--v-bio);--c-physics:var(--v-physics);--c-chem:var(--v-chem);--c-general:var(--v-general)}
/* SVG text inherits the page's rtl direction, which flips text-anchor; charts position text explicitly. */
.chart-svg text{direction:ltr;unicode-bidi:plaintext}
.s-mag{stroke:var(--brand-2)}

/* ---------- Floating planner ---------- */
.mobile-only{display:none}
@media (max-width:900px){.mobile-only{display:inline-grid}}
.series-s-math{--color:var(--v-math)}.series-s-bio{--color:var(--v-bio)}.series-s-physics{--color:var(--v-physics)}.series-s-chem{--color:var(--v-chem)}.series-s-general{--color:var(--v-general)}.series-s-mag{--color:var(--brand-2)}
.plan-items{display:grid;gap:10px}
.plan-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:18px}
.plan-grid .panel{margin:0}
.plan-day{margin-top:14px}
.plan-day h3{font-size:15px;margin-bottom:8px}
.plan-day h3 small{font-weight:500}
.plan-day .task-card{margin-bottom:8px}
.link-btn{display:inline-flex;align-items:center;gap:4px;color:var(--gold);font-weight:700;min-height:32px}
.stepper{list-style:none;margin:0 0 18px;padding:0;display:grid;grid-template-columns:repeat(5,1fr);gap:6px;counter-reset:s}
.stepper li{display:flex;flex-direction:column;align-items:center;gap:4px;font-size:12px;color:var(--muted);text-align:center;font-weight:600}
.stepper li span{display:grid;place-items:center;width:30px;height:30px;border-radius:50%;background:var(--surface-2);border:1px solid var(--line);font-weight:800}
.stepper li.current{color:var(--ink)}
.stepper li.current span{background:var(--brand-2);color:var(--on-accent);border-color:transparent}
.stepper li.done span{background:var(--success-soft);color:var(--success);border-color:transparent}
.chip-row{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin-top:10px}
.chip{min-height:36px;padding:0 14px;border-radius:999px;border:1px solid var(--line-strong);background:var(--surface);font-size:13px;font-weight:600}
.chip:hover{background:var(--surface-2)}
.week-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:10px}
.subject-card{border:1px solid var(--line);border-radius:14px;padding:14px;margin-top:14px;background:var(--bg)}
.subject-card .panel-header{flex-wrap:wrap;align-items:flex-end}
.field.grow{flex:1;min-width:180px}
.topic-rows{display:grid;gap:8px;margin-bottom:6px}
.topic-row,.test-row{display:grid;grid-template-columns:1fr 1.6fr 90px 90px 110px auto;gap:8px;align-items:center}
.test-row{grid-template-columns:1.3fr 1.5fr 100px 100px auto}
.builder-actions{justify-content:space-between}
@media (max-width:1100px){.week-grid{grid-template-columns:repeat(4,1fr)}}
@media (max-width:900px){
  .stepper li{font-size:0;gap:0}.stepper li.current{font-size:12px;gap:4px}
  .week-grid{grid-template-columns:repeat(2,1fr)}
  .topic-row,.test-row{grid-template-columns:1fr 1fr 1fr auto;padding:10px;border:1px solid var(--line);border-radius:12px;background:var(--surface)}
  .topic-row{grid-template-areas:"title title title del" "book book book book" "from to diff diff"}
  .topic-row [data-t=title]{grid-area:title}.topic-row [data-t=book]{grid-area:book}.topic-row [data-t=pageFrom]{grid-area:from}.topic-row [data-t=pageTo]{grid-area:to}.topic-row [data-t=difficulty]{grid-area:diff}.topic-row .icon-btn,.test-row .icon-btn{grid-area:del}
  .test-row{grid-template-areas:"source source source del" "topic topic topic topic" "from to . ."}
  .test-row [data-q=source]{grid-area:source}.test-row [data-q=topicId]{grid-area:topic}.test-row [data-q=from]{grid-area:from}.test-row [data-q=to]{grid-area:to}
  .plan-grid{grid-template-columns:1fr}
}
.s-plan{stroke:var(--v-plan)}
.s-warn{fill:var(--warn)}.swatch.s-warn{background:var(--warn)}
.day-chips{border:0;padding:0;margin:0 0 14px;display:flex;flex-wrap:wrap;gap:8px}
.day-chips legend{font-size:13px;color:var(--muted);font-weight:600;margin-bottom:8px;padding:0}
.chip-check{position:relative;display:inline-flex}
.chip-check input{position:absolute;opacity:0;inset:0;width:100%;height:100%;margin:0;cursor:pointer}
.chip-check span{display:inline-flex;align-items:center;min-height:40px;padding:0 14px;border-radius:999px;border:1px solid var(--line-strong);background:var(--surface);font-size:14px;font-weight:600;transition:background-color .15s var(--ease),color .15s var(--ease)}
.chip-check input:checked+span{background:var(--brand-2);color:var(--on-accent);border-color:transparent}
.chip-check input:focus-visible+span{outline:2px solid var(--ring);outline-offset:2px}
input.estimated{border-color:var(--warn);background:var(--warn-soft)}
.book-chapters{display:grid;gap:4px;max-height:40vh;overflow:auto;padding:4px 0}
.radio-row{display:flex;flex-wrap:wrap;gap:8px 18px;margin:6px 0 10px}
.radio-row label{display:inline-flex;gap:6px;align-items:center;font-size:14px;min-height:36px;cursor:pointer}
.radio-row input{width:18px;height:18px;min-height:0;accent-color:var(--brand-2)}
.week-row{display:flex;align-items:center;gap:10px;font-size:14px;margin:8px 0}
.week-row .progress{flex:1;margin:0}
.week-row span:first-child{min-width:120px}

/* ---------- Catalogue, test counts, learning stages ---------- */
:root{--v-6:#008300;--v-7:#4a3aa7;--v-8:#e34948}
@media (prefers-color-scheme:dark){:root{--v-6:#008300;--v-7:#9085e9;--v-8:#e66767}}
.s-6{fill:var(--v-6);stroke:var(--v-6)}.s-7{fill:var(--v-7);stroke:var(--v-7)}.s-8{fill:var(--v-8);stroke:var(--v-8)}
.swatch.s-6{background:var(--v-6)}.swatch.s-7{background:var(--v-7)}.swatch.s-8{background:var(--v-8)}
.series-s-6{--color:var(--v-6)}.series-s-7{--color:var(--v-7)}.series-s-8{--color:var(--v-8)}
.catalog-tools{display:flex;flex-wrap:wrap;gap:10px;align-items:flex-end;margin:14px 0}
.catalog-tools .field{flex:1;min-width:220px}
.cat-book{border:1px solid var(--line);border-radius:14px;background:var(--bg);margin-top:10px;overflow:hidden}
.cat-book summary{display:flex;justify-content:space-between;align-items:center;gap:10px;padding:12px 16px;cursor:pointer;font-weight:700;min-height:48px;list-style:none}
.cat-book summary::-webkit-details-marker{display:none}
.cat-book summary:after{content:'';width:9px;height:9px;border-inline-start:2px solid var(--muted);border-bottom:2px solid var(--muted);transform:rotate(-45deg);transition:transform .2s var(--ease);margin-inline-start:4px}
.cat-book[open] summary:after{transform:rotate(-135deg)}
.cat-book>.chip-row{padding:0 16px}
.cat-chapter{border:0;border-top:1px solid var(--line);margin:8px 0 0;padding:6px 16px 10px}
.cat-chapter legend{padding:0;width:100%}
.cat-topic{min-height:38px;padding-inline-start:26px;justify-content:space-between}
.cat-topic span{flex:1}
.cat-topic small{white-space:nowrap}
.count-rows{display:grid;gap:6px}
.count-row{display:grid;grid-template-columns:1fr 90px 110px;gap:8px;align-items:center;font-size:14px;padding:6px 0;border-bottom:1px dashed var(--line)}
.count-row:last-child{border-bottom:0}
.stage{display:inline-block;font-size:12px;font-weight:700;padding:1px 8px;border-radius:999px;margin:2px 0 0}
.stage-learn{background:var(--success-soft);color:var(--success)}
.stage-fix{background:var(--warn-soft);color:var(--warn)}
.stage-master{background:color-mix(in srgb,var(--v-7) 16%,transparent);color:var(--v-7)}
.item-tip{display:inline-block;margin-top:4px;font-size:12px;color:var(--muted)}
@media (max-width:900px){.count-row{grid-template-columns:1fr 70px 90px}.catalog-tools .btn{width:100%}}

/* ---------- Smart plan ---------- */
.level-row{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:8px 0;border-bottom:1px dashed var(--line);font-weight:600}
.level-row:last-child{border-bottom:0}
.seg-radio{display:inline-flex;background:var(--surface-2);border-radius:12px;padding:3px;gap:2px}
.seg-radio label{position:relative;display:inline-flex}
.seg-radio input{position:absolute;opacity:0;inset:0;margin:0;cursor:pointer;width:100%;height:100%}
.seg-radio span{display:inline-flex;align-items:center;min-height:36px;padding:0 14px;border-radius:9px;font-size:14px;font-weight:700;color:var(--muted)}
.seg-radio input:checked+span{background:var(--surface);color:var(--ink);box-shadow:var(--shadow-sm)}
.seg-radio input:focus-visible+span{outline:2px solid var(--ring);outline-offset:1px}
.principles{margin-top:14px;border:1px solid var(--line);border-radius:12px;padding:0 14px;background:var(--bg)}
.principles summary{cursor:pointer;font-weight:700;min-height:44px;display:flex;align-items:center}
.principles ul{margin:0 0 12px;padding-inline-start:18px;line-height:2;font-size:14px}
#smart-form .panel h2{margin-bottom:10px}

/* ---------- Audit 2026-10-15: touch targets, lighter forms, accounts ---------- */
@media (max-width:900px),(pointer:coarse){
  .btn.small,.segmented button,select.compact,.link-btn,.chip,.cat-topic{min-height:44px}
  .day-nav .icon-btn{width:44px;height:44px}
  .chip-check span,.radio-row label,.seg-radio span{min-height:44px}
}
.icon-btn.active{color:var(--success);background:var(--success-soft)}
.danger-text{color:var(--danger)!important}
.hint{display:block;font-size:12px;color:var(--muted);margin-top:-2px}
.form-span{grid-column:1/-1}
p.callout{margin:0}
/* one-tap choices (status, mood, Kanoon) */
.choices{border:0;margin:0;padding:0;min-width:0;grid-column:1/-1}
.choices legend{font-size:13px;color:var(--muted);font-weight:600;padding:0;margin-bottom:6px}
.choice-row{display:flex;flex-wrap:wrap;gap:8px}
.choices.wide .choice{flex:1 1 0}
.choice{position:relative;display:flex;min-width:0}
.choice input{position:absolute;inset:0;opacity:0;margin:0;width:100%;height:100%;min-height:0;cursor:pointer}
.choice span{flex:1;display:inline-flex;align-items:center;justify-content:center;text-align:center;min-height:var(--tap);padding:4px 12px;border-radius:12px;border:1px solid var(--line-strong);background:var(--surface);font-size:14px;font-weight:700;line-height:1.4;transition:background-color .18s var(--ease),border-color .18s var(--ease),color .18s var(--ease)}
.choice input:checked+span{background:var(--brand-2);border-color:var(--brand-2);color:var(--on-accent)}
.choice.tone-success input:checked+span{background:var(--success-soft);border-color:var(--success);color:var(--success)}
.choice.tone-warn input:checked+span{background:var(--warn-soft);border-color:var(--warn);color:var(--warn)}
.choice.tone-danger input:checked+span{background:var(--danger-soft);border-color:var(--danger);color:var(--danger)}
.choice input:focus-visible+span{outline:2px solid var(--ring);outline-offset:2px}

form .choices{margin-bottom:2px}
#daily-form>.choices,#daily-form>details{margin-top:14px}
/* collapsible routine section */
details.more{border:1px solid var(--line);border-radius:12px;padding:0 14px;background:var(--bg)}
details.more>summary{cursor:pointer;min-height:var(--tap);display:flex;align-items:center;gap:6px;font-weight:700;font-size:14px}
details.more>summary small{font-weight:500}
details.more[open]>summary{margin-bottom:8px}
details.more .form-grid{padding-bottom:14px}
/* typed 24-hour time */
.time-input{text-align:center;font-variant-numeric:tabular-nums;letter-spacing:.5px}
/* record actions on session cards */
.foot-actions{display:inline-flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}
.btn.quick{background:var(--success);color:#fff}
.btn.quick:hover{background:var(--brand-2)}
/* sign-in / sign-up */
.auth-switch{margin-top:16px;text-align:center;font-size:14px}
.auth form .choices{margin-top:4px}
small{font-size:max(12px,.83em)}
.table-wrap th,.table-wrap td{white-space:nowrap}

/* ---------- Landing (visitors) ---------- */
.lp{max-width:1120px;margin:0 auto;padding:0 20px 40px}
.lp-top{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:18px 0;position:sticky;top:0;z-index:5;background:color-mix(in srgb,var(--bg) 92%,transparent);backdrop-filter:blur(10px)}
.lp-top .brand{font-size:22px}
.lp-top .brand span,.lp-foot .brand span{color:var(--gold)}
.lp-top-actions{display:flex;gap:8px}
.lp-hero{display:grid;grid-template-columns:1.1fr .9fr;gap:40px;align-items:center;padding:40px 0 56px}
.lp-copy h1{font-size:44px;line-height:1.35;margin:10px 0 14px}
.lp-copy>p{font-size:17px;color:var(--muted);line-height:2;max-width:560px}
.lp-cta{display:flex;flex-wrap:wrap;gap:10px;margin:26px 0 12px}
.btn.lp-main{min-height:52px;padding:0 26px;font-size:16px;border-radius:14px}
.lp-note{display:flex;gap:6px;align-items:center}
.lp-points{list-style:none;margin:14px 0 0;padding:0;display:grid;gap:8px}
.lp-points li{display:flex;gap:8px;align-items:flex-start;font-weight:600}
.lp-points svg{flex:none;margin-top:4px;color:var(--emerald)}
.lp-phone{justify-self:center;width:min(100%,340px);padding:12px;border-radius:34px;background:var(--brand);box-shadow:var(--shadow-lg)}
.lp-screen{background:var(--bg);color:var(--ink);border-radius:24px;padding:18px 14px;display:grid;gap:10px}
.lp-screen-head{display:grid;gap:2px;padding:0 4px 4px}
.lp-screen-head strong{font-size:18px}
.lp-item{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:10px;background:var(--surface);border:1px solid var(--line);border-inline-start:4px solid var(--series,var(--brand-2));border-radius:12px;padding:10px 12px}
.lp-item strong{display:block;font-size:14px}.lp-item small{font-size:12px}
.lp-item.s-bio{--series:var(--c-bio)}.lp-item.s-chem{--series:var(--c-chem)}.lp-item.s-math{--series:var(--c-math)}.lp-item.s-physics{--series:var(--c-physics)}
.lp-time{font-size:12px;color:var(--muted);font-weight:700}
.lp-check{display:grid;place-items:center;width:26px;height:26px;border-radius:50%;background:var(--success-soft);color:var(--success)}
.lp-now{font-size:12px;font-weight:700;background:var(--brand-2);color:var(--on-accent);border-radius:999px;padding:2px 10px}
.lp-progress{height:8px;border-radius:99px;background:var(--surface-2);overflow:hidden;margin-top:4px}.lp-progress span{display:block;height:100%;width:42%;background:var(--success);border-radius:inherit}
.lp-progress-label{padding:0 4px}
.lp-section{padding:36px 0;border-top:1px solid var(--line)}
.lp-facts{list-style:none;margin:0;padding:22px 0;display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:12px}
.lp-facts li{display:grid;gap:2px;padding:14px 16px;border-radius:var(--radius);background:var(--surface);border:1px solid var(--line)}
.lp-facts strong{font-size:22px;font-weight:800;color:var(--brand-2)}
.lp-facts span{font-size:13px;color:var(--muted)}
.lp-lead{color:var(--muted);margin:-12px 0 22px}
.lp-shots{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(3,1fr);gap:28px 22px}
.lp-shot{display:grid;align-content:start;gap:6px}
.lp-shot-frame{justify-self:center;width:min(100%,260px);padding:8px;margin-bottom:10px;border-radius:30px;background:#030812;box-shadow:var(--shadow-lg),0 0 0 1px #ffffff14}
.lp-shot-frame img{display:block;width:100%;height:auto;aspect-ratio:390/844;border-radius:23px;background:var(--surface-2)}
.lp-shot h3{font-size:17px}
.lp-shot p{color:var(--muted);font-size:14px;line-height:1.9}
.lp-shots-note{display:block;margin-top:18px;color:var(--muted);font-size:12px}
@media (max-width:860px){
  .lp-shots{grid-auto-flow:column;grid-template-columns:none;grid-auto-columns:min(72vw,280px);overflow-x:auto;scroll-snap-type:x mandatory;overscroll-behavior-x:contain;margin-inline:-20px;padding:4px 20px 14px;gap:16px}
  .lp-shot{scroll-snap-align:center}
  .lp-facts{grid-template-columns:repeat(2,1fr)}
  .lp-facts strong{font-size:19px}
}
.lp-section>h2{font-size:26px;margin-bottom:22px}
.lp-features{display:grid;grid-template-columns:repeat(3,1fr);gap:16px}
.lp-feature{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);padding:20px}
.lp-feature h3{margin:12px 0 6px}.lp-feature p{color:var(--muted);font-size:14px;line-height:1.9}
.lp-feature-icon{display:grid;place-items:center;width:44px;height:44px;border-radius:12px;background:var(--gold-soft);color:var(--gold)}
.lp-steps{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(3,1fr);gap:16px;counter-reset:step}
.lp-steps li{counter-increment:step;background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);padding:20px;display:grid;gap:6px}
.lp-steps li:before{content:counter(step,persian);display:grid;place-items:center;width:36px;height:36px;border-radius:50%;background:var(--brand-2);color:var(--on-accent);font-weight:800}
.lp-steps span{color:var(--muted);font-size:14px}
.lp-faq details{border-bottom:1px solid var(--line)}
.lp-faq summary{cursor:pointer;min-height:52px;display:flex;align-items:center;justify-content:space-between;gap:12px;font-weight:700;list-style:none}
.lp-faq summary::-webkit-details-marker{display:none}
.lp-faq summary::after{content:'';flex:none;width:9px;height:9px;border-right:2px solid var(--muted);border-bottom:2px solid var(--muted);transform:translateY(-3px) rotate(45deg);transition:transform .2s var(--ease)}
.lp-faq details[open] summary::after{transform:translateY(2px) rotate(-135deg)}
.lp-faq p{padding:0 0 16px;color:var(--muted)}
.lp-final{text-align:center;padding:48px 20px;margin-top:20px;border-radius:24px;background:var(--brand);color:var(--on-brand);display:grid;gap:18px;justify-items:center}
.lp-final h2{font-size:clamp(19px,5.3vw,26px);line-height:1.6}
.lp-final p{margin:-6px 0 0;color:var(--brand-muted)}
.lp-final .btn{background:var(--gold-bright);color:#1f1400}
.lp-foot{text-align:center;color:var(--muted);font-size:13px;padding:28px 0 0}
@media (max-width:860px){
  .lp-hero{grid-template-columns:1fr;padding:20px 0 40px;gap:28px}
  .lp-copy h1{font-size:clamp(25px,7.2vw,32px)}
  .lp-features,.lp-steps{grid-template-columns:1fr}
  .lp-top .btn.ghost{padding:0 12px}
}
.auth-back{margin-bottom:8px}

/* ---------- Today: unified day, closing, success ---------- */
.day-close{display:grid;gap:10px}
.day-close .btn{width:100%}
.today-stats{margin-top:18px}
.plan-why{display:flex;gap:6px;align-items:flex-start;font-size:13px;color:var(--muted);background:var(--surface-2);border-radius:10px;padding:8px 12px;margin:0 0 12px}
.plan-why .icon{margin-top:4px;flex:none}
.queue-note{margin:12px 0 0}
.focus.done{border-color:color-mix(in srgb,var(--success) 45%,transparent);background:color-mix(in srgb,var(--success-soft) 70%,var(--surface))}
.focus.pop{animation:pop .3s var(--ease)}
#toast.celebrate{background:var(--success);color:#fff}
#toast.celebrate.show{animation:toast-pop .28s var(--ease)}
@keyframes toast-pop{from{transform:translate(-50%,12px) scale(.94)}to{transform:translate(-50%,0) scale(1)}}

/* ---------- First-run guide ---------- */
.guide{display:grid;justify-items:center;text-align:center;gap:10px;padding:8px 0 4px}
.guide-icon{display:grid;place-items:center;width:64px;height:64px;border-radius:20px;background:var(--success-soft);color:var(--success)}
.guide p{color:var(--muted);line-height:2}
.guide-dots{display:flex;gap:6px}.guide-dots span{width:8px;height:8px;border-radius:50%;background:var(--line-strong)}.guide-dots span.on{width:22px;border-radius:99px;background:var(--brand-2)}
.guide-actions{width:100%;display:grid;gap:8px}.guide-actions .btn{width:100%}

/* ---------- Settings: share link ---------- */
.share-row{display:flex;gap:8px}.share-row input{flex:1;font-size:13px}

/* ---------- Shared report (parents, counselors) ---------- */
.shared{max-width:1000px;margin:0 auto;padding:16px 20px 48px}
.shared-head{display:flex;justify-content:space-between;align-items:center;padding:8px 0 18px}
.shared .metrics{margin-top:8px}

/* ---------- Plain-language plan summary and details ---------- */
.plan-summary{font-size:16px;line-height:2;background:var(--surface);border:1px solid var(--line);border-inline-start:4px solid var(--brand-2);border-radius:var(--radius);padding:14px 18px;margin:0 0 16px}
.facts{display:grid;gap:2px;padding-bottom:12px}
.fact{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:10px 0;border-bottom:1px dashed var(--line)}
.fact:last-child{border-bottom:0}
.fact span{display:grid;font-weight:600;font-size:14px}.fact small{font-weight:400}
.fact strong{font-size:17px;white-space:nowrap}
.idle-plans{display:flex;gap:12px;align-items:center;padding:14px 18px}
.idle-plans>.icon{color:var(--muted);flex:none}
.idle-plans div{display:grid;gap:2px}.idle-plans small{line-height:1.8}
.dash-section .link-btn{margin:2px 0 10px}

/* ---------- Persian date picker (replaces long date drop-downs) ---------- */
select.dp-native{position:absolute!important;width:1px!important;height:1px!important;min-height:0!important;opacity:0;pointer-events:none;padding:0!important;border:0!important}
.dp-wrap{position:relative;min-width:0}
.dp-trigger{display:flex;align-items:center;gap:10px;width:100%;min-height:var(--tap);border:1px solid var(--line-strong);background:var(--surface);border-radius:11px;padding:9px 12px;font-size:15px;text-align:right;color:var(--ink);transition:border-color .18s var(--ease)}
.dp-trigger .icon{color:var(--gold)}
.dp-trigger[aria-expanded=true]{border-color:var(--brand-2);box-shadow:0 0 0 3px color-mix(in srgb,var(--brand-2) 18%,transparent)}
.dp{margin-top:8px;background:var(--surface);border:1px solid var(--line);border-radius:16px;box-shadow:var(--shadow);padding:12px;animation:pop .18s var(--ease)}
.dp-head{display:grid;grid-template-columns:44px 1fr 1fr 44px;gap:6px;align-items:center;margin-bottom:8px}
.dp-head select{min-height:44px;font-size:15px;font-weight:700;text-align:center;padding:6px 8px}
.dp-head .icon-btn:disabled{opacity:.3}
.dp-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:4px}
.dp-dow{text-align:center;font-size:12px;color:var(--muted);font-weight:700;padding:4px 0}
.dp-day{min-height:44px;border-radius:12px;font-size:15px;font-weight:600;font-variant-numeric:tabular-nums;transition:background-color .15s var(--ease)}
.dp-day:not(:disabled):hover{background:var(--surface-2)}
.dp-day:disabled{color:var(--line-strong);cursor:default}
.dp-day.today{box-shadow:inset 0 0 0 1.5px var(--gold)}
.dp-day.on{background:var(--brand-2);color:var(--on-accent)}
.dp-foot{display:flex;justify-content:center;margin-top:6px}
.dp-title{font-weight:800;font-size:16px;margin:2px 4px 10px}
.dp-foot{gap:8px}
@media (min-width:901px){.dp{position:absolute;top:100%;inset-inline-start:0;z-index:50;width:340px}}
@media (max-width:900px){
  .dp{position:fixed;left:0;right:0;bottom:0;margin:0;z-index:300;border-radius:22px 22px 0 0;padding:16px 16px calc(16px + env(safe-area-inset-bottom));max-height:90vh;overflow:auto;animation:sheet .24s var(--ease)}
  .dp-wrap.open::before{content:'';position:fixed;inset:0;background:#08122666;z-index:299}
}

/* ======================= Today, redesigned ======================= */
/* Week strip: move between days at a glance */
.week-strip{margin-bottom:14px}
.ws-head{display:grid;grid-template-columns:44px 1fr 44px;align-items:center;margin-bottom:6px}
.ws-head strong{text-align:center;font-size:14px;color:var(--muted)}
.ws-days{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:6px}
.ws-day{display:grid;justify-items:center;align-content:center;gap:2px;min-height:64px;padding:6px 0;border-radius:16px;background:var(--surface);border:1px solid var(--line);transition:background-color .18s var(--ease),border-color .18s var(--ease),transform .12s var(--ease)}
.ws-day:hover{border-color:var(--line-strong)}
.ws-day:active{transform:scale(.95)}
.ws-day small{font-size:12px;font-weight:700;color:var(--muted);line-height:1.2}
.ws-day strong{font-size:18px;line-height:1.25}
.ws-day i{width:7px;height:7px;border-radius:50%;background:transparent}
.ws-day.s-full i{background:var(--success)}.ws-day.s-part i{background:var(--warn)}.ws-day.s-miss i{background:var(--danger)}.ws-day.s-todo i,.ws-day.s-plan i{background:var(--line-strong)}
.ws-day.is-today{border-color:var(--gold);border-width:1.5px}
.ws-day.on{background:var(--brand-2);border-color:var(--brand-2);color:var(--on-accent);box-shadow:var(--shadow)}
.ws-day.on small{color:inherit;opacity:.9}
.ws-day.on.s-todo i,.ws-day.on.s-plan i{background:var(--brand-muted)}

/* Day card: greeting, progress ring and the day's numbers */
.day-hero{position:relative;overflow:hidden;display:grid;grid-template-columns:1fr auto;gap:18px;align-items:center;background:linear-gradient(145deg,var(--brand) 0%,var(--brand-hi) 100%);color:var(--on-brand);border-radius:22px;padding:22px 24px;margin-bottom:16px;box-shadow:var(--shadow)}
.day-hero:before{content:'';position:absolute;width:240px;height:240px;border-radius:50%;border:1px solid #ffffff17;left:-80px;top:-120px;pointer-events:none}
.day-hero:after{content:'';position:absolute;width:150px;height:150px;border-radius:50%;background:radial-gradient(circle,#10b98126,transparent 70%);left:20%;bottom:-80px;pointer-events:none}
.day-hero .eyebrow{color:var(--gold-bright)}
.day-hero h1{font-size:25px;line-height:1.5;margin:4px 0 0;color:var(--on-brand)}
.day-hero p{color:var(--brand-muted);font-size:14px}
.dh-text{position:relative;z-index:1;min-width:0}
.dh-stats{position:relative;z-index:1;grid-column:1/-1;grid-row:2;display:grid;grid-auto-flow:column;grid-auto-columns:minmax(0,1fr);gap:8px}
.dh-stats div{display:grid;gap:0;padding:8px 14px;border-radius:14px;background:#ffffff14;border:1px solid #ffffff1f;min-width:84px}
.dh-stats small{font-size:12px;color:var(--brand-muted)}
.dh-stats strong{font-size:17px;line-height:1.5}
.dh-stats span{font-size:12px;color:var(--brand-muted)}
.dh-ring{position:relative;z-index:1;width:124px;height:124px;flex:none}
.dh-ring svg{width:100%;height:100%;display:block}
.ring-bg{fill:none;stroke:#ffffff24;stroke-width:11}
.ring-fg{fill:none;stroke:var(--gold-bright);stroke-width:11;stroke-linecap:round;animation:ring-in .8s var(--ease)}
@keyframes ring-in{from{stroke-dasharray:0 100}}
.dh-ring>div{position:absolute;inset:0;display:grid;place-content:center;text-align:center}
.dh-ring strong{font-size:26px;line-height:1.15}
.dh-ring small{font-size:12px;color:var(--brand-muted)}

/* Timeline: one continuous rail, a node per session */
.timeline{position:relative;gap:2px}
.timeline:before{content:'';position:absolute;top:14px;bottom:14px;inset-inline-start:83px;width:2px;border-radius:2px;background:var(--line)}
.task{grid-template-columns:62px 20px minmax(0,1fr);gap:12px;padding-bottom:10px}
.task .node,.break .node{position:relative;z-index:1;display:grid;place-items:center;width:20px;height:20px;margin-top:16px;border-radius:50%;background:var(--surface);border:2.5px solid var(--color,var(--line-strong));color:#fff}
.task .node .icon{width:12px;height:12px;stroke-width:3}
.task.is-done .node{background:var(--success);border-color:var(--success)}
.task.is-late .node{border-color:var(--danger);background:var(--danger-soft)}
.task.is-now .node{background:var(--color);box-shadow:0 0 0 0 color-mix(in srgb,var(--color) 55%,transparent);animation:node-pulse 1.8s var(--ease) infinite}
@keyframes node-pulse{70%{box-shadow:0 0 0 10px transparent}100%{box-shadow:0 0 0 0 transparent}}
.task.is-done .time{color:var(--muted)}
.task.is-done .task-card{background:color-mix(in srgb,var(--success-soft) 60%,var(--surface))}
.task.is-done .task-body{display:none}
.task.is-done .log-note{margin-top:8px}
.task-card{border-radius:16px;box-shadow:var(--shadow-sm)}
.task-card.current{box-shadow:0 0 0 2px var(--color),var(--shadow)}
.task-head h3{font-size:16px}
.break{display:grid;grid-template-columns:62px 20px 1fr;gap:12px;align-items:center;padding:0 0 10px;font-size:12px;color:var(--muted)}
.break:after{display:none}
.break .node{margin-top:0;width:20px;height:20px;border:0;background:var(--surface-2);color:var(--muted)}
.break .node .icon{width:12px;height:12px}

/* Floating-plan items share the rail look */
.plan-items{position:relative;padding-inline-start:30px}
.plan-items:before{content:'';position:absolute;top:14px;bottom:14px;inset-inline-start:9px;width:2px;border-radius:2px;background:var(--line)}
.plan-item{position:relative}
.plan-item:before{content:'';position:absolute;inset-inline-start:-30px;top:16px;width:20px;height:20px;box-sizing:border-box;border-radius:50%;background:var(--surface);border:2.5px solid var(--color,var(--line-strong))}
.plan-item.complete:before{background:var(--success);border-color:var(--success)}
.plan-item.overdue:before{border-color:var(--danger);background:var(--danger-soft)}

/* Quote and weekly numbers */
.quote-card{position:relative;background:var(--surface);border:1px solid var(--line);border-radius:20px;padding:20px 22px 20px 56px;margin-bottom:12px;box-shadow:var(--shadow-sm)}
.quote-card:after{content:'”';position:absolute;left:18px;top:4px;font-size:64px;line-height:1;color:var(--gold-bright);opacity:.55}
.quote-card p{font-size:16px;line-height:2}
.week-mini{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.week-mini>div{display:flex;align-items:center;gap:12px;background:var(--surface);border:1px solid var(--line);border-radius:16px;padding:14px 16px}
.week-mini .icon{color:var(--gold);flex:none}
.week-mini span{display:grid}.week-mini small{font-size:12px;color:var(--muted)}.week-mini strong{font-size:17px}

@media (max-width:900px){
  .day-hero{padding:18px;gap:12px;border-radius:20px}
  .day-hero h1{font-size:20px}
  .dh-ring{width:100px;height:100px}
  .dh-ring strong{font-size:21px}
  .dh-stats div{padding:6px 10px;min-width:0}
  .dh-stats strong{font-size:15px}
  .ws-days{gap:4px}
  .ws-day{min-height:58px;border-radius:14px}
  .ws-day strong{font-size:16px}
  .timeline:before{inset-inline-start:65px}
  .task{grid-template-columns:48px 20px minmax(0,1fr);gap:8px}
  .break{grid-template-columns:48px 20px 1fr;gap:8px}
  .week-mini{grid-template-columns:1fr}
}
@media (max-width:420px){.dh-ring{width:86px;height:86px}.dh-ring strong{font-size:18px}.dh-ring small{font-size:12px;line-height:1.3}.day-hero h1{font-size:18px}}
@media (max-width:330px){.day-hero{grid-template-columns:1fr}.dh-ring{justify-self:center;grid-row:1}.dh-text{grid-row:2}.dh-stats{grid-row:3}}
@media (prefers-reduced-motion:reduce){.task.is-now .node{animation:none}.ring-fg{animation:none}}
@media print{.week-strip{display:none}.day-hero{color:#0b1730;background:#fff;border:1px solid #ccc}}
.timeline:before,.plan-items:before{background:var(--line-strong)}
.task.is-done .task-foot .btn{flex:0 0 auto}
.task.is-done .task-card{padding-block:10px}
@media (max-width:900px){
  .timeline:before{inset-inline-start:54px}
  .task{grid-template-columns:40px 18px minmax(0,1fr);gap:6px}
  .break{grid-template-columns:40px 18px 1fr;gap:6px}
  .task .node,.break .node{width:18px;height:18px}
  .time{font-size:12.5px}
  .task-head h3{font-size:15px}
}
.workspace.single{grid-template-columns:minmax(0,1fr)}
.workspace.single>aside{display:none}

/* ===== "مسیر امروز" cards, option A: tinted by subject, icon tile, chips ===== */
.timeline{display:grid;gap:12px}
.timeline:before{display:none}
.task{display:block;padding:0}
.task-card{--tint:color-mix(in srgb,var(--color) 11%,var(--surface));background:var(--tint);border:1px solid color-mix(in srgb,var(--color) 32%,transparent);border-radius:20px;padding:14px 16px;box-shadow:none;transition:box-shadow .2s var(--ease),transform .15s var(--ease)}
.task-card:hover{box-shadow:var(--shadow-sm)}
.tc-head{display:flex;align-items:center;gap:12px}
.tc-icon{flex:none;display:grid;place-items:center;width:46px;height:46px;border-radius:15px;background:color-mix(in srgb,var(--color) 24%,var(--surface));color:color-mix(in srgb,var(--color) 70%,var(--ink))}
.tc-icon .icon{width:22px;height:22px}
.tc-title{flex:1;min-width:0}
.tc-title h3{font-size:16px;line-height:1.55;margin:0}
.tc-title small{display:block;font-size:12.5px;color:var(--muted)}
.tc-head .badge{align-self:flex-start;margin-top:2px}
.tc-chips{display:flex;flex-wrap:wrap;gap:6px;margin:12px 0 0}
.tc-chips span:not(.stage){font-size:12.5px;line-height:1.75;padding:3px 11px;border-radius:999px;background:color-mix(in srgb,var(--color) 15%,var(--surface));color:color-mix(in srgb,var(--color) 45%,var(--ink))}
.tc-chips .stage{margin:0;padding:3px 11px;line-height:1.75;font-size:12.5px}
.tc-progress{height:6px;border-radius:99px;margin:12px 0 0;overflow:hidden;background:color-mix(in srgb,var(--color) 20%,var(--surface))}
.tc-progress span{display:block;height:100%;border-radius:inherit;background:var(--color)}
.task-card .task-foot{margin-top:12px;justify-content:flex-end}
.task-card.current{box-shadow:0 0 0 2px var(--color),var(--shadow)}
.task-card.current .tc-icon{animation:node-pulse 2s var(--ease) infinite;box-shadow:0 0 0 0 color-mix(in srgb,var(--color) 50%,transparent)}
.task-card.overdue{border-color:color-mix(in srgb,var(--danger) 50%,transparent);border-inline-start-color:color-mix(in srgb,var(--danger) 50%,transparent)}
.task-card .log-note{margin:12px 0 0;background:color-mix(in srgb,var(--color) 9%,var(--surface));font-size:12.5px}
/* done: green and compact; the details stay one tap away under "ویرایش" */
.task-card.complete{--color:var(--success);padding-block:10px}
.task-card.complete .tc-icon{width:38px;height:38px;border-radius:50%;background:var(--success);color:#fff}
.task-card.complete .tc-icon .icon{width:18px;height:18px;stroke-width:2.6}
.task-card.complete .tc-chips{display:none}
.task-card.complete .log-note{margin-top:8px;background:transparent;padding:0;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.task-card.complete .task-foot{margin-top:6px}
.task-card.complete .task-foot .btn{flex:0 0 auto}
/* breaks: a small pill between cards */
.break{display:flex;justify-content:center;padding:0;gap:0}
.break span{display:inline-flex;align-items:center;gap:6px;font-size:12px;color:var(--muted);padding:3px 12px;border-radius:999px;background:var(--surface-2)}
/* floating-plan items: same card, no rail */
.plan-items{padding-inline-start:0;gap:12px}
.plan-items:before,.plan-item:before{display:none}
@media (max-width:900px){
  .task-card{padding:12px 14px;border-radius:18px}
  .tc-icon{width:42px;height:42px;border-radius:13px}
  .task-card .task-foot .btn{flex:1}
  .task-card.complete .task-foot .btn{flex:0 0 auto}
}
@media (prefers-reduced-motion:reduce){.task-card.current .tc-icon{animation:none}}

/* ======================= Harmony: every page speaks the Today page's language ======================= */
/* Page header: the same green band as the day card */
.intro{position:relative;overflow:hidden;align-items:center;background:linear-gradient(145deg,var(--brand) 0%,var(--brand-hi) 100%);color:var(--on-brand);border-radius:22px;padding:20px 24px;margin-bottom:18px;box-shadow:var(--shadow)}
.intro:before{content:'';position:absolute;width:240px;height:240px;border-radius:50%;border:1px solid #ffffff17;left:-80px;top:-120px;pointer-events:none}
.intro>*{position:relative;z-index:1}
.intro h1{color:var(--on-brand)}
.intro p{color:var(--brand-muted)}
.intro .eyebrow,.intro .link-btn{color:var(--gold-bright)}
.intro .btn{background:var(--gold-bright);color:#1f1400;border:0}
.intro .btn:hover{background:#fcd34d}
.intro .btn.light{background:#ffffff1a;color:var(--on-brand);border:1px solid #ffffff40}
.intro .btn.light:hover{background:#ffffff2e}
.intro .btn.danger-text{color:#ffd2ca!important}
/* Surfaces: one radius family, soft shadows */
.panel{border-radius:20px;box-shadow:var(--shadow-sm)}
.callout{border-radius:16px}
.metric{border-radius:18px;align-items:center}
.metric-icon{width:44px;height:44px;border-radius:14px;background:var(--gold-soft);color:var(--gold)}
.metric-icon .icon{width:22px;height:22px}
/* "Now / next" card: tinted by state, like the subject cards */
.focus{--color:var(--success);background:color-mix(in srgb,var(--color) 10%,var(--surface));border:1px solid color-mix(in srgb,var(--color) 32%,transparent);border-radius:20px;box-shadow:none}
.focus.alert{--color:var(--danger)}
.focus.next{--color:var(--gold)}
.focus .focus-icon,.focus.alert .focus-icon,.focus.next .focus-icon{width:48px;height:48px;border-radius:15px;background:color-mix(in srgb,var(--color) 22%,var(--surface));color:color-mix(in srgb,var(--color) 75%,var(--ink))}
.focus .progress{background:color-mix(in srgb,var(--color) 18%,var(--surface))}
.focus .progress span{background:var(--color)}
/* Calendar: selection and today read like the week strip */
.calendar-cell{border-radius:14px}
.calendar-cell.today{background:var(--surface);border-color:var(--gold);border-width:1.5px}
.calendar-cell.selected{background:var(--brand-2);border-color:var(--brand-2);color:var(--on-accent);box-shadow:var(--shadow)}
.calendar-cell.selected small{color:inherit;opacity:.85}
/* Plan cards: an icon tile and a gentle lift */
.plan-card{--color:var(--brand-2);transition:box-shadow .2s var(--ease),transform .2s var(--ease)}
.plan-card:hover{box-shadow:var(--shadow);transform:translateY(-2px)}
.pc-title{display:flex;align-items:center;gap:12px;min-width:0}
.pc-title .tc-icon{width:42px;height:42px;border-radius:13px}
/* Empty states: the icon sits in a soft tile */
.empty>.icon{box-sizing:border-box;width:58px;height:58px;padding:15px;border-radius:18px;background:var(--surface-2);color:var(--muted);margin-bottom:10px}
@media (max-width:900px){
  .intro{padding:18px;border-radius:20px}
  .intro .day-tools{margin-top:12px}
  .metric-icon{width:40px;height:40px;border-radius:13px}
  .calendar-cell{border-radius:11px}
}
@media print{.intro{color:#0b1730;background:#fff;border:1px solid #ccc;box-shadow:none}.intro h1,.intro p{color:#0b1730}}
.plan-summary{border:1px solid color-mix(in srgb,var(--brand-2) 28%,transparent);background:color-mix(in srgb,var(--brand-2) 8%,var(--surface));border-radius:18px}

/* ======================= Admin, supporter and parent panels ======================= */
.loading-inline{display:flex;gap:8px;align-items:center;justify-content:center;color:var(--muted);padding:40px 0}
.filter-bar{display:flex;flex-wrap:wrap;gap:10px;align-items:center;justify-content:space-between;margin-bottom:16px}
.filter-bar input[type=search]{max-width:320px}
.people-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:16px;margin-bottom:18px}
.person-card{--color:var(--brand-2);display:grid;gap:12px;align-content:start;background:var(--surface);border:1px solid var(--line);border-radius:20px;padding:16px;box-shadow:var(--shadow-sm);transition:box-shadow .2s var(--ease),transform .2s var(--ease)}
.person-card:hover{box-shadow:var(--shadow);transform:translateY(-2px)}
.person-card.at-risk{--color:var(--warn);border-color:color-mix(in srgb,var(--warn) 40%,transparent);background:color-mix(in srgb,var(--warn) 5%,var(--surface))}
.pc-top{display:flex;align-items:center;gap:12px}
.pc-avatar{flex:none;display:grid;place-items:center;width:46px;height:46px;border-radius:15px;background:color-mix(in srgb,var(--color) 18%,var(--surface));color:color-mix(in srgb,var(--color) 70%,var(--ink));font-weight:800;font-size:19px}
.pc-name{flex:1;min-width:0;display:grid}
.pc-name h3{font-size:16px;margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pc-name small{color:var(--muted);font-size:12px;text-align:right}
.pc-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.pc-stats div{display:grid;padding:8px 10px;border-radius:14px;background:var(--surface-2)}
.pc-stats small{font-size:12px;color:var(--muted)}
.pc-stats strong{font-size:16px;line-height:1.5}
.pc-stats span{font-size:12px;color:var(--muted)}
.person-card .progress{margin:0}
.person-card .progress span{background:var(--color)}
.pc-foot{display:flex;align-items:center;gap:6px;font-size:13px;color:var(--muted);margin:0}
.warn-text{color:var(--warn)}
.pc-assign{display:grid;grid-template-columns:auto 1fr;align-items:center;gap:10px;font-size:13px;font-weight:700;color:var(--muted)}
.pc-open{width:100%}
.pc-reset{display:block;margin:8px auto 0;font-size:13px}
.reset-requests{border-color:var(--gold)}
.staff-row{display:flex;align-items:center;gap:12px;padding:12px 0;border-bottom:1px solid var(--line)}
.staff-row .pc-name strong{font-size:15px}
.staff-actions{display:flex;flex-wrap:wrap;gap:6px;justify-content:flex-end}
.kids{margin-top:12px}
.report-head{margin:6px 2px 10px}.report-head h2{font-size:17px}
@media (max-width:900px){
  .people-grid{grid-template-columns:1fr}
  .filter-bar input[type=search]{max-width:none}
  .staff-row{flex-wrap:wrap}.staff-actions{width:100%;justify-content:flex-start}
}

/* ======================= Study orbit, ranking, advice ======================= */
.person-card.orbit-on{--color:var(--success)}
.person-card.orbit-edge{--color:var(--warn);border-color:color-mix(in srgb,var(--warn) 35%,transparent)}
.person-card.orbit-off{--color:var(--danger);border-color:color-mix(in srgb,var(--danger) 40%,transparent);background:color-mix(in srgb,var(--danger) 4%,var(--surface))}
.pc-rank{flex:none;display:grid;place-items:center;min-width:40px;height:40px;padding:0 8px;border-radius:12px;background:var(--surface-2);font-weight:800;font-size:17px}
.pc-orbit{display:flex;flex-wrap:wrap;align-items:center;gap:8px;font-size:13px;color:var(--muted)}
.delta{font-size:12px;font-weight:800}
.delta.up{color:var(--success)}.delta.down{color:var(--danger)}.delta.same{color:var(--muted)}
/* group bar */
.orbit-bar{display:flex;height:16px;border-radius:99px;overflow:hidden;background:var(--surface-2)}
.orbit-bar span{display:block;height:100%}
.ob-on{background:var(--success)}.ob-edge{background:var(--gold-bright)}.ob-off{background:var(--danger)}.ob-none{background:var(--line-strong)}
.swatch.ob-on{background:var(--success)}.swatch.ob-edge{background:var(--gold-bright)}.swatch.ob-off{background:var(--danger)}.swatch.ob-none{background:var(--line-strong)}
/* a student's orbit card */
.orbit-card{--color:var(--brand-2)}
.orbit-card.orbit-on{--color:var(--success)}.orbit-card.orbit-edge{--color:var(--warn)}.orbit-card.orbit-off{--color:var(--danger)}
.orbit-card{background:color-mix(in srgb,var(--color) 6%,var(--surface));border-color:color-mix(in srgb,var(--color) 28%,transparent)}
.op-top{display:flex;align-items:center;gap:16px;margin-bottom:12px}
.op-score{display:grid;place-items:center;flex:none;width:92px;height:92px;border-radius:50%;border:6px solid color-mix(in srgb,var(--color) 70%,transparent);text-align:center;align-content:center}
.op-score strong{font-size:28px;line-height:1.1}.op-score small{font-size:12px;color:var(--muted)}
.op-place{display:grid;gap:4px}.op-place strong{font-size:16px}.op-place small{color:var(--muted);font-size:13px}
.op-parts{display:grid;gap:8px}
.op-part{display:grid;grid-template-columns:110px 1fr 48px;align-items:center;gap:10px;font-size:13px}
.op-part .progress{margin:0}.op-part .progress span{background:var(--color)}
.orbit-card details.more{margin-top:12px}
/* ranking list */
.rank-list{padding:8px}
.rank-row{display:grid;grid-template-columns:48px minmax(0,1.2fr) minmax(0,1.4fr) auto;align-items:center;gap:12px;width:100%;text-align:right;padding:12px;border-radius:14px;color:inherit}
.rank-row+.rank-row{border-top:1px solid var(--line)}
.rank-row:hover{background:var(--surface-2)}
.rr-rank{display:grid;place-items:center;width:44px;height:44px;border-radius:14px;background:var(--surface-2);font-size:18px;font-weight:800}
.rank-row:nth-child(1) .rr-rank{background:var(--gold-bright);color:#1f1400}
.rank-row:nth-child(2) .rr-rank,.rank-row:nth-child(3) .rr-rank{background:var(--gold-soft);color:var(--gold)}
.rr-name{display:grid;min-width:0}.rr-name strong{font-size:15px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.rr-name small{font-size:12px;color:var(--muted)}
.rr-score{display:grid;gap:4px}.rr-score .progress{margin:0}.rr-score small{font-size:12px;color:var(--muted)}
.rank-row.orbit-on .rr-score .progress span{background:var(--success)}.rank-row.orbit-edge .rr-score .progress span{background:var(--gold-bright)}.rank-row.orbit-off .rr-score .progress span{background:var(--danger)}
.rr-end{display:flex;flex-direction:column;align-items:flex-end;gap:4px}
/* advice */
.advice-suggest{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:12px}
.advice-suggest small{width:100%;color:var(--muted)}
.chip-suggest{font-size:13px;line-height:1.7;text-align:right;padding:6px 12px;min-height:44px;border-radius:14px;background:var(--gold-soft);color:var(--ink);border:1px solid color-mix(in srgb,var(--gold) 25%,transparent)}
.chip-suggest:hover{border-color:var(--gold)}
#advice-form textarea{min-height:96px}
.advice-list{display:grid;gap:10px;margin-top:14px}
.advice-item{padding:12px 14px;border-radius:14px;background:var(--surface-2)}
.advice-item.done{opacity:.8}
.advice-item p{margin:6px 0 0;line-height:1.9}
.advice-item small{color:var(--muted);font-size:12px}
.advice-card{--color:var(--gold);background:color-mix(in srgb,var(--color) 10%,var(--surface));border:1px solid color-mix(in srgb,var(--color) 32%,transparent);border-radius:20px;padding:14px 16px;margin-bottom:12px}
.advice-card.unread{box-shadow:0 0 0 2px color-mix(in srgb,var(--color) 50%,transparent)}
.ac-head{display:flex;align-items:center;gap:12px}
.ac-head div{display:grid}.ac-head small{color:var(--muted);font-size:12px}
.advice-card p{margin:10px 0 0;line-height:2;font-size:15px}
.ac-actions{display:flex;gap:8px;justify-content:flex-end;margin-top:10px}
@media (max-width:900px){
  .rank-row{grid-template-columns:44px minmax(0,1fr) auto;grid-template-areas:"r n e" "r s s"}
  .rr-rank{grid-area:r}.rr-name{grid-area:n}.rr-score{grid-area:s}.rr-end{grid-area:e}
  .op-part{grid-template-columns:96px 1fr 44px}
  .op-score{width:80px;height:80px}.op-score strong{font-size:24px}
}
@media print{.rank-row{break-inside:avoid}.filter-bar,.day-tools{display:none!important}}

/* ===== Mobile sign-in, password recovery, linking a number ===== */
.auth-alt{display:grid;gap:10px;justify-items:center;margin-top:16px;padding-top:16px;border-top:1px solid var(--line)}
.auth-alt .btn{width:100%}
.otp-input{text-align:center;font-size:24px;letter-spacing:10px;font-variant-numeric:tabular-nums;font-weight:800}
#otp-form{display:grid;gap:14px}
#otp-form .link-btn{justify-self:center}
.dev-code{background:var(--gold-soft);border-radius:10px;padding:6px 10px}
.phone-box .form-actions{margin-top:10px}
#otp-step2{display:grid;gap:12px}
#otp-step2.hidden{display:none}

/* ===== Study outside the plan ===== */
.extra-panel .plan-items{margin-bottom:4px}
.extra-card .badge{background:var(--gold-soft);color:var(--gold)}
.extra-add{width:100%;border-style:dashed}
.label-like{font-size:13px;color:var(--muted);font-weight:600}
.quick-min{gap:6px}.quick-min .chip{min-width:52px;min-height:44px}

/* ---------- Subjects of the other grades and tracks (programs.mjs) reuse the palette ---------- */
[data-subject=hesaban]{--color:var(--c-math)}.s-hesaban{fill:var(--v-math);stroke:var(--v-math)}.swatch.s-hesaban{background:var(--v-math)}.series-s-hesaban{--color:var(--v-math)}
[data-subject=riazi]{--color:var(--c-math)}.s-riazi{fill:var(--v-math);stroke:var(--v-math)}.swatch.s-riazi{background:var(--v-math)}.series-s-riazi{--color:var(--v-math)}
[data-subject=hendese]{--color:var(--c-bio)}.s-hendese{fill:var(--v-bio);stroke:var(--v-bio)}.swatch.s-hendese{background:var(--v-bio)}.series-s-hendese{--color:var(--v-bio)}
[data-subject=adabi]{--color:var(--c-bio)}.s-adabi{fill:var(--v-bio);stroke:var(--v-bio)}.swatch.s-adabi{background:var(--v-bio)}.series-s-adabi{--color:var(--v-bio)}
[data-subject=arabi]{--color:var(--c-physics)}.s-arabi{fill:var(--v-physics);stroke:var(--v-physics)}.swatch.s-arabi{background:var(--v-physics)}.series-s-arabi{--color:var(--v-physics)}
[data-subject=jameh]{--color:var(--c-chem)}.s-jameh{fill:var(--v-chem);stroke:var(--v-chem)}.swatch.s-jameh{background:var(--v-chem)}.series-s-jameh{--color:var(--v-chem)}
[data-subject=amar]{--color:var(--v-7)}.s-amar{fill:var(--v-7);stroke:var(--v-7)}.swatch.s-amar{background:var(--v-7)}.series-s-amar{--color:var(--v-7)}
[data-subject=gosaste]{--color:var(--v-7)}.s-gosaste{fill:var(--v-7);stroke:var(--v-7)}.swatch.s-gosaste{background:var(--v-7)}.series-s-gosaste{--color:var(--v-7)}
[data-subject=geo]{--color:var(--v-6)}.s-geo{fill:var(--v-6);stroke:var(--v-6)}.swatch.s-geo{background:var(--v-6)}.series-s-geo{--color:var(--v-6)}
[data-subject=tarikh]{--color:var(--v-6)}.s-tarikh{fill:var(--v-6);stroke:var(--v-6)}.swatch.s-tarikh{background:var(--v-6)}.series-s-tarikh{--color:var(--v-6)}
[data-subject=joghrafi]{--color:var(--v-7)}.s-joghrafi{fill:var(--v-7);stroke:var(--v-7)}.swatch.s-joghrafi{background:var(--v-7)}.series-s-joghrafi{--color:var(--v-7)}
[data-subject=mantegh]{--color:var(--v-8)}.s-mantegh{fill:var(--v-8);stroke:var(--v-8)}.swatch.s-mantegh{background:var(--v-8)}.series-s-mantegh{--color:var(--v-8)}
[data-subject=falsafe]{--color:var(--v-8)}.s-falsafe{fill:var(--v-8);stroke:var(--v-8)}.swatch.s-falsafe{background:var(--v-8)}.series-s-falsafe{--color:var(--v-8)}
[data-subject=eghtesad]{--color:var(--c-general)}.s-eghtesad{fill:var(--v-general);stroke:var(--v-general)}.swatch.s-eghtesad{background:var(--v-general)}.series-s-eghtesad{--color:var(--v-general)}
[data-subject=ravan]{--color:var(--c-analysis)}.s-ravan{fill:var(--c-analysis);stroke:var(--c-analysis)}.swatch.s-ravan{background:var(--c-analysis)}.series-s-ravan{--color:var(--c-analysis)}
/* Profile */
.profile-link{width:100%;text-align:start;color:inherit;background:none;cursor:pointer;border-radius:12px;transition:background-color .15s var(--ease)}
.profile-link:hover{background:#ffffff12}.profile-link:focus-visible{outline:2px solid var(--gold-bright);outline-offset:2px}
.book-chips{display:flex;flex-wrap:wrap;gap:8px;list-style:none;margin:0;padding:0}
.book-chip{display:inline-flex;align-items:center;gap:6px;min-height:36px;padding:0 12px;border-radius:999px;background:var(--surface-2);border:1px solid var(--line);font-size:14px;font-weight:600}
.book-chip .icon{color:var(--brand-2)}
.book-chip.review{background:transparent;border-style:dashed;color:var(--muted)}
.book-chip.review .icon{color:var(--muted)}
.list-row:has(.btn){display:flex;align-items:center;justify-content:space-between;gap:12px}
/* Study timer: a floating bar above the content (and above the tab bar on phones) */
.focus-timer{margin-top:10px}
/* Study buddies */
.inline-form{display:flex;flex-wrap:wrap;align-items:flex-end;gap:10px}
.inline-form .field{flex:1;min-width:160px;margin:0}
.inline-form .error:empty{display:none}
.inline-form .error{flex-basis:100%}
.league{list-style:none;margin:0;padding:0}
.league li{display:grid;grid-template-columns:1fr auto 44px 40px;align-items:center;gap:10px;padding:10px 4px;border-bottom:1px solid var(--line)}
.league li:last-child{border-bottom:0}
.league li.me{background:var(--success-soft);border-radius:var(--radius-sm)}
.league-name{font-weight:700;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#friend-code{font-size:20px;font-weight:800;letter-spacing:3px;text-align:center;flex:1;min-width:0}
/* Percentage calculator and tools */
.pct-field{display:flex;flex-direction:column}
.pct-calc{margin-top:-4px;font-size:13px}
.pct-calc summary{cursor:pointer;color:var(--brand-2);padding:6px 0;min-height:32px}
.calc-row{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
.calc-row label{display:flex;flex-direction:column;gap:4px;font-size:13px;color:var(--muted)}
.calc-row input{width:100%;min-width:0}
.gpa-row{display:grid;grid-template-columns:2fr 1fr 1fr;gap:8px;margin-bottom:8px}
.gpa-row input{width:100%;min-width:0}
.league-score{font-weight:800;text-align:center}
.back-card{align-items:center}
.back-card .btn{margin-inline-start:auto;flex:none}
.finish-choices{display:grid;gap:10px;margin-top:8px}
.finish-choices .btn{min-height:52px;font-size:15px}
.big-stat{font-size:15px;margin:8px 0}
.big-stat strong{font-size:28px;font-weight:800;margin-inline-end:4px}
/* Profile: books open to chapters and topics; unticked topics leave the path */
.book-tree{display:grid;gap:8px}
.book-node{border:1px solid var(--line);border-radius:var(--radius-sm);background:var(--surface)}
.book-node.review{border-style:dashed}
.book-node summary{display:flex;align-items:center;justify-content:space-between;gap:10px;min-height:48px;padding:8px 14px;cursor:pointer;list-style:none}
.book-node summary::-webkit-details-marker{display:none}
.book-node summary:focus-visible{outline:2px solid var(--ring);outline-offset:2px;border-radius:var(--radius-sm)}
.book-node .bn-title{display:inline-flex;align-items:center;gap:8px;font-weight:700}
.book-node .bn-title .icon{color:var(--brand-2)}
.book-node .bn-count{font-size:13px;color:var(--muted);white-space:nowrap}
.book-node[open] summary{border-bottom:1px solid var(--line)}
.bn-body{padding:6px 14px 12px}
.bn-chapter{border:0;margin:8px 0 0;padding:0}
.bn-chapter legend{padding:0;margin-bottom:2px}
.bn-chapter legend .check-row{min-height:40px}
.bn-topic{display:flex;align-items:center;gap:8px;min-height:40px;padding-inline-start:26px;font-size:14px}
.bn-topic span{flex:1}
.bn-topic small{color:var(--muted);white-space:nowrap}
.bn-topic:has(input:not(:checked)) span{color:var(--muted);text-decoration:line-through}
/* Learning cycle */
.cycle-bars .subject-row{margin-top:10px}
.st-chip{position:relative;margin-inline-start:auto;flex:none;min-height:30px;padding:0 10px;border-radius:999px;border:1px dashed var(--line-strong);background:transparent;color:var(--muted);font-size:12px;cursor:pointer}
.st-chip.set{border-style:solid;background:var(--surface-2);color:var(--ink);font-weight:700}
.st-chip:focus-visible{outline:2px solid var(--ring);outline-offset:2px}
.bn-topic small{margin-inline-start:auto}
.bn-topic small+.st-chip{margin-inline-start:8px}
.st-chip::after{content:'';position:absolute;inset:-7px -4px}
.feedback-row .choice span{font-size:13px}
/* Backlog and plan time */
.backlog-list{margin:8px 0 0;padding-inline-start:18px;font-size:14px;display:grid;gap:4px}
.backlog-list small{color:var(--muted)}
.review-list{margin:4px 0 6px;padding-inline-start:18px;display:grid;gap:2px}
.review-list small{color:var(--muted)}
.behind-actions{margin:10px 0 4px}
/* Guide */
.help-tools{display:grid;gap:12px}
.help-toc{display:flex;flex-wrap:wrap;gap:8px}
.help-toc a{display:inline-flex;align-items:center;min-height:44px;padding:0 14px;border-radius:999px;border:1px solid var(--line-strong);background:var(--surface);color:var(--ink);font-size:13.5px;font-weight:600;text-decoration:none;transition:background-color .15s var(--ease)}
.help-toc a:hover{background:var(--surface-2)}
.help-toc a:focus-visible{outline:2px solid var(--ring);outline-offset:2px}
.help-section{padding:0;scroll-margin-top:16px}
.help-section>summary{display:flex;align-items:center;gap:12px;padding:16px 18px;cursor:pointer;list-style:none;min-height:var(--tap)}
.help-section>summary::-webkit-details-marker{display:none}
.help-section>summary::after{content:'';margin-inline-start:auto;width:9px;height:9px;flex:none;border-inline-end:2px solid var(--muted);border-block-end:2px solid var(--muted);transform:rotate(45deg);transition:transform .2s var(--ease)}
.help-section[open]>summary::after{transform:rotate(-135deg)}
.help-section>summary:focus-visible{outline:2px solid var(--ring);outline-offset:-2px;border-radius:var(--radius)}
.help-section>summary strong{display:block;font-size:16px}
.help-section>summary small{display:block;color:var(--muted);font-size:13.5px;margin-top:2px;line-height:1.6}
.help-icon{display:grid;place-items:center;width:40px;height:40px;flex:none;border-radius:12px;background:var(--surface-2);color:var(--brand-2)}
.help-body{padding:0 18px 18px;border-top:1px solid var(--line)}
.help-body h3{font-size:15px;margin:16px 0 8px}
.help-body p{line-height:1.9;margin:0 0 8px}
.help-steps{margin:0;padding-inline-start:20px;display:grid;gap:7px;line-height:1.9}
.help-steps li::marker{color:var(--gold);font-weight:700}
.help-body .callout{margin:14px 0 0;line-height:1.9}
.help-terms{display:grid;gap:10px;margin:14px 0 0}
.help-terms dt{font-weight:700}
.help-terms dd{margin:2px 0 0;color:var(--muted);line-height:1.8}
#help-list{display:grid;gap:12px}
@media (prefers-reduced-motion:reduce){.help-section>summary::after{transition:none}}
/* Landing — ره‌تیک (brand document, 2026-10-25) */
.lp{overflow-x:clip}
.lp-logo{display:inline-flex;align-items:center;gap:10px}
.lp-mark{width:34px;height:34px;flex:none;border-radius:10px}
.lp-latin{font-size:13px;font-weight:700;color:var(--muted);letter-spacing:.3px;border-inline-start:1px solid var(--line-strong);padding-inline-start:10px}
.lp-top{background:color-mix(in srgb,var(--bg) 90%,transparent);backdrop-filter:blur(12px)}
.lp-band{position:relative;overflow:hidden;margin-inline:calc(50% - 50vw);padding:0 max(20px,calc(50vw - 540px));background:radial-gradient(ellipse at 15% 0%,#14305c 0%,transparent 60%),#081226;color:#f2f6ff}
.lp-path{position:absolute;inset:0;width:100%;height:100%;opacity:.55;filter:drop-shadow(0 0 10px #10b98199);pointer-events:none}
.lp-band .lp-hero{position:relative;z-index:1;padding:56px 0 64px}
.lp-band .eyebrow{color:#fbbf24}
.lp-band h1{color:#f2f6ff}
.lp-band .lp-copy>p{color:#b9c4da}
.lp-band .lp-note{color:#9aa8c3}
.lp-rah,.lp-tik{font-style:normal}
.lp-rah{color:#10b981}
.lp-tik{color:#fbbf24}
.lp-band .btn.lp-main{background:#10b981;color:#04241b}
.lp-band .btn.lp-main:hover{background:#34d399}
.btn.lp-ghost{background:#ffffff14;color:#f2f6ff;border:1px solid #ffffff38}
.btn.lp-ghost:hover{background:#ffffff24}
.lp-band .lp-phone{background:#030812;box-shadow:0 30px 80px #0009,0 0 0 1px #ffffff14}
.lp-compare{display:grid;border:1px solid var(--line);border-radius:20px;overflow:hidden;background:var(--surface)}
.lp-compare-head,.lp-compare-row{display:grid;grid-template-columns:1fr 1fr}
.lp-compare-head span{display:flex;align-items:center;gap:8px;padding:14px 18px;font-weight:800;background:var(--surface-2)}
.lp-compare-head span:first-child{color:var(--danger)}
.lp-compare-head span:last-child{color:var(--success)}
.lp-compare-row span[role=cell]{display:flex;gap:10px;align-items:flex-start;padding:14px 18px;border-top:1px solid var(--line);line-height:1.9;font-size:14.5px}
.lp-compare-row span[role=cell]+span[role=cell],.lp-compare-head span+span{border-inline-start:1px solid var(--line)}
.lp-x .icon{color:var(--danger);margin-top:5px}
.lp-x>span{color:var(--muted)}
.lp-v .icon{color:var(--success);margin-top:5px}
.lp-v>span{font-weight:600}
.lp-steps{position:relative}
.lp-steps li:before{display:none}
.lp-steps .lp-step-n{display:grid;place-items:center;width:40px;height:40px;border-radius:50%;background:#081226;color:#10b981;font-weight:800;font-size:18px;box-shadow:0 0 0 4px var(--success-soft)}
.lp-steps li{gap:8px}
.lp-feature-icon{background:var(--success-soft);color:var(--success)}
.lp-features{grid-template-columns:repeat(4,1fr)}
.lp-story{margin-top:18px;padding:26px 28px;border-radius:22px;background:linear-gradient(160deg,color-mix(in srgb,#fbbf24 16%,var(--surface)) 0%,var(--surface) 70%);border:1px solid color-mix(in srgb,#fbbf24 45%,transparent);border-inline-start:5px solid #fbbf24}
.lp-story h3{font-size:20px;margin:4px 0 12px}
.lp-story p{line-height:2.1;margin:0 0 10px;max-width:820px}
.lp-story p:last-child{margin:0;font-weight:600}
.lp-final{background:radial-gradient(ellipse at 80% 100%,#0f4a3c 0%,transparent 55%),#081226}
.lp-final .btn{background:#10b981;color:#04241b}
.lp-final .btn:hover{background:#34d399}
.lp-foot{display:grid;justify-items:center;gap:6px}
.lp-foot .brand{font-size:18px}
@media (max-width:1100px){.lp-features{grid-template-columns:repeat(2,1fr)}}
@media (max-width:860px){
  .lp-band .lp-hero{padding:28px 0 40px}
  .lp-path{display:none}
  .lp-features{grid-template-columns:1fr}
  .lp-compare-head{display:none}
  .lp-compare-row{grid-template-columns:1fr}
  .lp-compare-row span[role=cell]+span[role=cell]{border-inline-start:0;border-top:1px dashed var(--line);background:color-mix(in srgb,var(--success-soft) 45%,var(--surface))}
  .lp-latin{display:none}
  .lp-story{padding:20px}
}
@media (prefers-reduced-motion:reduce){.lp-path{filter:none}}
/* Public pages (site.mjs): navigation, article pages, tables, track links */
a.btn{text-decoration:none}
.lp-top .lp-logo{text-decoration:none;color:inherit;min-height:44px}
.sp-nav{display:flex;gap:4px;flex-wrap:wrap;margin-inline-start:auto;margin-inline-end:12px}
.sp-nav a{padding:8px 12px;border-radius:10px;color:var(--ink);text-decoration:none;font-weight:600;font-size:14px}
.sp-nav a:hover{background:var(--surface-2)}
.sp-band .sp-hero{position:relative;z-index:1;padding:48px 0 56px;max-width:820px}
.sp-band h1{color:#f2f6ff;font-size:38px;line-height:1.4;margin:6px 0 14px}
.sp-band p{color:#b9c4da;font-size:17px;line-height:2}
.sp-crumbs{font-size:13px;color:#9aa8c3}.sp-crumbs a{color:#fbbf24;text-decoration:none}
.sp-article{max-width:920px;margin:0 auto}
.sp-article .lp-section>p{line-height:2.1;margin:0 0 12px}
.sp-article .lp-section a{color:var(--brand-2);font-weight:700}
.sp-list{margin:0;padding-inline-start:20px;display:grid;gap:8px;line-height:2}
.sp-table{width:100%;border-collapse:collapse;margin:8px 0 16px;font-size:14.5px;background:var(--surface);border:1px solid var(--line);border-radius:16px;overflow:hidden}
.sp-table th,.sp-table td{padding:10px 14px;text-align:start;border-bottom:1px solid var(--line)}
.sp-table th{background:var(--surface-2);font-weight:800}
.sp-table td:first-child{font-variant-numeric:tabular-nums;white-space:nowrap;color:var(--muted)}
.lp-tracks{display:grid;grid-template-columns:repeat(3,1fr);gap:16px}
.lp-track{display:grid;gap:6px;padding:20px;border-radius:20px;border:1px solid var(--line);background:var(--surface);color:var(--ink);text-decoration:none;transition:box-shadow .2s var(--ease),transform .15s var(--ease)}
.lp-track:hover{box-shadow:var(--shadow);transform:translateY(-1px)}
.lp-track strong{font-size:17px;color:var(--brand-2)}.lp-track span{color:var(--muted);font-size:14px;line-height:1.9}
.lp-more{margin:18px 0 0;line-height:2.2}.lp-more a{display:inline-flex;align-items:center;min-height:44px;color:var(--brand-2);font-weight:700}
.lp-contact{display:block;margin-top:4px}
.pkg-grid.pkg-two{grid-template-columns:repeat(auto-fit,minmax(240px,1fr));max-width:760px;margin-inline:auto}
.support-link{display:inline-flex;align-items:center;min-height:44px;padding:0 4px;font-weight:700;color:var(--brand-2);text-decoration:none;unicode-bidi:isolate}
.lp-links{display:flex;flex-wrap:wrap;justify-content:center;gap:0 12px;margin-top:6px}
.lp-links a{display:inline-flex;align-items:center;min-height:44px;padding:0 2px;color:var(--muted);text-decoration:none;font-size:13px}.lp-links a:hover{color:var(--ink)}
@media (max-width:1000px){.sp-nav{display:none}}
@media (max-width:860px){.lp-tracks{grid-template-columns:1fr}.sp-band h1{font-size:28px}.sp-band .sp-hero{padding:28px 0 36px}.sp-table{font-size:13.5px}.sp-table th,.sp-table td{padding:8px 10px}}
/* ── Staff panels (2026-10-25): dashboard, student file, follow-up, notices, activity log, sign-in links ── */
.dash-bar{display:grid;grid-template-columns:minmax(110px,40%) 1fr auto;align-items:center;gap:12px;padding:6px 0;font-size:14px}
.dash-bar .progress{margin:0}
.dash-row{display:flex;align-items:center;gap:12px;width:100%;padding:10px 6px;border:0;border-bottom:1px solid var(--line);background:none;color:inherit;font:inherit;text-align:start;cursor:pointer;min-height:var(--tap)}
.dash-row:last-child{border-bottom:0}.dash-row:hover{background:var(--surface-2)}.dash-row:focus-visible{outline:2px solid var(--brand-2);outline-offset:2px}
.dash-row-main{display:grid;flex:1;gap:2px;min-width:0}.dash-row-main small{color:var(--muted);font-size:12.5px}
.facts{display:grid;grid-template-columns:repeat(auto-fill,minmax(170px,1fr));gap:10px}
.fact{background:var(--surface-2);border-radius:var(--radius-sm);padding:10px 12px;display:grid;gap:2px}
.fact small{color:var(--muted);font-size:12px}.fact strong{font-size:14px;overflow-wrap:anywhere}
.student-file .chip-row{margin-bottom:8px}
.audit-list{margin-top:12px}
.audit-row{display:grid;grid-template-columns:150px 1fr;gap:12px;padding:10px 0;border-bottom:1px solid var(--line);font-size:14px}
.audit-row:last-child{border-bottom:0}
.audit-when{color:var(--muted);font-size:12.5px}.audit-detail{display:block;color:var(--muted);margin-top:2px}
.audit-mini{display:grid;gap:1px;padding:6px 0;border-bottom:1px solid var(--line);font-size:13px}.audit-mini small{color:var(--muted)}
.notice-text{margin:6px 0;line-height:1.9}
.notice-bar{margin-bottom:14px;align-items:center}.notice-bar>div{flex:1;line-height:1.9}
.notice-close{width:36px;height:36px;flex:none}
.auth-roles{margin-top:14px;text-align:center;font-size:13.5px;color:var(--muted)}
.lp-login{margin-top:10px;align-items:center}.lp-login span{color:var(--muted);font-size:13px}
@media (max-width:640px){.audit-row{grid-template-columns:1fr;gap:2px}.dash-bar{grid-template-columns:1fr auto}.dash-bar .progress{grid-column:1/-1;order:3}}
.muted{color:var(--muted)}
.student-file .chip{display:inline-flex;align-items:center;gap:6px}
/* ── Quick record (2026-10-25): one sheet, one tap per session ── */
.quick-sheet{display:grid;gap:12px}
.quick-big{width:100%;min-height:54px;font-size:16px;justify-content:center}
.quick-two{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.quick-missed{background:var(--surface-2);border-radius:var(--radius-sm);padding:12px}
.quick-missed .note{margin:0}
.reason-chips{display:flex;flex-wrap:wrap;gap:8px;margin-top:8px}
.reason-chips .chip-suggest{min-height:40px}
.chip-suggest.on{background:var(--brand-2);border-color:var(--brand-2);color:var(--on-accent)}
.quick-other{display:grid;grid-template-columns:1fr auto;gap:8px;align-items:end;margin-top:10px}
.quick-sheet [hidden]{display:none}
.quick-other textarea{min-height:0}
.quick-foot{display:flex;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap;font-size:14px}
.quick-all{justify-self:center;font-size:13.5px}
.quick-score{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
.quick-score label{display:grid;gap:4px;font-size:13px;color:var(--muted)}
.callout [data-quick-day]{flex:none;align-self:center}
/* ── «تیک‌تاک» (2026-10-25): launcher, chip and the focus view. The focus view is dark in both themes. ── */
.tt-fab{position:fixed;z-index:35;inset-inline-end:16px;bottom:20px;display:flex;align-items:center;gap:10px;min-height:56px;padding:9px 18px 9px 10px;border:0;border-radius:999px;background:linear-gradient(135deg,#0b1f3f,#14406a);color:#fff;box-shadow:0 10px 28px rgba(8,18,38,.35);font:inherit;cursor:pointer;transition:transform .2s var(--ease)}
.tt-fab:hover{transform:translateY(-2px)}.tt-fab:focus-visible{outline:3px solid #fbbf24;outline-offset:3px}
.tt-fab-icon{display:grid;place-items:center;width:38px;height:38px;border-radius:50%;background:#10b981;color:#06261b}
.tt-fab-text{display:grid;line-height:1.35;text-align:start}.tt-fab-text strong{font-size:15px}.tt-fab-text small{font-size:12px;opacity:.85}
.tt-fab.is-compact{padding:9px}.tt-fab.is-compact .tt-fab-text{display:none}
.tt-chip{position:fixed;z-index:35;inset-inline-end:16px;bottom:20px;display:flex;align-items:center;gap:9px;min-height:50px;max-width:min(340px,calc(100vw - 32px));padding:8px 16px;border:0;border-radius:999px;background:#081226;color:#fff;box-shadow:0 10px 28px rgba(8,18,38,.35);font:inherit;cursor:pointer}
.tt-chip strong{font-size:18px;font-variant-numeric:tabular-nums}
.tt-chip small{font-size:12px;opacity:.8;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.tt-chip-dot{width:10px;height:10px;border-radius:50%;background:#10b981;flex:none;animation:tt-pulse 2s ease-in-out infinite}
.tt-chip.is-pause .tt-chip-dot{background:#7dd3fc;animation:none}.tt-chip.is-done{background:#7a3d05}.tt-chip.is-done .tt-chip-dot{background:#fbbf24}
.tt-chip:focus-visible{outline:3px solid #fbbf24;outline-offset:3px}
.tt{position:fixed;inset:0;z-index:60;display:flex;justify-content:center;overflow:auto;padding:max(12px,env(safe-area-inset-top)) 16px max(16px,env(safe-area-inset-bottom));background:radial-gradient(120% 80% at 50% 0%,#14365f 0%,#081226 62%);color:#e7edf8}
.tt-sheet{width:100%;max-width:460px;min-height:100%;display:flex;flex-direction:column;align-items:center;gap:14px}
.tt-top{width:100%;display:flex;align-items:center;justify-content:space-between}
.tt-brand{font-size:18px;font-weight:800}.tt-brand span{color:#fbbf24}
.tt-icon{display:grid;place-items:center;width:44px;height:44px;border-radius:50%;border:1px solid #ffffff2a;background:#ffffff12;color:inherit;cursor:pointer}
.tt-head{display:flex;align-items:center;justify-content:center;gap:10px;text-align:center}
.tt-head h2{margin:0;font-size:20px;line-height:1.6;color:#fff}
.tt-dot{width:12px;height:12px;border-radius:50%;background:var(--color,#10b981);flex:none}
.tt-ring{position:relative;display:grid;place-items:center;width:min(78vw,320px);aspect-ratio:1;margin:2px 0}
.tt-ring-svg{position:absolute;inset:0;width:100%;height:100%}
.tt-track{fill:none;stroke:#ffffff14;stroke-width:12}
.tt-progress{fill:none;stroke:#10b981;stroke-width:12;stroke-linecap:round;transition:stroke-dashoffset 1s linear,stroke .4s}
.tt-tick{stroke:#ffffff30;stroke-width:4;stroke-linecap:round;transition:stroke .4s}.tt-tick.on{stroke:#fbbf24}
.tt-center{position:relative;display:grid;justify-items:center;gap:2px;text-align:center}
.tt-center small{font-size:13px;color:#a9b8d4}
.tt-time{font-size:clamp(44px,14vw,64px);font-weight:800;line-height:1.15;letter-spacing:1px;font-variant-numeric:tabular-nums;color:#fff}
.tt.is-done .tt-progress{stroke:#fbbf24}.tt.is-done .tt-time{color:#fbbf24}
.tt.is-pause .tt-progress{stroke:#7dd3fc}.tt.is-over .tt-progress{stroke:#f87171}
.tt-breath{position:absolute;width:56%;aspect-ratio:1;border-radius:50%;background:radial-gradient(circle,#7dd3fc40,transparent 70%);opacity:0;transform:scale(.8)}
.tt.is-pause .tt-breath{opacity:1;animation:tt-breath 8s ease-in-out infinite}
@keyframes tt-breath{0%,100%{transform:scale(.75)}50%{transform:scale(1.15)}}
@keyframes tt-pulse{0%,100%{opacity:1}50%{opacity:.35}}
.tt-word{max-width:380px;min-height:3.8em;margin:0;text-align:center;font-size:16px;line-height:1.9;color:#e7edf8}
.tt-controls{width:100%;display:grid;grid-template-columns:1fr 1fr;gap:10px}
.tt-btn{display:flex;align-items:center;justify-content:center;gap:8px;min-height:56px;border-radius:16px;border:1px solid #ffffff2a;background:#ffffff12;color:inherit;font:inherit;font-size:16px;font-weight:700;cursor:pointer}
.tt-finish{background:#10b981;border-color:#10b981;color:#062a1d}
.tt-btn.tt-resume{background:#fbbf24;border-color:#fbbf24;color:#2a1c00}
.tt-btn:focus-visible,.tt-icon:focus-visible,.tt-discard:focus-visible,.tt-what summary:focus-visible{outline:3px solid #fbbf24;outline-offset:2px}
.tt-what{width:100%;padding:10px 14px;border:1px solid #ffffff1a;border-radius:14px;background:#ffffff0d}
.tt-what summary{display:flex;align-items:center;min-height:36px;font-weight:700;cursor:pointer}
.tt-what ul{margin:8px 0;padding-inline-start:18px;font-size:14px;line-height:1.9}
.tt-tip{display:flex;align-items:flex-start;gap:8px;margin:6px 0 0;font-size:13.5px;line-height:1.8;color:#c9d6ee}
.tt-discard{margin-top:auto;padding:8px;border:0;background:none;color:#a9b8d4;font:inherit;font-size:13px;text-decoration:underline;cursor:pointer}
body.tt-open{overflow:hidden}
.tt-picker{display:grid;gap:10px}
.tt-pick{display:flex;align-items:center;gap:12px;width:100%;min-height:64px;padding:10px 14px;border:1px solid var(--line);border-inline-start:5px solid var(--color,var(--brand-2));border-radius:14px;background:var(--surface);color:var(--ink);font:inherit;text-align:start;cursor:pointer}
.tt-pick:hover{background:var(--surface-2)}.tt-pick:focus-visible{outline:2px solid var(--brand-2);outline-offset:2px}
.tt-pick-icon{display:grid;place-items:center;width:40px;height:40px;border-radius:12px;flex:none;background:color-mix(in srgb,var(--color,var(--brand-2)) 15%,transparent);color:var(--color,var(--brand-2))}
.tt-pick-main{display:grid;gap:2px;flex:1;min-width:0}.tt-pick-main small{font-size:12.5px;color:var(--muted)}
.tt-pick-free{border-style:dashed;border-inline-start-style:solid}
@media (max-width:900px){.tt-fab,.tt-chip{bottom:calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 12px)}body.has-tiktak .main{padding-bottom:calc(var(--tabbar-h) + 96px)}}
@media (prefers-reduced-motion:reduce){.tt-progress,.tt-tick,.tt-fab{transition:none}.tt.is-pause .tt-breath,.tt-chip-dot{animation:none}}
.legal h3{margin:14px 0 6px;font-size:16px}.legal ul{line-height:2;padding-inline-start:20px}.legal p{line-height:2}
.legal-hint{display:block;text-align:center;margin-top:10px;line-height:1.9}.legal-hint a{color:var(--brand-2);font-weight:700}
/* ── Sign-in pages (2026-10-25): one look per kind of account ── */
.auth{--portal:var(--brand-2);border-top:6px solid var(--portal)}
.auth .auth-mark{background:var(--portal)}
.auth.portal-parent{--portal:#c2410c}
.auth.portal-supporter{--portal:#2563eb}
.auth.portal-admin{--portal:#0b1730;max-width:400px}
:root[data-theme="dark"] .auth.portal-admin,.dark .auth.portal-admin{--portal:#334155}
@media (prefers-color-scheme:dark){:root:not([data-theme="light"]) .auth.portal-admin{--portal:#334155}}
.auth .eyebrow{color:var(--portal)}
.auth-how{display:flex;gap:10px;align-items:flex-start;margin-top:16px;padding:12px 14px;border-radius:var(--radius-sm);background:color-mix(in srgb,var(--portal) 8%,var(--surface));border:1px solid color-mix(in srgb,var(--portal) 22%,transparent);font-size:13.5px;line-height:1.9}
.auth-how p{margin:0}.auth-how .btn{margin-top:10px;width:100%}.auth-how>svg{flex:none;margin-top:4px;color:var(--portal)}
.auth-redirect{margin:4px 0 8px}.auth-redirect .btn{width:100%}
.parent-code{display:grid;justify-items:center;gap:2px;margin:12px 0 8px;padding:14px;border-radius:var(--radius-sm);background:var(--surface-2);text-align:center}
.parent-code strong{font-size:30px;letter-spacing:6px;font-variant-numeric:tabular-nums}.parent-code small{color:var(--muted)}
.auth form .btn[type=submit]{background:var(--portal);border-color:var(--portal);color:#fff}
/* ── Subscription (2026-10-25): packages, checkout, payment, the admin's sales tab ── */
.pkg-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:18px}
.pkg{position:relative;display:flex;flex-direction:column;gap:6px;padding:22px 18px 18px;border:1px solid var(--line);border-radius:var(--radius);background:var(--surface);box-shadow:var(--shadow)}
.pkg h3{margin:0;font-size:18px}.pkg-days{color:var(--muted)}
.pkg.best{border:2px solid var(--brand-2);transform:translateY(-4px);box-shadow:0 14px 34px color-mix(in srgb,var(--brand-2) 22%,transparent)}
.pkg-badge{position:absolute;top:-12px;inset-inline-start:16px;padding:3px 12px;border-radius:999px;background:var(--brand-2);color:var(--on-accent);font-size:12px;font-weight:700}
.pkg-badge.soft{background:var(--gold-soft);color:var(--gold)}
.pkg-price{display:flex;flex-wrap:wrap;align-items:baseline;gap:6px;margin-top:6px}
.pkg-price del{width:100%;color:var(--muted);font-size:14px}.pkg-price strong{font-size:28px;font-weight:800;font-variant-numeric:tabular-nums}.pkg-price small{color:var(--muted)}
.pkg-month{margin:0;color:var(--muted);font-size:13px}
.pkg-gift{margin:0;display:flex;gap:6px;align-items:center;color:var(--gold);font-size:13px;font-weight:700}
.pkg .btn{margin-top:auto;width:100%}
.pkg-features{list-style:none;padding:0;margin:0;display:grid;gap:8px;font-size:14px}.pkg-features li{display:flex;gap:8px;align-items:flex-start}.pkg-features svg{color:var(--success);flex:none;margin-top:3px}
.order-card{border:2px solid var(--gold)}
.pay-amount{display:grid;gap:2px;margin:6px 0 12px}.pay-amount strong{font-size:30px;font-weight:800}.pay-amount small{color:var(--muted)}
.pay-box{display:grid;gap:8px}.pay-line{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:10px;padding:10px 12px;border-radius:var(--radius-sm);background:var(--surface-2)}
.pay-line small{color:var(--muted)}.pay-line strong{font-size:16px;letter-spacing:1px;overflow-wrap:anywhere}
.checkout-sum{display:grid;gap:2px;padding:12px 14px;border-radius:var(--radius-sm);background:var(--surface-2);margin-bottom:12px}.checkout-sum .total{border-top:1px solid var(--line);margin-top:6px;padding-top:8px;font-size:16px}
.checkout-sum del{color:var(--muted);font-size:13px}.success-text{color:var(--success)}
.code-row{display:grid;grid-template-columns:1fr auto;gap:8px;align-items:end}
.billing-bar{align-items:center;margin-bottom:14px}.billing-bar>div{flex:1}
.offer p{line-height:2}.offer .btn{width:100%;margin-top:8px}
.order-row{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:10px;padding:12px 0;border-bottom:1px solid var(--line)}
.order-row:last-child{border-bottom:0}.order-main{display:grid;gap:3px;min-width:0;flex:1}.order-main small{color:var(--muted)}
.pkg-table{display:grid;gap:10px}.pkg-edit{display:grid;grid-template-columns:1.2fr 1fr 1fr;gap:10px;align-items:end;padding:10px;border-radius:var(--radius-sm);background:var(--surface-2)}
.file-billing{padding:12px 14px;border-radius:var(--radius-sm);background:var(--surface-2)}.file-billing small{display:block;color:var(--muted);margin-top:4px;line-height:1.9}
@media (max-width:1000px){.pkg-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (max-width:640px){.pkg-grid{grid-template-columns:1fr}.pkg.best{transform:none;order:-1}.pkg-edit{grid-template-columns:1fr 1fr}.pkg-edit .check-row{grid-column:1/-1}}
/* Days after the subscription ended: a lock, no plan */
.ws-day.s-lock{opacity:.55}.ws-day.s-lock i{background:transparent!important;border:1.5px dashed var(--muted)}
.calendar-cell.locked{opacity:.5;background:var(--surface-2)}.calendar-cell .cal-lock{color:var(--muted);display:grid;place-items:center}
.locked-day .empty .day-tools{justify-content:center;margin-top:12px}
/* ── «کارنامهٔ تلاش» (2026-10-25): headline, changes, notes, where the time went ── */
.report-hero{display:grid;grid-template-columns:auto 1fr;gap:22px;align-items:center;padding:22px 24px;margin-bottom:16px;border-radius:var(--radius);background:linear-gradient(135deg,var(--brand) 0%,var(--brand-hi) 100%);color:var(--on-brand)}
.rh-ring{--p:0;position:relative;display:grid;place-items:center;align-content:center;width:132px;aspect-ratio:1;border-radius:50%;background:conic-gradient(var(--gold-bright) calc(var(--p)*1%),#ffffff26 0)}
.rh-ring::before{content:"";position:absolute;inset:12px;border-radius:50%;background:var(--brand)}
.rh-ring>*{position:relative}.rh-ring strong{font-size:30px;font-weight:800;line-height:1.1}.rh-ring small{font-size:12px;opacity:.85}
.rh-text h2{margin:4px 0 6px;font-size:26px;color:inherit}.rh-text p{margin:0;opacity:.92;line-height:1.9}.rh-text .eyebrow{color:var(--gold-bright)}
.rh-compare{display:flex;gap:6px;align-items:center;margin-top:8px!important;font-size:14px}
.delta-chip{display:inline-flex;align-items:center;gap:2px;margin-inline-start:6px;padding:1px 8px;border-radius:999px;font-size:12px;font-weight:700;vertical-align:middle;background:var(--surface-2);color:var(--muted)}
.delta-chip.good{background:color-mix(in srgb,var(--success) 15%,transparent);color:var(--success)}.delta-chip.bad{background:color-mix(in srgb,var(--danger) 13%,transparent);color:var(--danger)}
.report-notes .note-line{display:flex;gap:12px;align-items:flex-start;padding:10px 0;border-bottom:1px solid var(--line)}.report-notes .note-line:last-child{border-bottom:0}
.report-notes .note-line svg{flex:none;margin-top:4px;color:var(--gold)}.report-notes .note-line p{margin:0;line-height:2}
.subj-row{display:grid;grid-template-columns:minmax(90px,34%) 1fr auto;grid-template-areas:"name bar time" "name bar pct";column-gap:12px;align-items:center;padding:8px 0;border-bottom:1px solid var(--line)}
.subj-row:last-child{border-bottom:0}.subj-name{grid-area:name;display:flex;align-items:center;gap:8px;font-size:14px;font-weight:600}
.subj-dot{width:10px;height:10px;border-radius:50%;background:var(--color,var(--brand-2));flex:none}
.subj-bar{grid-area:bar;height:10px;border-radius:99px;background:var(--surface-2);overflow:hidden}.subj-bar span{display:block;height:100%;border-radius:99px;background:var(--color,var(--brand-2))}
.subj-row strong{grid-area:time;font-size:13.5px;text-align:end}.subj-row small{grid-area:pct;font-size:12px;color:var(--muted);text-align:end}
.kind-bar{display:flex;height:18px;border-radius:99px;overflow:hidden;background:var(--surface-2);margin:6px 0 14px}.kind-bar span{display:block;height:100%}
.kind-legend{display:grid;gap:8px}.kind-legend div{display:grid;grid-template-columns:12px 1fr 3.2em 8.5em;gap:10px;align-items:center;font-size:14px}.kind-legend strong{text-align:end}.kind-legend i{width:12px;height:12px;border-radius:4px}.kind-legend small{color:var(--muted);font-size:12px;min-width:70px;text-align:end}
.k-teach{background:#2563eb}.k-test{background:#10b981}.k-review{background:#f59e0b}.k-assess{background:#8b5cf6}.k-improve{background:#ef4444}.k-general{background:#64748b}
.progress.acc-low span{background:var(--danger)}.progress.acc-mid span{background:var(--gold-bright)}.progress.acc-high span{background:var(--success)}
.report-more>summary{display:flex;align-items:baseline;gap:10px;cursor:pointer;list-style:none}.report-more>summary::-webkit-details-marker{display:none}
.report-more>summary h2{margin:0;font-size:17px}.report-more>summary small{color:var(--muted)}.report-more>summary::after{content:"▾";margin-inline-start:auto;color:var(--muted)}.report-more[open]>summary::after{content:"▴"}
.report-more[open]>summary{margin-bottom:14px}
@media (max-width:640px){.report-hero{grid-template-columns:1fr;justify-items:center;text-align:center}.rh-compare{justify-content:center}.subj-row{grid-template-columns:1fr auto;grid-template-areas:"name time" "bar pct"}}
@media print{.report-more{display:block}.report-more>summary::after{display:none}.report-hero{-webkit-print-color-adjust:exact;print-color-adjust:exact}}
