/* =================================================================
   Modul — Инженерные решения
   Архитектура стилей:
   1. Дизайн-токены (цвета, типографика, тени, радиусы) + тёмная тема
   2. Сброс и базовые стили
   3. Утилиты и доступность
   4. Компоненты (навигация, герой, секции, карточки, футер)
   5. Адаптивность
   6. prefers-reduced-motion
   ================================================================= */

/* ============================ 1. ТОКЕНЫ ========================== */
:root {
  /* Бренд */
  --brand: #2563eb;
  --brand-strong: #1d4ed8;
  --brand-soft: #3b82f6;
  --brand-2: #8b5cf6;

  /* Светлая тема */
  --bg: #ffffff;
  --bg-subtle: #f6f8fc;
  --bg-elev: #ffffff;
  --surface-soft: #eef2ff;
  --text: #0f172a;
  --text-muted: #5b6b85;
  --heading: #0f172a;
  --border: #e6ebf3;
  --border-strong: #d4ddea;

  /* Градиенты и акценты */
  --accent: var(--brand);
  --accent-solid: #2563eb; /* фон залитых кнопок: всегда контрастен к белому тексту */
  --accent-contrast: #ffffff;
  --ring: rgba(37, 99, 235, 0.45);
  --grad-brand: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
  --grad-soft: linear-gradient(135deg, #eef2ff 0%, #e0e7ff 100%);

  /* Тени */
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 6px 18px -6px rgba(15, 23, 42, 0.14);
  --shadow-lg: 0 18px 40px -12px rgba(15, 23, 42, 0.2);
  --shadow-xl: 0 30px 60px -18px rgba(15, 23, 42, 0.28);
  --shadow-brand: 0 10px 30px -8px rgba(37, 99, 235, 0.45);

  /* Геометрия */
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 22px;
  --radius-pill: 999px;

  /* Слои */
  --z-nav: 1000;
  --z-overlay: 1100;
  --z-menu: 1200;

  --maxw: 1200px;
  --maxw-wide: 1400px;
  --nav-h: 76px;

  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

/* Тёмная тема */
[data-theme='dark'] {
  --bg: #0b1120;
  --bg-subtle: #0f172a;
  --bg-elev: #131c31;
  --surface-soft: #18233d;
  --text: #e8edf6;
  --text-muted: #9aa8c2;
  --heading: #f4f7fc;
  --border: #1e2a44;
  --border-strong: #2a3a5c;

  --accent: #60a5fa;
  --accent-solid: #3b82f6;
  --ring: rgba(96, 165, 250, 0.5);
  --grad-soft: linear-gradient(135deg, #18233d 0%, #1e2a4a 100%);

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 8px 22px -8px rgba(0, 0, 0, 0.6);
  --shadow-lg: 0 22px 48px -14px rgba(0, 0, 0, 0.7);
  --shadow-xl: 0 34px 70px -20px rgba(0, 0, 0, 0.8);
  --shadow-brand: 0 12px 34px -10px rgba(96, 165, 250, 0.45);
}

/* ===================== 2. СБРОС / БАЗА =========================== */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 10px);
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: background 0.4s var(--ease), color 0.4s var(--ease);
}

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

a {
  color: inherit;
}

::selection {
  background: rgba(59, 130, 246, 0.25);
}

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 40px);
}

/* ================= 3. УТИЛИТЫ / ДОСТУПНОСТЬ ===================== */
.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: var(--z-menu);
  background: var(--accent);
  color: #fff;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  text-decoration: none;
  transition: top 0.25s var(--ease);
}
.skip-link:focus {
  top: 16px;
}

:focus-visible {
  outline: 3px solid var(--ring);
  outline-offset: 3px;
  border-radius: 6px;
}

/* Индикатор прокрутки */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  z-index: calc(var(--z-nav) + 1);
  background: transparent;
  pointer-events: none;
}
.scroll-progress-bar {
  display: block;
  height: 100%;
  width: 0;
  background: var(--grad-brand);
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.6);
  transition: width 0.1s linear;
}

