/* ============================================================
   Pregões BR — Premium Design System
   Modern SaaS Platform for Brazilian Public Procurement
   ============================================================ */

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

/* ============================================================
   1. CSS CUSTOM PROPERTIES
   ============================================================ */
:root {
    /* Brand Colors */
    --primary: #2563eb;
    --primary-hover: #1d4ed8;
    --primary-light: #eff6ff;
    --primary-dark: #1e40af;
    --primary-50: #eff6ff;
    --primary-100: #dbeafe;
    --primary-200: #bfdbfe;
    --primary-500: #3b82f6;
    --primary-600: #2563eb;
    --primary-700: #1d4ed8;

    /* Accent Colors */
    --green: #10b981;
    --green-light: #ecfdf5;
    --yellow: #f59e0b;
    --yellow-light: #fffbeb;
    --red: #ef4444;
    --red-light: #fef2f2;
    --purple: #8b5cf6;
    --purple-light: #f5f3ff;
    --cyan: #06b6d4;
    --cyan-light: #ecfeff;

    /* Surfaces */
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-tertiary: #f1f5f9;
    --bg-card: #ffffff;
    --bg-input: #f8fafc;

    /* Text */
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --text-inverse: #ffffff;

    /* Borders */
    --border-color: #e2e8f0;
    --border-light: #f1f5f9;

    /* Shadows */
    --shadow-xs: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
    --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-md: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);
    --shadow-glow: 0 0 40px rgb(37 99 235 / 0.15);

    /* Layout */
    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-2xl: 24px;
    --radius-full: 9999px;

    /* Typography */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

    /* Spacing */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 3rem;
    --space-3xl: 4rem;
    --space-4xl: 6rem;

    /* 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);

    /* Z-index */
    --z-dropdown: 100;
    --z-sticky: 200;
    --z-overlay: 300;
    --z-modal: 400;
    --z-toast: 500;
}

/* Dark Theme */
[data-theme="dark"] {
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --bg-tertiary: #334155;
    --bg-card: #1e293b;
    --bg-input: #334155;

    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;

    --border-color: #334155;
    --border-light: #1e293b;

    --shadow-xs: 0 1px 2px 0 rgb(0 0 0 / 0.3);
    --shadow-sm: 0 1px 3px 0 rgb(0 0 0 / 0.4), 0 1px 2px -1px rgb(0 0 0 / 0.3);
    --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.4), 0 2px 4px -2px rgb(0 0 0 / 0.3);
    --shadow-md: 0 10px 15px -3px rgb(0 0 0 / 0.5), 0 4px 6px -4px rgb(0 0 0 / 0.4);
    --shadow-lg: 0 20px 25px -5px rgb(0 0 0 / 0.5), 0 8px 10px -6px rgb(0 0 0 / 0.4);
    --shadow-xl: 0 25px 50px -12px rgb(0 0 0 / 0.6);

    --primary-light: #1e3a5f;
    --green-light: #064e3b;
    --yellow-light: #78350f;
    --red-light: #7f1d1d;
    --purple-light: #3b0764;
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

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

a {
    color: var(--primary);
    text-decoration: none;
    transition: color var(--transition-fast);
}

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

ul, ol {
    list-style: none;
}

button {
    cursor: pointer;
    border: none;
    background: none;
    font-family: inherit;
    font-size: inherit;
    color: inherit;
}

input, select, textarea {
    font-family: inherit;
    font-size: inherit;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-primary);
}

::selection {
    background: var(--primary);
    color: #fff;
}

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

/* ============================================================
   4. HEADER
   ============================================================ */
.header {
    position: sticky;
    top: 0;
    z-index: var(--z-sticky);
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid var(--border-color);
    transition: all var(--transition-base);
}

[data-theme="dark"] .header {
    background: rgba(15, 23, 42, 0.85);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-lg);
}

.header-logo {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-primary);
    text-decoration: none;
    letter-spacing: -0.03em;
}

.header-logo i {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--purple) 100%);
    color: #fff;
    border-radius: var(--radius-sm);
    font-size: 1.125rem;
}

