:root {
    --sidebar: #0f2428;
    --sidebar-text: #d5e2e4;
    --sidebar-dim: #8aa0a4;
    --active: #1a6b72;
    --bg: #f3f1ea;
    --card: #fffdf8;
    --text: #0f2428;
    --muted: #5f6f72;
    --line: #e4e0d6;
    --green: #16a34a;
    --amber: #d97706;
    --red: #ef4444;
    --gray: #94a3b8;
    --blue: #1a6b72;
    --shadow: 0 12px 32px rgba(15, 36, 40, 0.07);
    --radius: 18px;
    --side: 272px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
    font-family: "DM Sans", "Segoe UI", sans-serif;
    color: var(--text);
    background:
        radial-gradient(900px 420px at 100% -10%, rgba(26, 107, 114, 0.10), transparent 55%),
        radial-gradient(700px 360px at 0% 0%, rgba(217, 119, 6, 0.08), transparent 50%),
        var(--bg);
    -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font-family: inherit; }
a { color: var(--blue); text-decoration: none; }
h1, h2, h3, p { margin: 0; }

.app { min-height: 100vh; }
.sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: var(--side);
    background:
        radial-gradient(420px 220px at 20% 0%, rgba(26, 107, 114, 0.35), transparent 70%),
        linear-gradient(180deg, #16353a 0%, var(--sidebar) 28%);
    color: var(--sidebar-text);
    box-shadow: 8px 0 30px rgba(15, 36, 40, 0.10);
    display: flex;
    flex-direction: column;
    padding: 28px 18px 18px;
    z-index: 20;
    overflow: hidden;
}
.brand-mark {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: linear-gradient(145deg, #2a8f97, var(--active));
    color: #fff;
    box-shadow: 0 8px 18px rgba(26, 107, 114, 0.35);
    display: grid;
    place-items: center;
    font-weight: 800;
    letter-spacing: -0.04em;
    margin-bottom: 16px;
}
.brand-kicker {
    color: #7ec4c9;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}
.brand-title {
    margin-top: 12px;
    font-size: 1.375rem;
    line-height: 1.25;
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.02em;
}
.brand-sub {
    margin-top: 8px;
    color: var(--sidebar-dim);
    font-size: 13px;
    line-height: 1.4;
    letter-spacing: 0.01em;
}
.side-nav { margin-top: 22px; display: flex; flex-direction: column; gap: 4px; flex: 1; min-height: 0; overflow: auto; }
.side-nav a {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--sidebar-text);
    border-radius: 12px;
    padding: 11px 12px;
    font-size: 14.5px;
    font-weight: 600;
}
.side-nav a .num {
    width: 22px;
    color: #8aa0a4;
    font-size: 12px;
    font-weight: 700;
}
.side-nav a.active {
    background: linear-gradient(90deg, #218088, var(--active));
    color: #fff;
    box-shadow: 0 8px 18px rgba(26, 107, 114, 0.35);
}
.side-nav a.active .num { color: #d7ecee; }
.side-nav a:hover:not(.active) { background: rgba(255,255,255,0.04); }
.side-foot {
    margin-top: auto;
    padding: 14px 8px 4px;
    color: #8aa0a4;
    font-size: 12px;
    line-height: 1.45;
}
.side-foot a { color: #9fd4d8; display: inline-block; margin: 8px 10px 0 0; }

.main { margin-left: var(--side); min-height: 100vh; }
.topbar {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 26px 32px 0;
}
.topbar-title { min-width: 0; }
.who {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #fff;
    margin-bottom: 10px;
}
.who strong { display: block; font-size: 14px; }
.who small { display: block; color: #8aa0a4; font-size: 12px; }
.account { margin-left: 10px; position: relative; }

.gashan-theme {
    margin-left: auto;
    position: relative;
    width: 72px;
    height: 34px;
    border: 0;
    border-radius: 999px;
    background: #121820;
    box-shadow:
        inset 0 0 0 1px rgba(255,255,255,0.05),
        inset 0 2px 6px rgba(0,0,0,0.5);
    cursor: pointer;
    overflow: visible;
    flex: 0 0 auto;
    padding: 0;
}
.gashan-theme .sun,
.gashan-theme .moon,
.gashan-theme .hole {
    position: absolute;
    pointer-events: none;
    border-radius: 50%;
}
.gashan-theme .walker { display: none !important; }
.gashan-theme .moon {
    left: 5px;
    top: 4px;
    width: 26px;
    height: 26px;
    background: transparent;
    box-shadow:
        inset -7px -2px 0 0 #7ad7ff,
        0 0 8px rgba(122,215,255,0.55),
        0 0 18px rgba(122,215,255,0.4);
    filter: drop-shadow(0 0 5px rgba(122,215,255,0.95));
    opacity: 1;
    transition: opacity 0.25s ease, transform 0.35s ease;
}
.gashan-theme .moon svg { display: none; }
.gashan-theme .sun {
    left: 5px;
    top: 4px;
    width: 26px;
    height: 26px;
    background: #fff;
    display: grid;
    place-items: center;
    color: #f0b429;
    box-shadow: 0 0 12px rgba(255,200,80,0.55);
    opacity: 0;
    transform: scale(0.7);
    transition: opacity 0.25s ease, transform 0.35s ease;
}
.gashan-theme .sun svg { width: 16px; height: 16px; display: block; }
.gashan-theme .hole {
    right: 5px;
    top: 5px;
    width: 24px;
    height: 24px;
    background: #0a0e14;
    box-shadow:
        inset 0 2px 5px rgba(0,0,0,0.75),
        inset 0 0 0 1px rgba(255,255,255,0.04);
}
html:not([data-theme="dark"]) .gashan-theme {
    background: #e8eef4;
    box-shadow: inset 0 0 0 1px rgba(13,46,53,0.08);
}
html:not([data-theme="dark"]) .gashan-theme .moon { opacity: 0; transform: scale(0.7); }
html:not([data-theme="dark"]) .gashan-theme .sun { opacity: 1; transform: scale(1); }
html:not([data-theme="dark"]) .gashan-theme .hole {
    background: #cfd8e2;
    box-shadow: inset 0 2px 4px rgba(80,100,120,0.3);
}
@media (max-width: 860px) {
    .gashan-theme { width: 48px; height: 26px; }
    .gashan-theme .moon,
    .gashan-theme .sun {
        top: 4px;
        left: 4px;
        width: 18px;
        height: 18px;
    }
    .gashan-theme .moon {
        box-shadow:
            inset -5px -1px 0 0 #7ad7ff,
            0 0 6px rgba(122,215,255,0.55);
    }
    .gashan-theme .sun svg { width: 12px; height: 12px; }
    .gashan-theme .hole {
        top: 4px;
        right: 4px;
        width: 18px;
        height: 18px;
    }
}

html[data-theme="dark"] {
    --bg: #0b1418; --card: #122026; --text: #e7eef0; --muted: #9bb0b5;
    --line: #2a3d43; --blue: #3d9aa3; --shadow: 0 12px 32px rgba(0,0,0,0.35);
}
html[data-theme="dark"] body {
    background:
        radial-gradient(900px 420px at 100% -10%, rgba(26,107,114,0.18), transparent 55%),
        radial-gradient(700px 360px at 0% 0%, rgba(125,211,252,0.06), transparent 50%),
        var(--bg);
    color: var(--text);
}
html[data-theme="dark"] a { color: #5ec4cd; }
html[data-theme="dark"] .topbar h1,
html[data-theme="dark"] .section-title,
html[data-theme="dark"] .lede,
html[data-theme="dark"] .strong,
html[data-theme="dark"] h1, html[data-theme="dark"] h2, html[data-theme="dark"] h3,
html[data-theme="dark"] label, html[data-theme="dark"] .lbl { color: var(--text); }
html[data-theme="dark"] .muted,
html[data-theme="dark"] .stat span,
html[data-theme="dark"] .stat small { color: var(--muted); }
html[data-theme="dark"] .card, html[data-theme="dark"] .presence,
html[data-theme="dark"] .account-btn, html[data-theme="dark"] .account-menu,
html[data-theme="dark"] .avatar-pop, html[data-theme="dark"] .menu-btn,
html[data-theme="dark"] .btn.secondary, html[data-theme="dark"] .btn.danger {
    background: var(--card); border-color: var(--line); color: var(--text);
}
html[data-theme="dark"] .account-menu a { color: var(--text); }
html[data-theme="dark"] .account-menu a:hover { background: #1a2c32; }
html[data-theme="dark"] .account-menu a.sign-out { color: #f87171; }
html[data-theme="dark"] input, html[data-theme="dark"] select, html[data-theme="dark"] textarea {
    background: #0f1a1e; color: var(--text); border-color: var(--line);
}
html[data-theme="dark"] table { color: var(--text); }
html[data-theme="dark"] table th, html[data-theme="dark"] table td { border-color: var(--line); }
html[data-theme="dark"] table th { color: var(--muted); }
html[data-theme="dark"] tbody tr:hover td { background: #183038; }
html[data-theme="dark"] .flash-ok, html[data-theme="dark"] .flash:not(.flash-bad) { background: #0f2a1c; color: #86efac; }
html[data-theme="dark"] .flash-bad { background: #2a1212; color: #fca5a5; }
html[data-theme="dark"] .pill.good { background: #0f2a1c; color: #86efac; }
html[data-theme="dark"] .pill.warn { background: #2a1c0c; color: #fdba74; }
html[data-theme="dark"] .pill.bad { background: #2a1212; color: #fca5a5; }
html[data-theme="dark"] .pill.draft { background: #1e1b4b; color: #a5b4fc; }
html[data-theme="dark"] .pill.neutral { background: #1d3036; color: #c5d6da; }
html[data-theme="dark"] .hbar-track, html[data-theme="dark"] .bar { background: #1a2c32; }
html[data-theme="dark"] .vcol-track { background: linear-gradient(180deg, #1a2c32, #122026); }
html[data-theme="dark"] .btn.secondary:hover { background: #1a2c32; }
html[data-theme="dark"] .step,
html[data-theme="dark"] .choice,
html[data-theme="dark"] .choice.selected,
html[data-theme="dark"] .cal .day,
html[data-theme="dark"] .cal .today,
html[data-theme="dark"] .faq details,
html[data-theme="dark"] .report,
html[data-theme="dark"] .ring span.ring-in,
html[data-theme="dark"] .guide-shot,
html[data-theme="dark"] .guide-shot figcaption,
html[data-theme="dark"] .disclaimer {
    background: var(--card);
    color: var(--text);
    border-color: var(--line);
}
html[data-theme="dark"] .choice small,
html[data-theme="dark"] .cal .day span,
html[data-theme="dark"] .faq details p,
html[data-theme="dark"] .guide-shot figcaption,
html[data-theme="dark"] .disclaimer,
html[data-theme="dark"] .report .muted {
    color: var(--muted);
}
html[data-theme="dark"] .presence-time { color: #8ee4ea; }
html[data-theme="dark"] .side-nav a { color: var(--sidebar-text); }
html[data-theme="dark"] .side-nav a.active,
html[data-theme="dark"] a.btn,
html[data-theme="dark"] .who,
html[data-theme="dark"] .who strong { color: #fff; }
html[data-theme="dark"] .who small { color: #8aa0a4; }
html[data-theme="dark"] a.btn.secondary { color: var(--text); }
html[data-theme="dark"] a.btn.danger,
html[data-theme="dark"] .btn.danger { color: #fca5a5; }
html[data-theme="dark"] a.btn.ghost { color: #5ec4cd; }
html[data-theme="dark"] .guide-toc a:hover { background: #1a2c32; }


.presence {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 14px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 8px 14px;
    box-shadow: var(--shadow);
}
.presence + .account { margin-left: 0; }
.presence strong { display: block; font-size: 14px; line-height: 1.2; }
.presence small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; }
.presence-time { font-size: 13px; font-weight: 750; color: #1a6b72; white-space: nowrap; }
.account-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 4px 12px 4px 4px;
    cursor: pointer;
    font-weight: 700;
    color: var(--text);
}
.account-name { font-size: 14px; }
.avatar[hidden] { display: none !important; }
.avatar, .avatar.fallback {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    display: inline-grid;
    place-items: center;
    background: var(--blue);
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    flex: 0 0 auto;
}
.avatar.sm { width: 32px; height: 32px; font-size: 11px; }
.avatar.lg { width: 96px; height: 96px; font-size: 32px; }
.account-menu {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    width: 260px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: var(--shadow);
    padding: 8px;
    z-index: 30;
}
.account-meta {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 8px 10px 12px;
    border-bottom: 1px solid var(--line);
    margin-bottom: 6px;
}
.account-meta strong, .account-meta small { display: block; }
.account-meta small { color: var(--muted); font-weight: 600; word-break: break-all; }
.account-menu a {
    display: block;
    padding: 10px 12px;
    border-radius: 10px;
    color: var(--text);
    font-weight: 700;
}
.account-menu a:hover { background: #f3f1ea; }
.account-menu a.sign-out { color: #b91c1c; }
.profile-card { text-align: center; }
.avatar-wrap { position: relative; display: inline-grid; margin-bottom: 12px; }
.avatar-hit {
    border: 0;
    padding: 0;
    background: transparent;
    cursor: pointer;
    border-radius: 50%;
    line-height: 0;
}
.avatar-pop {
    position: absolute;
    left: 50%;
    top: calc(100% + 8px);
    transform: translateX(-50%);
    width: 190px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 14px;
    box-shadow: var(--shadow);
    padding: 6px;
    z-index: 8;
    text-align: left;
}
.avatar-pop button,
.avatar-pop label {
    display: block;
    width: 100%;
    margin: 0;
    border: 0;
    background: transparent;
    color: var(--text);
    text-align: left;
    border-radius: 10px;
    padding: 10px 12px;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
}
.avatar-pop button:hover,
.avatar-pop label:hover { background: #f3f1ea; }
.avatar-wrap:has(.avatar-pop:not([hidden])) { margin-bottom: 96px; }
.sr-file {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}
.photo-view {
    position: fixed;
    inset: 0;
    z-index: 40;
    background: rgba(15, 36, 40, 0.72);
    display: grid;
    place-items: center;
    padding: 24px;
}
.photo-view[hidden] { display: none !important; }
.photo-view img,
.avatar.xl {
    width: min(320px, 78vw);
    height: min(320px, 78vw);
    border-radius: 50%;
    object-fit: cover;
    font-size: 72px;
}
.photo-view-close {
    position: absolute;
    top: 18px;
    right: 18px;
    border: 0;
    background: #fff;
    border-radius: 999px;
    padding: 8px 14px;
    font-weight: 700;
    cursor: pointer;
}
.profile-photo { display: grid; place-items: center; margin-bottom: 12px; }
.photo-picker {
    position: relative;
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 18px 0 20px;
}
.photo-frame {
    width: 84px;
    height: 84px;
    border-radius: 50%;
    background: var(--blue);
    color: #fff;
    display: grid;
    place-items: center;
    overflow: hidden;
    flex: 0 0 84px;
    font-size: 26px;
    font-weight: 800;
    letter-spacing: -0.04em;
}
.photo-frame img {
    width: 84px;
    height: 84px;
    object-fit: cover;
    display: block;
}
.photo-frame [hidden] { display: none !important; }
.photo-actions { min-width: 0; }
.photo-actions .btn { margin-bottom: 6px; }
.photo-actions input[type="file"] {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}
.photo-actions .check {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
    font-size: 13px;
    font-weight: 650;
}
.form-note {
    margin: 8px 0 14px;
    font-size: 16px;
    letter-spacing: -0.02em;
}
.eyebrow {
    color: #1a6b72;
    font-size: 11px;
    font-weight: 750;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}
.topbar h1 {
    margin-top: 6px;
    font-size: 1.5rem;
    letter-spacing: -0.02em;
    font-weight: 700;
    line-height: 1.25;
    color: var(--text);
}
.menu-btn {
    display: none;
    border: 1px solid var(--line);
    background: #fff;
    border-radius: 10px;
    padding: 8px 12px;
    font-weight: 700;
}
.content { padding: 22px 32px 48px; }

.flash {
    background: #ecfdf3;
    color: #166534;
    border-radius: 12px;
    padding: 12px 14px;
    margin-bottom: 16px;
}
.flash-ok { background: #ecfdf3; color: #166534; }
.flash-bad { background: #fef2f2; color: #991b1b; }

.grid { display: grid; gap: 16px; }
.stats { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.stats-5 { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.stats-3 { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.split { grid-template-columns: 320px 1fr; align-items: start; }
.two { grid-template-columns: 1fr 1fr; }

.card {
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 22px;
    border: 1px solid var(--line);
}
.stat { position: relative; min-height: 108px; }
.stat .dot {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
}
.dot.red { background: var(--red); }
.dot.green { background: var(--green); }
.dot.amber { background: var(--amber); }
.dot.gray { background: var(--gray); }
.dot.blue { background: var(--blue); }
.stat b {
    display: block;
    font-size: 34px;
    letter-spacing: -0.04em;
    line-height: 1;
    margin-top: 2px;
}
.stat span, .muted { color: var(--muted); font-size: 13px; }
.stat small { display: block; margin-top: 8px; color: var(--muted); font-size: 12px; }

.charts { grid-template-columns: 1fr 1.35fr; }
.chart-card h2 { font-size: 17px; letter-spacing: -0.03em; margin-bottom: 6px; }
.chart-card .muted { margin-bottom: 14px; }
.donut-wrap { display: flex; align-items: center; gap: 22px; }
.donut {
    width: 168px;
    height: 168px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    flex: none;
}
.donut > span {
    width: 108px;
    height: 108px;
    border-radius: 50%;
    background: #fff;
    display: grid;
    place-items: center;
    text-align: center;
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.04em;
    line-height: 1;
}
.donut small { display: block; margin-top: 4px; font-size: 11px; font-weight: 650; color: var(--muted); letter-spacing: 0; }
.legend { list-style: none; margin: 0; padding: 0; width: 100%; }
.legend li { display: flex; align-items: center; gap: 8px; margin: 8px 0; font-size: 14px; font-weight: 650; }
.legend i { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.legend b { margin-left: auto; }
.hbar { margin: 0 0 12px; }
.hbar:last-child { margin-bottom: 0; }
.hbar-top { display: flex; justify-content: space-between; gap: 12px; font-size: 13px; font-weight: 650; margin-bottom: 6px; }
.hbar-track { height: 10px; background: #eef1f6; border-radius: 99px; overflow: hidden; }
.hbar-track > span { display: block; height: 100%; border-radius: 99px; min-width: 0; }
.hbar-track > span.good { background: var(--green); }
.hbar-track > span.warn { background: var(--amber); }
.hbar-track > span.bad { background: var(--red); }
.hbar-track > span.neutral { background: var(--gray); }
.vchart { display: flex; align-items: flex-end; gap: 14px; height: 210px; padding-top: 8px; }
.vcol { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; height: 100%; }
.vcol b { font-size: 13px; margin-bottom: 6px; }
.vcol-track { flex: 1; width: 100%; max-width: 46px; background: linear-gradient(180deg, #f3f1ea, #e7ebf4); border-radius: 14px; display: flex; flex-direction: column; overflow: hidden; }
.vcol-track > i { display: block; min-height: 0; }
.vcol-track > span { display: block; width: 100%; min-height: 0; border-radius: 8px 8px 0 0; background: var(--blue); }
.vcol > span { margin-top: 8px; font-size: 11px; color: var(--muted); font-weight: 650; text-align: center; line-height: 1.25; }

.section-title {
    margin: 26px 0 12px;
    font-size: 1.125rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.3;
    color: var(--text);
}
.lede {
    color: var(--muted);
    max-width: 720px;
    line-height: 1.55;
    margin-bottom: 18px;
    font-size: 0.98rem;
    letter-spacing: -0.01em;
}

.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th {
    text-align: left;
    font-size: 11px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #8b93a7;
    font-weight: 700;
    padding: 8px 10px 12px;
}
tbody tr:hover td { background: #f8faff; }
td { padding: 14px 10px; border-top: 1px solid var(--line); vertical-align: top; font-size: 14px; }
td.strong { font-weight: 700; }

.pill {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 700;
    background: #f3f4f6;
    color: #374151;
    white-space: nowrap;
}
.pill.good { background: #ecfdf3; color: #15803d; }
.pill.warn { background: #fff7ed; color: #c2410c; }
.pill.bad { background: #fef2f2; color: #b91c1c; }
.pill.mid { background: #fefce8; color: #a16207; }
.pill.draft { background: #eef2ff; color: #4338ca; }
.pill.neutral { background: #f1f5f9; color: #475569; }
.pill.sev-high { background: #fef2f2; color: #b91c1c; }
.pill.sev-medium { background: #fff7ed; color: #c2410c; }
.pill.sev-low { background: #f1f5f9; color: #475569; }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: linear-gradient(180deg, #5472ff, var(--blue));
    color: #fff;
    border: 0;
    border-radius: 12px;
    padding: 12px 16px;
    font-weight: 700;
    cursor: pointer;
    font-size: 14px;
    box-shadow: 0 8px 18px rgba(26, 107, 114, 0.28);
}
.btn:hover { filter: brightness(1.05); }
.btn.secondary { background: #fff; color: var(--text); border: 1px solid var(--line); box-shadow: none; }
.btn.small { padding: 6px 10px; font-size: 12px; border-radius: 9px; box-shadow: none; }
.btn.danger { background: #fff; color: #b91c1c; border: 1px solid #fecaca; box-shadow: none; }
.btn.ghost { background: transparent; color: var(--blue); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }

.hero-card h2 { font-size: 22px; letter-spacing: -0.03em; margin-bottom: 8px; }
.steps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; margin-top: 18px; }
.step {
    background: #f8f9fc;
    border-radius: 14px;
    padding: 14px;
    min-height: 112px;
}
.step b { display: block; font-size: 13px; margin-bottom: 6px; }
.step span { color: var(--muted); font-size: 13px; line-height: 1.4; }

label.lbl { display: block; font-size: 13px; font-weight: 700; margin-bottom: 6px; }
input[type="text"], input[type="email"], input[type="url"], input[type="password"], input[type="tel"], input[type="date"], input[type="number"], select, textarea {
    width: 100%;
    border: 1px solid #e1e5ee;
    background: #fff;
    border-radius: 12px;
    padding: 12px 12px;
    font-size: 14px;
    color: var(--text);
    outline: none;
}
textarea { min-height: 120px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: #b9c4ff; box-shadow: 0 0 0 4px rgba(61,91,253,0.12); }
.secret { position: relative; }
.secret input { padding-right: 68px; }
.secret-toggle {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    border: 0;
    background: transparent;
    color: var(--blue);
    font-weight: 750;
    font-size: 12px;
    cursor: pointer;
    padding: 6px 8px;
}
.field { margin-bottom: 14px; }
.field-error { color: var(--red); font-size: 12px; margin: 6px 0 0; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }

.choice {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 14px;
    margin-bottom: 10px;
    cursor: pointer;
    background: #fff;
}
.choice input { margin-top: 3px; accent-color: var(--blue); }
.choice strong { display: block; }
.choice small { color: var(--muted); }
.choice.selected { border-color: #c9d2ff; background: #f5f7ff; }
.q-kicker { color: var(--muted); font-size: 13px; font-weight: 700; margin-bottom: 8px; }
.q-text { font-size: 22px; letter-spacing: -0.03em; line-height: 1.35; margin-bottom: 18px; }
.progress {
    height: 8px;
    background: #e8ebf3;
    border-radius: 99px;
    overflow: hidden;
    margin: 8px 0 18px;
}
.progress > span { display: block; height: 100%; background: var(--blue); width: 0; }
.save-state { color: var(--muted); font-size: 12px; min-height: 18px; }

.bar { height: 8px; background: #eef1f6; border-radius: 99px; overflow: hidden; margin-top: 8px; }
.bar > span { display: block; height: 100%; border-radius: 99px; }
.bar.good > span { background: var(--green); }
.bar.warn > span, .bar.mid > span { background: var(--amber); }
.bar.bad > span { background: var(--red); }

.ring {
    width: 148px;
    height: 148px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    margin: 8px auto 4px;
    background: conic-gradient(var(--ring, var(--blue)) calc(var(--p) * 1%), #e8ebf3 0);
}
.domain-nav a {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    padding: 10px 8px;
    border-top: 1px solid var(--line);
    color: var(--text);
    font-weight: 650;
    font-size: 14px;
}
.domain-nav a.active { color: var(--blue); }
.domain-nav span { color: var(--muted); font-weight: 600; font-size: 12px; }
.login-body { background: #0c1224; }
.gate { min-height: 100vh; display: grid; grid-template-columns: minmax(280px, 1.05fr) minmax(320px, 0.95fr); }
.gate-side {
    position: relative;
    overflow: hidden;
    color: #e8ecf7;
    background:
        radial-gradient(900px 480px at 20% 10%, rgba(26, 107, 114, 0.45), transparent 60%),
        radial-gradient(700px 420px at 80% 90%, rgba(22, 163, 74, 0.16), transparent 55%),
        #0c1224;
    padding: 56px 48px;
    display: flex;
    align-items: flex-end;
}
.gate-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
    background-size: 42px 42px;
    mask-image: linear-gradient(180deg, rgba(0,0,0,0.9), transparent 92%);
}
.gate-glow {
    position: absolute;
    width: 280px;
    height: 280px;
    right: -60px;
    top: 12%;
    border-radius: 50%;
    border: 1px solid rgba(125, 149, 255, 0.35);
    box-shadow: 0 0 0 40px rgba(26, 107, 114, 0.05), 0 0 80px rgba(26, 107, 114, 0.25);
}
.gate-glow:before, .gate-glow:after {
    content: "";
    position: absolute;
    inset: 28px;
    border-radius: 50%;
    border: 1px solid rgba(125, 149, 255, 0.25);
}
.gate-glow:after { inset: 64px; }
.gate-copy { position: relative; z-index: 1; max-width: 460px; }
.gate-kicker {
    margin: 18px 0 8px;
    color: #9eb0ff;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}
.gate-kicker.dark { color: var(--blue); margin-top: 0; }
.gate-side h1 {
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: #fff;
    line-height: 1.2;
}
.gate-side p { margin-top: 14px; color: #c5d5d7; line-height: 1.55; font-size: 16px; }
.gate-side ul { margin: 22px 0 0; padding: 0; list-style: none; }
.gate-side li { position: relative; padding: 8px 0 8px 22px; color: #d5e2e4; font-weight: 650; }
.gate-side li:before { content: ""; position: absolute; left: 0; top: 15px; width: 8px; height: 8px; border-radius: 50%; background: #1a6b72; box-shadow: 0 0 0 4px rgba(26, 107, 114, 0.2); }
.gate-main {
    display: grid;
    place-items: center;
    padding: 32px 24px;
    background:
        radial-gradient(500px 240px at 50% 0%, rgba(26, 107, 114, 0.08), transparent 70%),
        #f3f1ea;
}
.gate-form { width: min(420px, 100%); }
.gate-form h2 {
    font-size: 1.375rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.25;
    margin-bottom: 8px;
}
.gate-form .muted { margin-bottom: 18px; }
.gate-submit { width: 100%; margin-top: 6px; padding: 14px 16px; }
.gate-foot { margin-top: 16px; color: var(--muted); font-size: 12px; line-height: 1.45; }
.gate-link { display: block; margin-top: 14px; text-align: center; font-weight: 750; }
@media (max-width: 860px) {
    .gate { grid-template-columns: 1fr; }
    .gate-side { min-height: 280px; align-items: flex-end; padding: 28px 22px; }
    .gate-side h1 { font-size: 36px; }
    .gate-side ul { display: none; }
    .gate-glow { width: 160px; height: 160px; }
}
.ring inner, .ring span.ring-in {
    width: 112px;
    height: 112px;
    border-radius: 50%;
    background: #fff;
    display: grid;
    place-items: center;
    text-align: center;
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.04em;
}

.domain-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    padding: 14px 4px;
    border-top: 1px solid var(--line);
}
.domain-row:first-child { border-top: 0; }
.faq details {
    background: #fff;
    border: 1px solid #e4e0d6;
    border-radius: 16px;
    padding: 16px 18px;
    margin-bottom: 10px;
    box-shadow: var(--shadow);
}
.faq summary { cursor: pointer; font-weight: 700; }
.faq details p { margin-top: 8px; color: var(--muted); line-height: 1.5; }

.guide-intro { max-width: 760px; }
.guide-toc {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px 16px;
    list-style: none;
    margin: 16px 0 0;
    padding: 0;
}
.guide-toc a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 12px;
    text-decoration: none;
    color: inherit;
    font-weight: 650;
}
.guide-toc a:hover { background: #f3f1ea; }
.guide-toc .num {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: #e7f3f4;
    color: #1a6b72;
    display: grid;
    place-items: center;
    font-size: 12px;
    font-weight: 800;
    flex: none;
}
.guide-block { margin-top: 18px; }
.guide-kicker {
    margin: 0 0 6px;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #1a6b72;
    font-weight: 800;
}
.guide-block h2 { margin-bottom: 4px; }
.guide-points {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 16px;
}
.guide-points article {
    background: #f6f4ee;
    border-radius: 14px;
    padding: 14px 14px 16px;
}
.guide-points h3 {
    margin: 0 0 6px;
    font-size: 13px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #5c657a;
}
.guide-points p { margin: 0; color: #3c4458; font-size: 14px; line-height: 1.55; }
.guide-shot {
    margin: 18px 0 0;
    border: 1px solid #e4e0d6;
    border-radius: 16px;
    overflow: hidden;
    background: #f3f5f9;
}
.guide-shot img { display: block; width: 100%; height: auto; }
.guide-shot figcaption {
    padding: 10px 14px 12px;
    background: #fff;
    border-top: 1px solid #e4e0d6;
    color: var(--muted);
    font-size: 13px;
}
.guide-block .table-wrap { margin-top: 16px; }

.report {
    background: #fff;
    border-radius: 18px;
    padding: 36px;
    box-shadow: var(--shadow);
    max-width: 900px;
}
.report h2 { font-size: 28px; letter-spacing: -0.03em; margin: 8px 0; }
.report h3 { margin: 26px 0 8px; font-size: 18px; }
.report p, .report li { line-height: 1.5; }
.cover-rule { height: 6px; width: 72px; background: var(--blue); border-radius: 99px; margin: 18px 0; }
.disclaimer {
    margin-top: 22px;
    padding: 14px;
    background: #f8f9fc;
    border-radius: 12px;
    color: #4b5568;
    font-size: 13px;
}

.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.cal .dow { background: transparent; border: 0; min-height: 0; color: var(--muted); font-weight: 700; font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase; }
.cal .day { background: #fff; border: 1px solid var(--line); border-radius: 12px; min-height: 78px; padding: 8px; font-size: 12px; }
.cal .day strong { display: block; margin-bottom: 4px; }
.cal .day span { display: block; color: var(--muted); line-height: 1.3; }
.cal .today { outline: 2px solid var(--blue); background: #f3f6ff; }
.cal .empty { background: transparent; border-color: transparent; }

@media (max-width: 1100px) {
    .stats, .stats-5, .steps, .charts, .guide-points { grid-template-columns: 1fr; }
    .split, .two, .form-grid, .guide-toc { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
    .account-name { display: none; }
    .topbar { flex-wrap: wrap; }
    .presence { order: 3; width: 100%; margin-left: 0; justify-content: space-between; }
    .menu-btn { display: inline-flex; }
    .sidebar { transform: translateX(-105%); transition: transform 0.2s ease; }
    .sidebar.open { transform: none; }
    .main { margin-left: 0; }
    .topbar, .content { padding-left: 16px; padding-right: 16px; }
    .topbar h1 { font-size: 24px; }
    .stats, .stats-5, .steps { grid-template-columns: 1fr; }
}

@media print {
    .sidebar, .topbar, .menu-btn, .account, .no-print { display: none !important; }
    .main { margin: 0; }
    .content { padding: 0; }
    body, .report { background: #fff; box-shadow: none; }
}

.content h2 {
    font-size: 1.125rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.3;
}
html[data-theme="dark"] .eyebrow { color: #5ec4cd; }
.side-nav {
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,.2) transparent;
}
.content .lede { max-width: 70ch; }
.actions { display:flex; flex-wrap:wrap; gap:10px; align-items:center; }

/* Users page */
.users-page { display: grid; gap: 18px; }
.users-form-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
}
.users-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 16px;
}
.users-form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 4px;
}
.users-modules {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 8px;
}
.users-mod {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: rgba(13, 46, 53, 0.02);
    cursor: pointer;
    font-size: 0.92rem;
}
.users-mod:has(input:checked) {
    border-color: rgba(61, 154, 163, 0.45);
    background: rgba(61, 154, 163, 0.08);
}
.users-check {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}
.users-list-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}
.users-table td { vertical-align: middle; }
.users-table tr.is-editing {
    background: rgba(61, 154, 163, 0.08);
}
.users-person {
    display: flex;
    align-items: center;
    gap: 10px;
}
.users-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    background: #14343b;
    color: #fff;
    font-weight: 700;
    font-size: 0.9rem;
}
.users-person strong { display: block; }
.users-person small {
    display: block;
    color: var(--muted);
    font-size: 0.82rem;
}
.users-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.users-tag {
    display: inline-flex;
    padding: 3px 8px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: rgba(13, 46, 53, 0.03);
    font-size: 0.78rem;
    color: var(--muted);
}
.users-actions {
    white-space: nowrap;
    display: flex;
    gap: 6px;
    align-items: center;
    justify-content: flex-end;
}
.users-actions form { display: inline; margin: 0; }
.users-publish { margin: 0; }
html[data-theme="dark"] .users-mod {
    background: rgba(255,255,255,0.03);
}
html[data-theme="dark"] .users-mod:has(input:checked) {
    background: rgba(94, 196, 205, 0.12);
    border-color: rgba(94, 196, 205, 0.35);
}
html[data-theme="dark"] .users-tag {
    background: rgba(255,255,255,0.04);
}
html[data-theme="dark"] .users-table tr.is-editing {
    background: rgba(94, 196, 205, 0.1);
}
@media (max-width: 780px) {
    .users-form-grid { grid-template-columns: 1fr; }
    .users-actions { justify-content: flex-start; }
}

/* Blog page — writing studio */
.blog-page { display: grid; gap: 18px; }
.blog-hero {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    padding: 8px 2px 0;
}
.blog-kicker {
    margin: 0 0 6px;
    font-size: 0.78rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #1a6b72;
    font-weight: 700;
}
.blog-hero-title {
    margin: 0;
    font-size: 1.375rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.25;
}
.blog-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}
.blog-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}
.blog-stat { padding: 16px 18px; min-height: auto; }
.blog-stat b {
    display: block;
    margin-top: 6px;
    font-size: 28px;
    letter-spacing: -0.03em;
    line-height: 1;
}
.blog-stat-draft {
    border-color: rgba(67, 56, 202, 0.28);
    background: linear-gradient(180deg, rgba(238, 242, 255, 0.95), rgba(255, 255, 255, 0.98));
}
.blog-stat-draft .muted { color: #4338ca; }
.blog-stat-draft b { color: #3730a3; }
.blog-card.is-draft {
    border-color: rgba(67, 56, 202, 0.28);
    background: linear-gradient(90deg, rgba(238, 242, 255, 0.7), rgba(13, 46, 53, 0.02));
}
.blog-chip.is-draft {
    background: #eef2ff;
    color: #4338ca;
}
.blog-studio {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 16px;
    align-items: start;
}
.blog-canvas {
    padding: 22px 24px 18px;
    min-height: 640px;
    display: flex;
    flex-direction: column;
    background:
        linear-gradient(180deg, rgba(255,255,255,0.92), rgba(255,255,255,0.98)),
        radial-gradient(700px 280px at 0% 0%, rgba(26,107,114,0.08), transparent 60%);
}
.blog-canvas-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
}
.blog-chip {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(26,107,114,0.1);
    color: #14555b;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}
.blog-title-input {
    width: 100%;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    padding: 6px 0 14px !important;
    margin: 0 0 8px;
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    line-height: 1.35;
    color: var(--text);
}
.blog-title-input:focus { outline: none; }
.blog-title-input::placeholder { color: #9bb0b5; }
.blog-body-input {
    width: 100%;
    flex: 1 1 auto;
    min-height: 420px;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    resize: vertical;
    padding: 8px 0 16px !important;
    margin: 0;
    font-family: "DM Sans", sans-serif;
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--text);
}
.blog-body-input:focus { outline: none; }
.blog-body-input::placeholder { color: #9bb0b5; }
.blog-canvas-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-top: 14px;
    border-top: 1px solid var(--line);
    margin-top: auto;
}
.blog-meta {
    display: grid;
    gap: 12px;
    position: sticky;
    top: 16px;
}
.blog-meta-card { padding: 16px; }
.blog-panel-title {
    margin: 0 0 12px;
    font-size: 0.78rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--muted);
}
.blog-cover-preview {
    width: 100%;
    max-height: 160px;
    object-fit: cover;
    border-radius: 12px;
    display: block;
    border: 1px solid var(--line);
}
.blog-cover-empty {
    height: 110px;
    border-radius: 12px;
    border: 1px dashed var(--line);
    display: grid;
    place-items: center;
    color: var(--muted);
    font-size: 0.88rem;
    background: rgba(13,46,53,0.02);
}
.blog-author-preview {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--line);
    display: block;
}
.blog-form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.blog-sticky-save { position: sticky; bottom: 12px; }
.blog-list-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}
.blog-cards { display: grid; gap: 10px; }
.blog-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px 16px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: rgba(13,46,53,0.02);
}
.blog-card.is-editing {
    border-color: rgba(61,154,163,0.45);
    background: rgba(61,154,163,0.08);
}
.blog-card-main h3 {
    margin: 6px 0 4px;
    font-size: 1.02rem;
    line-height: 1.3;
}
.blog-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}
.blog-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
    justify-content: flex-end;
}
.blog-actions form { display: inline; margin: 0; }
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
}
html[data-theme="dark"] .blog-kicker { color: #5ec4cd; }
html[data-theme="dark"] .blog-chip {
    background: rgba(94,196,205,0.16);
    color: #9fe0e6;
}
html[data-theme="dark"] .blog-chip.is-draft {
    background: rgba(165, 180, 252, 0.18);
    color: #c7d2fe;
}
html[data-theme="dark"] .blog-stat-draft {
    border-color: rgba(165, 180, 252, 0.35);
    background: linear-gradient(180deg, rgba(30, 27, 75, 0.85), rgba(18, 32, 38, 0.98));
}
html[data-theme="dark"] .blog-stat-draft .muted { color: #a5b4fc; }
html[data-theme="dark"] .blog-stat-draft b { color: #c7d2fe; }
html[data-theme="dark"] .blog-canvas {
    background:
        linear-gradient(180deg, rgba(18,32,38,0.96), rgba(18,32,38,0.98)),
        radial-gradient(700px 280px at 0% 0%, rgba(94,196,205,0.1), transparent 60%);
}
html[data-theme="dark"] .blog-cover-empty,
html[data-theme="dark"] .blog-card {
    background: rgba(255,255,255,0.03);
}
html[data-theme="dark"] .blog-card.is-draft {
    border-color: rgba(165, 180, 252, 0.3);
    background: linear-gradient(90deg, rgba(30, 27, 75, 0.55), rgba(255, 255, 255, 0.03));
}
html[data-theme="dark"] .blog-card.is-editing {
    background: rgba(94,196,205,0.1);
}
@media (max-width: 980px) {
    .blog-studio { grid-template-columns: 1fr; }
    .blog-meta { position: static; }
    .blog-hero { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 900px) {
    .blog-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
    .blog-stats { grid-template-columns: 1fr 1fr; }
    .blog-card { flex-direction: column; align-items: stretch; }
    .blog-actions { justify-content: flex-start; }
    .blog-canvas { min-height: 520px; padding: 18px; }
    .blog-body-input { min-height: 320px; }
}

/* Website member account (no staff sidebar) */
.member-body {
    min-height: 100vh;
    color: #e7eef0;
    background:
        radial-gradient(820px 360px at 100% -8%, rgba(26, 107, 114, 0.35), transparent 58%),
        radial-gradient(640px 280px at 0% 0%, rgba(201, 130, 31, 0.16), transparent 52%),
        #0d2e35;
}
.member-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 28px;
    background: #fffdf8;
    color: #0f2428;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}
.member-brand {
    font-weight: 700;
    color: #0d2e35;
    text-decoration: none;
}
.member-top-user {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 700;
    color: #0f2428;
}
.member-wrap {
    max-width: 1080px;
    margin: 0 auto;
    padding: 36px 24px 72px;
    display: grid;
    grid-template-columns: 200px minmax(0, 1fr);
    gap: 32px;
    align-items: start;
}
.member-nav {
    display: flex;
    flex-direction: column;
    gap: 6px;
    position: sticky;
    top: 20px;
    padding: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
}
.member-nav a {
    padding: 11px 14px;
    border-radius: 999px;
    color: #d5e4e6;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
}
.member-nav a:hover { background: rgba(255, 255, 255, 0.08); color: #fff; }
.member-nav a.is-on,
.member-nav a.is-on:hover {
    background: #fffdf8;
    color: #0d2e35;
}
.member-nav a.member-out { margin-top: 10px; color: #f3b4b4; }
.member-nav a.member-out:hover { background: rgba(243, 180, 180, 0.12); color: #fff; }
.member-main { min-width: 0; }
.member-page-title {
    margin: 0 0 8px;
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    color: #fff;
}
.member-main .lede { color: #c5d5d8; max-width: 62ch; }
.member-main .card { background: #fffdf8; color: #0f2428; }
.member-main .avatar-pop { left: 0; transform: none; }
.member-main:has(.member-settings) .member-page-title { text-align: center; }
.member-settings {
    width: min(520px, 100%);
    margin-left: auto;
    margin-right: auto;
}
.member-settings .photo-field { text-align: center; }
.member-settings .photo-field .lbl { display: block; }
.member-settings .avatar-wrap:has(.avatar-pop:not([hidden])) { margin-bottom: 128px; }
.member-settings #askDelete,
.member-settings #photoDeleteAsk button[name="delete_photo"] { color: #b91c1c; }
.member-settings #photoDeleteAsk { padding: 8px 8px 4px; }
.member-settings #photoDeleteAsk p {
    margin: 0 4px 6px;
    font-size: 14px;
    font-weight: 700;
}
.member-cards {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin-top: 8px;
}
.member-card {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-height: 148px;
    padding: 22px;
    text-decoration: none;
    color: inherit;
    border-top: 3px solid #1a6b72;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.member-card strong { font-size: 1.15rem; letter-spacing: -0.02em; }
.member-card:hover { transform: translateY(-2px); box-shadow: 0 16px 32px rgba(0, 0, 0, 0.18); }
.member-comment-list { display: grid; gap: 16px; }
.member-comment-item {
    padding-bottom: 16px;
    border-bottom: 1px solid var(--line);
}
.member-comment-item:last-child { border-bottom: 0; padding-bottom: 0; }
@media (max-width: 760px) {
    .member-top { padding: 12px 16px; }
    .member-wrap { grid-template-columns: 1fr; padding: 20px 16px 48px; gap: 16px; }
    .member-nav { position: static; flex-direction: row; overflow-x: auto; }
    .member-nav a { white-space: nowrap; }
    .member-nav a.member-out { margin-top: 0; }
    .member-cards { grid-template-columns: 1fr; }
    .member-page-title { font-size: 1.6rem; }
}




/* Shared CMS pages */
.cms-page { display: grid; gap: 18px; }
.cms-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
}
.cms-stat { padding: 16px 18px; min-height: auto; }
.cms-stat b {
    display: block;
    margin-top: 6px;
    font-size: 28px;
    letter-spacing: -0.03em;
    line-height: 1;
}
.cms-form-head,
.cms-list-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
}
.cms-panel {
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 16px;
    background: rgba(13, 46, 53, 0.02);
}
.cms-panel:last-child { margin-bottom: 0; }
.cms-panel-title {
    margin: 0 0 12px;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: var(--muted);
}
.cms-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 14px;
}
.cms-form-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0 14px;
}
.cms-form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 4px;
}
.cms-actions-cell {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
    justify-content: flex-end;
    white-space: nowrap;
}
.cms-actions-cell form { display: inline; margin: 0; }
.cms-thumb {
    width: 44px;
    height: 44px;
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid var(--line);
    display: block;
}
.cms-thumb.round { border-radius: 50%; }
.cms-thumb.logo {
    width: auto;
    max-width: 90px;
    height: 40px;
    object-fit: contain;
    background: rgba(13,46,53,0.04);
    padding: 4px 8px;
    border-radius: 10px;
}
.cms-preview {
    max-width: 200px;
    border-radius: 14px;
    border: 1px solid var(--line);
    display: block;
}
.cms-table td { vertical-align: middle; }
.cms-table tr.is-editing {
    background: rgba(61, 154, 163, 0.08);
}
.cms-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.cms-title-cell strong { display: block; }
.cms-title-cell small,
.cms-title-cell .muted {
    display: block;
    margin-top: 3px;
    font-size: 0.82rem;
}
html[data-theme="dark"] .cms-panel {
    background: rgba(255,255,255,0.03);
}
html[data-theme="dark"] .cms-table tr.is-editing {
    background: rgba(94, 196, 205, 0.1);
}
html[data-theme="dark"] .cms-thumb.logo {
    background: rgba(255,255,255,0.06);
}
@media (max-width: 780px) {
    .cms-form-grid,
    .cms-form-grid-3 { grid-template-columns: 1fr; }
    .cms-actions-cell { justify-content: flex-start; }
}

/* Blogger dashboard polish */
.blogger-dash { display: grid; gap: 18px; }
.blogger-access {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.blogger-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
}
.blogger-link {
    display: block;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 14px;
    text-decoration: none;
    color: inherit;
    background: rgba(13,46,53,0.02);
    transition: border-color .15s ease, background .15s ease;
}
.blogger-link:hover {
    border-color: rgba(61,154,163,0.45);
    background: rgba(61,154,163,0.08);
}
.blogger-link strong { display: block; margin-bottom: 4px; }
.blogger-link span { color: var(--muted); font-size: 0.88rem; }
html[data-theme="dark"] .blogger-link {
    background: rgba(255,255,255,0.03);
}
html[data-theme="dark"] .blogger-link:hover {
    background: rgba(94,196,205,0.12);
}
