:root {
    --paper: #f7f2e8;
    --ink: #1e211b;
    --muted: #667060;
    --line: #d9cdb7;
    --coal: #11140f;
    --copper: #b56332;
    --copper-dark: #7d3d20;
    --sage: #2d6c56;
    --sage-soft: #dfeee4;
    --cream: #fffaf0;
    --warning: #8b3f24;
    --shadow: 0 30px 90px rgba(40, 31, 18, 0.18);
}

* { box-sizing: border-box; }

body {
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    font-family: "Space Grotesk", "Segoe UI", sans-serif;
    background:
        radial-gradient(circle at 12% 12%, rgba(181, 99, 50, 0.22), transparent 28%),
        radial-gradient(circle at 82% 18%, rgba(45, 108, 86, 0.18), transparent 30%),
        linear-gradient(135deg, #fff7e7 0%, var(--paper) 48%, #edf2e7 100%);
}

.checkout-shell {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.8fr);
    gap: clamp(28px, 5vw, 72px);
    width: min(1180px, calc(100% - 42px));
    min-height: 100vh;
    margin: 0 auto;
    padding: 48px 0;
    align-items: center;
}

.brand-mark,
.eyebrow,
.selected-strip span,
.stage-topline,
.card-kicker,
.stage-hint {
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.brand-mark {
    display: inline-flex;
    color: var(--coal);
    font-size: 14px;
    font-weight: 800;
    text-decoration: none;
    border-bottom: 2px solid var(--copper);
}

.eyebrow {
    margin: 38px 0 10px;
    color: var(--copper-dark);
    font-size: 13px;
    font-weight: 800;
}

h1,
.package-card h2 {
    font-family: "Fraunces", Georgia, serif;
    line-height: 0.96;
}

h1 {
    max-width: 760px;
    margin: 0;
    font-size: clamp(46px, 8vw, 84px);
}

.lede {
    max-width: 660px;
    color: var(--muted);
    font-size: 18px;
}

.checkout-form {
    display: grid;
    gap: 16px;
    max-width: 720px;
    margin-top: 30px;
    padding: 20px;
    background: rgba(255, 250, 240, 0.78);
    border: 1px solid rgba(217, 205, 183, 0.9);
    border-radius: 26px;
    box-shadow: 0 14px 40px rgba(40, 31, 18, 0.08);
    backdrop-filter: blur(18px);
}

label {
    display: grid;
    gap: 7px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
}

input {
    width: 100%;
    min-height: 48px;
    padding: 12px 14px;
    color: var(--ink);
    font: inherit;
    background: #fffdf6;
    border: 1px solid var(--line);
    border-radius: 14px;
    outline: none;
}

input:focus {
    border-color: var(--copper);
    box-shadow: 0 0 0 4px rgba(181, 99, 50, 0.14);
}

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

.legal-card {
    display: grid;
    gap: 10px;
    padding: 14px;
    background: rgba(45, 108, 86, 0.08);
    border: 1px dashed rgba(45, 108, 86, 0.35);
    border-radius: 18px;
}

.check-row {
    display: grid;
    grid-template-columns: 22px 1fr;
    align-items: start;
    gap: 10px;
    color: var(--ink);
    font-size: 14px;
    font-weight: 600;
}

.check-row input {
    min-height: 18px;
    margin-top: 2px;
}

.selected-strip,
.result-box {
    border-radius: 16px;
    padding: 14px 16px;
}

.selected-strip {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    background: #fffdf6;
    border: 1px solid var(--line);
}

.selected-strip span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}

.primary-action,
.ticket-link,
.stage-controls button {
    min-height: 46px;
    padding: 0 18px;
    font: inherit;
    font-weight: 800;
    border-radius: 999px;
    cursor: pointer;
}

.primary-action {
    color: #fffaf0;
    background: var(--coal);
    border: 0;
}

.primary-action:disabled {
    cursor: not-allowed;
    opacity: 0.45;
}

.ticket-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--coal);
    text-decoration: none;
    background: var(--sage-soft);
    border: 1px solid rgba(45, 108, 86, 0.3);
}

.result-box {
    margin: 0;
    color: var(--muted);
    background: rgba(255, 255, 255, 0.58);
    border: 1px solid rgba(217, 205, 183, 0.7);
}

.result-box[data-state="ready"] {
    color: var(--sage);
    background: var(--sage-soft);
}

.result-box[data-state="blocked"],
.result-box[data-state="ticket"] {
    color: var(--warning);
    background: #fff0df;
}

.package-stage {
    position: relative;
}

.stage-topline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 900;
}

.stage-controls {
    display: flex;
    gap: 8px;
}

.stage-controls button {
    min-height: 36px;
    color: var(--coal);
    background: rgba(255, 250, 240, 0.72);
    border: 1px solid var(--line);
}

.package-card {
    min-height: 620px;
    padding: clamp(26px, 4vw, 44px);
    color: #fff8eb;
    background:
        linear-gradient(150deg, rgba(255, 255, 255, 0.08), transparent 35%),
        linear-gradient(135deg, #1b2119 0%, #26341f 44%, #8a4427 100%);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 38px;
    box-shadow: var(--shadow);
    transform: rotate(1.25deg);
    transition: transform 220ms ease, opacity 180ms ease;
    outline: none;
}

.package-card.is-switching {
    opacity: 0.45;
    transform: translateY(8px) rotate(-1deg);
}

.card-kicker {
    color: #f3c797;
    font-size: 12px;
    font-weight: 900;
}

.package-card h2 {
    margin: 18px 0;
    font-size: clamp(44px, 6vw, 76px);
}

.package-card p {
    color: rgba(255, 248, 235, 0.76);
    font-size: 17px;
}

.price-row {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin: 28px 0;
}

.price-row strong {
    font-size: 42px;
}

.variant-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 22px;
}

.variant-row button {
    padding: 9px 12px;
    color: #fff8eb;
    font: inherit;
    font-size: 13px;
    font-weight: 800;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 999px;
    cursor: pointer;
}

.variant-row button[aria-pressed="true"] {
    color: var(--coal);
    background: #f3c797;
}

.feature-list {
    display: grid;
    gap: 10px;
    margin: 0 0 24px;
    padding: 0;
    list-style: none;
}

.feature-list li {
    padding-left: 22px;
    position: relative;
    color: rgba(255, 248, 235, 0.84);
}

.feature-list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.72em;
    width: 8px;
    height: 8px;
    background: #f3c797;
    border-radius: 999px;
}

.card-status {
    margin-top: auto;
    padding: 14px;
    color: #fff8eb;
    background: rgba(0, 0, 0, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 18px;
}

.stage-hint {
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
    text-align: center;
}

@media (max-width: 920px) {
    .checkout-shell {
        grid-template-columns: 1fr;
        padding-top: 28px;
    }

    .package-stage {
        order: -1;
    }

    .package-card {
        min-height: auto;
        transform: none;
    }
}

@media (max-width: 620px) {
    .checkout-shell {
        width: min(100% - 24px, 1180px);
    }

    .field-grid,
    .selected-strip {
        grid-template-columns: 1fr;
        display: grid;
    }
}
