/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=Inter:wght@300;400;500;600;700&display=swap');

/* Base Variables */
:root {
    /* Light Mode */
    --color-primary: #0F172A;
    --color-accent: #22D3EE;
    --color-text-primary: #020617;
    --color-text-secondary: #64748B;
    --color-surface: #F8FAFC;
    --color-border: #E2E8F0;
    --color-white: #FFFFFF;

    /* Typography */
    --font-heading: 'Space Grotesk', sans-serif;
    --font-body: 'Inter', sans-serif;

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;
    --spacing-2xl: 4rem;
}

/* Dark Mode Variables */
[data-theme="dark"] {
    --color-primary: #020617;
    --color-accent: #22D3EE;
    --color-text-primary: #E5E7EB;
    --color-text-secondary: #9CA3AF;
    --color-surface: rgba(2, 6, 23, 0.6);
    --color-border: rgba(255, 255, 255, 0.1);
    --color-white: #020617;
}

/* Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    font-size: 15px;
    line-height: 1.6;
    color: var(--color-text-primary);
    background-color: var(--color-surface);
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 600;
    line-height: 1.2;
    color: var(--color-text-primary);
}

h1 {
    font-size: clamp(36px, 5vw, 56px);
}

h2 {
    font-size: clamp(28px, 4vw, 40px);
}

h3 {
    font-size: clamp(24px, 3vw, 32px);
}

p {
    color: var(--color-text-secondary);
    font-size: 15px;
}

/* Glassmorphism */
.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

[data-theme="dark"] .glass {
    background: rgba(2, 6, 23, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Neomorphism */
.neomorphic {
    background: var(--color-surface);
    box-shadow: 8px 8px 16px rgba(0, 0, 0, 0.1),
        -8px -8px 16px rgba(255, 255, 255, 0.1);
    border: none;
}

[data-theme="dark"] .neomorphic {
    box-shadow: 8px 8px 16px rgba(0, 0, 0, 0.3),
        -8px -8px 16px rgba(255, 255, 255, 0.05);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    font-family: var(--font-body);
    font-size: 15px;
    font-weight: 500;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, #0EA5E9 0%, #22D3EE 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(34, 211, 238, 0.3);
}

.btn-outline {
    border: 2px solid var(--color-accent);
    color: var(--color-accent);
    background: transparent;
}

.btn-outline:hover {
    background: var(--color-accent);
    color: white;
}

/* Theme Toggle */
.theme-toggle {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
}

.theme-toggle:hover {
    transform: scale(1.1);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 1rem 0;
    transition: all 0.3s ease;
    background: var(--color-white);
    border-bottom: 1px solid var(--color-border);
}

[data-theme="dark"] .navbar {
    background: var(--color-primary);
    border-bottom-color: var(--color-border);
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--color-border);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

[data-theme="dark"] .navbar.scrolled {
    background: rgba(2, 6, 23, 0.95);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* Active Menu State */
.navbar a.nav-active,
[data-mobile-menu] a.nav-active {
    color: #22D3EE !important;
    position: relative;
    font-weight: 600;
}

.navbar a.nav-active::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, #0EA5E9 0%, #22D3EE 100%);
    border-radius: 2px;
}

[data-mobile-menu] a.nav-active::before {
    content: '';
    position: absolute;
    left: -1rem;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 70%;
    background: linear-gradient(180deg, #0EA5E9 0%, #22D3EE 100%);
    border-radius: 0 4px 4px 0;
}


/* Mobile Menu */
[data-mobile-menu] {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    background: var(--color-white);
    margin-top: 1rem;
    border-top: 1px solid var(--color-border);
    display: block;
}

[data-mobile-menu].open {
    max-height: 500px;
}

[data-mobile-menu].hidden {
    display: none;
    max-height: 0;
}

[data-theme="dark"] [data-mobile-menu] {
    background: var(--color-primary);
    border-top-color: var(--color-border);
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

@media (min-width: 1024px) {
    .navbar {
        background: var(--color-white);
        border-bottom: 1px solid var(--color-border);
    }

    [data-theme="dark"] .navbar {
        background: var(--color-primary);
        border-bottom-color: var(--color-border);
    }
}

/* Cards */
.card {
    background: var(--color-white);
    border-radius: 1rem;
    padding: 1.5rem;
    border: 1px solid var(--color-border);
    transition: all 0.3s ease;
}

[data-theme="dark"] .card {
    background: var(--color-surface);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Utility Classes */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.section {
    padding: 4rem 0;
}

.text-gradient {
    background: linear-gradient(135deg, #0EA5E9 0%, #22D3EE 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Hero Section Dark Mode */
[data-theme="dark"] .hero-bg {
    background: linear-gradient(135deg, rgba(2, 6, 23, 0.8) 0%, rgba(15, 23, 42, 0.8) 50%, rgba(2, 6, 23, 0.8) 100%) !important;
}

[data-theme="dark"] .hero-blob-1,
[data-theme="dark"] .hero-blob-2,
[data-theme="dark"] .hero-blob-3 {
    opacity: 0.1 !important;
    mix-blend-mode: screen;
}

[data-theme="dark"] .hero-heading {
    color: #FFFFFF !important;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .hero-description {
    color: #E5E7EB !important;
}

[data-theme="dark"] .hero-content .text-sm {
    color: #22D3EE !important;
}

[data-theme="dark"] .hero-stat {
    color: #22D3EE !important;
    text-shadow: 0 0 10px rgba(34, 211, 238, 0.3);
}

[data-theme="dark"] .hero-content .text-sm.font-medium {
    color: #9CA3AF !important;
}

/* Home 2 Hero Dark Mode */
[data-theme="dark"] .hero-bg-home2 {
    background: linear-gradient(135deg, #020617 0%, #0F172A 50%, #020617 100%) !important;
    opacity: 0.98 !important;
}

[data-theme="dark"] .hero-heading-home2 {
    color: #FFFFFF !important;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.5), 0 0 20px rgba(34, 211, 238, 0.2) !important;
}

[data-theme="dark"] .hero-heading-home2 .text-cyan-300 {
    color: #67E8F9 !important;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.5), 0 0 20px rgba(103, 232, 249, 0.3) !important;
}

[data-theme="dark"] .hero-description-home2 {
    color: #E5E7EB !important;
    opacity: 1 !important;
    text-shadow: 0 1px 6px rgba(0, 0, 0, 0.5) !important;
}

/* Responsive */
@media (max-width: 768px) {
    .section {
        padding: 2rem 0;
    }

    h1 {
        font-size: 32px;
    }

    h2 {
        font-size: 24px;
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}