:root {
  --neon-cyan: #00f0ff;
  --neon-pink: #ff0055;
  --belt-amber: #ffaa00;
  --bg-dark: #070b19;
  --card-bg: #111833;
  --card-border: rgba(0, 240, 255, 0.35);
  --text-light: #f1f5f9;
  --text-dim: #94a3b8;
  --header-bg: rgba(7, 11, 25, 0.95);
  --ladder-rail: #475569;
  --window-bg: rgba(14, 23, 56, 0.65);
}

body.light-theme {
  --bg-dark: #f1f5f9;
  --card-bg: #ffffff;
  --card-border: rgba(2, 132, 199, 0.4);
  --text-light: #0f172a;
  --text-dim: #334155;
  --header-bg: rgba(255, 255, 255, 0.96);
  --ladder-rail: #64748b;
  --window-bg: #ffffff;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--bg-dark);
  color: var(--text-light);
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
  transition: background-color 0.3s, color 0.3s;
}

/* ШАПКА */
.header-nav {
  position: sticky;
  top: 0;
  z-index: 10000 !important;
  background: var(--header-bg);
  backdrop-filter: blur(15px);
  border-bottom: 1px solid rgba(0, 240, 255, 0.2);
  padding: 10px 24px;
}

.nav-wrap {
  max-width: 1350px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
}

