/* --- Современный · Светлая тема --- */
[data-style="modern"][data-theme="light"] {
  --bg: #FBFBFD;
  --bg-secondary: #F5F5F7;
  --bg-tertiary: #E8E8ED;
  --fg: #1D1D1F;
  --fg-secondary: #424245;
  --fg-muted: #86868B;
  --accent: #0071E3;
  --accent-rgb: 0, 113, 227;
  --accent-hover: #0077ED;
  --accent-glow: rgba(0, 113, 227, 0.15);
  --card-bg: rgba(255, 255, 255, 0.82);
  --card-border: rgba(0, 0, 0, 0.06);
  --card-hover-border: rgba(0, 113, 227, 0.3);
  --glass-bg: rgba(251, 251, 253, 0.72);
  --glass-border: rgba(0, 0, 0, 0.08);
  --input-bg: rgba(255, 255, 255, 0.6);
  --input-border: rgba(0, 0, 0, 0.1);
  --input-focus: rgba(0, 113, 227, 0.5);
  --blob-1: rgba(0, 113, 227, 0.06);
  --blob-2: rgba(175, 82, 222, 0.04);
  --blob-3: rgba(0, 113, 227, 0.04);
  --particle-rgb: 0, 113, 227;
  --nav-bg: rgba(251, 251, 253, 0.82);
  --overlay: rgba(0, 0, 0, 0.4);
  --toast-bg: rgba(29, 29, 31, 0.92);
  --toast-fg: #F5F5F7;
  --shadow-card: 0 2px 12px rgba(0, 0, 0, 0.04);
  --shadow-card-hover: 0 8px 30px rgba(0, 113, 227, 0.1);
  --scrollbar-thumb: rgba(0, 0, 0, 0.15);
}

/* --- Современный · Тёмная тема --- */
[data-style="modern"][data-theme="dark"] {
  --bg: #000000;
  --bg-secondary: #1C1C1E;
  --bg-tertiary: #2C2C2E;
  --fg: #F5F5F7;
  --fg-secondary: #E8E8ED;
  --fg-muted: #98989D;
  --accent: #2997FF;
  --accent-rgb: 41, 151, 255;
  --accent-hover: #4DA3FF;
  --accent-glow: rgba(41, 151, 255, 0.2);
  --card-bg: rgba(28, 28, 30, 0.82);
  --card-border: rgba(255, 255, 255, 0.08);
  --card-hover-border: rgba(41, 151, 255, 0.35);
  --glass-bg: rgba(28, 28, 30, 0.72);
  --glass-border: rgba(255, 255, 255, 0.06);
  --input-bg: rgba(0, 0, 0, 0.4);
  --input-border: rgba(255, 255, 255, 0.1);
  --input-focus: rgba(41, 151, 255, 0.5);
  --blob-1: rgba(41, 151, 255, 0.05);
  --blob-2: rgba(175, 82, 222, 0.04);
  --blob-3: rgba(41, 151, 255, 0.03);
  --particle-rgb: 41, 151, 255;
  --nav-bg: rgba(0, 0, 0, 0.82);
  --overlay: rgba(0, 0, 0, 0.6);
  --toast-bg: rgba(245, 245, 247, 0.95);
  --toast-fg: #1D1D1F;
  --shadow-card: 0 2px 12px rgba(0, 0, 0, 0.2);
  --shadow-card-hover: 0 8px 30px rgba(41, 151, 255, 0.12);
  --scrollbar-thumb: rgba(255, 255, 255, 0.15);
}

