/* ============================================
   NextGen Tech - Design System
   Inspired by Vercel, Cloudflare, Tailwind
   RTL Arabic Layout
============================================ */

/* ============================================
   1. CSS CUSTOM PROPERTIES (Design Tokens)
============================================ */
:root {
    /* Brand Colors */
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --primary-light: #818cf8;
    --primary-subtle: rgba(99, 102, 241, 0.1);

    --secondary: #f97316;
    --secondary-hover: #ea580c;
    --secondary-light: #fb923c;
    --secondary-subtle: rgba(249, 115, 22, 0.1);

    /* Semantic Colors */
    --success: #22c55e;
    --success-subtle: rgba(34, 197, 94, 0.1);
    --warning: #f59e0b;
    --warning-subtle: rgba(245, 158, 11, 0.1);
    --error: #ef4444;
    --error-subtle: rgba(239, 68, 68, 0.1);
    --info: #3b82f6;
    --info-subtle: rgba(59, 130, 246, 0.1);

    /* Background Colors */
    --bg-primary: #000000;
    --bg-secondary: #0a0a0a;
    --bg-tertiary: #111111;
    --bg-card: #171717;
    --bg-card-hover: #1f1f1f;
    --bg-elevated: #262626;
    --bg-input: #0a0a0a;

    /* Text Colors */
    --text-primary: #fafafa;
    --text-secondary: #a1a1aa;
    --text-muted: #71717a;
    --text-inverse: #000000;

    /* Border Colors */
    --border: #262626;
    --border-hover: #404040;
    --border-focus: var(--primary);

    /* Category Colors */
    --cat-ai: #10b981;
    --cat-data: #3b82f6;
    --cat-cloud: #f59e0b;
    --cat-programming: #8b5cf6;
    --cat-certs: #ef4444;

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    --gradient-subtle: linear-gradient(180deg, transparent 0%, rgba(99, 102, 241, 0.03) 100%);
    --gradient-radial: radial-gradient(ellipse at top, rgba(99, 102, 241, 0.15) 0%, transparent 50%);

    /* Shadows */
    --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.5);
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.6);
    --shadow-xl: 0 16px 48px rgba(0, 0, 0, 0.7);
    --shadow-glow: 0 0 48px rgba(99, 102, 241, 0.2);
    --shadow-glow-sm: 0 0 24px rgba(99, 102, 241, 0.15);

    /* Typography */
    --font-sans: 'IBM Plex Sans Arabic', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

    --text-xs: 0.75rem;     /* 12px */
    --text-sm: 0.875rem;    /* 14px */
    --text-base: 1rem;      /* 16px */
    --text-lg: 1.125rem;    /* 18px */
    --text-xl: 1.25rem;     /* 20px */
    --text-2xl: 1.5rem;     /* 24px */
    --text-3xl: 1.875rem;   /* 30px */
    --text-4xl: 2.25rem;    /* 36px */
    --text-5xl: 3rem;       /* 48px */
    --text-6xl: 3.75rem;    /* 60px */

    --leading-tight: 1.25;
    --leading-normal: 1.5;
    --leading-relaxed: 1.75;

    --tracking-tight: -0.025em;
    --tracking-normal: 0;
    --tracking-wide: 0.025em;

    /* Spacing Scale */
    --space-0: 0;
    --space-1: 0.25rem;   /* 4px */
    --space-2: 0.5rem;    /* 8px */
    --space-3: 0.75rem;   /* 12px */
    --space-4: 1rem;      /* 16px */
    --space-5: 1.25rem;   /* 20px */
    --space-6: 1.5rem;    /* 24px */
    --space-8: 2rem;      /* 32px */
    --space-10: 2.5rem;   /* 40px */
    --space-12: 3rem;     /* 48px */
    --space-16: 4rem;     /* 64px */
    --space-20: 5rem;     /* 80px */
    --space-24: 6rem;     /* 96px */
    --space-32: 8rem;     /* 128px */

    /* Border Radius */
    --radius-none: 0;
    --radius-sm: 0.375rem;  /* 6px */
    --radius-md: 0.5rem;    /* 8px */
    --radius-lg: 0.75rem;   /* 12px */
    --radius-xl: 1rem;      /* 16px */
    --radius-2xl: 1.5rem;   /* 24px */
    --radius-full: 9999px;

    /* Transitions */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 200ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 300ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slower: 500ms cubic-bezier(0.4, 0, 0.2, 1);

    /* Z-Index Scale */
    --z-dropdown: 100;
    --z-sticky: 200;
    --z-fixed: 300;
    --z-modal-backdrop: 400;
    --z-modal: 500;
    --z-popover: 600;
    --z-tooltip: 700;

    /* Container Widths */
    --container-sm: 640px;
    --container-md: 768px;
    --container-lg: 1024px;
    --container-xl: 1280px;
    --container-2xl: 1400px;

    /* Header Height */
    --header-height: 64px;
}

