/* ==========================================================================
   Meyori — Coming Soon landing page
   Romantic neon glassmorphism. Mobile-first; no external dependencies.
   ========================================================================== */

:root {
    --navy: #090B1C;
    --violet: #17102E;
    --plum: #291344;
    --pink: #FF4FA3;
    --magenta: #FF36C8;
    --purple: #B45CFF;
    --cyan: #62DFFF;
    --white: #F7F3FF;

    --text: var(--white);
    --text-muted: #CFC4E8;          /* 10:1 on navy */
    --text-soft: #B7A9D6;           /* 7.6:1 on navy */
    --error: #FF9DB5;
    --success: #9DF5D0;

    /* Button gradient uses deeper tones so white text keeps >= 4.5:1 contrast. */
    --btn-gradient: linear-gradient(100deg, #D81B78 0%, #C81E9E 48%, #8B3BDB 100%);
    --neon-gradient: linear-gradient(100deg, var(--pink), var(--magenta) 50%, var(--purple));

    --glass-bg: rgba(23, 16, 46, 0.58);
    --glass-border: rgba(255, 150, 220, 0.32);
    --radius-lg: 28px;
    --radius-md: 16px;

    --font-display: "Palatino Linotype", "Book Antiqua", Palatino, "Iowan Old Style", "URW Palladio L", Georgia, serif;
    --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

    --header-h: 52px;
    --gutter: clamp(16px, 4vw, 40px);
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-h) + 16px);
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text);
    background-color: var(--navy);
    background-image:
        radial-gradient(60vw 50vh at 85% 10%, rgba(180, 92, 255, 0.18), transparent 70%),
        radial-gradient(50vw 40vh at 10% 90%, rgba(255, 79, 163, 0.14), transparent 70%),
        linear-gradient(180deg, var(--navy) 0%, var(--violet) 55%, var(--plum) 100%);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }
picture { display: contents; }

