:root {
    --ink-900: #182436;
    --ink-700: #3f5472;
    --ink-500: #71849d;
    --paper: #f8f1e8;
    --card: rgba(255, 250, 244, 0.88);
    --white: #ffffff;
    --accent: #c45f43;
    --accent-deep: #8c3a29;
    --border: rgba(24, 36, 54, 0.1);
    --shadow: 0 24px 60px rgba(24, 36, 54, 0.12);
    --radius: 28px;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: "Avenir Next", "Segoe UI", sans-serif;
    color: var(--ink-900);
    background:
        radial-gradient(circle at top left, rgba(196, 95, 67, 0.18), transparent 22%),
        radial-gradient(circle at bottom right, rgba(36, 88, 124, 0.12), transparent 24%),
        linear-gradient(180deg, #fbf7f2 0%, var(--paper) 100%);
    min-height: 100vh;
}

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

.site-shell,
.dashboard-shell {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    padding: 24px 0 40px;
}

.compact-shell {
    display: grid;
    gap: 42px;
}

.topbar,
.dashboard-card {
    background: var(--card);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
    backdrop-filter: blur(16px);
}

.compact-topbar {
    border-radius: 999px;
    padding: 16px 18px;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 22px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 14px;
}

.brand img {
    width: 46px;
    height: 46px;
}

.brand strong {
    display: block;
    font-size: 18px;
}

.brand span {
    display: block;
    color: var(--ink-500);
    font-size: 13px;
}

.menu-cluster,
.top-actions {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.dropdown {
    position: relative;
}

.dropdown-toggle,
.top-actions a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    border-radius: 999px;
    border: 1px solid transparent;
    background: transparent;
    color: var(--ink-700);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.dropdown-toggle::after {
    content: "▾";
    font-size: 12px;
    opacity: 0.7;
}

.dropdown-toggle.active,
.top-actions a.active {
    background: var(--ink-900);
    color: var(--white);
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    min-width: 180px;
    padding: 10px;
    border-radius: 22px;
    border: 1px solid var(--border);
    background: rgba(255, 250, 244, 0.98);
    box-shadow: 0 20px 42px rgba(24, 36, 54, 0.14);
    display: none;
    z-index: 20;
}

.dropdown:hover .dropdown-menu,
.dropdown:focus-within .dropdown-menu {
    display: grid;
    gap: 6px;
}

.dropdown-menu a {
    border-radius: 14px;
    padding: 12px 14px;
    color: var(--ink-700);
    font-weight: 600;
}

.dropdown-menu a:hover {
    background: rgba(24, 36, 54, 0.06);
    color: var(--ink-900);
}

.flag-actions a span:first-child {
    font-size: 16px;
}

.center-stage {
    min-height: calc(100vh - 180px);
    display: grid;
    place-items: center;
}

.form-stage {
    width: min(760px, 100%);
}

.empty-stage {
    min-height: 420px;
}

.form-shell {
    display: grid;
    gap: 16px;
}

.centered-form {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 34px;
}

.centered-form h2,
.feature-card h2,
.profile-card h2 {
    margin: 0 0 6px;
    font-size: 28px;
    line-height: 1.1;
}

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

label {
    display: grid;
    gap: 8px;
}

label span {
    color: var(--ink-700);
    font-size: 13px;
    font-weight: 700;
}

input,
textarea {
    width: 100%;
    padding: 14px 16px;
    border-radius: 16px;
    border: 1px solid rgba(24, 36, 54, 0.12);
    background: rgba(255, 255, 255, 0.84);
    color: var(--ink-900);
    font: inherit;
}

textarea {
    min-height: 110px;
    resize: vertical;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 18px;
    border-radius: 16px;
    font-weight: 700;
    transition: transform 0.16s ease;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent), var(--accent-deep));
    color: var(--white);
}

.btn-secondary {
    background: var(--white);
    border: 1px solid var(--border);
}

.btn.block {
    width: 100%;
}

.notice {
    margin-bottom: 14px;
    padding: 14px 16px;
    border-radius: 18px;
    font-weight: 600;
}

.notice.success {
    background: rgba(38, 139, 92, 0.12);
    color: #0d7b4a;
}

.notice.error {
    background: rgba(196, 95, 67, 0.12);
    color: var(--accent-deep);
}

.eyebrow {
    display: inline-flex;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(196, 95, 67, 0.12);
    color: var(--accent);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.dashboard-card {
    padding: 30px;
    border-radius: var(--radius);
}

.dashboard-top {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: flex-start;
}

.dashboard-actions {
    display: grid;
    gap: 10px;
}

.feature-card,
.profile-card,
.info-banner {
    margin-top: 24px;
    padding: 22px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid var(--border);
}

.feature-card ul {
    margin: 0;
    padding-left: 18px;
    color: var(--ink-700);
    line-height: 1.8;
}

.profile-card dl {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    margin: 0;
}

.profile-card dt {
    color: var(--ink-500);
    font-size: 13px;
    margin-bottom: 6px;
}

.profile-card dd {
    margin: 0;
    font-weight: 700;
}

@media (max-width: 980px) {
    .compact-topbar {
        grid-template-columns: 1fr;
        justify-items: start;
        border-radius: 34px;
    }

    .menu-cluster,
    .top-actions {
        flex-wrap: wrap;
    }

    .center-stage {
        min-height: auto;
    }

    .empty-stage {
        min-height: 280px;
    }
}

@media (max-width: 720px) {
    .site-shell,
    .dashboard-shell {
        width: min(100% - 20px, 100%);
    }

    .centered-form,
    .dashboard-card {
        padding: 22px;
    }

    .field-grid,
    .profile-card dl {
        grid-template-columns: 1fr;
    }

    .dropdown-menu {
        position: static;
        margin-top: 8px;
    }

    .dropdown:hover .dropdown-menu,
    .dropdown:focus-within .dropdown-menu {
        display: grid;
    }
}
