:root {
    /* Color Palette */
    --bg-gradient-1: #fbf7ff;
    --bg-gradient-2: #eef3fb;

    /* Brand */
    --brand-magenta: #CB30E0;
    --brand-blue: #0088FF;
    --brand-grad: linear-gradient(135deg, #CB30E0, #0088FF);

    /* Icon Colors based on design */
    --color-orange: #eaa991;
    --color-purple: #c597db;
    --color-green: #90d3a5;
    --color-blue: #88bae6;
    --color-pink: #ec94b9;
    --color-brown: #d7c1a2;

    /* Glass Effects */
    --glass-bg: rgba(255, 255, 255, 0.4);
    --glass-border: rgba(255, 255, 255, 0.5);
    --glass-border-light: rgba(255, 255, 255, 0.8);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.1);
    
    /* Typography */
    --font-serif: 'Playfair Display', serif;
    --font-sans: 'Inter', sans-serif;
    --text-primary: #1a1a1a;
    --text-secondary: #5a5a5a;
    --text-muted: #888888;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-sans);
    color: var(--text-primary);
    overflow-x: hidden;
    min-height: 100vh;
    background:
        radial-gradient(1200px 620px at 12% -8%, rgba(203, 48, 224, 0.16), transparent 60%),
        radial-gradient(1100px 640px at 112% 6%, rgba(0, 136, 255, 0.16), transparent 58%),
        linear-gradient(180deg, #fbf8ff 0%, #eef3fb 100%);
    background-attachment: fixed;
}

/* Background gradient mesh — animated 3×3 mesh gradient painted on a <canvas>
   by script.js (mirrors the iOS/Android app). The radial-gradient below is the
   pre-paint / no-WebGL fallback so there's never a blank flash. */
/* Branded background now lives on <body> (a reliable CSS aurora). The old
   animated <canvas> mesh rendered unpredictably (sometimes solid black), so it's
   hidden in favour of the always-correct gradient. */
.background-mesh { display: none; }

/* Cinematic fade-in — content is invisible until JS adds .content-visible to body */
nav, main, footer {
    opacity: 0;
    transition: opacity 1.4s cubic-bezier(0.4, 0, 0.2, 1);
}

body.content-visible nav,
body.content-visible main,
body.content-visible footer {
    opacity: 1;
}

/* Glassmorphism Utilities */
.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-top: 1px solid var(--glass-border-light);
    border-left: 1px solid var(--glass-border-light);
    box-shadow: var(--glass-shadow);
}

.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-top: 1px solid var(--glass-border-light);
    border-left: 1px solid var(--glass-border-light);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
    border-radius: 24px;
    padding: 24px;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

/* Navigation */
.glass-nav {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    width: max-content;
    max-width: calc(100vw - 24px);
    border-radius: 40px;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border-light);
    box-shadow: var(--glass-shadow);
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 32px;
    gap: 40px;
}

