/* ==========================================================================
   SnapHaven Website Design System & Global Styles
   ========================================================================== */

:root {
    /* Color Palette */
    --bg-dark: #07090e;
    --bg-card: rgba(15, 23, 42, 0.75);
    --bg-card-hover: rgba(30, 41, 59, 0.85);
    --bg-input: #0f172a;
    --border-color: rgba(56, 189, 248, 0.15);
    --border-highlight: rgba(56, 189, 248, 0.4);
    
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    
    --accent-cyan: #38bdf8;
    --accent-indigo: #6366f1;
    --accent-emerald: #10b981;
    --accent-amber: #f59e0b;
    --accent-rose: #f43f5e;
    
    --rainbow-gradient: linear-gradient(135deg, #ef4444 0%, #f59e0b 25%, #10b981 50%, #3b82f6 75%, #8b5cf6 100%);
    --cyan-glow: 0 0 25px rgba(56, 189, 248, 0.35);
    --purple-glow: 0 0 35px rgba(99, 102, 241, 0.3);
    
    --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
    
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 24px;
    --radius-full: 9999px;
    
    --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-smooth: 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Reset & Base Setup */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

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

body {
    background-color: var(--bg-dark);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Background Ambient Glows */
.ambient-glow {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.glow-orb-1 {
    position: absolute;
    top: -10%;
    left: 50%;
    transform: translateX(-50%);
    width: 700px;
    height: 500px;
    background: radial-gradient(ellipse at center, rgba(56, 189, 248, 0.14) 0%, rgba(99, 102, 241, 0.05) 50%, transparent 70%);
    pointer-events: none;
}

.glow-orb-2 {
    position: absolute;
    top: 40%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(ellipse at center, rgba(139, 92, 246, 0.12) 0%, transparent 70%);
    pointer-events: none;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text-primary);
}

.gradient-text {
    background: linear-gradient(135deg, #ffffff 0%, #38bdf8 50%, #8b5cf6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.rainbow-text {
    background: var(--rainbow-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Layout Containers */
.container {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 1;
}

section {
    padding: 100px 0;
    position: relative;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    padding: 20px 0;
    transition: var(--transition-smooth);
    background: rgba(7, 9, 14, 0.6);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.navbar.scrolled {
    padding: 14px 0;
    background: rgba(7, 9, 14, 0.92);
    border-bottom: 1px solid var(--border-color);
}

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

.nav-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--text-primary);
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 700;
}

.brand-icon-img {
    width: 44px;
    height: 44px;
    max-width: 44px;
    max-height: 44px;
    flex-shrink: 0;
    border-radius: 10px;
    object-fit: cover;
    filter: drop-shadow(0 0 12px rgba(56, 189, 248, 0.45));
}

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

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition-fast);
}

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

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 24px;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: var(--transition-smooth);
}

.btn-primary {
    background: linear-gradient(135deg, #0284c7 0%, #4f46e5 100%);
    color: #ffffff;
    box-shadow: 0 4px 20px rgba(2, 132, 199, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(2, 132, 199, 0.5);
    background: linear-gradient(135deg, #0369a1 0%, #4338ca 100%);
}

.btn-secondary {
    background: rgba(30, 41, 59, 0.7);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: rgba(51, 65, 85, 0.9);
    border-color: var(--border-highlight);
    transform: translateY(-2px);
}

.badge-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.badge-cyan {
    background: rgba(56, 189, 248, 0.12);
    color: var(--accent-cyan);
    border: 1px solid rgba(56, 189, 248, 0.3);
}

.badge-amber {
    background: rgba(245, 158, 11, 0.12);
    color: var(--accent-amber);
    border: 1px solid rgba(245, 158, 11, 0.3);
}

/* Hero Section */
.hero-section {
    padding-top: 170px;
    padding-bottom: 90px;
    text-align: center;
}

.hero-title {
    font-size: 3.8rem;
    line-height: 1.1;
    margin-bottom: 24px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    max-width: 720px;
    margin: 0 auto 40px;
    font-weight: 400;
}

.hero-cta-group {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 60px;
}

/* Glass Cards */
.glass-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 32px;
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.glass-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-highlight);
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
}

/* Hero Demo Mockup */
.demo-window {
    max-width: 960px;
    margin: 0 auto;
    border-radius: var(--radius-lg);
    background: rgba(15, 23, 42, 0.95);
    border: 1px solid rgba(56, 189, 248, 0.25);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.8), var(--cyan-glow);
    overflow: hidden;
    text-align: left;
}

.window-header {
    background: rgba(30, 41, 59, 0.7);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.window-dots {
    display: flex;
    gap: 8px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}
.dot-red { background: #ff5f56; }
.dot-yellow { background: #ffbd2e; }
.dot-green { background: #27c93f; }

.window-title {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

.window-body {
    padding: 32px;
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 32px;
    align-items: center;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-top: 50px;
}

.feature-icon-box {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-md);
    background: rgba(56, 189, 248, 0.1);
    border: 1px solid rgba(56, 189, 248, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: var(--accent-cyan);
}

.feature-title {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.feature-desc {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* How It Works Steps */
.steps-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    margin-top: 60px;
}

.step-card {
    text-align: center;
    position: relative;
}

.step-number {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0284c7, #6366f1);
    color: #ffffff;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 0 20px rgba(2, 132, 199, 0.4);
}

/* Savings Calculator Section */
.pricing-box {
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.9) 0%, rgba(30, 41, 59, 0.7) 100%);
    border: 1px solid var(--border-highlight);
    border-radius: var(--radius-lg);
    padding: 48px;
    max-width: 800px;
    margin: 40px auto 0;
    position: relative;
    box-shadow: var(--purple-glow);
    text-align: center;
}

.pricing-badge {
    position: absolute;
    top: -16px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--rainbow-gradient);
    color: #ffffff;
    padding: 4px 18px;
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.price-display {
    font-size: 4rem;
    font-family: var(--font-heading);
    font-weight: 800;
    color: #ffffff;
    margin: 16px 0;
}

.price-subtext {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Modal Popup */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(7, 9, 14, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition-smooth);
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-card {
    background: #0f172a;
    border: 1px solid var(--border-highlight);
    border-radius: var(--radius-lg);
    padding: 36px;
    max-width: 480px;
    width: 90%;
    text-align: center;
    box-shadow: 0 25px 60px rgba(0,0,0,0.8);
    position: relative;
}

.modal-close-btn {
    position: absolute;
    top: 16px;
    right: 16px;
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
}

.modal-close-btn:hover {
    color: var(--text-primary);
}

/* Footer */
footer {
    padding: 60px 0 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    font-size: 0.9rem;
}

.footer-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-link {
    color: var(--text-muted);
    text-decoration: none;
    transition: var(--transition-fast);
}

.footer-link:hover {
    color: var(--accent-cyan);
}

/* Responsive Breakpoints */
@media (max-width: 992px) {
    .hero-title { font-size: 2.8rem; }
    .window-body { grid-template-columns: 1fr; }
    .steps-container { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .nav-links { display: none; }
    .hero-title { font-size: 2.2rem; }
    .hero-subtitle { font-size: 1.05rem; }
    section { padding: 60px 0; }
}