/* ====================== 4. НАВИГАЦИЯ ============================ */
.navbar {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: var(--z-nav);
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  backdrop-filter: blur(18px) saturate(140%);
  border-bottom: 1px solid transparent;
  transition: background 0.3s var(--ease), border-color 0.3s var(--ease),
    box-shadow 0.3s var(--ease);
}
.navbar.scrolled {
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  border-bottom-color: var(--border);
  box-shadow: var(--shadow-sm);
}

.nav-container {
  max-width: var(--maxw-wide);
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 40px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--nav-h);
  gap: 16px;
}

.nav-logo {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}
.nav-logo img {
  height: 40px;
  width: auto;
  transition: transform 0.3s var(--ease);
}
[data-theme='dark'] .nav-logo img {
  filter: brightness(0) invert(1);
}
.nav-logo:hover img {
  transform: scale(1.05);
}

.nav-menu {
  display: flex;
  gap: clamp(20px, 3vw, 40px);
  list-style: none;
  margin-left: auto;
}
.nav-link {
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
  font-size: 15px;
  position: relative;
  padding: 6px 0;
  transition: color 0.3s var(--ease);
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  border-radius: 2px;
  background: var(--grad-brand);
  transition: width 0.3s var(--ease);
}
.nav-link:hover,
.nav-link.active {
  color: var(--accent);
}
.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.theme-toggle {
  width: 42px;
  height: 42px;
  border: 1px solid var(--border-strong);
  background: var(--bg-elev);
  color: var(--text);
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s var(--ease);
}
.theme-toggle:hover {
  color: var(--accent);
  border-color: var(--accent);
  transform: translateY(-2px);
}
.theme-toggle .icon-moon {
  display: none;
}
[data-theme='dark'] .theme-toggle .icon-sun {
  display: none;
}
[data-theme='dark'] .theme-toggle .icon-moon {
  display: block;
}

.nav-cta {
  padding: 11px 26px;
  background: var(--accent-solid);
  color: var(--accent-contrast);
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  white-space: nowrap;
  transition: all 0.3s var(--ease);
  box-shadow: var(--shadow-brand);
}
.nav-cta:hover {
  background: var(--brand-strong);
  transform: translateY(-2px);
  box-shadow: 0 14px 34px -8px rgba(37, 99, 235, 0.55);
}

/* Бургер */
.nav-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  border: 1px solid var(--border-strong);
  background: var(--bg-elev);
  border-radius: var(--radius-sm);
  cursor: pointer;
  padding: 0 11px;
}
.nav-burger span {
  height: 2px;
  width: 100%;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s var(--ease), opacity 0.2s var(--ease);
}
body.menu-open .nav-burger span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
body.menu-open .nav-burger span:nth-child(2) {
  opacity: 0;
}
body.menu-open .nav-burger span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Мобильное меню */
.nav-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--z-overlay);
  background: rgba(8, 12, 24, 0.5);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
  opacity: 0;
  transition: opacity 0.3s var(--ease);
}
.nav-overlay:not([hidden]) {
  display: block;
}
body.menu-open .nav-overlay {
  opacity: 1;
}

.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  z-index: var(--z-menu);
  width: min(82vw, 340px);
  height: 100dvh;
  background: var(--bg-elev);
  border-left: 1px solid var(--border);
  box-shadow: var(--shadow-xl);
  padding: calc(var(--nav-h) + 24px) 28px 28px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  transform: translateX(105%);
  transition: transform 0.4s var(--ease-out);
}
body.menu-open .mobile-menu {
  transform: translateX(0);
}
.mobile-menu-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.mobile-link {
  display: block;
  padding: 14px 4px;
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--heading);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  transition: color 0.25s var(--ease), padding-left 0.25s var(--ease);
}
.mobile-link:hover {
  color: var(--accent);
  padding-left: 10px;
}
.btn.mobile-cta {
  margin-top: auto;
  width: 100%;
  justify-content: center;
  background: var(--accent-solid);
  color: var(--accent-contrast);
  box-shadow: var(--shadow-brand);
}
.btn.mobile-cta:hover {
  background: var(--brand-strong);
  transform: translateY(-2px);
}