/* ============================================
   2. CSS RESET & BASE
============================================ */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    direction: rtl;
    scroll-behavior: smooth;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

body {
    font-family: var(--font-sans);
    font-size: var(--text-base);
    line-height: var(--leading-relaxed);
    color: var(--text-primary);
    background-color: var(--bg-primary);
    min-height: 100vh;
    overflow-x: hidden;
}

/* Selection */
::selection {
    background-color: var(--primary);
    color: white;
}

/* Focus Styles (Accessibility) */
:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Skip Link (Accessibility) */
.skip-link {
    position: absolute;
    top: -100%;
    right: var(--space-4);
    padding: var(--space-3) var(--space-4);
    background: var(--primary);
    color: white;
    font-weight: 600;
    border-radius: var(--radius-md);
    z-index: var(--z-tooltip);
    transition: top var(--transition-fast);
}

.skip-link:focus {
    top: var(--space-4);
}

/* Links */
a {
    color: inherit;
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--primary-light);
}

/* Images */
img, video {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Lists */
ul, ol {
    list-style: none;
}

/* Buttons & Inputs */
button, input, textarea, select {
    font: inherit;
    color: inherit;
    background: none;
    border: none;
}

button {
    cursor: pointer;
}

/* Remove default button styles */
button:focus {
    outline: none;
}

/* Tables */
table {
    border-collapse: collapse;
    width: 100%;
}

/* ============================================
   3. LAYOUT UTILITIES
============================================ */
.container {
    width: 100%;
    max-width: var(--container-xl);
    margin: 0 auto;
    padding: 0 var(--space-6);
}

.container-sm { max-width: var(--container-sm); }
.container-md { max-width: var(--container-md); }
.container-lg { max-width: var(--container-lg); }
.container-2xl { max-width: var(--container-2xl); }

/* Main Content */
main {
    min-height: calc(100vh - var(--header-height));
    padding-top: var(--header-height);
}

/* Section Spacing */
.section {
    padding: var(--space-20) 0;
}

.section-sm { padding: var(--space-12) 0; }
.section-lg { padding: var(--space-32) 0; }

/* Grid System */
.grid {
    display: grid;
    gap: var(--space-6);
}

.grid-cols-1 { grid-template-columns: repeat(1, 1fr); }
.grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
.grid-cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid-cols-4 { grid-template-columns: repeat(4, 1fr); }

/* Flex Utilities */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.items-end { align-items: flex-end; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end { justify-content: flex-end; }
.gap-1 { gap: var(--space-1); }
.gap-2 { gap: var(--space-2); }
.gap-3 { gap: var(--space-3); }
.gap-4 { gap: var(--space-4); }
.gap-6 { gap: var(--space-6); }
.gap-8 { gap: var(--space-8); }

/* ============================================
   4. TYPOGRAPHY
============================================ */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: var(--leading-tight);
    color: var(--text-primary);
}

h1 { font-size: var(--text-4xl); }
h2 { font-size: var(--text-3xl); }
h3 { font-size: var(--text-2xl); }
h4 { font-size: var(--text-xl); }
h5 { font-size: var(--text-lg); }
h6 { font-size: var(--text-base); }

.text-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.text-balance {
    text-wrap: balance;
}

/* ============================================
   5. HEADER & NAVIGATION
============================================ */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header-height);
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    z-index: var(--z-fixed);
    transition: background var(--transition-base), box-shadow var(--transition-base);
}

.header.scrolled {
    background: rgba(0, 0, 0, 0.95);
    box-shadow: var(--shadow-lg);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    gap: var(--space-8);
}

