
/* ================================
   1. GLOBAL STYLES
================================ */

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

:root {
    --bg-primary: #080b14;
    --bg-secondary: #101522;
    --bg-card: #111827;
    --text-primary: #f8fafc;
    --text-secondary: #9ca3af;
    --accent: #8b5cf6;
    --accent-light: #a78bfa;
    --border: rgba(255, 255, 255, 0.09);
}

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

html {
    scroll-behavior: smooth;
}

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

a {
    text-decoration: none;
    color: inherit;
}

.landing-page {
    width: 100%;
    min-height: 100vh;
    overflow: hidden;
}

/* ================================
   2. NAVIGATION BAR
================================ */

.navbar {
    width: 100%;
    height: 82px;
    padding: 0 8%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border);
    background: rgba(8, 11, 20, 0.85);
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 21px;
    font-weight: 800;
    letter-spacing: -0.8px;
}

.logo-icon {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 9px;
    background: linear-gradient(135deg, #8b5cf6, #6366f1);
    color: white;
    font-size: 22px;
}

.logo-highlight {
    color: var(--accent-light);
}

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

.nav-links a {
    color: var(--text-secondary);
    font-size: 14px;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: white;
}

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

/* ================================
   3. BUTTONS
================================ */

.btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-outline {
    padding: 10px 19px;
    border: 1px solid var(--border);
    color: white;
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.07);
}

.btn-primary {
    padding: 11px 20px;
    color: white;
    background: linear-gradient(135deg, #8b5cf6, #6366f1);
    box-shadow: 0 5px 20px rgba(139, 92, 246, 0.2);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(139, 92, 246, 0.35);
}

.btn-secondary {
    padding: 14px 24px;
    border: 1px solid var(--border);
    color: white;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.07);
}

.btn-large {
    padding: 15px 25px;
    font-size: 15px;
}

/* ================================
   4. HERO SECTION
================================ */

.hero {
    position: relative;
    min-height: 590px;
    padding: 110px 20px 90px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background:
        radial-gradient(
            ellipse at 50% 20%,
            rgba(109, 40, 217, 0.19),
            transparent 55%
        );
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 8px 15px;
    margin-bottom: 30px;
    border: 1px solid rgba(167, 139, 250, 0.25);
    border-radius: 30px;
    background: rgba(139, 92, 246, 0.08);
    color: #c4b5fd;
    font-size: 12px;
    font-weight: 600;
}

.status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #a78bfa;
    box-shadow: 0 0 10px #a78bfa;
}

.hero h1 {
    max-width: 850px;
    font-size: clamp(38px, 6vw, 65px);
    line-height: 1.15;
    letter-spacing: -2.8px;
    font-weight: 800;
}

.hero h1 span {
    display: block;
    background: linear-gradient(90deg, #a78bfa, #818cf8, #c084fc);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-description {
    max-width: 620px;
    margin-top: 25px;
    color: var(--text-secondary);
    font-size: 16px;
    line-height: 1.8;
}

.hero-actions {
    display: flex;
    gap: 15px;
    margin-top: 35px;
}

.hero-note {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 24px;
    margin-top: 35px;
    color: #9ca3af;
    font-size: 12px;
}

.hero-note span {
    color: #a78bfa;
    font-weight: 700;
}

/* ================================
   5. FEATURES SECTION
================================ */

.features {
    padding: 90px 8% 110px;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
}

.section-heading {
    text-align: center;
    margin-bottom: 55px;
}

.section-label {
    color: var(--accent-light);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
}

.section-heading h2 {
    margin-top: 13px;
    font-size: clamp(25px, 4vw, 36px);
    letter-spacing: -1px;
}

.section-heading p {
    margin-top: 12px;
    color: var(--text-secondary);
    font-size: 14px;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.feature-card {
    padding: 28px 24px;
    min-height: 220px;
    border: 1px solid var(--border);
    border-radius: 13px;
    background: var(--bg-card);
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-6px);
    border-color: rgba(167, 139, 250, 0.5);
    background: #171e30;
}

.feature-icon {
    width: 43px;
    height: 43px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: rgba(139, 92, 246, 0.14);
    color: #c4b5fd;
    font-size: 23px;
}

.feature-card h3 {
    margin-top: 22px;
    font-size: 16px;
    font-weight: 700;
}

.feature-card p {
    margin-top: 10px;
    color: var(--text-secondary);
    font-size: 13px;
    line-height: 1.8;
}

/* ================================
   6. FOOTER
================================ */

.footer {
    min-height: 100px;
    padding: 25px 8%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    background: var(--bg-primary);
    border-top: 1px solid var(--border);
}

.footer p,
.footer > span {
    color: var(--text-secondary);
    font-size: 12px;
}

/* ================================
   7. RESPONSIVE DESIGN
================================ */

@media (max-width: 1000px) {
    .feature-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .navbar {
        padding: 0 5%;
    }
}

@media (max-width: 650px) {
    .navbar {
        height: auto;
        min-height: 75px;
        padding: 18px 5%;
        flex-wrap: wrap;
        gap: 15px;
    }

    .nav-links {
        display: none;
    }

    .nav-actions {
        gap: 8px;
    }

    .btn-outline,
    .nav-actions .btn-primary {
        padding: 9px 12px;
        font-size: 12px;
    }

    .hero {
        padding: 85px 20px 70px;
    }

    .hero h1 {
        letter-spacing: -1.5px;
    }

    .hero-description {
        font-size: 14px;
    }

    .hero-actions {
        flex-direction: column;
        width: 100%;
        max-width: 280px;
    }

    .hero-note {
        gap: 12px;
        font-size: 11px;
    }

    .features {
        padding: 70px 6%;
    }

    .feature-grid {
        grid-template-columns: 1fr;
    }

    .footer {
        flex-direction: column;
        text-align: center;
    }
}

/* Conversation history item layout */

.conversation-item-wrapper {
    display: flex;
    align-items: center;
    gap: 6px;
    width: 100%;
}

.conversation-item-wrapper .conversation-item {
    flex: 1;
    min-width: 0;
}

/* Conversation delete button */

.conversation-delete-btn {
    flex-shrink: 0;
    width: 30px;
    height: 30px;
    border: none;
    border-radius: 6px;
    background: transparent;
    color: #9ca3af;
    font-size: 21px;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}

.conversation-delete-btn:hover {
    background: rgba(239, 68, 68, 0.12);
    color: #ef4444;
}

.conversation-delete-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* =========================================
   THEME TOGGLE & LIGHT THEME STYLES
========================================= */

.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 9px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    cursor: pointer;
    font-size: 16px;
    transition: all 0.25s ease;
}

