/* ===================================
   AEY Dev Studio - Avant-Garde Design System
   =================================== */

/* Google Fonts Import */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&family=Syne:wght@400;600;700;800&display=swap');

:root {
    /* Color Palette - Warm Cream & Indigo Accent */
    --bg-deep: #faf8f5;
    --bg-surface: #fffdf9;
    --bg-surface-trans: rgba(250, 248, 245, 0.9);
    
    --primary: #6366f1;
    --primary-glow: rgba(99, 102, 241, 0.3);
    --secondary: #2dd4bf;
    
    --text-main: #2d2a26;
    --text-muted: #6b6660;
    
    --border-subtle: rgba(45, 42, 38, 0.1);
    --border-glow: rgba(99, 102, 241, 0.3);

    /* Spacing & Layout */
    --container-width: 1200px;
    --header-height: 80px;
    
    /* Animation */
    --ease-elastic: cubic-bezier(0.68, -0.6, 0.32, 1.6);
    --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    background-color: var(--bg-deep);
    color: var(--text-main);
    font-family: 'Outfit', sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

/* Background Atmosphere */
body::before {
    content: '';
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: 
        radial-gradient(circle at 50% 50%, rgba(99, 102, 241, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(45, 212, 191, 0.05) 0%, transparent 30%);
    z-index: -1;
    pointer-events: none;
    animation: pulseAtmosphere 15s ease-in-out infinite alternate;
}

@keyframes pulseAtmosphere {
    0% { transform: scale(1); opacity: 0.8; }
    100% { transform: scale(1.1); opacity: 1; }
}

/* Typography - Syne for Headers, Outfit for Body */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Syne', sans-serif;
    color: var(--text-main);
    line-height: 1.1;
    letter-spacing: -0.02em;
}

h1 {
    font-size: clamp(3rem, 8vw, 6rem);
    font-weight: 800;
    background: linear-gradient(135deg, #2d2a26 0%, #6b6660 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

h2 {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 700;
    margin-bottom: 2rem;
}

p {
    color: var(--text-muted);
    font-size: 1.125rem;
    max-width: 65ch;
}

a {
    color: inherit;
    text-decoration: none;
    transition: all 0.3s var(--ease-smooth);
}

/* Layout Utilities */
.container {
    width: 90%;
    max-width: var(--container-width);
    margin: 0 auto;
    position: relative;
}

.section {
    padding: 8rem 0;
    position: relative;
}

/* Components: Button */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-subtle);
    border-radius: 100px;
    font-family: 'Syne', sans-serif;
    font-weight: 700;
    font-size: 1rem;
    color: var(--text-main);
    backdrop-filter: blur(10px);
    overflow: hidden;
    position: relative;
    z-index: 1;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0%;
    height: 100%;
    background: var(--primary);
    transition: width 0.4s var(--ease-elastic);
    z-index: -1;
}

.btn:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px -10px var(--primary-glow);
}

.btn:hover::before {
    width: 100%;
}

.btn-secondary {
    background: var(--primary);
    border-color: var(--primary);
}

.btn-secondary:hover {
    background: transparent;
    color: var(--primary);
}

.btn-secondary::before {
    display: none;
}

/* Header & Nav */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    height: var(--header-height);
    background: rgba(250, 248, 245, 0.9);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-subtle);
    z-index: 1000;
    display: flex;
    align-items: center;
}

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

.logo {
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    font-size: 1.5rem;
    letter-spacing: -0.05em;
    position: relative;
}

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

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

.nav a {
    font-size: 0.95rem;
    font-weight: 500;
    position: relative;
    opacity: 0.7;
}

.nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s var(--ease-smooth);
}

.nav a:hover {
    opacity: 1;
}

.nav a:hover::after {
    width: 100%;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: var(--header-height);
    background: radial-gradient(circle at 100% 0%, rgba(99, 102, 241, 0.1) 0%, transparent 40%);
}

.hero-content {
    max-width: 800px;
}

.hero-content h1 {
    margin-bottom: 1.5rem;
    line-height: 1;
}

.hero-content p {
    font-size: 1.5rem;
    margin-bottom: 3rem;
    opacity: 0.8;
}

/* Scroll Indicators */
.scroll-indicator {
    position: absolute;
    bottom: 3rem;
    left: 50%;
    transform: translateX(-50%);
    width: 1px;
    height: 80px;
    background: linear-gradient(to bottom, var(--text-muted) 0%, transparent 100%);
    opacity: 0.5;
}

