:root {
  --bg-dark: #08060f;
  --bg-card: rgba(18, 14, 28, 0.7);
  --bg-card-hover: rgba(32, 24, 52, 0.9);

  --accent-purple: #8b5cf6;
  --accent-purple-glow: rgba(139, 92, 246, 0.4);
  --accent-purple-hover: #7c3aed;
  --accent-green: #10b981;

  --text-main: #f3f3f7;
  --text-muted: #9490ad;
  --border-color: rgba(255, 255, 255, 0.08);

  --font-family: 'Inter', system-ui, -apple-system, sans-serif;
  --nav-height: 70px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ВКЛЮЧАЕМ ПОПРАНИЧНУЮ ПРИВЯЗКУ (SCROLL SNAP) */
html {
  background-color: var(--bg-dark);
  scroll-behavior: smooth;
  scroll-snap-type: y mandatory; /* Страницы магнитом притягиваются при скролле */
}

body {
  background-color: var(--bg-dark);
  color: var(--text-main);
  font-family: var(--font-family);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
}

/* ДИНАМИЧЕСКИЙ ФОН И CANVAS */
#bg-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 1;
  pointer-events: none;
}

/* Анимированная светящаяся сетка на фоне */
.page-bg-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image: 
    radial-gradient(circle at 50% 30%, rgba(139, 92, 246, 0.15) 0%, transparent 60%),
    linear-gradient(to right, rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 100% 100%, 50px 50px, 50px 50px;
  animation: bgPulse 8s ease-in-out infinite alternate;
}

@keyframes bgPulse {
  0% { opacity: 0.6; transform: scale(1); }
  100% { opacity: 1; transform: scale(1.02); }
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
}

/* НАВИГАЦИЯ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--nav-height);
  background-color: rgba(8, 6, 15, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
  z-index: 1000;
}

.nav-container {
  max-width: 1200px;
  height: 100%;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-size: 1.5rem;
  font-weight: 800;
  color: #fff;
  text-decoration: none;
  letter-spacing: 1px;
}

.logo span { color: var(--accent-purple); }

.nav-links { display: flex; gap: 30px; }
.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.2s;
  cursor: pointer;
}
.nav-links a:hover, .nav-links a.active { color: #fff; }

/* КНОПКА IP */
.btn-copy-ip {
  position: relative;
  overflow: hidden;
  user-select: none;
  background: rgba(139, 92, 246, 0.12);
  border: 1px solid rgba(139, 92, 246, 0.4);
  color: #fff;
  padding: 9px 20px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.88rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: all 0.25s ease;
  box-shadow: 0 0 15px rgba(139, 92, 246, 0.15);
}

.btn-copy-ip i {
  color: var(--accent-purple);
  transition: transform 0.3s ease, color 0.3s ease;
}

.btn-copy-ip:hover {
  background: rgba(139, 92, 246, 0.25);
  border-color: var(--accent-purple);
  transform: translateY(-2px);
  box-shadow: 0 0 22px rgba(139, 92, 246, 0.4);
}

.btn-copy-ip:active, .btn-primary:active {
  transform: scale(0.95) !important;
}

.btn-copy-ip.copied, .btn-primary.copied {
  background: rgba(16, 185, 129, 0.2) !important;
  border-color: var(--accent-green) !important;
  color: #a7f3d0 !important;
  box-shadow: 0 0 25px rgba(16, 185, 129, 0.4) !important;
}

.btn-copy-ip.copied i, .btn-primary.copied i {
  color: var(--accent-green) !important;
  transform: scale(1.25) rotate(360deg);
}

.ripple-wave {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  transform: scale(0);
  animation: rippleAnimation 0.6s linear;
  pointer-events: none;
}

@keyframes rippleAnimation {
  to {
    transform: scale(4);
    opacity: 0;
  }
}

/* КОНТЕЙНЕР СЕКЦИЙ И СТРАНИЦЫ (SCROLL SNAP ITEMS) */
.page-main {
  position: relative;
  width: 100%;
  z-index: 2;
}

.site-section {
  position: relative;
  height: 100vh; /* Каждый блок строго высотой в один экран */
  min-height: 650px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: calc(var(--nav-height) + 20px) 0 40px;
  overflow: hidden;

  /* Точка фиксации страницы при скролле */
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

/* СВЕТЯЩИЕСЯ ОРБЫ НА ФОНЕ */
.glow-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
  z-index: 0;
  animation: floatOrb 10s infinite alternate ease-in-out;
}

