/* ============================================
   IFEDOR.RU — ДИЗАЙН-СИСТЕМА
   Версия: 1.4
   Тренды 2026–2027
   ============================================ */

/* ============================================
   1. ПЕРЕМЕННЫЕ (3 ТЕМЫ)
   ============================================ */

:root {
    --color-bg: #F0F2F5;
    --color-bg-surface: rgba(255, 255, 255, 0.7);
    --color-bg-card: rgba(255, 255, 255, 0.5);
    --color-bg-input: rgba(255, 255, 255, 0.8);
    --color-bg-hover: rgba(0, 135, 90, 0.03);
    
    --color-text-primary: #0A0E1A;
    --color-text-secondary: #2E3A4A;
    --color-text-muted: #7A8A9E;
    --color-text-inverse: #FFFFFF;
    
    --color-accent-1: #00875A;
    --color-accent-2: #0066CC;
    --color-accent-grad: linear-gradient(135deg, #00875A, #0066CC);
    --color-accent-hover: rgba(0, 135, 90, 0.15);
    --color-accent-active: rgba(0, 135, 90, 0.25);
    
    --color-border: rgba(0, 0, 0, 0.06);
    --color-border-hover: rgba(0, 135, 90, 0.2);
    --color-border-focus: rgba(0, 135, 90, 0.4);
    
    --color-shadow: rgba(0, 0, 0, 0.04);
    --shadow-glow: 0 0 60px rgba(0, 135, 90, 0.04);
    --shadow-card: 0 20px 60px rgba(0, 0, 0, 0.04);
    --shadow-btn: 0 0 40px rgba(0, 135, 90, 0.08);
    --shadow-focus: 0 0 0 4px rgba(0, 135, 90, 0.06);
    
    --radius-lg: 20px;
    --radius-md: 14px;
    --radius-sm: 12px;
    --radius-xs: 10px;
    --radius-round: 50%;
    
    --space-xxs: 4px;
    --space-xs: 6px;
    --space-sm: 8px;
    --space-md: 12px;
    --space-lg: 16px;
    --space-xl: 24px;
    --space-xxl: 32px;
    --space-xxxl: 48px;
    --space-xxxxl: 64px;
}

[data-theme="dark"] {
    --color-bg: #05050A;
    --color-bg-surface: rgba(12, 16, 28, 0.6);
    --color-bg-card: rgba(255, 255, 255, 0.03);
    --color-bg-input: rgba(255, 255, 255, 0.04);
    --color-bg-hover: rgba(0, 245, 160, 0.04);
    
    --color-text-primary: #FFFFFF;
    --color-text-secondary: #A0B0C8;
    --color-text-muted: #5A6A85;
    --color-text-inverse: #0A0E1A;
    
    --color-accent-1: #00F5A0;
    --color-accent-2: #00D4FF;
    --color-accent-grad: linear-gradient(135deg, #00F5A0, #00D4FF);
    --color-accent-hover: rgba(0, 245, 160, 0.2);
    --color-accent-active: rgba(0, 245, 160, 0.3);
    
    --color-border: rgba(255, 255, 255, 0.06);
    --color-border-hover: rgba(0, 245, 160, 0.25);
    --color-border-focus: rgba(0, 245, 160, 0.5);
    
    --color-shadow: rgba(0, 0, 0, 0.4);
    --shadow-glow: 0 0 60px rgba(0, 245, 160, 0.06);
    --shadow-card: 0 20px 60px rgba(0, 0, 0, 0.25);
    --shadow-btn: 0 0 40px rgba(0, 245, 160, 0.1);
    --shadow-focus: 0 0 0 4px rgba(0, 245, 160, 0.08);
}

[data-theme="violet"] {
    --color-bg: #0A0015;
    --color-bg-surface: rgba(20, 0, 40, 0.7);
    --color-bg-card: rgba(255, 0, 255, 0.04);
    --color-bg-input: rgba(255, 0, 255, 0.03);
    --color-bg-hover: rgba(255, 0, 255, 0.06);
    
    --color-text-primary: #F0E6FF;
    --color-text-secondary: #C4A8E6;
    --color-text-muted: #7A5A99;
    --color-text-inverse: #0A0015;
    
    --color-accent-1: #FF00FF;
    --color-accent-2: #00FFFF;
    --color-accent-grad: linear-gradient(135deg, #FF00FF, #00FFFF);
    --color-accent-hover: rgba(255, 0, 255, 0.2);
    --color-accent-active: rgba(255, 0, 255, 0.3);
    
    --color-border: rgba(255, 0, 255, 0.1);
    --color-border-hover: rgba(255, 0, 255, 0.3);
    --color-border-focus: rgba(255, 0, 255, 0.5);
    
    --color-shadow: rgba(255, 0, 255, 0.1);
    --shadow-glow: 0 0 60px rgba(255, 0, 255, 0.08);
    --shadow-card: 0 20px 60px rgba(255, 0, 255, 0.06);
    --shadow-btn: 0 0 40px rgba(255, 0, 255, 0.15);
    --shadow-focus: 0 0 0 4px rgba(255, 0, 255, 0.08);
}

@media (prefers-color-scheme: light) {
    :root:not([data-theme]) {
        --color-bg: #F0F2F5;
        --color-bg-surface: rgba(255, 255, 255, 0.7);
        --color-bg-card: rgba(255, 255, 255, 0.5);
        --color-bg-input: rgba(255, 255, 255, 0.8);
        --color-text-primary: #0A0E1A;
        --color-text-secondary: #2E3A4A;
        --color-text-muted: #7A8A9E;
        --color-text-inverse: #FFFFFF;
        --color-accent-1: #00875A;
        --color-accent-2: #0066CC;
        --color-accent-grad: linear-gradient(135deg, #00875A, #0066CC);
        --color-border: rgba(0, 0, 0, 0.06);
        --color-border-hover: rgba(0, 135, 90, 0.2);
        --color-border-focus: rgba(0, 135, 90, 0.4);
    }
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme]) {
        --color-bg: #05050A;
        --color-bg-surface: rgba(12, 16, 28, 0.6);
        --color-bg-card: rgba(255, 255, 255, 0.03);
        --color-bg-input: rgba(255, 255, 255, 0.04);
        --color-text-primary: #FFFFFF;
        --color-text-secondary: #A0B0C8;
        --color-text-muted: #5A6A85;
        --color-text-inverse: #0A0E1A;
        --color-accent-1: #00F5A0;
        --color-accent-2: #00D4FF;
        --color-accent-grad: linear-gradient(135deg, #00F5A0, #00D4FF);
        --color-border: rgba(255, 255, 255, 0.06);
        --color-border-hover: rgba(0, 245, 160, 0.25);
        --color-border-focus: rgba(0, 245, 160, 0.5);
    }
}

/* ============================================
   2. БАЗОВЫЕ СТИЛИ
   ============================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-weight: 400;
    line-height: 1.6;
    background: var(--color-bg);
    color: var(--color-text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    transition: background 0.7s cubic-bezier(0.22, 1, 0.36, 1),
                color 0.7s cubic-bezier(0.22, 1, 0.36, 1);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

::-webkit-scrollbar {
    width: 4px;
    height: 4px;
}
::-webkit-scrollbar-track {
    background: var(--color-bg);
}
::-webkit-scrollbar-thumb {
    background: var(--color-accent-1);
    border-radius: 2px;
    opacity: 0.3;
}
::-webkit-scrollbar-thumb:hover {
    opacity: 1;
}

::selection {
    background: var(--color-accent-1);
    color: var(--color-text-inverse);
}

:focus-visible {
    outline: 2px solid var(--color-accent-1);
    outline-offset: 2px;
    border-radius: 4px;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--color-accent-2);
    text-decoration: none;
    transition: color 0.3s ease;
}
a:hover {
    color: var(--color-accent-1);
}

/* ============================================
   3. КОНТЕЙНЕР
   ============================================ */

.container {
    max-width: 1200px;
    width: 92%;
    margin: 0 auto;
    padding: 0 var(--space-lg);
}
@media (min-width: 768px) {
    .container {
        padding: 0 var(--space-xxl);
    }
}
@media (min-width: 1200px) {
    .container {
        padding: 0 var(--space-xxxl);
    }
}

/* ============================================
   4. ХЕДЕР
   ============================================ */

.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: var(--space-sm) 0;
    background: var(--color-bg-surface);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-bottom: 1px solid var(--color-border);
    transition: padding 0.4s cubic-bezier(0.22, 1, 0.36, 1),
                background 0.7s cubic-bezier(0.22, 1, 0.36, 1),
                box-shadow 0.4s ease;
}

.header-scrolled {
    padding: var(--space-xs) 0;
    box-shadow: 0 4px 40px var(--color-shadow);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    width: 92%;
    margin: 0 auto;
}

.logo {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-xxs);
    transition: transform 0.3s ease;
    text-decoration: none;
}
.logo:hover {
    transform: scale(1.01);
}

.logo-main {
    font-size: clamp(1.1rem, 1.3vw, 1.5rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    background: var(--color-accent-grad);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    line-height: 1.1;
}

.logo-typing {
    font-size: clamp(0.65rem, 0.7vw, 0.8rem);
    font-weight: 400;
    color: var(--color-text-secondary);
    border-right: 1.5px solid var(--color-accent-1);
    padding-right: 3px;
    animation: blink 0.8s step-end infinite;
    white-space: nowrap;
    min-height: 1.2em;
    display: inline-block;
    letter-spacing: 0.01em;
}

@keyframes blink {
    0%, 100% { border-color: var(--color-accent-1); }
    50% { border-color: transparent; }
}

.themes {
    display: flex;
    gap: var(--space-sm);
    align-items: center;
}

.theme-btn {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-round);
    border: 1.5px solid var(--color-border);
    background: var(--color-bg-card);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    padding: 0;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}
.theme-btn:hover {
    transform: scale(1.1);
    border-color: var(--color-accent-1);
}
.theme-btn:active {
    transform: scale(0.92);
}
.theme-btn.active {
    border-color: var(--color-accent-1);
    box-shadow: 0 0 20px var(--color-accent-1);
}
.theme-btn svg {
    width: 16px;
    height: 16px;
    fill: none;
    stroke: var(--color-text-secondary);
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: stroke 0.3s ease;
    pointer-events: none;
}
.theme-btn:hover svg {
    stroke: var(--color-accent-1);
}
.theme-btn.active svg {
    stroke: var(--color-accent-1);
}

@media (max-width: 480px) {
    .theme-btn {
        width: 36px;
        height: 36px;
    }
    .theme-btn svg {
        width: 18px;
        height: 18px;
    }
    .logo-main {
        font-size: 0.95rem;
    }
    .logo-typing {
        font-size: 0.55rem;
    }
}

/* ============================================
   5. ОСНОВНОЙ КОНТЕЙНЕР
   ============================================ */

.main {
    min-height: 100vh;
    padding: 120px 0 var(--space-xxxxl);
    position: relative;
    overflow: hidden;
}

@media (max-width: 768px) {
    .main {
        padding: 100px 0 var(--space-xxxl);
    }
}
@media (max-width: 480px) {
    .main {
        padding: 90px 0 var(--space-xxl);
    }
}

.main::before {
    content: '';
    position: absolute;
    width: 80vw;
    height: 80vw;
    top: -30%;
    right: -20%;
    background: radial-gradient(circle, var(--color-accent-1) 0%, transparent 70%);
    opacity: 0.03;
    border-radius: 50%;
    pointer-events: none;
    filter: blur(100px);
    animation: floatBg 25s ease-in-out infinite alternate;
    transition: background 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}
.main::after {
    content: '';
    position: absolute;
    width: 60vw;
    height: 60vw;
    bottom: -30%;
    left: -20%;
    background: radial-gradient(circle, var(--color-accent-2) 0%, transparent 70%);
    opacity: 0.02;
    border-radius: 50%;
    pointer-events: none;
    filter: blur(100px);
    animation: floatBg 30s ease-in-out infinite alternate-reverse;
    transition: background 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes floatBg {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(40px, -40px) scale(1.1); }
}

.main-content {
    position: relative;
    z-index: 2;
    width: 100%;
}

/* ============================================
   6. HERO
   ============================================ */

.hero {
    margin-bottom: var(--space-xxxxl);
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-xxl);
    align-items: start;
}

