/* ============================================================
   EdgeStream Website - Design System & CSS Variables
   Dark Theme for Professional Technical Documentation
   ============================================================ */

:root {
    /* Color Palette */
    --color-bg-primary: #0f1419;
    --color-bg-secondary: #1a1f29;
    --color-bg-tertiary: #242b38;
    --color-bg-hover: #2d3544;

    --color-text-primary: #e8eaed;
    --color-text-secondary: #b8bcc4;
    --color-text-tertiary: #888d96;

    --color-border: #3d4451;
    --color-border-light: #4d5561;

    /* Brand Colors */
    --color-primary: #3b82f6;
    --color-primary-hover: #2563eb;
    --color-primary-dark: #1d4ed8;

    --color-secondary: #06b6d4;
    --color-secondary-hover: #0891b2;

    --color-accent: #f97316;
    --color-accent-hover: #ea580c;

    /* Semantic Colors */
    --color-success: #10b981;
    --color-warning: #f59e0b;
    --color-error: #ef4444;
    --color-info: #3b82f6;

    /* Status Colors */
    --color-status-active: #10b981;
    --color-status-inactive: #6b7280;
    --color-status-pending: #f59e0b;

    /* Spacing Scale */
    --space-0: 0;
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;
    --space-20: 5rem;
    --space-24: 6rem;

    /* Typography */
    --font-family-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
    --font-family-mono: 'Monaco', 'Menlo', 'Consolas', 'Courier New', monospace;

    --font-size-xs: 0.75rem;
    --font-size-sm: 0.875rem;
    --font-size-base: 1rem;
    --font-size-lg: 1.125rem;
    --font-size-xl: 1.25rem;
    --font-size-2xl: 1.5rem;
    --font-size-3xl: 1.875rem;
    --font-size-4xl: 2.25rem;
    --font-size-5xl: 3rem;

    --font-weight-regular: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;

    --line-height-tight: 1.25;
    --line-height-normal: 1.5;
    --line-height-relaxed: 1.75;

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);

    /* Border Radius */
    --radius-sm: 0.25rem;
    --radius-md: 0.375rem;
    --radius-lg: 0.5rem;
    --radius-xl: 0.75rem;
    --radius-2xl: 1rem;
    --radius-full: 9999px;

    /* Transitions */
    --transition-fast: 150ms ease-in-out;
    --transition-base: 250ms ease-in-out;
    --transition-slow: 350ms ease-in-out;

    /* Z-Index */
    --z-hide: -1;
    --z-auto: 0;
    --z-base: 1;
    --z-dropdown: 100;
    --z-fixed: 500;
    --z-modal-backdrop: 1000;
    --z-modal: 1001;
    --z-tooltip: 1100;
}

/* ============================================================
   Base Styles
   ============================================================ */

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    font-family: var(--font-family-sans);
    font-size: var(--font-size-base);
    line-height: var(--line-height-normal);
    color: var(--color-text-primary);
    background-color: var(--color-bg-primary);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

* {
    box-sizing: border-box;
}

/* ============================================================
   Typography
   ============================================================ */

h1, h2, h3, h4, h5, h6 {
    margin: 0;
    font-weight: var(--font-weight-bold);
    line-height: var(--line-height-tight);
}

h1 {
    font-size: var(--font-size-5xl);
}

h2 {
    font-size: var(--font-size-4xl);
    margin-bottom: var(--space-12);
}

h3 {
    font-size: var(--font-size-2xl);
    margin-bottom: var(--space-6);
}

h4 {
    font-size: var(--font-size-lg);
    margin-bottom: var(--space-4);
}

p {
    margin: 0;
    line-height: var(--line-height-normal);
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color var(--transition-base);
}

a:hover {
    color: var(--color-primary-hover);
}

/* ============================================================
   Links & Interactive
   ============================================================ */

button, a.btn {
    cursor: pointer;
    transition: all var(--transition-base);
    font-family: var(--font-family-sans);
}

button:focus, a.btn:focus {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* ============================================================
   Code & Preformatted
   ============================================================ */

code, pre {
    font-family: var(--font-family-mono);
    background-color: var(--color-bg-secondary);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
}

code {
    padding: var(--space-1) var(--space-2);
    font-size: var(--font-size-sm);
    color: var(--color-secondary);
}

pre {
    padding: var(--space-4);
    overflow-x: auto;
    line-height: var(--line-height-relaxed);
}

pre code {
    padding: 0;
    border: none;
    background-color: transparent;
}

/* ============================================================
   Lists
   ============================================================ */

ul, ol {
    margin: 0;
    padding-left: var(--space-6);
}

li {
    margin-bottom: var(--space-2);
    line-height: var(--line-height-relaxed);
}

/* ============================================================
   Tables
   ============================================================ */

table {
    width: 100%;
    border-collapse: collapse;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

th {
    background-color: var(--color-bg-secondary);
    color: var(--color-text-primary);
    font-weight: var(--font-weight-semibold);
    padding: var(--space-4);
    text-align: left;
    border-bottom: 1px solid var(--color-border);
}

td {
    padding: var(--space-4);
    border-bottom: 1px solid var(--color-border);
}

tr:hover {
    background-color: var(--color-bg-hover);
}

/* ============================================================
   Images
   ============================================================ */

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ============================================================
   Accessibility
   ============================================================ */

:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ============================================================
   Print Styles
   ============================================================ */

@media print {
    body {
        background-color: white;
        color: black;
    }

    a {
        color: #0563c1;
    }
}