.theme-toggle:hover {
    border-color: var(--accent);
    transform: translateY(-1px);
    background: rgba(139, 92, 246, 0.15);
}

/* --- LIGHT THEME (PURE WHITE BACKGROUND) --- */
[data-theme="light"] {
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-card: #ffffff;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --accent: #7c3aed;
    --accent-light: #6d28d9;
    --border: #e2e8f0;
}

[data-theme="light"] body {
    background: #ffffff !important;
    color: #0f172a !important;
}

[data-theme="light"] .landing-page {
    background: #ffffff !important;
}

[data-theme="light"] .navbar {
    background: #ffffff !important;
    border-bottom: 1px solid #e2e8f0 !important;
}

[data-theme="light"] .nav-links a {
    color: #475569 !important;
}

[data-theme="light"] .nav-links a:hover {
    color: #0f172a !important;
}

[data-theme="light"] .hero {
    background: radial-gradient(ellipse at 50% 20%, rgba(124, 58, 237, 0.08), transparent 60%) !important;
}

[data-theme="light"] .hero h1 {
    color: #0f172a !important;
}

[data-theme="light"] .hero h1 span {
    color: #7c3aed !important;
}

[data-theme="light"] .hero-description {
    color: #475569 !important;
}

[data-theme="light"] .hero-badge {
    background: rgba(124, 58, 237, 0.08) !important;
    border: 1px solid rgba(124, 58, 237, 0.2) !important;
    color: #6d28d9 !important;
}

[data-theme="light"] .hero-note {
    color: #64748b !important;
}

[data-theme="light"] .hero-note span {
    color: #059669 !important;
}

[data-theme="light"] .section-heading h2 {
    color: #0f172a !important;
}

[data-theme="light"] .section-heading p {
    color: #64748b !important;
}

[data-theme="light"] .feature-card {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04) !important;
}

[data-theme="light"] .feature-card:hover {
    border-color: rgba(124, 58, 237, 0.4) !important;
    box-shadow: 0 10px 25px rgba(124, 58, 237, 0.08) !important;
}

[data-theme="light"] .feature-card h3 {
    color: #0f172a !important;
}

[data-theme="light"] .feature-card p {
    color: #64748b !important;
}

[data-theme="light"] .feature-icon {
    background: rgba(124, 58, 237, 0.1) !important;
    color: #7c3aed !important;
}

[data-theme="light"] .btn-outline {
    border: 1px solid #cbd5e1 !important;
    color: #0f172a !important;
}

[data-theme="light"] .btn-outline:hover {
    background: #f1f5f9 !important;
    border-color: #7c3aed !important;
    color: #7c3aed !important;
}

[data-theme="light"] .btn-secondary {
    background: #f1f5f9 !important;
    color: #0f172a !important;
    border: 1px solid #e2e8f0 !important;
}

[data-theme="light"] .btn-secondary:hover {
    background: #e2e8f0 !important;
}

[data-theme="light"] .footer {
    background: #ffffff !important;
    border-top: 1px solid #e2e8f0 !important;
    color: #64748b !important;
}

[data-theme="light"] .footer p,
[data-theme="light"] .footer span {
    color: #64748b !important;
}

[data-theme="light"] .theme-toggle {
    background: #f8fafc !important;
    border: 1px solid #cbd5e1 !important;
    color: #0f172a !important;
}

[data-theme="light"] .theme-toggle:hover {
    border-color: #7c3aed !important;
    background: #ede9fe !important;
    color: #7c3aed !important;
}
