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

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
}

:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --bg-dark: #020617;
    --glass: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
    --text-white: #f8fafc;
    --text-muted: #94a3b8;
    --accent: #c084fc;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-white);
    overflow-x: hidden;
    width: 100%;
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(99, 102, 241, 0.05) 0%, transparent 40%),
        radial-gradient(circle at 90% 80%, rgba(192, 132, 252, 0.05) 0%, transparent 40%);
    background-attachment: fixed;
}

/* =========================================
   2. NAVBAR
   ========================================= */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 8%;
    position: fixed;
    width: 100%;
    top: 0;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    z-index: 1000;
    border-bottom: 1px solid var(--glass-border);
}

.logo {
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    cursor: pointer;
    color: #ffffff;
    display: flex;
    align-items: center;
    transition: 0.3s;
}

.logo span { 
    background: linear-gradient(135deg, #818cf8 0%, #c084fc 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 600;
    margin-left: 4px;
    filter: drop-shadow(0 0 12px rgba(192, 132, 252, 0.2));
}

.nav-links {
    display: flex;
    gap: 12px;
}

.nav-links button {
    padding: 10px 24px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    font-size: 0.9rem;
}

.btn-login {
    background: transparent;
    color: white;
    border: 1px solid var(--glass-border) !important;
}

.btn-login:hover {
    background: var(--glass);
}

.btn-signup {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

.btn-signup:hover { 
    background: var(--primary-dark); 
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

/* =========================================
   3. HERO SECTION
   ========================================= */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 120px 8% 60px;
    position: relative;
}

.hero-content {
    max-width: 650px;
    z-index: 5;
    animation: fadeInUp 0.8s ease-out;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

.hero h1 {
    font-size: clamp(2.8rem, 8vw, 4.5rem);
    line-height: 1.1;
    font-weight: 800;
    margin-bottom: 24px;
    letter-spacing: -0.03em;
}

.gradient-text {
    background: linear-gradient(90deg, #818cf8, #c084fc, #818cf8);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientShift 4s linear infinite;
}

@keyframes gradientShift {
    to { background-position: 200% center; }
}

.hero p {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: var(--text-muted);
    margin-bottom: 40px;
    line-height: 1.6;
}

.cta-group {
    display: flex;
    background: var(--glass);
    padding: 8px;
    border-radius: 16px;
    border: 1px solid var(--glass-border);
    max-width: 500px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    transition: 0.3s;
}

.cta-group:focus-within {
    border-color: rgba(99, 102, 241, 0.5);
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.1);
}

.hero-input {
    background: transparent;
    border: none;
    padding: 12px 20px;
    color: white;
    flex: 1;
    outline: none;
    font-size: 1rem;
}

.btn-main {
    background: white;
    color: black;
    padding: 14px 28px;
    border-radius: 12px;
    border: none;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    transition: 0.3s;
}

.btn-main:hover {
    transform: scale(1.02);
    box-shadow: 0 0 20px rgba(255,255,255,0.2);
}

/* =========================================
   4. FLOATING CARDS
   ========================================= */
.floating-cards {
    position: absolute;
    right: 5%;
    width: 450px;
    height: 450px;
    z-index: 1;
    pointer-events: none;
}

.card {
    position: absolute;
    padding: 16px 24px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 20px;
    animation: float 6s infinite ease-in-out;
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.2);
}

.card i { font-size: 1.2rem; }

.card-1 { top: 10%; left: 0%; animation-delay: 0s; color: #e1306c; }
.card-2 { top: 45%; right: 5%; animation-delay: 2s; color: #00f2ea; }
.card-3 { bottom: 10%; left: 15%; animation-delay: 4s; color: #ff0000; }

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0); }
    50% { transform: translateY(-30px) rotate(3deg); }
}

/* =========================================
   5. MODAL SYSTEM
   ========================================= */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; 
    width: 100%; height: 100%;
    background: rgba(2, 6, 23, 0.9);
    backdrop-filter: blur(12px);
    display: none; 
    justify-content: center;
    align-items: center;
    z-index: 9999;
    padding: 20px;
}

.modal {
    background: linear-gradient(145deg, #0f172a, #020617);
    padding: 48px 40px;
    border-radius: 32px;
    width: 100%;
    max-width: 440px;
    text-align: center;
    position: relative;
    border: 1px solid var(--glass-border);
    box-shadow: 0 40px 100px -20px rgba(0, 0, 0, 0.8);
    transform: translateY(40px) scale(0.9);
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-overlay.active { display: flex; }
.modal-overlay.active .modal {
    transform: translateY(0) scale(1);
    opacity: 1;
}

.icon-box {
    width: 72px;
    height: 72px;
    background: rgba(99, 102, 241, 0.1);
    color: #818cf8;
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    font-size: 2rem;
}

.modal h2 {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 12px;
    color: #fff;
    letter-spacing: -0.02em;
}

.modal p {
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 32px;
}

.btn-google {
    width: 100%;
    padding: 16px;
    border-radius: 18px;
    border: 1px solid #e2e8f0;
    background: white;
    color: #1e293b;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    font-weight: 700;
    font-size: 1.05rem;
    cursor: pointer;
    transition: 0.3s;
}

.btn-google:hover {
    background: #f8fafc;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.btn-google img { width: 24px; }

.close-btn {
    position: absolute;
    top: 24px; right: 24px;
    width: 40px; height: 40px;
    border-radius: 50%;
    background: var(--glass);
    color: #fff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
}

.close-btn:hover { background: rgba(255,255,255,0.1); }

.terms {
    margin-top: 32px;
    font-size: 0.85rem;
    color: #64748b;
}

.terms a { color: var(--primary); text-decoration: none; font-weight: 600; }

/* =========================================
   6. RESPONSIVE
   ========================================= */
@media (max-width: 768px) {
    .navbar { padding: 16px 5%; }
    .hero { padding: 120px 5% 60px; text-align: center; }
    .hero-content { margin: 0 auto; }
    .cta-group { flex-direction: column; background: transparent; border: none; padding: 0; box-shadow: none; }
    .hero-input { 
        background: var(--glass); 
        border-radius: 16px; 
        border: 1px solid var(--glass-border); 
        padding: 18px; 
        margin-bottom: 12px;
        width: 100%;
    }
    .btn-main { width: 100%; padding: 18px; }
    .floating-cards { display: none; }
}

@media (max-width: 480px) {
    .logo { font-size: 1.3rem; }
    .nav-links button { padding: 8px 16px; font-size: 0.85rem; }
    .modal-overlay { align-items: flex-end; padding: 0; }
    .modal {
        padding: 48px 30px;
        border-radius: 32px 32px 0 0;
        transform: translateY(100%);
        transition: 0.6s cubic-bezier(0.32, 0.72, 0, 1);
    }
}