/* === Variables === */
:root {
  --color-black: #0a0a0f;
  --color-dark: #0f172a;
  --color-dark-alt: #1e293b;
  --color-mid: #334155;
  --color-white: #ffffff;
  --color-ice: #f8fafc;
  --color-blue: #38bdf8;
  --color-blue-alt: #0ea5e9;
  --color-blue-deep: #0284c7;
  --gradient-main: linear-gradient(135deg, #38bdf8 0%, #0ea5e9 50%, #0284c7 100%);
  --gradient-text: linear-gradient(135deg, #38bdf8, #7dd3fc);
  --font-display: 'Playfair Display', serif;
  --font-body: 'Outfit', sans-serif;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --shadow-glow: 0 0 60px rgba(56, 189, 248, 0.15);
  --transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* === Reset & Base === */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-white);
  background: var(--color-black);
  overflow-x: hidden;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}

/* === Animated Background === */
.bg-grid {
  position: fixed;
  inset: 0;
  background-image: 
    linear-gradient(rgba(56, 189, 248, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(56, 189, 248, 0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
  z-index: -2;
}

.bg-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.4;
  pointer-events: none;
  z-index: -1;
}

.bg-glow-1 {
  width: 600px;
  height: 600px;
  background: var(--color-blue);
  top: -200px;
  right: -200px;
  animation: float 20s ease-in-out infinite;
}

.bg-glow-2 {
  width: 400px;
  height: 400px;
  background: var(--color-blue-deep);
  bottom: 20%;
  left: -100px;
  animation: float 25s ease-in-out infinite reverse;
}

.bg-glow-3 {
  width: 300px;
  height: 300px;
  background: var(--color-blue-alt);
  bottom: -100px;
  right: 20%;
  animation: float 18s ease-in-out infinite 2s;
}

@keyframes float {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(30px, -30px); }
}

/* === Layout === */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* === Header === */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 20px 0;
  transition: var(--transition);
}

.header.scrolled {
  background: rgba(10, 10, 15, 0.9);
  backdrop-filter: blur(20px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  text-decoration: none;
  color: var(--color-white);
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-right: 20%;
}

/* Анимация лого — один раз для нового пользователя */
.header-logo.logo-animate {
  animation: logoIntro 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.header-logo.logo-animate .logo-accent {
  animation: logoAccentReveal 1s cubic-bezier(0.16, 1, 0.3, 1) 0.15s both;
}

.header-logo.logo-seen,
.header-logo.logo-animate.ended {
  opacity: 1;
  transform: none;
}

@keyframes logoIntro {
  0% {
    opacity: 0;
    transform: scale(0.92) translateY(-6px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

@keyframes logoAccentReveal {
  0% {
    opacity: 0;
    transform: translateX(-8px);
  }
  100% {
    opacity: 1;
    transform: translateX(0);
  }
}

.logo-accent {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

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

.nav-link {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  font-weight: 500;
  transition: color var(--transition);
}

.nav-link:hover,
.nav-link.active {
  color: var(--color-blue);
}

.nav-cta {
  padding: 10px 20px !important;
  font-size: 0.95rem !important;
}

.burger {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.burger span {
  width: 24px;
  height: 2px;
  background: var(--color-white);
  transition: var(--transition);
}

/* === Buttons === */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 28px;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
  border: none;
}

.btn-primary {
  background: var(--gradient-main);
  color: var(--color-black);
  box-shadow: 0 4px 20px rgba(56, 189, 248, 0.35);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(56, 189, 248, 0.5);
}

.btn-outline {
  background: transparent;
  color: var(--color-blue);
  border: 2px solid var(--color-blue);
}

.btn-outline:hover {
  background: rgba(56, 189, 248, 0.1);
}

.admin-link {
  padding: 10px 20px;
  font-size: 0.95rem;
}
.admin-link--visible {
  display: inline-flex !important;
}

.btn-lg {
  padding: 18px 36px;
  font-size: 1.05rem;
}

.btn-full {
  width: 100%;
}

/* === Hero === */
.hero {
  min-height: 70vh;
  display: flex;
  align-items: center;
  padding: 90px 0 50px;
  position: relative;
}

.hero-inner {
  width: 100%;
}

.hero-badge {
  display: inline-block;
  padding: 8px 16px;
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: 100px;
  font-size: 0.9rem;
  color: var(--color-blue);
  margin-bottom: 32px;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 24px;
  letter-spacing: -0.02em;
}

.gradient-text {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.7);
  max-width: 520px;
  margin-bottom: 28px;
}

.hero-cta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-visual {
  position: absolute;
  top: 50%;
  right: 5%;
  transform: translateY(-50%);
}

.hero-card {
  width: 320px;
  background: linear-gradient(180deg, rgba(30, 41, 59, 0.8) 0%, rgba(15, 23, 42, 0.9) 100%);
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-glow);
  backdrop-filter: blur(10px);
}

.hero-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-mid);
}

.dot:first-child { background: #ef4444; }
.dot:nth-child(2) { background: #eab308; }
.dot:nth-child(3) { background: #22c55e; }

.hero-card-title {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.6);
}

.hero-card-body .stats-row {
  display: flex;
  gap: 24px;
  margin-bottom: 16px;
}

.stat {
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.8);
}

.stat strong {
  color: var(--color-blue);
}

.progress-bar {
  height: 6px;
  background: var(--color-dark-alt);
  border-radius: 100px;
  overflow: hidden;
}

.progress-fill {
  width: 75%;
  height: 100%;
  background: var(--gradient-main);
  border-radius: 100px;
  animation: progress 2s ease-out forwards;
}

@keyframes progress {
  from { width: 0; }
  to { width: 75%; }
}

/* === Animations === */
.animate-fade-up {
  opacity: 0;
  transform: translateY(30px);
  animation: fadeUp 0.8s ease-out forwards;
}

.animate-fade-up[data-delay="1"] { animation-delay: 0.1s; }
.animate-fade-up[data-delay="2"] { animation-delay: 0.2s; }
.animate-fade-up[data-delay="3"] { animation-delay: 0.3s; }

.animate-scale-in {
  opacity: 0;
  transform: scale(0.9);
  animation: scaleIn 1s ease-out 0.5s forwards;
}

@keyframes fadeUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scaleIn {
  to {
    opacity: 1;
    transform: scale(1);
  }
}

[data-animate] {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

[data-animate].visible {
  opacity: 1;
  transform: translateY(0);
}

/* === Sections === */
.section {
  padding: 50px 0;
}

.section-badge {
  display: inline-block;
  color: var(--color-blue);
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 12px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3.5vw, 2.5rem);
  font-weight: 700;
  margin-bottom: 28px;
}

/* === Services === */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}

.service-card {
  padding: 28px 24px;
  background: linear-gradient(180deg, rgba(30, 41, 59, 0.4) 0%, rgba(15, 23, 42, 0.6) 100%);
  border: 1px solid rgba(56, 189, 248, 0.15);
  border-radius: var(--radius-lg);
  transition: var(--transition);
}

.service-card:hover {
  border-color: rgba(56, 189, 248, 0.4);
  transform: translateY(-4px);
  box-shadow: var(--shadow-glow);
}

.service-icon {
  font-size: 2.5rem;
  font-weight: 800;
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 20px;
}

.service-card h3 {
  font-size: 1.25rem;
  margin-bottom: 12px;
}

.service-card p {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.95rem;
}

/* === CTA Section === */
.cta-box {
  padding: 36px 32px;
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.08) 0%, rgba(14, 165, 233, 0.04) 100%);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: var(--radius-xl);
  text-align: center;
}

.cta-box h2 {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3vw, 1.75rem);
  margin-bottom: 20px;
}