/* Logo */
.logo {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    font-size: var(--text-xl);
    font-weight: 700;
    color: var(--text-primary);
    white-space: nowrap;
}

.logo-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--gradient-primary);
    border-radius: var(--radius-lg);
    font-size: var(--text-lg);
    color: white;
}

/* Navigation */
.nav {
    display: flex;
    align-items: center;
    gap: var(--space-1);
}

.nav-link {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-2) var(--space-4);
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.nav-link:hover {
    color: var(--text-primary);
    background: var(--bg-card);
}

.nav-link.active {
    color: var(--primary-light);
    background: var(--primary-subtle);
}

.nav-link i {
    font-size: var(--text-base);
}

/* Header Actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

.search-trigger {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.search-trigger:hover {
    color: var(--text-primary);
    background: var(--bg-card);
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.menu-toggle:hover {
    color: var(--text-primary);
    background: var(--bg-card);
}

/* Mobile Navigation */
.mobile-nav {
    display: none;
    position: fixed;
    top: var(--header-height);
    right: 0;
    bottom: 0;
    width: 100%;
    max-width: 320px;
    background: var(--bg-secondary);
    border-left: 1px solid var(--border);
    padding: var(--space-6);
    transform: translateX(100%);
    transition: transform var(--transition-slow);
    z-index: var(--z-modal);
    overflow-y: auto;
}

.mobile-nav.open {
    transform: translateX(0);
}

.mobile-nav-overlay {
    display: none;
    position: fixed;
    inset: 0;
    top: var(--header-height);
    background: rgba(0, 0, 0, 0.5);
    z-index: var(--z-modal-backdrop);
    opacity: 0;
    transition: opacity var(--transition-slow);
}

.mobile-nav-overlay.open {
    opacity: 1;
}

.mobile-nav-link {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-4);
    font-size: var(--text-lg);
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-2);
    transition: all var(--transition-fast);
}

.mobile-nav-link:hover,
.mobile-nav-link.active {
    color: var(--text-primary);
    background: var(--bg-card);
}

.mobile-nav-link.active {
    color: var(--primary-light);
}

/* ============================================
   6. BUTTONS
============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-6);
    font-size: var(--text-sm);
    font-weight: 600;
    line-height: 1;
    border-radius: var(--radius-lg);
    transition: all var(--transition-fast);
    white-space: nowrap;
    cursor: pointer;
}

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

/* Primary Button */
.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: var(--shadow-sm), 0 0 0 0 var(--primary-subtle);
}

.btn-primary:hover:not(:disabled) {
    background: var(--primary-hover);
    box-shadow: var(--shadow-md), var(--shadow-glow-sm);
    transform: translateY(-1px);
}

.btn-primary:active:not(:disabled) {
    transform: translateY(0);
}

/* Secondary Button */
.btn-secondary {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--bg-card-hover);
    border-color: var(--border-hover);
}

/* Ghost Button */
.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
}

.btn-ghost:hover:not(:disabled) {
    background: var(--bg-card);
    color: var(--text-primary);
}

/* Outline Button */
.btn-outline {
    background: transparent;
    color: var(--primary-light);
    border: 1px solid var(--primary);
}

.btn-outline:hover:not(:disabled) {
    background: var(--primary-subtle);
}

/* Button Sizes */
.btn-sm {
    padding: var(--space-2) var(--space-4);
    font-size: var(--text-xs);
    border-radius: var(--radius-md);
}

.btn-lg {
    padding: var(--space-4) var(--space-8);
    font-size: var(--text-base);
    border-radius: var(--radius-xl);
}

.btn-icon {
    width: 40px;
    height: 40px;
    padding: 0;
}

.btn-icon.btn-sm {
    width: 32px;
    height: 32px;
}

/* ============================================
   7. CARDS
============================================ */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: all var(--transition-base);
}