@media (min-width: 900px) {
    .hero-grid {
        grid-template-columns: 1.2fr 1fr;
        gap: var(--space-xxxl);
        align-items: start;
    }
}

.hero-left {
    display: flex;
    flex-direction: column;
    gap: var(--space-xl);
}

.hero-title {
    font-size: clamp(2.2rem, 5vw, 4rem);
    font-weight: 900;
    letter-spacing: -0.03em;
    line-height: 1.05;
    background: var(--color-accent-grad);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-role {
    font-size: clamp(0.9rem, 1vw, 1.05rem);
    color: var(--color-accent-1);
    font-weight: 500;
    line-height: 1.5;
    margin: 0;
}

.hero-sub {
    font-size: clamp(0.95rem, 1.05vw, 1.15rem);
    color: var(--color-text-secondary);
    line-height: 1.55;
    margin: 0;
}

/* ============================================
   6.1 BENTO-СЕТКА 2×2
   ============================================ */

.bento-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-md);
}

.bento-tile {
    background: var(--color-bg-card);
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: var(--space-lg);
    text-decoration: none;
    transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-start;
    gap: var(--space-sm);
    min-height: 90px;
    position: relative;
    overflow: hidden;
}

.bento-tile::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--color-accent-grad);
    opacity: 0;
    transition: opacity 0.35s ease;
    z-index: 0;
}

