:root {
    --bg-primary: #FFF8F5;
    --bg-secondary: #F5F4F1;
    --bg-white: #FFFFFF;
    --text-primary: #2D2926;
    --text-secondary: #6B635E;
    --text-tertiary: #A39E99;
    --coral: #E07A5F;
    --coral-light: #FF9A7B;
    --coral-soft: #FFF0EB;
    --green: #3D8A5A;
    --green-light: #C8F0D8;
    --border: #F0E8E4;
    --border-subtle: #E5E4E1;
    --shadow-warm: rgba(224, 122, 95, 0.08);
    --shadow-soft: rgba(45, 41, 38, 0.06);
    --surface-glass: rgba(255, 255, 255, 0.72);
    --pro-gold-start: #FFC107;
    --pro-gold-end: #FF9800;
}

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

body, html {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    overflow-x: hidden;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

::selection {
    background: var(--coral-soft);
    color: var(--coral);
}

/* Ambient Background */
.ambient-glow {
    position: fixed;
    border-radius: 50%;
    filter: blur(140px);
    z-index: -1;
    pointer-events: none;
}

.glow-1 {
    top: -200px;
    right: -100px;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(224, 122, 95, 0.12), transparent 70%);
    animation: drift 25s infinite alternate ease-in-out;
}

.glow-2 {
    bottom: 30%;
    left: -150px;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255, 154, 123, 0.1), transparent 70%);
    animation: drift 20s infinite alternate-reverse ease-in-out;
}

.glow-3 {
    top: 50%;
    right: -200px;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(61, 138, 90, 0.06), transparent 70%);
    animation: drift 30s infinite alternate ease-in-out;
}

@keyframes drift {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(40px, 60px) scale(1.15); }
}

/* Navbar */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 5%;
    background: rgba(255, 248, 245, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--border);
}

.logo {
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: -1px;
    color: var(--text-primary);
    text-decoration: none;
}

.logo span {
    color: var(--coral);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    padding: 0.5rem 1rem;
    border-radius: 12px;
    transition: color 0.25s, background 0.25s;
}

.nav-links a:hover {
    color: var(--text-primary);
    background: rgba(224, 122, 95, 0.06);
}

.btn-nav {
    background: var(--coral) !important;
    color: #fff !important;
    padding: 0.55rem 1.4rem !important;
    border-radius: 14px !important;
    font-weight: 600 !important;
    font-size: 0.9rem !important;
    transition: transform 0.25s, box-shadow 0.25s, background 0.25s !important;
    box-shadow: 0 2px 12px var(--shadow-warm);
}

.btn-nav:hover {
    background: var(--coral-light) !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 20px rgba(224, 122, 95, 0.2) !important;
}

/* Hero Section */
.hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 85vh;
    padding: 4rem 5%;
    gap: 4rem;
    max-width: 1400px;
    margin: 0 auto;
}

.hero-content {
    flex: 1;
    max-width: 560px;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 1.1rem;
    background: var(--coral-soft);
    color: var(--coral);
    border: 1px solid rgba(224, 122, 95, 0.15);
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 1.75rem;
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

.badge::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--coral);
    animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.8); }
}

.hero h1 {
    font-size: 3.75rem;
    font-weight: 700;
    line-height: 1.08;
    margin-bottom: 1.5rem;
    letter-spacing: -2px;
    color: var(--text-primary);
}

.gradient-text {
    background: linear-gradient(135deg, var(--coral), var(--coral-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.15rem;
    color: var(--text-secondary);
    line-height: 1.65;
    margin-bottom: 2.5rem;
    max-width: 480px;
}

.cta-group {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.app-store-badge {
    height: 48px;
    transition: transform 0.3s ease, opacity 0.3s;
    border-radius: 10px;
}

.app-store-badge:hover {
    transform: translateY(-2px) scale(1.02);
}

.hero-stats {
    display: flex;
    gap: 2.5rem;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}

.stat {
    display: flex;
    flex-direction: column;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: -0.5px;
}

.stat-label {
    font-size: 0.82rem;
    color: var(--text-tertiary);
    margin-top: 0.15rem;
}

/* Phone Mockup */
.hero-visual {
    flex: 1;
    display: flex;
    justify-content: center;
    perspective: 1200px;
}

.phone-mockup {
    width: 290px;
    height: 600px;
    background: var(--bg-primary);
    border-radius: 40px;
    border: 8px solid var(--text-primary);
    box-shadow:
        0 40px 80px rgba(45, 41, 38, 0.12),
        0 0 0 1px rgba(45, 41, 38, 0.05),
        inset 0 0 0 1px rgba(255, 255, 255, 0.3);
    position: relative;
    overflow: hidden;
    transform: rotateY(-8deg) rotateX(4deg);
    transition: transform 0.6s cubic-bezier(0.23, 1, 0.32, 1);
}

.phone-mockup:hover {
    transform: rotateY(0deg) rotateX(0deg);
}

.phone-notch {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 28px;
    background: var(--text-primary);
    border-radius: 0 0 18px 18px;
    z-index: 10;
}

.phone-screen {
    width: 100%;
    height: 100%;
    background: var(--bg-secondary);
    position: relative;
    padding: 3rem 1.25rem 1.5rem;
    overflow: hidden;
}

.app-ui {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.ui-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 0.25rem;
}

.ui-greeting {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-primary);
}

.ui-greeting small {
    display: block;
    font-size: 0.7rem;
    font-weight: 400;
    color: var(--text-tertiary);
    margin-top: 2px;
}

.ui-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--coral-soft), var(--coral-light));
    border: 2px solid #fff;
    box-shadow: 0 2px 8px var(--shadow-warm);
}