.header-nav {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
}

.header-nav a {
    padding: var(--space-sm) var(--space-md);
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
}

.header-nav a:hover {
    color: var(--text-primary);
    background: var(--bg-tertiary);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

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

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

.mobile-menu-btn {
    display: none;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
}

.mobile-nav {
    display: none;
}

/* ============================================================
   5. BUTTONS
   ============================================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    padding: 0.75rem 1.5rem;
    font-size: 0.9375rem;
    font-weight: 600;
    line-height: 1.25;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    white-space: nowrap;
    text-decoration: none;
    transition: all var(--transition-fast);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1rem;
}

.btn-xl {
    padding: 1.125rem 2.25rem;
    font-size: 1.0625rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-hover) 100%);
    color: #fff;
    box-shadow: 0 4px 14px 0 rgb(37 99 235 / 0.35);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px 0 rgb(37 99 235 / 0.45);
}

.btn-secondary {
    background: var(--bg-primary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-xs);
}

.btn-secondary:hover {
    background: var(--bg-secondary);
    border-color: var(--text-muted);
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}

.btn-accent {
    background: linear-gradient(135deg, var(--green) 0%, #059669 100%);
    color: #fff;
    box-shadow: 0 4px 14px 0 rgb(16 185 129 / 0.35);
}

.btn-accent:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px 0 rgb(16 185 129 / 0.45);
}

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

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

/* ============================================================
   6. HERO SECTION
   ============================================================ */
.hero {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--space-4xl) var(--space-lg);
    text-align: center;
    overflow: hidden;
    background: linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 1000px;
    height: 600px;
    background: radial-gradient(ellipse, rgba(37, 99, 235, 0.12) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.hero > * {
    position: relative;
    z-index: 1;
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 800px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--space-sm);
    padding: 0.5rem 1rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--primary);
    background: var(--primary-light);
    border: 1px solid var(--primary-200);
    border-radius: var(--radius-full);
    margin-bottom: var(--space-xl);
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 800;
    letter-spacing: -0.04em;
    line-height: 1.1;
    margin-bottom: var(--space-lg);
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--text-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    max-width: 600px;
    line-height: 1.7;
    margin-bottom: var(--space-2xl);
}

/* Search Bar */
.search-bar {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    width: 100%;
    max-width: 680px;
    padding: var(--space-sm);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg), var(--shadow-glow);
    margin-bottom: var(--space-2xl);
}

.search-bar input {
    flex: 1;
    padding: 1rem 1.5rem;
    font-size: 1rem;
    color: var(--text-primary);
    background: transparent;
    border: none;
    outline: none;
}

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

.search-bar select {
    padding: 1rem 1.5rem;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--text-primary);
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    outline: none;
    min-width: 180px;
    cursor: pointer;
}

.search-bar .btn {
    padding: 1rem 2rem;
    border-radius: var(--radius);
    font-weight: 600;
}

/* Trust Indicators */
.trust-indicators {
    display: flex;
    align-items: center;
    gap: var(--space-3xl);
}

.trust-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-xs);
}

.trust-value {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

.trust-label {
    font-size: 0.875rem;
    color: var(--text-muted);
    font-weight: 500;
}

/* ============================================================
   7. STATS SECTION
   ============================================================ */
.stats {
    padding: var(--space-3xl) 0;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-lg);
}

.stat-card {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
    padding: var(--space-xl);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    transition: all var(--transition-base);
}

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

.stat-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: var(--radius);
    font-size: 1.25rem;
    margin-bottom: var(--space-sm);
}

.stat-icon.blue {
    background: var(--primary-light);
    color: var(--primary);
}

.stat-icon.green {
    background: var(--green-light);
    color: var(--green);
}

.stat-icon.yellow {
    background: var(--yellow-light);
    color: var(--yellow);
}

.stat-icon.purple {
    background: var(--purple-light);
    color: var(--purple);
}

