/* =========================================================
   Stretching for Women — landing page
   Palette inspired by the Solace in-app aesthetic:
   cream/bone backgrounds, sage greens, blush pink accents,
   Fraunces elegant serif.
   ========================================================= */

:root {
    --cream:        #F5EFE4;
    --cream-2:      #EFE7D8;
    --cream-3:      #E9DFCD;
    --ink:          #15140F;
    --ink-2:        #2A2822;
    --mute:         #6C675B;
    --mute-soft:    #8F8A7D;
    --line:         #DFD5BF;
    --sage:         #8FA48A;
    --sage-deep:    #4F6B55;
    --sage-dark:    #233329;
    --blush:        #D9B8AF;
    --peach:        #E4C9A8;
    --gold:         #C9A86B;

    --radius:       22px;
    --radius-lg:    32px;
    --radius-pill:  999px;

    --shadow-soft:  0 8px 30px rgba(35, 51, 41, 0.06), 0 2px 6px rgba(35, 51, 41, 0.04);
    --shadow-card:  0 24px 60px -20px rgba(35, 51, 41, 0.18), 0 8px 20px -8px rgba(35, 51, 41, 0.08);
    --shadow-phone: 0 40px 80px -30px rgba(35, 51, 41, 0.35), 0 14px 30px -10px rgba(35, 51, 41, 0.18);

    --font-serif:   'Fraunces', 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
    --font-sans:    'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

    --max-width:    1160px;
}

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    font-family: var(--font-sans);
    font-size: 17px;
    line-height: 1.6;
    color: var(--ink);
    background: var(--cream);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

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

/* ---------- Ambient blobs ---------- */
.ambient {
    position: fixed;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
    z-index: 0;
    opacity: 0.55;
}
.ambient-1 {
    width: 520px;
    height: 520px;
    background: radial-gradient(circle, var(--blush) 0%, transparent 70%);
    top: -160px;
    right: -180px;
}
.ambient-2 {
    width: 640px;
    height: 640px;
    background: radial-gradient(circle, var(--sage) 0%, transparent 70%);
    bottom: -260px;
    left: -220px;
    opacity: 0.35;
}

/* ---------- Navigation ---------- */
#navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 32px;
    backdrop-filter: saturate(160%) blur(14px);
    -webkit-backdrop-filter: saturate(160%) blur(14px);
    background: rgba(245, 239, 228, 0.72);
    border-bottom: 1px solid rgba(223, 213, 191, 0.5);
}
.nav-logo {
    font-family: var(--font-serif);
    font-size: 22px;
    font-weight: 500;
    letter-spacing: -0.01em;
    color: var(--ink);
}
.nav-logo em {
    font-style: italic;
    color: var(--sage-deep);
}
.nav-cta {
    font-family: var(--font-sans);
    font-size: 14px;
    font-weight: 600;
    color: var(--ink);
    padding: 10px 18px;
    border-radius: var(--radius-pill);
    border: 1px solid var(--ink);
    transition: background 0.2s ease, color 0.2s ease, transform 0.15s ease;
}
.nav-cta:hover {
    background: var(--ink);
    color: var(--cream);
    transform: translateY(-1px);
}

/* ---------- Section scaffolding ---------- */
section {
    position: relative;
    z-index: 1;
    padding: 120px 32px;
    max-width: var(--max-width);
    margin: 0 auto;
}

.section-label {
    display: inline-block;
    font-family: var(--font-sans);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--sage-deep);
    margin-bottom: 20px;
}

.section-header {
    text-align: center;
    max-width: 760px;
    margin: 0 auto 64px;
}

h1, h2, h3 {
    font-family: var(--font-serif);
    font-weight: 500;
    color: var(--ink);
    letter-spacing: -0.01em;
    margin: 0 0 18px;
}
h1 em, h2 em, h3 em {
    font-style: italic;
    font-weight: 500;
    color: var(--sage-deep);
}