.nav-content .logo,
.footer-nav .logo {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 600;
    background: var(--brand-grad);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.nav-links {
    display: flex;
    gap: 20px;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    transition: color 0.2s ease;
}

.nav-links a:hover {
    color: var(--text-primary);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 24px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
}

.btn i {
    width: 18px;
    height: 18px;
}

.btn-primary.nav-btn {
    background: var(--text-primary);
    color: white;
    padding: 10px 20px;
    border-radius: 20px;
}

.btn-primary.nav-btn:hover {
    background: #333;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 96px 24px 48px;
}

.hero-grid {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: 56px;
    align-items: center;
}

.hero-copy { text-align: left; }

.hero-logo {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 24px;
}

.hero-mark {
    font-family: var(--font-serif);
    font-size: 2rem;
    background: var(--brand-grad);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-word {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 600;
}

.hero-headline {
    font-family: var(--font-serif);
    font-weight: 600;
    font-size: clamp(2.4rem, 4.6vw, 3.6rem);
    line-height: 1.08;
    letter-spacing: -0.02em;
    margin-bottom: 20px;
}

.hero-headline .grad {
    background: var(--brand-grad);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-sub {
    font-size: clamp(1.05rem, 1.4vw, 1.2rem);
    color: var(--text-secondary);
    max-width: 520px;
    line-height: 1.6;
    margin-bottom: 32px;
}

.hero-trial {
    margin-top: 16px;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.store-badges {
    display: flex;
    gap: 16px;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-start;
}

.store-badge img {
    height: 48px;
    width: auto;
    transition: transform 0.2s ease;
}

.store-badge.google-play-badge img {
    height: 70px;
    margin: -11px 0; /* PNG has built-in padding; pull it back to match the App Store badge */
}

.store-badge:hover img { transform: scale(1.05); }

/* Hero phone mockup */
.hero-visual { display: flex; justify-content: center; }

.phone {
    width: 300px;
    max-width: 100%;
    border-radius: 44px;
    padding: 14px;
    background: linear-gradient(160deg, #16131f, #0a0911);
    box-shadow: 0 36px 80px -24px rgba(120, 30, 160, 0.45), 0 12px 32px rgba(0, 0, 0, 0.22);
}

.phone-screen {
    border-radius: 32px;
    padding: 18px;
    background: linear-gradient(165deg, #f4ebfb, #e7f0ff);
    display: flex;
    flex-direction: column;
    gap: 11px;
}

.phone-prompt {
    background: rgba(255, 255, 255, 0.72);
    border-radius: 16px;
    padding: 14px;
}

.phone-cat {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.72rem;
    font-weight: 700;
    color: #9c6b5a;
    margin-bottom: 8px;
}

.phone-cat i { width: 14px; height: 14px; }

.phone-prompt p {
    font-size: 0.82rem;
    line-height: 1.45;
    color: #3a3550;
}

.phone-tone {
    background: #fff;
    border-radius: 14px;
    padding: 11px 14px;
    border-left: 4px solid;
    box-shadow: 0 2px 10px rgba(40, 20, 60, 0.05);
}

.phone-tone span {
    display: block;
    font-size: 0.64rem;
    font-weight: 800;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    margin-bottom: 5px;
}

.phone-tone p {
    font-size: 0.8rem;
    line-height: 1.4;
    color: #2c2740;
}

.t-warm { border-color: #D4537E; }
.t-warm span { color: #b53e69; }
.t-direct { border-color: #378ADD; }
.t-direct span { color: #1f6fc0; }
.t-firm { border-color: #7F77DD; }
.t-firm span { color: #5249c0; }

/* Hero stacks on tablet / phone */
@media (max-width: 920px) {
    .hero { padding: 92px 22px 48px; min-height: auto; }
    .hero-grid { grid-template-columns: 1fr; gap: 40px; }
    .hero-copy { text-align: center; }
    .hero-logo { justify-content: center; }
    .hero-sub { margin-left: auto; margin-right: auto; }
    .store-badges { justify-content: center; }
}

/* Sections Common */
section {
    padding: 80px 24px;
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    text-align: center;
    font-size: clamp(1.6rem, 4.5vw, 2.2rem);
    margin-bottom: 48px;
    font-weight: 600;
}

.section-subtitle {
    text-align: center;
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: -30px auto 48px auto;
}

/* Features Grid */
.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    max-width: 900px;
    margin: 0 auto;
}

.feature-card h3 {
    font-size: 1.25rem;
    margin-bottom: 8px;
    font-weight: 600;
}

.feature-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.4;
}

.icon-wrapper {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    color: white;
}

.icon-wrapper.small {
    width: 40px;
    height: 40px;
    margin-bottom: 0;
}

.icon-wrapper i {
    width: 28px;
    height: 28px;
}

.icon-wrapper.small i {
    width: 20px;
    height: 20px;
}

/* Icon Colors */
.bg-orange { background-color: var(--color-orange); }
.bg-purple { background-color: var(--color-purple); }
.bg-green { background-color: var(--color-green); }
.bg-blue { background-color: var(--color-blue); }
.bg-pink { background-color: var(--color-pink); }
.bg-brown { background-color: var(--color-brown); }

/* App Mockup */
.showcase {
    display: flex;
    justify-content: center;
}

.app-mockup {
    max-width: 400px;
    width: 100%;
    margin: 0 auto;
    border-radius: 32px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.mockup-header {
    display: flex;
    align-items: center;
    gap: 16px;
}

.back-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.6);
}

.mockup-title-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.mockup-title-group h3 {
    font-size: 1.1rem;
    font-family: var(--font-serif);
    margin-bottom: 2px;
}

.mockup-title-group p {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.mockup-tabs {
    display: flex;
    border-radius: 20px;
    padding: 4px;
}

.mockup-tabs .tab {
    flex: 1;
    text-align: center;
    padding: 8px 0;
    font-size: 0.9rem;
    font-weight: 500;
    border-radius: 16px;
    cursor: pointer;
    color: var(--text-secondary);
}

.mockup-tabs .tab.active {
    background: rgba(255, 255, 255, 0.8);
    color: var(--text-primary);
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.mockup-banner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-radius: 16px;
    font-size: 0.85rem;
}

.banner-text {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
}

.banner-text i {
    width: 16px;
    height: 16px;
    color: #6a6a6a;
}

.upgrade-btn {
    color: #CB30E0;
    font-weight: 600;
    cursor: pointer;
}

.mockup-input-area {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.mockup-input-area label {
    font-weight: 600;
    font-size: 0.95rem;
    margin-left: 4px;
}

.textarea-glass {
    min-height: 120px;
    border-radius: 16px;
    padding: 16px;
    color: var(--text-muted);
    font-size: 0.95rem;
    display: flex;
    align-items: flex-start;
}

.mockup-recipient {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 14px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.mockup-recipient i {
    width: 15px;
    height: 15px;
    flex-shrink: 0;
    color: var(--text-secondary);
}

.recipient-placeholder {
    color: var(--text-muted);
}

.mockup-progress {
    display: flex;
    gap: 6px;
}

.progress-pip {
    flex: 1;
    height: 3px;
    border-radius: 999px;
    background: rgba(0,0,0,0.12);
}

.progress-pip.active {
    background: rgba(0,0,0,0.7);
}

.mockup-guided-card {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 20px;
    border-radius: 20px;
}

.guided-question {
    font-size: 1rem;
    font-weight: 500;
    text-align: center;
}

.guided-textarea {
    min-height: 72px;
}

.mockup-generate-btn-wrap {
    display: flex;
    justify-content: center;
}

.mockup-generate-btn {
    padding: 14px 28px;
    border-radius: 50px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    cursor: pointer;
    border: 1px solid var(--glass-border);
    background: rgba(255, 255, 255, 0.45);
    transition: all 0.2s ease;
}

.mockup-generate-btn i {
    width: 16px;
    height: 16px;
}

.mockup-generate-btn:hover {
    background: rgba(255, 255, 255, 0.65);
}

/* Pricing Section */
.pricing-grid {
    display: flex;
    gap: 32px;
    justify-content: center;
    max-width: 800px;
    margin: 0 auto;
    flex-wrap: wrap;
}

.pricing-card {
    flex: 1;
    min-width: 300px;
    max-width: 380px;
    display: flex;
    flex-direction: column;
    position: relative;
}

.premium-card {
    border: 1px solid rgba(203, 48, 224, 0.4);
    box-shadow: 0 12px 48px rgba(203, 48, 224, 0.15);
}

.premium-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: #CB30E0;
    color: white;
    padding: 4px 16px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.pricing-header {
    text-align: center;
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--glass-border);
}

.pricing-header h3 {
    font-size: 1.5rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.price {
    font-family: var(--font-serif);
    font-size: 3rem;
    font-weight: 700;
    color: var(--text-primary);
}

.price span {
    font-family: var(--font-sans);
    font-size: 1rem;
    font-weight: 400;
    color: var(--text-secondary);
}

.pricing-features {
    list-style: none;
    margin-bottom: 32px;
    flex: 1;
}

.pricing-features li {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    font-size: 1rem;
    color: var(--text-primary);
}

.check-icon {
    color: #CB30E0;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

/* Tone Example */
.examples .section-subtitle {
    margin-bottom: 40px;
}

.example-prompt {
    max-width: 640px;
    margin: 0 auto 36px;
    border-radius: 20px;
    padding: 20px 24px;
}

.example-prompt-head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.example-situation {
    font-size: 1.05rem;
    line-height: 1.55;
    color: var(--text-primary);
}

.example-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    max-width: 1000px;
    margin: 0 auto;
}

.tone-card {
    display: flex;
    flex-direction: column;
    gap: 14px;
    text-align: left;
}

.tone-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.tone-label {
    font-weight: 600;
    font-size: 0.9rem;
    padding: 5px 14px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.5);
}

.tone-warm { color: #c2683f; }
.tone-direct { color: #3f73c2; }
.tone-firm { color: #4a5568; }

.tone-msg {
    font-size: 0.98rem;
    line-height: 1.6;
    color: var(--text-primary);
}

.copy-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: none;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.8rem;
    font-weight: 600;
    transition: color 0.2s ease, background 0.2s ease;
}

.copy-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.45);
}

.copy-btn svg {
    width: 18px;
    height: 18px;
}

.copied-text {
    display: none;
    color: #2e9e6b;
}

.copy-btn.copied svg {
    display: none;
}

.copy-btn.copied .copied-text {
    display: inline;
}

/* Footer links */
.footer-links {
    display: flex;
    gap: 20px;
    margin: 4px 0;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s ease;
}

.footer-links a:hover {
    color: var(--text-primary);
}

/* Content pages (Privacy, Support) */
.page {
    max-width: 820px;
    margin: 0 auto;
    padding: 56px 24px 96px;
}

.page-home {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 600;
    margin-bottom: 24px;
    transition: color 0.2s ease;
}

.page-home:hover {
    color: var(--text-primary);
}

.page-home i {
    width: 18px;
    height: 18px;
}

.legal {
    border-radius: 24px;
    padding: 40px;
}

.legal h1 {
    font-family: var(--font-serif);
    font-size: clamp(2rem, 5vw, 2.75rem);
    font-weight: 600;
    margin-bottom: 8px;
}

.legal .updated {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 32px;
}

.legal h2 {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 32px 0 12px;
}

.legal h3 {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 24px 0 8px;
}

.legal p,
.legal li {
    color: var(--text-secondary);
    line-height: 1.7;
    font-size: 1rem;
}

.legal p {
    margin-bottom: 16px;
}

.legal ul {
    margin: 0 0 16px 22px;
}

.legal li {
    margin-bottom: 8px;
}

.legal a {
    color: #0088FF;
    text-decoration: none;
    font-weight: 500;
}

.legal a:hover {
    text-decoration: underline;
}

.legal strong {
    color: var(--text-primary);
    font-weight: 600;
}

.contact-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 4px 0 12px;
    padding: 14px 24px;
    border-radius: 16px;
    background: #CB30E0;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    transition: background 0.2s ease;
}

.contact-btn:hover {
    background: #0088FF;
}

.contact-btn i {
    width: 18px;
    height: 18px;
}

/* Footer */
footer {
    padding-bottom: 120px; /* Space for the bottom nav */
}

.footer-nav {
    position: static;
    transform: none;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 24px;
}

.footer-nav p {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Animations */
.fade-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}

.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }

/* ------------------------------------------------------------------ *
 * Responsive — desktop (base) · tablet · phone · small phone
 * Narrower breakpoints come later so they override the wider ones.
 * ------------------------------------------------------------------ */

/* Tablet (and small laptops) */
@media (max-width: 1024px) {
    section {
        padding: 64px 24px;
    }

    .nav-content {
        gap: 28px;
        padding: 12px 24px;
    }
}

/* Phone */
@media (max-width: 768px) {
    /* Bottom pill becomes an app-style tab bar: links only, no logo */
    .nav-content .logo {
        display: none;
    }

    .nav-content {
        gap: 0;
        padding: 12px 22px;
    }

    .nav-links {
        display: flex;
        gap: 18px;
        font-size: 0.95rem;
    }

    .nav-links a {
        padding: 4px 2px; /* roomier tap target */
    }

    .glass-nav {
        bottom: calc(16px + env(safe-area-inset-bottom));
    }

    section {
        padding: 56px 20px;
    }

    .section-title {
        margin-bottom: 32px;
    }

    .hero {
        padding: 0 20px;
    }

    .hero .title {
        font-size: clamp(3rem, 13vw, 4rem);
    }

    .hero .subtitle {
        margin-bottom: 36px;
    }

    .glass-card {
        padding: 20px;
    }

    .app-mockup {
        padding: 20px;
    }

    .example-grid {
        grid-template-columns: 1fr;
    }

    .legal {
        padding: 28px 22px;
    }

    .footer-links {
        gap: 16px;
    }

    /* Stack pricing cards full-width so they never overflow narrow screens */
    .pricing-grid {
        flex-direction: column;
        align-items: center;
    }

    .pricing-card {
        min-width: 0;
        width: 100%;
        max-width: 420px;
    }

    /* Clear the floating nav + the home indicator */
    footer {
        padding-bottom: calc(108px + env(safe-area-inset-bottom));
    }
}

/* Small phones */
@media (max-width: 480px) {
    section {
        padding: 48px 16px;
    }

    .hero {
        padding: 0 16px;
    }

    .hero .title {
        font-size: 2.75rem;
        letter-spacing: -0.5px;
    }

    .hero .subtitle {
        font-size: 1.1rem;
        margin-bottom: 32px;
    }

    .nav-content {
        padding: 11px 16px;
    }

    .nav-links {
        gap: 14px;
        font-size: 0.9rem;
    }

    .grid-container {
        grid-template-columns: 1fr;
    }

    .price {
        font-size: 2.5rem;
    }

    .store-badge img {
        height: 44px;
    }

    .store-badge.google-play-badge img {
        height: 64px;
    }

    .glass-card {
        padding: 18px;
    }
}

/* Short, wide screens (e.g. phones held in landscape) */
@media (max-height: 600px) and (orientation: landscape) {
    .hero {
        min-height: auto;
        padding: 120px 24px 72px;
    }

    .hero-content {
        margin-top: 0;
    }
}