.card:hover {
    border-color: var(--border-hover);
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.card-image {
    position: relative;
    aspect-ratio: 16/9;
    overflow: hidden;
    background: var(--bg-tertiary);
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.card:hover .card-image img {
    transform: scale(1.05);
}

.card-body {
    padding: var(--space-6);
}

.card-category {
    display: inline-block;
    font-size: var(--text-xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    margin-bottom: var(--space-3);
}

.card-title {
    font-size: var(--text-lg);
    font-weight: 600;
    margin-bottom: var(--space-3);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-title a:hover {
    color: var(--primary-light);
}

.card-excerpt {
    font-size: var(--text-sm);
    color: var(--text-secondary);
    line-height: var(--leading-relaxed);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: var(--space-4);
}

.card-meta {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    font-size: var(--text-xs);
    color: var(--text-muted);
}

.card-meta span {
    display: flex;
    align-items: center;
    gap: var(--space-1);
}

/* ============================================
   8. HERO SECTION
============================================ */
.hero {
    position: relative;
    min-height: calc(100vh - var(--header-height));
    display: flex;
    align-items: center;
    padding: var(--space-20) 0;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--gradient-radial);
    pointer-events: none;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 200px;
    background: linear-gradient(to top, var(--bg-primary), transparent);
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-2) var(--space-4);
    background: var(--primary-subtle);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: var(--radius-full);
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--primary-light);
    margin-bottom: var(--space-6);
}

.hero-title {
    font-size: clamp(var(--text-3xl), 6vw, var(--text-6xl));
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: var(--space-6);
}

.hero-subtitle {
    font-size: var(--text-xl);
    color: var(--text-secondary);
    line-height: var(--leading-relaxed);
    max-width: 600px;
    margin: 0 auto var(--space-8);
}

.hero-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-4);
    flex-wrap: wrap;
    margin-bottom: var(--space-12);
}

.hero-newsletter {
    display: flex;
    gap: var(--space-3);
    max-width: 420px;
    margin: 0 auto;
    padding: var(--space-2);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
}

.hero-newsletter input {
    flex: 1;
    padding: var(--space-3) var(--space-4);
    background: transparent;
    color: var(--text-primary);
    font-size: var(--text-sm);
    min-width: 0;
}

.hero-newsletter input::placeholder {
    color: var(--text-muted);
}

/* ============================================
   9. SECTION HEADERS
============================================ */
.section-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: var(--space-6);
    margin-bottom: var(--space-10);
    flex-wrap: wrap;
}

.section-title {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    font-size: var(--text-2xl);
    font-weight: 700;
}

.section-title i {
    color: var(--primary);
}

.section-subtitle {
    font-size: var(--text-base);
    color: var(--text-secondary);
    margin-top: var(--space-2);
}

.section-link {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--primary-light);
    transition: gap var(--transition-fast);
}

.section-link:hover {
    gap: var(--space-3);
}

/* ============================================
   10. STATS BAR
============================================ */
.stats-bar {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-6);
    padding: var(--space-8);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-2xl);
}

.stat-item {
    text-align: center;
    padding: var(--space-4);
}

.stat-number {
    font-size: var(--text-4xl);
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: var(--space-2);
}

.stat-label {
    font-size: var(--text-sm);
    color: var(--text-muted);
}

/* ============================================
   11. TECH CARDS
============================================ */
.tech-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--space-6);
}

.tech-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: var(--space-8);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    transition: all var(--transition-base);
}

.tech-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.tech-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: var(--radius-xl);
    font-size: var(--text-2xl);
    color: white;
    margin-bottom: var(--space-4);
}

.tech-card h3 {
    font-size: var(--text-lg);
    font-weight: 600;
    margin-bottom: var(--space-2);
}

.tech-card p {
    font-size: var(--text-sm);
    color: var(--text-secondary);
    margin-bottom: var(--space-4);
    flex: 1;
}

.tech-link {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--primary-light);
}

.tech-link:hover {
    gap: var(--space-3);
}

/* ============================================
   12. NEWSLETTER SECTION
============================================ */
.newsletter-section {
    background: var(--gradient-subtle);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.newsletter-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-8);
    padding: var(--space-12);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-2xl);
    flex-wrap: wrap;
}

.newsletter-content {
    flex: 1;
    min-width: 280px;
}

.newsletter-content h2 {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    font-size: var(--text-2xl);
    margin-bottom: var(--space-2);
}

.newsletter-content p {
    color: var(--text-secondary);
}

.newsletter-form {
    display: flex;
    gap: var(--space-3);
    flex: 1;
    min-width: 280px;
    max-width: 420px;
}

