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

:root {
  --primary: #0f62fe;
  --primary-dark: #0043ce;
  --accent: #f1c21b;
  --dark: #161616;
  --gray: #525252;
  --light-gray: #f4f4f4;
  --white: #ffffff;
  --radius: 12px;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
  --shadow-hover: 0 8px 32px rgba(0, 0, 0, 0.12);
  --transition: 0.25s ease;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--dark);
  line-height: 1.6;
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
  text-decoration: none;
}

ul {
  list-style: none;
}

.container {
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 8px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
  text-align: center;
}

.btn-primary {
  background: var(--primary);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(15, 98, 254, 0.35);
}

.btn-outline {
  background: transparent;
  border-color: var(--white);
  color: var(--white);
}

.btn-outline:hover {
  background: var(--white);
  color: var(--dark);
}

.btn-large {
  padding: 18px 36px;
  font-size: 18px;
}

.btn-full {
  width: 100%;
}

/* ===== Header ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  transition: box-shadow var(--transition);
}

.header.scrolled {
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 20px;
  color: var(--dark);
}

.logo-icon {
  font-size: 24px;
}

.nav {
  display: flex;
  gap: 32px;
}

.nav a {
  font-size: 15px;
  font-weight: 500;
  color: var(--gray);
  transition: color var(--transition);
}

.nav a:hover {
  color: var(--primary);
}

.header-phone {
  font-weight: 600;
  font-size: 15px;
  color: var(--dark);
  transition: color var(--transition);
}

.header-phone:hover {
  color: var(--primary);
}

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

.burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--dark);
  border-radius: 2px;
  transition: var(--transition);
}

/* ===== Hero ===== */
.hero {
  padding: 140px 0 80px;
  background: linear-gradient(135deg, #0f62fe 0%, #0043ce 50%, #001d6c 100%);
  color: var(--white);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(241, 194, 27, 0.15) 0%, transparent 70%);
  pointer-events: none;
}

.hero-content {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 20px;
}

.hero-subtitle {
  font-size: 18px;
  opacity: 0.9;
  margin-bottom: 28px;
  max-width: 480px;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 32px;
}

.hero-contacts-mini {
  margin-top: 8px;
}

.hero-contacts-label {
  font-size: 14px;
  opacity: 0.85;
  margin-bottom: 8px;
}

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

.contact-link {
  font-weight: 600;
  font-size: 15px;
  border-bottom: 1px solid rgba(255,255,255,0.4);
  transition: border-color var(--transition);
}

.contact-link:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.hero-visual {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.hero-card {
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  padding: 24px 28px;
  text-align: left;
  transition: transform var(--transition), background var(--transition);
}

.hero-card-link {
  display: block;
  color: var(--white);
  cursor: pointer;
}

.hero-card-link:hover {
  transform: translateY(-4px);
  background: rgba(255, 255, 255, 0.2);
}

.hero-card-urgent {
  border-color: rgba(241, 194, 27, 0.5);
  background: rgba(241, 194, 27, 0.12);
}

.hero-card-icon {
  font-size: 32px;
  margin-bottom: 10px;
}

.hero-card-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 6px;
}

.hero-card-note {
  font-size: 14px;
  opacity: 0.9;
  line-height: 1.45;
}

.hero-stats {
  display: flex;
  gap: 40px;
  margin-top: 8px;
}

.stat {
  display: flex;
  flex-direction: column;
}

.stat-num {
  font-size: 28px;
  font-weight: 700;
  color: var(--accent);
}

.stat-label {
  font-size: 14px;
  opacity: 0.8;
}

/* ===== Advantages ===== */
.advantages-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.advantage {
  text-align: center;
  padding: 24px 16px;
}

.advantage-num {
  font-size: 32px;
  font-weight: 700;
  color: var(--primary);
  opacity: 0.3;
  margin-bottom: 12px;
}

.advantage h3 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 10px;
}

.advantage p {
  font-size: 14px;
  color: var(--gray);
  line-height: 1.55;
}

@media (max-width: 900px) {
  .advantages-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .hero-stats {
    justify-content: center;
  }
}

@media (max-width: 640px) {
  .advantages-grid {
    grid-template-columns: 1fr;
  }
  .hero-stats {
    gap: 24px;
  }
  .stat-num {
    font-size: 22px;
  }
}



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

.section-title {
  font-size: clamp(28px, 4vw, 36px);
  font-weight: 700;
  text-align: center;
  margin-bottom: 12px;
}