/* --- Пустыня · Светлая --- */
[data-style="desert"][data-theme="light"] {
  --bg: #F7EDE2;
  --bg-secondary: #EFE0D0;
  --bg-tertiary: #E6D3BF;
  --fg: #2C1810;
  --fg-secondary: #5C3D2E;
  --fg-muted: #8B6B5A;
  --accent: #C46D3B;
  --accent-rgb: 196, 109, 59;
  --accent-hover: #A85A2E;
  --accent-glow: rgba(196, 109, 59, 0.25);
  --card-bg: rgba(247, 237, 226, 0.82);
  --card-border: rgba(196, 109, 59, 0.14);
  --card-hover-border: rgba(196, 109, 59, 0.38);
  --glass-bg: rgba(247, 237, 226, 0.65);
  --glass-border: rgba(196, 109, 59, 0.12);
  --input-bg: rgba(255, 255, 255, 0.55);
  --input-border: rgba(196, 109, 59, 0.2);
  --input-focus: rgba(196, 109, 59, 0.55);
  --blob-1: rgba(196, 109, 59, 0.09);
  --blob-2: rgba(232, 145, 58, 0.07);
  --blob-3: rgba(168, 90, 46, 0.06);
  --particle-rgb: 196, 109, 59;
  --nav-bg: rgba(247, 237, 226, 0.82);
  --overlay: rgba(44, 24, 16, 0.45);
  --toast-bg: rgba(44, 24, 16, 0.92);
  --toast-fg: #F7EDE2;
  --shadow-card: 0 4px 24px rgba(44, 24, 16, 0.08);
  --shadow-card-hover: 0 12px 40px rgba(196, 109, 59, 0.15);
  --scrollbar-thumb: rgba(196, 109, 59, 0.3);
}

/* --- Пустыня · Тёмная --- */
[data-style="desert"][data-theme="dark"] {
  --bg: #1A120B;
  --bg-secondary: #2C1F14;
  --bg-tertiary: #3A2A1D;
  --fg: #F0E0D0;
  --fg-secondary: #C8B0A0;
  --fg-muted: #8B7464;
  --accent: #E8913A;
  --accent-rgb: 232, 145, 58;
  --accent-hover: #F0A050;
  --accent-glow: rgba(232, 145, 58, 0.25);
  --card-bg: rgba(44, 31, 20, 0.82);
  --card-border: rgba(232, 145, 58, 0.1);
  --card-hover-border: rgba(232, 145, 58, 0.32);
  --glass-bg: rgba(44, 31, 20, 0.65);
  --glass-border: rgba(232, 145, 58, 0.1);
  --input-bg: rgba(26, 18, 11, 0.55);
  --input-border: rgba(232, 145, 58, 0.15);
  --input-focus: rgba(232, 145, 58, 0.5);
  --blob-1: rgba(232, 145, 58, 0.07);
  --blob-2: rgba(196, 109, 59, 0.05);
  --blob-3: rgba(240, 160, 80, 0.04);
  --particle-rgb: 232, 145, 58;
  --nav-bg: rgba(26, 18, 11, 0.88);
  --overlay: rgba(0, 0, 0, 0.55);
  --toast-bg: rgba(240, 224, 208, 0.95);
  --toast-fg: #1A120B;
  --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.2);
  --shadow-card-hover: 0 12px 40px rgba(232, 145, 58, 0.12);
  --scrollbar-thumb: rgba(232, 145, 58, 0.3);
}

/* --- Оазис · Светлая --- */
[data-style="oasis"][data-theme="light"] {
  --bg: #E8F0E4;
  --bg-secondary: #D4E4CC;
  --bg-tertiary: #C0D8B4;
  --fg: #1A2E1A;
  --fg-secondary: #2D4A2D;
  --fg-muted: #5A7A5A;
  --accent: #1B7A3D;
  --accent-rgb: 27, 122, 61;
  --accent-hover: #156131;
  --accent-glow: rgba(27, 122, 61, 0.25);
  --card-bg: rgba(232, 240, 228, 0.82);
  --card-border: rgba(27, 122, 61, 0.14);
  --card-hover-border: rgba(27, 122, 61, 0.38);
  --glass-bg: rgba(232, 240, 228, 0.65);
  --glass-border: rgba(27, 122, 61, 0.12);
  --input-bg: rgba(255, 255, 255, 0.55);
  --input-border: rgba(27, 122, 61, 0.2);
  --input-focus: rgba(27, 122, 61, 0.55);
  --blob-1: rgba(27, 122, 61, 0.09);
  --blob-2: rgba(0, 137, 123, 0.07);
  --blob-3: rgba(76, 175, 80, 0.06);
  --particle-rgb: 27, 122, 61;
  --nav-bg: rgba(232, 240, 228, 0.82);
  --overlay: rgba(26, 46, 26, 0.45);
  --toast-bg: rgba(26, 46, 26, 0.92);
  --toast-fg: #E8F0E4;
  --shadow-card: 0 4px 24px rgba(26, 46, 26, 0.08);
  --shadow-card-hover: 0 12px 40px rgba(27, 122, 61, 0.15);
  --scrollbar-thumb: rgba(27, 122, 61, 0.3);
}