a { color: #FFB8DE; text-underline-offset: 3px; }
a:hover { color: #fff; }

:focus-visible {
    outline: 3px solid var(--cyan);
    outline-offset: 3px;
    border-radius: 6px;
}

.container {
    width: 100%;
    max-width: 1320px;
    margin-inline: auto;
    padding-inline: var(--gutter);
}

.skip-link {
    position: absolute;
    left: 16px;
    top: -60px;
    z-index: 100;
    padding: 10px 16px;
    border-radius: 999px;
    background: var(--white);
    color: var(--navy);
    font-weight: 700;
    text-decoration: none;
    transition: top 0.2s;
}
.skip-link:focus { top: 12px; }

/* ---------- Page background (supplied main_bg artwork) ---------- */

.page-bg {
    position: fixed;
    inset: 0;
    z-index: -1;
    background-color: var(--violet);
    background-image: url("../../site_data/main_bg.png");
    background-image: image-set(url("../img/generated/bg-main-960.webp") type("image/webp"), url("../../site_data/main_bg.png") type("image/png"));
    background-size: cover;
    background-position: 50% 30%;
    transform: translateZ(0);
}
.page-bg::after {
    /* Readability scrim: darkens toward the text column and the lower page. */
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(9, 11, 28, 0.35) 0%, rgba(9, 11, 28, 0.55) 45%, rgba(9, 11, 28, 0.82) 100%),
        radial-gradient(70% 60% at 50% 40%, rgba(23, 16, 46, 0.25), rgba(9, 11, 28, 0.55));
}
.page-bg::before {
    /* Subtle twinkling sparkles */
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background-image:
        radial-gradient(1.5px 1.5px at 12% 18%, #fff, transparent),
        radial-gradient(1.5px 1.5px at 72% 12%, #ffd6f0, transparent),
        radial-gradient(2px 2px at 88% 42%, #fff, transparent),
        radial-gradient(1.5px 1.5px at 35% 30%, #d9c7ff, transparent),
        radial-gradient(1.5px 1.5px at 58% 64%, #fff, transparent),
        radial-gradient(2px 2px at 22% 72%, #ffd6f0, transparent),
        radial-gradient(1.5px 1.5px at 94% 80%, #c9f4ff, transparent);
    animation: twinkle 5s ease-in-out infinite alternate;
}
@keyframes twinkle {
    from { opacity: 0.35; }
    to { opacity: 1; }
}

@media (min-width: 1024px) {
    .page-bg {
        background-image: image-set(url("../img/generated/bg-main-1672.webp") type("image/webp"), url("../../site_data/main_bg.png") type("image/png"));
        background-position: center;
    }
    .page-bg::after {
        background:
            linear-gradient(90deg, rgba(9, 11, 28, 0.15) 0%, rgba(9, 11, 28, 0.2) 40%, rgba(9, 11, 28, 0.62) 62%, rgba(9, 11, 28, 0.7) 100%),
            linear-gradient(180deg, transparent 55%, rgba(9, 11, 28, 0.75) 100%);
    }
}

/* ---------- Floating petals (spawned by main.js) ---------- */

.petals {
    position: fixed;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    overflow: hidden;
}
.petal {
    position: absolute;
    top: -12vh;
    left: var(--x, 50%);
    width: var(--size, 28px);
    height: auto;
    opacity: 0;
    will-change: transform, opacity;
    filter: drop-shadow(0 0 6px rgba(255, 79, 163, 0.55));
    animation: petal-fall var(--dur, 14s) linear var(--delay, 0s) infinite;
}
.petal--blur { filter: blur(1.5px) drop-shadow(0 0 8px rgba(255, 79, 163, 0.5)); }
@keyframes petal-fall {
    0%   { transform: translate3d(0, 0, 0) rotate(0deg); opacity: 0; }
    8%   { opacity: var(--alpha, 0.85); }
    50%  { transform: translate3d(var(--drift, 60px), 60vh, 0) rotate(calc(var(--spin, 240deg) / 2)); }
    92%  { opacity: var(--alpha, 0.85); }
    100% { transform: translate3d(calc(var(--drift, 60px) * -0.4), 125vh, 0) rotate(var(--spin, 240deg)); opacity: 0; }
}

/* ---------- Page shell: header + hero + footer fill one viewport ---------- */

.shell {
    position: relative;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    min-height: 100dvh;
    overflow-x: clip;
}

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

/* ---------- Header (compact) ---------- */

.site-header {
    position: relative;
    z-index: 20;
    flex: none;
    border-bottom: 1px solid rgba(255, 150, 220, 0.14);
    background: linear-gradient(180deg, rgba(9, 11, 28, 0.6), rgba(9, 11, 28, 0.25));
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: var(--header-h);
    padding-block: 6px;
}
.brand {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex: none;
    text-decoration: none;
}
.brand-logo {
    width: 34px;
    height: 34px;
    object-fit: contain;
    filter: drop-shadow(0 0 10px rgba(255, 54, 200, 0.45));
}
.brand-text { font-family: var(--font-display); font-size: 1.3rem; font-weight: 700; color: var(--white); }
.brand-wordmark {
    width: auto;
    height: 26px;
    object-fit: contain;
    filter: drop-shadow(0 0 10px rgba(255, 54, 200, 0.35));
}
.header-icons {
    display: flex;
    gap: 5px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.header-icon {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    border-radius: 10px;
    border: 1px solid var(--glass-border);
    background: linear-gradient(160deg, rgba(41, 19, 68, 0.75), rgba(9, 11, 28, 0.6));
    box-shadow: 0 0 12px rgba(255, 54, 200, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.08);
    transition: border-color 0.25s, box-shadow 0.25s, transform 0.25s;
}
.header-icon img { width: 18px; height: 18px; object-fit: contain; }
.header-icon:hover {
    transform: translateY(-1px);
    border-color: rgba(255, 79, 163, 0.65);
    box-shadow: 0 0 18px rgba(255, 54, 200, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 10px;
    padding: 4px 12px;
    border-radius: 999px;
    border: 1px solid rgba(98, 223, 255, 0.4);
    background: rgba(9, 11, 28, 0.55);
    color: #D8F7FF;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    white-space: nowrap;
}
.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--cyan);
    animation: pulse 2s infinite;
}
@keyframes pulse {
    0%   { box-shadow: 0 0 0 0 rgba(98, 223, 255, 0.6); }
    70%  { box-shadow: 0 0 0 8px rgba(98, 223, 255, 0); }
    100% { box-shadow: 0 0 0 0 rgba(98, 223, 255, 0); }
}

/* ---------- Hero (fills the space between header and footer) ---------- */

.hero {
    position: relative;
    flex: 1 0 auto;
    display: flex;
    flex-direction: column;
}

/* Brand overlay: absolutely positioned, so it adds no height and moves nothing.
   Shown on desktop only — below 1024px the top centre is occupied by the couple
   banner, so the header's small wordmark is used there instead. */
.brand-layer {
    display: none;
    position: absolute;
    top: calc(var(--header-h) + clamp(8px, 1.4vh, 16px));
    left: 50%;
    z-index: 4;
    transform: translateX(-50%);
    pointer-events: none;
}
.brand-layer.is-hidden { visibility: hidden; }
.brand-layer-img {
    width: auto;
    height: clamp(44px, 8vh, 86px);
    object-fit: contain;
    filter: drop-shadow(0 0 18px rgba(255, 54, 200, 0.4));
}

/* Couple artwork. Mobile/tablet: a banner above the content.
   Desktop: anchored to the hero's bottom-left (see breakpoints below). */
.hero-art {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: center;
    pointer-events: none;
}
.hero-couple {
    width: 100%;
    max-width: 560px;
    height: auto;
    object-fit: contain;
    object-position: center bottom;
    filter: drop-shadow(0 0 24px rgba(255, 54, 200, 0.25));
}

.hero-inner {
    position: relative;
    z-index: 3;
    flex: 1 0 auto;
    display: flex;
    justify-content: center;
    padding-top: 4px;
    padding-bottom: 36px;
}
.hero-content {
    width: 100%;
    max-width: 600px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.hero-title {
    margin: 0 0 8px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(1.6rem, 6.3vw, 2.4rem);
    line-height: 1.08;
    letter-spacing: -0.01em;
    color: #FFD9EE;
    background: linear-gradient(180deg, #FFF1F9 0%, #FFC2E4 45%, #FF8BCB 75%, #E1A0FF 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 2px 18px rgba(255, 54, 200, 0.45));
    text-wrap: balance;
}
.hero-lead {
    max-width: 32em;
    margin: 0 0 28px;
    font-size: clamp(0.98rem, 1.5vw, 1.1rem);
    line-height: 1.55;
    color: var(--text-muted);
    text-shadow: 0 1px 12px rgba(9, 11, 28, 0.9);
    text-wrap: pretty;
}

/* ---------- Buttons ---------- */

.btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 52px;
    padding: 14px 32px;
    border: 0;
    border-radius: 999px;
    font: inherit;
    font-weight: 700;
    font-size: 1.05rem;
    letter-spacing: 0.01em;
    text-decoration: none;
    cursor: pointer;
    isolation: isolate;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.25s ease, filter 0.2s ease;
}
.btn-primary {
    color: #fff;
    background: var(--btn-gradient);
    text-shadow: 0 1px 2px rgba(60, 0, 40, 0.35);
    box-shadow:
        0 0 0 1px rgba(255, 180, 230, 0.35) inset,
        0 10px 28px rgba(255, 54, 200, 0.38),
        0 0 32px rgba(180, 92, 255, 0.25);
}
.btn-primary::before {
    /* glossy highlight */
    content: "";
    position: absolute;
    inset: 1px 1px 50% 1px;
    z-index: -1;
    border-radius: 999px 999px 40% 40%;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.38), rgba(255, 255, 255, 0.04));
}
.btn-primary::after {
    /* sheen sweep on hover */
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: -60%;
    width: 40%;
    z-index: -1;
    background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.35), transparent);
    transform: skewX(-20deg);
    transition: left 0.6s ease;
}
.btn-primary:hover {
    color: #fff;
    transform: translateY(-2px);
    filter: brightness(1.08) saturate(1.1);
    box-shadow:
        0 0 0 1px rgba(255, 200, 240, 0.5) inset,
        0 16px 36px rgba(255, 54, 200, 0.5),
        0 0 44px rgba(180, 92, 255, 0.35);
}
.btn-primary:hover::after { left: 120%; }
.btn-primary:active { transform: translateY(0); }
.btn-block { width: 100%; }
.btn[disabled] { cursor: progress; filter: saturate(0.7); }

.btn-link {
    padding: 6px 4px;
    border: 0;
    background: none;
    color: #FFB8DE;
    font: inherit;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 3px;
    cursor: pointer;
}
.btn-link:hover { color: #fff; }

.spinner {
    display: none;
    width: 18px;
    height: 18px;
    border: 2.5px solid rgba(255, 255, 255, 0.4);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
.is-loading .spinner { display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Subscription card ---------- */

.subscribe-card {
    position: relative;
    width: 100%;
    max-width: 580px;
    margin-inline: auto;
    text-align: left;
    outline: none;
}
.subscribe-card::before {
    /* Frosted glass panel */
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    border-radius: var(--radius-lg);
    border: 1px solid var(--glass-border);
    background:
        linear-gradient(160deg, rgba(255, 79, 163, 0.10), transparent 40%),
        linear-gradient(340deg, rgba(98, 223, 255, 0.07), transparent 40%),
        var(--glass-bg);
    -webkit-backdrop-filter: blur(18px) saturate(140%);
    backdrop-filter: blur(18px) saturate(140%);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 0 0 1px rgba(255, 54, 200, 0.12),
        0 0 42px rgba(255, 54, 200, 0.28),
        0 30px 60px rgba(0, 0, 0, 0.45);
}
.card-deco {
    position: absolute;
    z-index: 1;
    pointer-events: none;
}
.card-deco img { width: 100%; height: auto; object-fit: contain; }
.card-deco--right {
    /* Mirror of the left spray: stems centred on the card's top and right
       borders, so the artwork sits half inside, half outside the card. */
    top: 0;
    right: 0;
    width: 110px;
    transform: translate(16.2%, -25.3%);
}
.card-deco--left {
    /* The spray is L-shaped; this centres its stems on the card's left and
       bottom borders so the artwork sits half inside, half outside the card. */
    bottom: 0;
    left: 0;
    width: 110px;
    transform: translate(-17.8%, 27.7%);
}

.card-body {
    position: relative;
    z-index: 2;
    padding: 34px 20px 26px;
}
.card-title {
    margin: 0 0 6px;
    text-align: center;
    font-family: var(--font-display);
    font-size: clamp(1.6rem, 4.6vw, 2.1rem);
    line-height: 1.15;
    color: #FFB3E0;
    text-shadow: 0 0 18px rgba(255, 54, 200, 0.45);
}
.card-text {
    max-width: 30em;
    margin: 0 auto 22px;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.98rem;
}

.subscribe-form { --form-gap: 16px; display: grid; gap: var(--form-gap); }
.form-scroll { position: relative; display: grid; gap: var(--form-gap); min-width: 0; }
.subscribe-form[hidden], .form-success[hidden] { display: none !important; }

.hp {
    position: absolute !important;
    left: -10000px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.field-grid { display: grid; gap: 14px 12px; grid-template-columns: minmax(0, 1fr); }
.field { display: grid; gap: 6px; min-width: 0; }
.field-label {
    display: flex;
    align-items: baseline;
    gap: 8px;
    padding: 0;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--white);
}
.tag {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: var(--text-soft);
}
.tag.is-required { color: #FFC4E5; }

.input-wrap { position: relative; }
.input-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    width: 20px;
    height: 20px;
    transform: translateY(-50%);
    fill: #D9C9F5;
    pointer-events: none;
}
.input-wrap input {
    width: 100%;
    min-height: 50px;
    padding: 12px 16px 12px 44px;
    border: 1px solid rgba(214, 170, 255, 0.3);
    border-radius: 14px;
    background: rgba(9, 11, 28, 0.6);
    color: var(--white);
    font: inherit;
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s, background-color 0.2s;
}
.input-wrap input::placeholder { color: rgba(207, 196, 232, 0.6); }
.input-wrap input:hover { border-color: rgba(255, 150, 220, 0.5); }
.input-wrap input:focus {
    outline: none;
    border-color: var(--pink);
    background: rgba(9, 11, 28, 0.78);
    box-shadow: 0 0 0 3px rgba(255, 79, 163, 0.3), 0 0 18px rgba(255, 54, 200, 0.25);
}
.input-wrap input:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; }
.input-wrap input[aria-invalid="true"] {
    border-color: #FF6F93;
    box-shadow: 0 0 0 3px rgba(255, 111, 147, 0.2);
}
.input-wrap input:-webkit-autofill {
    -webkit-text-fill-color: var(--white);
    -webkit-box-shadow: 0 0 0 100px #1a1433 inset;
    caret-color: var(--white);
}

.field-hint { margin: 0; font-size: 0.8rem; color: var(--text-soft); }
.field-error {
    margin: 0;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--error);
}
.field-error::before { content: "⚠ "; }
.field-error[hidden] { display: none; }

/* Preference — segmented radio control */
.pref-group {
    margin: 0;
    padding: 0;
    border: 0;
    display: grid;
    gap: 8px;
    min-width: 0;
}
.segmented {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
    padding: 4px;
    border-radius: 16px;
    border: 1px solid rgba(214, 170, 255, 0.3);
    background: rgba(9, 11, 28, 0.6);
}
.segment { position: relative; cursor: pointer; }
.segment input {
    position: absolute;
    inset: 0;
    margin: 0;
    opacity: 0;
    cursor: pointer;
}
.segment span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 8px 6px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-muted);
    transition: background 0.2s, color 0.2s, box-shadow 0.2s;
}
.segment:hover span { color: #fff; background: rgba(255, 79, 163, 0.12); }
.segment input:checked + span {
    color: #fff;
    background: var(--btn-gradient);
    box-shadow: 0 4px 16px rgba(255, 54, 200, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.3);
}
.segment input:focus-visible + span { outline: 3px solid var(--cyan); outline-offset: 2px; }
.pref-group[aria-invalid="true"] .segmented { border-color: #FF6F93; }

/* Hide the field that the chosen preference doesn't need (JS sets data-pref). */
.subscribe-form[data-pref="email"] .field[data-channel="whatsapp"],
.subscribe-form[data-pref="whatsapp"] .field[data-channel="email"] { display: none; }

/* Consent checkbox */
.check {
    position: relative;
    display: grid;
    grid-template-columns: 22px 1fr;
    gap: 12px;
    align-items: start;
    cursor: pointer;
    font-size: 0.88rem;
    line-height: 1.5;
    color: var(--text-muted);
}
.check input {
    position: absolute;
    width: 22px;
    height: 22px;
    margin: 0;
    opacity: 0;
    cursor: pointer;
}
.check-box {
    width: 22px;
    height: 22px;
    margin-top: 1px;
    border-radius: 7px;
    border: 1.5px solid rgba(214, 170, 255, 0.55);
    background: rgba(9, 11, 28, 0.6);
    transition: background 0.2s, border-color 0.2s;
}
.check input:checked + .check-box {
    border-color: transparent;
    background:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round' d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 16px no-repeat,
        var(--btn-gradient);
}
.check input:focus-visible + .check-box { outline: 3px solid var(--cyan); outline-offset: 2px; }
.check input[aria-invalid="true"] + .check-box { border-color: #FF6F93; }

.form-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin: 2px 0 0;
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-soft);
}
.form-note svg { flex: none; width: 14px; height: 14px; fill: currentColor; }

.form-status {
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 0.92rem;
    font-weight: 600;
    outline: none;
}
.form-status.is-error {
    border: 1px solid rgba(255, 111, 147, 0.5);
    background: rgba(255, 111, 147, 0.12);
    color: #FFD1DC;
}
.form-status[hidden] { display: none; }

.form-success {
    display: grid;
    justify-items: center;
    gap: 10px;
    padding: 12px 0 6px;
    text-align: center;
    outline: none;
}
.success-icon {
    width: 64px;
    height: 64px;
    fill: var(--pink);
    filter: drop-shadow(0 0 16px rgba(255, 54, 200, 0.75));
    animation: heartbeat 1.6s ease-in-out infinite;
}
.success-message {
    margin: 0;
    font-family: var(--font-display);
    font-size: 1.3rem;
    line-height: 1.35;
    color: #FFE3F3;
}
@keyframes heartbeat {
    0%, 100% { transform: scale(1); }
    15% { transform: scale(1.12); }
    30% { transform: scale(1); }
    45% { transform: scale(1.08); }
}

/* ---------- Floral corner decorations ---------- */

.deco {
    position: absolute;
    z-index: 0;
    pointer-events: none;
}
.deco img { width: 100%; height: auto; object-fit: contain; }
.deco--top-right {
    top: var(--header-h);
    right: 0;
    width: clamp(130px, 34vw, 300px);
    opacity: 0.6;
}
.deco--bottom-left {
    bottom: 0;
    left: 0;
    z-index: 2;
    width: clamp(170px, 46vw, 440px);
    opacity: 0.9;
}

/* ---------- Footer (single slim strip) ---------- */

.site-footer {
    position: relative;
    z-index: 5;
    flex: none;
    border-top: 1px solid rgba(255, 150, 220, 0.22);
    background: rgba(9, 11, 28, 0.62);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    box-shadow: 0 -1px 18px rgba(255, 54, 200, 0.12);
}
.footer-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 2px 20px;
    padding-top: 9px;
    padding-bottom: calc(9px + env(safe-area-inset-bottom));
    font-size: 0.82rem;
    line-height: 1.5;
}
.footer-info { margin: 0; color: var(--text-soft); }
.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2px 20px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.footer-links a { color: #FFC4E5; text-decoration: none; }
.footer-links a:hover { color: #fff; text-decoration: underline; }

@media (min-width: 560px) {
    .footer-inner { justify-content: space-between; }
}

/* ---------- Legal / utility pages ---------- */

.legal {
    position: relative;
    z-index: 3;
    flex: 1 0 auto;
    padding: 32px 0 56px;
}
.legal-card {
    max-width: 820px;
    margin: 0 auto;
    padding: clamp(24px, 5vw, 48px);
    border-radius: var(--radius-lg);
    border: 1px solid var(--glass-border);
    background: rgba(13, 12, 34, 0.86);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
}
.legal-card h1 {
    margin: 0 0 8px;
    font-family: var(--font-display);
    font-size: clamp(2rem, 5vw, 2.8rem);
    color: #FFD9EE;
}
.legal-card h2 { margin: 32px 0 8px; font-family: var(--font-display); color: #FFC9E8; font-size: 1.35rem; }
.legal-card p, .legal-card li { color: var(--text-muted); }
.legal-meta { color: var(--text-soft); font-size: 0.9rem; }
.notice {
    margin: 18px 0 8px;
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px dashed rgba(98, 223, 255, 0.55);
    background: rgba(98, 223, 255, 0.08);
    color: #DDF7FF;
    font-size: 0.92rem;
}
.legal-card .btn { margin-top: 12px; }

/* ---------- Tablet / desktop ---------- */

@media (min-width: 640px) {
    .card-body { padding: 32px 36px 24px; }
    .card-deco--right { width: 160px; }
    .card-deco--left { width: 160px; }
    .field-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: clamp(8px, 1.3vh, 14px); }
    .field-grid > .field[data-channel="whatsapp"] { grid-column: 1 / -1; }
    .subscribe-form[data-pref="whatsapp"] .field-grid > .field[data-channel="whatsapp"] { grid-column: auto; }
    .hero-couple { max-width: 520px; }
    .hero-inner { padding-bottom: 28px; }
    .card-text { max-width: 36em; }
}

/* Desktop: one cinematic screen. Couple anchored bottom-left, content on the right. */
@media (min-width: 1024px) {
    :root { --header-h: 56px; }

    .brand-layer { display: block; }
    .hero-art {
        position: absolute;
        left: 0;
        bottom: 0;
        width: min(62vw, 1120px);
        height: 96%;
        display: block;
    }
    .hero-couple {
        width: 100%;
        height: 100%;
        max-width: none;
        object-fit: contain;
        object-position: left bottom;
    }
    .hero-inner {
        justify-content: flex-end;
        align-items: center;
        padding-block: clamp(8px, 1.6vh, 28px);
    }
    .hero-content { width: min(540px, max(40vw, 480px)); max-width: none; }
    .hero-title { font-size: clamp(1.6rem, min(2.5vw, 4.5vh), 2.8rem); margin-bottom: clamp(4px, 0.8vh, 8px); }
    .hero-lead { font-size: clamp(0.86rem, 1.7vh, 1rem); margin-bottom: clamp(10px, 2vh, 20px); }
    .status-pill { margin-bottom: clamp(6px, 1vh, 10px); padding: 3px 10px; font-size: 0.66rem; gap: 6px; }
    .status-dot { width: 7px; height: 7px; }

    /* Compact, height-aware form. */
    .subscribe-card::before { border-radius: 24px; }
    .card-body { padding: clamp(12px, 2vh, 26px) clamp(18px, 1.9vw, 28px) clamp(10px, 1.6vh, 18px); }
    .card-title { font-size: clamp(1.25rem, 3vh, 1.7rem); margin-bottom: 2px; }
    .card-text { max-width: 36em; font-size: 0.82rem; margin-bottom: clamp(6px, 1.4vh, 14px); }
    .subscribe-form { --form-gap: clamp(6px, 1vh, 12px); }
    .field-grid { gap: clamp(6px, 1.1vh, 12px) 10px; }
    .field, .pref-group { gap: 3px; }
    .field-label { font-size: 0.78rem; gap: 6px; }
    .tag { font-size: 0.68rem; }
    .input-wrap input { min-height: clamp(36px, 4.8vh, 42px); padding: 6px 12px 6px 38px; font-size: 0.9rem; border-radius: 12px; }
    .input-icon { left: 12px; width: 17px; height: 17px; }
    .segmented { padding: 3px; border-radius: 14px; }
    .segment span { min-height: clamp(30px, 4.1vh, 36px); padding-block: 4px; font-size: 0.86rem; border-radius: 11px; }
    .check { grid-template-columns: 18px 1fr; gap: 10px; font-size: 0.76rem; line-height: 1.45; }
    .check input, .check-box { width: 18px; height: 18px; }
    .check-box { border-radius: 6px; }
    .check input:checked + .check-box { background-size: 13px, auto; }
    .btn-block { min-height: clamp(38px, 5vh, 46px); padding-block: 8px; font-size: 0.95rem; }
    .spinner { width: 15px; height: 15px; }
    .form-note { font-size: 0.72rem; }
    .form-note svg { width: 12px; height: 12px; }
    .field-hint { font-size: 0.72rem; }
    .field-error { font-size: 0.74rem; line-height: 1.3; }
    .form-status { padding: 8px 12px; font-size: 0.82rem; }

    /* WhatsApp hint sits on the label row when the field is full width. */
    .subscribe-form:not([data-pref="whatsapp"]) .field[data-channel="whatsapp"] {
        grid-template-columns: 1fr auto;
        align-items: end;
        column-gap: 10px;
    }
    .subscribe-form:not([data-pref="whatsapp"]) .field[data-channel="whatsapp"] > .field-hint { grid-row: 1; grid-column: 2; }
    .subscribe-form:not([data-pref="whatsapp"]) .field[data-channel="whatsapp"] > .input-wrap,
    .subscribe-form:not([data-pref="whatsapp"]) .field[data-channel="whatsapp"] > .field-error { grid-column: 1 / -1; }

    .card-deco--right { width: 140px; }
    .card-deco--left { width: 140px; }

    .deco--top-right { width: clamp(160px, 14vw, 260px); opacity: 0.55; }
    .deco--bottom-left { width: clamp(240px, 24vw, 420px); opacity: 1; }
}

/* ---------- Viewport-locked landing page (tablet + desktop) ----------
   The shell is exactly one viewport tall. Every flex level below it has
   min-height: 0, so nothing can push the footer down. If the form needs
   more room than the hero has, only .form-scroll scrolls (inside the card);
   the card heading and the submit button stay put. Phones keep natural
   page scrolling. */
@media (min-width: 768px) {
    .page-home .shell {
        height: 100vh;
        height: 100dvh;
        min-height: 0;
    }
    .page-home .hero {
        flex: 1 1 0;
        min-height: 0;
        min-width: 0;
        overflow: clip;            /* decorative bleed (flowers, ribbons) only */
    }
    .page-home .hero-art { flex: none; }
    .page-home .hero-inner {
        flex: 1 1 0;
        min-height: 0;
        min-width: 0;
        align-items: stretch;
    }
    .page-home .hero-content {
        min-height: 0;
        justify-content: center;
    }
    .page-home .hero-content > * { flex-shrink: 0; }
    .page-home .subscribe-card {
        flex: 0 1 auto;
        min-height: 0;
        display: flex;
        flex-direction: column;
    }
    .page-home .card-body {
        flex: 0 1 auto;
        min-height: 0;
        display: flex;
        flex-direction: column;
    }
    .page-home .card-body > * { flex-shrink: 0; }
    .page-home .card-body > .subscribe-form:not([hidden]) {
        flex: 0 1 auto;
        min-height: 0;
        display: flex;
        flex-direction: column;
    }
    .page-home .subscribe-form > * { flex-shrink: 0; }
    .page-home .subscribe-form > .form-scroll {
        flex: 0 1 auto;
        min-height: 0;
        overflow-y: auto;
        overscroll-behavior: contain;
        /* room for focus rings inside the scroll box, aligned with the button */
        margin: -4px;
        padding: 4px;
        scrollbar-width: thin;
        scrollbar-color: rgba(255, 79, 163, 0.55) transparent;
    }
    .form-scroll::-webkit-scrollbar { width: 6px; }
    .form-scroll::-webkit-scrollbar-track { background: transparent; }
    .form-scroll::-webkit-scrollbar-thumb {
        border-radius: 6px;
        background: linear-gradient(180deg, var(--pink), var(--purple));
    }
    /* Soft fade at the edge(s) that have more content (classes set by main.js). */
    .form-scroll.is-scrollable:not(.at-end) {
        -webkit-mask-image: linear-gradient(180deg, #000 calc(100% - 22px), transparent);
        mask-image: linear-gradient(180deg, #000 calc(100% - 22px), transparent);
    }
    .form-scroll.is-scrollable:not(.at-start):not(.at-end) {
        -webkit-mask-image: linear-gradient(180deg, transparent, #000 18px, #000 calc(100% - 22px), transparent);
        mask-image: linear-gradient(180deg, transparent, #000 18px, #000 calc(100% - 22px), transparent);
    }
    .form-scroll.is-scrollable.at-end:not(.at-start) {
        -webkit-mask-image: linear-gradient(180deg, transparent, #000 18px);
        mask-image: linear-gradient(180deg, transparent, #000 18px);
    }
    .form-scroll:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; }
}

/* ---------- Parallax (camera pan) ----------
   main.js writes one variable, --par (-1 … 1): a slow idle sway blended with the
   mouse's horizontal position. Each layer turns it into its own left/right shift —
   deeper layers move less, nearer ones more — while the content plane (heading,
   form, wordmark, header, footer) stays still. Horizontal movement only.
   Edge-anchored artwork gets a bleed equal to its travel, so a cut edge is never
   revealed. Disabled entirely for prefers-reduced-motion. */
:root { --par: 0; }

@media (prefers-reduced-motion: no-preference) {
    .page-home .page-bg {
        /* the 4% scale leaves >= 7.8px of spare image per side, more than the travel */
        transform: translate3d(calc(var(--par) * 5px), 0, 0) scale(1.04);
        will-change: transform;
    }
    .page-home .petals {
        transform: translate3d(calc(var(--par) * 18px), 0, 0);
        will-change: transform;
    }
}

@media (min-width: 1024px) and (prefers-reduced-motion: no-preference) {
    .page-home .page-bg { transform: translate3d(calc(var(--par) * 8px), 0, 0) scale(1.04); }
    .page-home .petals { transform: translate3d(calc(var(--par) * 30px), 0, 0); }
    .page-home .hero-art {
        left: -20px;
        transform: translate3d(calc(var(--par) * 20px), 0, 0);
        will-change: transform;
    }
    .page-home .deco--bottom-left {
        left: -14px;
        transform: translate3d(calc(var(--par) * 14px), 0, 0);
        will-change: transform;
    }
    .page-home .deco--top-right {
        right: -14px;
        transform: translate3d(calc(var(--par) * 14px), 0, 0);
        will-change: transform;
    }
    .page-home .card-deco--right { transform: translate(16.2%, -25.3%) translate3d(calc(var(--par) * 4px), 0, 0); }
    .page-home .card-deco--left { transform: translate(-17.8%, 27.7%) translate3d(calc(var(--par) * 4px), 0, 0); }
}

/* ---------- Accessibility preferences ---------- */

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
    }
    .petals { display: none; }
    .btn-primary:hover, .header-icon:hover { transform: none; }
}

@media (forced-colors: active) {
    .hero-title { -webkit-text-fill-color: CanvasText; color: CanvasText; background: none; filter: none; }
    .btn-primary { border: 2px solid ButtonText; }
    .segment input:checked + span { outline: 2px solid Highlight; }
}

/* Decorative images that failed to load are hidden by main.js */
.is-broken { display: none !important; }
