/* ==========================================================================
   Recipe Vault - Modern Design System & Stylesheet
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
    /* Color Palette - Culinary Emerald & Amber Gold */
    --primary: #0F382C;
    --primary-light: #1B4D3E;
    --primary-accent: #2D6A4F;
    --accent-amber: #E0A96D;
    --accent-gold: #F4A261;
    --accent-sage: #81B29A;
    --accent-coral: #E07A5F;
    
    /* Light Theme Neutral Variables */
    --bg-main: #FAF7F2;
    --bg-surface: #FFFFFF;
    --bg-surface-elevated: #F3EFEA;
    --border-color: rgba(15, 56, 44, 0.08);
    --border-color-hover: rgba(15, 56, 44, 0.2);
    --text-main: #1C2522;
    --text-muted: #5C6763;
    --text-light: #8E9894;
    
    /* Card Glassmorphism */
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(255, 255, 255, 0.6);
    --shadow-sm: 0 2px 8px rgba(15, 56, 44, 0.04);
    --shadow-md: 0 8px 24px rgba(15, 56, 44, 0.08);
    --shadow-lg: 0 20px 40px rgba(15, 56, 44, 0.12);
    --shadow-glow: 0 0 35px rgba(224, 169, 109, 0.25);
    
    /* Layout & Utilities */
    --radius-sm: 10px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-full: 9999px;
    --transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    
    --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-body: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* Dark Theme Overrides */
[data-theme="dark"] {
    --bg-main: #0B1210;
    --bg-surface: #141F1C;
    --bg-surface-elevated: #1D2B27;
    --border-color: rgba(255, 255, 255, 0.08);
    --border-color-hover: rgba(255, 255, 255, 0.2);
    --text-main: #F0F4F2;
    --text-muted: #A3B0AB;
    --text-light: #6E7D77;
    --glass-bg: rgba(20, 31, 28, 0.85);
    --glass-border: rgba(255, 255, 255, 0.08);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.6);
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
    overflow-x: hidden;
}

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

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

/* Typography Helpers */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-main);
}

/* Container */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Navigation Bar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
    transition: var(--transition);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 80px;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-heading);
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--text-main);
}

.brand-icon {
    width: 42px;
    height: 42px;
    border-radius: var(--radius-sm);
    box-shadow: 0 4px 12px rgba(15, 56, 44, 0.15);
    object-fit: cover;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 32px;
    list-style: none;
}

.nav-link {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-muted);
    transition: var(--transition);
}

.nav-link:hover {
    color: var(--accent-amber);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Theme Toggle Switch */
.theme-toggle {
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    width: 44px;
    height: 44px;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    font-size: 1.2rem;
}

.theme-toggle:hover {
    transform: scale(1.05);
    border-color: var(--accent-amber);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 26px;
    border-radius: var(--radius-full);
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    outline: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: #FFFFFF;
    box-shadow: 0 6px 18px rgba(15, 56, 44, 0.25);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(15, 56, 44, 0.35);
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary-accent) 100%);
}

.btn-secondary {
    background: var(--bg-surface);
    color: var(--text-main);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
    transform: translateY(-2px);
    border-color: var(--accent-amber);
    color: var(--accent-amber);
    box-shadow: var(--shadow-md);
}

.btn-amber {
    background: linear-gradient(135deg, var(--accent-amber) 0%, var(--accent-gold) 100%);
    color: #1C2522;
    box-shadow: 0 6px 18px rgba(244, 162, 97, 0.3);
}

.btn-amber:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(244, 162, 97, 0.45);
}

/* Hero Section */
.hero {
    padding-top: 150px;
    padding-bottom: 90px;
    position: relative;
    overflow: hidden;
}

.hero-glow-bg {
    position: absolute;
    top: 10%;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(224, 169, 109, 0.18) 0%, rgba(45, 106, 79, 0.08) 50%, rgba(0,0,0,0) 70%);
    pointer-events: none;
    z-index: 0;
    filter: blur(50px);
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    background: rgba(224, 169, 109, 0.15);
    border: 1px solid rgba(224, 169, 109, 0.3);
    border-radius: var(--radius-full);
    color: var(--accent-amber);
    font-weight: 700;
    font-size: 0.85rem;
    margin-bottom: 24px;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 20px;
    color: var(--text-main);
}

