:root {
    color-scheme: light;
    --bg: #f4efe6;
    --bg-accent: #efe2cb;
    --surface: rgba(255, 251, 244, 0.86);
    --surface-strong: #fffaf2;
    --text: #1f2a37;
    --text-soft: #59687a;
    --line: rgba(31, 42, 55, 0.1);
    --brand: #0f766e;
    --brand-strong: #0b4f4a;
    --highlight: #d97706;
    --shadow: 0 24px 70px rgba(32, 41, 56, 0.12);
    --radius-lg: 28px;
    --radius-md: 20px;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: "Segoe UI Variable", "Trebuchet MS", sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(217, 119, 6, 0.18), transparent 28%),
        radial-gradient(circle at top right, rgba(15, 118, 110, 0.22), transparent 24%),
        linear-gradient(180deg, var(--bg), #f8f5ef 45%, #f2ede3 100%);
}

a {
    color: inherit;
    text-decoration: none;
}

img,
svg {
    max-width: 100%;
    height: auto;
}

.shell {
    width: min(1180px, calc(100% - 2rem));
    margin: 0 auto;
    padding: 1.5rem 0 3rem;
}

.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.25rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 250, 242, 0.72);
    backdrop-filter: blur(16px);
    box-shadow: var(--shadow);
}

.brand-copy {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.eyebrow {
    margin: 0;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--brand);
}

.brand-name {
    margin: 0;
    font-size: 1.15rem;
    font-weight: 800;
}

.topbar nav {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.nav-form {
    margin: 0;
}

.nav-button {
    border: none;
    background: transparent;
    cursor: pointer;
    font: inherit;
}

.nav-user {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    justify-content: center;
    padding: 0.65rem 1rem;
    border-radius: 999px;
    border: 1px solid rgba(31, 42, 55, 0.08);
    background: rgba(255, 255, 255, 0.58);
    color: var(--text-soft);
    font-size: 0.92rem;
    font-weight: 600;
    text-align: center;
    overflow-wrap: anywhere;
}

.nav-user-label {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--brand);
}

.nav-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.8rem;
    padding: 0.65rem 1rem;
    border-radius: 999px;
    color: var(--text-soft);
    text-align: center;
    overflow-wrap: anywhere;
    transition: background-color 180ms ease, color 180ms ease, transform 180ms ease;
}

.nav-link.is-active {
    color: var(--brand-strong);
    background: rgba(15, 118, 110, 0.14);
    box-shadow: inset 0 0 0 1px rgba(15, 118, 110, 0.12);
    font-weight: 700;
}

.nav-link:hover {
    color: var(--brand-strong);
    background: rgba(15, 118, 110, 0.12);
    transform: translateY(-1px);
}

.page-stack {
    display: grid;
    gap: 1.5rem;
    margin-top: 1.75rem;
}

.alert {
    padding: 1rem 1.2rem;
    border-radius: 1rem;
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
    font-weight: 600;
}

.alert-success {
    background: rgba(15, 118, 110, 0.12);
    color: var(--brand-strong);
}

.alert-error {
    background: rgba(185, 28, 28, 0.1);
    color: #8b1e1e;
}

.hero {
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.35);
    background:
        linear-gradient(135deg, rgba(255, 250, 242, 0.92), rgba(249, 241, 226, 0.88)),
        linear-gradient(135deg, rgba(15, 118, 110, 0.06), rgba(217, 119, 6, 0.08));
    box-shadow: var(--shadow);
}

.hero h1,
.hero h2,
.panel h2,
.panel h3,
.panel p {
    margin-top: 0;
}

.hero h1 {
    margin-bottom: 0.85rem;
    font-size: clamp(2rem, 5vw, 4rem);
    line-height: 0.98;
    letter-spacing: -0.04em;
    max-width: 10ch;
}

.hero-copy {
    max-width: 62ch;
    color: var(--text-soft);
    font-size: 1.05rem;
    line-height: 1.7;
    overflow-wrap: anywhere;
}

.hero-actions {
    display: flex;
    gap: 0.9rem;
    flex-wrap: wrap;
    margin-top: 1.5rem;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.85rem 1.2rem;
    border-radius: 999px;
    font-weight: 700;
    text-align: center;
    white-space: normal;
    transition: transform 180ms ease, box-shadow 180ms ease, background-color 180ms ease;
}

.button-primary {
    color: #f9f7f2;
    background: linear-gradient(135deg, var(--brand), var(--brand-strong));
    box-shadow: 0 16px 36px rgba(15, 118, 110, 0.22);
}

.button-secondary {
    color: var(--text);
    background: rgba(255, 255, 255, 0.58);
    border: 1px solid var(--line);
}

.button:hover {
    transform: translateY(-2px);
}

.panel {
    padding: 1.5rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--line);
    background: var(--surface);
    box-shadow: var(--shadow);
    backdrop-filter: blur(10px);
}

.grid-3 {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.stat-value {
    margin: 0.35rem 0 0.5rem;
    font-size: clamp(2rem, 4vw, 2.8rem);
    line-height: 1;
    letter-spacing: -0.05em;
}

.stat-label,
.muted {
    color: var(--text-soft);
}

.info-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.info-card {
    padding: 1.3rem;
    border-radius: 1.2rem;
    background: var(--surface-strong);
    border: 1px solid rgba(15, 118, 110, 0.08);
}

.info-card h3 {
    margin-bottom: 0.7rem;
    font-size: 1rem;
}

.info-card p {
    margin-bottom: 0;
    color: var(--text-soft);
    line-height: 1.65;
}

@media (max-width: 900px) {
    .grid-3,
    .info-grid {
        grid-template-columns: 1fr;
    }

    .topbar {
        border-radius: 1.5rem;
        align-items: stretch;
        flex-direction: column;
    }

    .topbar nav {
        width: 100%;
        display: grid;
        gap: 0.65rem;
    }

    .nav-form,
    .nav-link,
    .nav-user {
        width: 100%;
    }

    .hero {
        padding: 1.75rem;
    }

    .hero h1 {
        max-width: none;
    }
}

@media (max-width: 640px) {
    .shell {
        width: min(1180px, calc(100% - 1rem));
        padding-top: 1rem;
        padding-bottom: 2.5rem;
    }

    .topbar,
    .hero,
    .panel {
        border-radius: 1.35rem;
    }

    .hero,
    .panel {
        padding: 1.2rem;
    }

    .alert {
        padding: 0.9rem 1rem;
    }
}