@keyframes floatOrb {
  0% { transform: scale(1) translate(0, 0); opacity: 0.4; }
  50% { transform: scale(1.2) translate(30px, -30px); opacity: 0.7; }
  100% { transform: scale(0.9) translate(-20px, 20px); opacity: 0.5; }
}

.orb-1 { width: 500px; height: 500px; background: rgba(139, 92, 246, 0.25); top: 10%; left: 50%; transform: translateX(-50%); }
.orb-2 { width: 450px; height: 450px; background: rgba(124, 58, 237, 0.2); bottom: 10%; right: 5%; }
.orb-3 { width: 400px; height: 400px; background: rgba(168, 85, 247, 0.18); top: 20%; left: 5%; }

/* ЗАГОЛОВКИ */
.section-header {
  margin-bottom: 25px;
  text-align: center;
  position: relative;
  z-index: 2;
}

.section-badge {
  display: inline-block;
  background: rgba(139, 92, 246, 0.12);
  border: 1px solid rgba(139, 92, 246, 0.3);
  color: #c4b5fd;
  padding: 4px 14px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 1px;
  margin-bottom: 8px;
  text-transform: uppercase;
}

.section-title {
  font-size: 2.2rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.5px;
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 0.92rem;
  margin-top: 4px;
}

/* HERO */
.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 800px;
}

.online-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(139, 92, 246, 0.1);
  border: 1px solid rgba(139, 92, 246, 0.25);
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  background-color: #10b981;
  border-radius: 50%;
  box-shadow: 0 0 10px #10b981;
}

.hero-title { font-size: 3.6rem; font-weight: 900; line-height: 1.1; margin-bottom: 16px; }
.hero-title span {
  background: linear-gradient(135deg, #c4b5fd 0%, var(--accent-purple) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle { color: var(--text-muted); font-size: 1.05rem; margin: 0 auto 28px; max-width: 600px; }
.hero-buttons { display: flex; gap: 15px; justify-content: center; }

.btn-primary, .btn-secondary {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 12px 26px; border-radius: 12px; font-size: 0.92rem; font-weight: 700;
  text-decoration: none; cursor: pointer; transition: all 0.25s ease;
  position: relative; overflow: hidden;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-purple) 0%, var(--accent-purple-hover) 100%);
  color: #fff; border: none; box-shadow: 0 4px 20px var(--accent-purple-glow);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 6px 25px rgba(139, 92, 246, 0.5); }

.btn-secondary {
  background-color: rgba(255, 255, 255, 0.05); color: var(--text-main); border: 1px solid var(--border-color);
}
.btn-secondary:hover { background-color: rgba(255, 255, 255, 0.1); border-color: rgba(255, 255, 255, 0.2); }

/* CARDS GRID */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  position: relative;
  z-index: 2;
}

.feature-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 24px;
  text-decoration: none;
  color: var(--text-main);
  backdrop-filter: blur(12px);
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
}

.feature-card:hover {
  background: var(--bg-card-hover);
  transform: translateY(-5px);
  border-color: rgba(139, 92, 246, 0.4);
  box-shadow: 0 12px 30px rgba(0,0,0,0.6), 0 0 15px rgba(139, 92, 246, 0.2);
}

.card-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }

.card-icon {
  width: 44px; height: 44px;
  background: rgba(139, 92, 246, 0.12);
  border: 1px solid rgba(139, 92, 246, 0.25);
  border-radius: 12px; display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; color: #c4b5fd; transition: 0.3s;
}

