:root {
    --bg: #090d14;
    --sidebar: #0c111b;
    --panel: #111824;
    --panel-soft: #141d2b;
    --border: #222e3f;

    --text: #f7f9fc;
    --muted: #8f9bad;
    --muted-strong: #b8c1ce;

    --accent: #5ca9ff;
    --accent-soft: rgba(92, 169, 255, 0.12);

    --success: #35d07f;
    --warning: #f3b94f;
    --danger: #f1636c;

    --sidebar-width: 250px;
    --radius: 14px;
}

* {
    box-sizing: border-box;
}

html {
    color-scheme: dark;
}

body {
    margin: 0;
    min-width: 320px;
    background:
        radial-gradient(
            circle at 75% -10%,
            rgba(55, 112, 177, 0.12),
            transparent 34%
        ),
        var(--bg);
    color: var(--text);
    font-family:
        Pretendard,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
}

button,
input,
select {
    font: inherit;
}

.app-shell {
    min-height: 100vh;
}

.sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 20;
    display: flex;
    width: var(--sidebar-width);
    flex-direction: column;
    border-right: 1px solid var(--border);
    background: rgba(12, 17, 27, 0.95);
    backdrop-filter: blur(20px);
}

.brand {
    display: flex;
    align-items: center;
    gap: 13px;
    height: 86px;
    padding: 0 24px;
    border-bottom: 1px solid var(--border);
}

.brand-mark {
    display: grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border: 1px solid rgba(92, 169, 255, 0.36);
    border-radius: 11px;
    background: linear-gradient(
        145deg,
        rgba(92, 169, 255, 0.24),
        rgba(92, 169, 255, 0.06)
    );
    color: #89c4ff;
    font-size: 15px;
    font-weight: 800;
}

.brand strong,
.brand span {
    display: block;
}

.brand strong {
    font-size: 15px;
    letter-spacing: 0.08em;
}

.brand span {
    margin-top: 2px;
    color: var(--muted);
    font-size: 11px;
}

.sidebar-nav {
    display: grid;
    gap: 7px;
    padding: 25px 14px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 44px;
    padding: 0 14px;
    border: 1px solid transparent;
    border-radius: 10px;
    color: var(--muted-strong);
    font-size: 14px;
    text-decoration: none;
    transition:
        background 0.18s ease,
        border-color 0.18s ease,
        color 0.18s ease;
}

.nav-item:hover {
    border-color: var(--border);
    background: rgba(255, 255, 255, 0.025);
    color: var(--text);
}

.nav-item.active {
    border-color: rgba(92, 169, 255, 0.22);
    background: var(--accent-soft);
    color: #d9ecff;
}

.nav-icon {
    width: 18px;
    text-align: center;
    opacity: 0.85;
}

.sidebar-footer {
    margin-top: auto;
    padding: 20px;
}

.system-live {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.018);
}

.system-live strong,
.system-live span {
    display: block;
}

.system-live strong {
    font-size: 12px;
}

.system-live div > span {
    margin-top: 3px;
    color: var(--muted);
    font-size: 10px;
}

.live-dot,
.health-indicator {
    display: inline-block;
    flex: 0 0 auto;
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: var(--success);
    box-shadow: 0 0 0 5px rgba(53, 208, 127, 0.1);
}

.main-content {
    min-height: 100vh;
    margin-left: var(--sidebar-width);
    padding: 0 34px 32px;
}

.topbar {
    display: flex;
    min-height: 86px;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border);
}

.page-eyebrow,
.section-label {
    color: #64758a;
    font-size: 9px;
    font-weight: 750;
    letter-spacing: 0.15em;
}

.topbar h1 {
    margin: 5px 0 0;
    font-size: 23px;
    font-weight: 650;
    letter-spacing: -0.03em;
}

.topbar-status {
    display: flex;
    align-items: center;
    gap: 15px;
    color: var(--muted);
    font-size: 12px;
}

.live-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 10px;
    border: 1px solid rgba(53, 208, 127, 0.2);
    border-radius: 999px;
    background: rgba(53, 208, 127, 0.07);
    color: #8ce5b5;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.09em;
}

.live-badge .live-dot {
    width: 6px;
    height: 6px;
    box-shadow: none;
}

.hero-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 36px 2px 27px;
}

.hero-panel h2 {
    margin: 9px 0 8px;
    font-size: clamp(24px, 2.4vw, 34px);
    font-weight: 620;
    letter-spacing: -0.045em;
}

.hero-panel p {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
}

.health-summary {
    display: flex;
    min-width: 280px;
    align-items: center;
    gap: 14px;
    padding: 16px 18px;
    border: 1px solid rgba(53, 208, 127, 0.18);
    border-radius: var(--radius);
    background: rgba(53, 208, 127, 0.04);
}

.health-summary strong,
.health-summary span {
    display: block;
}

.health-summary strong {
    font-size: 13px;
}

.health-summary div > span {
    margin-top: 4px;
    color: var(--muted);
    font-size: 11px;
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 13px;
}

.metrics-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.metric-card,
.panel {
    border: 1px solid var(--border);
    background: linear-gradient(
        150deg,
        rgba(20, 29, 43, 0.94),
        rgba(14, 21, 32, 0.96)
    );
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.12);
}

.metric-card {
    min-height: 176px;
    padding: 19px;
    border-radius: var(--radius);
    transition:
        border-color 0.18s ease,
        transform 0.18s ease;
}

.metric-card:hover {
    transform: translateY(-2px);
    border-color: #33445c;
}

.metric-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: var(--muted-strong);
    font-size: 12px;
}

.metric-tag {
    padding: 4px 7px;
    border: 1px solid var(--border);
    border-radius: 6px;
    color: #68788d;
    font-size: 8px;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.metric-value {
    display: block;
    margin: 23px 0 17px;
    font-size: 37px;
    font-weight: 620;
    letter-spacing: -0.06em;
}

.metric-value small {
    margin-left: 4px;
    color: var(--muted);
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0;
}

.progress-track {
    height: 4px;
    overflow: hidden;
    border-radius: 999px;
    background: #202b3a;
}

.progress-value {
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #4f9dea, #71baff);
    transition: width 0.5s ease;
}

.metric-footnote {
    display: block;
    margin-top: 13px;
    color: #67768a;
    font-size: 10px;
}

.service-health-line {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-top: -4px;
    color: var(--muted-strong);
    font-size: 11px;
}

.service-health-line .health-indicator {
    width: 6px;
    height: 6px;
    box-shadow: none;
}

.content-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(330px, 0.85fr);
    gap: 13px;
    margin-top: 13px;
}

.content-grid.activity-only {
    grid-template-columns: 1fr;
}

.panel {
    min-height: 330px;
    border-radius: var(--radius);
}

.panel-header {
    display: flex;
    min-height: 73px;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    border-bottom: 1px solid var(--border);
}

.panel-header h3 {
    margin: 5px 0 0;
    font-size: 15px;
    font-weight: 620;
}