.ui-streak {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: var(--coral-soft);
    padding: 0.3rem 0.75rem;
    border-radius: 100px;
    font-size: 0.65rem;
    font-weight: 600;
    color: var(--coral);
    width: fit-content;
}

.ui-card {
    background: #fff;
    border: 1px solid var(--border);
    padding: 1rem;
    border-radius: 16px;
    box-shadow: 0 2px 12px var(--shadow-soft);
}

.ui-card h3 {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.ui-card p {
    font-size: 0.65rem;
    color: var(--text-tertiary);
}

.ui-card-habits {
    display: flex;
    gap: 0.4rem;
    margin-top: 0.6rem;
}

.habit-dot {
    width: 28px;
    height: 28px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    border: 1px solid var(--border);
    background: var(--bg-primary);
}

.habit-dot.done {
    background: var(--green-light);
    border-color: transparent;
}

.ui-score {
    background: linear-gradient(135deg, var(--coral), var(--coral-light));
    padding: 1rem;
    border-radius: 16px;
    color: #fff;
    position: relative;
    overflow: hidden;
}

.ui-score::after {
    content: '';
    position: absolute;
    top: -20px;
    right: -20px;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
}

.ui-score h3 {
    font-size: 0.7rem;
    font-weight: 500;
    opacity: 0.85;
    margin-bottom: 0.35rem;
}

.ui-score .score-value {
    font-size: 1.8rem;
    font-weight: 700;
    letter-spacing: -1px;
}

.ui-score .score-label {
    font-size: 0.6rem;
    opacity: 0.75;
    margin-top: 0.1rem;
}

/* How It Works */
.how-it-works {
    padding: 6rem 5%;
    max-width: 1400px;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-eyebrow {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: var(--coral);
    margin-bottom: 0.75rem;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    letter-spacing: -1.5px;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.05rem;
    color: var(--text-secondary);
    max-width: 520px;
    margin: 0 auto;
    line-height: 1.6;
}

.steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.step {
    text-align: center;
    padding: 2.5rem 2rem;
    border-radius: 24px;
    background: var(--bg-white);
    border: 1px solid var(--border);
    box-shadow: 0 4px 24px var(--shadow-soft);
    transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1), box-shadow 0.4s;
    position: relative;
}

.step:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 40px rgba(45, 41, 38, 0.1);
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: var(--coral-soft);
    color: var(--coral);
    font-weight: 700;
    font-size: 1.1rem;
    margin-bottom: 1.25rem;
}

.step h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.step p {
    color: var(--text-secondary);
    line-height: 1.55;
    font-size: 0.95rem;
}

/* Features Section */
.features {
    padding: 6rem 5%;
    max-width: 1400px;
    margin: 0 auto;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.feature-card {
    background: var(--bg-white);
    border: 1px solid var(--border);
    padding: 2rem;
    border-radius: 20px;
    box-shadow: 0 2px 16px var(--shadow-soft);
    transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1), box-shadow 0.4s;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--coral), var(--coral-light));
    opacity: 0;
    transition: opacity 0.3s;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(224, 122, 95, 0.1);
}

.feature-card:hover::before {
    opacity: 1;
}

.feature-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    margin-bottom: 1.25rem;
}

.feature-icon.coral { background: var(--coral-soft); }
.feature-icon.green { background: var(--green-light); }
.feature-icon.gold { background: #FFF3D6; }
.feature-icon.blue { background: #E8F4FD; }

.feature-card h3 {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 0.6rem;
    color: var(--text-primary);
}

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

/* CTA Banner */
.cta-banner {
    margin: 4rem 5%;
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
    padding: 4rem 3rem;
    background: linear-gradient(135deg, var(--coral), var(--coral-light));
    border-radius: 28px;
    text-align: center;
    position: relative;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(224, 122, 95, 0.2);
}

.cta-banner::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 400px;
    height: 400px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
}

.cta-banner::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
}