h1 {
    font-size: clamp(44px, 6.8vw, 84px);
    line-height: 1.02;
    letter-spacing: -0.025em;
}

h2 {
    font-size: clamp(32px, 4.6vw, 56px);
    line-height: 1.08;
    letter-spacing: -0.02em;
}

h3 {
    font-size: 22px;
    line-height: 1.3;
}

p {
    margin: 0 0 14px;
    color: var(--ink-2);
}

/* ---------- Hero ---------- */
.hero {
    padding-top: 60px;
    padding-bottom: 140px;
}
.hero-inner {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: 72px;
    align-items: center;
}
.eyebrow {
    display: inline-block;
    font-family: var(--font-sans);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--sage-deep);
    padding: 8px 16px;
    border: 1px solid var(--line);
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.5);
    margin-bottom: 28px;
}
.hero-sub {
    font-size: 19px;
    line-height: 1.55;
    color: var(--ink-2);
    max-width: 520px;
    margin: 22px 0 36px;
}
.hero-sub strong {
    font-weight: 600;
    color: var(--ink);
}

/* ---------- Waitlist form ---------- */
.waitlist {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    max-width: 520px;
    margin: 0;
}
.waitlist input[type="email"] {
    flex: 1 1 240px;
    min-width: 0;
    padding: 18px 22px;
    font-family: var(--font-sans);
    font-size: 16px;
    color: var(--ink);
    background: #FFFFFF;
    border: 1px solid var(--line);
    border-radius: var(--radius-pill);
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.waitlist input[type="email"]::placeholder {
    color: var(--mute-soft);
}
.waitlist input[type="email"]:focus {
    border-color: var(--sage-deep);
    box-shadow: 0 0 0 4px rgba(79, 107, 85, 0.12);
}
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 18px 30px;
    font-family: var(--font-sans);
    font-size: 15px;
    font-weight: 600;
    letter-spacing: 0.01em;
    color: var(--cream);
    background: var(--ink);
    border: 1px solid var(--ink);
    border-radius: var(--radius-pill);
    cursor: pointer;
    transition: transform 0.15s ease, background 0.2s ease, box-shadow 0.2s ease;
    box-shadow: var(--shadow-soft);
    white-space: nowrap;
}
.btn-primary:hover {
    background: var(--sage-dark);
    transform: translateY(-2px);
    box-shadow: 0 14px 32px -10px rgba(35, 51, 41, 0.35);
}
.btn-primary:active {
    transform: translateY(0);
}
.btn-primary svg {
    transition: transform 0.2s ease;
}
.btn-primary:hover svg {
    transform: translateX(3px);
}
.waitlist-note {
    flex: 1 0 100%;
    margin: 10px 0 0;
    font-size: 13px;
    color: var(--mute);
}
.waitlist-success {
    flex: 1 0 100%;
    margin: 14px 0 0;
    padding: 14px 18px;
    font-size: 15px;
    color: var(--sage-dark);
    background: rgba(143, 164, 138, 0.18);
    border: 1px solid rgba(79, 107, 85, 0.3);
    border-radius: var(--radius);
    line-height: 1.45;
}
.waitlist.is-loading .btn-primary {
    opacity: 0.6;
    pointer-events: none;
}