.ghost-button {
    padding: 7px 11px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: transparent;
    color: var(--muted-strong);
    cursor: pointer;
    font-size: 10px;
}

.ghost-button:hover {
    border-color: #3a4a60;
    color: var(--text);
}

.empty-state {
    display: grid;
    min-height: 255px;
    place-content: center;
    justify-items: center;
    text-align: center;
}

.empty-state-icon {
    display: grid;
    width: 46px;
    height: 46px;
    margin-bottom: 14px;
    place-items: center;
    border: 1px solid var(--border);
    border-radius: 13px;
    background: var(--panel-soft);
    color: #6d7d92;
}

.empty-state strong {
    font-size: 13px;
}

.empty-state span {
    margin-top: 7px;
    color: var(--muted);
    font-size: 11px;
}

.event-list {
    padding: 6px 19px;
}

.event-item {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 12px;
    align-items: start;
    padding: 16px 0;
    border-bottom: 1px solid rgba(34, 46, 63, 0.78);
}

.event-item:last-child {
    border-bottom: 0;
}

.event-status {
    width: 7px;
    height: 7px;
    margin-top: 5px;
    border-radius: 50%;
}

.event-status.success {
    background: var(--success);
}

.event-status.neutral {
    background: #617188;
}

.event-item strong,
.event-item span {
    display: block;
}

.event-item strong {
    font-size: 11px;
}

.event-item div > span {
    margin-top: 5px;
    color: var(--muted);
    font-size: 10px;
    line-height: 1.5;
}

.event-item time {
    color: #627186;
    font-size: 9px;
}

.dashboard-footer {
    display: flex;
    justify-content: space-between;
    padding: 18px 2px 0;
    color: #59677a;
    font-size: 9px;
}

.dashboard-footer strong {
    color: #8290a3;
    font-weight: 550;
}

@media (max-width: 1180px) {
    .metrics-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .content-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    :root {
        --sidebar-width: 74px;
    }

    .sidebar {
        width: var(--sidebar-width);
    }

    .brand {
        justify-content: center;
        padding: 0;
    }

    .brand > div:not(.brand-mark),
    .nav-item span:last-child,
    .sidebar-footer {
        display: none;
    }

    .sidebar-nav {
        padding-inline: 10px;
    }

    .nav-item {
        justify-content: center;
        padding: 0;
    }

    .main-content {
        padding-inline: 18px;
    }

    .hero-panel {
        align-items: flex-start;
        flex-direction: column;
    }

    .health-summary {
        width: 100%;
        min-width: 0;
    }

    .metrics-grid {
        grid-template-columns: 1fr;
    }

    .topbar-status > span:last-child {
        display: none;
    }

    .dashboard-footer {
        gap: 10px;
        flex-direction: column;
    }
}

/* =========================================================
   SKY Control Center UI Framework v0.2
   ========================================================= */

body {
    font-family:
        Pretendard,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
}

.page-content {
    width: 100%;
}

.brand {
    padding: 0 19px;
}

.brand-link {
    display: flex;
    width: 100%;
    align-items: center;
    gap: 13px;
    color: inherit;
    text-decoration: none;
}

.brand-mark {
    flex: 0 0 auto;
}

.brand-mark svg {
    width: 18px;
    height: 18px;
}

.brand-copy {
    min-width: 0;
}

.brand-copy strong {
    font-size: 14px;
    font-weight: 750;
    letter-spacing: 0.12em;
}

.brand-copy span {
    color: var(--muted);
    font-size: 10px;
    letter-spacing: 0.03em;
}

.sidebar-nav {
    display: block;
    padding: 20px 12px;
}

.nav-section-title {
    display: block;
    padding: 0 13px 9px;
    color: #536176;
    font-size: 8px;
    font-weight: 800;
    letter-spacing: 0.18em;
}

.nav-section-spacer {
    margin-top: 25px;
}

.nav-item {
    position: relative;
    margin-bottom: 4px;
}

.nav-item::before {
    position: absolute;
    top: 9px;
    bottom: 9px;
    left: -12px;
    width: 2px;
    border-radius: 999px;
    background: transparent;
    content: "";
}

.nav-item.active::before {
    background: var(--accent);
    box-shadow: 0 0 12px rgba(92, 169, 255, 0.65);
}

.nav-item svg {
    width: 16px;
    height: 16px;
    flex: 0 0 auto;
}

.nav-item.active {
    background:
        linear-gradient(
            90deg,
            rgba(92, 169, 255, 0.13),
            rgba(92, 169, 255, 0.035)
        );
}

.system-live {
    position: relative;
    overflow: hidden;
}

.system-live::before {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        radial-gradient(
            circle at 0 50%,
            rgba(53, 208, 127, 0.08),
            transparent 55%
        );
    content: "";
}

.status-pulse {
    position: relative;
    z-index: 1;
}

.system-live-copy {
    position: relative;
    z-index: 1;
    min-width: 0;
    flex: 1;
}

.system-live-icon {
    position: relative;
    z-index: 1;
    width: 15px;
    height: 15px;
    color: #506276;
}

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 11px;
}

.topbar-clock {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 0 6px;
    color: var(--muted);
    font-size: 11px;
    font-variant-numeric: tabular-nums;
}

.topbar-clock svg {
    width: 14px;
    height: 14px;
}

.icon-button {
    display: grid;
    width: 34px;
    height: 34px;
    place-items: center;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: rgba(255, 255, 255, 0.018);
    color: #8290a3;
    cursor: pointer;
    transition:
        border-color 0.18s ease,
        background 0.18s ease,
        color 0.18s ease,
        transform 0.18s ease;
}

.icon-button:hover {
    border-color: #34455d;
    background: rgba(255, 255, 255, 0.035);
    color: var(--text);
}

.icon-button:active {
    transform: scale(0.96);
}

.icon-button svg {
    width: 15px;
    height: 15px;
}

.icon-button.is-loading svg {
    animation: spin 0.8s linear infinite;
}

.admin-profile {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-left: 4px;
    padding-left: 14px;
    border-left: 1px solid var(--border);
}

.admin-avatar {
    display: grid;
    width: 31px;
    height: 31px;
    place-items: center;
    border: 1px solid rgba(92, 169, 255, 0.25);
    border-radius: 9px;
    background: var(--accent-soft);
    color: #acd6ff;
    font-size: 11px;
    font-weight: 750;
}

.admin-copy strong,
.admin-copy span {
    display: block;
}

.admin-copy strong {
    font-size: 10px;
    font-weight: 650;
}

.admin-copy span {
    margin-top: 3px;
    color: #657489;
    font-size: 8px;
}

.progress-warning {
    background:
        linear-gradient(
            90deg,
            #d99a34,
            #f3b94f
        );
}

.progress-danger {
    background:
        linear-gradient(
            90deg,
            #d94f5a,
            #f1636c
        );
}

.metric-card,
.panel,
.hero-panel,
.topbar {
    animation:
        panel-enter
        0.45s
        ease
        both;
}

.metrics-grid .metric-card:nth-child(1) {
    animation-delay: 0.04s;
}