/* ======================== ГЕРОЙ ================================ */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: #0b1120;
  color: #fff;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: radial-gradient(120% 120% at 80% 0%, #15224a 0%, #0b1120 55%);
}
.hero-grid {
  position: absolute;
  inset: -2px;
  background-image: linear-gradient(rgba(99, 142, 255, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(99, 142, 255, 0.08) 1px, transparent 1px);
  background-size: 54px 54px;
  -webkit-mask-image: radial-gradient(110% 90% at 50% 0%, #000 35%, transparent 80%);
  mask-image: radial-gradient(110% 90% at 50% 0%, #000 35%, transparent 80%);
}
.aurora {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.55;
  will-change: transform;
}
.aurora-1 {
  width: 520px;
  height: 520px;
  top: -120px;
  right: -80px;
  background: radial-gradient(circle, #3b82f6, transparent 65%);
  animation: float-1 16s ease-in-out infinite;
}
.aurora-2 {
  width: 460px;
  height: 460px;
  bottom: -140px;
  left: -60px;
  background: radial-gradient(circle, #8b5cf6, transparent 65%);
  animation: float-2 19s ease-in-out infinite;
}
.aurora-3 {
  width: 360px;
  height: 360px;
  top: 40%;
  left: 45%;
  background: radial-gradient(circle, #22d3ee, transparent 65%);
  opacity: 0.35;
  animation: float-3 22s ease-in-out infinite;
}
.hero-noise {
  position: absolute;
  inset: 0;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

@keyframes float-1 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-40px, 50px) scale(1.12); }
}
@keyframes float-2 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(50px, -40px) scale(1.15); }
}
@keyframes float-3 {
  0%, 100% { transform: translate(-50%, -50%) scale(1); }
  50% { transform: translate(-35%, -60%) scale(1.2); }
}

.hero-content {
  position: relative;
  z-index: 3;
  max-width: var(--maxw);
  width: 100%;
  margin: 0 auto;
  padding: calc(var(--nav-h) + 40px) clamp(20px, 4vw, 40px) 40px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 18px;
  background: rgba(255, 255, 255, 0.08);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 28px;
  opacity: 0;
  animation: fadeInUp 0.8s var(--ease-out) forwards 0.15s;
}
.hero-badge-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.7);
  animation: pulse-dot 2s infinite;
}
@keyframes pulse-dot {
  0% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.6); }
  70% { box-shadow: 0 0 0 8px rgba(74, 222, 128, 0); }
  100% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0); }
}

.hero-title {
  font-size: clamp(2.6rem, 6.5vw, 5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.08;
  margin-bottom: 26px;
  opacity: 0;
  animation: fadeInUp 0.8s var(--ease-out) forwards 0.3s;
}
.gradient-text {
  background: linear-gradient(120deg, #60a5fa 0%, #a78bfa 50%, #22d3ee 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: shimmer 6s linear infinite;
}
@keyframes shimmer {
  to { background-position: 200% center; }
}

.hero-description {
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  max-width: 680px;
  margin-bottom: 38px;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.82);
  opacity: 0;
  animation: fadeInUp 0.8s var(--ease-out) forwards 0.45s;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  opacity: 0;
  animation: fadeInUp 0.8s var(--ease-out) forwards 0.6s;
}

/* Кнопки */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 30px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 16px;
  text-decoration: none;
  cursor: pointer;
  border: 2px solid transparent;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease),
    background 0.3s var(--ease), border-color 0.3s var(--ease);
}
.btn-primary {
  background: #fff;
  color: #0f172a;
  box-shadow: 0 10px 30px -8px rgba(255, 255, 255, 0.4);
}
.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 40px -10px rgba(255, 255, 255, 0.5);
}
.btn-primary svg {
  transition: transform 0.3s var(--ease);
}
.btn-primary:hover svg {
  transform: translateX(5px);
}
.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.3);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.6);
  transform: translateY(-3px);
}

