/* StudioAI landing. Tokens mirror the app's design system (Core/Design/DesignSystem.swift):
   warm paper background, cards with a 2 px border and a 4 px lip, saturated tones with a darker
   relief, rounded type. */

:root {
    --bg: #F7F5F2;
    --bg-soft: #EFECE6;
    --card: #FFFFFF;
    --border: #E3DFD8;
    --lip: #D3CEC5;
    --track: #E8E4DD;
    --text: #17171C;
    --muted: #64646C;

    --primary: #5B57F5; --primary-depth: #3F3BC9; --primary-ink: #3F3BC9;
    --reward: #FFB800; --reward-depth: #D99500; --reward-ink: #8A5A00;
    --success: #1B9A62; --success-depth: #137A4C;
    --danger: #E5484D; --danger-depth: #B8343A;
    --flashcards: #B869E5; --flashcards-depth: #9449BC; --flashcards-ink: #924CB7;
    --quiz: #0065B0; --quiz-depth: #02477C;
    --listening: #D37306; --listening-depth: #A45804;
    --grammar: #00837E; --grammar-depth: #01605C;
    --cloze: #7F9106; --cloze-depth: #616E00;
    --reading: #1596C3; --reading-depth: #037397;
    --conversation: #D22A7A; --conversation-depth: #A5035A; --conversation-ink: #BD2B6E;
    --tutor: #762575; --tutor-depth: #530053;

    --radius-card: 24px;
    --radius-control: 16px;
    --radius-tile: 14px;
    --lip-h: 4px;

    --font: ui-rounded, "SF Pro Rounded", "Nunito", "Varela Round", system-ui, -apple-system, "Segoe UI", sans-serif;
    --ease-spring: cubic-bezier(.34, 1.56, .64, 1);
    --ease-out: cubic-bezier(.22, 1, .36, 1);

    color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #0F0F13;
        --bg-soft: #15151B;
        --card: #1B1B21;
        --border: #363641;
        --lip: #2B2B34;
        --track: #2D2D37;
        --text: #F3F3F6;
        --muted: #9A9AA3;
        --primary: #6361EB; --primary-depth: #3D3BAE; --primary-ink: #A9A7FF;
        --reward-depth: #B87A00; --reward-ink: #FFC93D;
        --success-depth: #0F6540;
        --danger-depth: #9A2B31;
        --flashcards-depth: #9A50C3; --flashcards-ink: #C88EEA;
        --quiz: #0277CC; --quiz-depth: #015DA1;
        --listening-depth: #AD5D00;
        --grammar-depth: #006662;
        --cloze-depth: #667404;
        --reading-depth: #03799F;
        --conversation-depth: #AF0060; --conversation-ink: #EE73A2;
        --tutor: #A24FA0; --tutor-depth: #833782;
    }
}