.bento-tile:hover {
    transform: translateY(-4px) scale(1.02);
    border-color: var(--color-border-hover);
    box-shadow: var(--shadow-card), var(--shadow-glow);
}

.bento-tile:hover::before {
    opacity: 0.08;
}

.bento-tile:active {
    transform: scale(0.98);
}

.bento-text {
    position: relative;
    z-index: 1;
    font-size: clamp(0.85rem, 0.95vw, 1rem);
    font-weight: 500;
    color: var(--color-text-primary);
    line-height: 1.3;
}

.bento-meta {
    position: relative;
    z-index: 1;
    font-family: 'JetBrains Mono', monospace;
    font-size: clamp(0.7rem, 0.75vw, 0.8rem);
    color: var(--color-accent-1);
    letter-spacing: 0.02em;
    opacity: 0.85;
}

@media (max-width: 480px) {
    .bento-tile {
        padding: var(--space-md);
        min-height: 80px;
    }
    .bento-text {
        font-size: 0.8rem;
    }
}

/* ============================================
   6.2 ФОРМА В HERO
   ============================================ */

.hero-form {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
    width: 100%;
}

.field-group {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
    position: relative;
}

.hero-form textarea {
    width: 100%;
    background: var(--color-bg-input);
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-sm);
    padding: var(--space-lg);
    font-size: clamp(0.9rem, 1vw, 1rem);
    font-family: inherit;
    font-weight: 400;
    color: var(--color-text-primary);
    outline: none;
    min-height: 120px;
    max-height: 320px;
    resize: vertical;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    line-height: 1.5;
}

