@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    /* Color Palette */
    --bg-primary: #0b1220;
    --bg-secondary: #111b2e;
    --surface-glass: rgba(255, 255, 255, 0.05);
    --surface-glass-hover: rgba(255, 255, 255, 0.08);
    --surface-glass-border: rgba(255, 255, 255, 0.1);
    
    --accent-primary: #60a5fa;
    --accent-secondary: #22c55e;
    --highlight: #facc15;
    
    --text-primary: #f8fafc;
    --text-secondary: #cbd5f5;
    --text-muted: #94a3b8;
    
    --danger: #ef4444;

    /* Geometry */
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --max-width: 1200px;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Background Effects */
.bg-glow {
    position: fixed;
    top: -20%;
    left: -10%;
    width: 50vw;
    height: 50vw;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(96, 165, 250, 0.15) 0%, rgba(11, 18, 32, 0) 70%);
    z-index: -1;
    pointer-events: none;
}

.bg-glow-2 {
    position: fixed;
    bottom: -20%;
    right: -10%;
    width: 60vw;
    height: 60vw;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(34, 197, 94, 0.1) 0%, rgba(11, 18, 32, 0) 70%);
    z-index: -1;
    pointer-events: none;
}

/* Typography */
h1, h2, h3, h4 {
    color: var(--text-primary);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 { font-size: clamp(2.5rem, 5vw, 4rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(2rem, 4vw, 3rem); letter-spacing: -0.01em; }
h3 { font-size: 1.5rem; }
p { color: var(--text-secondary); margin-bottom: 1rem; }
a { color: var(--accent-primary); text-decoration: none; transition: all 0.3s ease; }
a:hover { color: var(--text-primary); }

.text-gradient {
    background: linear-gradient(135deg, var(--accent-primary), #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.text-green { color: var(--accent-secondary); }
.text-gold { color: var(--highlight); }

/* Layout & Containers */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 2rem;
}

section {
    padding: 6rem 0;
}

/* Header & Nav */
header {
    background: rgba(11, 18, 32, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--surface-glass-border);
    position: sticky;
    top: 0;
    z-index: 100;
}

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

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo svg {
    width: 28px;
    height: 28px;
    fill: var(--accent-primary);
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.95rem;
}

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background: var(--accent-primary);
    color: #000;
}

.btn-primary:hover {
    background: #7db4fb;
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(96, 165, 250, 0.3);
}

.btn-glass {
    background: var(--surface-glass);
    border: 1px solid var(--surface-glass-border);
    color: var(--text-primary);
    backdrop-filter: blur(10px);
}

.btn-glass:hover {
    background: var(--surface-glass-hover);
    transform: translateY(-2px);
}

/* Glassmorphism Cards */
.glass-card {
    background: var(--surface-glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--surface-glass-border);
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

/* Dashboard UI Simulation (Home Page) */
.hero-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    min-height: calc(100vh - 80px);
}

.dashboard-mockup {
    position: relative;
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
}

.mockup-main {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.mockup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.balance-title {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.balance-amount {
    font-size: 2.5rem;
    font-weight: 700;
}

.trend-up {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: var(--accent-secondary);
    font-size: 0.875rem;
    background: rgba(34, 197, 94, 0.1);
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius-sm);
}

/* Fake Chart */
.chart-container {
    height: 120px;
    display: flex;
    align-items: flex-end;
    gap: 0.5rem;
    padding-top: 1rem;
    border-bottom: 1px solid var(--surface-glass-border);
}

.chart-bar {
    flex: 1;
    background: rgba(96, 165, 250, 0.2);
    border-radius: 4px 4px 0 0;
    transition: height 1s ease-out;
    position: relative;
}

.chart-bar:hover {
    background: var(--accent-primary);
}

.chart-bar.active {
    background: var(--accent-primary);
}

.chart-bar.warning {
    background: var(--highlight);
}

/* Savings Progress */
.savings-widget {
    background: rgba(0,0,0,0.2);
    border-radius: var(--radius-md);
    padding: 1rem;
}

.savings-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.progress-track {
    width: 100%;
    height: 8px;
    background: var(--bg-primary);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
    width: 0%; /* Animated via JS */
    border-radius: 4px;
    transition: width 1.5s cubic-bezier(0.22, 1, 0.36, 1);
}

/* AI Insight Card */
.ai-insight {
    position: absolute;
    bottom: -20px;
    right: -30px;
    background: var(--bg-secondary);
    border: 1px solid var(--surface-glass-border);
    padding: 1rem;
    border-radius: var(--radius-md);
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    max-width: 280px;
    transform: translateY(20px);
    opacity: 0;
    animation: floatUp 0.8s ease-out forwards 1s;
}

.ai-icon {
    background: rgba(250, 204, 21, 0.1);
    color: var(--highlight);
    padding: 0.5rem;
    border-radius: 50%;
    display: flex;
}

.ai-text h4 {
    font-size: 0.875rem;
    margin-bottom: 0.25rem;
}

.ai-text p {
    font-size: 0.75rem;
    margin-bottom: 0;
    color: var(--text-muted);
}

@keyframes floatUp {
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

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

.feature-card {
    padding: 2rem;
    border-radius: var(--radius-lg);
    background: linear-gradient(180deg, var(--surface-glass) 0%, transparent 100%);
    border: 1px solid var(--surface-glass-border);
    transition: transform 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    border-color: rgba(96, 165, 250, 0.3);
}

.feature-icon {
    width: 48px;
    height: 48px;
    background: rgba(96, 165, 250, 0.1);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: var(--accent-primary);
}

/* Forms */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.form-control {
    width: 100%;
    padding: 0.75rem 1rem;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--surface-glass-border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-family: inherit;
    transition: all 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: rgba(0, 0, 0, 0.4);
}

textarea.form-control {
    min-height: 120px;
    resize: vertical;
}

/* Pricing Tables */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.pricing-card {
    position: relative;
    display: flex;
    flex-direction: column;
}

.pricing-card.popular {
    border-color: var(--accent-primary);
    box-shadow: 0 0 30px rgba(96, 165, 250, 0.1);
}

.popular-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent-primary);
    color: #000;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.25rem 1rem;
    border-radius: 20px;
    text-transform: uppercase;
}

.price {
    font-size: 3rem;
    font-weight: 700;
    margin: 1rem 0;
    color: var(--text-primary);
}

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

.pricing-features {
    list-style: none;
    margin: 2rem 0;
    flex-grow: 1;
}

.pricing-features li {
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
}

.pricing-features svg {
    color: var(--accent-secondary);
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

/* Simple Legal Content Formatting */
.content-doc {
    max-width: 800px;
    margin: 0 auto;
}

.content-doc h2 {
    margin-top: 2.5rem;
    font-size: 1.5rem;
}

.content-doc p, .content-doc ul {
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
}

.content-doc ul {
    padding-left: 1.5rem;
}

/* Footer */
footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--surface-glass-border);
    padding: 4rem 0 2rem;
    margin-top: 4rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 2rem;
    margin-bottom: 3rem;
}

.footer-col h4 {
    font-size: 1rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

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

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

.footer-bottom {
    border-top: 1px solid var(--surface-glass-border);
    padding-top: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Responsive */
@media (max-width: 900px) {
    .hero-split {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
        padding-top: 3rem;
    }
    
    .hero-split p {
        margin: 0 auto 2rem;
    }
    
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .ai-insight {
        right: 0;
        bottom: -40px;
    }
}

@media (max-width: 600px) {
    .nav-links {
        display: none; /* In a real app, implement a hamburger menu here */
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    h1 {
        font-size: 2.5rem;
    }
}