:root {
    --ink:        #1A1A1F;
    --ink-2:      #4B4B54;
    --ink-mute:   #8A8A94;
    --ink-faint:  #B8B8C0;
    --line:       #E7E7EA;
    --line-soft:  #F1F1F3;
    --surface:    #FFFFFF;
    --surface-2:  #FAFAFB;
    --surface-3:  #F4F4F6;
    --pop:        #00A862;
    --pop-soft:   rgba(0,168,98,0.10);
    --pop-ink:    #00854F;
    --warn:       #E89B1F;

    --radius-sm: 10px;
    --radius:    14px;
    --radius-lg: 20px;
    --radius-xl: 28px;

    --shadow-1: 0 1px 0 rgba(0,0,0,.03), 0 1px 2px rgba(0,0,0,.04);
    --shadow-2: 0 1px 0 rgba(0,0,0,.03), 0 8px 28px -12px rgba(0,0,0,.08);
    --shadow-3: 0 1px 0 rgba(0,0,0,.03), 0 18px 60px -20px rgba(0,0,0,.15);

    --font-body: "Space Grotesk", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
    --font-serif: "Instrument Serif", Georgia, serif;
    --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }

body {
    font-family: var(--font-body);
    color: var(--ink);
    background: var(--surface-2);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: geometricPrecision;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

button { font-family: inherit; cursor: pointer; }
a { color: inherit; text-decoration: none; }

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

/* ============== Topbar ============== */
.topbar {
    height: 56px;
    padding: 0 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    border-bottom: 1px solid var(--line);
    background: var(--surface);
    flex-shrink: 0;
    position: sticky;
    top: 0;
    z-index: 50;
}
.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    font-size: 16px;
    letter-spacing: -0.015em;
    color: var(--ink);
}
.brand-mark {
    width: 28px; height: 28px;
    border-radius: 7px;
    object-fit: cover;
    display: block;
    background: var(--surface-3);
}
.brand-name { font-weight: 600; }
.brand-beta {
    font-size: 11px;
    color: var(--ink-mute);
    font-weight: 400;
    background: var(--surface-3);
    padding: 2px 7px;
    border-radius: 999px;
    margin-left: 2px;
    font-family: var(--font-body);
}
.topbar-nav {
    display: flex;
    gap: 2px;
    margin-left: 14px;
}
.nav-link {
    padding: 6px 12px;
    font-size: 13px;
    color: var(--ink-2);
    border-radius: 7px;
    transition: background 120ms, color 120ms;
}
.nav-link:hover { color: var(--ink); background: var(--surface-3); }
.nav-link.is-active {
    color: var(--ink);
    background: var(--surface-3);
    font-weight: 500;
}
.topbar-spacer { flex: 1; }
.topbar-help {
    width: 28px; height: 28px;
    border-radius: 50%;
    display: grid; place-items: center;
    color: var(--ink-mute);
    font-size: 13px;
    border: 1px solid var(--line);
    background: var(--surface);
    transition: border-color 120ms, color 120ms;
}
.topbar-help:hover { border-color: var(--ink-faint); color: var(--ink); }
.topbar-avi {
    width: 28px; height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, #E6E9F0, #B8BECC);
    display: grid; place-items: center;
    font-size: 11.5px; font-weight: 600;
    color: var(--ink);
}

/* ============== Page ============== */
.page {
    flex: 1;
    width: 100%;
    max-width: 880px;
    margin: 0 auto;
    padding: 56px 24px 80px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.eyebrow {
    font-family: var(--font-mono);
    font-size: 11px;
    color: var(--ink-mute);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    font-weight: 500;
}

.v-head { text-align: center; max-width: 760px; }
.head {
    font-family: var(--font-body);
    font-size: clamp(2rem, 5vw, 44px);
    line-height: 1.05;
    letter-spacing: -0.025em;
    margin: 12px 0 0;
    font-weight: 500;
    color: var(--ink);
}
.serif-em {
    font-family: var(--font-serif);
    font-style: italic;
    font-weight: 400;
    font-size: 1.05em;
}
.lede {
    font-size: 16px;
    color: var(--ink-2);
    line-height: 1.55;
    margin: 18px auto 0;
    max-width: 520px;
}

/* ============== Buttons ============== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 40px;
    padding: 0 18px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 500;
    font-family: var(--font-body);
    border: 1px solid transparent;
    cursor: pointer;
    white-space: nowrap;
    transition: background 140ms, border-color 140ms, color 140ms, transform 120ms;
}
.btn:active { transform: translateY(1px); }
.btn.lg { height: 46px; padding: 0 22px; font-size: 15px; }
.btn.full { width: 100%; }
.btn.primary { background: var(--ink); color: #fff; }
.btn.primary:hover { background: #000; }
.btn.secondary { background: var(--surface); color: var(--ink); border-color: var(--line); }
.btn.secondary:hover { border-color: var(--ink-faint); }
.btn.pop { background: var(--pop); color: #fff; }
.btn.pop:hover { background: var(--pop-ink); }
.btn.ghost-light {
    background: rgba(255,255,255,0.08);
    color: #fff;
    border-color: rgba(255,255,255,0.18);
}
.btn.ghost-light:hover {
    background: rgba(255,255,255,0.14);
    border-color: rgba(255,255,255,0.28);
}

/* ============== Plans ============== */
.v1-plans {
    margin-top: 44px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    width: 100%;
    max-width: 880px;
}
.v1-plan {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 32px 32px 28px;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-1);
    transition: transform 200ms cubic-bezier(0.2,0.8,0.2,1), box-shadow 200ms;
}
.v1-plan:hover { transform: translateY(-2px); box-shadow: var(--shadow-2); }
.v1-plan.featured {
    border-color: var(--ink);
    box-shadow: var(--shadow-2);
}
.v1-plan .tag {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink-mute);
    font-weight: 500;
}
.v1-plan .price {
    font-family: var(--font-serif);
    font-size: 64px;
    line-height: 1;
    margin: 20px 0 6px;
    font-weight: 400;
    letter-spacing: -0.015em;
}
.v1-plan .what {
    font-size: 16px;
    color: var(--ink);
    font-weight: 500;
}
.v1-plan .what em {
    font-family: var(--font-serif);
    font-style: italic;
    font-weight: 400;
    color: var(--ink);
    font-size: 1.05em;
}
.v1-plan .sub {
    font-size: 13.5px;
    color: var(--ink-mute);
    margin-top: 6px;
}
.v1-plan .cta { margin-top: auto; padding-top: 32px; }

