:root {
    --bg: #0c1016;
    --bg-soft: #121823;
    --panel: rgba(20, 27, 37, 0.9);
    --panel-soft: rgba(26, 34, 46, 0.9);
    --panel-premium: rgba(36, 31, 20, 0.88);
    --panel-light: #f7f1e6;
    --text: #ecf0f5;
    --text-soft: #d7dde7;
    --muted: #9ea8b6;
    --muted-strong: #bcc5d2;
    --heading: #f6f8fb;
    --gold: #c9a463;
    --gold-soft: #e6ca98;
    --gold-deep: #9a7336;
    --line: rgba(255, 255, 255, 0.08);
    --line-strong: rgba(255, 255, 255, 0.14);
    --danger: #e07a7a;
    --success: #63c487;
    --warning: #f2ca71;
    --shadow: 0 24px 56px rgba(2, 6, 13, 0.32);
    --radius: 24px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 96px;
}

body {
    margin: 0;
    font-family: 'Inter', sans-serif;
    font-size: 14.5px;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    background:
        radial-gradient(circle at top right, rgba(201, 164, 99, 0.09), transparent 24%),
        radial-gradient(circle at top left, rgba(92, 122, 173, 0.08), transparent 28%),
        linear-gradient(180deg, #0b1016 0%, #101621 50%, #0d131c 100%);
    color: var(--text);
}

a {
    color: var(--gold-soft);
    text-decoration: none;
}

a:hover {
    color: #f0dcb4;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 2px solid rgba(201, 164, 99, 0.45);
    outline-offset: 3px;
}

img,
iframe {
    max-width: 100%;
}

h1,
h2,
h3,
h4 {
    margin-top: 0;
    margin-bottom: 0.55em;
    line-height: 1.14;
    letter-spacing: -0.02em;
    text-wrap: balance;
    font-family: 'Newsreader', serif;
    color: var(--heading);
}

h1 {
    font-size: clamp(1.85rem, 3.4vw, 2.85rem);
}

h2 {
    font-size: clamp(1.34rem, 2vw, 1.82rem);
}

h3 {
    font-size: clamp(1.02rem, 1.2vw, 1.18rem);
}

h4 {
    font-size: 0.94rem;
    line-height: 1.3;
}

p {
    margin: 0 0 1rem;
    font-size: 0.92rem;
    line-height: 1.68;
    color: var(--text-soft);
}

strong {
    font-size: 0.95rem;
}

small,
.muted {
    color: var(--muted);
    font-size: 0.82rem;
}

.page-shell {
    min-height: 100vh;
}

.container {
    width: min(1180px, calc(100vw - 40px));
    margin: 0 auto;
}

.desktop-only {
    display: block;
}

.mobile-only {
    display: none;
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(20px);
    background: rgba(10, 14, 20, 0.82);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.nav-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 16px 0;
}

.brand {
    display: flex;
    align-items: center;
    gap: 14px;
    color: var(--text);
    min-width: 0;
}

.brand strong {
    display: block;
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: var(--heading);
}

.brand small {
    display: block;
    color: var(--muted);
    font-size: 0.76rem;
}

.brand-mark {
    width: 48px;
    height: 48px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    font-family: 'Inter', sans-serif;
    font-weight: 800;
    font-size: 0.95rem;
    letter-spacing: 0.04em;
    color: #111722;
    background: linear-gradient(145deg, #f2deb5, var(--gold));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.32), 0 12px 26px rgba(110, 81, 34, 0.2);
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 18px;
}

.main-nav a {
    font-weight: 600;
    font-size: 0.86rem;
    color: var(--muted-strong);
    white-space: nowrap;
    transition: color 0.18s ease;
}

.main-nav a:hover {
    color: var(--heading);
}

.nav-button,
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: 999px;
    padding: 10px 16px;
    font-weight: 600;
    font-size: 0.85rem;
    line-height: 1.22;
    text-align: center;
    text-wrap: balance;
    border: 1px solid transparent;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
    cursor: pointer;
}

.button {
    white-space: normal;
}

.nav-button {
    white-space: nowrap;
}

.nav-button,
.button-primary {
    color: #10151d;
    background: linear-gradient(135deg, #ecd7ab, var(--gold));
    box-shadow: 0 12px 28px rgba(108, 80, 35, 0.2);
}

.button-secondary {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.1);
    color: var(--heading);
}

.button-secondary:hover,
.button-ghost:hover {
    border-color: rgba(201, 164, 99, 0.3);
}

.button-ghost {
    background: transparent;
    border-color: rgba(255, 255, 255, 0.1);
    color: var(--muted-strong);
}

.button-danger {
    background: rgba(224, 122, 122, 0.12);
    border-color: rgba(224, 122, 122, 0.22);
    color: #ffd6d6;
}

.button:hover,
.nav-button:hover {
    transform: translateY(-1px);
}

.button.small {
    padding: 8px 12px;
    font-size: 0.78rem;
}

.full-width {
    width: 100%;
}

.menu-toggle {
    display: none;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--heading);
    padding: 10px 14px;
    border-radius: 14px;
}