.hero-title span {
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent-amber) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

[data-theme="dark"] .hero-title span {
    background: linear-gradient(135deg, var(--accent-sage) 0%, var(--accent-amber) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-description {
    font-size: 1.15rem;
    color: var(--text-muted);
    margin-bottom: 36px;
    max-width: 540px;
}

.hero-ctas {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 40px;
}

.hero-stats {
    display: flex;
    align-items: center;
    gap: 32px;
    padding-top: 24px;
    border-top: 1px solid var(--border-color);
}

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

.stat-value {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-main);
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Phone Mockup Frame */
.hero-mockup-wrapper {
    position: relative;
    display: flex;
    justify-content: center;
}

.floating-icon-card {
    position: absolute;
    top: 20px;
    left: -20px;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    padding: 12px 20px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 10;
    animation: float 4s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.phone-mockup {
    width: 290px;
    height: 580px;
    background: #000;
    border-radius: 44px;
    padding: 12px;
    box-shadow: 0 25px 60px rgba(0,0,0,0.35);
    border: 4px solid #2B2E2C;
    position: relative;
    overflow: hidden;
}

.phone-notch {
    position: absolute;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    width: 110px;
    height: 24px;
    background: #000;
    border-radius: 12px;
    z-index: 20;
}

.phone-screen {
    width: 100%;
    height: 100%;
    border-radius: 34px;
    overflow: hidden;
    background: #111;
}

.phone-screen img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Feature Grid Section */
.section {
    padding: 90px 0;
}

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

.section-tag {
    font-size: 0.85rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent-amber);
    margin-bottom: 12px;
    display: block;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.section-subtitle {
    font-size: 1.05rem;
    color: var(--text-muted);
}

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

.feature-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    padding: 36px 28px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.feature-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-md);
    border-color: var(--border-color-hover);
}

.feature-icon-wrapper {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-md);
    background: rgba(224, 169, 109, 0.15);
    color: var(--accent-amber);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    margin-bottom: 24px;
}

.feature-card h3 {
    font-size: 1.3rem;
    margin-bottom: 12px;
}

.feature-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Interactive Demo Vault Section */
.demo-section {
    background: var(--bg-surface);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.demo-vault-box {
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 36px;
    box-shadow: var(--shadow-md);
}

.demo-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.demo-search {
    position: relative;
    flex: 1;
    min-width: 250px;
}

.demo-search input {
    width: 100%;
    padding: 12px 20px 12px 46px;
    border-radius: var(--radius-full);
    border: 1px solid var(--border-color);
    background: var(--bg-surface);
    color: var(--text-main);
    font-family: var(--font-body);
    font-size: 0.95rem;
    outline: none;
    transition: var(--transition);
}

.demo-search input:focus {
    border-color: var(--accent-amber);
    box-shadow: 0 0 0 3px rgba(224, 169, 109, 0.2);
}

.demo-search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
    font-size: 1.1rem;
}

.category-filter {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.cat-btn {
    padding: 8px 18px;
    border-radius: var(--radius-full);
    border: 1px solid var(--border-color);
    background: var(--bg-surface);
    color: var(--text-muted);
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.cat-btn.active, .cat-btn:hover {
    background: var(--primary);
    color: #FFFFFF;
    border-color: var(--primary);
}

.recipe-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.recipe-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.recipe-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--accent-amber);
}

.recipe-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.recipe-emoji {
    font-size: 1.8rem;
}

.recipe-badge {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    background: rgba(224, 169, 109, 0.2);
    color: var(--accent-amber);
}

.recipe-title {
    font-size: 1.15rem;
    margin-bottom: 8px;
}

.recipe-meta {
    display: flex;
    align-items: center;
    gap: 14px;
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.ingredients-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: auto;
}

