:root {
    --ink: #111827;
    --muted: #475467;
    --paper: #f6f2ea;
    --panel: #ffffff;
    --accent: #d97706;
    --accent-2: #1d4ed8;
    --shadow: 0 18px 48px rgba(15, 23, 42, 0.12);
}

body {
    font-family: "Trebuchet MS", "Segoe UI", sans-serif;
    color: var(--ink);
    background:
        radial-gradient(circle at 10% 20%, rgba(251, 191, 36, 0.12), transparent 48%),
        radial-gradient(circle at 90% 10%, rgba(37, 99, 235, 0.12), transparent 45%),
        linear-gradient(160deg, #fdfbf7, #f4f6fb);
    min-height: 100vh;
}

h1, h2, h3, h4, h5, h6 {
    font-family: "Georgia", "Times New Roman", serif;
    letter-spacing: 0.2px;
}

.app-nav {
    background: rgba(15, 23, 42, 0.92);
    backdrop-filter: blur(8px);
}

.app-nav .navbar-brand {
    font-weight: 700;
    letter-spacing: 0.5px;
}

.brand-logo {
    height: 32px;
    width: auto;
    aspect-ratio: 16 / 4;
    object-fit: contain;
    margin-right: 0.5rem;
    border-radius: 6px;
    border: none;
    background: transparent;
}

.nav-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.card {
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 18px;
    box-shadow: var(--shadow);
    background: var(--panel);
}

.btn {
    border-radius: 999px;
    font-weight: 600;
}

.btn-accent {
    background: var(--accent);
    border-color: var(--accent);
    color: #1f1200;
}

.btn-accent:hover {
    background: #b45309;
    border-color: #b45309;
    color: #fff8e1;
}

.btn-ghost {
    border: 1px solid rgba(15, 23, 42, 0.2);
    color: var(--ink);
    background: rgba(255, 255, 255, 0.7);
}

.btn-ghost:hover {
    background: rgba(255, 255, 255, 0.95);
}

.auth-shell {
    padding: 6vh 0;
}

.auth-card {
    padding: 2rem;
}

.eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 0.75rem;
    color: var(--muted);
    font-weight: 600;
}

.auth-intro h1 {
    font-size: clamp(2rem, 3vw, 2.75rem);
}

.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 0.75rem;
    margin-top: 1.25rem;
}

.stat-card {
    padding: 0.85rem;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(15, 23, 42, 0.08);
}

.stat-card span {
    display: block;
    font-size: 0.8rem;
    color: var(--muted);
}

.stat-card strong {
    font-size: 1.2rem;
}

.dashboard-hero {
    background: linear-gradient(135deg, rgba(29, 78, 216, 0.08), rgba(217, 119, 6, 0.1));
    border-radius: 20px;
    padding: 1.75rem;
    border: 1px solid rgba(15, 23, 42, 0.08);
}

.hero-content {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    align-items: center;
    justify-content: space-between;
}

.hero-title {
    margin-bottom: 0.35rem;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.hero-metrics {
    margin-top: 1.5rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 0.75rem;
}

.metric-card {
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 14px;
    padding: 0.9rem 1rem;
}

.metric-card .metric-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--muted);
    font-weight: 600;
}

.metric-card .metric-value {
    font-size: 1.4rem;
    font-weight: 700;
}

.risk-indicator {
    font-size: 2.4rem;
    font-weight: 700;
}

.table-responsive {
    border-radius: 12px;
    border: 1px solid rgba(15, 23, 42, 0.08);
}

.questionnaire-card {
    border: 1px dashed rgba(15, 23, 42, 0.2);
    border-radius: 16px;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.6);
}

.question-item {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    padding: 0.6rem 0;
    border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

.question-item:last-child {
    border-bottom: none;
}

.question-text {
    font-weight: 600;
    color: var(--ink);
}

.question-actions {
    display: flex;
    gap: 0.35rem;
}

@media (max-width: 768px) {
    .auth-shell {
        padding: 3rem 0;
    }
    .auth-card {
        padding: 1.5rem;
    }
    .hero-content {
        align-items: flex-start;
    }
    .question-item {
        align-items: flex-start;
        gap: 0.5rem;
    }
    .question-actions {
        width: 100%;
    }
}