.newsletter-form input {
    flex: 1;
    padding: var(--space-4);
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    color: var(--text-primary);
    font-size: var(--text-sm);
    transition: border-color var(--transition-fast);
}

.newsletter-form input:focus {
    border-color: var(--primary);
    outline: none;
}

.newsletter-form input::placeholder {
    color: var(--text-muted);
}

/* ============================================
   13. CTA BANNER (Visinova)
============================================ */
.cta-banner {
    position: relative;
    padding: var(--space-12);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-2xl);
    overflow: hidden;
}

.cta-banner::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--gradient-radial);
    opacity: 0.5;
    pointer-events: none;
}

.cta-banner-content {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-8);
    flex-wrap: wrap;
}

.cta-banner h3 {
    font-size: var(--text-2xl);
    margin-bottom: var(--space-2);
}

.cta-banner p {
    color: var(--text-secondary);
    max-width: 500px;
}

/* ============================================
   14. PAGE HEADER
============================================ */
.page-header {
    position: relative;
    padding: var(--space-20) 0 var(--space-12);
    text-align: center;
    background: var(--gradient-subtle);
}

.page-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--gradient-radial);
    pointer-events: none;
}

.page-header .container {
    position: relative;
    z-index: 1;
}

.page-header h1 {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-4);
    font-size: var(--text-4xl);
    margin-bottom: var(--space-4);
}

.page-header h1 i {
    color: var(--primary);
}

.page-header p {
    font-size: var(--text-lg);
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* ============================================
   15. FILTER BAR
============================================ */
.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-4);
    padding: var(--space-4);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    margin-bottom: var(--space-8);
}

.filter-group {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    flex-wrap: wrap;
}

.filter-label {
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--text-secondary);
    margin-left: var(--space-2);
}

.filter-btn {
    padding: var(--space-2) var(--space-4);
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--text-secondary);
    background: transparent;
    border: 1px solid transparent;
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.filter-btn:hover {
    color: var(--text-primary);
    background: var(--bg-tertiary);
}

.filter-btn.active {
    color: var(--primary-light);
    background: var(--primary-subtle);
    border-color: rgba(99, 102, 241, 0.3);
}

/* ============================================
   16. PAGINATION
============================================ */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    margin-top: var(--space-12);
}

.pagination-btn {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-4);
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--text-secondary);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.pagination-btn:hover {
    color: var(--text-primary);
    border-color: var(--border-hover);
}

.pagination-numbers {
    display: flex;
    align-items: center;
    gap: var(--space-1);
}

.pagination-numbers a,
.pagination-numbers span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    font-size: var(--text-sm);
    font-weight: 500;
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.pagination-numbers a {
    color: var(--text-secondary);
}

.pagination-numbers a:hover {
    color: var(--text-primary);
    background: var(--bg-card);
}

.pagination-current {
    color: white;
    background: var(--primary);
}

/* ============================================
   17. FORMS
============================================ */
.form-group {
    margin-bottom: var(--space-6);
}

.form-label {
    display: block;
    font-size: var(--text-sm);
    font-weight: 500;
    margin-bottom: var(--space-2);
    color: var(--text-primary);
}

.form-input {
    width: 100%;
    padding: var(--space-4);
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    color: var(--text-primary);
    font-size: var(--text-base);
    transition: all var(--transition-fast);
}

.form-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-subtle);
    outline: none;
}

.form-input::placeholder {
    color: var(--text-muted);
}

textarea.form-input {
    min-height: 150px;
    resize: vertical;
}

.form-error {
    font-size: var(--text-sm);
    color: var(--error);
    margin-top: var(--space-2);
}

/* ============================================
   18. FOOTER
============================================ */
.footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
    padding-top: var(--space-16);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr repeat(3, 1fr);
    gap: var(--space-12);
    padding-bottom: var(--space-12);
    border-bottom: 1px solid var(--border);
}

.footer-brand {
    max-width: 300px;
}

.footer-brand .logo {
    margin-bottom: var(--space-4);
}

.footer-brand > p {
    font-size: var(--text-sm);
    color: var(--text-secondary);
    line-height: var(--leading-relaxed);
    margin-bottom: var(--space-6);
}