.cta-list {
  list-style: none;
  margin-bottom: 28px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

.cta-list li {
  padding: 16px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: var(--radius-md);
  color: rgba(255, 255, 255, 0.9);
}

/* === Reviews === */
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}

.review-card {
  padding: 24px;
  background: linear-gradient(180deg, rgba(30, 41, 59, 0.5) 0%, rgba(15, 23, 42, 0.7) 100%);
  border: 1px solid rgba(56, 189, 248, 0.12);
  border-radius: var(--radius-lg);
  transition: var(--transition);
}

.review-card:hover {
  border-color: rgba(56, 189, 248, 0.3);
}

.review-stars {
  color: #eab308;
  font-size: 1.1rem;
  margin-bottom: 16px;
}

.review-card p {
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 24px;
  font-style: italic;
}

.review-author {
  display: flex;
  align-items: center;
  gap: 16px;
}

.review-avatar {
  width: 48px;
  height: 48px;
  background: var(--gradient-main);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: var(--color-black);
}

.review-author strong {
  display: block;
}

.review-author span {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
}

/* === Order Form === */
.order-section {
  background: linear-gradient(180deg, transparent 0%, rgba(15, 23, 42, 0.5) 100%);
}

.order-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 36px;
  align-items: start;
  padding: 36px 32px;
  background: linear-gradient(180deg, rgba(30, 41, 59, 0.4) 0%, rgba(15, 23, 42, 0.6) 100%);
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-radius: var(--radius-xl);
}