.flash-stack {
    padding-top: 18px;
}

.flash {
    margin-bottom: 12px;
    padding: 14px 18px;
    border-radius: 16px;
    border: 1px solid;
    font-size: 0.88rem;
}

.flash-success {
    background: rgba(99, 196, 135, 0.12);
    border-color: rgba(99, 196, 135, 0.22);
}

.flash-danger {
    background: rgba(224, 122, 122, 0.12);
    border-color: rgba(224, 122, 122, 0.22);
}

.flash-warning {
    background: rgba(242, 202, 113, 0.12);
    border-color: rgba(242, 202, 113, 0.22);
}

.section {
    padding: 68px 0;
}

.hero-section {
    padding: 74px 0 58px;
}

.hero-grid,
.two-col {
    display: grid;
    grid-template-columns: minmax(0, 1.18fr) minmax(320px, 0.82fr);
    gap: 34px;
}

.align-start {
    align-items: start;
}

.hero-section h1 {
    max-width: 11.5ch;
    font-size: clamp(2rem, 3.5vw, 3.1rem);
    margin-bottom: 0.4em;
}

.hero-copy {
    max-width: 66ch;
    font-size: 0.95rem;
    color: #d7dde7;
}

.hero-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin: 24px 0 30px;
}

.hero-metrics,
.card-grid {
    display: grid;
    gap: 18px;
}

.hero-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card-grid.three-up {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card-grid.five-up {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.panel,
.metric-card {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0.01));
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
    overflow-wrap: anywhere;
}

.panel h1,
.panel h2,
.panel h3,
.panel h4,
.metric-card h1,
.metric-card h2,
.metric-card h3,
.metric-card h4,
.section-head h1,
.section-head h2,
.site-footer h3,
.site-footer h4 {
    color: var(--heading);
}

.metric-card,
.status-card,
.success-card,
.report-card,
.stat-box,
.message-card {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.metric-card strong,
.stat-box strong,
.price-card strong {
    display: block;
    font-size: 1.5rem;
    font-family: 'Newsreader', serif;
    color: var(--gold-soft);
}

.metric-card span,
.stat-box span {
    color: var(--muted);
    font-size: 0.86rem;
    line-height: 1.55;
}

.premium-panel {
    background: linear-gradient(180deg, rgba(201, 164, 99, 0.12), rgba(24, 21, 16, 0.95));
    border-color: rgba(201, 164, 99, 0.18);
}

.hero-section .premium-panel {
    align-self: start;
}

.dark-panel {
    background: linear-gradient(180deg, rgba(43, 51, 66, 0.92), rgba(21, 28, 39, 0.94));
}

.disclaimer-panel {
    background: linear-gradient(180deg, rgba(224, 122, 122, 0.08), rgba(20, 25, 34, 0.96));
    border-color: rgba(224, 122, 122, 0.18);
}

.eyebrow,
.pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    width: fit-content;
    padding: 7px 12px;
    border-radius: 999px;
    background: rgba(201, 164, 99, 0.1);
    border: 1px solid rgba(201, 164, 99, 0.18);
    color: var(--gold-soft);
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    font-size: 0.64rem;
}

.pill-status {
    white-space: nowrap;
}