.metrics-grid .metric-card:nth-child(2) {
    animation-delay: 0.08s;
}

.metrics-grid .metric-card:nth-child(3) {
    animation-delay: 0.12s;
}

.metrics-grid .metric-card:nth-child(4) {
    animation-delay: 0.16s;
}

.content-grid .panel:nth-child(1) {
    animation-delay: 0.2s;
}

.content-grid .panel:nth-child(2) {
    animation-delay: 0.24s;
}

@keyframes panel-enter {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@media (max-width: 900px) {
    .admin-copy {
        display: none;
    }
}

.blocked-page {
    display: grid; min-height: 100vh; place-items: center; margin: 0; padding: 24px;
    background: radial-gradient(circle at top, #13243a 0, #090e16 45%, #070b11 100%);
    color: #edf5ff; font-family: Inter, Pretendard, system-ui, sans-serif;
}
.blocked-card {
    width: min(520px, 100%); padding: 38px; border: 1px solid #27384e;
    border-radius: 18px; background: rgba(13, 22, 34, .94);
    box-shadow: 0 28px 80px rgba(0, 0, 0, .48); text-align: center;
}
.blocked-mark {
    display: grid; width: 54px; height: 54px; place-items: center; margin: 0 auto 24px;
    border: 1px solid #397fc4; border-radius: 14px; color: #8dc6ff;
    font-size: 13px; font-weight: 800; letter-spacing: .12em;
}
.blocked-card h1 { margin: 13px 0 10px; font-size: 24px; }
.blocked-card p { margin: 0; color: #aab8ca; font-size: 13px; line-height: 1.7; }
.blocked-card small { display: block; margin-top: 22px; color: #65758b; font-size: 10px; line-height: 1.6; }

.first-password-body {
    display: grid; min-height: 100vh; place-items: center; margin: 0; padding: 24px;
    background: radial-gradient(circle at top, #13243a 0, #090e16 48%, #070b11 100%);
    color: #edf5ff; font-family: Inter, Pretendard, system-ui, sans-serif;
}
.first-password-card {
    width: min(470px, 100%); padding: 34px; border: 1px solid #293a50;
    border-radius: 18px; background: rgba(13, 22, 34, .96);
    box-shadow: 0 28px 80px rgba(0, 0, 0, .5);
}
.first-password-brand { display: flex; align-items: baseline; gap: 8px; margin-bottom: 28px; }
.first-password-brand span { font-size: 18px; font-weight: 900; letter-spacing: .14em; }
.first-password-brand small { color: #71839a; font-size: 8px; letter-spacing: .18em; }
.first-password-card h1 { margin: 11px 0 8px; font-size: 23px; }
.first-password-card > p { margin: 0 0 22px; color: #91a1b5; font-size: 11px; }
.first-password-form { display: grid; gap: 14px; }
.first-password-form label { display: grid; gap: 7px; color: #afbdcd; font-size: 11px; }
.first-password-form input {
    height: 44px; padding: 0 12px; border: 1px solid #28384d; border-radius: 9px;
    outline: 0; background: #0a111b; color: white;
}
.first-password-form input:focus { border-color: #4e92d7; box-shadow: 0 0 0 3px rgba(78, 146, 215, .1); }
.first-password-form small { color: #687a90; font-size: 9px; }
.first-password-form > button {
    height: 44px; border: 1px solid #5ca9ff; border-radius: 9px; background: #397fc4;
    color: white; cursor: pointer; font-size: 11px; font-weight: 800;
}
.first-password-logout { margin-top: 13px; text-align: center; }
.first-password-logout button { border: 0; background: transparent; color: #7f90a5; cursor: pointer; font-size: 10px; }
.service-readonly-label { color: #718198; font-size: 9px; }

.service-register-panel { margin-bottom: 18px; padding-bottom: 18px; }
.service-register-form { display: grid; grid-template-columns: 1.4fr 1fr 1.2fr .55fr 1.5fr auto; gap: 10px; align-items: end; padding: 16px 18px 0; }
.service-register-form label, .service-edit-panel label { display: grid; gap: 6px; color: var(--muted); font-size: 11px; }
.service-register-form input, .service-edit-panel input { min-width: 0; height: 40px; border: 1px solid var(--border); border-radius: 8px; background: rgba(4, 12, 23, .45); color: var(--text); padding: 0 11px; }
.service-register-panel .form-help { margin: 12px 18px 0; color: var(--muted); font-size: 11px; }
.service-edit-panel { margin-top: 14px; border-top: 1px solid var(--border); padding-top: 12px; }
.service-edit-panel summary { color: var(--accent); cursor: pointer; font-size: 11px; }
.service-edit-panel form { display: grid; grid-template-columns: 1.3fr 1.1fr .5fr 1.5fr auto; gap: 8px; align-items: end; margin-top: 12px; }
.service-edit-panel .delete-service-form { display: flex; justify-content: flex-end; }
.danger-button { color: #ff8b95 !important; border-color: rgba(255, 92, 105, .35) !important; }
.remote-dashboard-panel { margin: 18px 0; }
.remote-dashboard-values { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; padding: 16px 18px 18px; }
.remote-dashboard-values span { border: 1px solid var(--border); border-radius: 9px; padding: 13px; color: var(--muted); }
.remote-dashboard-values strong { color: var(--text); font-size: 20px; margin-left: 8px; }
.remote-dashboard-values .offline { color: #ff8b95; }
.remote-metrics { margin-top: 18px; }
@media (max-width: 1100px) { .service-register-form, .service-edit-panel form { grid-template-columns: 1fr 1fr; } }
@media (max-width: 700px) { .service-register-form, .service-edit-panel form, .remote-dashboard-values { grid-template-columns: 1fr; } }

.backup-summary-grid { display: grid; grid-template-columns: .7fr 1.5fr 1fr; gap: 13px; }
.backup-summary, .backup-create-card { min-height: 0; padding: 19px; }
.backup-summary strong { display: block; margin: 9px 0 5px; font-size: 25px; }
.backup-summary .backup-path { overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.backup-summary small { color: #69798e; font-size: 9px; }
.backup-create-card form { display: flex; height: 100%; flex-direction: column; justify-content: space-between; gap: 15px; color: #7e8ea2; font-size: 10px; }
.backup-create-card button, .backup-list button {
    height: 36px; padding: 0 12px; border: 1px solid rgba(92,169,255,.35);
    border-radius: 8px; background: #397fc4; color: white; cursor: pointer;
}
.backup-list-panel { min-height: 0; margin-top: 13px; }
.backup-list { display: grid; padding: 0 18px 14px; }
.backup-list > article { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 13px 0; border-bottom: 1px solid var(--border); }
.backup-list strong, .backup-list span { display: block; }
.backup-list strong { font-size: 10px; }.backup-list span { margin-top: 4px; color: #68788d; font-size: 8px; }
.backup-list summary { color: #8dbff0; cursor: pointer; font-size: 10px; }
.backup-list details form { display: flex; gap: 7px; margin-top: 9px; }
.backup-list input { height: 36px; padding: 0 9px; border: 1px solid var(--border); border-radius: 7px; background: #0a111a; color: white; }
.backup-warning { color: #e9b86f; font-size: 9px; }
@media (max-width: 900px) {
    .backup-summary-grid { grid-template-columns: 1fr; }
    .backup-list > article, .backup-list details form { align-items: stretch; flex-direction: column; }
}

.alert-list { display: grid; gap: 10px; }
.notification-status {
    display: inline-flex; padding: 5px 8px;
    border-radius: 999px; font-size: 9px; font-weight: 700;
    vertical-align: middle;
}
.notification-status.enabled { color: #65d6a4; background: rgba(53,208,127,.1); }
.notification-status.disabled { color: #7c8b9e; background: rgba(255,255,255,.04); }
.page-title-inline { display: inline-flex; align-items: center; gap: 10px; }
.alert-card {
    display: grid; min-height: 0; grid-template-columns: auto 1fr auto;
    gap: 14px; align-items: center; padding: 17px 18px;
}
.alert-card.resolved { opacity: .62; }
.alert-severity { padding: 5px 8px; border-radius: 999px; font-size: 9px; font-weight: 800; }
.alert-card.critical .alert-severity { color: #f29aa1; background: rgba(241,99,108,.12); }
.alert-card.warning .alert-severity { color: #e9b86f; background: rgba(233,184,111,.1); }
.alert-card h3 { margin: 0 0 5px; font-size: 13px; }
.alert-card p { margin: 0 0 6px; color: #8796a9; font-size: 10px; }
.alert-card time { color: #58677b; font-size: 8px; }
.alert-state { display: grid; justify-items: end; gap: 6px; font-size: 9px; }
.alert-state span { color: #657489; }
.alert-state button {
    padding: 6px 9px; border: 1px solid var(--border); border-radius: 7px;
    background: transparent; color: #8dbff0; cursor: pointer; font-size: 9px;
}
.alert-state .alert-delete-button { color: #ff8b95; border-color: rgba(255, 92, 105, .3); }
.alert-empty { min-height: 0; padding: 30px; text-align: center; }
.dashboard-alerts { min-height: 0; margin-top: 13px; }
.dashboard-alert-list { display: grid; gap: 0; padding: 4px 18px 12px; color: #68788d; font-size: 10px; }
.dashboard-alert-row { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.dashboard-alert-row strong { min-width: 180px; color: #dce7f4; }
.dashboard-alert-row.critical strong { color: #e98189; }

.server-admin-warning {
    display: flex; gap: 12px; margin-bottom: 13px; padding: 12px 15px;
    border: 1px solid rgba(233,184,111,.22); border-radius: 10px;
    background: rgba(233,184,111,.05); color: #8998aa; font-size: 10px;
}
.server-admin-warning strong { color: #e9b86f; }
.server-admin-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }
.server-admin-grid.lower { margin-top: 13px; }
.server-info-panel { min-height: 0; }
.server-info-panel pre {
    max-height: 360px; overflow: auto; margin: 0; padding: 15px;
    background: #080d14; color: #acbbcc; font: 10px/1.65 ui-monospace, monospace;
    white-space: pre-wrap;
}
.reboot-panel { min-height: 0; padding: 20px; border-color: rgba(241,99,108,.22); }
.reboot-panel h3 { margin: 7px 0; color: #e98189; }
.reboot-panel p { margin: 0 0 18px; color: #75859a; font-size: 10px; line-height: 1.6; }
.reboot-panel form, .reboot-panel label { display: grid; gap: 8px; }
.reboot-panel form { gap: 13px; }
.reboot-panel label span { color: #9cabbc; font-size: 10px; }
.reboot-panel input {
    height: 40px; padding: 0 11px; border: 1px solid var(--border);
    border-radius: 8px; background: #0a111a; color: white;
}
.reboot-panel button {
    height: 40px; border: 1px solid rgba(241,99,108,.4); border-radius: 8px;
    background: rgba(241,99,108,.12); color: #ef9ba1; cursor: pointer; font-weight: 700;
}
@media (max-width: 900px) { .server-admin-grid { grid-template-columns: 1fr; } }

.final-summary-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 13px; margin-bottom: 13px; }
.final-summary-card { min-height: 0; padding: 16px 18px; color: inherit; text-decoration: none; }
.final-summary-card > span { color: #62738a; font-size: 8px; font-weight: 800; letter-spacing: .16em; }
.final-summary-card strong { display: block; margin: 8px 0 4px; font-size: 21px; }
.final-summary-card small { color: #68788d; font-size: 9px; }
.database-hero { display: flex; min-height: 0; align-items: center; gap: 14px; padding: 22px; }
.database-hero > div { flex: 1; }
.database-hero h2 { margin: 6px 0; font-size: 22px; }
.database-hero p { margin: 0; color: #6d7e93; font-size: 10px; }
.database-hero > strong { color: #65d6a4; font-size: 12px; }
.sqlite-panel { min-height: 0; margin-top: 13px; }
.sqlite-panel .panel-header > span { color: #718198; font-size: 10px; }
.db-table-wrap { overflow: auto; max-height: 560px; }
.db-integrity { color: #e9b86f; }.db-integrity.ok { color: #65d6a4; }
.nas-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 13px; }
.nas-card { min-height: 0; padding: 20px; }
.nas-card b { color: #8b9db2; font-size: 10px; }
.nas-ports { display: flex; gap: 7px; margin-top: 18px; }
.nas-ports span { padding: 5px 7px; border-radius: 6px; font-size: 8px; }
.nas-ports .online { color: #65d6a4; background: rgba(53,208,127,.1); }
.nas-ports .offline { color: #748398; background: rgba(255,255,255,.03); }
.nas-empty { min-height: 0; padding: 35px; }
.nas-empty p { color: #718198; }.nas-empty pre { padding: 12px; background: #080d14; color: #aab9ca; overflow: auto; }
@media (max-width: 900px) {
    .final-summary-grid, .nas-grid { grid-template-columns: 1fr; }
}

.monitor-settings-form { display: grid; gap: 13px; }
.settings-panel { min-height: 0; }
.settings-fields { display: grid; grid-template-columns: repeat(3, 1fr); gap: 13px; padding: 18px; }
.settings-fields label, .health-settings-list label {
    display: grid; gap: 7px; color: #95a4b6; font-size: 10px;
}
.settings-fields input[type="number"], .health-settings-list input,
.maintenance-list input {
    height: 39px; padding: 0 10px; border: 1px solid var(--border);
    border-radius: 8px; background: #0b121c; color: white;
}
.settings-fields .toggle-setting { display: flex; align-items: center; gap: 9px; }
.health-settings-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; padding: 18px; }
.settings-save-button {
    justify-self: end; height: 40px; padding: 0 18px; border: 0; border-radius: 8px;
    background: #397fc4; color: white; cursor: pointer; font-weight: 700;
}
.maintenance-settings { margin-top: 13px; }
.maintenance-list { display: grid; gap: 0; padding: 0 18px 14px; }
.maintenance-list form {
    display: grid; grid-template-columns: minmax(190px, 1fr) 1.4fr 190px 72px;
    gap: 9px; align-items: center; padding: 11px 0; border-bottom: 1px solid var(--border);
}
.maintenance-list strong { font-size: 10px; }
.maintenance-list button {
    height: 36px; border: 1px solid rgba(233,184,111,.3); border-radius: 8px;
    background: rgba(233,184,111,.08); color: #e9b86f; cursor: pointer;
}
.maintenance-list .maintenance-off { color: #65d6a4; border-color: rgba(53,208,127,.3); }
.maintenance-note { color: #e9b86f; font-size: 9px; }
.postgres-detail-grid { display: grid; grid-template-columns: 1fr 1fr .6fr; gap: 13px; margin-top: 13px; }
.postgres-detail-card { min-height: 0; }
.simple-db-list { display: grid; padding: 8px 16px 14px; }
.simple-db-list span { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--border); font-size: 10px; }
.simple-db-list b { color: #8eb7df; }
.lock-count { display: block; padding: 28px; font-size: 30px; text-align: center; }
.postgres-monitor-notice { margin-top: 13px; padding: 13px 15px; border: 1px solid var(--border); border-radius: 10px; color: #78889b; font-size: 10px; }
@media (max-width: 900px) {
    .settings-fields, .health-settings-list, .postgres-detail-grid { grid-template-columns: 1fr; }
    .maintenance-list form { grid-template-columns: 1fr; }
}

.telemetry-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 13px;
    margin-top: 13px;
}
.telemetry-card { min-height: 235px; }
.telemetry-values {
    display: flex;
    gap: 22px;
    padding: 14px 20px 4px;
    color: #718198;
    font-size: 10px;
}
.telemetry-values strong { color: #dce9f8; font-size: 13px; }
.telemetry-chart { width: 100%; height: 115px; padding: 8px 20px 18px; overflow: visible; }
.chart-line {
    fill: none;
    stroke-width: 2;
    vector-effect: non-scaling-stroke;
}
.chart-line.network { stroke: #54a6f5; }
.chart-line.load { stroke: #65d6a4; }
@media (max-width: 900px) {
    .telemetry-grid { grid-template-columns: 1fr; }
    .telemetry-values { flex-wrap: wrap; }
}

.service-overview {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}
.managed-service-card { min-height: 0; padding: 18px; }
.service-card-top { display: flex; align-items: center; gap: 11px; }
.service-card-top > div { min-width: 0; flex: 1; }
.service-card-top h3 { margin: 0 0 4px; font-size: 14px; }
.service-card-top div > span { color: #637287; font-size: 9px; }
.service-state-dot { width: 9px; height: 9px; border-radius: 50%; }
.service-state-dot.online { background: #35d07f; box-shadow: 0 0 10px rgba(53,208,127,.5); }
.service-state-dot.offline { background: #f1636c; box-shadow: 0 0 10px rgba(241,99,108,.4); }
.service-state-label { padding: 4px 8px; border-radius: 999px; font-size: 9px; font-weight: 700; }
.service-state-label.online { color: #65d6a4; background: rgba(53,208,127,.1); }
.service-state-label.offline { color: #e98189; background: rgba(241,99,108,.1); }
.service-details { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 20px 0 12px; }
.service-details div { padding: 10px; border: 1px solid var(--border); border-radius: 8px; background: rgba(8,13,21,.35); }
.service-details dt { color: #607087; font-size: 8px; }
.service-details dd { margin: 5px 0 0; color: #cbd7e5; font-size: 11px; }
.service-since { overflow: hidden; margin: 0; color: #5f6e82; font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
.service-location {
    overflow: hidden; margin: 0 0 6px; color: #8295ab; font-size: 9px;
    text-overflow: ellipsis; white-space: nowrap;
}
.service-card-actions { display: flex; gap: 8px; margin-top: 16px; }
.service-card-actions a, .service-card-actions button {
    display: inline-flex; min-height: 34px; align-items: center; padding: 0 12px;
    border: 1px solid var(--border); border-radius: 8px; background: transparent;
    color: #8dbff0; cursor: pointer; font-size: 10px; text-decoration: none;
}
.service-card-actions button { color: #e9b86f; }
.service-card-actions .service-delete-button { color: #ff8b95; border-color: rgba(255, 92, 105, .3); }
.service-page-toolbar {
    display: flex; align-items: center; justify-content: space-between; gap: 16px;
    margin-bottom: 16px; padding: 4px 2px;
}
.service-page-toolbar p { margin: 5px 0 0; color: var(--muted); font-size: 10px; }
.service-page-toolbar .admin-primary-button { min-width: 104px; }
.service-table-panel { min-height: 0; overflow: hidden; }
.service-table-scroll { overflow-x: auto; }
.service-management-table { width: 100%; min-width: 920px; border-collapse: collapse; }
.service-management-table th {
    padding: 12px 15px; border-bottom: 1px solid var(--border); color: #64758b;
    font-size: 9px; font-weight: 700; letter-spacing: .05em; text-align: left;
}
.service-management-table td {
    padding: 14px 15px; border-bottom: 1px solid var(--border); color: #b8c5d5;
    font-size: 10px; vertical-align: middle;
}
.service-management-table tbody tr:last-child td { border-bottom: 0; }
.service-table-state { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
.service-table-state b { color: #cbd7e5; font-size: 10px; }
.service-table-name strong, .service-table-name span, .service-table-name small,
.service-management-table td > small { display: block; }
.service-table-name strong { margin-bottom: 4px; color: var(--text); font-size: 12px; }
.service-table-name span { color: #718198; font-size: 9px; }
.service-table-name small, .service-management-table td > small { margin-top: 4px; color: #5f6e82; font-size: 8px; }
.service-runtime { display: block; margin-bottom: 4px; font-weight: 700; }
.service-runtime.online { color: #65d6a4; }
.service-runtime.offline { color: #e98189; }
.service-table-actions { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.service-table-actions form { margin: 0; }
.service-table-actions a, .service-table-actions button {
    display: inline-flex; min-height: 32px; align-items: center; padding: 0 10px;
    border: 1px solid var(--border); border-radius: 7px; background: transparent;
    color: #8dbff0; cursor: pointer; font-size: 9px; text-decoration: none;
}
.service-table-actions .restart-service-form button { color: #e9b86f; }
.service-table-actions .edit-service-button { color: #73b8ff; }
.service-table-actions .service-delete-button { color: #ff8b95; border-color: rgba(255, 92, 105, .3); }
.service-edit-row td { padding-top: 0; background: rgba(8, 13, 21, .2); }
.service-edit-row .service-edit-panel { margin: 0; padding: 10px 0 14px; border-top: 0; }
.service-table-empty { padding: 32px !important; color: var(--muted) !important; text-align: center; }
.password-modal.service-modal { width: min(620px, calc(100vw - 32px)); }
.service-modal-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.service-modal-fields label { display: grid; gap: 7px; color: #aeb9c7; font-size: 11px; }
.service-modal-fields input {
    width: 100%; height: 44px; padding: 0 12px; border: 1px solid var(--border);
    border-radius: 9px; outline: 0; background: #0c131d; color: var(--text);
}
.service-modal-fields input:focus { border-color: rgba(92,169,255,.55); box-shadow: 0 0 0 3px rgba(92,169,255,.08); }
.service-modal-location { grid-column: 1 / -1; }
.service-log-panel { min-height: 0; }
.service-log-panel pre {
    max-height: calc(100vh - 230px); overflow: auto; margin: 0; padding: 18px;
    background: #080d14; color: #aebdce; font: 11px/1.65 ui-monospace, SFMono-Regular, Menlo, monospace;
    white-space: pre-wrap; word-break: break-word;
}
@media (max-width: 1100px) { .service-overview { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 700px) { .service-overview { grid-template-columns: 1fr; } }
@media (max-width: 700px) {
    .service-modal-fields { grid-template-columns: 1fr; }
    .service-modal-location { grid-column: auto; }
}

.topbar {
    position: relative;
    z-index: 500;
    overflow: visible;
}
.profile-menu-wrap { z-index: 510; }
.profile-dropdown { z-index: 1000; }

.unified-log-panel { min-height: 0; }
.log-filter {
    display: grid; grid-template-columns: 1.2fr 130px 130px 1.4fr auto;
    gap: 9px; padding: 16px; border-bottom: 1px solid var(--border);
}
.log-filter select, .log-filter input {
    height: 38px; padding: 0 10px; border: 1px solid var(--border);
    border-radius: 8px; background: #0d141e; color: #becad8;
}
.log-filter button {
    padding: 0 16px; border: 1px solid rgba(92,169,255,.4); border-radius: 8px;
    background: #397fc4; color: white; cursor: pointer;
}
.unified-log-output {
    max-height: calc(100vh - 235px); overflow: auto; padding: 12px 16px 18px;
    background: #080d14; color: #aebdce; font: 10px/1.7 ui-monospace, monospace;
}
.unified-log-output div { padding: 3px 0; border-bottom: 1px solid rgba(42,56,76,.35); }
.remote-hero {
    display: flex; min-height: 0; align-items: center; justify-content: space-between;
    padding: 24px;
}
.remote-hero h2 { margin: 7px 0; font-size: 28px; }
.remote-hero p, .remote-note { color: #6f7f94; font-size: 11px; }
.remote-health { padding: 8px 12px; border-radius: 999px; font-size: 10px; font-weight: 700; }
.remote-health.online { color: #65d6a4; background: rgba(53,208,127,.1); }
.remote-health.offline { color: #e98189; background: rgba(241,99,108,.1); }
.remote-probe-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 13px; margin-top: 13px; }
.remote-probe-card { display: flex; min-height: 0; align-items: center; gap: 11px; padding: 18px; }
.remote-probe-card div { flex: 1; }
.remote-probe-card strong, .remote-probe-card span { display: block; }
.remote-probe-card strong { font-size: 12px; }
.remote-probe-card span { margin-top: 4px; color: #657489; font-size: 9px; }
.remote-probe-card b { color: #8ea0b5; font-size: 10px; }
.remote-note { margin: 13px 2px; }
@media (max-width: 900px) {
    .log-filter { grid-template-columns: 1fr 1fr; }
    .remote-probe-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 760px) {
    .brand-copy,
    .nav-section-title {
        display: none;
    }

    .brand-link {
        justify-content: center;
    }

    .topbar-actions {
        gap: 7px;
    }

    .topbar-clock,
    .admin-profile {
        display: none;
    }
}



/* =========================================================
   Login
   ========================================================= */

.login-body {
    min-height: 100vh;
    overflow-x: hidden;
    background:
        radial-gradient(
            circle at 12% 4%,
            rgba(57, 128, 204, 0.16),
            transparent 32%
        ),
        #080c13;
}

.login-layout {
    display: grid;
    min-height: 100vh;
    grid-template-columns:
        minmax(440px, 1.15fr)
        minmax(420px, 0.85fr);
}

.login-visual {
    position: relative;
    display: flex;
    overflow: hidden;
    flex-direction: column;
    min-height: 100vh;
    padding: 48px 58px 38px;
    border-right: 1px solid var(--border);
    background:
        linear-gradient(
            145deg,
            rgba(15, 24, 37, 0.96),
            rgba(8, 13, 21, 0.98)
        );
}

.login-visual::before {
    position: absolute;
    top: -170px;
    right: -150px;
    width: 500px;
    height: 500px;
    border: 1px solid rgba(92, 169, 255, 0.09);
    border-radius: 50%;
    content: "";
}

.login-visual::after {
    position: absolute;
    right: -20%;
    bottom: -48%;
    width: 760px;
    height: 760px;
    border: 1px solid rgba(92, 169, 255, 0.05);
    border-radius: 50%;
    content: "";
}

.login-brand {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 13px;
}

.login-brand-mark {
    display: grid;
    width: 40px;
    height: 40px;
    flex: 0 0 auto;
    place-items: center;
    border: 1px solid rgba(92, 169, 255, 0.3);
    border-radius: 12px;
    background: rgba(92, 169, 255, 0.1);
    color: #93caff;
}

.login-brand-mark svg {
    width: 18px;
    height: 18px;
}

.login-brand strong,
.login-brand span {
    display: block;
}

.login-brand strong {
    font-size: 15px;
    font-weight: 800;
    letter-spacing: 0.14em;
}

.login-brand span {
    margin-top: 3px;
    color: #73839a;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.16em;
}

.login-visual-content {
    position: relative;
    z-index: 1;
    width: min(570px, 100%);
    margin: auto 0;
}

.login-eyebrow {
    color: #63758d;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.2em;
}

.login-visual-content h1 {
    margin: 17px 0 20px;
    font-size: clamp(38px, 4vw, 59px);
    font-weight: 610;
    line-height: 1.17;
    letter-spacing: -0.055em;
}

.login-visual-content > p {
    max-width: 520px;
    margin: 0;
    color: #8694a8;
    font-size: 14px;
    line-height: 1.8;
}

.login-status-card {
    display: flex;
    width: min(420px, 100%);
    align-items: center;
    gap: 13px;
    margin-top: 42px;
    padding: 16px 17px;
    border: 1px solid rgba(53, 208, 127, 0.16);
    border-radius: 13px;
    background: rgba(53, 208, 127, 0.035);
}

.login-status-card > div {
    min-width: 0;
    flex: 1;
}

.login-status-card strong,
.login-status-card span {
    display: block;
}

.login-status-card strong {
    font-size: 12px;
}

.login-status-card div > span {
    margin-top: 4px;
    color: #708096;
    font-size: 10px;
}

.login-status-card > svg {
    width: 17px;
    height: 17px;
    color: #5d7187;
}

.login-visual-footer {
    position: relative;
    z-index: 1;
    color: #48576b;
    font-size: 9px;
    letter-spacing: 0.04em;
}

.login-panel {
    display: grid;
    min-height: 100vh;
    place-items: center;
    padding: 42px;
    background:
        radial-gradient(
            circle at 100% 0,
            rgba(92, 169, 255, 0.07),
            transparent 30%
        ),
        rgba(8, 12, 19, 0.95);
}

.login-form-wrap {
    width: min(390px, 100%);
    animation: panel-enter 0.5s ease both;
}

.login-mobile-brand {
    display: none;
}

.login-heading {
    margin-bottom: 29px;
}

.login-heading h2 {
    margin: 11px 0 8px;
    font-size: 30px;
    font-weight: 650;
    letter-spacing: -0.045em;
}

.login-heading p {
    margin: 0;
    color: var(--muted);
    font-size: 12px;
}

.login-alert {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 18px;
    padding: 12px 13px;
    border: 1px solid rgba(241, 99, 108, 0.22);
    border-radius: 10px;
    background: rgba(241, 99, 108, 0.06);
    color: #f39ca2;
    font-size: 11px;
}

.login-alert svg {
    width: 15px;
    height: 15px;
    flex: 0 0 auto;
}

.login-form {
    display: grid;
    gap: 18px;
}

.login-field {
    display: grid;
    gap: 8px;
}

.login-field > span {
    color: #aeb9c7;
    font-size: 11px;
    font-weight: 600;
}

.login-input-wrap {
    position: relative;
}

.login-input-wrap > svg {
    position: absolute;
    top: 50%;
    left: 14px;
    width: 16px;
    height: 16px;
    color: #607087;
    pointer-events: none;
    transform: translateY(-50%);
}

.login-input-wrap input {
    width: 100%;
    height: 48px;
    padding: 0 46px 0 43px;
    border: 1px solid var(--border);
    outline: 0;
    border-radius: 11px;
    background: rgba(17, 24, 36, 0.84);
    color: var(--text);
    font-size: 12px;
    transition:
        border-color 0.18s ease,
        box-shadow 0.18s ease,
        background 0.18s ease;
}

.login-input-wrap input::placeholder {
    color: #536176;
}

.login-input-wrap input:focus {
    border-color: rgba(92, 169, 255, 0.52);
    background: rgba(19, 28, 42, 0.94);
    box-shadow: 0 0 0 3px rgba(92, 169, 255, 0.08);
}

.password-toggle {
    position: absolute;
    top: 50%;
    right: 9px;
    display: grid;
    width: 32px;
    height: 32px;
    place-items: center;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #66778c;
    cursor: pointer;
    transform: translateY(-50%);
}

.password-toggle:hover {
    background: rgba(255, 255, 255, 0.035);
    color: #a9b6c6;
}

.password-toggle svg {
    width: 15px;
    height: 15px;
}

.login-submit {
    display: flex;
    width: 100%;
    height: 48px;
    align-items: center;
    justify-content: center;
    gap: 9px;
    margin-top: 4px;
    border: 1px solid rgba(92, 169, 255, 0.38);
    border-radius: 11px;
    background:
        linear-gradient(
            135deg,
            #397fc4,
            #4e9be8
        );
    color: #f7fbff;
    cursor: pointer;
    font-size: 12px;
    font-weight: 700;
    box-shadow: 0 12px 28px rgba(23, 94, 164, 0.18);
    transition:
        transform 0.18s ease,
        box-shadow 0.18s ease,
        filter 0.18s ease;
}

.login-submit:hover {
    filter: brightness(1.07);
    transform: translateY(-1px);
    box-shadow: 0 16px 32px rgba(23, 94, 164, 0.24);
}

.login-submit:active {
    transform: translateY(0);
}

.login-submit svg {
    width: 15px;
    height: 15px;
}

.login-security {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    margin-top: 21px;
    color: #5f6e82;
    font-size: 9px;
    line-height: 1.6;
}

.login-security svg {
    width: 14px;
    height: 14px;
    flex: 0 0 auto;
    margin-top: 1px;
}

@media (max-width: 960px) {
    .login-layout {
        grid-template-columns: 1fr;
    }

    .login-visual {
        display: none;
    }

    .login-panel {
        padding: 28px;
    }

    .login-mobile-brand {
        display: flex;
        align-items: center;
        gap: 12px;
        margin-bottom: 56px;
    }

    .login-mobile-brand strong {
        font-size: 13px;
        letter-spacing: 0.02em;
    }
}

.logout-button {
    display: flex;
    width: auto;
    height: 30px;
    padding: 0 10px;
    gap: 6px;
    margin-left: 2px;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #64748a;
    cursor: pointer;
    font-size: 10px;
    font-weight: 700;
}

.nav-symbol {
    width: 17px;
    text-align: center;
    font-size: 14px;
}

.page-alert {
    margin-bottom: 16px;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: rgba(36, 47, 63, 0.85);
    color: var(--text);
    font-size: 12px;
}

.page-alert.success { border-color: rgba(72, 199, 142, 0.35); }
.page-alert.error { border-color: rgba(241, 99, 108, 0.42); }

.admin-summary-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin-bottom: 16px;
}

.admin-summary-value,
.admin-summary-owner {
    display: block;
    margin: 12px 0 8px;
    color: var(--text);
    font-size: 28px;
}

.admin-summary-owner { font-size: 20px; }
.admin-create-panel { margin-bottom: 16px; }

.admin-create-form {
    display: grid;
    grid-template-columns: 1fr 1fr 180px auto;
    gap: 12px;
    align-items: end;
}

.admin-create-form label {
    display: grid;
    gap: 7px;
    color: #aeb9c7;
    font-size: 11px;
}

.admin-create-form input,
.admin-create-form select,
.admin-table input,
.admin-table select {
    height: 38px;
    padding: 0 11px;
    border: 1px solid var(--border);
    border-radius: 8px;
    outline: none;
    background: #111824;
    color: var(--text);
}

.admin-primary-button,
.inline-form button,
.admin-actions button,
.primary-link {
    min-height: 38px;
    padding: 0 14px;
    border: 1px solid rgba(92, 169, 255, 0.4);
    border-radius: 8px;
    background: #397fc4;
    color: white;
    cursor: pointer;
    font-size: 11px;
    font-weight: 700;
    text-decoration: none;
}

.form-help,
.empty-copy {
    margin: 10px 0 0;
    color: var(--muted);
    font-size: 10px;
}

.admin-table-wrap { overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; }
.admin-table th,
.admin-table td {
    padding: 12px 10px;
    border-bottom: 1px solid var(--border);
    text-align: left;
    color: #aeb9c7;
    font-size: 11px;
    white-space: nowrap;
}
.admin-table th { color: #64748a; font-size: 9px; letter-spacing: .08em; }
.admin-table td strong { color: var(--text); }

.protected-badge,
.role-badge,
.status-chip {
    display: inline-flex;
    margin-left: 7px;
    padding: 3px 7px;
    border-radius: 999px;
    background: rgba(92, 169, 255, .12);
    color: #7eb8f5;
    font-size: 9px;
    font-weight: 700;
}

.inline-form,
.admin-actions,
.admin-actions details form {
    display: flex;
    align-items: center;
    gap: 7px;
}

.inline-form select { height: 34px; }
.inline-form button,
.admin-actions button { min-height: 32px; padding: 0 10px; }
.admin-actions details summary { color: #7eb8f5; cursor: pointer; font-size: 10px; }
.admin-actions details[open] form { margin-top: 8px; }
.admin-actions .danger-button {
    border-color: rgba(241, 99, 108, .35);
    background: rgba(241, 99, 108, .1);
    color: #e98189;
}

.admin-log-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-top: 16px;
}

.compact-log-list { display: grid; gap: 7px; }
.compact-log-row {
    display: grid;
    grid-template-columns: 54px 110px 1fr auto;
    gap: 8px;
    align-items: center;
    padding: 9px 0;
    border-bottom: 1px solid var(--border);
    color: #8090a4;
    font-size: 9px;
}
.compact-log-row.audit { grid-template-columns: 100px 1fr auto; }
.status-chip { margin: 0; justify-content: center; }
.status-chip.success { color: #65d6a4; background: rgba(72,199,142,.1); }
.status-chip.failed { color: #e98189; background: rgba(241,99,108,.1); }
.access-denied { text-align: center; padding: 60px 24px; }
.access-denied .primary-link { display: inline-flex; align-items: center; margin-top: 20px; }

@media (max-width: 900px) {
    .admin-create-form { grid-template-columns: 1fr; }
    .admin-summary-grid,
    .admin-log-grid { grid-template-columns: 1fr; }
}

.logout-button:hover {
    background: rgba(241, 99, 108, 0.08);
    color: #e98189;
}

.logout-button svg {
    width: 14px;
    height: 14px;
}

/* v0.3.1 — login, profile and account-management polish */
.login-field-icon {
    position: absolute;
    top: 50%;
    left: 15px;
    z-index: 1;
    width: 17px;
    height: 17px;
    fill: none;
    stroke: #607087;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
    pointer-events: none;
    transform: translateY(-50%);
}

.password-toggle svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
}

.password-toggle svg[hidden] { display: none; }

.profile-menu-wrap {
    position: relative;
    margin-left: 4px;
    padding-left: 14px;
    border-left: 1px solid var(--border);
}

.profile-trigger {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 4px 7px 4px 4px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: inherit;
    cursor: pointer;
}

.profile-trigger:hover,
.profile-trigger[aria-expanded="true"] {
    background: rgba(255, 255, 255, 0.04);
}

.profile-chevron {
    width: 14px;
    height: 14px;
    fill: none;
    stroke: #66778c;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
}

.profile-dropdown {
    position: absolute;
    top: calc(100% + 9px);
    right: 0;
    z-index: 30;
    width: 174px;
    overflow: hidden;
    padding: 6px;
    border: 1px solid #2a384c;
    border-radius: 11px;
    background: #111925;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.38);
}

.profile-dropdown[hidden] { display: none; }
.profile-dropdown form { margin: 0; }

.profile-dropdown button {
    width: 100%;
    padding: 10px 11px;
    border: 0;
    border-radius: 7px;
    background: transparent;
    color: #bac5d3;
    cursor: pointer;
    font-size: 11px;
    text-align: left;
}

.profile-dropdown button:hover {
    background: rgba(92, 169, 255, 0.08);
    color: #edf6ff;
}

.profile-dropdown .profile-logout {
    color: #e98189;
}

.password-modal {
    width: min(430px, calc(100vw - 32px));
    padding: 0;
    border: 1px solid #2c3b50;
    border-radius: 15px;
    background: #101823;
    color: var(--text);
    box-shadow: 0 28px 80px rgba(0, 0, 0, 0.55);
}

.password-modal::backdrop {
    background: rgba(3, 7, 13, 0.76);
    backdrop-filter: blur(4px);
}

.password-modal-card {
    display: grid;
    gap: 15px;
    padding: 24px;
}

.password-modal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 3px;
}

.password-modal-header h2 {
    margin: 6px 0 0;
    font-size: 20px;
}

.modal-close {
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #78879a;
    cursor: pointer;
    font-size: 22px;
}

.modal-close:hover { background: rgba(255,255,255,.05); color: white; }

.password-modal-card label {
    display: grid;
    gap: 7px;
    color: #aeb9c7;
    font-size: 11px;
}

.password-modal-card input {
    width: 100%;
    height: 44px;
    padding: 0 12px;
    border: 1px solid var(--border);
    border-radius: 9px;
    outline: 0;
    background: #0c131d;
    color: var(--text);
}

.password-modal-card input:focus {
    border-color: rgba(92, 169, 255, .55);
    box-shadow: 0 0 0 3px rgba(92, 169, 255, .08);
}

.password-modal-card > p {
    margin: -3px 0 0;
    color: #657489;
    font-size: 9px;
}

.password-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 5px;
}

.password-modal-actions button {
    min-width: 84px;
    height: 38px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 11px;
    font-weight: 700;
}

.modal-cancel {
    border: 1px solid var(--border);
    background: transparent;
    color: #aeb9c7;
}

.modal-submit {
    border: 1px solid rgba(92,169,255,.4);
    background: #397fc4;
    color: white;
}

.admin-management-page {
    display: grid;
    gap: 14px;
}

.admin-management-page .panel,
.admin-management-page .metric-card {
    min-height: 0;
    box-shadow: 0 12px 30px rgba(0, 0, 0, .1);
}

.admin-management-page .admin-summary-grid {
    gap: 14px;
    margin: 0;
}

.admin-management-page .admin-summary-grid .metric-card {
    padding: 18px 20px;
}

.admin-management-page .admin-summary-value,
.admin-management-page .admin-summary-owner {
    margin: 9px 0 5px;
}

.admin-management-page .panel-header {
    min-height: 62px;
    padding: 0 18px;
}

.admin-management-page .admin-create-panel {
    margin: 0;
    padding-bottom: 16px;
}

.admin-management-page .admin-create-form {
    padding: 16px 18px 0;
    grid-template-columns: minmax(170px, 1fr) minmax(220px, 1.25fr) 150px 100px;
}

.admin-management-page .form-help {
    margin: 9px 18px 0;
}

.admin-management-page .admin-table th,
.admin-management-page .admin-table td {
    padding: 11px 14px;
}

.admin-management-page .admin-log-grid {
    gap: 14px;
    margin: 0;
}

.admin-management-page .compact-log-list {
    max-height: 310px;
    overflow-y: auto;
    padding: 0 14px 10px;
}

.admin-management-page .compact-log-row {
    min-height: 42px;
    padding: 8px 2px;
}

@media (max-width: 900px) {
    .profile-trigger .admin-copy { display: none; }
    .admin-management-page .admin-create-form { grid-template-columns: 1fr; }
}