.scroll-hint {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
  opacity: 0;
  animation: fadeIn 0.8s ease forwards 1.1s;
}
.scroll-hint span {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: 500;
}
.mouse-icon {
  width: 24px;
  height: 38px;
  border: 2px solid rgba(255, 255, 255, 0.5);
  border-radius: 12px;
  position: relative;
}
.mouse-icon::before {
  content: '';
  position: absolute;
  top: 7px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  height: 8px;
  background: #fff;
  border-radius: 2px;
  animation: scroll-dot 2s infinite;
}
@keyframes scroll-dot {
  0%, 100% { transform: translate(-50%, 0); opacity: 1; }
  50% { transform: translate(-50%, 12px); opacity: 0; }
}

/* ======================= СЕКЦИИ =============================== */
section {
  padding: clamp(64px, 9vw, 110px) 0;
}

.section-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto clamp(40px, 6vw, 64px);
}
.section-label {
  display: inline-block;
  padding: 7px 18px;
  background: var(--surface-soft);
  color: var(--accent);
  border-radius: var(--radius-pill);
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 18px;
}
.section-title {
  font-size: clamp(2rem, 4.2vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--heading);
  line-height: 1.18;
}

/* Преимущества */
.advantages {
  background: var(--bg-subtle);
}
.advantages-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: clamp(18px, 2.5vw, 28px);
}
.advantage-card {
  position: relative;
  background: var(--bg-elev);
  padding: clamp(28px, 3vw, 38px);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease),
    border-color 0.35s var(--ease);
  overflow: hidden;
}
.advantage-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--grad-brand);
  opacity: 0;
  transition: opacity 0.35s var(--ease);
  z-index: 0;
  mix-blend-mode: normal;
}
.advantage-card > * {
  position: relative;
  z-index: 1;
}
.advantage-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: transparent;
}
.advantage-icon {
  width: 60px;
  height: 60px;
  background: var(--grad-soft);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 22px;
  transition: transform 0.35s var(--ease);
}
.advantage-card:hover .advantage-icon {
  transform: scale(1.08) rotate(-4deg);
}
.advantage-icon svg {
  width: 30px;
  height: 30px;
  stroke: var(--accent);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}
.advantage-card h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--heading);
  margin-bottom: 10px;
}
.advantage-card p {
  color: var(--text-muted);
  line-height: 1.7;
}

/* Услуги (аккордеон) */
.services {
  background: var(--bg);
}
.services-list {
  max-width: 900px;
  margin: 0 auto;
}
.service-item {
  background: var(--bg-subtle);
  border-radius: var(--radius);
  margin-bottom: 16px;
  border: 1px solid var(--border);
  overflow: hidden;
  transition: box-shadow 0.4s var(--ease), border-color 0.4s var(--ease),
    background 0.4s var(--ease);
}
.service-item:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--border-strong);
}
.service-item.active {
  background: var(--bg-elev);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent);
}
.service-header {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: clamp(20px, 3vw, 28px) clamp(20px, 3vw, 32px);
  cursor: pointer;
}
.service-number {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 800;
  background: var(--grad-brand);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  min-width: 48px;
  flex-shrink: 0;
  transition: transform 0.4s var(--ease);
}
.service-item.active .service-number {
  transform: scale(1.12);
}
.service-content {
  flex: 1;
}
.service-content h3 {
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  font-weight: 700;
  color: var(--heading);
  transition: color 0.3s var(--ease);
}
.service-item:hover .service-content h3,
.service-item.active .service-content h3 {
  color: var(--accent);
}
.service-toggle {
  background: var(--surface-soft);
  border: none;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.4s var(--ease), transform 0.4s var(--ease);
}
.service-toggle:hover {
  transform: scale(1.06);
}
.service-toggle svg {
  stroke: var(--accent);
  transition: stroke 0.4s var(--ease);
}
.service-item.active .service-toggle {
  background: var(--accent-solid);
  transform: rotate(135deg);
}
.service-item.active .service-toggle svg {
  stroke: #fff;
}