.order-info h2 {
  font-family: var(--font-display);
  font-size: 2rem;
  margin-bottom: 16px;
}

.order-info p {
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 24px;
}

.order-contacts {
  list-style: none;
  -webkit-user-select: text;
  user-select: text;
}

.order-contacts li {
  color: var(--color-blue);
  margin-bottom: 8px;
}

.order-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.form-group label {
  display: block;
  font-weight: 500;
  margin-bottom: 8px;
  color: rgba(255, 255, 255, 0.9);
}

.form-group input,
.form-group textarea {
  -webkit-user-select: text;
  -moz-user-select: text;
  user-select: text;
  width: 100%;
  padding: 14px 18px;
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-radius: var(--radius-md);
  color: var(--color-white);
  font-family: var(--font-body);
  font-size: 1rem;
  transition: var(--transition);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--color-blue);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.2);
}

/* === Footer === */
.footer {
  padding: 28px 0;
  border-top: 1px solid rgba(56, 189, 248, 0.1);
  -webkit-user-select: text;
  user-select: text;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 24px;
}

.footer-domain {
  color: var(--color-blue);
  font-weight: 500;
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color var(--transition);
}

.footer-links a:hover {
  color: var(--color-blue);
}

/* === Templates Page === */
.templates-hero {
  padding: 100px 0 50px;
  text-align: center;
}

.templates-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  margin-bottom: 16px;
}

.templates-hero p {
  color: rgba(255, 255, 255, 0.7);
  max-width: 600px;
  margin: 0 auto 28px;
  font-size: 1rem;
}

.templates-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
  padding-bottom: 50px;
}

.template-card {
  background: linear-gradient(180deg, rgba(30, 41, 59, 0.5) 0%, rgba(15, 23, 42, 0.8) 100%);
  border: 1px solid rgba(56, 189, 248, 0.15);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: var(--transition);
}

.template-card:hover {
  transform: translateY(-8px);
  border-color: rgba(56, 189, 248, 0.4);
  box-shadow: var(--shadow-glow);
}

.template-preview {
  height: 180px;
  background: linear-gradient(135deg, var(--color-dark-alt) 0%, var(--color-dark) 100%);
  position: relative;
  overflow: hidden;
}

.template-preview::before {
  content: '';
  position: absolute;
  inset: 0;
  background: 
    linear-gradient(90deg, transparent 0%, rgba(56, 189, 248, 0.05) 50%, transparent 100%);
  animation: shimmer 2s infinite;
}

@keyframes shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

.template-preview-inner {
  width: 90%;
  height: 80%;
  background: rgba(15, 23, 42, 0.6);
  border-radius: 8px;
  border: 1px solid rgba(56, 189, 248, 0.2);
}

.template-preview-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.template-content {
  padding: 20px;
}

.template-content h3 {
  font-size: 1.25rem;
  margin-bottom: 8px;
}

.template-content p {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.9rem;
  margin-bottom: 20px;
}

.template-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.template-actions .btn {
  flex: 1;
  min-width: 120px;
}

