/* ========================================
   AI.PAVEL-DORONIN.COM — Design System
   ======================================== */

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

:root {
    /* Colors */
    --color-bg: #000;
    --color-bg-alt: #0a0a0a;
    --color-surface: rgba(255, 255, 255, 0.04);
    --color-surface-hover: rgba(255, 199, 0, 0.06);
    --color-border: rgba(255, 199, 0, 0.15);
    --color-border-hover: rgba(255, 199, 0, 0.5);
    --color-accent: #FFC700;
    --color-accent-hover: #FFD740;
    --color-accent-glow: rgba(255, 199, 0, 0.3);
    --color-text: #fff;
    --color-text-secondary: rgba(255, 255, 255, 0.6);
    --color-text-muted: rgba(255, 255, 255, 0.35);

    /* Typography */
    --font-primary: 'Montserrat', -apple-system, BlinkMacSystemFont, sans-serif;

    /* Spacing */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 40px;
    --space-2xl: 60px;
    --space-3xl: 80px;

    /* Radii */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 16px;
    --radius-pill: 100px;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition: 0.3s ease;

    /* Theme toggle button */
    --th-bg: rgba(0, 0, 0, 0.5);
    --th-border: rgba(255, 255, 255, 0.15);
    --th-color: #FFC700;
    --th-accent: #FFC700;
}

/* Light theme override */
[data-theme="light"] {
    --color-bg: #f5f5f7;
    --color-bg-alt: #eeeef0;
    --color-surface: #fff;
    --color-surface-hover: rgba(212, 160, 0, 0.06);
    --color-border: #e0e0e4;
    --color-border-hover: rgba(212, 160, 0, 0.5);
    --color-accent: #d4a000;
    --color-accent-hover: #c49200;
    --color-accent-glow: rgba(212, 160, 0, 0.25);
    --color-text: #1a1a2e;
    --color-text-secondary: #6b6b80;
    --color-text-muted: #8e8e93;

    --th-bg: rgba(255, 255, 255, 0.85);
    --th-border: #e0e0e4;
    --th-color: #b8860b;
    --th-accent: #d4a000;
}

/* ===== Reset ===== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-primary);
    background: var(--color-bg);
    color: var(--color-text);
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    transition: background 0.3s, color 0.3s;
}

/* ===== Background Effects ===== */
.bg-glow::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        radial-gradient(ellipse at 20% 0%, rgba(255, 199, 0, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 100%, rgba(255, 199, 0, 0.04) 0%, transparent 50%);
    z-index: 0;
    pointer-events: none;
}

.bg-dots {
    background-image: radial-gradient(rgba(255, 199, 0, 0.08) 1px, transparent 1px);
    background-size: 32px 32px;
}

.bg-grid {
    background-image:
        linear-gradient(rgba(255, 199, 0, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 199, 0, 0.04) 1px, transparent 1px);
    background-size: 48px 48px;
}

/* ===== Layout ===== */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 1;
}

.container-sm { max-width: 800px; margin: 0 auto; padding: 0 24px; }
.container-lg { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

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

.section-divider {
    border: none;
    height: 1px;
    background: var(--color-border);
    margin: 0;
}

/* ===== Grid ===== */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--space-lg); }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-lg); }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-lg); }

.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }

/* ===== Typography ===== */
h1, .h1 {
    font-size: 56px;
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -1px;
}

h2, .h2 {
    font-size: 40px;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.5px;
}

h3, .h3 {
    font-size: 24px;
    font-weight: 700;
    line-height: 1.3;
}

h4, .h4 {
    font-size: 18px;
    font-weight: 700;
    line-height: 1.4;
}

.text-accent { color: var(--color-accent); }
.text-secondary { color: var(--color-text-secondary); }
.text-muted { color: var(--color-text-muted); }
.text-center { text-align: center; }

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

.text-shadow-accent {
    text-shadow: 2px 2px 0 rgba(255, 150, 0, 0.3);
}

.label {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: var(--color-text-muted);
}

.lead {
    font-size: 18px;
    color: var(--color-text-secondary);
    line-height: 1.7;
}

/* ===== Cards ===== */
.card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 32px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.card:hover {
    border-color: var(--color-border-hover);
    background: var(--color-surface-hover);
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(255, 199, 0, 0.1);
}

.card-glass {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    padding: 32px;
    transition: var(--transition);
}

.card-glass:hover {
    border-color: rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.05);
}

.card-accent {
    border-color: var(--color-accent);
    box-shadow: 0 0 20px rgba(255, 199, 0, 0.1);
}

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-primary);
    font-size: 15px;
    font-weight: 700;
    padding: 14px 32px;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}

.btn-accent {
    background: var(--color-accent);
    color: #000;
}

.btn-accent:hover {
    background: var(--color-accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(255, 199, 0, 0.25);
}

.btn-outline {
    background: transparent;
    color: var(--color-accent);
    border: 2px solid var(--color-accent);
}

.btn-outline:hover {
    background: rgba(255, 199, 0, 0.1);
    transform: translateY(-2px);
}

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

.btn-ghost:hover {
    color: var(--color-accent);
}

.btn-lg {
    font-size: 17px;
    padding: 18px 40px;
}

.btn-sm {
    font-size: 13px;
    padding: 10px 20px;
}

/* ===== Tags ===== */
.tag {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--color-accent);
    background: rgba(255, 199, 0, 0.1);
    padding: 5px 14px;
    border-radius: var(--radius-sm);
}

.tag-outline {
    background: transparent;
    border: 1px solid var(--color-border);
    color: var(--color-text-secondary);
}

/* ===== Inputs ===== */
.input {
    font-family: var(--font-primary);
    font-size: 16px;
    padding: 14px 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.04);
    color: var(--color-text);
    outline: none;
    transition: var(--transition-fast);
    width: 100%;
}

.input::placeholder { color: rgba(255, 255, 255, 0.25); }

.input:focus {
    border-color: var(--color-accent);
    box-shadow: 0 0 12px var(--color-accent-glow);
}

/* ===== Decorative ===== */
.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
}

.orb-gold {
    background: rgba(255, 199, 0, 0.15);
}

.orb-white {
    background: rgba(255, 255, 255, 0.05);
}

.divider-accent {
    width: 60px;
    height: 3px;
    background: var(--color-accent);
    border-radius: 2px;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    h1, .h1 { font-size: 36px; }
    h2, .h2 { font-size: 28px; }
    h3, .h3 { font-size: 20px; }

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

    .section { padding: var(--space-xl) 0; }
    .container, .container-sm, .container-lg { padding: 0 16px; }
}

@media (max-width: 480px) {
    h1, .h1 { font-size: 28px; }
    .btn-lg { font-size: 15px; padding: 14px 28px; }
}