.service-details {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.55s var(--ease);
}
.service-details-inner {
  padding: 0 clamp(20px, 3vw, 32px) clamp(20px, 3vw, 32px);
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity 0.4s var(--ease) 0.1s, transform 0.4s var(--ease) 0.1s;
}
.service-item.active .service-details-inner {
  opacity: 1;
  transform: translateY(0);
}
.service-details ul {
  list-style: none;
}
.service-details li {
  padding: 12px 0 12px 30px;
  position: relative;
  color: var(--text-muted);
  line-height: 1.7;
  border-top: 1px solid var(--border);
  transition: color 0.3s var(--ease), padding-left 0.3s var(--ease);
}
.service-details li:first-child {
  border-top: none;
}
.service-details li::before {
  content: '';
  position: absolute;
  left: 4px;
  top: 20px;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--grad-brand);
  transition: transform 0.3s var(--ease);
}
.service-details li:hover {
  color: var(--text);
  padding-left: 36px;
}
.service-details li:hover::before {
  transform: scale(1.3) rotate(45deg);
}

/* Сертификаты */
.certificates {
  background: var(--bg-subtle);
}
.certificates-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(20px, 3vw, 36px);
  max-width: 1100px;
  margin: 0 auto;
}
.certificate-card {
  background: var(--bg-elev);
  padding: clamp(28px, 4vw, 48px);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}
.certificate-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 5px;
  background: var(--grad-brand);
}
.certificate-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-xl);
}
.certificate-badge {
  display: inline-block;
  padding: 7px 18px;
  background: var(--grad-soft);
  color: var(--accent);
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 22px;
}
.certificate-card h3 {
  font-size: clamp(1.35rem, 2.4vw, 1.75rem);
  font-weight: 700;
  color: var(--heading);
  margin-bottom: 12px;
}
.certificate-org {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 26px;
  font-weight: 500;
  line-height: 1.6;
}
.certificate-info {
  background: var(--bg-subtle);
  padding: 22px;
  border-radius: var(--radius-sm);
  margin-bottom: 22px;
  border: 1px solid var(--border);
}
.info-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 14px;
}
.info-item:last-child {
  margin-bottom: 0;
}
.info-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}
.info-value {
  font-size: 1.02rem;
  color: var(--heading);
  font-weight: 700;
}
.certificate-desc {
  color: var(--text-muted);
  line-height: 1.7;
}
.certificate-list {
  list-style: none;
  margin-top: 10px;
}
.certificate-list li {
  position: relative;
  padding-left: 20px;
  margin-bottom: 7px;
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.5;
}
.certificate-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 9px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

/* Контакты */
.contacts {
  background: var(--bg);
}
.contacts-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: clamp(32px, 5vw, 60px);
  align-items: start;
}
.contact-info {
  display: flex;
  flex-direction: column;
  gap: 26px;
}
.contact-item {
  display: flex;
  gap: 18px;
}
.contact-icon {
  width: 54px;
  height: 54px;
  background: var(--grad-soft);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.contact-icon svg {
  width: 26px;
  height: 26px;
  stroke: var(--accent);
  stroke-width: 2;
  fill: none;
}
.contact-item h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--heading);
  margin-bottom: 6px;
}
.contact-item p {
  color: var(--text-muted);
  line-height: 1.7;
}
.contact-item a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.3s var(--ease);
}
.contact-item a:hover {
  color: var(--brand-strong);
  text-decoration: underline;
}
.contact-details {
  background: var(--bg-subtle);
  padding: 22px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}