.feature-card:hover .card-icon { background: var(--accent-purple); color: #fff; }
.card-tag { font-size: 0.72rem; color: var(--text-muted); background: rgba(255, 255, 255, 0.05); padding: 3px 8px; border-radius: 10px; }

.feature-card h3 { font-size: 1.15rem; font-weight: 700; margin-bottom: 6px; color: #fff; }
.feature-card p { color: var(--text-muted); font-size: 0.88rem; margin-bottom: 20px; flex-grow: 1; }
.card-footer { display: flex; align-items: center; gap: 8px; font-size: 0.82rem; font-weight: 600; color: #c4b5fd; }

/* ГАЛЕРЕЯ */
.flex-header { display: flex; justify-content: space-between; align-items: flex-end; text-align: left; }

.bento-gallery-compact {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(2, 175px);
  gap: 16px;
  position: relative;
  z-index: 2;
}

.bento-item {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border-color);
  background: #110e1a;
}

.bento-item img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.bento-content {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(5, 4, 8, 0.95) 0%, rgba(5, 4, 8, 0.1) 60%, transparent 100%);
  padding: 16px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.bento-tag { font-size: 0.68rem; color: #c4b5fd; font-weight: 700; text-transform: uppercase; margin-bottom: 2px; }
.bento-content h4 { font-size: 1.05rem; font-weight: 700; color: #fff; }

.bento-item:hover img { transform: scale(1.08); }

/* АРХИВ / 1 СЕЗОН */
.season-banner {
  background: linear-gradient(135deg, rgba(20, 16, 32, 0.85) 0%, rgba(12, 9, 20, 0.95) 100%);
  border: 1px solid rgba(139, 92, 246, 0.25);
  border-radius: 24px;
  padding: 35px 40px;
  position: relative;
  z-index: 2;
  backdrop-filter: blur(12px);
}

.season-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 35px;
  align-items: center;
}

.season-info h2 { font-size: 2.1rem; font-weight: 900; margin: 8px 0 12px; }
.season-info p { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 22px; }

.season-features { display: flex; gap: 20px; margin-bottom: 25px; }
.s-feat-item { display: flex; align-items: center; gap: 10px; }
.s-feat-item i {
  font-size: 1.1rem; color: var(--accent-purple);
  background: rgba(139, 92, 246, 0.12); padding: 10px; border-radius: 10px;
}
.s-feat-item strong { display: block; font-size: 0.88rem; color: #fff; }
.s-feat-item span { font-size: 0.75rem; color: var(--text-muted); }

.season-btn-group { display: flex; gap: 12px; }

.visual-card {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border-color);
  height: 250px;
}

.visual-card img { width: 100%; height: 100%; object-fit: cover; }
.visual-overlay {
  position: absolute; bottom: 0; left: 0; right: 0; padding: 12px 16px;
  background: rgba(5, 4, 8, 0.85); backdrop-filter: blur(8px);
  display: flex; align-items: center; gap: 8px; font-size: 0.82rem; font-weight: 600; color: #fff;
}
.visual-overlay i { color: #f59e0b; }

/* ПОДВАЛ (СЕКЦИЯ С ФИКСАЦИЕЙ) */
.footer {
  height: auto;
  min-height: auto;
  padding: 30px 0;
  border-top: 1px solid var(--border-color);
  background: var(--bg-dark);
  position: relative;
  z-index: 10;
  scroll-snap-align: end;
}

.footer-container { max-width: 1200px; margin: 0 auto; padding: 0 24px; display: flex; justify-content: space-between; align-items: center; }
.disclaimer { display: flex; align-items: center; gap: 8px; font-size: 0.78rem; color: var(--text-muted); }
.footer-links a { color: var(--text-muted); text-decoration: none; font-size: 0.82rem; }

.toast {
  position: fixed; bottom: 25px; right: 25px; background: #161224; border: 1px solid var(--accent-purple);
  color: #fff; padding: 12px 20px; border-radius: 10px; display: flex; align-items: center; gap: 10px;
  font-size: 0.9rem; font-weight: 600; box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  opacity: 0; visibility: hidden; transform: translateY(20px); transition: all 0.3s ease; z-index: 2000;
}
.toast.show { opacity: 1; visibility: visible; transform: translateY(0); }

/* МЕДИАЗАПРОСЫ (На маленьких экранах отключаем snap, чтобы контент не резался) */
@media (max-width: 992px) {
  html { scroll-snap-type: none; }
  .site-section { height: auto; min-height: calc(100vh - var(--nav-height)); padding: 80px 0; }
  .cards-grid { grid-template-columns: repeat(2, 1fr); }
  .bento-gallery-compact { grid-template-columns: repeat(2, 1fr); grid-template-rows: auto; }
  .bento-item { height: 200px; }
  .season-grid { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .hero-title { font-size: 2.6rem; }
  .cards-grid, .bento-gallery-compact { grid-template-columns: 1fr; }
  .nav-links { display: none; }
}