/* sinav.dersino.com — karanlık mod
   html[data-theme="dark"] iken geçer. Aydınlık palet lisans.css :root'ta kalır. */

.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 1px solid var(--line, #e2e8f0);
    border-radius: 12px;
    background: var(--surface, #fff);
    color: var(--ink-soft, #475569);
    cursor: pointer;
    flex-shrink: 0;
    transition: background .15s, border-color .15s, color .15s;
}
.theme-toggle:hover { color: var(--brand, #2563eb); border-color: #93c5fd; background: var(--brand-50, #eff6ff); }
.theme-toggle:focus-visible { outline: 3px solid #2563eb; outline-offset: 2px; }
.theme-toggle svg { display: block; }
.theme-toggle [data-icon="sun"] { display: none; }
html[data-theme="dark"] .theme-toggle [data-icon="moon"] { display: none; }
html[data-theme="dark"] .theme-toggle [data-icon="sun"] { display: block; }
.theme-slot {
    position: fixed;
    top: max(12px, env(safe-area-inset-top));
    right: max(12px, env(safe-area-inset-right));
    z-index: 80;
}

html[data-theme="dark"] {
    color-scheme: dark;
    --bg: #0b1220;
    --surface: #141e30;
    --surface-2: #1c2940;
    --line: #2c3d58;
    --line-soft: #1e2d46;
    --ink: #e8eef8;
    --ink-soft: #c5d0e2;
    --muted: #93a0b8;
    --brand: #60a5fa;
    --brand-700: #93c5fd;
    --brand-50: #172554;
    --ok: #34d399;
    --ok-bg: #052e24;
    --ok-line: #065f46;
    --warn: #fbbf24;
    --warn-bg: #3a2a0a;
    --warn-line: #92400e;
    --bad: #fb7185;
    --bad-bg: #3f1219;
    --bad-line: #9f1239;
    --off: #cbd5e1;
    --off-bg: #1e293b;
    --off-line: #334155;
    --good: #34d399;
    --weak: #fb7185;
    --shadow: 0 1px 2px rgba(0, 0, 0, .35), 0 10px 28px rgba(0, 0, 0, .28);
    --s1: #60a5fa;
    --s2: #fb923c;
    --s3: #34d399;
    --s4: #fbbf24;
}

html[data-theme="dark"] body {
    background: var(--bg);
    color: var(--ink);
}

/* —— Kabuk: menü, üst çubuk, alt menü —— */
html[data-theme="dark"] .shell-app-wrap {
    background: var(--bg);
    color: var(--ink);
}
html[data-theme="dark"] .side,
html[data-theme="dark"] .side-head {
    background: #10192b;
    border-color: var(--line);
    color: var(--ink-soft);
}
html[data-theme="dark"] .side-logo-link {
    background: #fff;
    border-radius: 12px;
    padding: 4px 8px;
}
html[data-theme="dark"] .side-scroll-inner { scrollbar-color: #3d5270 transparent; }
html[data-theme="dark"] .side-scroll-inner::-webkit-scrollbar-thumb { background: #3d5270; }
html[data-theme="dark"] .side-close-btn { color: var(--muted); }
html[data-theme="dark"] .side-close-btn:hover { color: var(--ink); background: var(--surface-2); }
html[data-theme="dark"] .side-wa { background: #10192b; border-color: var(--line-soft); }
html[data-theme="dark"] .side-wa-link { background: #052e24; border-color: #065f46; }
html[data-theme="dark"] .side-wa-link:hover { background: #064e3b; }
html[data-theme="dark"] .side-wa-title { color: #a7f3d0; }
html[data-theme="dark"] .side-wa-phone { color: #6ee7b7; }
html[data-theme="dark"] .side-school-card { background: rgba(30, 58, 138, .35); border-color: #1e3a8a; }
html[data-theme="dark"] .side-school-badge,
html[data-theme="dark"] .side-user-school,
html[data-theme="dark"] .side-item-icon { color: #93c5fd; }
html[data-theme="dark"] .side-school-name,
html[data-theme="dark"] .side-user-name,
html[data-theme="dark"] .side-item-title,
html[data-theme="dark"] .shell-page-title { color: var(--ink); }
html[data-theme="dark"] .side-lic-days,
html[data-theme="dark"] .side-item-sub,
html[data-theme="dark"] .shell-page-sub { color: var(--muted); }
html[data-theme="dark"] .side-lic-pill.ok { background: #052e24; color: #6ee7b7; border-color: #065f46; }
html[data-theme="dark"] .side-lic-pill.bad { background: #3f1219; color: #fda4af; border-color: #9f1239; }
html[data-theme="dark"] .side-nav-item { color: var(--ink-soft); }
html[data-theme="dark"] .side-nav-item:hover,
html[data-theme="dark"] .side-nav-gsum:hover { background: var(--surface-2); color: var(--ink); }
html[data-theme="dark"] .side-nav-item.on,
html[data-theme="dark"] .side-nav-item.on .side-item-icon,
html[data-theme="dark"] .side-nav-item.on .side-item-sub { color: #fff; }
html[data-theme="dark"] .side-user-bar,
html[data-theme="dark"] .side-quick { background: #0e1726; border-color: var(--line); }
html[data-theme="dark"] .side-logout-btn { color: var(--muted); }
html[data-theme="dark"] .side-logout-btn:hover { background: #3f1219; color: #fda4af; }
html[data-theme="dark"] .side-quick-lic,
html[data-theme="dark"] .side-quick-app { background: var(--surface-2); border-color: var(--line); color: var(--ink-soft); }
html[data-theme="dark"] .side-quick-app { background: #172554; border-color: #1e3a8a; color: #bfdbfe; }
html[data-theme="dark"] .shell-header {
    background: rgba(16, 25, 43, .92);
    border-bottom-color: var(--line);
    box-shadow: none;
}
html[data-theme="dark"] .header-toggle-btn,
html[data-theme="dark"] .header-collapse-btn,
html[data-theme="dark"] .header-back-btn,
html[data-theme="dark"] .header-icon-btn,
html[data-theme="dark"] .theme-toggle,
html[data-theme="dark"] .sb-edge-toggle {
    background: var(--surface);
    border-color: var(--line);
    color: var(--ink-soft);
}
html[data-theme="dark"] .header-back-btn:hover,
html[data-theme="dark"] .header-icon-btn:hover,
html[data-theme="dark"] .header-collapse-btn:hover,
html[data-theme="dark"] .theme-toggle:hover,
html[data-theme="dark"] .sb-edge-toggle:hover {
    background: #172554;
    border-color: #1d4ed8;
    color: #bfdbfe;
}
html[data-theme="dark"] .topbar {
    background: rgba(16, 25, 43, .92);
    border-bottom-color: var(--line);
}
html[data-theme="dark"] .brand img,
html[data-theme="dark"] .login .brand img {
    background: #fff;
    border-radius: 10px;
    padding: 4px 8px;
}
html[data-theme="dark"] .bnav {
    background: rgba(16, 25, 43, .96);
    border-top-color: var(--line);
    box-shadow: none;
}
html[data-theme="dark"] .bnav-i { color: var(--muted); }
html[data-theme="dark"] .bnav-i.on { color: #93c5fd; }
html[data-theme="dark"] .bnav-i.on svg { background: #172554; }
html[data-theme="dark"] .bnav-i:active { background: var(--surface-2); }

/* —— Yüzeyler —— */
html[data-theme="dark"] :is(
    .card, .stat, .table-wrap, .dash-welcome-card, .hub-metric, .hub-agenda, .hub-alerts,
    .hub-box, .ho-ops, .nt-panel, .drop, .rank, .outcomes, .stu, .rp-plan, .rp-sum, .hp-story,
    .hub-pwa, .th-notif, .cls-def, .yk-slot, .login, .keybox, .qt-step, .qt-action, .hero-stat
) {
    background-color: var(--surface);
    border-color: var(--line);
    color: var(--ink);
    box-shadow: var(--shadow);
}
html[data-theme="dark"] .shell-content .card,
html[data-theme="dark"] .shell-content .stat,
html[data-theme="dark"] .shell-content .table-wrap,
html[data-theme="dark"] .shell-content .dash-welcome-card,
html[data-theme="dark"] .shell-content .drop {
    background: var(--surface);
    border-color: var(--line);
    color: var(--ink);
}
html[data-theme="dark"] .shell-content .card-head,
html[data-theme="dark"] .card-head { border-bottom-color: var(--line-soft); }
html[data-theme="dark"] .shell-content .card-head h2,
html[data-theme="dark"] .card-head h2,
html[data-theme="dark"] .hub-hello h1,
html[data-theme="dark"] .dash-school-title { color: var(--ink); }

html[data-theme="dark"] .hub-metric-teal { background: linear-gradient(165deg, #0c2f2c 0%, #141e30 58%); }
html[data-theme="dark"] .hub-metric-amber { background: linear-gradient(165deg, #3a2a0a 0%, #141e30 58%); }
html[data-theme="dark"] .hub-metric-rose { background: linear-gradient(165deg, #3f1219 0%, #141e30 58%); }
html[data-theme="dark"] .hub-metric-blue { background: linear-gradient(165deg, #172554 0%, #141e30 58%); }
html[data-theme="dark"] .hub-metric-green { background: linear-gradient(165deg, #052e24 0%, #141e30 58%); }
html[data-theme="dark"] .hub-metric-violet { background: linear-gradient(165deg, #2e1064 0%, #141e30 58%); }
html[data-theme="dark"] .hub-metric-value,
html[data-theme="dark"] .hub-title,
html[data-theme="dark"] .hub-hero b,
html[data-theme="dark"] .hub-agenda-head h2,
html[data-theme="dark"] .hub-alerts-head h2,
html[data-theme="dark"] .hub-agenda-time b,
html[data-theme="dark"] .hub-agenda-body strong,
html[data-theme="dark"] .hub-alert-body strong { color: var(--ink); }
html[data-theme="dark"] .hub-metric-bar { background: #24344e; }
html[data-theme="dark"] .hub-metric-chip,
html[data-theme="dark"] .hub-kpi,
html[data-theme="dark"] .hub-ico,
html[data-theme="dark"] .hub-pill,
html[data-theme="dark"] .hub-arrow,
html[data-theme="dark"] .hub-agenda-go,
html[data-theme="dark"] .hub-alert-go {
    background: var(--surface-2);
    color: var(--ink-soft);
    border-color: var(--line);
}
html[data-theme="dark"] .hub-box {
    background: linear-gradient(165deg, color-mix(in srgb, var(--t) 28%, #141e30) 0%, #141e30 55%);
    border-color: var(--line);
}
html[data-theme="dark"] .hub-box-acts a:hover { background: color-mix(in srgb, var(--t) 18%, #141e30); }
html[data-theme="dark"] .hub-kpi.is-bad { background: #3f1219; border-color: #9f1239; color: #fda4af; }
html[data-theme="dark"] .hub-chip-yok,
html[data-theme="dark"] .hub-chip-late { border-color: #9f1239; color: #fda4af; }
html[data-theme="dark"] .hub-agenda-day { background: var(--surface-2); color: var(--muted); }
html[data-theme="dark"] .hub-agenda-day b { color: var(--ink); }
html[data-theme="dark"] .hub-agenda-day:hover { background: #172554; color: #bfdbfe; border-color: #1d4ed8; }
html[data-theme="dark"] .hub-agenda-day.is-today { background: #172554; color: #93c5fd; border-color: #1d4ed8; }
html[data-theme="dark"] .hub-agenda-day.is-today b { color: #dbeafe; }
html[data-theme="dark"] .hub-agenda-day.is-selected,
html[data-theme="dark"] .hub-agenda-day.is-selected:hover { background: #1d4ed8; border-color: #1d4ed8; color: #fff; }
html[data-theme="dark"] .hub-agenda-day.is-selected b,
html[data-theme="dark"] .hub-agenda-day.is-selected span { color: #fff; }
html[data-theme="dark"] .hub-agenda-chip,
html[data-theme="dark"] .hub-agenda-item,
html[data-theme="dark"] .hub-agenda-empty,
html[data-theme="dark"] .hub-alert { background: var(--surface-2); border-color: var(--line); color: var(--ink-soft); }
html[data-theme="dark"] .hub-agenda-item.is-now { background: #172554; border-color: #1d4ed8; }
html[data-theme="dark"] .hub-ag-ozet { background: #3a2a0a; }
html[data-theme="dark"] .hub-ap-blue { background: #172554; border-color: #1e3a8a; color: #bfdbfe; }
html[data-theme="dark"] .hub-ap-amber { background: #3a2a0a; border-color: #92400e; color: #fcd34d; }
html[data-theme="dark"] .hub-ap-teal { background: #042f2e; border-color: #115e59; color: #5eead4; }
html[data-theme="dark"] .hub-ap-green { background: #052e24; border-color: #065f46; color: #6ee7b7; }
html[data-theme="dark"] .hub-ap-slate { background: #1e293b; border-color: #334155; color: #cbd5e1; }
html[data-theme="dark"] .hub-alert-critical { background: #3f1219; border-color: #9f1239; }
html[data-theme="dark"] .hub-alert-critical .hub-alert-mark { background: #881337; color: #fecdd3; }
html[data-theme="dark"] .hub-alert-critical .hub-alert-tag { color: #fda4af; }
html[data-theme="dark"] .hub-alert-warn { background: #3a2a0a; border-color: #92400e; }
html[data-theme="dark"] .hub-alert-warn .hub-alert-mark { background: #78350f; color: #fde68a; }
html[data-theme="dark"] .hub-alert-warn .hub-alert-tag { color: #fcd34d; }
html[data-theme="dark"] .hub-alert-info { background: var(--surface-2); }
html[data-theme="dark"] .hub-alert-info .hub-alert-mark { background: #334155; color: #e2e8f0; }
html[data-theme="dark"] .hub-alerts-ok { background: #052e24; border-color: #065f46; }
html[data-theme="dark"] .hub-alerts-ok strong { color: #bbf7d0; }
html[data-theme="dark"] .hub-alerts-ok span { color: #6ee7b7; }
html[data-theme="dark"] .hub-agenda-go:hover,
html[data-theme="dark"] .hub-alert-go:hover { background: #172554; color: #bfdbfe; border-color: #1d4ed8; }

/* —— Tablo, form, sekmeler —— */
html[data-theme="dark"] .table th,
html[data-theme="dark"] .shell-content .table thead th,
html[data-theme="dark"] .outcomes summary,
html[data-theme="dark"] .table tr.total td,
html[data-theme="dark"] tr.main-row td {
    background: var(--surface-2);
    color: var(--muted);
    border-color: var(--line);
}
html[data-theme="dark"] tr.main-row td,
html[data-theme="dark"] .table tr.total td,
html[data-theme="dark"] .shell-content .table tbody td { color: var(--ink-soft); }
html[data-theme="dark"] .table td,
html[data-theme="dark"] .shell-content .table tbody td { border-bottom-color: var(--line-soft); }
html[data-theme="dark"] .table tr:hover td,
html[data-theme="dark"] .shell-content .table tbody tr:hover td,
html[data-theme="dark"] .th-rows a:hover,
html[data-theme="dark"] .nt-item:hover { background: #1c2940; }
html[data-theme="dark"] .table tr.current td { background: #172554; }
html[data-theme="dark"] .code { background: var(--surface-2); color: var(--ink-soft); }

html[data-theme="dark"] :is(input, select, textarea),
html[data-theme="dark"] .shell-content :is(input, select, textarea),
html[data-theme="dark"] .field :is(input, select, textarea) {
    background: #0e1728;
    color: var(--ink);
    border-color: var(--line);
}
html[data-theme="dark"] :is(input, select, textarea):focus,
html[data-theme="dark"] .shell-content :is(input, select, textarea):focus {
    background: #101c33;
    border-color: var(--brand);
    box-shadow: 0 0 0 3px rgba(96, 165, 250, .22);
}
html[data-theme="dark"] ::placeholder { color: #7d8da6; }
html[data-theme="dark"] .tabs { background: var(--surface-2); }
html[data-theme="dark"] .tabs button.on,
html[data-theme="dark"] .tabs button.on { background: #243656; color: var(--ink); }
html[data-theme="dark"] .type-tab { color: var(--ink-soft); }
html[data-theme="dark"] .type-tab span,
html[data-theme="dark"] .hm-badge { background: var(--surface-2); color: var(--ink-soft); }
html[data-theme="dark"] .type-tab.on,
html[data-theme="dark"] .type-tab:hover { color: #93c5fd; }
html[data-theme="dark"] .type-tab.on span { background: #172554; color: #bfdbfe; }
html[data-theme="dark"] .chip { background: transparent; color: var(--ink-soft); border-color: var(--line); }
html[data-theme="dark"] .chip.on,
html[data-theme="dark"] .chip:hover,
html[data-theme="dark"] .shell-content .chip.on,
html[data-theme="dark"] .shell-content .chip:hover { background: #172554; border-color: #1d4ed8; color: #bfdbfe; }
html[data-theme="dark"] .btn-ghost { color: var(--ink-soft); }
html[data-theme="dark"] .btn-ghost:hover,
html[data-theme="dark"] .shell-content .btn-ghost:hover { background: var(--surface-2); color: var(--ink); }
html[data-theme="dark"] .btn-soft,
html[data-theme="dark"] .shell-content .btn-soft { background: #172554; color: #bfdbfe; border-color: #1e40af; }
html[data-theme="dark"] .btn-soft:hover,
html[data-theme="dark"] .shell-content .btn-soft:hover { background: #1e3a8a; }
html[data-theme="dark"] .quick button { background: var(--surface-2); color: var(--ink-soft); border-color: var(--line); }
html[data-theme="dark"] .drop,
html[data-theme="dark"] .shell-content .drop { background: #172554; border-color: #1d4ed8; }
html[data-theme="dark"] .drop:hover,
html[data-theme="dark"] .drop.over,
html[data-theme="dark"] .shell-content .drop:hover,
html[data-theme="dark"] .shell-content .drop.over { background: #1e3a8a; }
html[data-theme="dark"] .drop strong,
html[data-theme="dark"] .shell-content .drop strong { color: #bfdbfe; }
html[data-theme="dark"] .qt-banner,
html[data-theme="dark"] .shell-content .qt-banner { background: linear-gradient(90deg, #172554, #141e30); border-color: #1e3a8a; }
html[data-theme="dark"] .status { background: var(--surface-2); color: var(--ink-soft); border-color: var(--line); }

html[data-theme="dark"] .pill.type-lgs { color: #ddd6fe; background: #2e1064; border-color: #5b21b6; }
html[data-theme="dark"] .pill.type-tyt { color: #bae6fd; background: #0c4a6e; border-color: #0369a1; }
html[data-theme="dark"] .pill.type-gen { color: #a7f3d0; background: #052e24; border-color: #065f46; }
html[data-theme="dark"] .q-hi, html[data-theme="dark"] .a-ok { background: var(--ok-bg); border-color: var(--ok-line); }
html[data-theme="dark"] .q-mid { background: var(--warn-bg); border-color: var(--warn-line); }
html[data-theme="dark"] .q-lo, html[data-theme="dark"] .a-bad { background: var(--bad-bg); border-color: var(--bad-line); }
html[data-theme="dark"] .a-blank { background: var(--surface-2); border-color: var(--line); }
html[data-theme="dark"] .line-chart .me-dot,
html[data-theme="dark"] .line-chart .avg-dot { stroke: #141e30; }

/* —— Bildirim, öğretmen, kayıt parçaları —— */
html[data-theme="dark"] .nt-panel,
html[data-theme="dark"] .nt-item,
html[data-theme="dark"] .nt-foot,
html[data-theme="dark"] .nt-people,
html[data-theme="dark"] .nt-dev li,
html[data-theme="dark"] .nt-hist li,
html[data-theme="dark"] .th-kpis > div,
html[data-theme="dark"] .th-mini a,
html[data-theme="dark"] .th-work-list li,
html[data-theme="dark"] .rp-tags li,
html[data-theme="dark"] .rp-goal,
html[data-theme="dark"] .todo-ic,
html[data-theme="dark"] .ho-ops-card,
html[data-theme="dark"] .ho-ops-slate,
html[data-theme="dark"] .hp-story {
    background: var(--surface-2);
    border-color: var(--line);
    color: var(--ink-soft);
}
html[data-theme="dark"] .nt-item.unread,
html[data-theme="dark"] .nt-enable { background: #172554; color: #bfdbfe; border-color: #1e3a8a; }
html[data-theme="dark"] .nt-badge { box-shadow: 0 0 0 2px #141e30; }
html[data-theme="dark"] .nt-panel-head b,
html[data-theme="dark"] .nt-item-body b { color: var(--ink); }
html[data-theme="dark"] .th-notif-info { background: var(--surface-2); border-color: var(--line); }
html[data-theme="dark"] .hero-stat { background: linear-gradient(180deg, #141e30, #172554); border-color: #1e3a8a; }
html[data-theme="dark"] .hero-stat strong { color: #bfdbfe; }
html[data-theme="dark"] .login-wrap { background: radial-gradient(900px 420px at 50% -10%, #1e3a8a, transparent); }

/* Giriş ekranı (giris.php kendi paletini kullanır) */
html[data-theme="dark"] body:has(.login) {
    --ink: #e8eef8;
    --muted: #93a0b8;
    --line: rgba(226, 232, 240, .16);
    --card: rgba(20, 30, 48, .94);
    --accent: #2dd4bf;
    --accent-2: #14b8a6;
    background:
        radial-gradient(900px 480px at 12% -10%, rgba(13, 148, 136, .28), transparent 55%),
        radial-gradient(700px 420px at 100% 10%, rgba(217, 119, 6, .16), transparent 50%),
        linear-gradient(160deg, #0b1220 0%, #10192b 50%, #0e1726 100%);
    color: var(--ink);
}
html[data-theme="dark"] .login .card { background: var(--card, #141e30); }
html[data-theme="dark"] .login .tabs { background: rgba(255, 255, 255, .06); }
html[data-theme="dark"] .login .tabs button.on { background: #243656; color: #e8eef8; }
html[data-theme="dark"] .login .msg.err { background: #3f1219; color: #fda4af; border-color: #9f1239; }
html[data-theme="dark"] .login .msg.warn { background: #3a2a0a; color: #fcd34d; border-color: #92400e; }
html[data-theme="dark"] .vp-tile { background: linear-gradient(180deg, #141e30, #101827); border-color: #2c3d58; }
html[data-theme="dark"] .vp-tile.empty { background: #121a28; }
html[data-theme="dark"] .vp-tile.warn { background: linear-gradient(180deg, #3a2a0a, #1c1408); border-color: #92400e; }
html[data-theme="dark"] .vp-tile strong { color: #93c5fd; }
html[data-theme="dark"] .vp-tile.warn strong { color: #fdba74; }
html[data-theme="dark"] a.vp-tile:hover { border-color: #3b82f6; box-shadow: 0 0 0 3px rgba(59, 130, 246, .15); }
html[data-theme="dark"] .vp-alert-bad { background: #3f1219; color: #fda4af; border-color: #7f1d1d; }
html[data-theme="dark"] .vp-alert-warn { background: #3a2a0a; color: #fdba74; border-color: #92400e; }
html[data-theme="dark"] .vp-alert-info { background: #0f1e3a; color: #93c5fd; border-color: #1e3a8a; }
html[data-theme="dark"] .vp-jump a { background: #141e30; border-color: #2c3d58; color: #cbd5e1; }
html[data-theme="dark"] .vp-jump a:hover { background: #172554; border-color: #3b82f6; color: #bfdbfe; }
html[data-theme="dark"] .vp-pay-bar { background: #1e293b; }
html[data-theme="dark"] .vp-pill-odendi { background: #064e3b; color: #6ee7b7; }
html[data-theme="dark"] .vp-pill-gecikti { background: #450a0a; color: #fda4af; }
html[data-theme="dark"] .vp-pill-bekliyor { background: #1e293b; color: #94a3b8; }
html[data-theme="dark"] .vp-pill-kismi { background: #3a2a0a; color: #fdba74; }
html[data-theme="dark"] .vp-row-warn td { background: #2a1c0a; }
html[data-theme="dark"] .vp-sec { border-top-color: #2c3d58; }
html[data-theme="dark"] .st-plan-add,
html[data-theme="dark"] .st-plan-add-full,
html[data-theme="dark"] .st-plan-stats > div,
html[data-theme="dark"] .st-hours-day { background: #101827; border-color: #2c3d58; }
html[data-theme="dark"] .st-plan-hours,
html[data-theme="dark"] .st-plan-tpl,
html[data-theme="dark"] .st-week-col,
html[data-theme="dark"] .st-plan-list li { background: #141e30; border-color: #2c3d58; }
html[data-theme="dark"] .st-week-col li { background: #0f172a; border-color: #243656; }
html[data-theme="dark"] .st-week-col.today,
html[data-theme="dark"] .st-plan-list li.today,
html[data-theme="dark"] .st-hours-day.today { border-color: #3b82f6; box-shadow: 0 0 0 3px rgba(59, 130, 246, .15); }
html[data-theme="dark"] .st-hours-day.on { border-color: #6366f1; }
html[data-theme="dark"] .st-plan-box { background: #0f172a; border-color: #2c3d58; color: #94a3b8; }
html[data-theme="dark"] .st-plan-box.on { background: #064e3b; border-color: #059669; color: #6ee7b7; }
html[data-theme="dark"] .st-plan-body b,
html[data-theme="dark"] .st-week-col header span { color: #93c5fd; }
html[data-theme="dark"] .st-week-col .st-plan-body em { color: #a5b4fc; }
html[data-theme="dark"] .st-dash-card,
html[data-theme="dark"] .st-weak,
html[data-theme="dark"] .st-grid-wrap,
html[data-theme="dark"] .st-modal-card { background: #141e30; border-color: #2c3d58; }
html[data-theme="dark"] .st-dash-card strong { color: #93c5fd; }
html[data-theme="dark"] .st-weak-chip,
html[data-theme="dark"] .st-hg-cell,
html[data-theme="dark"] .st-status-btn { background: #0f172a; border-color: #2c3d58; }
html[data-theme="dark"] .st-hg-day,
html[data-theme="dark"] .st-hg-corner,
html[data-theme="dark"] .st-hg-time,
html[data-theme="dark"] .st-modal-card footer { background: #101827; border-color: #2c3d58; }
html[data-theme="dark"] .st-hg-cell.today,
html[data-theme="dark"] .st-hg-day.today { background: #172554; }
html[data-theme="dark"] .st-block { background: linear-gradient(180deg, #1e1b4b, #312e81); border-color: #6366f1; }
html[data-theme="dark"] .st-agenda-head { background: #172554; }
html[data-theme="dark"] .st-agenda-head span { color: #93c5fd; }
html[data-theme="dark"] .st-card { background: #0f172a; border-color: #2c3d58; }
html[data-theme="dark"] .st-card.is-done { background: #101827; }
html[data-theme="dark"] .st-card-topic { color: #94a3b8; }
html[data-theme="dark"] .st-info-box { background: #0f172a; border-color: #1e3a8a; }
html[data-theme="dark"] .st-info-box-h a { color: #93c5fd; }
html[data-theme="dark"] .note-dismissed { background: #101827; }
html[data-theme="dark"] .st-tasks { background: #101827; border-color: #2c3d58; }
html[data-theme="dark"] .st-tasks-when,
html[data-theme="dark"] .st-tasks-list li { background: #0f172a; border-color: #2c3d58; }
html[data-theme="dark"] .st-tasks-list li.due { background: #431407; border-color: #9a3412; }
html[data-theme="dark"] .st-remind-q { background: #0f172a; border-color: #2c3d58; color: #e2e8f0; }
html[data-theme="dark"] .st-tasks-at { color: #93c5fd; }
html[data-theme="dark"] .st-agenda-empty { background: #101827; border-color: #2c3d58; }
html[data-theme="dark"] .st-weak-box { background: #101827; border-color: #2c3d58; }
html[data-theme="dark"] .st-weak-tab { background: #0f172a; border-color: #2c3d58; color: #e2e8f0; }
html[data-theme="dark"] .st-weak-tab small { background: #1e293b; color: #94a3b8; }
html[data-theme="dark"] .st-weak-tab.on { background: #2563eb; border-color: #2563eb; color: #fff; }
html[data-theme="dark"] .st-weak-row { background: #0f172a; border-color: #2c3d58; }
html[data-theme="dark"] .st-weak-add { background: #2563eb; }
html[data-theme="dark"] .st-dur-custom { background: #0f172a; border-color: #2c3d58; }
html[data-theme="dark"] .st-dur-custom input[type="number"] { background: #101827; border-color: #2c3d58; color: #e2e8f0; }
html[data-theme="dark"] .st-dur-btn { background: #0f172a; border-color: #2c3d58; color: #e2e8f0; }
html[data-theme="dark"] .st-dur-btn.on { background: #2563eb; border-color: #2563eb; color: #fff; }
html[data-theme="dark"] .st-dur-btn.st-dur-deneme { background: #1e1b4b; border-color: #6366f1; color: #a5b4fc; }
html[data-theme="dark"] .st-st-done { background: linear-gradient(180deg, #064e3b, #065f46); border-color: #059669; }
html[data-theme="dark"] .st-st-progress { background: linear-gradient(180deg, #78350f, #92400e); border-color: #f59e0b; }
html[data-theme="dark"] .st-st-postponed { background: linear-gradient(180deg, #7c2d12, #9a3412); border-color: #fb923c; }
html[data-theme="dark"] .st-status-btn.on { background: #3b82f6; border-color: #3b82f6; color: #fff; }
html[data-theme="dark"] .st-day-tab { background: #0f172a; border-color: #2c3d58; color: #e2e8f0; }
html[data-theme="dark"] .st-day-tab.on { background: #2563eb; border-color: #2563eb; color: #fff; }
html[data-theme="dark"] .st-day-tab.on small { color: #bfdbfe; }
html[data-theme="dark"] .st-hg-day.st-m-show { background: #172554; }
html[data-theme="dark"] .login .msg.ok { background: #052e24; color: #6ee7b7; border-color: #065f46; }
html[data-theme="dark"] .login .pw-toggle:hover { background: rgba(255, 255, 255, .06); color: #e8eef8; }

/* Öğrenci / veli SPA (Tailwind yardımcıları) */
html[data-theme="dark"] body.bg-slate-50,
html[data-theme="dark"] .bg-slate-50,
html[data-theme="dark"] .bg-slate-50\/50,
html[data-theme="dark"] .bg-slate-50\/60,
html[data-theme="dark"] .bg-slate-50\/70,
html[data-theme="dark"] .bg-slate-50\/80 { background-color: #0b1220; }
html[data-theme="dark"] .bg-white,
html[data-theme="dark"] .bg-white\/95,
html[data-theme="dark"] .bg-white\/85,
html[data-theme="dark"] .bg-white\/80,
html[data-theme="dark"] .bg-white\/70 { background-color: #141e30; }
html[data-theme="dark"] .bg-slate-100,
html[data-theme="dark"] .bg-slate-100\/50,
html[data-theme="dark"] .bg-slate-100\/80,
html[data-theme="dark"] .bg-slate-200,
html[data-theme="dark"] .bg-slate-200\/70 { background-color: #1c2940; }
html[data-theme="dark"] .text-slate-950,
html[data-theme="dark"] .text-slate-900,
html[data-theme="dark"] .text-slate-800 { color: #e8eef8; }
html[data-theme="dark"] .text-slate-700,
html[data-theme="dark"] .text-slate-600 { color: #c5d0e2; }
html[data-theme="dark"] .text-slate-500,
html[data-theme="dark"] .text-slate-400 { color: #93a0b8; }
html[data-theme="dark"] .border-slate-100,
html[data-theme="dark"] .border-slate-200,
html[data-theme="dark"] .border-slate-200\/50,
html[data-theme="dark"] .border-slate-200\/60,
html[data-theme="dark"] .border-slate-200\/70,
html[data-theme="dark"] .border-slate-200\/80,
html[data-theme="dark"] .border-slate-200\/90,
html[data-theme="dark"] .border-slate-300,
html[data-theme="dark"] .divide-slate-100 > :not([hidden]) ~ :not([hidden]) { border-color: #2c3d58; }
html[data-theme="dark"] .bg-emerald-50,
html[data-theme="dark"] .bg-emerald-50\/40,
html[data-theme="dark"] .bg-emerald-50\/50,
html[data-theme="dark"] .bg-emerald-50\/70,
html[data-theme="dark"] .bg-emerald-100 { background-color: #052e24; }
html[data-theme="dark"] .text-emerald-900,
html[data-theme="dark"] .text-emerald-800,
html[data-theme="dark"] .text-emerald-700,
html[data-theme="dark"] .text-emerald-600 { color: #6ee7b7; }
html[data-theme="dark"] .bg-amber-50,
html[data-theme="dark"] .bg-amber-50\/70,
html[data-theme="dark"] .bg-amber-100 { background-color: #3a2a0a; }
html[data-theme="dark"] .text-amber-950,
html[data-theme="dark"] .text-amber-900,
html[data-theme="dark"] .text-amber-800,
html[data-theme="dark"] .text-amber-700,
html[data-theme="dark"] .text-amber-600 { color: #fcd34d; }
html[data-theme="dark"] .bg-rose-50,
html[data-theme="dark"] .bg-rose-50\/20,
html[data-theme="dark"] .bg-rose-50\/50,
html[data-theme="dark"] .bg-rose-100 { background-color: #3f1219; }
html[data-theme="dark"] .text-rose-950,
html[data-theme="dark"] .text-rose-900,
html[data-theme="dark"] .text-rose-800,
html[data-theme="dark"] .text-rose-700,
html[data-theme="dark"] .text-rose-600 { color: #fda4af; }
html[data-theme="dark"] .bg-blue-50\/70,
html[data-theme="dark"] .bg-blue-50\/90,
html[data-theme="dark"] .bg-blue-100,
html[data-theme="dark"] .bg-blue-100\/60,
html[data-theme="dark"] .bg-brand-50,
html[data-theme="dark"] .bg-brand-50\/50,
html[data-theme="dark"] .bg-indigo-50,
html[data-theme="dark"] .bg-indigo-50\/70,
html[data-theme="dark"] .bg-indigo-100 { background-color: #172554; }
html[data-theme="dark"] .text-\[\#0058be\],
html[data-theme="dark"] .hover\:text-\[\#0058be\]:hover { color: #93c5fd; }
html[data-theme="dark"] img[alt="dersino"],
html[data-theme="dark"] img[alt="Dersino"] {
    background: #fff;
    border-radius: 12px;
    padding: 4px 10px;
}
html[data-theme="dark"] .text-blue-900,
html[data-theme="dark"] .text-blue-600,
html[data-theme="dark"] .text-brand-900,
html[data-theme="dark"] .text-brand-800,
html[data-theme="dark"] .text-brand-700,
html[data-theme="dark"] .text-brand-600,
html[data-theme="dark"] .text-indigo-700,
html[data-theme="dark"] .text-indigo-600 { color: #93c5fd; }
html[data-theme="dark"] .bg-purple-50,
html[data-theme="dark"] .bg-purple-50\/40,
html[data-theme="dark"] .bg-purple-50\/90,
html[data-theme="dark"] .bg-purple-100,
html[data-theme="dark"] .bg-purple-100\/60 { background-color: #2e1064; }
html[data-theme="dark"] .text-purple-950,
html[data-theme="dark"] .text-purple-900,
html[data-theme="dark"] .text-purple-800,
html[data-theme="dark"] .text-purple-700,
html[data-theme="dark"] .text-purple-600 { color: #d8b4fe; }
html[data-theme="dark"] .bg-teal-50 { background-color: #042f2e; }
html[data-theme="dark"] .text-teal-800,
html[data-theme="dark"] .text-teal-600 { color: #5eead4; }
html[data-theme="dark"] .border-emerald-100,
html[data-theme="dark"] .border-emerald-200,
html[data-theme="dark"] .border-amber-100,
html[data-theme="dark"] .border-amber-200,
html[data-theme="dark"] .border-rose-100,
html[data-theme="dark"] .border-rose-200,
html[data-theme="dark"] .border-indigo-100,
html[data-theme="dark"] .border-indigo-200,
html[data-theme="dark"] .border-purple-100,
html[data-theme="dark"] .border-purple-200,
html[data-theme="dark"] .border-brand-200 { border-color: #2c3d58; }
html[data-theme="dark"] .hover\:bg-slate-50:hover,
html[data-theme="dark"] .hover\:bg-slate-100:hover,
html[data-theme="dark"] .hover\:bg-white:hover,
html[data-theme="dark"] .hover\:bg-slate-50\/70:hover,
html[data-theme="dark"] .hover\:bg-slate-50\/80:hover { background-color: #1c2940; }
html[data-theme="dark"] .hover\:bg-slate-200:hover,
html[data-theme="dark"] .hover\:bg-slate-200\/70:hover { background-color: #243656; }
html[data-theme="dark"] .hover\:text-slate-900:hover,
html[data-theme="dark"] .hover\:text-slate-800:hover,
html[data-theme="dark"] .hover\:text-slate-700:hover { color: #f8fafc; }
html[data-theme="dark"] .focus\:bg-white:focus { background-color: #101c33; }
html[data-theme="dark"] .ring-brand-50,
html[data-theme="dark"] .ring-emerald-200,
html[data-theme="dark"] .ring-rose-200 { --tw-ring-color: #2c3d58; }

@media (max-width: 760px) {
    .theme-toggle { width: 36px; height: 36px; }
}

@media print {
    .theme-toggle, .theme-slot { display: none !important; }
    html[data-theme="dark"],
    html[data-theme="dark"] body,
    html[data-theme="dark"] .shell-app-wrap {
        --bg: #fff;
        --surface: #fff;
        --ink: #0f172a;
        --ink-soft: #334155;
        --muted: #64748b;
        background: #fff !important;
        color: #0f172a !important;
    }
    html[data-theme="dark"] :is(.card, .stat, .side, .shell-header, .table-wrap, .hub-metric, .hub-agenda, .hub-box) {
        background: #fff !important;
        color: #0f172a !important;
        box-shadow: none !important;
    }
}

/* Okul modu geniş kartlar */
html[data-theme="dark"] .hub-wide { background: linear-gradient(120deg, color-mix(in srgb, var(--t) 22%, #141e30) 0%, #141e30 45%); border-color: #24344e; border-left-color: var(--t); }
html[data-theme="dark"] .hub-wide-head h2, html[data-theme="dark"] .hub-wbtn, html[data-theme="dark"] .hub-wide-status b { color: var(--ink); }
html[data-theme="dark"] .hub-wbtn, html[data-theme="dark"] .hub-wide-status, html[data-theme="dark"] .hub-mode-opt { background: #1a2740; border-color: #2c3e5c; }
html[data-theme="dark"] .hub-wbtn-ico { background: color-mix(in srgb, var(--t) 22%, #1a2740); }
html[data-theme="dark"] .hub-wbtn.is-main { background: var(--t); border-color: var(--t); color: #fff; }
html[data-theme="dark"] .hub-wide .hub-ico { background: #1a2740; }
html[data-theme="dark"] .hub-mode-opt:has(input:checked) { border-color: #60a5fa; background: #172554; }