.contact-details h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--heading);
  margin-bottom: 10px;
}
.contact-details p {
  color: var(--text-muted);
  line-height: 1.8;
  font-size: 0.9rem;
}
.contact-map {
  height: clamp(380px, 60vh, 600px);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}
.contact-map:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}
.contact-map iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

/* Футер */
.footer {
  background: #0b1120;
  color: rgba(255, 255, 255, 0.75);
  padding: clamp(48px, 6vw, 64px) 0 30px;
}
.footer-content {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1.2fr;
  gap: clamp(32px, 5vw, 60px);
  margin-bottom: 40px;
}
.footer-logo {
  height: 38px;
  width: auto;
  margin-bottom: 16px;
  filter: brightness(0) invert(1);
}
.footer-brand p {
  max-width: 320px;
  color: rgba(255, 255, 255, 0.6);
}
.footer-links h4,
.footer-contact h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 18px;
}
.footer-links ul {
  list-style: none;
}
.footer-links li {
  margin-bottom: 11px;
}
.footer-links a,
.footer-contact a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 0.3s var(--ease);
}
.footer-links a:hover,
.footer-contact a:hover {
  color: #fff;
}
.footer-contact p {
  margin-bottom: 11px;
}
.footer-bottom {
  padding-top: 28px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.9rem;
}

/* Кнопка наверх */
.scroll-top {
  position: fixed;
  right: clamp(16px, 3vw, 40px);
  bottom: clamp(16px, 3vw, 40px);
  width: 52px;
  height: 52px;
  background: var(--accent-solid);
  border: none;
  border-radius: 50%;
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-brand);
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px) scale(0.9);
  transition: all 0.3s var(--ease);
  z-index: 990;
}
.scroll-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}
.scroll-top:hover {
  background: var(--brand-strong);
  transform: translateY(-4px);
}
.scroll-top svg {
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Анимации появления */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===================== 5. АДАПТИВНОСТЬ ========================= */
@media (max-width: 1024px) {
  .contacts-grid {
    grid-template-columns: 1fr;
  }
  .footer-content {
    grid-template-columns: 1fr 1fr;
  }
  .footer-brand {
    grid-column: 1 / -1;
  }
}

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

@media (max-width: 768px) {
  .nav-menu,
  .nav-cta {
    display: none;
  }
  .nav-burger {
    display: flex;
  }
  .footer-content {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

@media (max-width: 480px) {
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .btn {
    justify-content: center;
  }
  .theme-toggle {
    width: 40px;
    height: 40px;
  }
}

/* ================= 6. УВАЖЕНИЕ К НАСТРОЙКАМ =================== */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .hero-badge,
  .hero-title,
  .hero-description,
  .hero-actions,
  .scroll-hint {
    opacity: 1;
    animation: none;
  }
  .aurora {
    animation: none;
  }
}

/* =================================================================
   7. ДОПОЛНЕНИЯ: кнопка-заливка и страница 404
   ================================================================= */

.btn.btn-form {
  background: var(--accent-solid);
  color: #fff;
  justify-content: center;
  box-shadow: var(--shadow-brand);
}
.btn.btn-form:hover {
  background: var(--brand-strong);
  transform: translateY(-2px);
}
/* Страница 404 */
.notfound {
  text-align: center;
  padding: calc(var(--nav-h) + 60px) 0 100px;
  background: var(--bg);
}
.notfound-code {
  font-size: clamp(5rem, 18vw, 11rem);
  font-weight: 900;
  line-height: 1;
  background: var(--grad-brand);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.notfound h1 {
  font-size: clamp(1.5rem, 4vw, 2.2rem);
  color: var(--heading);
  margin: 10px 0 14px;
}
.notfound p {
  color: var(--text-muted);
  max-width: 520px;
  margin: 0 auto 28px;
}
.notfound .hero-actions {
  justify-content: center;
  opacity: 1;
  animation: none;
}