.section-subtitle {
  text-align: center;
  color: var(--gray);
  font-size: 17px;
  margin-bottom: 48px;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

/* ===== Services ===== */
.services {
  background: var(--light-gray);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  overflow: visible;
}

.service-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 28px 24px;
  box-shadow: var(--shadow);
  transition: transform var(--transition), box-shadow var(--transition);
  display: flex;
  flex-direction: column;
  overflow: visible;
  position: relative;
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
}

.service-icons-row {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.service-icons-row .svc-ico-img {
  width: 72px;
  height: 72px;
  padding: 6px;
  object-fit: contain;
  background: #f4f4f4;
  border-radius: 14px;
  border: 1px solid #e0e0e0;
  box-sizing: border-box;
}

.service-icons-row .svc-ico {
  width: 72px;
  height: 72px;
  padding: 12px;
  background: #f0f4ff;
  border-radius: 12px;
  border: 1px solid #e0e7ff;
  color: #0f62fe;
  box-sizing: border-box;
}

.service-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}


.service-icon {
  font-size: 36px;
  line-height: 1;
  flex-shrink: 0;
}


/* ===== Фото услуг ===== */
.service-photos {
  width: 100px;
  height: 75px;
  border-radius: 10px;
  flex-shrink: 0;
  position: relative;
  z-index: 2;
}

.service-photos-inner {
  width: 100px;
  height: 75px;
  border-radius: 10px;
  overflow: hidden;
  position: relative;
  background: #e8eaed;
  border: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.service-photos:hover .service-photos-inner {
  transform: scale(1.03);
  box-shadow: 0 4px 14px rgba(0,0,0,0.12);
}

.service-photos-inner .media-item,
.service-photos .media-item {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.45s ease;
  display: block;
}

.service-photos-inner .media-item.active,
.service-photos .media-item.active {
  opacity: 1;
}

.service-photos video.media-item {
  background: #111;
}

.photo-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: #b0b5be;
  background: #eef0f3;
}

/* Попап — крупный просмотр */
.service-photos-popup {
  position: absolute;
  right: 0;
  top: calc(100% + 12px);
  width: 320px;
  height: 240px;
  border-radius: 16px;
  overflow: hidden;
  background: #0d0d0d;
  box-shadow: 0 20px 50px rgba(0,0,0,0.35);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px) scale(0.94);
  transition: opacity 0.28s ease, transform 0.28s ease, visibility 0.28s;
  z-index: 200;
  pointer-events: none;
  border: 2px solid rgba(255,255,255,0.12);
}

.service-photos-popup img,
.service-photos-popup video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.45s ease;
}

.service-photos-popup img.active,
.service-photos-popup video.active {
  opacity: 1;
}

/* Точки-индикаторы */
.service-photos-dots {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 5;
}

.service-photos-dots span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255,255,255,0.4);
  transition: background 0.25s ease, transform 0.25s ease;
}

.service-photos-dots span.on {
  background: #fff;
  transform: scale(1.2);
}

.service-photos:hover .service-photos-popup,
.service-photos.is-expanded .service-photos-popup {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.service-card {
  position: relative;
  overflow: visible;
}

.services-grid {
  overflow: visible;
}

@media (max-width: 640px) {
  .service-photos-popup {
    width: min(280px, 85vw);
    height: 200px;
    right: auto;
    left: 50%;
    transform: translateX(-50%) translateY(12px) scale(0.94);
  }
  .service-photos:hover .service-photos-popup,
  .service-photos.is-expanded .service-photos-popup {
    transform: translateX(-50%) translateY(0) scale(1);
  }
}

.service-card h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px;
}

.service-card p {
  font-size: 14px;
  color: var(--gray);
  line-height: 1.5;
  flex-grow: 1;
  margin-bottom: 14px;
}

.service-price {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 16px;
  color: var(--primary);
  margin-top: auto;
}

/* Знак ! с подсказкой */
.price-info {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff3cd;
  color: #856404;
  font-size: 13px;
  font-weight: 700;
  cursor: help;
  position: relative;
  flex-shrink: 0;
  border: 1px solid #ffc107;
  vertical-align: middle;
}

/* Подсказка слева от знака — не уезжает за край таблицы */
.price-info:hover::after {
  content: attr(title);
  position: absolute;
  right: calc(100% + 12px);
  top: 50%;
  transform: translateY(-50%);
  background: var(--dark);
  color: var(--white);
  font-size: 12px;
  font-weight: 400;
  line-height: 1.45;
  padding: 10px 14px;
  border-radius: 8px;
  width: max-content;
  max-width: 280px;
  white-space: normal;
  z-index: 100;
  box-shadow: 0 8px 24px rgba(0,0,0,0.25);
  pointer-events: none;
  text-align: left;
}

.price-info:hover::before {
  content: '';
  position: absolute;
  right: calc(100% + 4px);
  top: 50%;
  transform: translateY(-50%);
  border: 6px solid transparent;
  border-left-color: var(--dark);
  z-index: 101;
}

