:root {
    --s1: #10b981; --s2: #f59e0b; --s3: #ef4444;
    --card: #ffffff; --card-border: #e8eaf0; --muted: #64748b; --ink: #0f172a; --soft: #f1f3f9;
    --accent: #4f46e5; --accent-2: #7c3aed;
    --shadow: 0 1px 2px rgba(16,24,40,.04), 0 1px 3px rgba(16,24,40,.06);
}
.app.dark { --card: #121a2e; --card-border: #1f2a44; --muted: #94a3b8; --ink: #e2e8f0; --soft: #0f1628; --shadow: none; }

html, body { font-family: Inter, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased; }
body { background: var(--mud-palette-background); }
.main { min-height: 100vh; }
.content { padding: 88px 32px 48px; max-width: 1640px; margin: 0 auto; }
@media (max-width: 700px) { .content { padding: 80px 14px 32px; } }

/* ── Top bar ── */
.topbar { backdrop-filter: saturate(180%) blur(12px); border-bottom: 1px solid var(--card-border); }
.crumb { display: flex; gap: 8px; align-items: center; font-size: .85rem; color: var(--muted); margin-left: 6px; }
.crumb .bank { color: var(--ink); font-weight: 600; }
.crumb .sep { opacity: .5; }
@media (max-width: 800px) { .crumb { display: none; } }
.period-pill { display: flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; background: var(--soft); border: 1px solid var(--card-border); font-size: .8rem; color: var(--ink); }
.dot-live { width: 7px; height: 7px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 3px rgba(34,197,94,.2); }
.demo-pill { margin: 0 8px; font-size: .68rem; font-weight: 700; letter-spacing: .08em; padding: 4px 8px; border-radius: 6px; background: linear-gradient(135deg,#f59e0b,#ef4444); color: #fff; }
.user-chip { display: flex; align-items: center; gap: 10px; padding: 4px 8px 4px 4px; border-radius: 12px; cursor: pointer; border: 1px solid var(--card-border); background: var(--card); }
.user-chip:hover { border-color: var(--accent); }
.user-chip .who { line-height: 1.15; }
.user-chip .name, .menu-user .name { font-weight: 600; font-size: .82rem; color: var(--ink); }
.user-chip .role, .menu-user .role { font-size: .72rem; color: var(--muted); }
@media (max-width: 700px) { .user-chip .who { display: none; } }
.avatar { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; font-weight: 700; font-size: .75rem; color: #fff; background: linear-gradient(135deg, var(--accent), var(--accent-2)); }
.avatar.sm { width: 28px; height: 28px; border-radius: 8px; font-size: .7rem; }
.menu-caption { padding: 10px 16px 6px; font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 600; }
.menu-user { display: flex; gap: 10px; align-items: center; }
.menu-user.active .name { color: var(--accent); }

/* ── Sidebar ── */
.sidebar { border-right: 1px solid rgba(255,255,255,.04) !important; background: radial-gradient(1200px 400px at -10% -10%, rgba(99,102,241,.25), transparent 50%), #0b1120 !important; }
.brand { display: flex; align-items: center; gap: 12px; padding: 18px 20px 14px; }
.brand .logo { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 1.1rem; background: linear-gradient(135deg,#6366f1,#a855f7); box-shadow: 0 6px 20px rgba(99,102,241,.45); }
.brand-name { color: #fff; font-weight: 800; letter-spacing: .02em; }
.brand-sub { color: #94a3b8; font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; }
.nav { padding: 4px 10px 16px; }
.nav-section { padding: 16px 12px 6px; color: #64748b; font-size: .66rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.nav .mud-nav-link { border-radius: 9px; margin: 1px 0; padding: 7px 12px !important; color: #cbd5e1; font-size: .84rem; }
.nav .mud-nav-link:hover { background: rgba(255,255,255,.06) !important; color: #fff; }
.nav .mud-nav-link.active { background: linear-gradient(90deg, rgba(99,102,241,.35), rgba(99,102,241,.08)) !important; color: #fff !important; font-weight: 600; box-shadow: inset 2px 0 0 #818cf8; }
.nav .mud-nav-link .mud-nav-link-icon { color: #94a3b8; font-size: 1.15rem; }
.nav .mud-nav-link.active .mud-nav-link-icon { color: #a5b4fc; }
.sidebar-foot { padding: 14px 22px 22px; color: #475569; font-size: .7rem; }

/* ── Page header ── */
.page-header { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.eyebrow { font-size: .72rem; font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: .12em; margin-bottom: 4px; }
.app.dark .eyebrow { color: #a5b4fc; }
.page-title { font-size: 1.6rem; font-weight: 800; letter-spacing: -.02em; color: var(--ink); margin: 0; }
.page-subtitle { color: var(--muted); margin-top: 4px; font-size: .9rem; max-width: 820px; }
.page-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* ── Cards ── */
.card { background: var(--card); border: 1px solid var(--card-border); border-radius: 14px; box-shadow: var(--shadow); padding: 18px 20px; }
.card.flush { padding: 0; overflow: hidden; }
.card-title { font-weight: 700; color: var(--ink); font-size: .95rem; display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 12px; }
.card-title .hint { font-weight: 500; font-size: .78rem; color: var(--muted); }
.card.flush .card-title { padding: 16px 20px 0; }
.grid { display: grid; gap: 16px; }
.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)); }
.g5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.g-2-1 { grid-template-columns: 2fr 1fr; }
.g-1-2 { grid-template-columns: 1fr 2fr; }
@media (max-width: 1200px) { .g4, .g5 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 900px) { .g2, .g3, .g4, .g5, .g-2-1, .g-1-2 { grid-template-columns: minmax(0, 1fr); } }
.mt { margin-top: 16px; } .mb { margin-bottom: 16px; }

/* ── KPI ── */
.kpi-card { background: var(--card); border: 1px solid var(--card-border); border-radius: 14px; padding: 16px 18px; box-shadow: var(--shadow); position: relative; overflow: hidden; }
.kpi-card::after { content: ""; position: absolute; inset: auto -40px -60px auto; width: 140px; height: 140px; border-radius: 50%; background: radial-gradient(circle, rgba(99,102,241,.08), transparent 70%); }
.kpi-top { display: flex; justify-content: space-between; align-items: center; }
.kpi-label { font-size: .76rem; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.kpi-icon { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; }
.kpi-value { font-size: 1.6rem; font-weight: 800; color: var(--ink); letter-spacing: -.02em; margin-top: 8px; font-variant-numeric: tabular-nums; }
.kpi-sub { font-size: .78rem; color: var(--muted); margin-top: 2px; }
.kpi-sub.up { color: #16a34a; } .kpi-sub.down { color: #dc2626; }

/* ── Chips ── */
.status-chip { display: inline-flex; align-items: center; padding: 2px 9px; border-radius: 999px; font-size: .72rem; font-weight: 600; white-space: nowrap; border: 1px solid transparent; }
.status-chip.ok { background: #dcfce7; color: #166534; } .status-chip.warn { background: #fef3c7; color: #92400e; }
.status-chip.bad { background: #fee2e2; color: #991b1b; } .status-chip.info { background: #e0e7ff; color: #3730a3; }
.status-chip.muted { background: var(--soft); color: var(--muted); border-color: var(--card-border); }
.status-chip.s1 { background: #d1fae5; color: #065f46; } .status-chip.s2 { background: #fef3c7; color: #92400e; } .status-chip.s3 { background: #fee2e2; color: #991b1b; }
.app.dark .status-chip.ok { background: rgba(34,197,94,.15); color: #86efac; } .app.dark .status-chip.warn, .app.dark .status-chip.s2 { background: rgba(245,158,11,.15); color: #fcd34d; }
.app.dark .status-chip.bad, .app.dark .status-chip.s3 { background: rgba(239,68,68,.15); color: #fca5a5; } .app.dark .status-chip.info { background: rgba(99,102,241,.18); color: #c7d2fe; }
.app.dark .status-chip.s1 { background: rgba(16,185,129,.15); color: #6ee7b7; }

/* ── Stage bar ── */
.stage-bar { display: flex; width: 100%; border-radius: 999px; overflow: hidden; background: var(--soft); }
.stage-bar .seg { height: 100%; transition: width .6s ease; }
.seg.s1, .dot.s1 { background: var(--s1); } .seg.s2, .dot.s2 { background: var(--s2); } .seg.s3, .dot.s3 { background: var(--s3); }
.stage-legend { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 8px; font-size: .76rem; color: var(--muted); }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; }

/* ── Tables ── */
.tbl { width: 100%; border-collapse: separate; border-spacing: 0; font-size: .83rem; }
.tbl th { text-align: left; font-weight: 600; color: var(--muted); font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; padding: 10px 12px; border-bottom: 1px solid var(--card-border); background: var(--soft); position: sticky; top: 0; z-index: 1; }
.tbl td { padding: 9px 12px; border-bottom: 1px solid var(--card-border); color: var(--ink); }
.tbl tr:last-child td { border-bottom: none; }
.tbl tbody tr:hover td { background: rgba(99,102,241,.04); }
.tbl .num, .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tbl tr.total td { font-weight: 700; background: var(--soft); }
.tbl tr.section td { font-weight: 700; color: var(--accent); background: transparent; padding-top: 16px; }
.app.dark .tbl tr.section td { color: #a5b4fc; }
.tbl td.indent { padding-left: 28px; }
.tbl-wrap { overflow-x: auto; }
.tbl-wrap.scroll { max-height: 560px; overflow-y: auto; }
.neg { color: #dc2626; } .pos { color: #16a34a; }
.mono { font-family: "Cascadia Code", Consolas, monospace; font-size: .8rem; }
.muted { color: var(--muted); }
.small { font-size: .78rem; }
.link { color: var(--accent); cursor: pointer; font-weight: 600; text-decoration: none; }
.app.dark .link { color: #a5b4fc; }
.link:hover { text-decoration: underline; }

/* ── Close checklist ── */
.steps { display: flex; flex-direction: column; gap: 2px; }
.step { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-radius: 10px; }
.step:hover { background: var(--soft); }
.step .num-badge { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: .78rem; flex-shrink: 0; }
.step.done .num-badge { background: #dcfce7; color: #15803d; } .step.todo .num-badge { background: var(--soft); color: var(--muted); border: 1px dashed var(--card-border); }
.app.dark .step.done .num-badge { background: rgba(34,197,94,.15); color: #86efac; }
.step .title { font-weight: 600; color: var(--ink); font-size: .86rem; }
.step .detail { font-size: .76rem; color: var(--muted); }
.progress-ring { font-size: 2.2rem; font-weight: 800; color: var(--ink); }

/* ── Matrix / heat ── */
.heat td.cell { text-align: center; font-variant-numeric: tabular-nums; font-weight: 600; }
.flow { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: .78rem; }
.flow .node { padding: 6px 10px; border-radius: 8px; background: var(--soft); border: 1px solid var(--card-border); color: var(--ink); font-weight: 600; }
.flow .arrow { color: var(--muted); }

/* ── Misc ── */
.bar-row { display: grid; grid-template-columns: 140px 1fr 110px; gap: 10px; align-items: center; padding: 6px 0; font-size: .82rem; }
.bar-row .track { height: 9px; background: var(--soft); border-radius: 999px; overflow: hidden; }
.bar-row .fill { height: 100%; border-radius: 999px; background: linear-gradient(90deg, #6366f1, #a855f7); }
.pill-tabs .mud-tabs-tabbar { background: transparent !important; }
.hero { border-radius: 18px; padding: 22px 26px; color: #fff; background: radial-gradient(800px 300px at 100% 0%, rgba(168,85,247,.55), transparent 60%), linear-gradient(135deg, #312e81, #4f46e5 55%, #0ea5e9); box-shadow: 0 10px 30px rgba(79,70,229,.25); }
.hero .h-title { font-size: 1.3rem; font-weight: 800; }
.hero .h-sub { opacity: .85; font-size: .88rem; margin-top: 4px; }
.hero .h-stats { display: flex; gap: 32px; flex-wrap: wrap; margin-top: 16px; }
.hero .h-stat .v { font-size: 1.5rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.hero .h-stat .l { font-size: .72rem; opacity: .8; text-transform: uppercase; letter-spacing: .08em; }
.empty { padding: 36px; text-align: center; color: var(--muted); }
.kv { display: grid; grid-template-columns: 180px 1fr; gap: 8px 16px; font-size: .84rem; }
.kv .k { color: var(--muted); } .kv .v { color: var(--ink); font-weight: 500; }
.formula { font-family: "Cascadia Code", Consolas, monospace; background: var(--soft); border: 1px solid var(--card-border); border-radius: 10px; padding: 12px 14px; font-size: .82rem; color: var(--ink); }
.mud-table-root .mud-table-head .mud-table-cell { font-weight: 600; font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.mud-chart text { fill: var(--muted) !important; }
#blazor-error-ui { display: none; position: fixed; bottom: 16px; left: 50%; transform: translateX(-50%); z-index: 2000; background: #7f1d1d; color: #fff; padding: 10px 18px; border-radius: 10px; box-shadow: 0 10px 30px rgba(0,0,0,.25); font-size: .85rem; }
#blazor-error-ui a { color: #fecaca; font-weight: 700; margin-left: 8px; }
@media print { .sidebar, .topbar, .page-actions { display: none !important; } .mud-main-content { margin-left: 0 !important; padding-top: 0 !important; } }

/* ── Sign-in (static server-rendered account pages) ── */
.auth-shell { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); font-family: Inter, "Segoe UI", sans-serif; background: #f5f6fa; }
.auth-side { background: radial-gradient(900px 400px at -10% -10%, rgba(99,102,241,.45), transparent 55%), linear-gradient(160deg, #0b1120, #1e1b4b); color: #cbd5e1; padding: 36px 48px; display: flex; flex-direction: column; justify-content: space-between; }
.auth-side .brand { padding: 0; }
.auth-pitch h2 { color: #fff; font-size: 2rem; font-weight: 800; letter-spacing: -.02em; margin: 0 0 12px; }
.auth-pitch p { font-size: 1rem; line-height: 1.6; max-width: 460px; }
.auth-pitch ul { padding-left: 18px; line-height: 2; color: #a5b4fc; }
.auth-foot { font-size: .75rem; color: #64748b; }
.auth-main { display: grid; place-items: center; padding: 32px 16px; }
.auth-card { width: 100%; max-width: 420px; background: #fff; border: 1px solid #e8eaf0; border-radius: 18px; padding: 32px; box-shadow: 0 20px 50px rgba(15,23,42,.08); }
.auth-card h1 { font-size: 1.6rem; font-weight: 800; color: #0f172a; margin: 0 0 6px; letter-spacing: -.02em; }
.auth-sub { color: #64748b; font-size: .9rem; margin: 0 0 18px; line-height: 1.5; }
.auth-card label { display: block; font-size: .8rem; font-weight: 600; color: #334155; margin: 14px 0 6px; }
.auth-card input { width: 100%; box-sizing: border-box; padding: 11px 12px; border: 1px solid #cbd5e1; border-radius: 10px; font-size: .95rem; font-family: inherit; }
.auth-card input:focus { outline: none; border-color: #6366f1; box-shadow: 0 0 0 3px rgba(99,102,241,.18); }
.auth-card .code-input { font-size: 1.6rem; letter-spacing: .5em; text-align: center; font-family: "Cascadia Code", Consolas, monospace; }
.auth-btn { display: block; width: 100%; box-sizing: border-box; text-align: center; margin-top: 20px; padding: 12px; border: 0; border-radius: 10px; background: linear-gradient(135deg, #4f46e5, #7c3aed); color: #fff; font-weight: 700; font-size: .95rem; cursor: pointer; text-decoration: none; font-family: inherit; }
.auth-btn:hover { filter: brightness(1.08); }
.auth-btn.secondary { background: #fff; color: #4f46e5; border: 1px solid #c7d2fe; margin-top: 0; }
.auth-link { display: block; text-align: center; margin-top: 14px; font-size: .85rem; color: #4f46e5; text-decoration: none; }
.auth-alert { border-radius: 10px; padding: 10px 12px; font-size: .85rem; margin-bottom: 12px; }
.auth-alert.error { background: #fee2e2; color: #991b1b; } .auth-alert.ok { background: #dcfce7; color: #166534; } .auth-alert.warn { background: #fef3c7; color: #92400e; }
.auth-demo { margin-top: 18px; font-size: .8rem; color: #475569; background: #f1f5f9; border: 1px dashed #cbd5e1; border-radius: 10px; padding: 10px 12px; line-height: 1.55; }
.auth-demo .big { font-size: 1.1rem; font-weight: 700; letter-spacing: .15em; color: #4f46e5; }
.auth-divider { text-align: center; margin: 18px 0; color: #94a3b8; font-size: .8rem; position: relative; }
.auth-divider::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; border-top: 1px solid #e2e8f0; }
.auth-divider span { background: #fff; padding: 0 10px; position: relative; }
@media (max-width: 900px) { .auth-shell { grid-template-columns: minmax(0, 1fr); } .auth-side { display: none; } }
.secret-box { font-family: "Cascadia Code", Consolas, monospace; background: var(--soft); border: 1px dashed var(--card-border); border-radius: 10px; padding: 12px; word-break: break-all; }

/* ── AI & analytics (phase 10) ───────────────────────────────────────────── */
.ai-mode { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 12px; border: 1px dashed var(--card-border); background: var(--soft); font-size: .82rem; color: var(--muted); }
.ai-mode b { color: var(--ink); }
.ai-mode .dot { width: 9px; height: 9px; border-radius: 50%; background: #f59e0b; flex: none; }
.ai-mode .dot.on { background: #10b981; box-shadow: 0 0 0 4px rgba(16,185,129,.15); }
.insight { display: flex; flex-direction: column; gap: 6px; border-left: 4px solid #6366f1; }
.insight.High { border-left-color: #ef4444; } .insight.Medium { border-left-color: #f59e0b; } .insight.Info { border-left-color: #0ea5e9; }
.insight .area { font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; display: flex; justify-content: space-between; }
.insight .ttl { font-weight: 700; color: var(--ink); font-size: .95rem; }
.insight .body { color: var(--muted); font-size: .84rem; line-height: 1.5; }
.insight .metric { font-weight: 800; color: var(--ink); }
.sev { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: .7rem; font-weight: 700; }
.sev.High, .sev.Critical { background: rgba(239,68,68,.12); color: #dc2626; }
.sev.Medium, .sev.Elevated { background: rgba(245,158,11,.14); color: #b45309; }
.sev.Low, .sev.Info { background: rgba(14,165,233,.12); color: #0369a1; }
.sev.Escalated { background: rgba(168,85,247,.14); color: #7e22ce; }
.sev.Dismissed, .sev.Resolved { background: var(--soft); color: var(--muted); }
.sev.Open { background: rgba(245,158,11,.14); color: #b45309; }
.driver-chip { display: inline-block; margin: 1px 4px 1px 0; padding: 1px 7px; border-radius: 6px; background: var(--soft); border: 1px solid var(--card-border); font-size: .7rem; color: var(--ink); }
.prob { display: grid; grid-template-columns: 1fr 44px; gap: 8px; align-items: center; }
.prob .track { height: 8px; background: var(--soft); border-radius: 999px; overflow: hidden; }
.prob .fill { height: 100%; border-radius: 999px; }
.finding { border: 1px solid var(--card-border); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; background: var(--card); }
.finding .head { display: flex; gap: 10px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.finding .ttl { font-weight: 700; color: var(--ink); font-size: .9rem; }
.finding ul { margin: 8px 0 0 18px; padding: 0; color: var(--muted); font-size: .82rem; line-height: 1.55; }
.finding .review { margin-top: 8px; font-size: .78rem; color: var(--muted); }
.wf-row { display: grid; grid-template-columns: 220px 1fr 120px; gap: 12px; align-items: center; padding: 7px 0; border-bottom: 1px solid var(--card-border); font-size: .84rem; }
.wf-row:last-child { border-bottom: none; }
.wf-row.total { font-weight: 700; }
.wf-track { position: relative; height: 16px; }
.wf-bar { position: absolute; top: 0; height: 16px; border-radius: 4px; }
.wf-bar.up { background: #ef4444; } .wf-bar.down { background: #10b981; } .wf-bar.tot { background: #6366f1; }
.chat { display: flex; flex-direction: column; gap: 14px; }
.msg { max-width: 920px; padding: 12px 16px; border-radius: 14px; font-size: .9rem; line-height: 1.55; }
.msg.user { align-self: flex-end; background: linear-gradient(135deg, #4f46e5, #7c3aed); color: #fff; border-bottom-right-radius: 4px; }
.msg.bot { align-self: flex-start; background: var(--card); border: 1px solid var(--card-border); color: var(--ink); border-bottom-left-radius: 4px; }
.msg .meta { margin-top: 8px; font-size: .72rem; color: var(--muted); }
.suggest { display: flex; flex-wrap: wrap; gap: 8px; }
.suggest button { border: 1px solid var(--card-border); background: var(--card); color: var(--ink); border-radius: 999px; padding: 6px 12px; font-size: .8rem; cursor: pointer; }
.suggest button:hover { border-color: #6366f1; color: #4f46e5; }
.md p { margin: 0 0 8px; } .md p:last-child { margin-bottom: 0; }
.md ul, .md ol { margin: 4px 0 8px 20px; padding: 0; }
.md h1, .md h2, .md h3 { font-size: .95rem; margin: 12px 0 6px; color: var(--ink); }
.md table { border-collapse: collapse; margin: 8px 0; font-size: .82rem; }
.md th, .md td { border: 1px solid var(--card-border); padding: 4px 10px; }
.md th { background: var(--soft); text-align: left; }
.md code { background: var(--soft); padding: 1px 5px; border-radius: 4px; font-size: .8rem; }
.chat-input { flex: 1; height: 48px; border-radius: 12px; border: 1px solid var(--card-border); background: var(--card); color: var(--ink); padding: 0 14px; font: inherit; font-size: .9rem; outline: none; }
.chat-input:focus { border-color: #6366f1; box-shadow: 0 0 0 3px rgba(99,102,241,.15); }
@media (max-width: 700px) { .wf-row { grid-template-columns: 1fr 90px; } .wf-track { display: none; } }

/* Demo quick sign-in */
.demo-group { margin: 18px 0 8px; font-size: .7rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #64748b; }
.demo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; }
.demo-grid form { margin: 0; }
.demo-user { width: 100%; display: flex; align-items: center; gap: 12px; padding: 10px 12px; border: 1px solid #e8eaf0; border-radius: 12px; background: #fff; cursor: pointer; text-align: left; font: inherit; transition: border-color .15s, box-shadow .15s, transform .15s; }
.demo-user:hover, .demo-user:focus-visible { border-color: #6366f1; box-shadow: 0 6px 18px rgba(79,70,229,.15); transform: translateY(-1px); outline: none; }
.demo-user .avatar { width: 38px; height: 38px; flex: none; border-radius: 10px; color: #fff; font-weight: 700; font-size: .85rem; display: grid; place-items: center; }
.demo-user .who { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.demo-user .who b { color: #0f172a; font-size: .86rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.demo-user .who > span { color: #64748b; font-size: .75rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.demo-user .tags { display: flex; gap: 6px; align-items: center; margin-top: 3px; flex-wrap: wrap; }
.demo-user .tag { font-size: .62rem; font-weight: 700; padding: 1px 6px; border-radius: 999px; background: #f1f5f9; color: #475569; }
.demo-user .tag.mfa { background: rgba(99,102,241,.12); color: #4f46e5; }
.demo-user .go { color: #94a3b8; font-weight: 700; }
.demo-user:hover .go { color: #4f46e5; }
.demo-pw { margin-top: 20px; border-top: 1px solid #e8eaf0; padding-top: 14px; }
.demo-pw summary { cursor: pointer; font-size: .82rem; font-weight: 600; color: #4f46e5; margin-bottom: 8px; }
@media (max-width: 900px) { .auth-shell { grid-template-columns: minmax(0, 1fr) !important; } }
