/* =========================================
   eGrab Premium Landing Page Styles
   Theme: Dark, Glassmorphism, Neon Blue
   ========================================= */

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

:root {
    /* Color Palette */
    --bg-dark: #0f1115;
    --bg-card: rgba(255, 255, 255, 0.03);
    --primary: #3b82f6;
    --primary-glow: #60a5fa;
    --text-main: #ffffff;
    --text-muted: #94a3b8;
    --border-light: rgba(255, 255, 255, 0.1);
    --glass-highlight: rgba(255, 255, 255, 0.05);

    /* Spacing & Layout */
    --container-width: 1200px;
    --header-height: 80px;
}

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

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

/* Background Effects */
.bg-glow {
    position: fixed;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.15) 0%, rgba(15, 17, 21, 0) 70%);
    border-radius: 50%;
    pointer-events: none;
    z-index: -1;
    top: -200px;
    left: 50%;
    transform: translate(-50%, -50%);
}

.bg-grid {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: -2;
    background-image:
        linear-gradient(var(--border-light) 1px, transparent 1px),
        linear-gradient(90deg, var(--border-light) 1px, transparent 1px);
    background-size: 50px 50px;
    opacity: 0.1;
    mask-image: radial-gradient(circle at center, black 40%, transparent 100%);
}

/* Typography Utilities */
h1,
h2,
h3 {
    line-height: 1.2;
    color: var(--text-main);
}

.gradient-text {
    background: linear-gradient(135deg, #ffffff 0%, var(--primary-glow) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

/* Container */
.container {
    width: 80%;
    margin: 0 auto;
    padding: 0 24px;
}

/* =========================================
   Header & Nav
   ========================================= */
header {
    height: var(--header-height);
    display: flex;
    align-items: center;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 100;
    backdrop-filter: blur(12px);
    background: rgba(15, 17, 21, 0.7);
    border-bottom: 1px solid var(--border-light);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-main);
    text-decoration: none;
}

.btn {
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.btn-primary {
    background: var(--primary);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.3);
}

.btn-primary:hover {
    background: var(--primary-glow);
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(59, 130, 246, 0.4);
}

/* =========================================
   Hero Section
   ========================================= */
.hero {
    min-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: calc(var(--header-height) + 5em);
    text-align: center;
    position: relative;
}

.hero-content {
    max-width: 800px;
    animation: fadeUp 0.8s ease-out;
}

.hero h1 {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 24px;
    letter-spacing: -0.02em;
}

.hero p {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* =========================================
   Features Grid
   ========================================= */
.features {
    padding: 100px 0;
    position: relative;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.section-header p {
    color: var(--text-muted);
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
}

/* =========================================
   Sponsor Section
   ========================================= */
.sponsor-section {
    padding: 80px 0;
    position: relative;
    overflow: hidden;
}

.sponsor-container {
    background: rgba(255, 255, 255, 0.02);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-light);
    border-radius: 24px;
    padding: 40px;
    text-align: center;
    position: relative;
    max-width: 900px;
    margin: 0 auto;
    box-shadow: 0 20px 80px -20px rgba(0, 0, 0, 0.5);
}

.sponsor-container::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.08) 0%, transparent 70%);
    pointer-events: none;
    z-index: -1;
}

.sponsor-header h2 {
    font-size: 2rem;
    margin-bottom: 10px;
}

.sponsor-header p {
    color: var(--text-muted);
    margin-bottom: 30px;
}

.iframe-wrapper {
    display: inline-flex;
    justify-content: center;
    overflow: hidden;
    border-radius: 12px;
    background: transparent;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    width: 100%;
    max-width: 600px;
}

.iframe-wrapper iframe {
    width: 100%;
    max-width: 600px;
}

.card {
    background: var(--bg-card);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-light);
    border-radius: 16px;
    padding: 32px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    margin: auto 0;
}

.card:hover {
    transform: translateY(-5px);
    border-color: rgba(59, 130, 246, 0.3);
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.5);
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.03), transparent);
    transform: translateX(-100%);
    transition: 0.5s;
}

.card:hover::before {
    transform: translateX(100%);
}

.card-icon {
    width: 50px;
    height: 50px;
    background: rgba(59, 130, 246, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: var(--primary-glow);
}

.card h3 {
    font-size: 1.25rem;
    margin-bottom: 12px;
}

.card p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* =========================================
   Demo / Preview Section
   ========================================= */
.preview {
    margin-top: 40px;
    border-radius: 16px;
    border: 1px solid var(--border-light);
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    animation: fadeUp 1s ease-out 0.2s backwards;
}

.window-bar {
    background: rgba(0, 0, 0, 0.4);
    padding: 12px 20px;
    display: flex;
    gap: 8px;
    border-bottom: 1px solid var(--border-light);
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.red {
    background: #ff5f56;
}

.dot.yellow {
    background: #ffbd2e;
}

.dot.green {
    background: #27c93f;
}

.code-block {
    background: #1e1e1e;
    padding: 24px;
    font-family: 'Fira Code', monospace;
    font-size: 0.9rem;
    color: #d4d4d4;
    overflow-x: auto;
}

.syntax-tag {
    color: #569cd6;
}

.syntax-attr {
    color: #9cdcfe;
}

.syntax-str {
    color: #ce9178;
}

.syntax-comment {
    color: #6a9955;
}

/* =========================================
   Footer
   ========================================= */
footer {
    padding: 40px 0;
    border-top: 1px solid var(--border-light);
    text-align: center;
    color: var(--text-muted);
    margin-top: 80px;
}

/* =========================================
   Animations
   ========================================= */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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

/* =========================================
   Media Queries
   ========================================= */
@media (max-width: 768px) {
    :root {
        --header-height: 70px;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero p {
        font-size: 1rem;
        padding: 0 10px;
    }

    .container {
        padding: 0 20px;
        width: 100%;
    }

    /* Nav Mobile Adjustments */
    .logo span {
        font-size: 1.25rem;
    }

    .btn {
        padding: 10px 16px;
        font-size: 0.9rem;
    }

    /* Grid Adjustments */
    .grid {
        grid-template-columns: 1fr;
    }

    .card {
        padding: 24px;
    }

    /* Code Preview Adjustments */
    .code-block {
        font-size: 0.8rem;
        padding: 16px;
    }

    /* Sponsor Mobile */
    .sponsor-container {
        padding: 24px;
        border-radius: 16px;
    }

    .sponsor-header h2 {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .header .container {
        padding: 0 16px;
    }

    .hero {
        padding-top: calc(var(--header-height) + 2em);
    }

    .hero h1 {
        font-size: 2rem;
    }

    /* Hide decorative blobs on very small screens if they block text */
    .bg-glow {
        opacity: 0.5;
    }
}