/* ── Base ─────────────────────────────────────────────────────────────── */

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: 18px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { margin: 0; line-height: 1.08; letter-spacing: -0.025em; font-weight: 900; }
h2 { font-size: clamp(2rem, 4.6vw, 3.25rem); }
h3 { font-size: 1.3rem; font-weight: 800; letter-spacing: -0.015em; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
:focus-visible { outline: 3px solid var(--primary); outline-offset: 3px; border-radius: 8px; }

.skip {
    position: absolute; left: 16px; top: -60px; z-index: 100;
    background: var(--primary); color: #fff; padding: 10px 16px; border-radius: 12px; font-weight: 800;
}
.skip:focus { top: 12px; }

.wrap { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 20px; }
.wrap--narrow { max-width: 780px; }
.center { text-align: center; }

/* ── Tactile primitives ───────────────────────────────────────────────── */

.card {
    background: var(--card);
    border: 2px solid var(--border);
    border-radius: var(--radius-card);
    box-shadow: 0 var(--lip-h) 0 var(--lip);
}

.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    font: inherit; font-weight: 800; text-decoration: none; cursor: pointer;
    border: 0; border-radius: var(--radius-control);
    padding: 14px 22px;
    transition: transform .09s ease, box-shadow .09s ease, filter .2s ease;
}
.btn--primary { background: var(--primary); color: #fff; box-shadow: 0 5px 0 var(--primary-depth); }
.btn--primary:hover { filter: brightness(1.06); }
.btn--primary:active { transform: translateY(5px); box-shadow: 0 0 0 var(--primary-depth); }
.btn--sm { padding: 9px 16px; font-size: 16px; border-radius: 13px; box-shadow: 0 4px 0 var(--primary-depth); }
.btn--sm:active { transform: translateY(4px); }

.tile {
    --t: var(--primary); --td: var(--primary-depth);
    display: inline-grid; place-items: center; flex: none;
    width: 48px; height: 48px; border-radius: var(--radius-tile);
    background: var(--t); color: #fff; box-shadow: 0 4px 0 var(--td);
}
.tile svg { width: 26px; height: 26px; fill: currentColor; stroke: currentColor; stroke-width: 0; }
.tile svg [fill="none"] { fill: none; }
.tile--sm { width: 34px; height: 34px; border-radius: 10px; box-shadow: 0 3px 0 var(--td); }
.tile--sm svg { width: 20px; height: 20px; }
.tile--primary { --t: var(--primary); --td: var(--primary-depth); }
.tile--reward { --t: var(--reward); --td: var(--reward-depth); color: #3B2600; }
.tile--success { --t: var(--success); --td: var(--success-depth); }
.tile--danger { --t: var(--danger); --td: var(--danger-depth); }
.tile--quiz { --t: var(--quiz); --td: var(--quiz-depth); }
.tile--reading { --t: var(--reading); --td: var(--reading-depth); }
.tile--listening { --t: var(--listening); --td: var(--listening-depth); }
.tile--grammar { --t: var(--grammar); --td: var(--grammar-depth); }
.tile--tutor { --t: var(--tutor); --td: var(--tutor-depth); }
.tile--on-fill { --t: rgba(255, 255, 255, .18); --td: rgba(0, 0, 0, .22); }

.kicker {
    display: inline-block; margin-bottom: 14px;
    font-size: 14px; font-weight: 900; letter-spacing: .08em; text-transform: uppercase;
    color: var(--primary-ink);
}
.kicker--on-fill { color: rgba(255, 255, 255, .8); }
.lead { margin-top: 16px; font-size: 1.15rem; color: var(--muted); max-width: 640px; }

.link-arrow { font-weight: 800; color: var(--primary-ink); text-decoration: none; }
.link-arrow:hover { text-decoration: underline; text-underline-offset: 4px; }

.checks { display: grid; gap: 10px; margin-top: 20px; }
.checks li { position: relative; padding-left: 34px; font-weight: 600; }
.checks li::before {
    content: ""; position: absolute; left: 0; top: 3px; width: 22px; height: 22px; border-radius: 7px;
    background: var(--tone, var(--success)) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4 8-9' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 16px no-repeat;
    box-shadow: 0 2px 0 var(--tone-depth, var(--success-depth));
}

/* ── Navigation ───────────────────────────────────────────────────────── */

.nav {
    position: sticky; top: 0; z-index: 50;
    background: color-mix(in srgb, var(--bg) 82%, transparent);
    -webkit-backdrop-filter: saturate(1.6) blur(16px);
    backdrop-filter: saturate(1.6) blur(16px);
    border-bottom: 2px solid transparent;
    transition: border-color .2s ease;
}
.nav.is-scrolled { border-bottom-color: var(--border); }
.nav__inner {
    max-width: 1160px; margin: 0 auto; padding: 12px 20px;
    display: flex; align-items: center; gap: 24px;
}
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 900; font-size: 20px; letter-spacing: -0.02em; text-decoration: none; }
.brand img { border-radius: 8px; }
.nav__links { display: none; gap: 26px; margin-left: 12px; }
.nav__links a { text-decoration: none; font-weight: 700; color: var(--muted); font-size: 16px; }
.nav__links a:hover { color: var(--text); }
.nav__actions { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.lang-switch {
    font-weight: 900; font-size: 14px; text-decoration: none; color: var(--muted);
    border: 2px solid var(--border); border-radius: 10px; padding: 5px 9px; box-shadow: 0 3px 0 var(--lip);
    background: var(--card);
}
.lang-switch:active { transform: translateY(3px); box-shadow: none; }
@media (min-width: 940px) { .nav__links { display: flex; } }

/* ── Hero ─────────────────────────────────────────────────────────────── */

.hero { position: relative; padding: 48px 0 40px; overflow: hidden; }
.hero__bg {
    position: absolute; inset: -20% -10% auto; height: 900px; z-index: -1; pointer-events: none;
    background:
        radial-gradient(520px 380px at 78% 38%, color-mix(in srgb, var(--primary) 26%, transparent), transparent 70%),
        radial-gradient(360px 300px at 92% 70%, color-mix(in srgb, var(--conversation) 16%, transparent), transparent 70%),
        radial-gradient(380px 300px at 12% 8%, color-mix(in srgb, var(--reward) 14%, transparent), transparent 70%),
        radial-gradient(circle at 1px 1px, color-mix(in srgb, var(--text) 9%, transparent) 1.2px, transparent 1.6px) 0 0 / 26px 26px;
    -webkit-mask-image: linear-gradient(to bottom, #000 55%, transparent);
    mask-image: linear-gradient(to bottom, #000 55%, transparent);
}
.hero__grid { display: grid; gap: 48px; align-items: center; }
@media (min-width: 940px) {
    .hero { padding: 72px 0 56px; }
    .hero__grid { grid-template-columns: 1.08fr .92fr; gap: 40px; }
}

.eyebrow {
    display: inline-flex; align-items: center; gap: 10px;
    font-size: 15px; font-weight: 800; color: var(--primary-ink);
    background: var(--card); border: 2px solid var(--border); box-shadow: 0 3px 0 var(--lip);
    padding: 6px 14px 6px 10px; border-radius: 999px;
}
.eyebrow__dot { width: 10px; height: 10px; border-radius: 50%; background: var(--success); box-shadow: 0 0 0 4px color-mix(in srgb, var(--success) 22%, transparent); }

.hero__title {
    margin-top: 22px;
    font-size: clamp(2.7rem, 7.4vw, 5.1rem);
    line-height: 1.0; letter-spacing: -0.04em;
    text-wrap: balance;
}
.hero__title em {
    font-style: normal; color: var(--primary);
    background: linear-gradient(transparent 86%, var(--reward) 86%, var(--reward) 97%, transparent 97%);
    -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.hero__sub { margin-top: 22px; font-size: clamp(1.1rem, 2vw, 1.3rem); color: var(--muted); max-width: 560px; }
.hero__sub strong { color: var(--text); }
.hero__ctas { margin-top: 32px; display: flex; flex-wrap: wrap; align-items: center; gap: 18px 28px; }
.hero__facts { margin-top: 26px; display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: 15px; font-weight: 700; color: var(--muted); }
.hero__facts li { display: inline-flex; align-items: center; gap: 8px; }
.hero__facts li::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--primary); opacity: .6; }

.store-badge { display: inline-block; border-radius: 12px; transition: transform .2s var(--ease-spring); }
.store-badge:hover { transform: translateY(-2px) scale(1.02); }
.store-badge:active { transform: translateY(1px) scale(.98); }
.store-badge img { width: 180px; height: auto; }
.store-badge__img--light { display: none; }
@media (prefers-color-scheme: dark) {
    .store-badge__img--dark { display: none; }
    .store-badge__img--light { display: block; }
}

/* Phone frame around a full-screen capture (the capture already has the status bar). */
.phone {
    margin: 0; position: relative;
    width: min(300px, 74vw);
    aspect-ratio: 750 / 1630;
    border-radius: 46px;
    padding: 9px;
    background: linear-gradient(145deg, #2A2A31, #0C0C0F 60%);
    box-shadow:
        0 0 0 1.5px #3A3A42 inset,
        0 2px 0 1px rgba(255, 255, 255, .06) inset,
        0 30px 60px -20px rgba(28, 22, 90, .45),
        0 18px 36px -18px rgba(0, 0, 0, .35);
}
.phone img { width: 100%; height: 100%; object-fit: cover; border-radius: 37px; background: var(--bg-soft); }

.hero__visual { position: relative; display: grid; place-items: center; padding: 10px 0 30px; }
.phone--hero { width: min(318px, 76vw); transform: rotate(2.5deg); }

.float-chip {
    position: absolute; display: flex; align-items: center; gap: 12px;
    padding: 10px 16px 10px 10px;
    background: var(--card); border: 2px solid var(--border); border-radius: 18px; box-shadow: 0 4px 0 var(--lip), 0 18px 30px -18px rgba(0, 0, 0, .3);
    line-height: 1.15; white-space: nowrap;
    animation: float 6s ease-in-out infinite;
}
.float-chip b { display: block; font-size: 17px; font-weight: 900; }
.float-chip small { display: block; font-size: 13px; font-weight: 700; color: var(--muted); }
.float-chip .tile { width: 40px; height: 40px; border-radius: 12px; }
.float-chip .tile svg { width: 22px; height: 22px; }
.float-chip--a { top: 9%; left: max(0px, calc(50% - 250px)); }
.float-chip--b { top: 46%; right: max(0px, calc(50% - 262px)); animation-delay: -2s; }
.float-chip--c { bottom: 10%; left: max(0px, calc(50% - 236px)); animation-delay: -4s; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

.ring { position: relative; width: 40px; height: 40px; display: grid; place-items: center; }
.ring svg { position: absolute; inset: 0; transform: rotate(-90deg); }
.ring circle { fill: none; stroke: var(--track); stroke-width: 5; }
.ring .ring__fill { stroke: var(--primary); stroke-linecap: round; stroke-dasharray: 88; stroke-dashoffset: 44; }
.ring b { font-size: 15px; color: var(--primary-ink); }

@media (max-width: 520px) {
    .float-chip { padding: 8px 12px 8px 8px; gap: 9px; border-radius: 15px; }
    .float-chip b { font-size: 15px; }
    .float-chip small { font-size: 12px; }
    .float-chip .tile, .ring { width: 34px; height: 34px; }
    .float-chip--a { left: 0; }
    .float-chip--b { display: none; }
    .float-chip--c { left: 2px; }
}

.sources { margin-top: 36px; display: flex; flex-wrap: wrap; align-items: center; gap: 14px 26px; }
.sources__label { font-size: 14px; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.sources__list { display: flex; flex-wrap: wrap; gap: 12px 22px; }
.sources__list li { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; }
.sources__list .tile svg { stroke: #fff; }

/* Load choreography: a short staggered rise, once (only with JS, so the hero never depends on it). */
.js .rise { animation: rise .8s var(--ease-out) both; animation-delay: calc(var(--d, 0) * 90ms + 60ms); }
@keyframes rise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
.js .hero__visual.rise { animation-name: rise-pop; animation-duration: 1s; }
@keyframes rise-pop { from { opacity: 0; transform: translateY(40px) scale(.96); } to { opacity: 1; transform: none; } }

/* ── Sections ─────────────────────────────────────────────────────────── */

.section { padding: 96px 0; }
.section--tight { padding: 64px 0; }
.section--soft { background: var(--bg-soft); border-block: 2px solid var(--border); }
.section__head { text-align: center; max-width: 760px; margin: 0 auto 48px; }
.section__head .lead { margin-inline: auto; }
@media (max-width: 640px) { .section { padding: 72px 0; } .section__head { margin-bottom: 36px; } }

.steps { display: grid; gap: 20px; counter-reset: s; }
@media (min-width: 860px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step { padding: 28px; }
.step__num { font-size: 22px; font-weight: 900; margin-bottom: 20px; }
.step h3 { margin-bottom: 10px; }
.step p { color: var(--muted); }

/* Feature rows */
.feature {
    display: grid; gap: 36px; align-items: center; justify-items: center;
    padding: 36px 0;
}
.feature + .feature { border-top: 2px dashed var(--border); }
.feature__copy { max-width: 520px; }
.feature__copy h3 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); font-weight: 900; letter-spacing: -0.03em; margin: 14px 0 14px; }
.feature__copy > p:not(.tag) { color: var(--muted); font-size: 1.1rem; }
.feature .phone { width: min(280px, 70vw); }
@media (min-width: 900px) {
    .feature { grid-template-columns: 1fr 1fr; gap: 64px; padding: 56px 0; }
    .feature--flip .feature__copy { order: 2; }
    .feature__copy { justify-self: start; }
    .feature--flip .feature__copy { justify-self: end; }
}
.tag {
    display: inline-flex; align-items: center; gap: 8px;
    font-size: 15px; font-weight: 900; color: var(--tone-ink, var(--tone));
    background: color-mix(in srgb, var(--tone) 12%, var(--card));
    border: 2px solid color-mix(in srgb, var(--tone) 40%, transparent);
    padding: 5px 12px; border-radius: 999px;
}
.tag__dot { width: 9px; height: 9px; border-radius: 3px; background: var(--tone); }
.feature .phone { box-shadow: 0 0 0 1.5px #3A3A42 inset, 0 30px 60px -24px color-mix(in srgb, var(--tone) 60%, transparent), 0 18px 36px -18px rgba(0, 0, 0, .3); }

.activities { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.activities li {
    display: inline-flex; align-items: center; gap: 8px;
    font-size: 15px; font-weight: 800;
    background: var(--card); border: 2px solid var(--border); box-shadow: 0 3px 0 var(--lip);
    padding: 7px 13px 7px 9px; border-radius: 12px;
}
.activities li::before { content: ""; width: 14px; height: 14px; border-radius: 5px; background: var(--c); box-shadow: 0 2px 0 color-mix(in srgb, var(--c) 70%, #000); }

/* Habit band */
.band {
    position: relative; overflow: hidden;
    background:
        radial-gradient(600px 400px at 85% 20%, rgba(255, 255, 255, .14), transparent 70%),
        linear-gradient(160deg, var(--primary), color-mix(in srgb, var(--primary-depth) 85%, #1a1050));
    color: #fff; padding: 96px 0;
}
.band__grid { display: grid; gap: 56px; align-items: center; }
@media (min-width: 940px) { .band__grid { grid-template-columns: 1fr 1fr; } }
.band .lead { color: rgba(255, 255, 255, .82); }
.habits { display: grid; gap: 22px; margin-top: 34px; }
.habits li { display: flex; gap: 18px; align-items: flex-start; }
.habits h3 { font-size: 1.15rem; margin-bottom: 4px; }
.habits p { color: rgba(255, 255, 255, .8); }
.habits .tile svg circle, .habits .tile svg path { stroke: #fff; }
.habits .ico-ring circle { fill: none; }
.band__visual { display: flex; justify-content: center; align-items: center; gap: 0; min-height: 520px; }
.band__visual .phone { width: min(250px, 44vw); }
.phone--tilt-l { transform: rotate(-6deg) translateX(18px); z-index: 1; }
.phone--tilt-r { transform: rotate(5deg) translate(-18px, 40px); }

/* Science */
.science { display: grid; gap: 20px; }
@media (min-width: 900px) {
    .science { grid-template-columns: 1.25fr 1fr; grid-template-areas: "fsrs cefr" "fsrs native"; }
    .science__fsrs { grid-area: fsrs; }
    .science__cefr { grid-area: cefr; }
    .science__native { grid-area: native; }
}
.science .card { padding: 30px; }
.science h3 { font-size: 1.45rem; margin-bottom: 10px; }
.science p { color: var(--muted); }
.curve { margin: 26px 0 0; }
.curve svg { width: 100%; height: auto; overflow: visible; }
.curve__axis { stroke: var(--border); stroke-width: 2; }
.curve__without { fill: none; stroke: var(--muted); stroke-width: 3; stroke-dasharray: 6 7; opacity: .55; }
.curve__with { fill: none; stroke: var(--primary); stroke-width: 4.5; stroke-linejoin: round; stroke-linecap: round; }
.curve__dot { fill: var(--reward); stroke: var(--card); stroke-width: 3; }
.curve__label { font-family: var(--font); font-size: 12px; font-weight: 800; fill: var(--muted); }
.curve__label--with { fill: var(--primary-ink); }
.curve__label--dot { fill: var(--reward-ink); font-size: 11px; }
.js .curve__with { stroke-dasharray: 900; stroke-dashoffset: 900; }
.js .in .curve__with { animation: draw 1.8s var(--ease-out) .2s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }

.ladder { display: flex; align-items: flex-end; gap: 8px; height: 120px; margin-top: 24px; }
.ladder span {
    flex: 1; height: var(--h); display: flex; align-items: flex-start; justify-content: center; padding-top: 8px;
    background: var(--c); color: #fff; font-weight: 900; font-size: 15px;
    border-radius: 12px; box-shadow: 0 4px 0 color-mix(in srgb, var(--c) 70%, #000);
}
.js .science__cefr .ladder span { transform: scaleY(.2); transform-origin: bottom; opacity: 0; transition: transform .7s var(--ease-spring), opacity .3s ease; }
.js .science__cefr.in .ladder span { transform: none; opacity: 1; }
.science__cefr.in .ladder span:nth-child(2) { transition-delay: .06s; }
.science__cefr.in .ladder span:nth-child(3) { transition-delay: .12s; }
.science__cefr.in .ladder span:nth-child(4) { transition-delay: .18s; }
.science__cefr.in .ladder span:nth-child(5) { transition-delay: .24s; }
.science__cefr.in .ladder span:nth-child(6) { transition-delay: .30s; }

.bubble-pair { display: grid; gap: 8px; margin-top: 22px; }
.bubble { padding: 12px 16px; border-radius: 18px; font-weight: 700; font-size: 16px; max-width: 92%; }
.bubble--target { background: var(--track); color: var(--text) !important; border-bottom-left-radius: 6px; }
.bubble--native { justify-self: end; background: var(--grammar); color: #fff !important; border-bottom-right-radius: 6px; box-shadow: 0 3px 0 var(--grammar-depth); }

/* Privacy */
.privacy { display: grid; gap: 20px; }
@media (min-width: 720px) { .privacy { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .privacy { grid-template-columns: repeat(4, 1fr); } }
.privacy li { padding: 26px; }
.privacy .tile { margin-bottom: 18px; }
.privacy .tile svg [fill="none"] { stroke: #fff; }
.privacy h3 { font-size: 1.12rem; margin-bottom: 8px; }
.privacy p { color: var(--muted); font-size: 16px; }
#privacidad .center { margin-top: 36px; }

/* Languages */
.langs { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 22px 14px; max-width: 900px; margin: 0 auto; }
.langs li { display: flex; flex-direction: column; align-items: center; gap: 12px; font-weight: 800; text-align: center; }
.flag {
    width: 56px; height: 56px; border-radius: 50%;
    border: 2.5px solid var(--border);
    box-shadow: 0 4px 0 var(--lip);
    transition: transform .3s var(--ease-spring);
}
.langs li:hover .flag { transform: translateY(-4px) rotate(-6deg); }

/* Plans: Free is the quiet card, Pro the gold one that carries the section. */
.plans { display: grid; gap: 26px; max-width: 1020px; margin: 0 auto; align-items: center; }
@media (min-width: 860px) { .plans { grid-template-columns: .78fr 1.22fr; } }
.plan { padding: 32px; position: relative; }
.plan h3 { font-size: 1.6rem; }
.plan__price { margin-top: 6px; font-weight: 900; font-size: 1.05rem; color: var(--muted); }
.plan__desc { margin-top: 14px; color: var(--muted); }

.plan--pro {
    padding: 40px 36px 36px;
    border: 2.5px solid var(--reward);
    background:
        radial-gradient(420px 260px at 100% 0%, color-mix(in srgb, var(--reward) 30%, transparent), transparent 70%),
        radial-gradient(360px 240px at 0% 100%, color-mix(in srgb, var(--primary) 12%, transparent), transparent 70%),
        linear-gradient(170deg, color-mix(in srgb, var(--reward) 12%, var(--card)), var(--card) 55%);
    box-shadow: 0 6px 0 var(--reward-depth), 0 30px 60px -28px color-mix(in srgb, var(--reward-depth) 70%, transparent);
    --tone: var(--reward); --tone-depth: var(--reward-depth);
}
@media (max-width: 859px) { .plan--pro { order: -1; } }
.plan__badge {
    position: absolute; top: -17px; right: 28px;
    background: var(--reward); color: #3B2600; font-weight: 900; font-size: 15px;
    padding: 6px 14px; border-radius: 999px; box-shadow: 0 3px 0 var(--reward-depth);
}
.pro__head { display: flex; align-items: center; gap: 16px; }
.pro__crown { width: 58px; height: 58px; border-radius: 17px; box-shadow: 0 5px 0 var(--reward-depth); }
.pro__crown svg { width: 32px; height: 32px; }
.plan--pro h3 { font-size: clamp(1.9rem, 3.4vw, 2.4rem); letter-spacing: -0.03em; }
.plan--pro .plan__price { color: var(--reward-ink); margin-top: 2px; }
.pro__pitch { margin-top: 18px; font-size: 1.15rem; font-weight: 700; }
.pro__features { display: grid; gap: 16px 22px; margin-top: 24px; }
@media (min-width: 560px) { .pro__features { grid-template-columns: 1fr 1fr; } }
.pro__features li { display: flex; gap: 12px; align-items: flex-start; }
.pro__features .tile svg [fill="none"] { stroke: #fff; }
.pro__features strong { display: block; font-weight: 900; line-height: 1.25; }
.pro__features span:not(.tile) { display: block; margin-top: 3px; font-size: 15px; line-height: 1.4; color: var(--muted); }
.pro__cta { margin-top: 30px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; }
.pro__cta p { font-size: 14px; font-weight: 700; color: var(--muted); }
.btn--reward { background: var(--reward); color: #3B2600; box-shadow: 0 5px 0 var(--reward-depth); font-size: 1.05rem; padding: 15px 24px; }
.btn--reward:hover { filter: brightness(1.05); }
.btn--reward:active { transform: translateY(5px); box-shadow: 0 0 0 var(--reward-depth); }
.note { margin-top: 28px; font-size: 15px; color: var(--muted); }

/* FAQ */
.faq { display: grid; gap: 14px; }
.faq details {
    background: var(--card); border: 2px solid var(--border); border-radius: 20px; box-shadow: 0 4px 0 var(--lip);
    transition: box-shadow .1s ease, transform .1s ease;
}
.faq summary {
    cursor: pointer; list-style: none; padding: 20px 56px 20px 24px; position: relative;
    font-weight: 800; font-size: 1.1rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
    content: ""; position: absolute; right: 22px; top: 50%; width: 22px; height: 22px; margin-top: -11px;
    border-radius: 8px; background: var(--track) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M7 10l5 5 5-5' fill='none' stroke='%2364646C' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 18px no-repeat;
    transition: transform .3s var(--ease-spring);
}
.faq details[open] summary::after { transform: rotate(180deg); }
.faq details p { padding: 0 24px 22px; color: var(--muted); }

/* Final CTA */
.final {
    text-align: center; color: #fff;
    padding: 64px 24px;
    border-radius: 32px;
    background:
        radial-gradient(500px 260px at 20% 0%, rgba(255, 255, 255, .16), transparent 70%),
        linear-gradient(160deg, var(--primary), var(--primary-depth));
    box-shadow: 0 6px 0 color-mix(in srgb, var(--primary-depth) 70%, #000);
}
.final h2 { max-width: 720px; margin: 0 auto; text-wrap: balance; }
.final > p { margin: 16px auto 30px; max-width: 560px; color: rgba(255, 255, 255, .85); font-size: 1.15rem; }
.final .final__note { margin: 18px auto 0; font-size: 15px; color: rgba(255, 255, 255, .75); }

/* Footer */
.footer { padding: 48px 0 56px; border-top: 2px solid var(--border); }
.footer__inner { display: grid; gap: 22px; }
.footer__brand p { margin-top: 10px; color: var(--muted); font-size: 15px; max-width: 360px; }
.footer__links { display: flex; flex-wrap: wrap; gap: 10px 22px; }
.footer__links a { font-weight: 700; font-size: 15px; color: var(--muted); text-decoration: none; }
.footer__links a:hover { color: var(--text); }
.footer__rights { font-size: 14px; color: var(--muted); }
@media (min-width: 860px) {
    .footer__inner { grid-template-columns: 1fr auto; align-items: start; }
    .footer__rights { grid-column: 1 / -1; }
}

/* Scroll reveal (only when JS runs; without it everything is visible). */
.js .reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s var(--ease-out), transform .8s var(--ease-out); }
.js .reveal.in { opacity: 1; transform: none; }
.js .steps .reveal:nth-child(2), .js .privacy .reveal:nth-child(2) { transition-delay: .08s; }
.js .steps .reveal:nth-child(3), .js .privacy .reveal:nth-child(3) { transition-delay: .16s; }
.js .privacy .reveal:nth-child(4) { transition-delay: .24s; }

@media (prefers-reduced-motion: reduce) {
    .js .rise, .js .hero__visual.rise, .float-chip { animation: none; }
    .js .reveal { opacity: 1; transform: none; transition: none; }
    .js .curve__with { stroke-dasharray: none; stroke-dashoffset: 0; animation: none; }
    .js .science__cefr .ladder span { transform: none; opacity: 1; transition: none; }
    .btn, .store-badge, .flag, .faq summary::after { transition: none; }
}