.prices-table {
  overflow: visible;
}

.prices-table tbody tr {
  position: relative;
}

/* ===== Prices ===== */
.prices {
  background: var(--white);
  overflow: visible;
}

.prices-table-wrap {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: visible;
  max-width: 720px;
  margin: 0 auto;
}

.prices-table {
  width: 100%;
  border-collapse: collapse;
}

.prices-table th,
.prices-table td {
  padding: 18px 24px;
  text-align: left;
}

.prices-table th {
  background: var(--dark);
  color: var(--white);
  font-weight: 600;
  font-size: 15px;
}

.prices-table td {
  border-bottom: 1px solid #eee;
  font-size: 15px;
}

.prices-table tr:last-child td {
  border-bottom: none;
}

.prices-table td:last-child {
  font-weight: 600;
  color: var(--primary);
  white-space: nowrap;
}

.prices-table td:last-child .price-info {
  margin-left: 6px;
  vertical-align: middle;
}

.prices-table tbody tr:hover {
  background: #f8f9ff;
}

.prices-note {
  text-align: center;
  font-size: 13px;
  color: var(--gray);
  margin-top: 20px;
}

/* ===== CTA ===== */
.cta {
  background: linear-gradient(135deg, #0f62fe, #0043ce);
  color: var(--white);
  padding: 64px 0;
  text-align: center;
}

.cta h2 {
  font-size: clamp(24px, 3.5vw, 32px);
  margin-bottom: 12px;
}

.cta p {
  font-size: 17px;
  opacity: 0.9;
  margin-bottom: 28px;
}

.cta-contacts {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}

/* ===== Contacts ===== */
.contacts-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
  max-width: 900px;
  margin: 0 auto;
}

.contact-item {
  display: flex;
  gap: 16px;
  margin-bottom: 28px;
}

.contact-icon {
  font-size: 24px;
  flex-shrink: 0;
}

.contact-item strong {
  display: block;
  font-size: 14px;
  color: var(--gray);
  margin-bottom: 4px;
}

.contact-item a,
.contact-item span {
  font-size: 16px;
  font-weight: 500;
}

.contact-item a:hover {
  color: var(--primary);
}

.contact-form {
  background: var(--light-gray);
  border-radius: var(--radius);
  padding: 32px;
}

.contact-form h3 {
  font-size: 20px;
  margin-bottom: 24px;
}

.form-group {
  margin-bottom: 16px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 15px;
  font-family: inherit;
  transition: border-color var(--transition);
  background: var(--white);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(15, 98, 254, 0.15);
}

.form-group textarea {
  resize: vertical;
  min-height: 100px;
}

.form-hint {
  font-size: 13px;
  color: var(--gray);
  line-height: 1.45;
  margin-bottom: 16px;
}

.form-note {
  font-size: 12px;
  color: var(--gray);
  margin-top: 12px;
  text-align: center;
}

/* ===== Footer ===== */
.footer {
  background: var(--dark);
  color: rgba(255, 255, 255, 0.7);
  padding: 48px 0 36px;
  text-align: center;
}

.footer-logo {
  font-size: 18px;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 12px;
}

.footer p {
  font-size: 14px;
  margin-bottom: 6px;
}

.footer-guarantee {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,0.12);
  color: #9ca3af;
  font-weight: 400;
}

.footer-copy {
  margin-top: 12px;
  opacity: 0.5;
  font-size: 13px;
}

/* ===== Mobile ===== */
@media (max-width: 900px) {
  .hero-content {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-subtitle {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-buttons,
  .hero-contacts-links {
    justify-content: center;
  }

  .hero-visual {
    max-width: 400px;
    margin: 0 auto;
  }

  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .contacts-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

@media (max-width: 640px) {
  .nav,
  .header-phone {
    display: none;
  }

  .burger {
    display: flex;
  }

  .nav.active {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--white);
    padding: 24px;
    gap: 20px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    border-top: 1px solid #eee;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    padding: 120px 0 60px;
  }

  .section {
    padding: 60px 0;
  }

  .price-info:hover::after {
    right: auto;
    left: 50%;
    top: auto;
    bottom: calc(100% + 10px);
    transform: translateX(-50%);
    max-width: min(260px, 70vw);
  }
  .price-info:hover::before {
    right: auto;
    left: 50%;
    top: auto;
    bottom: calc(100% + 4px);
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: var(--dark);
    border-left-color: transparent;
  }
}


.messenger-btn {
  text-align: center;
  text-decoration: none;
}
.contact-form-links {
  display: flex;
  flex-direction: column;
}