.brand-logo-link {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.logo-mascot-svg {
  width: 44px;
  height: 44px;
  filter: drop-shadow(0 0 8px rgba(0, 240, 255, 0.7));
}

.brand-text-block { display: flex; flex-direction: column; }
.brand-title {
  font-size: 1.45rem;
  font-weight: 900;
  color: var(--text-light);
  text-shadow: 0 0 12px var(--neon-cyan);
  letter-spacing: 1px;
}

body.light-theme .brand-title { color: #0369a1; text-shadow: none; }
.brand-subtitle { font-size: 0.68rem; color: var(--belt-amber); font-weight: 700; text-transform: uppercase; }

.nav-tabs { display: flex; list-style: none; gap: 8px; }
.nav-tab-btn {
  display: flex; align-items: center; gap: 7px;
  color: var(--text-dim); text-decoration: none;
  font-size: 0.9rem; font-weight: 600; padding: 8px 14px;
  border-radius: 6px; transition: all 0.25s; border: 1px solid transparent;
}
.nav-tab-btn:hover, .nav-tab-btn.active {
  color: var(--text-light); background: rgba(0, 240, 255, 0.12); border-color: rgba(0, 240, 255, 0.4);
}

.header-right { display: flex; align-items: center; gap: 12px; }
.theme-switch-btn {
  background: rgba(255, 255, 255, 0.08); border: 1px solid var(--neon-cyan);
  color: var(--text-light); width: 38px; height: 38px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; cursor: pointer;
}
.secure-phone-wrap { display: flex; flex-direction: column; align-items: flex-end; }
.secure-phone-canvas { cursor: pointer; user-select: none; }
.schedule-label { font-size: 0.7rem; color: var(--text-dim); }
.tg-pill {
  display: inline-flex; align-items: center; background: #229ed9;
  color: #fff; padding: 8px 16px; border-radius: 20px; text-decoration: none;
  font-weight: bold; font-size: 0.85rem; box-shadow: 0 0 12px rgba(34, 158, 217, 0.5);
}

/* ЛЕСТНИЦА И МОНТАЖНИК */
.ladder-system {
  position: fixed !important;
  right: 25px;
  top: 72px;
  bottom: 0;
  width: 52px;
  z-index: 8000;
  pointer-events: none;
}

.ladder-rails-3d {
  position: absolute; top: 0; bottom: 0; left: 0; right: 0;
  border-left: 5px solid var(--ladder-rail);
  border-right: 5px solid var(--ladder-rail);
  box-shadow: inset 2px 0 6px rgba(0, 0, 0, 0.7), inset -2px 0 6px rgba(0, 0, 0, 0.7);
  background-image: repeating-linear-gradient(
    0deg, var(--ladder-rail), var(--ladder-rail) 4px, transparent 4px, transparent 36px
  );
}

.climber-rig {
  position: absolute; left: -19px; width: 90px; height: 110px; top: 0;
  transform: translateY(100vh); will-change: transform; pointer-events: auto; cursor: pointer;
}

.climber-svg { filter: drop-shadow(0 0 10px rgba(0, 240, 255, 0.5)); }

.climber-quick-popup {
  position: absolute; right: 85px; top: -20px; width: 270px;
  background: var(--header-bg); border: 2px solid var(--neon-pink);
  border-radius: 12px; padding: 16px; box-shadow: 0 10px 30px rgba(255, 0, 85, 0.4);
  z-index: 99999; display: none;
}
.climber-quick-popup.active { display: block; }
.popup-close-btn {
  position: absolute; top: 8px; right: 10px; background: none; border: none;
  color: var(--text-dim); font-size: 16px; cursor: pointer;
}

/* СЕКЦИИ САЙТА */
.page-block-frame {
  max-width: 1300px;
  margin: 40px auto;
  padding: 0 20px;
  position: relative;
  z-index: 10;
}

.page-embed-window {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
  background: var(--window-bg);
  backdrop-filter: blur(10px);
}

/* ===================================================
   ГОРИЗОНТАЛЬНЫЕ ДОРОЖКИ С НЕПРЕРЫВНЫМ АВТОДВИЖЕНИЕМ
   =================================================== */
.h-marquee-container {
  position: relative;
  width: 100%;
  overflow: hidden;
  padding: 20px 0;
  cursor: grab;
}

.h-marquee-track {
  display: flex;
  gap: 25px;
  width: max-content;
  will-change: transform;
}

/* 1. Движение СЛЕВА НАПРАВО (RTL / Left-to-Right) */
.move-rtl {
  animation: marqueeRTL 45s linear infinite;
}

/* 2. Движение СПРАВА НАЛЕВО (LTR / Right-to-Left) */
.move-ltr {
  animation: marqueeLTR 45s linear infinite;
}

/* Пауза при наведении мыши или удержании пальцем */
.h-marquee-container:hover .h-marquee-track,
.h-marquee-container:active .h-marquee-track {
  animation-play-state: paused;
}

@keyframes marqueeLTR {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

@keyframes marqueeRTL {
  0% { transform: translateX(-50%); }
  100% { transform: translateX(0); }
}

/* КАРТОЧКА В ГОРИЗОНТАЛЬНОЙ ДОРОЖКЕ */
.h-flow-card {
  flex: 0 0 340px;
  max-width: 340px;
  cursor: pointer;
  transition: transform 0.25s, box-shadow 0.25s;
}

.h-flow-card:hover {
  transform: translateY(-8px) scale(1.03);
}

/* 1. ПЛАШКИ ЦЕН */
.price-tier-card {
  background: linear-gradient(145deg, #131c38, #182347) !important;
  border: 1px solid rgba(0, 240, 255, 0.4) !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4) !important;
  border-radius: 14px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 220px;
}

body.light-theme .price-tier-card {
  background: linear-gradient(145deg, #ffffff, #f0f7ff) !important;
  border: 1px solid rgba(2, 132, 199, 0.3) !important;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08) !important;
}

.tier-title { font-size: 1.25rem; color: #ffffff; margin-bottom: 8px; }
body.light-theme .tier-title { color: #0f172a; }
.tier-desc { font-size: 0.92rem; color: var(--text-dim); line-height: 1.45; }

.tier-price-box {
  margin-top: 18px;
  padding: 10px 14px;
  border-radius: 8px;
  background: rgba(7, 11, 25, 0.85);
  border: 1px solid rgba(0, 240, 255, 0.3);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

body.light-theme .tier-price-box { background: #e0f2fe; border-color: rgba(2, 132, 199, 0.4); }
.price-caption { font-size: 0.8rem; color: var(--text-dim); }
.price-value-badge {
  font-size: 1.25rem; font-weight: 900; color: var(--neon-cyan);
}
body.light-theme .price-value-badge { color: #0369a1; }

/* 2. СТИКЕРЫ НА ЛИПУЧКЕ */
.sticky-flow-card {
  flex: 0 0 160px;
  max-width: 160px;
}

.sticky-note-card {
  position: relative;
  width: 100%;
  min-height: 150px;
  background: #fef08a;
  color: #1e293b;
  border-radius: 2px 2px 14px 2px;
  padding: 22px 10px 14px 10px;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.35);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.sticker-tilt-1 { transform: rotate(-2deg); background: #fef08a; }
.sticker-tilt-2 { transform: rotate(1.8deg); background: #fed7aa; }
.sticker-tilt-3 { transform: rotate(-1.5deg); background: #e0f2fe; }
.sticker-tilt-4 { transform: rotate(2deg); background: #dcfce7; }

.sticky-tape {
  position: absolute; top: -8px; left: 50%; transform: translateX(-50%);
  width: 55px; height: 16px; background: rgba(255, 255, 255, 0.65);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.sticker-logo-img { width: 100%; height: 50px; object-fit: contain; margin-bottom: 8px; }
.sticker-brand-name { font-size: 0.9rem; font-weight: 800; color: #0f172a; line-height: 1.2; word-break: break-word; }

/* 3. ТЕТРАДНЫЕ ЛИСТЫ ОТЗЫВОВ */
.notebook-flow-card {
  flex: 0 0 380px;
  max-width: 380px;
}

.notebook-sheet-page {
  position: relative;
  background: #ffffff;
  background-image: 
    linear-gradient(rgba(186, 215, 242, 0.5) 1px, transparent 1px),
    linear-gradient(90deg, rgba(186, 215, 242, 0.5) 1px, transparent 1px);
  background-size: 20px 20px;
  border: 1px solid #cbd5e1;
  border-radius: 0 0 8px 8px;
  padding: 28px 20px 20px 42px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.35);
  min-height: 200px;
}

.torn-paper-top {
  position: absolute; top: 0; left: 0; right: 0; height: 10px;
  background: var(--bg-dark);
  mask-image: radial-gradient(circle at 10px 0, transparent 6px, #000 7px);
  mask-size: 20px 12px; mask-repeat: repeat-x;
}

.notebook-red-margin {
  position: absolute; top: 0; bottom: 0; left: 34px; width: 2px;
  background: #ef4444; opacity: 0.7;
}

.notebook-client-sign {
  font-family: 'Caveat', cursive; font-size: 1.45rem; font-weight: 700; color: #1e3a8a; margin-bottom: 6px;
}

.notebook-handwritten-text {
  font-family: 'Caveat', cursive; font-size: 1.4rem; line-height: 1.35; color: #1e40af;
}

.notebook-sheet-seal {
  margin-top: 10px; font-family: monospace; font-size: 0.75rem; color: #059669;
}

/* 4. КЕЙСЫ (ПОРТФОЛИО) */
.case-flow-card {
  flex: 0 0 380px;
  max-width: 380px;
}

.seo-case-box {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  padding: 22px;
  border-radius: 14px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

body.light-theme .seo-case-box { background: #ffffff !important; border-color: #cbd5e1 !important; }
.case-card-title { color: var(--neon-cyan); margin: 6px 0; font-size: 1.15rem; }
body.light-theme .case-card-title { color: #0369a1 !important; }
.case-label-task { color: #ffffff; font-size: 0.85rem; }
body.light-theme .case-label-task { color: #0f172a !important; }
.case-label-res { color: var(--belt-amber); font-size: 0.85rem; }
body.light-theme .case-label-res { color: #b45309 !important; }
.case-text-body { color: var(--text-dim); font-size: 0.9rem; line-height: 1.5; margin-top: 2px; }
body.light-theme .case-text-body { color: #334155 !important; }

/* ШТОРКА ДО/ПОСЛЕ В КЕЙСАХ */
.ba-slider-container {
  position: relative; width: 100%; height: 220px;
  overflow: hidden; border-radius: 10px; margin-bottom: 12px;
  user-select: none; background: #050814;
}

.ba-img { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; }
.ba-after-layer { z-index: 1; }
.ba-before-layer { z-index: 2; position: absolute; top: 0; left: 0; bottom: 0; width: 100%; overflow: hidden; clip-path: inset(0 100% 0 0); }
.ba-handle {
  position: absolute; top: 0; bottom: 0; left: 0%; width: 4px;
  background: #00f0ff; box-shadow: 0 0 12px #00f0ff; z-index: 5;
  cursor: ew-resize; transform: translateX(-50%); display: flex; align-items: center; justify-content: center;
}
.ba-handle-circle {
  width: 75px; height: 30px; background: #00f0ff; border: 2px solid #fff;
  border-radius: 15px; display: flex; align-items: center; justify-content: center;
  color: #000; font-weight: 900; font-size: 9px;
}
.ba-badge { position: absolute; top: 10px; padding: 4px 10px; border-radius: 4px; font-size: 0.75rem; font-weight: 900; z-index: 4; }
.ba-badge-before { left: 10px; background: rgba(255, 0, 85, 0.9); color: #fff; }
.ba-badge-after { right: 10px; background: rgba(0, 240, 255, 0.9); color: #000; }

/* ===================================================
   ПОЛНОРАЗМЕРНОЕ МОДАЛЬНОЕ ОКНО ZOOM ПОВЕРХ ЛЕСТНИЦЫ
   =================================================== */
.full-zoom-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(4, 6, 15, 0.94);
  backdrop-filter: blur(14px);
  z-index: 100000 !important; /* ПОВЕРХ ЛЕСТНИЦЫ И МОНТАЖНИКА */
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.full-zoom-content {
  position: relative;
  width: 100%;
  max-width: 850px;
  max-height: 90vh;
  overflow-y: auto;
  background: var(--card-bg);
  border: 2px solid var(--neon-cyan);
  border-radius: 18px;
  padding: 35px 25px;
  box-shadow: 0 0 50px rgba(0, 240, 255, 0.5);
  animation: zoomPop 0.25s ease-out;
}

@keyframes zoomPop {
  from { opacity: 0; transform: scale(0.9); }
  to { opacity: 1; transform: scale(1); }
}

.zoom-close-btn {
  position: absolute;
  top: 14px; right: 16px;
  background: var(--neon-pink);
  color: #fff;
  border: none;
  width: 36px; height: 36px;
  border-radius: 50%;
  font-size: 20px;
  font-weight: bold;
  cursor: pointer;
  box-shadow: 0 0 12px var(--neon-pink);
}

/* ДРУГИЕ БЛОКИ */
.block-neon, .block-contra, .block-beltlight, .block-lightbox { padding: 45px 30px; }
.neon-hero-title { font-size: 2.8rem; font-weight: 900; text-shadow: 0 0 20px var(--neon-pink); margin-bottom: 15px; line-height: 1.15; }
body.light-theme .neon-hero-title { text-shadow: none; color: #0284c7; }

.cards-3d-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; margin-top: 30px; }
.card-3d { background: var(--card-bg); border: 1px solid var(--card-border); padding: 24px; border-radius: 14px; }

.lightbox-frame-glow { max-width: 680px; margin: 0 auto; border-radius: 20px; padding: 4px; background: linear-gradient(135deg, var(--neon-cyan), transparent 40%, var(--neon-pink)); box-shadow: 0 0 45px rgba(0, 240, 255, 0.35); }
.lightbox-acrylic-front { background: var(--window-bg); border-radius: 18px; padding: 35px 25px; }
.neon-input { width: 100%; padding: 14px; margin: 8px 0; border-radius: 8px; background: rgba(0, 0, 0, 0.2); border: 1px solid #334155; color: var(--text-light); }
body.light-theme .neon-input { background: #f8fafc; color: #0f172a; }
.btn-ignite { width: 100%; padding: 16px; border-radius: 8px; background: linear-gradient(90deg, var(--neon-pink), #ff00aa); color: #fff; font-weight: bold; font-size: 1.1rem; border: none; cursor: pointer; box-shadow: 0 0 20px var(--neon-pink); }

.modal-overlay { position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(4, 6, 15, 0.88); backdrop-filter: blur(10px); z-index: 20000; display: none; align-items: center; justify-content: center; padding: 20px; }
.modal-content { background: var(--bg-dark); border: 1px solid var(--neon-cyan); border-radius: 16px; max-width: 750px; max-height: 85vh; overflow-y: auto; padding: 35px; }
footer { text-align: center; padding: 40px 20px; border-top: 1px solid rgba(255, 255, 255, 0.08); font-size: 0.9rem; color: var(--text-dim); }

/* МОБИЛЬНАЯ АДАПТАЦИЯ */
@media (max-width: 900px) {
  .nav-tabs { display: none; }
  .ladder-system { width: 38px; right: 4px; top: 65px; opacity: 0.85; }
  .climber-rig { left: -26px; transform: scale(0.65); }
  .neon-hero-title { font-size: 1.85rem; }
  .page-block-frame { padding: 0 8px; margin: 25px auto; }
  .block-neon, .block-contra, .block-beltlight, .block-lightbox { padding: 30px 14px; }
  .h-flow-card { flex: 0 0 280px; max-width: 280px; }
  .case-flow-card, .notebook-flow-card { flex: 0 0 300px; max-width: 300px; }
  .full-zoom-content { padding: 25px 15px; }
}