.price-card {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 18px 20px;
    margin-top: 20px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.price-card span,
.price-card small {
    color: var(--muted-strong);
}

.feature-list,
.step-list {
    margin: 0;
    padding-left: 18px;
    color: var(--text-soft);
    line-height: 1.68;
    font-size: 0.9rem;
}

.feature-list li::marker,
.step-list li::marker {
    color: var(--gold-soft);
}

.compact li {
    margin-bottom: 6px;
}

.section-head {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: start;
    margin-bottom: 28px;
}

.section-head > div {
    max-width: 62ch;
}

.section-head p,
.panel p,
.message-card p {
    max-width: 68ch;
}

.story-meta {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: auto;
    padding-top: 18px;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.84rem;
}

.story-meta strong {
    font-size: 0.93rem;
    color: var(--gold-soft);
}

.soft-bg {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.015), rgba(255, 255, 255, 0.005));
}

.narrow {
    max-width: 720px;
}

.form-panel form,
.inline-form {
    display: grid;
    gap: 16px;
}

label {
    display: grid;
    gap: 8px;
    font-size: 0.84rem;
    font-weight: 600;
    color: var(--muted-strong);
}

input,
textarea,
select {
    width: 100%;
    padding: 11px 13px;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    font: inherit;
}

textarea {
    resize: vertical;
}

input:focus,
textarea:focus,
select:focus {
    outline: 2px solid rgba(201, 164, 99, 0.22);
    border-color: rgba(201, 164, 99, 0.4);
}

.checkbox-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.checkbox-row input {
    width: auto;
}

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

.stack-list {
    display: grid;
    gap: 16px;
}

.stack-list > .list-row {
    padding: 16px 0;
    border-top: 1px solid var(--line);
}

.stack-list > .list-row:first-child {
    padding-top: 0;
    border-top: 0;
}

.list-row,
.message-card,
.admin-nav {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: center;
}

.align-start {
    align-items: start;
}

.locked-label {
    color: var(--muted);
    font-weight: 700;
    font-size: 0.82rem;
}

.top-space {
    margin-top: 26px;
}

.top-space-small {
    margin-top: 16px;
}

.report-frame iframe {
    width: 100%;
    height: 78vh;
    border: 0;
    border-radius: 16px;
    background: #fff;
}

.report-meta-card {
    margin-bottom: 22px;
    background: rgba(255, 255, 255, 0.03);
}

.admin-nav {
    flex-wrap: wrap;
    margin-bottom: 26px;
    padding: 14px;
    background: rgba(255, 255, 255, 0.02);
}

.admin-nav a {
    padding: 9px 13px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    color: var(--muted-strong);
    font-size: 0.82rem;
    white-space: nowrap;
    background: rgba(255, 255, 255, 0.02);
}

.admin-nav a:hover {
    color: var(--heading);
    border-color: rgba(201, 164, 99, 0.22);
}

.table-panel {
    overflow: hidden;
}

.table-wrap {
    overflow-x: auto;
}

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

th,
td {
    text-align: left;
    padding: 12px 10px;
    border-bottom: 1px solid var(--line);
    vertical-align: top;
    font-size: 0.86rem;
    overflow-wrap: anywhere;
}

th {
    color: var(--muted-strong);
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.button-stack {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.message-card {
    padding: 20px 22px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.02);
    align-items: start;
}

.message-header {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    width: 100%;
}

.helper-text {
    color: var(--muted);
    margin-top: 18px;
    font-size: 0.85rem;
}

.empty-state {
    text-align: left;
}

.status-card .button,
.report-card .button {
    margin-top: auto;
}

.report-card small,
.success-card small,
.status-card small {
    display: inline-block;
}

.site-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 30px 0 42px;
    margin-top: 30px;
    background: rgba(7, 10, 16, 0.7);
}

.site-footer p,
.site-footer .muted {
    color: var(--muted);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1.3fr;
    gap: 30px;
}