.hero-form textarea::placeholder {
    color: var(--color-text-muted);
    font-size: clamp(0.8rem, 0.9vw, 0.95rem);
    line-height: 1.45;
}

.hero-form textarea:focus {
    border-color: var(--color-accent-1);
    box-shadow: var(--shadow-focus);
}

.hero-form textarea.error {
    border-color: #e5484d;
    box-shadow: 0 0 0 4px rgba(229, 72, 77, 0.06);
    animation: shake 0.5s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-6px); }
    40% { transform: translateX(6px); }
    60% { transform: translateX(-4px); }
    80% { transform: translateX(4px); }
}

.field-hint {
    font-size: clamp(0.7rem, 0.75vw, 0.8rem);
    color: var(--color-text-muted);
    padding-left: var(--space-xxs);
    transition: color 0.3s ease;
}

.field-hint-warning {
    color: #d97706;
    font-weight: 500;
    min-height: 1.2em;
}

.field-error {
    display: none;
    font-size: clamp(0.7rem, 0.8vw, 0.85rem);
    color: #e5484d;
    padding-left: var(--space-xxs);
    font-weight: 500;
    line-height: 1.4;
}
.field-error.show {
    display: block;
}

/* ============================================
   6.3 ЧЕКБОКС СОГЛАСИЯ
   ============================================ */

.checkbox-group {
    display: flex;
    align-items: flex-start;
    gap: var(--space-sm);
    cursor: pointer;
    padding: var(--space-xs) 0;
    user-select: none;
}

.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    min-width: 20px;
    margin-top: 1px;
    cursor: pointer;
    background: var(--color-bg-input);
    border: 1.5px solid var(--color-border);
    border-radius: 6px;
    appearance: none;
    -webkit-appearance: none;
    transition: all 0.25s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
    flex-shrink: 0;
}

.checkbox-group input[type="checkbox"]:hover {
    border-color: var(--color-border-hover);
}

.checkbox-group input[type="checkbox"]:checked {
    background: var(--color-accent-grad);
    border-color: transparent;
    box-shadow: 0 0 0 3px var(--color-accent-hover);
}

.checkbox-group input[type="checkbox"]:checked::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 6px;
    width: 5px;
    height: 10px;
    border-right: 2.5px solid var(--color-text-inverse);
    border-bottom: 2.5px solid var(--color-text-inverse);
    transform: rotate(45deg);
    animation: checkPop 0.25s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes checkPop {
    0% { transform: rotate(45deg) scale(0); opacity: 0; }
    80% { transform: rotate(45deg) scale(1.2); }
    100% { transform: rotate(45deg) scale(1); opacity: 1; }
}

.checkbox-group label {
    font-size: clamp(0.8rem, 0.85vw, 0.9rem);
    color: var(--color-text-secondary);
    cursor: pointer;
    line-height: 1.4;
}

.checkbox-group label a {
    color: var(--color-accent-2);
    font-weight: 500;
    text-decoration: none;
}

.checkbox-group label a:hover {
    color: var(--color-accent-1);
    text-decoration: underline;
}

.checkbox-group.error input[type="checkbox"] {
    border-color: #e5484d;
    box-shadow: 0 0 0 3px rgba(229, 72, 77, 0.1);
    animation: shake 0.5s ease;
}

.checkbox-error {
    display: none;
    font-size: clamp(0.7rem, 0.8vw, 0.85rem);
    color: #e5484d;
    padding-left: var(--space-xxs);
    font-weight: 500;
    line-height: 1.4;
    margin-top: calc(-1 * var(--space-xs));
}

.checkbox-error.show {
    display: block;
    animation: fadeSlide 0.3s ease;
}

/* ============================================
   6.4 ФОТО В HERO
   ============================================ */