.cta-banner h2 {
    font-size: 2.25rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: -1px;
    margin-bottom: 0.75rem;
    position: relative;
    z-index: 1;
}

.cta-banner p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.05rem;
    margin-bottom: 2rem;
    max-width: 440px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
    position: relative;
    z-index: 1;
}

.cta-banner .app-store-badge {
    position: relative;
    z-index: 1;
    filter: brightness(0) invert(1);
}

/* Footer */
footer {
    border-top: 1px solid var(--border);
    padding: 3rem 5% 2rem;
    margin-top: 2rem;
    background: var(--bg-white);
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.footer-left {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.footer-logo {
    font-weight: 800;
    font-size: 1.3rem;
    letter-spacing: -1px;
    color: var(--text-primary);
}

.footer-tagline {
    font-size: 0.82rem;
    color: var(--text-tertiary);
}

.footer-links {
    display: flex;
    gap: 2rem;
}

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

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

.copyright {
    width: 100%;
    text-align: center;
    color: var(--text-tertiary);
    font-size: 0.8rem;
    padding-top: 1.5rem;
    margin-top: 1rem;
    border-top: 1px solid var(--border);
}

/* Legal Pages */
.legal-page {
    background: var(--bg-secondary);
    min-height: 100vh;
}

.legal-page .navbar {
    background: rgba(245, 244, 241, 0.85);
}

.legal-content {
    max-width: 720px;
    margin: 0 auto;
    padding: 3rem 5% 6rem;
    line-height: 1.75;
}

.legal-content .legal-header {
    margin-bottom: 2.5rem;
    padding: 2.5rem 2rem 2rem;
    background: var(--bg-white);
    border-radius: 20px;
    border: 1px solid var(--border);
    box-shadow: 0 2px 16px var(--shadow-soft);
}

.legal-content h1 {
    font-size: 2.5rem;
    font-weight: 700;
    letter-spacing: -1.5px;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.legal-content .legal-updated {
    font-size: 0.9rem;
    color: var(--text-tertiary);
}

.legal-content .legal-intro {
    font-size: 1.05rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 2rem;
    padding: 1.5rem 1.75rem;
    background: var(--coral-soft);
    border-radius: 16px;
    border: 1px solid rgba(224, 122, 95, 0.15);
}

.legal-section {
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.75rem 2rem;
    margin-bottom: 1rem;
    box-shadow: 0 1px 8px var(--shadow-soft);
}

.legal-section h2 {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    letter-spacing: -0.3px;
}

.legal-section p {
    color: var(--text-secondary);
    margin-bottom: 0;
    font-size: 0.95rem;
    line-height: 1.7;
}

.legal-content h2 {
    font-size: 1.15rem;
    font-weight: 600;
    margin-top: 2.5rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    letter-spacing: -0.3px;
}

.legal-content p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.legal-content .legal-footer {
    margin-top: 2rem;
    padding: 1.5rem 2rem;
    background: var(--bg-white);
    border: 1px solid var(--border);
    border-radius: 16px;
    font-size: 0.9rem;
    color: var(--text-tertiary);
    box-shadow: 0 1px 8px var(--shadow-soft);
}

.legal-content .legal-footer p {
    margin-bottom: 0;
    color: var(--text-tertiary);
}

/* Animations */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s cubic-bezier(0.23, 1, 0.32, 1), transform 0.7s cubic-bezier(0.23, 1, 0.32, 1);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* Responsive */
@media (max-width: 900px) {
    .hero {
        flex-direction: column;
        text-align: center;
        padding-top: 2rem;
        min-height: auto;
        gap: 3rem;
    }

    .hero-content {
        max-width: 100%;
    }

    .hero h1 {
        font-size: 2.75rem;
    }

    .hero-subtitle {
        margin-left: auto;
        margin-right: auto;
    }

    .cta-group {
        justify-content: center;
    }

    .hero-stats {
        justify-content: center;
    }

    .phone-mockup {
        transform: none;
        width: 260px;
        height: 530px;
    }

    .phone-mockup:hover {
        transform: none;
    }

    .steps {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

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

    .section-title {
        font-size: 2rem;
    }

    .cta-banner {
        padding: 3rem 1.5rem;
        margin: 3rem 5%;
    }

    .cta-banner h2 {
        font-size: 1.75rem;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
    }

    .footer-left {
        align-items: center;
    }

    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
        gap: 1.25rem;
    }

    .nav-links a:not(.btn-nav) {
        display: none;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 2.25rem;
        letter-spacing: -1.5px;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-stats {
        gap: 1.5rem;
    }

    .legal-content h1 {
        font-size: 2rem;
    }
}