.ing-tag {
    font-size: 0.75rem;
    padding: 4px 8px;
    border-radius: 6px;
    background: var(--bg-surface-elevated);
    color: var(--text-muted);
}

/* App Screenshots Section */
.screenshots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    justify-items: center;
}

.screenshot-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-md);
    text-align: center;
    transition: var(--transition);
    max-width: 360px;
}

.screenshot-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
}

.screenshot-frame {
    width: 100%;
    height: 480px;
    border-radius: var(--radius-md);
    overflow: hidden;
    margin-bottom: 20px;
    box-shadow: var(--shadow-sm);
}

.screenshot-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.screenshot-card h3 {
    font-size: 1.2rem;
    margin-bottom: 6px;
}

.screenshot-card p {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* CTA Download Banner */
.cta-banner {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-accent) 100%);
    border-radius: var(--radius-lg);
    padding: 60px 40px;
    color: #FFFFFF;
    text-align: center;
    box-shadow: var(--shadow-lg);
    position: relative;
    overflow: hidden;
}

.cta-banner h2 {
    color: #FFFFFF;
    font-size: 2.6rem;
    margin-bottom: 16px;
}

.cta-banner p {
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto 32px auto;
    opacity: 0.9;
}

.cta-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

/* Footer */
.site-footer {
    background: var(--bg-surface);
    border-top: 1px solid var(--border-color);
    padding: 60px 0 30px 0;
    margin-top: 60px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 50px;
    margin-bottom: 40px;
}

.footer-brand h3 {
    font-size: 1.4rem;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-brand p {
    color: var(--text-muted);
    font-size: 0.92rem;
    max-width: 320px;
}

.footer-col h4 {
    font-size: 1.05rem;
    margin-bottom: 18px;
    color: var(--text-main);
}

.footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-links a {
    color: var(--text-muted);
    font-size: 0.9rem;
    transition: var(--transition);
}

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

.footer-bottom {
    border-top: 1px solid var(--border-color);
    padding-top: 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.88rem;
    color: var(--text-muted);
    flex-wrap: wrap;
    gap: 16px;
}

/* Subpage Specific Layouts (Privacy Policy & 404) */
.subpage-header {
    padding-top: 140px;
    padding-bottom: 40px;
    text-align: center;
}

.subpage-title {
    font-size: 2.8rem;
    margin-bottom: 12px;
}

.policy-content {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 44px;
    box-shadow: var(--shadow-sm);
    margin-bottom: 60px;
}

.policy-section {
    margin-bottom: 36px;
}

.policy-section h2 {
    font-size: 1.5rem;
    color: var(--primary-accent);
    margin-bottom: 14px;
}

[data-theme="dark"] .policy-section h2 {
    color: var(--accent-sage);
}

.policy-section h3 {
    font-size: 1.15rem;
    margin: 18px 0 10px 0;
}

.policy-section p {
    color: var(--text-muted);
    margin-bottom: 12px;
}

.policy-section ul {
    margin-left: 24px;
    margin-bottom: 16px;
    color: var(--text-muted);
}

.policy-badge-box {
    background: var(--bg-surface-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    margin: 20px 0;
}

/* 404 Error Page */
.error-page {
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-top: 100px;
}

.error-content {
    max-width: 550px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 50px 30px;
    box-shadow: var(--shadow-lg);
}

.error-code {
    font-size: 5.5rem;
    font-weight: 800;
    color: var(--accent-coral);
    line-height: 1;
    margin-bottom: 10px;
}

.error-illustration {
    font-size: 4rem;
    margin-bottom: 20px;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}

/* Responsive Media Queries */
@media (max-width: 992px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-description {
        margin: 0 auto 36px auto;
    }
    
    .hero-ctas {
        justify-content: center;
    }
    
    .hero-stats {
        justify-content: center;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        display: none; /* Can be toggled if needed */
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .phone-mockup {
        width: 250px;
        height: 500px;
    }
    
    .floating-icon-card {
        display: none;
    }
    
    .policy-content {
        padding: 24px;
    }
}