.stat-value {
    font-size: 2.25rem;
    font-weight: 800;
    color: var(--text-primary);
    letter-spacing: -0.03em;
    line-height: 1;
}

.stat-label {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* ============================================================
   8. SECTIONS
   ============================================================ */
.section {
    padding: var(--space-4xl) 0;
}

.section-alt {
    background: var(--bg-secondary);
}

.section-title {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 800;
    text-align: center;
    margin-bottom: var(--space-sm);
    letter-spacing: -0.03em;
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    text-align: center;
    max-width: 600px;
    margin: 0 auto var(--space-3xl);
    line-height: 1.7;
}

/* ============================================================
   9. STEPS / HOW IT WORKS
   ============================================================ */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-xl);
}

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

.step-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-200);
}

.step-number {
    position: absolute;
    top: -16px;
    left: 50%;
    transform: translateX(-50%);
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-hover) 100%);
    color: #fff;
    font-size: 0.875rem;
    font-weight: 700;
    border-radius: var(--radius-full);
    box-shadow: 0 4px 12px rgb(37 99 235 / 0.35);
}

.step-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 72px;
    height: 72px;
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary-100) 100%);
    color: var(--primary);
    font-size: 1.75rem;
    margin-bottom: var(--space-lg);
    margin-top: var(--space-sm);
}

.step-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: var(--space-sm);
}

.step-desc {
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* ============================================================
   10. HIGHLIGHTS GRID
   ============================================================ */
.highlights-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-lg);
}

.highlight-loading {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--space-4xl);
    color: var(--text-muted);
    font-size: 1rem;
}

.highlight-loading i {
    font-size: 2.5rem;
    margin-bottom: var(--space-md);
    animation: spin 1s linear infinite;
}

.highlight-card {
    display: flex;
    flex-direction: column;
    padding: var(--space-xl);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    transition: all var(--transition-base);
}

.highlight-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-200);
}

.highlight-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-md);
}

.highlight-type {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--primary);
    background: var(--primary-light);
    padding: 0.375rem 0.75rem;
    border-radius: var(--radius-full);
}

.highlight-date {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.highlight-title {
    font-size: 1.0625rem;
    font-weight: 600;
    margin-bottom: var(--space-sm);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.highlight-org {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: var(--space-md);
}

.highlight-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
    padding-top: var(--space-md);
    border-top: 1px solid var(--border-color);
}

.highlight-value {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--green);
}

.highlight-status {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--green);
    background: var(--green-light);
    padding: 0.375rem 0.75rem;
    border-radius: var(--radius-full);
}

/* ============================================================
   11. WHY SECTION
   ============================================================ */
.why-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-xl);
}

.why-card {
    display: flex;
    gap: var(--space-lg);
    padding: var(--space-xl);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    transition: all var(--transition-base);
}

.why-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-200);
}

.why-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, var(--primary-light) 0%, var(--primary-100) 100%);
    color: var(--primary);
    font-size: 1.5rem;
    flex-shrink: 0;
}

.why-title {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: var(--space-sm);
}

.why-desc {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* ============================================================
   12. PRICING
   ============================================================ */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-lg);
    align-items: start;
}

.pricing-card {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: var(--space-2xl);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    transition: all var(--transition-base);
}

.pricing-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.pricing-card.popular {
    border-color: var(--primary);
    box-shadow: 0 0 0 1px var(--primary), var(--shadow-xl);
}

.pricing-card.popular::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: var(--radius-xl);
    background: linear-gradient(135deg, var(--primary) 0%, var(--purple) 100%);
    z-index: -1;
    opacity: 0.1;
}

.pricing-popular-badge {
    position: absolute;
    top: -14px;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.375rem 1rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #fff;
    background: linear-gradient(135deg, var(--primary) 0%, var(--purple) 100%);
    border-radius: var(--radius-full);
    white-space: nowrap;
    box-shadow: 0 4px 12px rgb(37 99 235 / 0.35);
}

.pricing-name {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: var(--space-sm);
}

.pricing-price {
    display: flex;
    align-items: baseline;
    gap: var(--space-xs);
    margin-bottom: var(--space-xs);
}

