/* Layout: app shell — sidebar on wide screens, bottom tab bar on phones; cards on a cool mountain-grey ground */
:root {
  --bg: #eff3f5;
  --surface: #ffffff;
  --surface-2: #f6f8f9;
  --ink: #0d1d26;
  --muted: #5a6a75;
  --line: #e0e7eb;
  --accent: #0c4a5e;
  --accent-2: #13667f;
  --accent-ink: #ffffff;
  --accent-soft: #e2eef2;
  --gold: #b08a35;
  --gold-soft: #f5eedc;
  --ok: #15803d;   --ok-soft: #e3f3e8;
  --warn: #c26a06; --warn-soft: #fdf0dc;
  --bad: #c0392b;  --bad-soft: #fbe6e3;
  --font-display: "Unbounded", "Manrope", system-ui, sans-serif;
  --font-body: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --r: 18px;
  --r-sm: 12px;
  --shadow: 0 1px 2px rgba(13, 29, 38, .04), 0 8px 28px rgba(13, 29, 38, .06);
  --shadow-lg: 0 24px 64px rgba(13, 29, 38, .22);
  --sat: env(safe-area-inset-top, 0px);
  --sab: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b1418; --surface: #121e24; --surface-2: #17252c; --ink: #e8eff2; --muted: #93a4ad; --line: #22343c;
    --accent: #4fb3cf; --accent-2: #6cc4dc; --accent-ink: #062029; --accent-soft: #15323c;
    --gold: #d6b25e; --gold-soft: #2c2616;
    --ok: #4cc27a; --ok-soft: #13301f; --warn: #f0a53c; --warn-soft: #33250f; --bad: #f07466; --bad-soft: #3a1b18;
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 28px rgba(0,0,0,.25);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0b1418; --surface: #121e24; --surface-2: #17252c; --ink: #e8eff2; --muted: #93a4ad; --line: #22343c;
  --accent: #4fb3cf; --accent-2: #6cc4dc; --accent-ink: #062029; --accent-soft: #15323c;
  --gold: #d6b25e; --gold-soft: #2c2616;
  --ok: #4cc27a; --ok-soft: #13301f; --warn: #f0a53c; --warn-soft: #33250f; --bad: #f07466; --bad-soft: #3a1b18;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 28px rgba(0,0,0,.25);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--ink); font-family: var(--font-body); font-size: 15px; line-height: 1.45; -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 2px; border-radius: 8px; }
h1, h2, h3 { text-wrap: balance; margin: 0; }
.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.ic { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ic.sm { width: 16px; height: 16px; }
.ic.lg { width: 26px; height: 26px; }

/* ---------- logo ---------- */
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; }
.logo-mark { width: 38px; height: 38px; border-radius: 11px; background: var(--accent); color: #fff; display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; font-size: 14px; letter-spacing: .02em; position: relative; flex: none; }
.logo-mark::after { content: ""; position: absolute; right: 6px; bottom: 6px; width: 6px; height: 6px; border-radius: 50%; background: var(--gold); }
.logo-txt b { display: block; font-family: var(--font-display); font-weight: 600; font-size: 15px; letter-spacing: -.01em; }
.logo-txt span { display: block; font-size: 11px; color: var(--muted); font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }

/* ---------- shell ---------- */
.shell { display: grid; grid-template-columns: 260px 1fr; min-height: 100%; }
.side { position: sticky; top: 0; height: 100vh; height: 100dvh; display: flex; flex-direction: column; gap: 24px; padding: 22px 16px; background: var(--surface); border-right: 1px solid var(--line); }
.side-nav { display: flex; flex-direction: column; gap: 4px; }
.nav-i { position: relative; display: flex; align-items: center; gap: 12px; padding: 11px 12px; border: 0; background: none; border-radius: 12px; color: var(--muted); font-weight: 600; text-align: left; }
.nav-i:hover { background: var(--surface-2); color: var(--ink); }
.nav-i.on { background: var(--accent-soft); color: var(--accent); }
.nav-i .dot { margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--warn); color: #fff; font-size: 11px; font-weight: 800; display: grid; place-items: center; }
.nav-i .dot.bad { background: var(--bad); }
.side-foot { margin-top: auto; display: flex; flex-direction: column; gap: 10px; }
.who { display: flex; gap: 10px; align-items: center; padding: 12px; border-radius: 14px; background: var(--surface-2); }
.who b { display: block; font-size: 14px; }
.who span { display: block; font-size: 12px; color: var(--muted); }
.demo-tag { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--gold); background: var(--gold-soft); padding: 4px 8px; border-radius: 6px; }
.link-btn { display: inline-flex; align-items: center; gap: 8px; border: 0; background: none; color: var(--muted); font-weight: 600; padding: 8px 10px; border-radius: 10px; }
.link-btn:hover { color: var(--ink); background: var(--surface-2); }

.main { min-width: 0; display: flex; flex-direction: column; }
.top { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: calc(14px + var(--sat)) 28px 14px; background: color-mix(in srgb, var(--bg) 86%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.top-l { display: flex; align-items: center; gap: 14px; min-width: 0; }
.top-l .logo { display: none; }
.pg-title { font-family: var(--font-display); font-weight: 600; font-size: 22px; letter-spacing: -.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-r { display: flex; align-items: center; gap: 8px; }
.content { padding: 8px 28px 48px; display: flex; flex-direction: column; gap: 20px; max-width: 1240px; width: 100%; }
.tabbar { display: none; }

.lang { display: inline-flex; padding: 3px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); }
.lang button { border: 0; background: none; padding: 5px 9px; border-radius: 7px; font-size: 12px; font-weight: 800; color: var(--muted); letter-spacing: .03em; }
.lang button.on { background: var(--accent); color: var(--accent-ink); }
.icon-btn { position: relative; width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); display: grid; place-items: center; color: var(--ink); }
.icon-btn .badge { position: absolute; top: -4px; right: -4px; min-width: 18px; height: 18px; border-radius: 9px; background: var(--bad); color: #fff; font-size: 10px; font-weight: 800; display: grid; place-items: center; padding: 0 4px; border: 2px solid var(--bg); }
.ava { width: 40px; height: 40px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 800; font-size: 14px; border: 0; flex: none; }
.ava.lg { width: 72px; height: 72px; font-size: 24px; }
.ava.gold { background: var(--gold-soft); color: var(--gold); }

/* ---------- generic blocks ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; box-shadow: var(--shadow); min-width: 0; }
.card.flat { box-shadow: none; }
.card-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.card-h h2, .h2 { font-size: 17px; font-weight: 800; letter-spacing: -.01em; }
.card-h .link { font-size: 13px; font-weight: 700; color: var(--accent); background: none; border: 0; padding: 0; }
.grid { display: grid; gap: 20px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.span2 { grid-column: span 2; }
.row { display: flex; align-items: center; gap: 12px; }
.row.wrap { flex-wrap: wrap; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.stack.tight { gap: 8px; }
.sp { flex: 1; }
.eyebrow { font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 18px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); font-weight: 700; font-size: 14px; white-space: nowrap; transition: transform .08s ease, background .15s; }
.btn:hover { background: var(--surface-2); }
.btn:active { transform: scale(.98); }
.btn.pri { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.pri:hover { background: var(--accent-2); }
.btn.gold { background: var(--gold); border-color: var(--gold); color: #fff; }
.btn.danger { color: var(--bad); }
.btn.ghost { border-color: transparent; background: transparent; }
.btn.sm { padding: 7px 12px; font-size: 13px; border-radius: 10px; }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

.chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); white-space: nowrap; }
.chip.ok { background: var(--ok-soft); color: var(--ok); border-color: transparent; }
.chip.warn { background: var(--warn-soft); color: var(--warn); border-color: transparent; }
.chip.bad { background: var(--bad-soft); color: var(--bad); border-color: transparent; }
.chip.acc { background: var(--accent-soft); color: var(--accent); border-color: transparent; }
.chip.gold { background: var(--gold-soft); color: var(--gold); border-color: transparent; }
.chip .sw { width: 8px; height: 8px; border-radius: 50%; }
.seg { display: inline-flex; padding: 3px; gap: 2px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); flex-wrap: wrap; }
.seg button { border: 0; background: none; padding: 7px 12px; border-radius: 9px; font-weight: 700; font-size: 13px; color: var(--muted); }
.seg button.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.tabs { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 2px; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tab { display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); font-weight: 700; font-size: 14px; white-space: nowrap; color: var(--muted); }
.tab.on { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }
.tab .sw { width: 9px; height: 9px; border-radius: 3px; }

.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 12px; font-weight: 800; color: var(--muted); letter-spacing: .02em; }
.input, select.input, textarea.input { width: 100%; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); outline: none; }
.input:focus { border-color: var(--accent-2); background: var(--surface); }
textarea.input { resize: vertical; min-height: 84px; }

/* ---------- alerts / attention triangle ---------- */
.alert { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 16px; border: 1px solid transparent; }
.alert.warn { background: var(--warn-soft); color: var(--warn); }
.alert.bad { background: var(--bad-soft); color: var(--bad); }
.alert .txt { flex: 1; color: var(--ink); font-size: 14px; }
.alert .txt b { display: block; }
.tri { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; flex: none; }
.tri.warn { background: var(--warn); color: #fff; }
.tri.bad { background: var(--bad); color: #fff; animation: pulse 1.8s ease-in-out infinite; }
.tri.sm { width: 22px; height: 22px; border-radius: 7px; }
.tri.sm .ic { width: 14px; height: 14px; }
@keyframes pulse { 0%,100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--bad) 45%, transparent); } 50% { box-shadow: 0 0 0 7px transparent; } }

/* ---------- ring ---------- */
.ringw { position: relative; display: inline-grid; place-items: center; flex: none; }
.ringw .rc { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; line-height: 1; }
.ringw .rc b { font-size: 20px; font-weight: 800; font-variant-numeric: tabular-nums; }
.ringw .rc small { display: block; font-size: 10px; color: var(--muted); font-weight: 700; margin-top: 2px; }
.ring-bg { stroke: var(--surface-2); fill: none; }
.ring-fg { fill: none; stroke-linecap: round; transition: stroke-dasharray .6s ease; }
.ring.ok .ring-fg { stroke: var(--accent-2); }
.ring.warn .ring-fg { stroke: var(--warn); }
.ring.bad .ring-fg { stroke: var(--bad); }

/* ---------- home ---------- */
.hello { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.hello h2 { font-family: var(--font-display); font-weight: 600; font-size: 26px; letter-spacing: -.02em; }
.hello p { margin: 4px 0 0; color: var(--muted); }
.next { position: relative; overflow: hidden; background: linear-gradient(135deg, #0c4a5e 0%, #0a3546 100%); color: #fff; border: 0; }
.next .eyebrow { color: rgba(255,255,255,.7); }
.next h3 { font-family: var(--font-display); font-weight: 600; font-size: 24px; margin: 8px 0 4px; letter-spacing: -.02em; }
.next .meta { color: rgba(255,255,255,.82); font-size: 14px; display: flex; flex-wrap: wrap; gap: 6px 16px; }
.next .meta span { display: inline-flex; align-items: center; gap: 6px; }
.next .count { margin-top: 16px; display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 10px; background: rgba(255,255,255,.12); font-weight: 700; font-size: 14px; }
.next .acts { margin-top: 18px; display: flex; gap: 8px; flex-wrap: wrap; }
.next .btn { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.18); color: #fff; }
.next .btn.pri { background: #fff; color: #0c4a5e; border-color: #fff; }
.next .mount { position: absolute; right: -10px; bottom: -6px; width: 260px; opacity: .16; pointer-events: none; }
.sub { display: flex; align-items: center; gap: 14px; }
.sub .info { flex: 1; min-width: 0; }
.sub .info b { display: block; font-size: 15px; }
.sub .info span { display: block; font-size: 13px; color: var(--muted); }
.stat { display: flex; flex-direction: column; gap: 4px; }
.stat b { font-size: 26px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.stat span { font-size: 13px; color: var(--muted); font-weight: 600; }
.stat .ic { color: var(--gold); }
.badges { display: flex; gap: 12px; flex-wrap: wrap; }
.bdg { display: flex; flex-direction: column; align-items: center; gap: 6px; width: 92px; text-align: center; font-size: 12px; font-weight: 700; color: var(--muted); }
.bdg i { width: 56px; height: 56px; border-radius: 18px; display: grid; place-items: center; background: var(--gold-soft); color: var(--gold); font-style: normal; }
.bdg.off i { background: var(--surface-2); color: var(--line); }
.bdg.off { opacity: .7; }

/* ---------- lesson rows ---------- */
.lesson { display: flex; gap: 14px; align-items: stretch; padding: 14px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); }
.lesson .tm { min-width: 58px; font-weight: 800; font-variant-numeric: tabular-nums; }
.lesson .tm small { display: block; color: var(--muted); font-weight: 600; }
.lesson .bar { width: 4px; border-radius: 4px; flex: none; }
.lesson .bd { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.lesson .bd b { font-size: 15px; }
.lesson .bd .m { font-size: 13px; color: var(--muted); }
.lesson .ac { display: flex; flex-direction: column; align-items: flex-end; justify-content: center; gap: 6px; }
.lesson.dim { opacity: .62; }
.lesson.extra { border-style: dashed; }
.seats { display: inline-flex; align-items: center; gap: 3px; font-size: 12px; color: var(--muted); font-weight: 700; }
.seats i { width: 8px; height: 8px; border-radius: 50%; background: var(--line); }
.seats i.f { background: var(--accent-2); }
.seats.full i.f { background: var(--warn); }
.daystrip { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.dayb { border: 1px solid var(--line); background: var(--surface); border-radius: 14px; padding: 8px 4px; display: flex; flex-direction: column; align-items: center; gap: 2px; color: var(--muted); font-weight: 700; font-size: 12px; }
.dayb b { font-size: 18px; color: var(--ink); font-variant-numeric: tabular-nums; }
.dayb .dots { display: flex; gap: 3px; height: 6px; }
.dayb .dots i { width: 5px; height: 5px; border-radius: 50%; background: var(--accent-2); }
.dayb.today { border-color: var(--gold); }
.dayb.on { background: var(--accent); border-color: var(--accent); color: rgba(255,255,255,.75); }
.dayb.on b { color: #fff; }
.dayb.on .dots i { background: #fff; }
.weeknav { display: flex; align-items: center; gap: 8px; }
.weeknav b { font-size: 14px; min-width: 150px; text-align: center; }

/* ---------- charts ---------- */
.chart { width: 100%; height: auto; display: block; overflow: visible; }
.chart text { fill: var(--muted); font-size: 10px; font-family: var(--font-body); font-weight: 600; }
.chart .grid-l { stroke: var(--line); stroke-width: 1; }
.chart .ln { fill: none; stroke: var(--accent-2); stroke-width: 2.4; stroke-linejoin: round; stroke-linecap: round; }
.chart .area { fill: var(--accent-2); opacity: .12; }
.chart .pt { fill: var(--surface); stroke: var(--accent-2); stroke-width: 2; }
.chart .pt.end { fill: var(--accent-2); }
.chart .br { fill: var(--accent-2); }
.chart .br.cur { fill: var(--gold); }
.chart .endlbl { fill: var(--ink); font-weight: 800; font-size: 11px; }
.legend { display: flex; flex-direction: column; gap: 8px; font-size: 13px; }
.legend div { display: flex; align-items: center; gap: 8px; }
.legend i { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.legend b { margin-left: auto; font-variant-numeric: tabular-nums; }
.pbar { height: 8px; border-radius: 4px; background: var(--surface-2); overflow: hidden; }
.pbar i { display: block; height: 100%; border-radius: 4px; background: var(--accent-2); }
.pbar.gold i { background: var(--gold); }
.attdots { display: flex; gap: 6px; flex-wrap: wrap; }
.attdots i { width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center; background: var(--ok-soft); color: var(--ok); font-style: normal; font-size: 11px; font-weight: 800; }
.attdots i.late { background: var(--warn-soft); color: var(--warn); }
.attdots i.miss { background: var(--bad-soft); color: var(--bad); }

/* ---------- lists / tables ---------- */
.list { display: flex; flex-direction: column; }
.li { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); min-width: 0; }
.li:first-child { border-top: 0; padding-top: 0; }
.li:last-child { padding-bottom: 0; }
.li .bd { flex: 1; min-width: 0; }
.li .bd b { display: block; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.li .bd span { display: block; font-size: 13px; color: var(--muted); }
.li.click { cursor: pointer; border-radius: 10px; }
.li.click:hover { background: var(--surface-2); }
.tbl-wrap { overflow-x: auto; }
table.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th { text-align: left; font-size: 12px; color: var(--muted); font-weight: 800; padding: 0 10px 10px; letter-spacing: .02em; white-space: nowrap; }
.tbl td { padding: 12px 10px; border-top: 1px solid var(--line); vertical-align: middle; }
.tbl tr.click { cursor: pointer; }
.tbl tr.click:hover td { background: var(--surface-2); }
.tbl .r { text-align: right; font-variant-numeric: tabular-nums; }
.hw { display: flex; gap: 12px; align-items: flex-start; padding: 14px; border-radius: 14px; background: var(--surface-2); }
.hw .bd { flex: 1; min-width: 0; font-size: 14px; }
.hw .bd .m { font-size: 12px; color: var(--muted); margin-top: 4px; }
.cmt { display: flex; gap: 12px; }
.cmt .bubble { flex: 1; background: var(--surface-2); border-radius: 4px 16px 16px 16px; padding: 12px 14px; font-size: 14px; }
.cmt .bubble .m { font-size: 12px; color: var(--muted); margin-bottom: 4px; font-weight: 700; }

/* ---------- KPI ---------- */
.kpi { display: flex; flex-direction: column; gap: 6px; }
.kpi .lbl { font-size: 13px; color: var(--muted); font-weight: 700; display: flex; align-items: center; gap: 6px; }
.kpi b { font-size: 28px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.kpi .d { font-size: 12px; font-weight: 700; }
.kpi .d.up { color: var(--ok); }
.kpi.attn { border-color: color-mix(in srgb, var(--warn) 45%, var(--line)); }

/* ---------- admin week grid ---------- */
.wgrid { display: grid; grid-template-columns: repeat(7, minmax(168px, 1fr)); gap: 10px; overflow-x: auto; padding-bottom: 6px; }
.wcol { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.wcol-h { padding: 8px 10px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); font-weight: 800; font-size: 13px; display: flex; justify-content: space-between; }
.wcol-h.today { border-color: var(--gold); color: var(--gold); }
.wl { text-align: left; border: 1px solid var(--line); border-left: 4px solid; background: var(--surface); border-radius: 12px; padding: 9px 10px; display: flex; flex-direction: column; gap: 3px; font-size: 12px; }
.wl:hover { background: var(--surface-2); }
.wl b { font-size: 13px; }
.wl .m { color: var(--muted); }
.wl.past { opacity: .6; }

/* ---------- kanban ---------- */
.kanban { display: grid; grid-template-columns: repeat(3, minmax(240px, 1fr)); gap: 16px; overflow-x: auto; }
.kcol { display: flex; flex-direction: column; gap: 10px; }
.kcol-h { display: flex; align-items: center; justify-content: space-between; font-weight: 800; font-size: 14px; padding: 0 4px; }
.lead { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px; display: flex; flex-direction: column; gap: 8px; box-shadow: var(--shadow); }
.lead.fresh { border-color: var(--gold); }
.lead b { font-size: 15px; }
.lead .m { font-size: 13px; color: var(--muted); }

/* ---------- sheet / modal ---------- */
.scrim { position: fixed; inset: 0; z-index: 60; background: rgba(6, 18, 24, .45); display: flex; align-items: center; justify-content: center; padding: 20px; animation: fade .18s ease; }
.sheet { width: 100%; max-width: 520px; max-height: 88vh; max-height: 88dvh; overflow: auto; background: var(--surface); border-radius: 24px; box-shadow: var(--shadow-lg); padding: 24px; animation: rise .22s ease; }
.sheet.wide { max-width: 680px; }
.sheet-h { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.sheet-h h2 { font-family: var(--font-display); font-weight: 600; font-size: 20px; letter-spacing: -.02em; }
.sheet-h p { margin: 4px 0 0; color: var(--muted); font-size: 14px; }
.x { border: 0; background: var(--surface-2); width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; flex: none; }
.sheet-f { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; flex-wrap: wrap; }
@keyframes fade { from { opacity: 0; } }
@keyframes rise { from { transform: translateY(18px); opacity: 0; } }
.pkg { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 16px; border: 1.5px solid var(--line); background: var(--surface); text-align: left; width: 100%; }
.pkg.on { border-color: var(--accent); background: var(--accent-soft); }
.pkg .rad { width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--line); flex: none; display: grid; place-items: center; }
.pkg.on .rad { border-color: var(--accent); }
.pkg.on .rad::after { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); }
.pkg .bd { flex: 1; }
.pkg .bd b { display: block; }
.pkg .bd span { font-size: 13px; color: var(--muted); }
.pkg .pr { font-weight: 800; font-variant-numeric: tabular-nums; text-align: right; }
.pkg .pr small { display: block; font-weight: 700; color: var(--ok); font-size: 12px; }
.qr { display: grid; place-items: center; padding: 18px; background: #fff; border-radius: 18px; border: 1px solid var(--line); width: fit-content; margin: 0 auto; }
.paybox { text-align: center; display: flex; flex-direction: column; gap: 14px; align-items: center; }
.paybox .amt { font-size: 32px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.kaspi { background: #e3262a; border-color: #e3262a; color: #fff; }
.kaspi:hover { background: #c81f23; }
.success { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; padding: 10px 0; }
.success .ok-ic { width: 76px; height: 76px; border-radius: 50%; background: var(--ok-soft); color: var(--ok); display: grid; place-items: center; animation: pop .35s cubic-bezier(.3,1.6,.6,1); }
.success .ok-ic .ic { width: 38px; height: 38px; stroke-width: 2.4; }
@keyframes pop { from { transform: scale(.4); opacity: 0; } }
.rcpt { font-size: 14px; display: flex; flex-direction: column; gap: 8px; }
.rcpt .r { display: flex; justify-content: space-between; gap: 12px; }
.rcpt .r span:first-child { color: var(--muted); }
.rcpt hr { border: 0; border-top: 1px dashed var(--line); margin: 6px 0; width: 100%; }
.att-seg button { min-width: 40px; }
.grade-ch { display: inline-flex; gap: 4px; }
.grade-ch button { width: 32px; height: 32px; border-radius: 9px; border: 1px solid var(--line); background: var(--surface); font-weight: 800; font-size: 13px; }
.grade-ch button.on { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.jrow { display: flex; flex-direction: column; gap: 10px; padding: 14px 0; border-top: 1px solid var(--line); }
.jrow:first-child { border-top: 0; }
.toggle { position: relative; width: 46px; height: 28px; border-radius: 14px; border: 0; background: var(--line); flex: none; transition: background .2s; }
.toggle::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .2s; }
.toggle.on { background: var(--accent-2); }
.toggle.on::after { transform: translateX(18px); }

.toast { position: fixed; left: 50%; bottom: calc(24px + var(--sab)); transform: translateX(-50%); z-index: 90; background: var(--ink); color: var(--bg); padding: 12px 18px; border-radius: 14px; font-weight: 700; font-size: 14px; box-shadow: var(--shadow-lg); display: flex; align-items: center; gap: 10px; max-width: calc(100% - 32px); animation: rise .2s ease; }

/* ---------- login ---------- */
.login { min-height: 100%; display: grid; grid-template-columns: 1.05fr 1fr; }
.login-art { position: relative; overflow: hidden; background: linear-gradient(160deg, #0c4a5e 0%, #072a36 100%); color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; gap: 32px; }
.login-art .logo-mark { background: #fff; color: #0c4a5e; }
.login-art .logo-txt span { color: rgba(255,255,255,.65); }
.login-art h1 { font-family: var(--font-display); font-weight: 600; font-size: clamp(28px, 3.4vw, 44px); line-height: 1.12; letter-spacing: -.03em; max-width: 14ch; }
.login-art p { color: rgba(255,255,255,.78); max-width: 42ch; font-size: 16px; }
.login-art .mount { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; opacity: .22; pointer-events: none; }
.login-art .facts { display: flex; gap: 28px; flex-wrap: wrap; position: relative; }
.login-art .facts b { display: block; font-family: var(--font-display); font-size: 22px; font-weight: 600; color: var(--gold); }
.login-art .facts span { font-size: 13px; color: rgba(255,255,255,.7); }
.login-form { padding: 40px; display: flex; flex-direction: column; justify-content: center; gap: 22px; max-width: 520px; width: 100%; margin: 0 auto; }
.login-form h2 { font-family: var(--font-display); font-weight: 600; font-size: 26px; letter-spacing: -.02em; }
.roles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.role { display: flex; align-items: center; gap: 12px; padding: 14px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface); text-align: left; }
.role:hover { border-color: var(--accent-2); background: var(--accent-soft); }
.role .ic-w { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); flex: none; }
.role b { display: block; font-size: 14px; }
.role span { display: block; font-size: 12px; color: var(--muted); }
.role.wide { grid-column: span 2; background: var(--gold-soft); border-color: transparent; }
.role.wide .ic-w { background: var(--gold); color: #fff; }
.divider { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 12px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* ---------- landing ---------- */
.land { min-height: 100%; }
.land-nav { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: calc(14px + var(--sat)) max(20px, calc((100% - 1160px) / 2)) 14px; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.land-sec { padding: 56px max(20px, calc((100% - 1160px) / 2)); }
.hero { display: grid; grid-template-columns: 1.15fr 1fr; gap: 40px; align-items: center; padding-top: 32px; }
.hero h1 { font-family: var(--font-display); font-weight: 600; font-size: clamp(30px, 4.4vw, 54px); line-height: 1.08; letter-spacing: -.035em; }
.hero h1 em { font-style: normal; color: var(--gold); }
.hero p { font-size: 18px; color: var(--muted); max-width: 46ch; margin: 18px 0 26px; }
.hero .cta { display: flex; gap: 10px; flex-wrap: wrap; }
.hero .btn { padding: 14px 22px; font-size: 15px; border-radius: 14px; }
.hero-card { position: relative; border-radius: 28px; overflow: hidden; background: linear-gradient(160deg, #0c4a5e, #072a36); color: #fff; padding: 28px; min-height: 360px; display: flex; flex-direction: column; justify-content: flex-end; gap: 12px; box-shadow: var(--shadow-lg); }
.hero-card .mount { position: absolute; inset: auto 0 0 0; width: 100%; opacity: .25; }
.hero-card .float { position: relative; background: rgba(255,255,255,.1); backdrop-filter: blur(10px); border: 1px solid rgba(255,255,255,.16); border-radius: 18px; padding: 14px 16px; display: flex; align-items: center; gap: 12px; }
.hero-card .float b { display: block; }
.hero-card .float span { font-size: 13px; color: rgba(255,255,255,.75); }
.facts-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-top: 40px; }
.facts-row div { padding: 18px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); }
.facts-row b { display: block; font-family: var(--font-display); font-weight: 600; font-size: 24px; color: var(--accent); }
.facts-row span { font-size: 13px; color: var(--muted); font-weight: 600; }
.sec-h { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.sec-h h2 { font-family: var(--font-display); font-weight: 600; font-size: clamp(24px, 3vw, 34px); letter-spacing: -.03em; }
.sec-h p { color: var(--muted); max-width: 52ch; margin: 8px 0 0; }
.course { display: flex; flex-direction: column; gap: 12px; }
.course .top-c { display: flex; align-items: center; justify-content: space-between; }
.course .sq { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; color: #fff; font-family: var(--font-display); font-weight: 600; font-size: 14px; }
.course h3 { font-size: 19px; font-weight: 800; }
.course p { margin: 0; color: var(--muted); font-size: 14px; }
.course .price { margin-top: auto; font-weight: 800; font-size: 15px; }
.course .price small { color: var(--muted); font-weight: 600; }
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.step { padding: 22px; border-radius: 20px; background: var(--surface); border: 1px solid var(--line); }
.step .n { font-family: var(--font-display); font-weight: 600; color: var(--gold); font-size: 14px; }
.step h3 { font-size: 17px; margin: 10px 0 6px; }
.step p { margin: 0; color: var(--muted); font-size: 14px; }
.tch { display: flex; gap: 14px; align-items: center; }
.tch b { display: block; }
.tch span { display: block; font-size: 13px; color: var(--muted); }
.price-t { width: 100%; border-collapse: collapse; }
.price-t th, .price-t td { padding: 14px 12px; border-top: 1px solid var(--line); text-align: left; }
.price-t th { border-top: 0; font-size: 12px; color: var(--muted); font-weight: 800; }
.price-t .r { text-align: right; font-variant-numeric: tabular-nums; font-weight: 800; }
.addr { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: stretch; }
.mapcard { border-radius: 22px; background: linear-gradient(135deg, var(--accent-soft), var(--surface-2)); border: 1px solid var(--line); min-height: 220px; position: relative; overflow: hidden; display: grid; place-items: center; }
.mapcard .pin { width: 56px; height: 56px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; box-shadow: 0 0 0 12px color-mix(in srgb, var(--accent) 18%, transparent); }
.mapcard svg.streets { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .5; }
.foot { padding: 28px max(20px, calc((100% - 1160px) / 2)) calc(28px + var(--sab)); border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.fab { position: fixed; right: 22px; bottom: calc(22px + var(--sab)); z-index: 40; display: inline-flex; align-items: center; gap: 10px; padding: 14px 20px 14px 16px; border-radius: 999px; border: 0; background: var(--gold); color: #fff; font-weight: 800; box-shadow: 0 12px 32px rgba(176, 138, 53, .45); }
.fab .ic { width: 22px; height: 22px; }

/* ---------- chat ---------- */
.chat { position: fixed; right: 22px; bottom: 22px; z-index: 70; width: 400px; height: min(640px, calc(100vh - 44px)); height: min(640px, calc(100dvh - 44px)); background: var(--surface); border-radius: 26px; box-shadow: var(--shadow-lg); border: 1px solid var(--line); display: flex; flex-direction: column; overflow: hidden; animation: rise .22s ease; }
.chat-h { display: flex; align-items: center; gap: 12px; padding: 16px 16px 14px; background: var(--accent); color: #fff; }
.chat-h .logo-mark { background: #fff; color: var(--accent); width: 40px; height: 40px; }
.chat-h b { display: block; }
.chat-h span { font-size: 12px; color: rgba(255,255,255,.75); display: flex; align-items: center; gap: 6px; }
.chat-h span::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #5ee08a; }
.chat-h .x { background: rgba(255,255,255,.14); color: #fff; margin-left: auto; }
.chat-b { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; background: var(--surface-2); }
.msg { max-width: 86%; padding: 11px 14px; border-radius: 18px; font-size: 14px; line-height: 1.45; white-space: pre-line; animation: rise .18s ease; }
.msg.bot { background: var(--surface); border: 1px solid var(--line); border-bottom-left-radius: 6px; align-self: flex-start; }
.msg.me { background: var(--accent); color: var(--accent-ink); border-bottom-right-radius: 6px; align-self: flex-end; }
.msg.card-m { max-width: 92%; padding: 0; overflow: hidden; }
.msg.card-m .mc { padding: 14px; display: flex; flex-direction: column; gap: 6px; }
.msg.card-m .mc-h { padding: 10px 14px; color: #fff; font-weight: 800; font-size: 13px; }
.typing { align-self: flex-start; display: flex; gap: 4px; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; border-bottom-left-radius: 6px; }
.typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); animation: blink 1s infinite; }
.typing i:nth-child(2) { animation-delay: .15s; }
.typing i:nth-child(3) { animation-delay: .3s; }
@keyframes blink { 0%, 80%, 100% { opacity: .25; } 40% { opacity: 1; } }
.quick { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 16px 12px; background: var(--surface-2); }
.quick button { border: 1.5px solid var(--accent); color: var(--accent); background: var(--surface); padding: 8px 14px; border-radius: 999px; font-weight: 700; font-size: 13px; }
.quick button:hover { background: var(--accent-soft); }
.chat-i { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--line); background: var(--surface); padding-bottom: calc(12px + var(--sab)); }
.chat-i .input { border-radius: 999px; }
.chat-i .send { width: 46px; height: 46px; border-radius: 50%; border: 0; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; flex: none; }
.chat-i .send[disabled] { opacity: .4; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .facts-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .side { display: none; }
  .top { padding: calc(12px + var(--sat)) 16px 12px; }
  .top-l .logo { display: flex; }
  .top-l .logo .logo-txt { display: none; }
  .pg-title { font-size: 19px; }
  .content { padding: 4px 16px calc(96px + var(--sab)); gap: 16px; }
  .tabbar { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-top: 1px solid var(--line); padding: 6px 4px calc(6px + var(--sab)); }
  .tabbar .nav-i { flex-direction: column; gap: 3px; padding: 6px 2px; font-size: 10.5px; justify-content: center; align-items: center; text-align: center; background: none; }
  .tabbar .nav-i.on { background: none; }
  .tabbar .nav-i .ic { width: 23px; height: 23px; }
  .tabbar .nav-i.on .ic { stroke-width: 2.2; }
  .tabbar .nav-i .dot { position: absolute; top: 2px; left: calc(50% + 6px); margin: 0; min-width: 16px; height: 16px; font-size: 10px; }
  .tabbar .nav-i span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
  .g2, .g3 { grid-template-columns: 1fr; }
  .span2 { grid-column: auto; }
  .card { padding: 16px; border-radius: 16px; }
  .hello h2 { font-size: 22px; }
  .scrim { align-items: flex-end; padding: 0; }
  .sheet { border-radius: 24px 24px 0 0; max-height: 92vh; max-height: 92dvh; padding: 20px 18px calc(20px + var(--sab)); }
  .login { grid-template-columns: 1fr; }
  .login-art { padding: calc(28px + var(--sat)) 22px 28px; min-height: auto; }
  .login-art .facts { gap: 18px; }
  .login-form { padding: 24px 18px calc(32px + var(--sab)); }
  .hero { grid-template-columns: 1fr; gap: 28px; padding-top: 16px; }
  .hero-card { min-height: 260px; }
  .land-sec { padding-top: 36px; padding-bottom: 36px; }
  .steps { grid-template-columns: 1fr; }
  .addr { grid-template-columns: 1fr; }
  .chat { inset: 0; width: 100%; height: 100%; border-radius: 0; border: 0; padding-top: var(--sat); }
  .kanban { grid-template-columns: repeat(3, minmax(260px, 1fr)); }
  .lang button { padding: 5px 7px; }
}
@media (max-width: 520px) {
  .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .kpi b { font-size: 22px; }
  .roles { grid-template-columns: 1fr; }
  .role.wide { grid-column: auto; }
  .lesson { flex-wrap: wrap; }
  .lesson .ac { flex-direction: row; width: 100%; justify-content: flex-start; padding-left: 76px; }
  .stat b { font-size: 22px; }
  .daystrip { gap: 4px; }
  .dayb { padding: 7px 2px; border-radius: 12px; }
  .dayb b { font-size: 16px; }
  .facts-row { gap: 10px; }
  .top-r .icon-btn { width: 38px; height: 38px; }
  .top-r .ava.sm { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
a.btn { text-decoration: none; color: inherit; }
a.btn.kaspi, a.btn.pri, a.btn.gold { color: #fff; }
.chat-b > * { flex-shrink: 0; }

/* ---------- files ---------- */
.files { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 8px; }
.files-l { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); width: 100%; }
.file { display: inline-flex; align-items: stretch; max-width: 100%; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); overflow: hidden; }
.file-o { display: inline-flex; align-items: center; gap: 6px; border: 0; background: none; padding: 7px 10px; min-width: 0; font-size: 13px; font-weight: 700; color: var(--accent); text-align: left; }
.file-o .fn { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 210px; }
.file-o small { color: var(--muted); font-weight: 600; white-space: nowrap; }
.file-o:hover, .file-d:hover { background: var(--accent-soft); }
.file-d { border: 0; border-left: 1px solid var(--line); background: none; padding: 0 9px; color: var(--accent); display: grid; place-items: center; }
.fview { background: var(--surface-2); border-radius: 14px; padding: 10px; display: grid; place-items: center; }
.fview img { max-width: 100%; max-height: 62vh; border-radius: 8px; box-shadow: var(--shadow); }
.ftext { background: var(--surface-2); border-radius: 14px; padding: 16px; margin: 0; max-height: 60vh; overflow: auto; white-space: pre-wrap; font: 14px/1.55 var(--font-body); }
.fcard { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; padding: 30px 16px; background: var(--surface-2); border-radius: 14px; color: var(--accent); }
.fcard b { color: var(--ink); }
.scale { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.grade-ch button.g0.on { background: var(--bad); border-color: var(--bad); color: #fff; }
.grade-ch button.g4.on { background: var(--warn); border-color: var(--warn); color: #fff; }
.grade-ch button.g5.on { background: var(--ok); border-color: var(--ok); color: #fff; }
.grade-ch button.g0 { color: var(--bad); }
.grade-ch button.g5 { color: var(--ok); }
.grade-ch button { width: 40px; height: 36px; }
.bd .files .file { display: inline-flex; color: var(--accent); font-size: 13px; }
.bd .files .fn { display: inline; color: inherit; font-size: 13px; }
.bd .files .files-l { display: flex; width: 100%; font-size: 11px; }
.thumbs { display: flex; flex-wrap: wrap; gap: 8px; }
.th { position: relative; width: 92px; display: flex; flex-direction: column; gap: 4px; }
.th img, .th-doc { width: 92px; height: 92px; border-radius: 12px; object-fit: cover; border: 1px solid var(--line); background: var(--surface-2); }
.th-doc { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; color: var(--accent); }
.th-doc small { font-size: 10px; font-weight: 800; }
.th-n { font-size: 11px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.th-x { position: absolute; top: -6px; right: -6px; width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--surface); background: var(--ink); color: var(--surface); display: grid; place-items: center; padding: 0; }
.th-x .ic { width: 12px; height: 12px; }
label.btn { cursor: pointer; }
@media (hover: hover) and (pointer: fine) { .photo-only { display: none; } }
.thumbs { display: flex; flex-wrap: wrap; gap: 8px; }
.th { position: relative; width: 92px; display: flex; flex-direction: column; gap: 4px; }
.th img, .th-doc { width: 92px; height: 92px; border-radius: 12px; object-fit: cover; border: 1px solid var(--line); background: var(--surface-2); }
.th-doc { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; color: var(--accent); }
.th-doc small { font-size: 10px; font-weight: 800; }
.th-n { font-size: 11px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.th-x { position: absolute; top: -6px; right: -6px; width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--surface); background: var(--ink); color: var(--surface); display: grid; place-items: center; padding: 0; }
.th-x .ic { width: 12px; height: 12px; }
label.btn { cursor: pointer; }
@media (hover: hover) and (pointer: fine) { .photo-only { display: none; } }
.sms { margin-top: 16px; border-radius: 18px; background: var(--surface-2); border: 1px solid var(--line); overflow: hidden; }
.sms-h { display: flex; align-items: center; gap: 8px; padding: 10px 14px; font-size: 12px; color: var(--muted); border-bottom: 1px solid var(--line); }
.sms-h b { color: var(--ink); }
.sms-b { margin: 14px; padding: 12px 14px; background: var(--surface); border-radius: 4px 16px 16px 16px; font-size: 14px; line-height: 1.5; box-shadow: var(--shadow); }
.sms-f { display: flex; align-items: center; gap: 6px; justify-content: flex-end; padding: 0 14px 12px; font-size: 12px; font-weight: 700; color: var(--ok); }
.otp { font-size: 30px; font-weight: 800; letter-spacing: .6em; text-align: center; padding: 14px; font-variant-numeric: tabular-nums; }
.onb-prog { display: flex; flex-direction: column; gap: 8px; }
.onb-prog .pbar i { background: var(--gold); transition: width .3s ease; }
.mcard { border-radius: 16px; overflow: hidden; border: 1px solid var(--line); background: var(--surface); box-shadow: var(--shadow); }
.mcard .mc-h { padding: 10px 14px; color: #fff; font-weight: 800; font-size: 13px; display: flex; justify-content: space-between; gap: 8px; }
.mcard .mc { padding: 14px; display: flex; flex-direction: column; gap: 6px; }
.welcome { border-color: color-mix(in srgb, var(--gold) 50%, var(--line)); background: linear-gradient(180deg, var(--gold-soft), var(--surface) 70%); }
.login-form h2 { font-family: var(--font-display); font-weight: 600; font-size: 24px; letter-spacing: -.02em; }
@media (max-width: 900px) { .login.onb .login-art { display: none; } .login.onb .login-form { padding-top: calc(20px + var(--sat)); } }
.slotgrid { grid-template-columns: repeat(7, minmax(148px, 1fr)); }
.wl.slot { cursor: pointer; position: relative; }
.wl.slot .aud { font-size: 11px; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .03em; }
.wl.slot .st { font-size: 12px; font-weight: 800; display: inline-flex; align-items: center; gap: 4px; }
.wl.slot.ok { background: var(--ok-soft); }
.wl.slot.ok .st { color: var(--ok); }
.wl.slot.low { background: var(--warn-soft); }
.wl.slot.low .st { color: var(--warn); }
.wl.slot.full { background: var(--bad-soft); }
.wl.slot.full .st { color: var(--bad); }
.wl.slot.off { opacity: .45; cursor: not-allowed; filter: grayscale(.4); }
.wl.slot.full.off { opacity: .7; }
.wl.slot.picked { outline: 2.5px solid var(--gold); outline-offset: 1px; }
.wl.slot.picked .st { color: var(--gold); }
.wl.slot:not(.off):hover { transform: translateY(-1px); box-shadow: var(--shadow); }
.slot-empty { color: var(--muted); text-align: center; padding: 10px; font-size: 13px; }
.slot-legend { gap: 12px; font-size: 12px; color: var(--muted); font-weight: 700; }
.slot-legend span { display: inline-flex; align-items: center; gap: 6px; }
.slot-legend i { width: 12px; height: 12px; border-radius: 4px; display: inline-block; }
.slot-legend i.ok { background: var(--ok); } .slot-legend i.low { background: var(--warn); } .slot-legend i.full { background: var(--bad); } .slot-legend i.off { background: var(--line); }
.icon-btn[disabled] { opacity: .35; cursor: not-allowed; }
.sheet.xwide { max-width: 1180px; }
.slotgrid { overflow-x: visible; }
@media (max-width: 1100px) { .slotgrid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 900px) {
  .slotgrid { grid-template-columns: 1fr; gap: 14px; }
  .slotgrid .wcol { gap: 6px; }
  .slotgrid .wcol-h { background: transparent; border: 0; padding: 0 2px; font-size: 14px; }
  .slotgrid .slot-empty { display: none; }
  .slotgrid .wcol:has(.slot-empty) { display: none; }
}
@media (max-width: 900px) { .slotgrid .wcol.pastday { display: none; } }

/* ---------- demand ---------- */
.money-row { display: grid; grid-template-columns: minmax(120px, 220px) 1fr auto; align-items: center; gap: 12px; font-size: 14px; }
.money-row .pbar { height: 12px; border-radius: 6px; }
.rec { border: 1px solid var(--line); border-radius: 16px; overflow: hidden; background: var(--surface); display: flex; flex-direction: column; }
.rec-h { padding: 10px 14px; color: #fff; display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.rec-h b { font-size: 14px; } .rec-h span { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; opacity: .9; white-space: nowrap; }
.rec-b { padding: 14px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.rec-b .btn { margin-top: auto; }
.rec-math { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding: 10px 12px; border-radius: 12px; background: var(--gold-soft); font-size: 13px; }
.rec-math b { font-size: 18px; color: var(--ink); } .rec-math small { font-size: 12px; color: var(--muted); font-weight: 600; }
.hm { display: grid; grid-template-columns: 52px repeat(7, minmax(44px, 1fr)); gap: 3px; min-width: 420px; }
.hm-c { height: 26px; border-radius: 6px; display: grid; place-items: center; font-size: 10px; font-weight: 800; }
.hm-h { background: none; color: var(--muted); font-size: 12px; height: 22px; }
.hm-h.today { color: var(--gold); }
.hm-t { background: none; color: var(--muted); font-weight: 600; justify-content: end; padding-right: 6px; font-variant-numeric: tabular-nums; }
.hm-c.busy { color: #fff; opacity: .9; }
.hm-c.busy span { mix-blend-mode: normal; opacity: .9; }
.hm-c.free { background: color-mix(in srgb, var(--ok) calc(var(--h) * 75% + 5%), var(--surface-2)); }
.hm-c.rec-cell { outline: 2px dashed var(--ink); outline-offset: -2px; color: var(--ink); }
.hm-c.busy { background: color-mix(in srgb, var(--ink) 72%, var(--surface)); box-shadow: inset 4px 0 0 var(--sc); color: #fff; opacity: 1; }
@media (max-width: 520px) { .money-row { grid-template-columns: 1fr auto; } .money-row .pbar { grid-column: 1 / -1; grid-row: 2; } }
.login-art .facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 24px; }
.login-art .facts b { font-size: 20px; }
.tag-new { font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; color: var(--gold); background: var(--gold-soft); padding: 2px 6px; border-radius: 6px; }
.off-tab { opacity: .55; cursor: default; }
.tag-age { font-size: 11px; font-weight: 700; color: var(--muted); }
.login-form > * { flex-shrink: 0; }
.login-form .stack > * { flex-shrink: 0; }
.toast { pointer-events: none; }
.login-form .tab, .off-tab { white-space: normal; max-width: 100%; text-align: left; line-height: 1.3; }
.login-form { min-width: 0; overflow-wrap: anywhere; }
.rc-dots { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.rc-dots i { width: 22px; height: 22px; border-radius: 50%; background: var(--surface-2); border: 2px dashed var(--line); }
.rc-dots i.f { background: var(--accent-2); border: 0; }
.rc-dots i.me { background: var(--gold); border: 0; box-shadow: 0 0 0 3px var(--gold-soft); }
.rc-dots span { margin-left: 6px; font-size: 13px; font-weight: 800; color: var(--muted); }
.rc-dots i.th { position: relative; }
.rc-dots i.th::after { content: ""; position: absolute; right: -4px; top: -4px; bottom: -4px; border-right: 2px solid var(--ok); }
a.mapcard { text-decoration: none; color: inherit; cursor: pointer; transition: transform .12s ease, box-shadow .12s ease; }
a.mapcard:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.map-pin { position: relative; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.map-lbl { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 8px 14px; text-align: center; box-shadow: var(--shadow); }
.map-lbl b { display: block; font-size: 14px; } .map-lbl span { font-size: 12px; color: var(--muted); }
.map-open { position: absolute; right: 14px; bottom: 14px; display: inline-flex; align-items: center; gap: 6px; background: var(--accent); color: var(--accent-ink); font-weight: 700; font-size: 13px; padding: 8px 12px; border-radius: 10px; }
.routes { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.done-card { max-width: 640px; margin: 0 auto; padding: 32px 24px; }
.done-card h1 { font-family: var(--font-display); font-weight: 600; font-size: 28px; letter-spacing: -.02em; }
@media (max-width: 520px) {
  .land-nav .logo-txt span { display: none; }
  .land-nav .logo-txt b { font-size: 14px; white-space: nowrap; }
  .land-nav .lang button { padding: 5px 6px; }
}
@media (max-width: 400px) { .land-nav .logo-txt { display: none; } .land-nav .btn.sm { padding: 7px 10px; } }