/* ---------- Phone mockups ---------- */
.hero-visual {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 620px;
}
.phone-frame {
    border-radius: 44px;
    padding: 10px;
    background: linear-gradient(150deg, #ffffff 0%, #efe4d3 100%);
    box-shadow: var(--shadow-phone);
    border: 1px solid rgba(255, 255, 255, 0.6);
    overflow: hidden;
    line-height: 0;
}
.phone-frame img {
    width: 260px;
    height: auto;
    border-radius: 36px;
    display: block;
}
.phone-hero {
    transform: rotate(-4deg);
    position: relative;
    z-index: 2;
}
.phone-offset {
    position: absolute;
    right: 4%;
    top: 8%;
    transform: rotate(6deg);
    z-index: 1;
    opacity: 0.96;
}
.phone-offset img {
    width: 230px;
}

.phone-small img {
    width: 220px;
}
.phone-tuck {
    margin-left: -60px;
    margin-top: 50px;
    transform: rotate(5deg);
}
.phone-tuck + .phone-frame,
.showcase-stack .phone-frame:first-child {
    transform: rotate(-4deg);
}

/* ---------- Why section ---------- */
.why {
    padding-top: 40px;
    padding-bottom: 40px;
    text-align: center;
}
.why h2 {
    max-width: 720px;
    margin: 0 auto 56px;
}
.pain-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 22px;
    text-align: left;
}
.pain-card {
    padding: 28px 26px 30px;
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
}
.pain-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-card);
    background: #FFFFFF;
}
.pain-icon {
    font-size: 28px;
    margin-bottom: 14px;
    line-height: 1;
}
.pain-card h3 {
    font-size: 19px;
    margin-bottom: 8px;
}
.pain-card p {
    font-size: 15px;
    color: var(--mute);
    margin: 0;
}

/* ---------- Showcase rows ---------- */
.showcase {
    padding-top: 40px;
}
.section-sub {
    font-size: 18px;
    color: var(--ink-2);
    max-width: 620px;
    margin: 0 auto;
    line-height: 1.55;
}
.showcase-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
    padding: 80px 0;
    border-top: 1px solid var(--line);
}
.showcase-row:first-of-type {
    border-top: 0;
}
.showcase-row.reverse .showcase-text {
    order: 2;
}
.showcase-row.reverse .showcase-visual {
    order: 1;
}
.showcase-text {
    max-width: 440px;
}
.step-mark {
    display: inline-block;
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 18px;
    color: var(--sage-deep);
    margin-bottom: 10px;
}
.showcase-text h3 {
    font-size: clamp(28px, 3vw, 40px);
    line-height: 1.15;
    margin-bottom: 14px;
}
.showcase-text p {
    font-size: 17px;
    color: var(--ink-2);
}
.showcase-visual {
    display: flex;
    justify-content: center;
}
.showcase-visual .phone-frame img {
    width: 280px;
}
.showcase-stack {
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

/* ---------- Promises grid ---------- */
.promises {
    padding-top: 60px;
    padding-bottom: 100px;
}
.promises-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 22px;
}
.promise-card {
    padding: 36px 28px 32px;
    background: #FFFFFF;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.promise-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-card);
}
.promise-mark {
    font-size: 26px;
    color: var(--sage-deep);
    margin-bottom: 16px;
    line-height: 1;
}
.promise-card h3 {
    font-size: 20px;
    margin-bottom: 8px;
}
.promise-card p {
    font-size: 15px;
    color: var(--mute);
    margin: 0;
    line-height: 1.55;
}

/* ---------- Final CTA ---------- */
.final-cta {
    padding-top: 40px;
    padding-bottom: 160px;
}
.cta-box {
    padding: clamp(44px, 6vw, 88px) clamp(28px, 5vw, 80px);
    background: linear-gradient(155deg, #FFFFFF 0%, var(--cream-2) 55%, var(--cream-3) 100%);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    text-align: center;
    position: relative;
    overflow: hidden;
}
.cta-box::before {
    content: "";
    position: absolute;
    top: -120px;
    right: -100px;
    width: 320px;
    height: 320px;
    background: radial-gradient(circle, rgba(217, 184, 175, 0.55), transparent 65%);
    pointer-events: none;
}
.cta-box::after {
    content: "";
    position: absolute;
    bottom: -120px;
    left: -120px;
    width: 360px;
    height: 360px;
    background: radial-gradient(circle, rgba(143, 164, 138, 0.4), transparent 65%);
    pointer-events: none;
}
.cta-box > * {
    position: relative;
    z-index: 1;
}
.cta-box h2 {
    max-width: 620px;
    margin: 0 auto 16px;
}
.cta-box p {
    max-width: 520px;
    margin: 0 auto 36px;
    font-size: 17px;
    color: var(--ink-2);
}
.waitlist-large {
    max-width: 560px;
    margin: 0 auto;
    justify-content: center;
}
.waitlist-large input[type="email"] {
    font-size: 17px;
    padding: 20px 24px;
}

/* ---------- Footer ---------- */
footer {
    border-top: 1px solid var(--line);
    padding: 40px 32px 48px;
    background: var(--cream-2);
    position: relative;
    z-index: 1;
}
.footer-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}
.footer-brand .nav-logo {
    font-size: 22px;
}
.footer-brand p {
    margin: 6px 0 0;
    font-size: 14px;
    color: var(--mute);
    max-width: 420px;
}
.footer-meta {
    font-size: 13px;
    color: var(--mute);
}