.hero-right {
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

.hero-photo {
    width: 100%;
    max-width: 460px;
    border-radius: var(--radius-lg);
    overflow: hidden;
    position: relative;
    box-shadow: var(--shadow-card), var(--shadow-glow);
}

.hero-photo img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    aspect-ratio: 4 / 5;
    transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.hero-photo:hover img {
    transform: scale(1.03);
}

@media (max-width: 900px) {
    .hero-right {
        justify-content: center;
        align-items: center;
    }
    .hero-photo {
        max-width: 360px;
    }
}

/* ============================================
   7. КНОПКИ
   ============================================ */

.btn {
    padding: var(--space-md) var(--space-xl);
    font-size: clamp(0.9rem, 0.95vw, 1rem);
    font-weight: 600;
    font-family: inherit;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    min-height: 54px;
    position: relative;
    overflow: hidden;
    letter-spacing: 0.01em;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.btn-primary {
    background: var(--color-accent-grad);
    color: var(--color-text-inverse);
    box-shadow: var(--shadow-btn);
    width: 100%;
}
.btn-primary::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(-100%);
    transition: transform 0.5s ease;
}
.btn-primary:hover::before {
    transform: translateX(0);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 40px var(--color-accent-1);
}
.btn-primary:active {
    transform: scale(0.97);
}
.btn-primary:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none !important;
}
.btn-primary .btn-text {
    position: relative;
    z-index: 1;
}
.btn-primary.loading .btn-text {
    opacity: 0;
}
.btn-primary.loading::after {
    content: '';
    position: absolute;
    width: 24px;
    height: 24px;
    border: 2.5px solid rgba(255, 255, 255, 0.15);
    border-top-color: var(--color-text-inverse);
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
    z-index: 2;
}
@keyframes spin {
    to { transform: rotate(360deg); }
}

.btn-secondary {
    background: var(--color-bg-card);
    color: var(--color-text-secondary);
    border: 1.5px solid var(--color-border);
    width: 100%;
}
.btn-secondary:hover {
    border-color: var(--color-accent-1);
    color: var(--color-accent-1);
    transform: translateY(-2px);
}
.btn-secondary:active {
    transform: scale(0.97);
}

.btn-card {
    background: var(--color-accent-grad);
    color: var(--color-text-inverse);
    padding: var(--space-sm) var(--space-lg);
    font-size: clamp(0.8rem, 0.85vw, 0.9rem);
    min-height: 44px;
    border-radius: var(--radius-xs);
    width: auto;
    align-self: flex-start;
    margin-top: var(--space-sm);
    box-shadow: var(--shadow-btn);
}
.btn-card:hover {
    transform: translateY(-2px);
    color: var(--color-text-inverse);
    box-shadow: 0 8px 30px var(--color-accent-1);
}

/* ============================================
   8. СООБЩЕНИЕ ОБ УСПЕХЕ
   ============================================ */

.msg-success {
    padding: var(--space-lg) var(--space-xl);
    border-radius: var(--radius-sm);
    background: rgba(0, 245, 160, 0.06);
    border: 1px solid rgba(0, 245, 160, 0.15);
    color: var(--color-accent-1);
    text-align: center;
    font-weight: 500;
    font-size: clamp(0.9rem, 0.95vw, 1rem);
    animation: fadeSlide 0.5s ease;
}

.msg-success svg {
    display: block;
    margin: 0 auto 0.75rem;
    fill: none;
    stroke: var(--color-accent-1);
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

@keyframes fadeSlide {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ============================================
   9. СЕКЦИИ — ОБЩЕЕ
   ============================================ */

.section-title {
    font-size: clamp(1.6rem, 3vw, 2.6rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.15;
    margin-bottom: var(--space-xxl);
    text-align: center;
    background: var(--color-accent-grad);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.cooperation {
    margin-bottom: var(--space-xxxxl);
}

.activity {
    margin-bottom: var(--space-xxxxl);
}

/* ============================================
   10. СОТРУДНИЧЕСТВО
   ============================================ */

.bento-coop {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-lg);
}

@media (min-width: 700px) {
    .bento-coop {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-xl);
    }
}

.coop-panel {
    background: var(--color-bg-card);
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

.coop-panel:hover {
    border-color: var(--color-border-hover);
    box-shadow: var(--shadow-card);
}

.coop-panel[open] {
    border-color: var(--color-accent-1);
    box-shadow: 0 0 0 3px var(--color-accent-hover), var(--shadow-card);
}

.coop-panel summary {
    list-style: none;
    cursor: pointer;
    padding: var(--space-xl);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-md);
    font-size: clamp(0.95rem, 1.05vw, 1.1rem);
    font-weight: 600;
    color: var(--color-text-primary);
    line-height: 1.3;
    transition: color 0.3s ease;
    position: relative;
}

.coop-panel summary::-webkit-details-marker {
    display: none;
}

.coop-panel summary::after {
    content: '';
    width: 10px;
    height: 10px;
    border-right: 2px solid var(--color-accent-1);
    border-bottom: 2px solid var(--color-accent-1);
    transform: rotate(45deg);
    transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
    flex-shrink: 0;
    margin-top: -4px;
}

.coop-panel[open] summary::after {
    transform: rotate(-135deg);
    margin-top: 4px;
}

.coop-panel summary:hover {
    color: var(--color-accent-1);
}

.coop-content {
    padding: 0 var(--space-xl) var(--space-xl);
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
    animation: fadeSlide 0.4s ease;
}

.coop-content p {
    font-size: clamp(0.85rem, 0.9vw, 0.95rem);
    color: var(--color-text-secondary);
    line-height: 1.5;
}

/* ============================================
   10.1 БЫСТРЫЕ ССЫЛКИ В «СОТРУДНИЧЕСТВЕ»
   ============================================ */

.coop-quick-title {
    font-size: clamp(0.75rem, 0.8vw, 0.85rem);
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--color-text-muted);
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    text-align: center;
    margin: var(--space-xxl) 0 var(--space-lg);
}

.coop-quick-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--space-md);
}