.pricing-price {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.04em;
    color: var(--text-primary);
}

.pricing-price small {
    font-size: 1.5rem;
    font-weight: 600;
}

.pricing-period {
    font-size: 0.9375rem;
    color: var(--text-muted);
    margin-bottom: var(--space-xl);
}

.pricing-features {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
    margin-bottom: var(--space-xl);
    flex: 1;
}

.pricing-features li {
    display: flex;
    align-items: flex-start;
    gap: var(--space-sm);
    font-size: 0.9375rem;
    color: var(--text-secondary);
}

.pricing-features li i {
    flex-shrink: 0;
    margin-top: 3px;
    color: var(--green);
    width: 18px;
}

.pricing-features li.disabled {
    color: var(--text-muted);
}

.pricing-features li.disabled i {
    color: var(--text-muted);
}

/* ============================================================
   13. FAQ
   ============================================================ */
.faq-list {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    border-bottom: 1px solid var(--border-color);
}

.faq-question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: var(--space-xl) 0;
    font-size: 1.0625rem;
    font-weight: 600;
    color: var(--text-primary);
    text-align: left;
    cursor: pointer;
    transition: color var(--transition-fast);
}

.faq-question:hover {
    color: var(--primary);
}

.faq-question i {
    flex-shrink: 0;
    transition: transform var(--transition-base);
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height var(--transition-slow);
}

.faq-item.active .faq-answer {
    max-height: 500px;
}

.faq-answer-inner {
    padding-bottom: var(--space-xl);
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.8;
}

/* ============================================================
   14. CTA SECTION
   ============================================================ */
.cta-section {
    padding: var(--space-4xl) 0;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 50%, var(--purple) 100%);
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
}

.cta-content {
    position: relative;
    z-index: 1;
    text-align: center;
}

.cta-title {
    font-size: clamp(2rem, 4vw, 2.75rem);
    font-weight: 800;
    color: #fff;
    margin-bottom: var(--space-lg);
    letter-spacing: -0.03em;
}

.cta-subtitle {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.85);
    max-width: 560px;
    margin: 0 auto var(--space-2xl);
    line-height: 1.7;
}

.cta-actions {
    display: flex;
    gap: var(--space-md);
    justify-content: center;
    flex-wrap: wrap;
}

/* ============================================================
   15. FOOTER
   ============================================================ */
.footer {
    padding: var(--space-4xl) var(--space-lg) var(--space-xl);
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: var(--space-2xl);
    max-width: 1200px;
    margin: 0 auto;
}

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

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

.footer-brand p {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: var(--space-lg);
}

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

.footer-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    transition: all var(--transition-fast);
}

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

.footer-col h4 {
    font-size: 0.8125rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    margin-bottom: var(--space-lg);
}

.footer-col a {
    display: block;
    font-size: 0.9375rem;
    color: var(--text-secondary);
    padding: var(--space-xs) 0;
    transition: color var(--transition-fast);
}

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

.footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: var(--space-3xl) auto 0;
    padding-top: var(--space-xl);
    border-top: 1px solid var(--border-color);
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* ============================================================
   16. ANIMATIONS
   ============================================================ */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

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

.fade-up {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================================
   17. TOAST
   ============================================================ */
.toast-container {
    position: fixed;
    bottom: var(--space-xl);
    right: var(--space-xl);
    z-index: var(--z-toast);
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}

.toast {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-md) var(--space-lg);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    box-shadow: var(--shadow-xl);
    font-size: 0.9375rem;
    min-width: 320px;
    animation: slideIn 0.3s ease-out;
}

/* ============================================================
    UTILITY CLASSES
    ============================================================ */
.page-content {
    padding: var(--space-3xl) var(--space-lg);
    max-width: 1200px;
    margin: 0 auto;
}

/* Badge */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 0.25rem 0.625rem;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: var(--radius-full);
    white-space: nowrap;
}

.badge-primary {
    background: var(--primary-light);
    color: var(--primary);
}