/* ---------- Reveal animation ---------- */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}
.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ---------- Responsive ---------- */

/* Tablet and below */
@media (max-width: 960px) {
    section {
        padding: 88px 24px;
    }
    #navbar {
        padding: 16px 22px;
        padding-left: max(22px, env(safe-area-inset-left));
        padding-right: max(22px, env(safe-area-inset-right));
    }
    .hero {
        padding-top: 40px;
        padding-bottom: 72px;
    }
    .hero-inner {
        grid-template-columns: 1fr;
        gap: 48px;
        text-align: center;
    }
    .hero-copy {
        max-width: 580px;
        margin: 0 auto;
    }
    .hero-sub {
        margin: 20px auto 30px;
    }
    .waitlist {
        margin: 0 auto;
        justify-content: center;
    }
    .hero-visual {
        min-height: 460px;
    }
    .showcase-row {
        grid-template-columns: 1fr;
        gap: 36px;
        padding: 56px 0;
        text-align: center;
    }
    .showcase-row.reverse .showcase-text,
    .showcase-row.reverse .showcase-visual {
        order: unset;
    }
    .showcase-text {
        margin: 0 auto;
    }
    .showcase-visual .phone-frame img {
        width: 260px;
    }
    .footer-inner {
        flex-direction: column;
        text-align: center;
        gap: 16px;
    }
}