/* --- Оазис · Тёмная --- */
[data-style="oasis"][data-theme="dark"] {
  --bg: #0D1A12;
  --bg-secondary: #152B1C;
  --bg-tertiary: #1E3D26;
  --fg: #D8ECD8;
  --fg-secondary: #A8D0A8;
  --fg-muted: #6A9A6A;
  --accent: #34D87A;
  --accent-rgb: 52, 216, 122;
  --accent-hover: #52E894;
  --accent-glow: rgba(52, 216, 122, 0.25);
  --card-bg: rgba(21, 43, 28, 0.82);
  --card-border: rgba(52, 216, 122, 0.1);
  --card-hover-border: rgba(52, 216, 122, 0.32);
  --glass-bg: rgba(21, 43, 28, 0.65);
  --glass-border: rgba(52, 216, 122, 0.1);
  --input-bg: rgba(13, 26, 18, 0.55);
  --input-border: rgba(52, 216, 122, 0.15);
  --input-focus: rgba(52, 216, 122, 0.5);
  --blob-1: rgba(52, 216, 122, 0.07);
  --blob-2: rgba(27, 122, 61, 0.05);
  --blob-3: rgba(0, 137, 123, 0.04);
  --particle-rgb: 52, 216, 122;
  --nav-bg: rgba(13, 26, 18, 0.88);
  --overlay: rgba(0, 0, 0, 0.55);
  --toast-bg: rgba(216, 236, 216, 0.95);
  --toast-fg: #0D1A12;
  --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.2);
  --shadow-card-hover: 0 12px 40px rgba(52, 216, 122, 0.12);
  --scrollbar-thumb: rgba(52, 216, 122, 0.3);
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scrollbar-width: thin; scrollbar-color: var(--scrollbar-thumb) transparent; }
body { font-family: 'DM Sans', sans-serif; background: var(--bg); color: var(--fg); line-height: 1.6; overflow-x: hidden; transition: background-color 0.6s ease, color 0.6s ease; min-height: 100vh; }
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--scrollbar-thumb); border-radius: 4px; }
a { color: var(--accent); text-decoration: none; transition: color 0.3s ease; }
a:hover { color: var(--accent-hover); }
img { display: block; max-width: 100%; }
button { cursor: pointer; font-family: inherit; border: none; background: none; }
input, textarea { font-family: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
#bg-canvas { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
.bg-blobs { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.blob { position: absolute; border-radius: 50%; filter: blur(100px); will-change: transform; transition: background 0.8s ease; }
.blob-1 { width: 520px; height: 520px; background: var(--blob-1); top: -120px; right: -80px; animation: blobDrift1 22s ease-in-out infinite; }
.blob-2 { width: 420px; height: 420px; background: var(--blob-2); bottom: 15%; left: -100px; animation: blobDrift2 28s ease-in-out infinite; }
.blob-3 { width: 360px; height: 360px; background: var(--blob-3); top: 45%; right: 25%; animation: blobDrift3 25s ease-in-out infinite; }
@keyframes blobDrift1 { 0%, 100% { transform: translate(0, 0) scale(1); } 33% { transform: translate(-90px, 70px) scale(1.12); } 66% { transform: translate(50px, -50px) scale(0.9); } }
@keyframes blobDrift2 { 0%, 100% { transform: translate(0, 0) scale(1); } 33% { transform: translate(70px, -60px) scale(0.88); } 66% { transform: translate(-40px, 50px) scale(1.1); } }
@keyframes blobDrift3 { 0%, 100% { transform: translate(0, 0) scale(1); } 50% { transform: translate(-60px, -70px) scale(1.08); } }
#header { position: fixed; top: 0; left: 0; right: 0; z-index: 100; transition: background-color 0.4s ease, box-shadow 0.4s ease, backdrop-filter 0.4s ease; }
#header.scrolled { background: var(--nav-bg); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); box-shadow: 0 1px 0 var(--card-border); }
.nav-container { max-width: 1200px; margin: 0 auto; padding: 0 24px; height: 68px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.logo { font-family: 'Cormorant Garamond', serif; font-size: 1.5rem; font-weight: 700; color: var(--fg); letter-spacing: -0.02em; white-space: nowrap; transition: color 0.4s ease; }
.logo:hover { color: var(--accent); }
.nav-links { display: flex; align-items: center; gap: 8px; }
.nav-link { padding: 8px 16px; border-radius: 8px; font-size: 0.9rem; font-weight: 500; color: var(--fg-muted); transition: color 0.3s ease, background-color 0.3s ease; }
.nav-link:hover, .nav-link.active { color: var(--fg); background: var(--card-border); }
.nav-link.active { color: var(--accent); }
.nav-controls { display: flex; align-items: center; gap: 8px; }
.control-btn { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: 8px; font-size: 0.82rem; font-weight: 500; color: var(--fg-muted); background: var(--card-border); transition: all 0.3s ease; white-space: nowrap; }
.control-btn:hover { color: var(--accent); background: var(--accent-glow); }
.control-btn i { font-size: 0.9rem; }
.lang-switcher { display: flex; border-radius: 8px; overflow: hidden; border: 1px solid var(--card-border); transition: border-color 0.3s ease; }
.lang-btn { padding: 7px 12px; font-size: 0.78rem; font-weight: 600; color: var(--fg-muted); background: transparent; transition: all 0.3s ease; letter-spacing: 0.04em; }
.lang-btn.active { background: var(--accent); color: #fff; }
.lang-btn:not(.active):hover { color: var(--fg); background: var(--card-border); }
.mobile-menu-btn { display: none; flex-direction: column; gap: 5px; padding: 8px; }
.mobile-menu-btn span { display: block; width: 22px; height: 2px; background: var(--fg); border-radius: 2px; transition: all 0.3s ease; }
.mobile-menu-btn.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.mobile-menu-btn.open span:nth-child(2) { opacity: 0; }
.mobile-menu-btn.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }
.hero { position: relative; z-index: 1; min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 120px 24px 80px; }
.hero-content { max-width: 720px; text-align: center; }
.hero-tag { display: inline-block; padding: 6px 18px; border-radius: 999px; font-size: 0.82rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); background: var(--accent-glow); border: 1px solid var(--card-hover-border); margin-bottom: 24px; transition: all 0.4s ease; }
.hero-title { font-family: 'Cormorant Garamond', serif; font-size: clamp(2.8rem, 7vw, 5rem); font-weight: 700; line-height: 1.08; letter-spacing: -0.03em; color: var(--fg); margin-bottom: 20px; transition: color 0.4s ease; }
.hero-desc { font-size: 1.1rem; color: var(--fg-secondary); max-width: 540px; margin: 0 auto 36px; line-height: 1.7; transition: color 0.4s ease; }
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-bottom: 56px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 28px; border-radius: 10px; font-size: 0.92rem; font-weight: 600; transition: all 0.3s ease; white-space: nowrap; }
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 4px 16px var(--accent-glow); }
.btn-primary:hover { background: var(--accent-hover); box-shadow: 0 6px 24px var(--accent-glow); transform: translateY(-2px); color: #fff; }
.btn-outline { border: 1.5px solid var(--card-hover-border); color: var(--fg); background: transparent; }
.btn-outline:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-glow); }
.btn-full { width: 100%; }
.hero-stats { display: flex; align-items: center; justify-content: center; gap: 32px; }
.stat { display: flex; flex-direction: column; align-items: center; }
.stat-number { font-family: 'Cormorant Garamond', serif; font-size: 2.4rem; font-weight: 700; color: var(--accent); line-height: 1.1; }
.stat-label { font-size: 0.8rem; color: var(--fg-muted); text-transform: uppercase; letter-spacing: 0.06em; font-weight: 500; }
.stat-divider { width: 1px; height: 40px; background: var(--card-border); }
.hero-scroll-hint { position: absolute; bottom: 32px; left: 50%; transform: translateX(-50%); }
.scroll-line { width: 1px; height: 48px; background: linear-gradient(to bottom, var(--accent), transparent); animation: scrollPulse 2s ease-in-out infinite; }
@keyframes scrollPulse { 0%, 100% { opacity: 0.3; transform: scaleY(0.6); transform-origin: top; } 50% { opacity: 1; transform: scaleY(1); } }
.toast-container { position: fixed; bottom: 24px; right: 24px; z-index: 300; display: flex; flex-direction: column; gap: 10px; pointer-events: none; }
.toast { display: flex; align-items: center; gap: 10px; padding: 14px 20px; border-radius: 12px; background: var(--toast-bg); color: var(--toast-fg); font-size: 0.88rem; font-weight: 500; box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2); pointer-events: auto; animation: toastIn 0.4s cubic-bezier(0.22, 1, 0.36, 1) forwards; max-width: 360px; }
.toast.removing { animation: toastOut 0.35s ease forwards; }
.toast i { font-size: 1rem; flex-shrink: 0; }
.toast.success i { color: #2ECC71; }
.toast.error i { color: #E74C3C; }
.toast.info i { color: var(--accent); }
@keyframes toastIn { from { opacity: 0; transform: translateX(40px) scale(0.95); } to { opacity: 1; transform: translateX(0) scale(1); } }
@keyframes toastOut { to { opacity: 0; transform: translateX(40px) scale(0.95); } }
.contact-form h4 { font-family: 'Cormorant Garamond', serif; font-size: 1.4rem; font-weight: 700; color: var(--fg); margin-bottom: 24px; }
.form-group { margin-bottom: 20px; position: relative; }
.form-group label { display: block; font-size: 0.78rem; font-weight: 600; color: var(--fg-secondary); margin-bottom: 6px; text-transform: uppercase; letter-spacing: 0.04em; }
.form-group input, .form-group textarea { width: 100%; padding: 12px 16px; border-radius: 10px; border: 1.5px solid var(--input-border); background: var(--input-bg); color: var(--fg); font-size: 0.9rem; transition: all 0.3s ease; outline: none; }
.form-group input::placeholder, .form-group textarea::placeholder { color: var(--fg-muted); opacity: 0.6; }
.form-group input:focus, .form-group textarea:focus { border-color: var(--input-focus); box-shadow: 0 0 0 3px var(--accent-glow); }
.form-group textarea { resize: vertical; min-height: 100px; }
.form-error { display: none; font-size: 0.75rem; color: #E74C3C; margin-top: 4px; }
.form-group.error input, .form-group.error textarea { border-color: #E74C3C; }
.form-group.error .form-error { display: block; }
.footer { position: relative; z-index: 1; text-align: center; padding: 32px 24px; font-size: 0.82rem; color: var(--fg-muted); border-top: 1px solid var(--card-border); transition: all 0.4s ease; }
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1); }
.reveal.visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; } html { scroll-behavior: auto; } .reveal { opacity: 1; transform: none; } .project-card { opacity: 1; transform: none; } }
@media (max-width: 768px) { .nav-links { position: fixed; top: 68px; left: 0; right: 0; flex-direction: column; padding: 16px; background: var(--nav-bg); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border-bottom: 1px solid var(--card-border); transform: translateY(-120%); opacity: 0; transition: transform 0.4s ease, opacity 0.4s ease; z-index: 99; } .nav-links.open { transform: translateY(0); opacity: 1; } .nav-link { width: 100%; text-align: center; padding: 12px; } .mobile-menu-btn { display: flex; } .control-btn span { display: none; } .hero-stats { gap: 20px; } .stat-number { font-size: 1.8rem; } .hero { padding: 100px 20px 60px; } }
@media (max-width: 420px) { .hero-actions { flex-direction: column; align-items: center; } .hero-actions .btn { width: 100%; } }