.footer-social {
    display: flex;
    gap: var(--space-3);
}

.footer-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-size: var(--text-lg);
    transition: all var(--transition-fast);
}

.footer-social a:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
    transform: translateY(-2px);
}

.footer-column h4 {
    font-size: var(--text-base);
    font-weight: 600;
    margin-bottom: var(--space-6);
    color: var(--text-primary);
}

.footer-column ul {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}

.footer-column a {
    font-size: var(--text-sm);
    color: var(--text-secondary);
    transition: color var(--transition-fast);
}

.footer-column a:hover {
    color: var(--primary-light);
}

.footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-6) 0;
    flex-wrap: wrap;
    gap: var(--space-4);
}

.footer-bottom p {
    font-size: var(--text-sm);
    color: var(--text-muted);
}

.footer-bottom-links {
    display: flex;
    gap: var(--space-6);
}

.footer-bottom-links a {
    font-size: var(--text-sm);
    color: var(--text-secondary);
}

.footer-bottom-links a:hover {
    color: var(--primary-light);
}

/* ============================================
   19. SEARCH MODAL
============================================ */
.search-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: var(--z-modal);
    padding: var(--space-20) var(--space-6);
    overflow-y: auto;
}

.search-modal.open {
    display: block;
}

.search-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
}

.search-modal-content {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-2xl);
    overflow: hidden;
}

.search-input-wrapper {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    padding: var(--space-4) var(--space-6);
    border-bottom: 1px solid var(--border);
}

.search-input-wrapper i {
    font-size: var(--text-xl);
    color: var(--text-muted);
}

.search-modal input {
    flex: 1;
    padding: var(--space-2);
    font-size: var(--text-lg);
    background: transparent;
    color: var(--text-primary);
}

.search-modal input::placeholder {
    color: var(--text-muted);
}

.search-results {
    max-height: 400px;
    overflow-y: auto;
    padding: var(--space-4);
}

.search-result-item {
    display: block;
    padding: var(--space-4);
    border-radius: var(--radius-lg);
    transition: background var(--transition-fast);
}

.search-result-item:hover {
    background: var(--bg-tertiary);
}

.search-result-item h4 {
    font-size: var(--text-base);
    font-weight: 500;
    margin-bottom: var(--space-1);
}

.search-result-item p {
    font-size: var(--text-sm);
    color: var(--text-muted);
}

/* ============================================
   20. COOKIE BANNER
============================================ */
.cookie-banner {
    display: none;
    position: fixed;
    bottom: var(--space-6);
    right: var(--space-6);
    left: var(--space-6);
    max-width: 500px;
    padding: var(--space-6);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-xl);
    z-index: var(--z-modal);
}

.cookie-banner.show {
    display: block;
    animation: slideUp var(--transition-slow) ease-out;
}

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

.cookie-banner h4 {
    font-size: var(--text-lg);
    margin-bottom: var(--space-2);
}

.cookie-banner p {
    font-size: var(--text-sm);
    color: var(--text-secondary);
    margin-bottom: var(--space-4);
}

.cookie-actions {
    display: flex;
    gap: var(--space-3);
    flex-wrap: wrap;
}

/* ============================================
   21. EMPTY STATE
============================================ */
.empty-state {
    text-align: center;
    padding: var(--space-16);
}

.empty-state i {
    font-size: var(--text-6xl);
    color: var(--text-muted);
    margin-bottom: var(--space-6);
}

.empty-state h3 {
    font-size: var(--text-2xl);
    margin-bottom: var(--space-4);
}

.empty-state p {
    color: var(--text-secondary);
    max-width: 400px;
    margin: 0 auto var(--space-6);
}

/* ============================================
   22. BREADCRUMB
============================================ */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    font-size: var(--text-sm);
    color: var(--text-muted);
    margin-bottom: var(--space-6);
}

.breadcrumb a {
    color: var(--text-secondary);
}

.breadcrumb a:hover {
    color: var(--primary-light);
}

.breadcrumb-separator {
    color: var(--text-muted);
}

/* ============================================
   23. ALERT MESSAGES
============================================ */
.alert {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    padding: var(--space-4);
    border-radius: var(--radius-lg);
    font-size: var(--text-sm);
}

.alert i {
    font-size: var(--text-lg);
    margin-top: 2px;
}