.badge-success {
    background: var(--green-light);
    color: var(--green);
}

.badge-neutral {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
}

.badge-dot::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
}

/* Card utility */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--space-xl);
    transition: all var(--transition-base);
}

.card:hover {
    box-shadow: var(--shadow-lg);
}

/* Table utility */
.table-wrap {
    overflow-x: auto;
}

.table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9375rem;
}

.table thead {
    background: var(--bg-secondary);
}

.table th {
    padding: 0.75rem 1rem;
    text-align: left;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
    border-bottom: 1px solid var(--border-color);
}

.table td {
    padding: 0.875rem 1rem;
    color: var(--text-primary);
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

.table tbody tr {
    transition: background var(--transition-fast);
}

.table tbody tr:hover {
    background: var(--bg-secondary);
}

.table tbody tr:last-child td {
    border-bottom: none;
}

.table-compact th,
.table-compact td {
    padding: 0.5rem 0.75rem;
}

/* Modal */
.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: var(--z-modal);
    align-items: center;
    justify-content: center;
    padding: var(--space-lg);
}

.modal-overlay.active {
    display: flex;
}

.modal {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    width: 100%;
    max-width: 640px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-xl);
    animation: slideIn 0.2s ease-out;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-xl) var(--space-2xl);
    border-bottom: 1px solid var(--border-color);
}

.modal-header h2 {
    font-size: 1.25rem;
    font-weight: 700;
}

.modal-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    transition: all var(--transition-fast);
}

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

/* Form utilities */
.is-invalid {
    border-color: var(--red) !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15) !important;
}

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

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

@media (max-width: 768px) {
    .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

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

/* Pulse animation for alerts */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.dot-pulse {
    animation: pulse 1.5s ease-in-out infinite;
}

/* ============================================================
   18. RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

    .pricing-card:last-child {
        grid-column: 1 / -1;
        max-width: 400px;
        justify-self: center;
    }

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

    .footer-brand {
        grid-column: 1 / -1;
    }
}

@media (max-width: 768px) {
    .header-inner {
        padding: 0 var(--space-md);
    }

    .header-nav {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        flex-direction: column;
        align-items: stretch;
        justify-content: flex-start;
        gap: var(--space-xs);
        padding: 6rem var(--space-lg) var(--space-xl);
        background: var(--bg-primary);
        z-index: var(--z-overlay);
        overflow-y: auto;
    }

    .header-nav.active,
    .mobile-nav.active {
        display: flex;
    }

    .header-nav a,
    .mobile-nav a {
        padding: var(--space-md);
        font-size: 1.125rem;
        border-radius: var(--radius-sm);
    }

    .mobile-menu-btn {
        display: flex;
    }

    .hero {
        padding: var(--space-3xl) var(--space-md);
    }

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

    .hero-subtitle {
        font-size: 1rem;
    }

    .search-bar {
        flex-direction: column;
        border-radius: var(--radius-lg);
    }

    .search-bar select {
        width: 100%;
    }

    .search-bar .btn {
        width: 100%;
    }

    .trust-indicators {
        flex-direction: column;
        gap: var(--space-md);
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-md);
    }

    .steps-grid,
    .why-grid,
    .highlights-grid {
        grid-template-columns: 1fr;
    }

    .pricing-grid {
        grid-template-columns: 1fr;
        max-width: 400px;
        margin: 0 auto;
    }

    .pricing-card:last-child {
        max-width: none;
    }

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

    .footer-bottom {
        flex-direction: column;
        gap: var(--space-md);
        text-align: center;
    }

    .cta-actions {
        flex-direction: column;
        width: 100%;
    }

    .cta-actions .btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .stat-card {
        padding: var(--space-lg);
    }

    .stat-value {
        font-size: 1.75rem;
    }
}

/* ============================================================
   19. PRINT
   ============================================================ */
@media print {
    .header,
    .footer,
    .mobile-menu-btn,
    .btn,
    .toast-container {
        display: none !important;
    }

    body {
        color: #000;
        background: #fff;
    }
}