/* ============== Teaser strip ============== */
.v1-teaser {
    margin-top: 24px;
    width: 100%;
    max-width: 880px;
    background: var(--ink);
    color: #fff;
    border-radius: var(--radius-lg);
    padding: 24px 28px;
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 24px;
}
.v1-teaser .l-eye {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--pop);
    font-weight: 500;
}
.v1-teaser .l-title {
    font-size: 20px;
    font-weight: 500;
    margin: 6px 0 4px;
    letter-spacing: -0.015em;
}
.v1-teaser .l-title em {
    font-family: var(--font-serif);
    font-style: italic;
    font-weight: 400;
    font-size: 1.05em;
}
.v1-teaser .l-sub {
    font-size: 13.5px;
    color: rgba(255,255,255,0.68);
    line-height: 1.5;
}
.v1-teaser .gift {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 12px;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(0,168,98,0.18);
    color: #B7E0CD;
    font-size: 12.5px;
    font-weight: 500;
}
.v1-teaser .gift-star { color: #B7E0CD; }
.v1-teaser__r {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
}
.v1-teaser .r-price {
    font-family: var(--font-serif);
    font-size: 38px;
    font-weight: 400;
    line-height: 1;
}
.v1-teaser .r-price .per {
    font-family: var(--font-body);
    font-size: 14px;
    color: rgba(255,255,255,0.6);
    margin-left: 4px;
}

/* ============== Legal pages ============== */
.legal-page {
    flex: 1;
    width: 100%;
    max-width: 760px;
    margin: 0 auto;
    padding: 56px 24px 80px;
}
.legal-content {
    color: var(--ink-2);
    font-size: 15.5px;
    line-height: 1.7;
}
.legal-head {
    margin-bottom: 40px;
    padding-bottom: 28px;
    border-bottom: 1px solid var(--line);
}
.legal-head .eyebrow {
    margin-bottom: 12px;
}
.legal-content h1 {
    font-family: var(--font-body);
    font-size: clamp(2rem, 4.5vw, 40px);
    font-weight: 500;
    letter-spacing: -0.025em;
    color: var(--ink);
    margin: 0 0 12px;
    line-height: 1.1;
}
.legal-content h2 {
    font-family: var(--font-body);
    font-size: 22px;
    font-weight: 500;
    color: var(--ink);
    letter-spacing: -0.015em;
    margin: 48px 0 12px;
    line-height: 1.25;
    scroll-margin-top: 80px;
}
.legal-content h3 {
    font-family: var(--font-body);
    font-size: 16px;
    font-weight: 600;
    color: var(--ink);
    margin: 24px 0 6px;
    line-height: 1.35;
}
.legal-content p {
    margin: 0 0 14px;
}
.legal-content ul {
    margin: 8px 0 18px;
    padding-left: 22px;
}
.legal-content ul li {
    margin-bottom: 8px;
    padding-left: 4px;
}
.legal-content ul li::marker {
    color: var(--ink-faint);
}
.legal-content a {
    color: var(--ink);
    text-decoration: underline;
    text-decoration-color: var(--ink-faint);
    text-underline-offset: 3px;
    transition: text-decoration-color 120ms;
}
.legal-content a:hover {
    text-decoration-color: var(--ink);
}
.legal-meta {
    font-family: var(--font-mono);
    font-size: 12px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--ink-mute);
    margin: 0 0 20px;
}
.legal-org {
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: 4px 16px;
    font-size: 13.5px;
    margin: 0;
}
.legal-org dt {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink-mute);
    align-self: center;
}
.legal-org dd {
    margin: 0;
    color: var(--ink-2);
}
.legal-address {
    font-style: normal;
    line-height: 1.6;
    padding: 16px 18px;
    background: var(--surface-3);
    border-radius: var(--radius);
    margin-top: 8px;
}
.legal-content section + section { /* spacing already covered by h2 margin */ }

