* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: Inter, "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: #f4f7fb;
    color: #1f2937;
}

a {
    text-decoration: none;
    color: inherit;
}

.auth-wrapper {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 24px;
}

.auth-card {
    width: 100%;
    max-width: 420px;
    background: #ffffff;
    border-radius: 16px;
    padding: 28px;
    box-shadow: 0 18px 40px rgba(17, 24, 39, 0.08);
    border: 1px solid #e5e7eb;
}

.auth-card h1 {
    font-size: 1.5rem;
    margin-bottom: 8px;
}

.muted {
    color: #6b7280;
    font-size: 0.92rem;
    margin-bottom: 18px;
}

.form-group {
    margin-bottom: 14px;
}

.form-group label {
    display: block;
    font-size: 0.9rem;
    margin-bottom: 6px;
    color: #374151;
    font-weight: 600;
}

.input,
.select {
    width: 100%;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    padding: 11px 12px;
    font-size: 0.95rem;
    background: #ffffff;
}

.radio-button-group {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.radio-btn {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.radio-option {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 11px 12px;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    background: #ffffff;
    color: #111827;
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0;
    cursor: pointer;
    transition: all 0.15s ease;
}

.radio-btn:checked + .radio-option {
    background: #2563eb;
    border-color: #2563eb;
    color: #ffffff;
}

.btn {
    border: none;
    border-radius: 10px;
    padding: 11px 14px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
}

.btn-primary {
    background: #2563eb;
    color: #ffffff;
}

.btn-danger {
    background: #dc2626;
    color: #ffffff;
}

.btn-secondary {
    background: #e5e7eb;
    color: #111827;
}

.btn-block {
    width: 100%;
}

.shell {
    display: grid;
    grid-template-columns: 240px 1fr;
    min-height: 100vh;
}

.sidebar {
    background: #111827;
    color: #f9fafb;
    padding: 22px 14px;
}

.brand {
    padding: 10px 12px 18px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    margin-bottom: 18px;
}

.brand h2 {
    font-size: 1.1rem;
    font-weight: 700;
}

.brand p {
    margin-top: 4px;
    font-size: 0.8rem;
    color: #9ca3af;
}

.menu {
    list-style: none;
    display: grid;
    gap: 6px;
}

.menu a {
    display: block;
    padding: 10px 12px;
    border-radius: 9px;
    color: #d1d5db;
    font-size: 0.92rem;
}

.menu a:hover,
.menu a.active {
    background: #1f2937;
    color: #ffffff;
}

.menu-toggle,
.menu-close {
    border: 1px solid #d1d5db;
    background: #ffffff;
    color: #111827;
    border-radius: 8px;
    font-size: 1.1rem;
    line-height: 1;
    padding: 8px 10px;
    cursor: pointer;
}

.menu-close {
    display: none;
}

.menu-backdrop {
    display: none;
}

.main {
    padding: 24px;
}

.topbar {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 14px 18px;
    margin-bottom: 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.topbar h1 {
    font-size: 1.15rem;
}

.topbar small {
    color: #6b7280;
}

.grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 16px;
}

.card {
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    padding: 16px;
}

.kpi {
    grid-column: span 4;
}

.kpi h3 {
    font-size: 0.88rem;
    color: #6b7280;
    margin-bottom: 8px;
}

.kpi p {
    font-size: 1.4rem;
    font-weight: 700;
}

.wide {
    grid-column: span 8;
}

.medium {
    grid-column: span 6;
}

.full {
    grid-column: span 12;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.92rem;
}

th,
td {
    text-align: left;
    padding: 10px 8px;
    border-bottom: 1px solid #e5e7eb;
}

th {
    color: #6b7280;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.status {
    display: inline-block;
    background: #dcfce7;
    color: #166534;
    font-size: 0.78rem;
    padding: 4px 8px;
    border-radius: 999px;
}

.status.warning {
    background: #fef3c7;
    color: #92400e;
}

.actions {
    display: flex;
    gap: 10px;
}

@media (max-width: 1000px) {
    .shell {
        grid-template-columns: 1fr;
        position: relative;
    }

    .sidebar {
        padding: 14px 12px;
        position: fixed;
        top: 0;
        left: 0;
        height: 100vh;
        width: 260px;
        z-index: 30;
        transform: translateX(-100%);
        transition: transform 0.2s ease;
    }

    .shell.menu-open .sidebar {
        transform: translateX(0);
    }

    .menu-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(17, 24, 39, 0.38);
        z-index: 20;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.2s ease;
    }

    .shell.menu-open .menu-backdrop {
        opacity: 1;
        visibility: visible;
    }

    .brand {
        padding: 6px 8px 12px;
        margin-bottom: 10px;
    }

    .menu {
        display: grid;
        gap: 8px;
    }

    .menu a {
        white-space: normal;
        padding: 12px 14px;
        border: 1px solid rgba(255, 255, 255, 0.18);
    }

    .menu-close {
        display: inline-block;
        margin-bottom: 10px;
    }

    .main {
        padding: 14px;
    }

    .topbar {
        flex-direction: row;
        align-items: center;
        gap: 10px;
        padding: 12px 14px;
    }

    .topbar small {
        margin-left: auto;
    }

    .actions {
        flex-wrap: wrap;
    }

    .kpi,
    .wide,
    .medium,
    .full {
        grid-column: span 12;
    }
}