.quick-link {
    font-size: clamp(0.8rem, 0.85vw, 0.9rem);
    color: var(--color-text-secondary);
    padding: var(--space-sm) var(--space-lg);
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-xs);
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    text-decoration: none;
    line-height: 1.4;
}

.quick-link:hover {
    border-color: var(--color-accent-1);
    color: var(--color-accent-1);
    transform: translateY(-1px);
    opacity: 1;
}

/* ============================================
   11. КАРТОЧКИ — ЧЕМ МОГУ БЫТЬ ПОЛЕЗЕН
   ============================================ */

.cards-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-lg);
}

@media (min-width: 700px) {
    .cards-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-xl);
    }
}

@media (min-width: 1024px) {
    .cards-grid {
        grid-template-columns: 1fr 1fr 1fr;
        gap: var(--space-xl);
    }
}

.card {
    background: var(--color-bg-card);
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: var(--space-xl);
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
    transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: var(--radius-md);
    background: var(--color-accent-grad);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: -1;
}

.card:hover::before {
    opacity: 0.1;
}

.card:hover {
    transform: translateY(-6px) scale(1.01);
    border-color: var(--color-border-hover);
    box-shadow: var(--shadow-card), var(--shadow-glow);
}

.card-title {
    font-size: clamp(1rem, 1.15vw, 1.2rem);
    font-weight: 700;
    color: var(--color-text-primary);
    line-height: 1.3;
    letter-spacing: -0.01em;
}

.card-text {
    font-size: clamp(0.85rem, 0.9vw, 0.95rem);
    color: var(--color-text-secondary);
    line-height: 1.5;
}

.card-link {
    font-size: clamp(0.85rem, 0.9vw, 0.95rem);
    font-weight: 600;
    color: var(--color-accent-1);
    align-self: flex-start;
    transition: color 0.3s ease;
}
.card-link:hover {
    color: var(--color-accent-2);
    text-decoration: underline;
}

.card-sublinks {
    display: flex;
    flex-direction: column;
    gap: var(--space-xxs);
    margin-top: var(--space-xs);
    padding-top: var(--space-md);
    border-top: 1px solid var(--color-border);
}

.card-sublinks-title {
    font-size: clamp(0.75rem, 0.8vw, 0.85rem);
    font-weight: 600;
    color: var(--color-text-primary);
    margin-bottom: var(--space-xxs);
}

.card-sublinks a {
    font-size: clamp(0.8rem, 0.85vw, 0.9rem);
    color: var(--color-text-secondary);
    transition: color 0.3s ease;
}
.card-sublinks a:hover {
    color: var(--color-accent-1);
}

.card-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}

.card-list li {
    font-size: clamp(0.8rem, 0.85vw, 0.9rem);
    color: var(--color-text-secondary);
    line-height: 1.4;
    padding-left: var(--space-md);
    position: relative;
}

.card-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--color-accent-1);
    opacity: 0.6;
}

.card-list li strong {
    color: var(--color-text-primary);
    font-weight: 600;
}

/* Спойлер внутри карточки MVP */
.mvp-hidden {
    margin-top: var(--space-sm);
}

.card-toggle {
    background: transparent;
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-xs);
    color: var(--color-accent-1);
    font-size: clamp(0.8rem, 0.85vw, 0.9rem);
    font-weight: 600;
    font-family: inherit;
    padding: var(--space-sm) var(--space-lg);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    align-self: flex-start;
    margin-top: var(--space-xs);
}

.card-toggle:hover {
    border-color: var(--color-accent-1);
    background: var(--color-accent-hover);
    transform: translateY(-1px);
}