.alert-success {
    background: var(--success-subtle);
    border: 1px solid var(--success);
    color: var(--success);
}

.alert-error {
    background: var(--error-subtle);
    border: 1px solid var(--error);
    color: var(--error);
}

.alert-warning {
    background: var(--warning-subtle);
    border: 1px solid var(--warning);
    color: var(--warning);
}

.alert-info {
    background: var(--info-subtle);
    border: 1px solid var(--info);
    color: var(--info);
}

/* ============================================
   24. LOADING STATES
============================================ */
.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-12);
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ============================================
   25. UTILITY CLASSES
============================================ */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.text-center { text-align: center; }
.text-right { text-align: right; }
.text-left { text-align: left; }

.text-primary { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }

.mb-0 { margin-bottom: 0; }
.mb-4 { margin-bottom: var(--space-4); }
.mb-6 { margin-bottom: var(--space-6); }
.mb-8 { margin-bottom: var(--space-8); }

.mt-auto { margin-top: auto; }

.w-full { width: 100%; }

.hidden { display: none; }

/* ============================================
   26. RESPONSIVE DESIGN
============================================ */

/* Tablet */
@media (max-width: 1024px) {
    :root {
        --header-height: 60px;
    }

    .nav { display: none; }
    .menu-toggle { display: flex; }
    .mobile-nav { display: block; }
    .mobile-nav-overlay { display: block; }

    .grid-cols-4 { grid-template-columns: repeat(2, 1fr); }
    .grid-cols-3 { grid-template-columns: repeat(2, 1fr); }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-8);
    }

    .stats-bar {
        grid-template-columns: repeat(2, 1fr);
    }

    .hero-title {
        font-size: var(--text-4xl);
    }

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

    .newsletter-form {
        width: 100%;
        max-width: none;
    }

    .cta-banner-content {
        flex-direction: column;
        text-align: center;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .container {
        padding: 0 var(--space-4);
    }

    .section {
        padding: var(--space-12) 0;
    }

    h1 { font-size: var(--text-3xl); }
    h2 { font-size: var(--text-2xl); }

    .grid-cols-4,
    .grid-cols-3,
    .grid-cols-2 {
        grid-template-columns: 1fr;
    }

    .hero {
        min-height: auto;
        padding: var(--space-12) 0;
    }

    .hero-title {
        font-size: var(--text-3xl);
    }

    .hero-subtitle {
        font-size: var(--text-base);
    }

    .hero-actions {
        flex-direction: column;
    }

    .hero-newsletter {
        flex-direction: column;
        gap: var(--space-2);
    }

    .stats-bar {
        grid-template-columns: repeat(2, 1fr);
        padding: var(--space-6);
        gap: var(--space-4);
    }

    .stat-number {
        font-size: var(--text-2xl);
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space-4);
    }

    .filter-bar {
        flex-direction: column;
    }

    .filter-group {
        width: 100%;
        overflow-x: auto;
        padding-bottom: var(--space-2);
        -webkit-overflow-scrolling: touch;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: var(--space-8);
    }

    .footer-brand {
        max-width: none;
    }

    .footer-social {
        justify-content: center;
    }

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

    .footer-bottom-links {
        justify-content: center;
        flex-wrap: wrap;
    }

    .page-header {
        padding: var(--space-12) 0 var(--space-8);
    }

    .page-header h1 {
        font-size: var(--text-2xl);
    }

    .pagination {
        flex-wrap: wrap;
    }

    .cookie-banner {
        right: var(--space-4);
        left: var(--space-4);
        bottom: var(--space-4);
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .hero-title {
        font-size: var(--text-2xl);
    }

    .btn {
        width: 100%;
    }

    .btn-lg {
        padding: var(--space-3) var(--space-6);
    }

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

    .newsletter-form {
        flex-direction: column;
    }

    .pagination-numbers {
        gap: 0;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    html {
        scroll-behavior: auto;
    }
}

/* Print Styles */
@media print {
    .header,
    .footer,
    .cookie-banner,
    .search-modal {
        display: none !important;
    }

    main {
        padding-top: 0;
    }

    body {
        background: white;
        color: black;
    }

    a {
        color: black;
        text-decoration: underline;
    }
}
