:root {
    --sidebar: #17233d;
    --line: #e8edf3;
    --text: #243044;
    --muted: #7a8699;
    --bg: #f5f7fb;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    color: var(--text);
    background: var(--bg);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", Arial, sans-serif;
}

a {
    color: inherit;
    text-decoration: none;
}

.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 16px;
    background: linear-gradient(135deg, #f7fbff 0%, #edf4fa 48%, #f8f0e8 100%);
}

.login-box {
    width: min(420px, 100%);
    padding: 34px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: 0 22px 60px rgba(23, 35, 61, .12);
}

.login-title {
    margin: 0 0 6px;
    font-size: 24px;
    font-weight: 700;
}

.login-subtitle {
    margin: 0 0 28px;
    color: var(--muted);
}

.form-row {
    margin-bottom: 18px;
}

.form-row label {
    display: block;
    margin-bottom: 8px;
    color: #4b5870;
}

.form-row input {
    width: 100%;
    height: 42px;
    padding: 0 12px;
    border: 1px solid #d8e0ea;
    border-radius: 6px;
    outline: none;
}

.form-row input:focus {
    border-color: #1f8efa;
    box-shadow: 0 0 0 3px rgba(31, 142, 250, .12);
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 38px;
    padding: 0 16px;
    border: 0;
    border-radius: 6px;
    color: #fff;
    background: #1f8efa;
    cursor: pointer;
}

.button.block {
    width: 100%;
    height: 44px;
}

.button.secondary {
    color: #243044;
    background: #eef3f8;
}

.layout {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 230px 1fr;
}

.sidebar {
    background: var(--sidebar);
    color: #d9e4f2;
}

.brand {
    height: 64px;
    display: flex;
    align-items: center;
    padding: 0 22px;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
    font-size: 18px;
    font-weight: 700;
    color: #fff;
}

.nav-section {
    padding: 12px;
}

.nav-group-title,
.nav-link {
    display: block;
    padding: 10px 12px;
    border-radius: 6px;
}

.nav-group-title {
    margin-top: 4px;
    color: #fff;
    font-weight: 600;
}

.nav-link {
    margin: 2px 0 2px 12px;
    color: #b8c7dc;
}

.nav-link:hover {
    color: #fff;
    background: rgba(255, 255, 255, .08);
}

.main {
    min-width: 0;
}

.topbar {
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    background: #fff;
    border-bottom: 1px solid var(--line);
}

.content {
    padding: 24px;
}

.page-title {
    margin: 0 0 18px;
    font-size: 22px;
}

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

.card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 18px;
}

.metric-label {
    color: var(--muted);
    font-size: 13px;
}

.metric-value {
    margin-top: 8px;
    font-size: 28px;
    font-weight: 700;
}

.notice {
    margin-bottom: 18px;
    padding: 12px 14px;
    border: 1px solid #f1d7a5;
    border-radius: 6px;
    color: #7a5311;
    background: #fff7e7;
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 12px;
    border-bottom: 1px solid var(--line);
    text-align: left;
}

.muted {
    color: var(--muted);
}

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

    .sidebar {
        display: none;
    }

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

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

    .content {
        padding: 16px;
    }
}