.card-toggle:active {
    transform: scale(0.97);
}

/* ============================================
   11.1 ПОРТФЕЛЬ
   ============================================ */

.portfolio-summary {
    margin-bottom: var(--space-xxxxl);
}

.portfolio-sub {
    font-size: clamp(0.95rem, 1vw, 1.05rem);
    color: var(--color-text-secondary);
    text-align: center;
    max-width: 640px;
    margin: 0 auto var(--space-xxl);
    line-height: 1.55;
}

.portfolio-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-md);
    margin-bottom: var(--space-xl);
}

@media (min-width: 700px) {
    .portfolio-stats {
        grid-template-columns: repeat(4, 1fr);
        gap: var(--space-lg);
    }
}

.stat-card {
    background: var(--color-bg-card);
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: var(--space-xl) var(--space-lg);
    text-align: center;
    transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

.stat-card:hover {
    border-color: var(--color-border-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-card);
}

.stat-num {
    font-family: 'JetBrains Mono', monospace;
    font-size: clamp(2rem, 3.5vw, 3rem);
    font-weight: 700;
    background: var(--color-accent-grad);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    line-height: 1;
    margin-bottom: var(--space-sm);
    letter-spacing: -0.03em;
}

.stat-label {
    font-size: clamp(0.8rem, 0.85vw, 0.9rem);
    color: var(--color-text-secondary);
    line-height: 1.4;
}

.portfolio-link {
    text-align: center;
    margin: 0;
}

.portfolio-link a {
    font-size: clamp(0.9rem, 0.95vw, 1rem);
    color: var(--color-accent-1);
    font-weight: 600;
    text-decoration: none;
}

.portfolio-link a:hover {
    color: var(--color-accent-2);
    text-decoration: underline;
}

/* ============================================
   11.2 ЧТО ПОЧИТАТЬ
   ============================================ */

.reading {
    margin-bottom: var(--space-xxxxl);
}

.reading-sub {
    font-size: clamp(0.95rem, 1vw, 1.05rem);
    color: var(--color-text-secondary);
    text-align: center;
    max-width: 640px;
    margin: 0 auto var(--space-xxl);
    line-height: 1.55;
}

.reading-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-lg);
}

@media (min-width: 700px) {
    .reading-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: var(--space-xl);
    }
}

.reading-card {
    background: var(--color-bg-card);
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: var(--space-xl);
    text-decoration: none;
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
    transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

.reading-card:hover {
    transform: translateY(-4px);
    border-color: var(--color-border-hover);
    box-shadow: var(--shadow-card), var(--shadow-glow);
    opacity: 1;
}

.reading-card h3 {
    font-size: clamp(1rem, 1.1vw, 1.15rem);
    font-weight: 700;
    color: var(--color-accent-1);
    line-height: 1.3;
    letter-spacing: -0.01em;
    margin: 0;
}

.reading-card p {
    font-size: clamp(0.85rem, 0.9vw, 0.95rem);
    color: var(--color-text-secondary);
    line-height: 1.5;
    margin: 0;
}

/* ============================================
   12. БЛОК ПЕРЕД ФУТЕРОМ — 2 КНОПКИ
   ============================================ */

.cta-bottom {
    text-align: center;
    padding: var(--space-xxl) 0 var(--space-xxxl);
    border-top: 1px solid var(--color-border);
}

.cta-bottom-text {
    font-size: clamp(0.95rem, 1vw, 1.1rem);
    color: var(--color-text-secondary);
    max-width: 640px;
    margin: 0 auto var(--space-xl);
    line-height: 1.55;
}

.cta-bottom-buttons {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
    max-width: 520px;
    margin: 0 auto;
}

@media (min-width: 640px) {
    .cta-bottom-buttons {
        flex-direction: row;
        justify-content: center;
    }
    .cta-bottom-buttons .btn {
        width: auto;
        min-width: 240px;
    }
}

/* ============================================
   13. ФУТЕР
   ============================================ */

.footer {
    padding: var(--space-xxl) 0;
    border-top: 1px solid var(--color-border);
    background: var(--color-bg-surface);
    backdrop-filter: blur(12px);
    text-align: center;
}

.footer-intro {
    margin-bottom: var(--space-xl);
}

.footer-intro p {
    font-size: clamp(0.85rem, 0.9vw, 0.95rem);
    color: var(--color-text-secondary);
    line-height: 1.6;
    margin-bottom: var(--space-xxs);
}

.footer-intro strong {
    color: var(--color-text-primary);
    font-weight: 600;
}

.footer-links-group {
    margin-bottom: var(--space-xl);
}

.footer-group-title {
    font-size: clamp(0.8rem, 0.85vw, 0.9rem);
    font-weight: 600;
    color: var(--color-text-primary);
    margin-bottom: var(--space-md);
}

.footer-links-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-sm) var(--space-md);
    max-width: 400px;
    margin: 0 auto var(--space-sm);
}