/* Mobile: 640 and below (most phones landscape and portrait) */
@media (max-width: 640px) {
    html {
        -webkit-tap-highlight-color: transparent;
    }
    body {
        font-size: 16px;
    }
    section {
        padding: 64px 20px;
    }

    /* Navigation */
    #navbar {
        padding: 12px 18px;
        padding-top: max(12px, env(safe-area-inset-top));
        padding-left: max(18px, env(safe-area-inset-left));
        padding-right: max(18px, env(safe-area-inset-right));
    }
    .nav-logo {
        font-size: 17px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 58vw;
    }
    .nav-cta {
        padding: 9px 14px;
        font-size: 13px;
        flex-shrink: 0;
    }

    /* Typography */
    h1 {
        font-size: clamp(36px, 9.5vw, 52px);
        line-height: 1.05;
        letter-spacing: -0.02em;
        overflow-wrap: break-word;
    }
    h2 {
        font-size: clamp(28px, 7.2vw, 40px);
        line-height: 1.12;
        overflow-wrap: break-word;
    }
    h3 {
        font-size: 20px;
    }
    .section-header {
        margin-bottom: 44px;
    }
    .section-sub {
        font-size: 16px;
    }

    /* Hero */
    .hero {
        padding-top: 28px;
        padding-bottom: 56px;
    }
    .hero-sub {
        font-size: 16.5px;
        line-height: 1.5;
        margin: 18px auto 26px;
    }
    .eyebrow {
        font-size: 11px;
        padding: 7px 14px;
        margin-bottom: 22px;
    }
    .hero-visual {
        min-height: 380px;
    }

    /* Form — keep desktop-style inline layout on mobile */
    .waitlist {
        gap: 8px;
    }
    .waitlist input[type="email"] {
        flex: 1 1 160px;
        padding: 14px 18px;
        font-size: 16px; /* must be 16px+ to prevent iOS zoom on focus */
    }
    .btn-primary {
        padding: 14px 20px;
        font-size: 14px;
        gap: 8px;
    }
    .waitlist-note {
        margin: 8px 0 0;
        font-size: 12.5px;
    }

    /* Phones in hero */
    .phone-frame {
        border-radius: 36px;
        padding: 8px;
    }
    .phone-frame img {
        border-radius: 28px;
    }
    .phone-hero img {
        width: 210px;
    }
    .phone-offset {
        right: -2%;
        top: 2%;
    }
    .phone-offset img {
        width: 160px;
    }

    /* Pain cards */
    .why {
        padding-bottom: 24px;
    }
    .pain-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    .pain-card {
        padding: 22px 22px 24px;
        text-align: left;
    }
    .pain-card h3 {
        font-size: 18px;
    }
    .pain-card p {
        font-size: 14.5px;
    }

    /* Showcase rows */
    .showcase {
        padding-top: 24px;
    }
    .showcase-row {
        gap: 32px;
        padding: 44px 0;
    }
    .showcase-text h3 {
        font-size: clamp(24px, 6.5vw, 32px);
        line-height: 1.18;
    }
    .showcase-text p {
        font-size: 16px;
    }
    .showcase-visual .phone-frame img {
        width: 240px;
    }
    .showcase-stack {
        flex-direction: row;
        justify-content: center;
    }
    .phone-tuck {
        margin-left: -40px;
        margin-top: 28px;
    }
    .phone-small img {
        width: 180px;
    }

    /* Promises */
    .promises {
        padding-top: 32px;
        padding-bottom: 72px;
    }
    .promises-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    .promise-card {
        padding: 28px 24px;
    }
    .promise-card h3 {
        font-size: 19px;
    }
    .promise-card p {
        font-size: 14.5px;
    }

    /* Final CTA */
    .final-cta {
        padding-top: 20px;
        padding-bottom: 96px;
    }
    .cta-box {
        padding: 48px 22px;
        border-radius: 26px;
    }
    .cta-box p {
        font-size: 16px;
        margin-bottom: 28px;
    }
    .waitlist-large input[type="email"] {
        font-size: 16px;
        padding: 14px 18px;
    }

    /* Footer */
    footer {
        padding: 32px 20px 40px;
        padding-bottom: max(40px, env(safe-area-inset-bottom));
    }
    .footer-brand p {
        font-size: 13.5px;
    }
}

/* Ultra-narrow: iPhone SE / small Androids */
@media (max-width: 380px) {
    section {
        padding: 56px 16px;
    }
    #navbar {
        padding: 10px 14px;
    }
    .nav-logo {
        font-size: 16px;
        max-width: 55vw;
    }
    .nav-cta {
        padding: 8px 12px;
        font-size: 12.5px;
    }
    h1 {
        font-size: clamp(32px, 9vw, 40px);
    }
    h2 {
        font-size: clamp(26px, 7vw, 34px);
    }
    .phone-hero img {
        width: 186px;
    }
    .phone-offset img {
        width: 140px;
    }
    .showcase-visual .phone-frame img {
        width: 220px;
    }
    .phone-small img {
        width: 160px;
    }
    .phone-tuck {
        margin-left: -30px;
    }
    .cta-box {
        padding: 40px 18px;
    }
}

/* Landscape phones with short height */
@media (max-height: 520px) and (orientation: landscape) {
    .hero {
        padding-top: 24px;
        padding-bottom: 40px;
    }
    .hero-visual {
        min-height: 320px;
    }
}

/* High-DPI image sharpening */
@media (min-resolution: 2dppx) {
    .phone-frame img {
        image-rendering: -webkit-optimize-contrast;
    }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
    .reveal {
        opacity: 1;
        transform: none;
    }
    html {
        scroll-behavior: auto;
    }
}
