:root {
    --ink: #1d2425;
    --forest: #163f38;
    --forest-dark: #0e2a26;
    --cream: #f3eddf;
    --paper: #fffdf7;
    --orange: #ce633f;
    --orange-dark: #a9442d;
    --sage: #9fbaaa;
    --muted: #5e6a67;
    --line: #ded5c6;
    --line-strong: #c5b8a7;
    --danger: #a33a34;
    --danger-soft: #f8e5df;
    --success: #28624e;
    --shadow: 0 28px 80px rgba(22, 42, 38, 0.15);
    --sans: "Figtree", "Trebuchet MS", sans-serif;
    --serif: "Bodoni Moda", "Iowan Old Style", "Palatino Linotype", serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background:
        radial-gradient(circle at 86% 8%, rgba(206, 99, 63, 0.17), transparent 27rem),
        radial-gradient(circle at -6% 52%, rgba(22, 63, 56, 0.11), transparent 34rem),
        var(--cream);
    color: var(--ink);
    font-family: var(--sans);
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

body::before {
    position: fixed;
    z-index: -1;
    inset: 0;
    background-image: linear-gradient(120deg, rgba(22, 63, 56, 0.028) 1px, transparent 1px),
        linear-gradient(30deg, rgba(22, 63, 56, 0.022) 1px, transparent 1px);
    background-size: 54px 54px;
    content: "";
    pointer-events: none;
}

[hidden] {
    display: none !important;
}

a {
    color: inherit;
}

button,
input,
textarea {
    font: inherit;
}

button {
    cursor: pointer;
}

::selection {
    background: rgba(217, 119, 69, 0.28);
}

.skip-link {
    position: fixed;
    z-index: 100;
    top: 0.75rem;
    left: 0.75rem;
    padding: 0.65rem 0.9rem;
    border-radius: 0.4rem;
    background: var(--ink);
    color: white;
    transform: translateY(-160%);
}

.skip-link:focus {
    transform: translateY(0);
}

.site-header {
    display: flex;
    width: min(1180px, calc(100% - 40px));
    min-height: 92px;
    margin: 0 auto;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid rgba(22, 63, 56, 0.17);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.72rem;
    color: var(--forest);
    font-size: 1.08rem;
    font-weight: 700;
    letter-spacing: -0.035em;
    text-decoration: none;
}

.brand em {
    color: var(--orange-dark);
    font-style: normal;
}

.brand-mark {
    display: grid;
    width: 2.25rem;
    height: 2.25rem;
    place-items: center;
    border-radius: 0.35rem 0.35rem 0.95rem 0.35rem;
    background: linear-gradient(140deg, var(--forest), #255b4e);
    color: var(--paper);
    font-family: var(--serif);
    font-size: 1.15rem;
    font-weight: 700;
}

.header-note {
    color: var(--muted);
    font-size: 0.82rem;
    font-weight: 650;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

main {
    overflow: clip;
}

.hero {
    display: grid;
    width: min(1180px, calc(100% - 40px));
    min-height: 590px;
    margin: 0 auto;
    padding: 7rem 0 6.5rem;
    grid-template-columns: minmax(0, 1.55fr) minmax(300px, 0.75fr);
    align-items: center;
    gap: clamp(3rem, 8vw, 8rem);
}

.hero-copy,
.principle-card,
.wizard-wrap,
.how-it-works {
    animation: page-reveal 700ms both cubic-bezier(.2,.75,.25,1);
}

.principle-card { animation-delay: 110ms; }
.wizard-wrap { animation-delay: 180ms; }
.how-it-works { animation-delay: 250ms; }

@keyframes page-reveal {
    from { opacity: 0; transform: translateY(18px); }
    to { opacity: 1; transform: translateY(0); }
}

.eyebrow,
.step-kicker {
    margin: 0 0 0.75rem;
    color: var(--orange-dark);
    font-size: 0.76rem;
    font-weight: 780;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.hero h1,
.response-intro h1,
.error-page h1 {
    max-width: 760px;
    margin: 0;
    color: var(--forest-dark);
    font-family: var(--serif);
    font-size: clamp(3.5rem, 7.4vw, 6.7rem);
    font-weight: 560;
    letter-spacing: -0.07em;
    line-height: 0.88;
}

.hero h1 span,
.response-intro h1 span {
    color: var(--orange-dark);
    font-style: italic;
    text-decoration: underline;
    text-decoration-color: rgba(206, 99, 63, 0.25);
    text-decoration-thickness: 0.11em;
    text-underline-offset: 0.09em;
}

.hero-lede {
    max-width: 670px;
    margin: 2rem 0 0;
    color: #47564e;
    font-family: var(--serif);
    font-size: clamp(1.18rem, 2.2vw, 1.55rem);
    line-height: 1.55;
}

.trust-row {
    display: flex;
    margin-top: 2.2rem;
    flex-wrap: wrap;
    gap: 0.7rem;
}

.trust-row span {
    padding: 0.5rem 0.8rem;
    border: 1px solid rgba(23, 63, 53, 0.16);
    border-radius: 999px;
    background: rgba(255, 253, 247, 0.7);
    color: var(--forest);
    font-size: 0.78rem;
    font-weight: 650;
}

.principle-card {
    position: relative;
    padding: 2.5rem 2.35rem;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 0.45rem 1.7rem 0.45rem 1.7rem;
    background: linear-gradient(150deg, #173f38, #0e2a26);
    box-shadow: var(--shadow);
    color: white;
    transform: rotate(1.5deg);
}

.principle-card::after {
    position: absolute;
    right: 1rem;
    bottom: -1rem;
    width: 65%;
    height: 1.5rem;
    border-radius: 50%;
    background: rgba(15, 47, 39, 0.22);
    content: "";
    filter: blur(16px);
}

.quote-mark {
    display: block;
    height: 2.5rem;
    color: var(--orange);
    font-family: var(--serif);
    font-size: 5rem;
    line-height: 0.8;
}

.principle-card blockquote {
    margin: 1.2rem 0;
    font-family: var(--serif);
    font-size: clamp(1.6rem, 3vw, 2.25rem);
    font-style: italic;
    line-height: 1.25;
}

.principle-card p {
    margin: 0;
    color: #dce7e1;
    font-size: 0.9rem;
}

.wizard-wrap {
    width: min(960px, calc(100% - 40px));
    margin: 0 auto 8rem;
    padding: clamp(1.4rem, 4vw, 3.5rem);
    border: 1px solid var(--line);
    border-radius: 0.55rem 1.8rem 0.55rem 1.8rem;
    background: var(--paper);
    box-shadow: var(--shadow);
}

.wizard-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 2rem;
}

.wizard-heading h2,
.how-it-works h2,
.response-summary h2,
.state-view h2,
.state-view h3 {
    margin: 0;
    color: var(--forest-dark);
    font-family: var(--serif);
    font-size: clamp(2rem, 4vw, 3.25rem);
    font-weight: 500;
    letter-spacing: -0.045em;
    line-height: 1.05;
}

.step-label {
    margin: 0 0 0.3rem;
    color: var(--muted);
    font-size: 0.84rem;
    font-weight: 700;
}

.progress {
    display: grid;
    margin: 2.5rem 0 3rem;
    padding: 0;
    grid-template-columns: repeat(4, 1fr);
    list-style: none;
}

.progress li {
    position: relative;
    display: grid;
    justify-items: center;
    color: #8c968f;
    gap: 0.45rem;
}

.progress li:not(:last-child)::after {
    position: absolute;
    z-index: 0;
    top: 1rem;
    left: calc(50% + 1.15rem);
    width: calc(100% - 2.3rem);
    height: 1px;
    background: var(--line);
    content: "";
}

.progress li.is-complete:not(:last-child)::after {
    background: var(--forest);
}

.progress span {
    position: relative;
    z-index: 1;
    display: grid;
    width: 2rem;
    height: 2rem;
    place-items: center;
    border: 1px solid var(--line-strong);
    border-radius: 50%;
    background: var(--paper);
    font-size: 0.75rem;
    font-weight: 750;
}

.progress small {
    font-size: 0.72rem;
    font-weight: 660;
}

.progress .is-active {
    color: var(--forest);
}

.progress .is-active span,
.progress .is-complete span {
    border-color: var(--forest);
    background: var(--forest);
    color: white;
}

.form-step {
    animation: step-in 280ms ease-out;
}

@keyframes step-in {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.step-copy {
    max-width: 670px;
    margin-bottom: 2rem;
}

.step-copy h3 {
    margin: 0;
    color: var(--forest-dark);
    font-family: var(--serif);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 500;
    letter-spacing: -0.04em;
    line-height: 1.08;
}

.step-copy p {
    max-width: 620px;
    margin: 0.8rem 0 0;
    color: var(--muted);
}

.field {
    display: grid;
    margin: 0 0 1.4rem;
    gap: 0.5rem;
}

.field > span {
    color: var(--forest-dark);
    font-size: 0.84rem;
    font-weight: 730;
}

.field small {
    color: var(--muted);
    font-size: 0.73rem;
    text-align: right;
}

input,
textarea {
    width: 100%;
    border: 1px solid var(--line-strong);
    border-radius: 0.85rem;
    outline: none;
    background: #fff;
    color: var(--ink);
    transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

input {
    min-height: 3.35rem;
    padding: 0 1rem;
}

textarea {
    min-height: 9rem;
    padding: 0.9rem 1rem;
    line-height: 1.55;
    resize: vertical;
}

input::placeholder,
textarea::placeholder {
    color: #9ba39e;
}

input:focus,
textarea:focus {
    border-color: var(--forest);
    box-shadow: 0 0 0 4px rgba(23, 63, 53, 0.1);
}

input.is-invalid,
textarea.is-invalid {
    border-color: var(--danger);
    background: #fffaf9;
    box-shadow: 0 0 0 3px rgba(163, 58, 52, 0.09);
}

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

.actions {
    display: flex;
    margin-top: 2rem;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.actions-end {
    justify-content: flex-end;
}

.button {
    display: inline-flex;
    min-height: 3rem;
    padding: 0.72rem 1.25rem;
    align-items: center;
    justify-content: center;
    border: 1px solid transparent;
    border-radius: 0.45rem;
    font-size: 0.88rem;
    font-weight: 720;
    letter-spacing: 0.01em;
    gap: 0.65rem;
    text-decoration: none;
    transition: transform 160ms ease, background 160ms ease, border-color 160ms ease;
}

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

.button:focus-visible,
.choice-card:has(input:focus-visible) {
    outline: 3px solid rgba(217, 119, 69, 0.32);
    outline-offset: 3px;
}

.button:disabled {
    cursor: wait;
    opacity: 0.62;
    transform: none;
}

.button-primary {
    background: var(--forest);
    color: white;
    box-shadow: 3px 3px 0 var(--orange);
}

.button-primary:hover {
    background: var(--forest-dark);
    box-shadow: 5px 5px 0 var(--orange);
}

.button-quiet {
    border-color: var(--line);
    background: transparent;
    color: var(--forest);
}

.button-quiet:hover {
    border-color: var(--forest);
    background: rgba(23, 63, 53, 0.04);
}

.privacy-card,
.fairness-note,
.invite-note {
    display: flex;
    padding: 1rem 1.1rem;
    border: 1px solid #d5e0da;
    border-radius: 0.8rem;
    background: #f4f8f5;
    color: #43544b;
    font-size: 0.83rem;
    gap: 0.8rem;
}

.privacy-card span,
.invite-note .choice-icon {
    color: var(--orange-dark);
    font-weight: 800;
}

.privacy-card p,
.fairness-note,
.invite-note p {
    margin: 0;
}

.choice-group {
    display: grid;
    margin: 0 0 1.5rem;
    padding: 0;
    border: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.9rem;
}

.choice-card {
    display: flex;
    min-height: 8rem;
    padding: 1.2rem;
    align-items: flex-start;
    border: 1px solid var(--line);
    border-radius: 0.4rem 1rem 0.4rem 1rem;
    background: #fff;
    cursor: pointer;
    gap: 0.9rem;
    transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.choice-card:hover {
    border-color: var(--sage);
    transform: translateY(-1px);
}

.choice-card.is-selected {
    border-color: var(--forest);
    background: #f2f7f4;
    box-shadow: inset 0 0 0 1px var(--forest);
}

.choice-card input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.choice-card > span:last-child {
    display: grid;
    gap: 0.35rem;
}

.choice-card strong {
    color: var(--forest-dark);
    font-size: 0.92rem;
}

.choice-card small {
    color: var(--muted);
    font-size: 0.76rem;
    line-height: 1.45;
}

.choice-icon {
    display: grid;
    width: 2rem;
    height: 2rem;
    flex: 0 0 2rem;
    place-items: center;
    border-radius: 50%;
    background: rgba(217, 119, 69, 0.13);
    color: var(--orange-dark);
    font-weight: 800;
}

.alert {
    margin: 1.2rem 0;
    padding: 0.85rem 1rem;
    border-radius: 0.7rem;
    font-size: 0.85rem;
}

.alert-error {
    border: 1px solid #e7b8b1;
    background: var(--danger-soft);
    color: var(--danger);
}

.state-view {
    max-width: 610px;
    margin: 1rem auto;
    padding: 4rem 1rem;
    text-align: center;
}

.state-view.compact {
    padding: 3.5rem 1.25rem;
}

.state-view p:not(.eyebrow) {
    max-width: 520px;
    margin: 1rem auto 0;
    color: var(--muted);
}

.state-view .button {
    margin-top: 1.8rem;
}

.pulse-mark,
.success-mark,
.error-mark {
    display: grid;
    width: 4.2rem;
    height: 4.2rem;
    margin: 0 auto 1.5rem;
    place-items: center;
    border-radius: 50%;
}

.pulse-mark {
    position: relative;
    border: 1px solid rgba(23, 63, 53, 0.25);
    background: #f2f7f4;
}

.pulse-mark::before,
.pulse-mark::after,
.pulse-mark span {
    position: absolute;
    border: 1px solid var(--forest);
    border-radius: 50%;
    content: "";
    animation: pulse 1.8s ease-out infinite;
}

.pulse-mark::before {
    width: 1rem;
    height: 1rem;
}

.pulse-mark span {
    width: 2rem;
    height: 2rem;
    animation-delay: 0.25s;
}

.pulse-mark::after {
    width: 3rem;
    height: 3rem;
    animation-delay: 0.5s;
}

@keyframes pulse {
    0% { opacity: 0.9; transform: scale(0.7); }
    80%, 100% { opacity: 0; transform: scale(1.25); }
}

.success-mark {
    background: var(--success);
    color: white;
    font-size: 1.7rem;
    font-weight: 800;
}

.error-mark {
    background: var(--danger-soft);
    color: var(--danger);
    font-family: var(--serif);
    font-size: 2rem;
    font-weight: 700;
}

.analysis-track {
    width: min(420px, 85%);
    height: 4px;
    margin: 2rem auto 0;
    overflow: hidden;
    border-radius: 99px;
    background: #dce4df;
}

.analysis-track span {
    display: block;
    width: 42%;
    height: 100%;
    border-radius: inherit;
    background: var(--orange);
    animation: tracking 1.8s ease-in-out infinite alternate;
}

@keyframes tracking {
    from { transform: translateX(-20%); }
    to { transform: translateX(160%); }
}

.how-it-works {
    display: grid;
    width: min(1180px, calc(100% - 40px));
    margin: 0 auto 8rem;
    grid-template-columns: 0.85fr 1.15fr;
    gap: clamp(3rem, 8vw, 8rem);
}

.how-it-works ol {
    margin: 0;
    padding: 0;
    list-style: none;
}

.how-it-works li {
    display: grid;
    padding: 1.45rem 0;
    border-top: 1px solid var(--line-strong);
    grid-template-columns: 3rem 1fr;
    gap: 1rem;
}

.how-it-works li:last-child {
    border-bottom: 1px solid var(--line-strong);
}

.how-it-works li > span,
.response-principles article > span {
    color: var(--orange-dark);
    font-family: var(--serif);
    font-style: italic;
}

.how-it-works strong {
    color: var(--forest-dark);
}

.how-it-works li p {
    margin: 0.35rem 0 0;
    color: var(--muted);
    font-size: 0.87rem;
}

.site-footer {
    display: grid;
    width: min(1180px, calc(100% - 40px));
    min-height: 130px;
    margin: 0 auto;
    padding: 2rem 0;
    align-items: center;
    border-top: 1px solid rgba(23, 63, 53, 0.16);
    grid-template-columns: 1fr auto 1fr;
    color: var(--muted);
    font-size: 0.76rem;
    gap: 1rem;
}

.site-footer p {
    margin: 0;
}

.site-footer p:last-child {
    text-align: right;
}

.brand-footer {
    font-size: 0.9rem;
}

.brand-footer .brand-mark {
    width: 1.8rem;
    height: 1.8rem;
    font-size: 0.9rem;
}

.response-main {
    width: min(960px, calc(100% - 40px));
    margin: 0 auto;
    overflow: visible;
}

.response-intro {
    max-width: 820px;
    padding: 6.5rem 0 4.5rem;
}

.response-intro h1 {
    font-size: clamp(3.4rem, 7vw, 6rem);
}

.response-intro > p:last-child {
    max-width: 650px;
    margin: 1.6rem 0 0;
    color: var(--muted);
    font-family: var(--serif);
    font-size: 1.25rem;
}

.response-card {
    padding: clamp(1.4rem, 4vw, 3.5rem);
    border: 1px solid var(--line);
    border-radius: 0.55rem 1.7rem 0.55rem 1.7rem;
    background: var(--paper);
    box-shadow: var(--shadow);
}

.response-summary {
    padding-bottom: 1.7rem;
    border-bottom: 1px solid var(--line);
}

.response-summary h2 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
}

.response-summary > p:last-child {
    margin: 0.8rem 0 0;
    color: var(--muted);
    font-size: 0.86rem;
}

.perspective-card {
    margin: 1.7rem 0 2rem;
    padding: 1.3rem 1.4rem;
    border-left: 3px solid var(--orange);
    border-radius: 0 0.8rem 0.8rem 0;
    background: #f5f2eb;
}

.perspective-card span {
    color: var(--orange-dark);
    font-size: 0.7rem;
    font-weight: 780;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.perspective-card p {
    margin: 0.7rem 0 0;
    white-space: pre-wrap;
}

.response-principles {
    display: grid;
    margin: 3rem 0 7rem;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 1rem;
    background: var(--line);
}

.response-principles article {
    padding: 1.4rem;
    background: rgba(255, 253, 248, 0.7);
}

.response-principles h3 {
    margin: 0.75rem 0 0;
    color: var(--forest-dark);
    font-family: var(--serif);
    font-size: 1.25rem;
}

.response-principles p {
    margin: 0.35rem 0 0;
    color: var(--muted);
    font-size: 0.78rem;
}

.error-page {
    width: min(700px, calc(100% - 40px));
    min-height: calc(100vh - 222px);
    margin: 0 auto;
    padding: 8rem 0;
}

.error-page h1 {
    font-size: clamp(3rem, 8vw, 5rem);
}

.error-page > p:not(.eyebrow) {
    max-width: 520px;
    margin: 1.3rem 0 2rem;
    color: var(--muted);
}

.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

@media (max-width: 850px) {
    .hero {
        min-height: 0;
        padding: 5rem 0;
        grid-template-columns: 1fr;
        gap: 3.5rem;
    }

    .principle-card {
        max-width: 520px;
        transform: rotate(0.7deg);
    }

    .how-it-works {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .site-footer {
        justify-items: center;
        grid-template-columns: 1fr;
        text-align: center;
    }

    .site-footer p:last-child {
        text-align: center;
    }
}

@media (max-width: 640px) {
    .site-header,
    .hero,
    .wizard-wrap,
    .how-it-works,
    .site-footer,
    .response-main,
    .error-page {
        width: min(100% - 24px, 1180px);
    }

    .site-header {
        min-height: 74px;
    }

    .header-note {
        display: none;
    }

    .hero {
        padding: 4rem 0;
    }

    .hero h1 {
        font-size: clamp(3.25rem, 16vw, 4.5rem);
    }

    .trust-row {
        align-items: flex-start;
        flex-direction: column;
    }

    .wizard-wrap,
    .response-card {
        padding: 1.2rem;
        border-radius: 1.1rem;
    }

    .wizard-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.4rem;
    }

    .progress {
        margin: 2rem 0 2.4rem;
    }

    .progress small {
        display: none;
    }

    .field-grid,
    .choice-group,
    .response-principles {
        grid-template-columns: 1fr;
    }

    .actions {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .actions .button {
        width: 100%;
    }

    .response-intro {
        padding: 4rem 0 3rem;
    }

    .response-intro h1 {
        font-size: clamp(3rem, 15vw, 4.3rem);
    }

    .response-principles {
        gap: 1px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
    }
}