@media (max-width: 720px) {
    .legal-page { padding: 32px 16px 56px; }
    .legal-content h2 { margin-top: 36px; }
    .legal-org { grid-template-columns: 1fr; gap: 0; }
    .legal-org dt { margin-top: 8px; }
}

/* ============== Site Footer ============== */
.site-footer {
    margin-top: auto;
    padding: 20px 32px;
    border-top: 1px solid var(--line);
    background: var(--surface);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    font-size: 13px;
    color: var(--ink-mute);
    flex-wrap: wrap;
}
.site-footer__copy {
    margin: 0;
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink-mute);
}
.site-footer__links {
    display: flex;
    align-items: center;
    gap: 18px;
    flex-wrap: wrap;
}
.site-footer__links a {
    color: var(--ink-2);
    text-decoration: none;
    font-size: 13px;
    transition: color 120ms;
}
.site-footer__links a:hover {
    color: var(--ink);
    text-decoration: underline;
    text-underline-offset: 3px;
}
.site-footer__cta {
    color: var(--ink);
    font-weight: 500;
}

/* ============== Entrance Animations ============== */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(24px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.v-head .eyebrow,
.v-head .head,
.v-head .lede {
    opacity: 0;
    animation: fadeUp 0.7s cubic-bezier(0.2,0.8,0.2,1) forwards;
}
.v-head .eyebrow { animation-delay: 0s; }
.v-head .head    { animation-delay: 0.05s; }
.v-head .lede    { animation-delay: 0.10s; }

.animate-in {
    opacity: 0;
    animation: fadeUp 0.8s cubic-bezier(0.2,0.8,0.2,1) forwards;
    animation-delay: var(--delay, 0s);
}

.v-footer-links {
    opacity: 0;
    animation: fadeIn 0.6s ease 0.6s forwards;
}

/* ============== Modal ============== */
.modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.modal.is-open { display: flex; }
.modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(10, 10, 11, 0.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    animation: fadeIn 0.25s ease forwards;
}
.modal__panel {
    position: relative;
    width: 100%;
    max-width: 460px;
    background: var(--surface);
    border-radius: var(--radius-lg);
    padding: 36px 32px 28px;
    box-shadow: var(--shadow-3);
    animation: fadeUp 0.35s cubic-bezier(0.2,0.8,0.2,1) forwards;
}
.modal__close {
    position: absolute;
    top: 12px;
    right: 14px;
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    color: var(--ink-mute);
    font-size: 24px;
    line-height: 1;
    border-radius: 8px;
    transition: background 120ms, color 120ms;
}
.modal__close:hover { background: var(--surface-3); color: var(--ink); }
.modal__eyebrow {
    font-family: var(--font-mono);
    font-size: 11px;
    color: var(--pop-ink);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    font-weight: 500;
}
.modal__title {
    font-family: var(--font-body);
    font-size: 22px;
    line-height: 1.25;
    letter-spacing: -0.015em;
    margin: 10px 0 8px;
    font-weight: 500;
    color: var(--ink);
}
.modal__sub {
    font-size: 14.5px;
    color: var(--ink-2);
    margin: 0 0 22px;
    line-height: 1.5;
}
.modal__form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.modal__form input[type="email"] {
    height: 46px;
    padding: 0 16px;
    border: 1px solid var(--line);
    border-radius: 12px;
    font-size: 15px;
    font-family: var(--font-body);
    color: var(--ink);
    background: var(--surface);
    transition: border-color 120ms;
}
.modal__form input[type="email"]:focus {
    outline: none;
    border-color: var(--ink);
}
.modal__form input[type="email"]::placeholder { color: var(--ink-faint); }
.modal__form .btn { width: 100%; }
.modal__success {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: var(--pop-soft);
    border: 1px solid rgba(0,168,98,0.25);
    border-radius: 12px;
    color: var(--pop-ink);
    font-size: 14px;
    margin-top: 16px;
}
.modal__success p { margin: 0; }

/* ============== Responsive ============== */
@media (max-width: 720px) {
    .topbar { padding: 0 16px; gap: 8px; }
    .topbar-nav { display: none; }
    .page { padding: 32px 16px 56px; }
    .v1-plans { grid-template-columns: 1fr; gap: 14px; margin-top: 32px; }
    .v1-plan { padding: 26px 24px 24px; }
    .v1-plan .price { font-size: 56px; }
    .v1-teaser { grid-template-columns: 1fr; padding: 22px; }
    .v1-teaser__r { flex-direction: row; justify-content: space-between; align-items: center; }
    .v-footer-links { flex-wrap: wrap; row-gap: 10px; }
}

/* ============== Reduced Motion ============== */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    .animate-in,
    .v-head .eyebrow,
    .v-head .head,
    .v-head .lede,
    .v-footer-links {
        opacity: 1;
        transform: none;
    }
}
