/* Общие стили */
body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  background: #e8f1f5;
  color: #333;
  scroll-behavior: smooth;
}

h1, h2, h3 {
  color: #1e3a8a;
  margin-top: 0;
}

section {
  padding: 80px 20px;
  max-width: 960px;
  margin: 0 auto;
}

/* ======= Видеофон: скорректированный порядок слоёв ======= */

/* 1) Убираем фон у родителя, чтобы не перекрывать видео */
.video-fullscreen {
  position: relative;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  /* background-color: #e8f1f5; */ /* ← этот фон лучше убрать */
}

/* 2) Само видео: положим его ниже затемнения, но выше фона body */
.video-fullscreen video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1; /* раньше было -2, заменили на -1 */
}

/* 3) Полупрозрачный чёрный слой поверх видео */
.video-fullscreen::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.35);
  z-index: 0; /* вместо -1, чтобы слой оказался над видео, но ниже текста */
}

/* 4) Контент (заголовок, кнопка и т. д.) поверх всего */
.video-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  color: #fff;
  animation: fadeIn 2s ease forwards;
  opacity: 0;
  z-index: 1; /* текст и кнопки теперь всегда над видео и затемнением */
}

/* 5) Если у вас есть отдельная подпись (video-disclaimer), она может идти ещё выше */
.video-disclaimer {
  position: absolute;
  bottom: 15px;
  right: 20px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.6);
  max-width: 250px;
  text-align: right;
  z-index: 2; /* поверх всего остального */
  font-style: italic;
}

/* Анимация появления */
@keyframes fadeIn {
  to {
    opacity: 1;
  }
}

.video-disclaimer {
  position: absolute;
  bottom: 15px;
  right: 20px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.6);
  max-width: 250px;
  text-align: right;
  z-index: 2;
  font-style: italic;
}

/* Кнопка "Узнать больше" */
.btn-scroll {
  display: inline-block;
  margin-top: 20px;
  padding: 12px 24px;
  background-color: #3b82f6;
  color: #fff;
  border-radius: 25px;
  text-decoration: none;
  transition: background-color 0.3s ease;
}

.btn-scroll:hover {
  background-color: #2563eb;
}

/* Навигация */
header {
  position: fixed;
  top: 0;
  width: 100%;
  background: #ffffffcc;
  backdrop-filter: blur(10px);
  z-index: 10;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

nav ul {
  list-style: none;
  display: flex;
  justify-content: center;
  margin: 0;
  padding: 10px 0;
}

nav ul li {
  margin: 0 15px;
}

nav ul li a {
  text-decoration: none;
  color: #1e3a8a;
  font-weight: 600;
}

nav ul li a:hover {
  color: #2563eb;
}

/* Кнопки и формы */
button,
input[type="submit"] {
  padding: 12px 20px;
  background-color: #3b82f6;
  color: #fff;
  border: none;
  border-radius: 25px;
  cursor: pointer;
  font-size: 16px;
  transition: background-color 0.3s ease;
}

button:hover,
input[type="submit"]:hover {
  background-color: #2563eb;
}

form {
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin-top: 20px;
}

input[type="text"],
input[type="tel"] {
  padding: 12px;
  width: 100%;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 16px;
  box-sizing: border-box;
  background: #fff;
}

#form-thankyou {
  margin-top: 20px;
  padding: 30px;
  background-color: #dbeafe;
  border: 1px solid #93c5fd;
  border-radius: 12px;
  text-align: center;
  color: #1e3a8a;
  font-weight: 600;
}

/* Таблицы */
table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.05);
}

th,
td {
  padding: 15px;
  border-bottom: 1px solid #e5e7eb;
  text-align: left;
}

th {
  background-color: #f0f9ff;
  color: #1e3a8a;
}

/* Аккордеон FAQ */
.accordion .item {
  margin-bottom: 10px;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  background: #fff;
  transition: box-shadow 0.3s ease;
}

.accordion .item.open {
  box-shadow: 0 0 6px rgba(59, 130, 246, 0.2);
}

.accordion h3 {
  margin: 0;
  padding: 15px;
  cursor: pointer;
  background: #f1f5f9;
  font-size: 16px;
}

.accordion .content {
  display: none;
  padding: 15px;
  background: #f9fafb;
  border-top: 1px solid #e5e7eb;
}

.accordion .item.open .content {
  display: block;
}

/* Footer legal links */
footer.legal {
  text-align: center;
  font-size: 13px;
  color: #6b7280;
  margin-top: 40px;
  padding-bottom: 20px;
}

/* Cookie consent banner */
#cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: #f1f5f9;
  padding: 15px 20px;
  display: flex;
  flex-wrap: wrap; /* разрешаем перенос строк */
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
  box-shadow: 0 -2px 5px rgba(0,0,0,0.05);
  z-index: 9999;
  box-sizing: border-box; /* учитываем padding в ширине */
}

#cookie-banner p {
  margin: 0;
  flex: 1 1 300px; /* адаптивная ширина текста */
  min-width: 200px;
}

#cookie-banner a {
  color: #2563eb;
  text-decoration: underline;
}

.cookie-actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
  margin-top: 10px;
}

.cookie-actions button {
  padding: 8px 16px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  background-color: #3b82f6;
  color: white;
  font-size: 14px;
  transition: background-color 0.2s ease;
}

.cookie-actions button:hover {
  background-color: #2563eb;
}

@media (max-width: 768px) {
  header nav ul {
    flex-direction: column;
    align-items: center;
  }

  .video-content h1 {
    font-size: 28px;
  }

  .video-content p {
    font-size: 16px;
  }

  section {
    padding: 60px 15px;
  }

  table, th, td {
    font-size: 14px;
  }

  .accordion h3 {
    font-size: 15px;
  }

  form {
    gap: 10px;
  }

  input[type="text"],
  input[type="tel"] {
    font-size: 15px;
  }

  .btn-scroll,
  button,
  input[type="submit"] {
    font-size: 15px;
    padding: 10px 18px;
  }

  #cookie-banner {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .cookie-actions {
    margin-top: 0;
  }
}