/* Feature/Apps Section */
.apps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 4rem;
}

.app-card {
    background: rgba(255, 253, 249, 0.8);
    border: 1px solid var(--border-subtle);
    border-radius: 20px;
    padding: 2rem;
    transition: all 0.4s var(--ease-smooth);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(45, 42, 38, 0.06);
}

.app-card:hover {
    background: rgba(255, 253, 249, 0.95);
    border-color: var(--primary);
    transform: translateY(-10px) scale(1.01);
    box-shadow: 0 20px 40px -20px rgba(99, 102, 241, 0.25);
}

.app-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent 0%, rgba(79, 70, 229, 0.03) 100%);
    opacity: 0;
    transition: opacity 0.4s;
}

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

.app-card h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.app-card h3::after {
    content: '→';
    font-size: 1.25rem;
    opacity: 0;
    transform: translateX(-10px);
    transition: all 0.3s var(--ease-smooth);
    color: var(--primary);
}

.app-card:hover h3::after {
    opacity: 1;
    transform: translateX(0);
}

.app-number {
    font-family: 'Syne', sans-serif;
    font-size: 4rem;
    font-weight: 800;
    color: rgba(79, 70, 229, 0.08);
    position: absolute;
    top: 1rem;
    right: 2rem;
    z-index: 0;
}

/* Footer (Redesigned) */
.footer {
    border-top: 1px solid var(--border-subtle);
    padding: 6rem 0 2rem;
    background: linear-gradient(to top, #f5f2ed 0%, transparent 100%);
}

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

.footer-brand h4 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.footer-brand p {
    font-size: 1rem;
    opacity: 0.6;
}

.footer-section h5 {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.footer-section a {
    display: block;
    color: var(--text-main);
    margin-bottom: 0.75rem;
    opacity: 0.7;
}

.footer-section a:hover {
    opacity: 1;
    color: var(--primary);
}

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

/* Legal Pages Styling Overrides */
.legal-page {
    background: transparent;
    padding: 4rem 0;
    box-shadow: none;
    border: none;
    max-width: 800px;
    margin: 0 auto;
}

.legal-code {
    background: rgba(255, 253, 249, 0.8);
    padding: 3rem;
    border-radius: 20px;
    border: 1px solid var(--border-subtle);
}

.legal-code h2 {
    font-size: 1.75rem;
    color: var(--primary);
    margin-top: 3rem;
}

.legal-code h3 {
    font-size: 1.25rem;
    margin-top: 2rem;
    color: var(--text-main);
}

.legal-code ul {
    list-style: none;
}

.legal-code li {
    padding-left: 1.5rem;
    position: relative;
    margin-bottom: 0.75rem;
}

.legal-code li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 10px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--primary);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    h1 { font-size: 2.5rem; }
    h2 { font-size: 1.75rem; }
    
    .section {
        padding: 4rem 0;
    }
    
    .header .container {
        padding: 0 1rem;
    }
    
    .nav {
        gap: 1.5rem;
    }
    
    .nav a {
        font-size: 0.85rem;
    }
    
    .hero {
        min-height: auto;
        padding: 6rem 0 4rem;
        padding-top: calc(var(--header-height) + 2rem);
    }
    
    .hero-content {
        padding: 0 0.5rem;
    }
    
    .hero-content p {
        font-size: 1rem;
        margin-bottom: 2rem;
    }
    
    .btn {
        padding: 0.85rem 1.5rem;
        font-size: 0.9rem;
    }
    
    .apps-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        margin-top: 2rem;
    }
    
    .app-card {
        padding: 1.5rem;
    }
    
    .app-card h3 {
        font-size: 1.5rem;
    }
    
    .app-number {
        font-size: 3rem;
        top: 0.5rem;
        right: 1rem;
    }
    
    .footer {
        padding: 3rem 0 1.5rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }
    
    .footer-brand {
        grid-column: span 2;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }
    
    .scroll-indicator {
        display: none;
    }
}

/* Extra small devices */
@media (max-width: 480px) {
    h1 { font-size: 2rem; }
    
    .container {
        width: 95%;
    }
    
    .header {
        height: 60px;
    }
    
    .logo {
        font-size: 1.25rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
    
    .footer-brand {
        grid-column: span 1;
    }
}