/* === Responsive === */
@media (max-width: 1024px) {
  .hero-visual {
    position: static;
    transform: none;
    margin-top: 36px;
  }

  .order-inner {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .section { padding: 40px 0; }
  .section-title { margin-bottom: 22px; font-size: clamp(1.4rem, 5vw, 1.8rem); }
  .container { padding: 0 16px; }
  .header { padding: 14px 0; }
  .logo { font-size: 1.25rem; margin-right: 0; }
  .cta-box { padding: 28px 20px; }
  .templates-hero { padding: 80px 0 36px; }
  .templates-hero p { margin-bottom: 20px; }
  .templates-grid { grid-template-columns: 1fr; gap: 20px; padding-bottom: 40px; }
  .template-preview { height: 160px; }
  .template-content { padding: 16px; }
  .template-content h3 { font-size: 1.1rem; }
  .template-content p { font-size: 0.85rem; margin-bottom: 14px; }
  .template-actions .btn { min-width: 100%; }
  .services-grid { gap: 16px; }
  .service-card { padding: 20px 18px; }
  .review-card { padding: 20px; }
  .order-inner { padding: 28px 20px; gap: 28px; }
  .footer { padding: 24px 0; }
  .footer-inner { gap: 16px; }
  .footer-links { gap: 16px; }
}

@media (max-width: 480px) {
  .section { padding: 32px 0; }
  .section-badge { font-size: 0.8rem; margin-bottom: 10px; }
  .section-title { margin-bottom: 18px; font-size: 1.35rem; }
  .container { padding: 0 14px; }
  .header { padding: 12px 0; }
  .logo { font-size: 1.15rem; }
  .cta-box { padding: 24px 16px; }
  .cta-box h2 { margin-bottom: 16px; }
  .cta-list { margin-bottom: 20px; gap: 10px; }
  .cta-list li { padding: 12px; }
  .templates-hero { padding: 72px 0 28px; }
  .templates-hero h1 { font-size: 1.6rem; margin-bottom: 12px; }
  .templates-hero p { font-size: 0.95rem; margin-bottom: 18px; }
  .template-preview { height: 140px; }
  .template-content { padding: 14px; }
  .service-card { padding: 18px 16px; }
  .service-card h3 { font-size: 1.1rem; }
  .review-card { padding: 18px; }
  .review-card p { margin-bottom: 18px; }
  .review-avatar { width: 40px; height: 40px; font-size: 0.9rem; }
  .order-inner { padding: 24px 16px; }
  .order-info h2 { font-size: 1.4rem; }
  .form-group input, .form-group textarea { padding: 12px 14px; font-size: 16px; }
  .btn, .btn-lg { padding: 12px 20px; font-size: 0.95rem; }
  .hero { min-height: auto; padding: 70px 0 40px; }
  .hero-title { font-size: 1.5rem; margin-bottom: 16px; }
  .hero-subtitle { font-size: 1rem; margin-bottom: 20px; }
  .lp-banner { padding: 10px 14px; flex-wrap: wrap; gap: 10px; }
  .lp-banner .btn { padding: 8px 14px; font-size: 0.85rem; }
  .lp-logo-text, .lp-logo { font-size: 1.1rem; }
}

/* Mobile menu */
@media (max-width: 768px) {
  .header-inner {
    justify-content: space-between;
    width: 100%;
  }

  .header-inner .logo {
    margin-right: auto;
    order: 1;
  }

  .header-inner .burger {
    margin-left: auto;
    order: 2;
  }

  .nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    max-width: 320px;
    height: 100vh;
    background: var(--color-dark);
    flex-direction: column;
    padding: 100px 32px 32px;
    gap: 24px;
    transition: right var(--transition);
  }

  .nav.open {
    right: 0;
    display: flex;
  }

  .burger {
    display: flex;
    z-index: 101;
    transition: var(--transition);
  }

  .burger.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
  }

  .burger.active span:nth-child(2) {
    opacity: 0;
  }

  .burger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
  }

  .hero-title {
    font-size: 2.25rem;
  }

  .hero-cta {
    flex-direction: column;
  }

  .hero-cta .btn {
    width: 100%;
  }

  .cta-box {
    padding: 28px 20px;
  }

  .order-inner {
    padding: 28px 20px;
  }
}

/* Cookie consent — 152-ФЗ РФ */
.cookie-consent {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 20px 24px;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.98) 0%, rgba(10, 10, 15, 0.99) 100%);
  border-top: 1px solid rgba(56, 189, 248, 0.2);
  transform: translateY(100%);
  opacity: 0;
  transition: transform 0.4s ease, opacity 0.4s ease;
}

.cookie-consent--visible {
  transform: translateY(0);
  opacity: 1;
}

.cookie-consent--hidden {
  transform: translateY(100%);
  opacity: 0;
}

.cookie-consent__inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

.cookie-consent__text {
  flex: 1;
  min-width: 260px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.95rem;
  line-height: 1.5;
}

.cookie-consent__link {
  color: var(--color-blue);
  text-decoration: underline;
  -webkit-user-select: text;
  user-select: text;
}

.cookie-consent__actions {
  display: flex;
  gap: 12px;
}

.cookie-consent__btn {
  flex-shrink: 0;
}

@media (max-width: 600px) {
  .cookie-consent__inner {
    flex-direction: column;
    align-items: stretch;
  }

  .cookie-consent__actions {
    justify-content: flex-end;
  }
}