@media (max-width: 1120px) {
    .hero-grid,
    .two-col,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .card-grid.three-up {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .card-grid.five-up {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .hero-metrics {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 820px) {
    body.nav-open {
        overflow: hidden;
    }

    .container {
        width: min(1180px, calc(100vw - 26px));
    }

    .nav-wrap {
        padding: 14px 0;
    }

    .brand {
        gap: 10px;
    }

    .brand strong,
    .brand small {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .brand-mark {
        width: 44px;
        height: 44px;
        border-radius: 15px;
        font-size: 0.9rem;
    }

    .menu-toggle {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        font-weight: 700;
    }

    .main-nav {
        position: fixed;
        top: 76px;
        right: 12px;
        left: 12px;
        max-height: calc(100vh - 92px);
        overflow-y: auto;
        padding: 18px;
        border: 1px solid rgba(255, 255, 255, 0.08);
        border-radius: 24px;
        background: rgba(10, 14, 20, 0.98);
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        box-shadow: var(--shadow);
    }

    body.nav-open .main-nav {
        display: flex;
    }

    .main-nav a,
    .main-nav .nav-button {
        width: 100%;
        justify-content: center;
        padding: 12px 14px;
        border-radius: 16px;
        background: rgba(255, 255, 255, 0.03);
        border: 1px solid rgba(255, 255, 255, 0.08);
        font-size: 0.86rem;
    }

    .main-nav .nav-button {
        margin-top: 4px;
    }

    .grid-2,
    .hero-metrics,
    .card-grid.three-up,
    .card-grid.five-up,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .section {
        padding: 50px 0;
    }

    .hero-section {
        padding-top: 46px;
    }

    .hero-actions,
    .button-stack,
    .story-meta,
    .section-head,
    .list-row,
    .message-header {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-actions .button,
    .list-row .button,
    .list-row form,
    .button-stack .button,
    .button-stack form,
    .button-stack a {
        width: 100%;
    }

    .section-head {
        margin-bottom: 22px;
    }

    .story-meta {
        gap: 10px;
    }

    .story-meta strong {
        font-size: 1.02rem;
    }

    .admin-nav {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 8px;
        -webkit-overflow-scrolling: touch;
    }

    .admin-nav a {
        white-space: nowrap;
        flex: 0 0 auto;
    }

    .message-card,
    .panel,
    .metric-card {
        padding: 20px;
    }

    .report-frame iframe {
        height: 68vh;
    }

    .responsive-table thead {
        display: none;
    }

    .responsive-table,
    .responsive-table tbody,
    .responsive-table tr,
    .responsive-table td {
        display: block;
        width: 100%;
    }

    .responsive-table tr {
        padding: 14px 0;
        border-bottom: 1px solid var(--line);
    }

    .responsive-table td {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
        gap: 12px;
        border-bottom: 0;
        padding: 8px 0;
    }

    .responsive-table td::before {
        content: attr(data-label);
        color: var(--muted-strong);
        font-weight: 700;
        font-size: 0.78rem;
        letter-spacing: 0.03em;
        text-transform: uppercase;
        flex: 0 0 84px;
    }

    .responsive-table td form,
    .responsive-table td .button,
    .responsive-table td .pill {
        margin-left: auto;
    }

    .desktop-only {
        display: none;
    }

    .mobile-only {
        display: block;
    }
}

@media (max-width: 640px) {
    h1 {
        font-size: clamp(1.6rem, 6.5vw, 2.08rem);
    }

    h2 {
        font-size: clamp(1.2rem, 5.4vw, 1.56rem);
    }

    h3 {
        font-size: 0.98rem;
    }

    .container {
        width: min(1180px, calc(100vw - 20px));
    }

    .brand small {
        display: none;
    }

    .hero-copy {
        font-size: 0.9rem;
    }

    .button,
    .nav-button {
        min-height: 42px;
        font-size: 0.82rem;
        padding: 9px 14px;
    }

    .panel,
    .metric-card,
    .message-card {
        padding: 16px;
        border-radius: 20px;
    }

    .price-card strong,
    .metric-card strong,
    .stat-box strong {
        font-size: 1.34rem;
    }

    .hero-actions {
        margin-bottom: 26px;
    }

    .feature-list,
    .step-list {
        padding-left: 18px;
    }

    .responsive-table td {
        flex-direction: column;
        gap: 8px;
    }

    .responsive-table td::before {
        flex: none;
    }

    .responsive-table td form,
    .responsive-table td .button,
    .responsive-table td .pill {
        margin-left: 0;
    }
}