@media (min-width: 640px) {
    .footer-links-grid {
        grid-template-columns: repeat(4, 1fr);
        max-width: 640px;
    }
}

.footer-links-grid a {
    font-size: clamp(0.8rem, 0.85vw, 0.9rem);
    color: var(--color-accent-2);
    transition: color 0.3s ease;
    text-align: center;
}

.footer-links-grid a:hover {
    color: var(--color-accent-1);
}

.footer-links-hidden {
    animation: fadeSlide 0.3s ease;
}

.footer-links-hidden .footer-links-grid {
    margin-top: var(--space-sm);
}

.footer-toggle {
    background: transparent;
    border: none;
    color: var(--color-accent-1);
    font-size: clamp(0.75rem, 0.8vw, 0.85rem);
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    padding: var(--space-xs);
    transition: color 0.3s ease;
}

.footer-toggle:hover {
    color: var(--color-accent-2);
    text-decoration: underline;
}

.footer-block {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: var(--space-sm) var(--space-lg);
    margin-bottom: var(--space-md);
    font-size: clamp(0.8rem, 0.85vw, 0.9rem);
}

.footer-label {
    color: var(--color-text-muted);
    font-weight: 500;
}

.footer-block a {
    color: var(--color-accent-2);
    transition: color 0.3s ease;
}
.footer-block a:hover {
    color: var(--color-accent-1);
}

.footer-copy {
    font-size: clamp(0.8rem, 0.85vw, 0.9rem);
    color: var(--color-text-secondary);
    margin-top: var(--space-lg);
    margin-bottom: var(--space-sm);
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: var(--space-xs);
    font-size: clamp(0.75rem, 0.8vw, 0.85rem);
    margin-bottom: var(--space-sm);
}

.footer-links a {
    color: var(--color-text-secondary);
    transition: color 0.3s ease;
}
.footer-links a:hover {
    color: var(--color-accent-1);
}

.footer-divider {
    display: inline-block;
    margin: 0 var(--space-xs);
    color: var(--color-text-muted);
    opacity: 0.4;
}

.footer-legal {
    font-size: 0.65rem;
    color: var(--color-text-muted);
    opacity: 0.5;
    margin-top: var(--space-sm);
}

/* ============================================
   14. COOKIE-БАННЕР
   ============================================ */

.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: var(--color-bg-surface);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--color-border);
    padding: var(--space-lg) var(--space-xl);
    box-shadow: 0 -8px 40px var(--color-shadow);
    animation: slideUp 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}
@keyframes slideUp {
    from { transform: translateY(100%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.cookie-banner-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-xl);
    flex-wrap: wrap;
}

.cookie-text {
    font-size: clamp(0.8rem, 0.85vw, 0.9rem);
    color: var(--color-text-secondary);
    margin: 0;
    flex: 1;
    line-height: 1.5;
}

.cookie-text strong {
    color: var(--color-text-primary);
    font-weight: 600;
    display: block;
    margin-bottom: var(--space-xxs);
}

.cookie-text a {
    color: var(--color-accent-2);
    font-weight: 500;
    text-decoration: underline;
}
.cookie-text a:hover {
    color: var(--color-accent-1);
}

.cookie-btn {
    padding: var(--space-sm) var(--space-xl);
    border: none;
    border-radius: var(--radius-xs);
    background: var(--color-accent-grad);
    color: var(--color-text-inverse);
    font-weight: 600;
    font-size: clamp(0.8rem, 0.85vw, 0.9rem);
    cursor: pointer;
    font-family: inherit;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    white-space: nowrap;
}
.cookie-btn:hover {
    transform: scale(1.03);
    box-shadow: 0 0 30px var(--color-accent-1);
}

@media (max-width: 640px) {
    .cookie-banner {
        padding: var(--space-md) var(--space-lg);
    }
    .cookie-banner-inner {
        flex-direction: column;
        align-items: stretch;
        gap: var(--space-md);
        text-align: center;
    }
    .cookie-btn {
        width: 100%;
        padding: var(--space-sm);
    }
}

/* ============================================
   15. 404 И OFFLINE
   ============================================ */

.error-404 {
    text-align: center;
    padding: var(--space-xxxl) 0;
}

.error-404 .code {
    font-size: clamp(4rem, 10vw, 8rem);
    font-weight: 900;
    background: var(--color-accent-grad);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    line-height: 1;
}

.error-404 .message {
    font-size: clamp(1rem, 1.1vw, 1.2rem);
    color: var(--color-text-secondary);
    margin: var(--space-lg) 0 var(--space-xxl);
}

/* ============================================
   16. ДОСТУПНОСТЬ
   ============================================ */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}