/* styles.css */

/* === BASE RESET === */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #222;
  background: #fff;
}

/* === HEADER & MOBILE MENU & MODAL === */
.menu-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.3);
  z-index: 999;
}
.menu-backdrop.active {
  display: block;
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}

.site-header {
  background: #fff;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.site-header .container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 20px;
}


/* Логотип ТОЛЬКО в шапке */
.site-header .logo img {
  max-height: 50px;  /* чуть больше для читаемости */
  width: auto;       /* сохраняем пропорции */
  display: block;    /* отключаем возможные inline-сдвиги */
}


/* Ссылки */
.site-header .logo-link,
.site-header .nav-list a,
.site-header .callback-btn {
  text-decoration: none !important;
}

/* Бургер */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 32px;
  height: 24px;
  background: none;
  border: none;
  cursor: pointer;
  position: relative;    /* чтобы быть над меню */
  z-index: 1100;         /* выше, чем у #mobileMenu (1000) */
}

.menu-toggle span {
  display: block;
  height: 4px;
  background: #0077cc;
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}
/* более крупный и чёткий крестик */
.menu-toggle.open span:nth-child(1) {
  transform: rotate(45deg) translate(8px, 8px);
}
.menu-toggle.open span:nth-child(2) {
  opacity: 0;
}
.menu-toggle.open span:nth-child(3) {
  transform: rotate(-45deg) translate(8px, -8px);
}

/* Desktop menu wrapper https://spravku-vbasseyn.com/ */
#mobileMenu {
  display: flex;
  align-items: center;
  gap: 20px;
}

/* Основная навигация */
.main-nav .nav-list {
  display: flex;
  list-style: none;
  gap: 20px;
  /* сдвигаем в сторону логотипа на 2 см */
  margin-left: -2cm;
}
.main-nav .nav-list a {
  font-size: 1rem;
  color: #0077cc;
}

/* Скрытая ссылка «версия для слабовидящих» */
.visually-hidden-desktop {
  display: none;
}

/* Контакты */
/* контейнер «телефон + часы» — ширина по телефону */
.contact-info {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  /* ширина автоматически под телефон */
}
.phone {
  text-decoration: none;
  cursor: pointer;
  font-size: 1rem;
  color: #0077cc;
}
.working-hours {
  font-size: 0.9rem;
  color: #666;
  margin-top: 4px;        /* отступ для ровности */
}
.phone {
  font-size: 1rem;
  color: #0077cc;
  text-decoration: none;     /* убираем подчеркивание */
  cursor: pointer;           /* остаётся кликабельным */

}
.working-hours {
  font-size: 0.9rem;
  color: #666;
}

/* Кнопка «Заказать звонок» */
.callback-btn {
  display: inline-block;
  padding: 8px 16px;
  border-radius: 4px;
  font-size: 1rem;
  cursor: pointer;
  background-color: #0077cc;
  color: #fff;
  border: none;

}

/* Модальное окно */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  align-items: center;
  justify-content: center;
  z-index: 1000;
}
.modal:target {
  display: flex;
}
.modal-content {
  background: #fff;
  padding: 20px;
  border-radius: 8px;
  width: 90%;
  max-width: 400px;
  position: relative;
}
.modal-close,
.modal .close {
  position: absolute;
  top: 10px; right: 10px;
  font-size: 1.5rem;
  text-decoration: none;
  color: #000;
}
.callback-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.callback-form label,
.callback-form input,
.callback-form button {
  font-size: 1rem;
}
.callback-form input {
  padding: 8px;
  border: 1px solid #ccc;
  border-radius: 4px;
}
.callback-form button {
  background: #0077cc;
  color: #fff;
  border: none;
  padding: 10px;
  border-radius: 4px;
  cursor: pointer;
}

/* === HERO === */
.hero {
  position: relative;
  height: 80vh;
  background: url('hero-bg.jpg') center/cover no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.4);
}
.hero-content {
  position: relative;
  color: white;
  z-index: 1;
}
.hero h1 {
  font-size: 32px;
  margin-bottom: 10px;
}
.hero p {
  font-size: 18px;
  margin-bottom: 20px;
}
.cta-btn {
  background: #28a745;
  color: white;
  padding: 12px 20px;
  text-decoration: none;
  border-radius: 6px;
  display: inline-block;
}

/* === PRICES === */
.prices {
  padding: 60px 0;
  background: #f0f0f0;
}
.prices h2 {
  margin-bottom: 20px;
  text-align: center; /* выравнивание по центру */
}
.price-table {
  width: 100%;
  border-collapse: collapse;
}
.price-table th,
.price-table td {
  border: 1px solid #ccc;
  padding: 12px;
  text-align: center;
  background: white;
}

/* === VALIDITY === */
.validity {
  padding: 40px 0;
  background: #fff;
  text-align: center;
}
.validity h3 {
  margin-bottom: 10px;
}

/* === ORDER spravku-vbasseyn.com === */
.order {
  padding: 60px 0;
  background: #f9f9f9;
}
.order-flex {
  display: flex;
  gap: 30px;
  align-items: flex-start;
}
.order-image img {
  max-width: 100%;
  border: 1px solid #ddd;
  cursor: zoom-in;
}
.order-form form {
  display: flex;
  flex-direction: column;
  gap: 15px;
}
/* Поля Для взрослых/Для детей над inputs и рядом в ряду */
.quantity-block {
  margin-bottom: 20px;
}
.dual-input {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  width: 100%;
}
.dual-input > div {
  flex: 1;
  display: flex;
  flex-direction: column;
}
/* Поля текст, селекты, textarea */
.order-form input,
.order-form select,
.order-form textarea {
  padding: 10px;
  font-size: 16px;
  border: 1px solid #ccc;
  border-radius: 4px;
}
.order-form textarea {
  height: 120px; /* увеличено в 2 раза */
}
.order-form button {
  background: #0077cc;
  color: white;
  border: none;
  padding: 12px;
  font-size: 16px;
  cursor: pointer;
  border-radius: 6px;
}
.form-title {
  margin-bottom: 24px;
  font-size: 24px;
  text-align: left;
}
select,
.metro-select {
  width: 100%;
  padding: 10px;
  margin: 12px 0;
  border-radius: 4px;
  border: 1px solid #ccc;
  background-color: #fff;
  color: #000;
  font-size: 15px;
}
select:focus {
  outline: 2px solid #0077cc;
  background-color: #f5f5f5;
}
select option {
  background: #fff;
  color: #000;
}

/* === TEXT SECTIONS === */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;
}
.text-section {
  margin: 50px 0;
}
.text-block {
  padding: 36px 24px;
  border-radius: 12px;
  margin-bottom: 32px;
}
.bg-light {
  background: #fff;
  color: #222;
}
.bg-dark {
  background: #f4f7fa;
  color: #191c21;
}
.text-block h2,
.text-block h3 {
  margin-bottom: 18px;
  font-weight: 700;
}
.text-content {
  position: relative;
  transition: max-height 0.6s cubic-bezier(.4,0,.2,1);
  overflow: hidden;
}
.show-text {
  display: block;
  overflow: hidden;
  max-height: 4.9em;
  transition: max-height 0.5s;
  position: relative;
}
.show-text.expanded {
  max-height: 2000px !important;
}

.show-text.expanded::after {
  display: none;             /* убираем градиентный «хвост» */
}


.show-text::after {
  content: '';
  display: block;
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 2.1em;
  background: linear-gradient(0deg, #fff 70%, transparent);
  pointer-events: none;
}
.bg-dark .show-text::after {
  background: linear-gradient(0deg, #f4f7fa 70%, transparent);
}
/* Кнопка без текстового узла — надпись рисуем через ::after,
   её не индексируют поисковики */
.toggle-text {
  margin-top: 8px;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 15px;
  font-weight: 600;
  position: relative;
  padding: 0;
  line-height: 1.2;
}

/* Видимая пользователю подпись */
.toggle-text::after {
  content: 'Читать далее';
  color: #0088cc;
  text-decoration: none;
}

/* Ховер-состояние */
.toggle-text:hover::after {
  color: #2aad2a;
  text-decoration: none;
}

/* Когда текст раскрыт — меняем подпись на «Скрыть» */
.toggle-text[aria-expanded="true"]::after {
  content: 'Скрыть';
}


/* === ANCHORS & OTHER DOCS === */
/* ЯКОРЯ — центрируем блок и ссылки */
.anchor-links { padding: 24px 0; }
.anchor-links .container {
  display: flex;
  justify-content: center;  /* по центру */
  align-items: center;
  gap: 16px;                /* расстояние между пунктами */
  flex-wrap: wrap;          /* красиво переносится на мобилках */
  text-align: center;
}
.anchor-links h3 {          /* убираем внешние отступы у h3 */
  margin: 0;
}
.anchor-links h3 a {
  display: inline-block;
  padding: 8px 14px;
  font-weight: 700;
  color: #0077cc;
  text-decoration: none;
  line-height: 1.2;
}
.anchor-links h3 a:hover { text-decoration: underline; }

/* Якорные ссылки в виде карточек */
.anchor-links--cards .container{
  display: grid;
  grid-template-columns: repeat(3, minmax(220px,1fr));
  gap: 16px;
  justify-items: center;
}
@media (max-width: 900px){
  .anchor-links--cards .container{ grid-template-columns: 1fr; }
}
.anchor-links--cards h3{ margin: 0; width: 100%; }
.anchor-links--cards h3 a{
  display: block;
  width: 100%;
  text-align: center;
  padding: 16px 18px;
  border-radius: 12px;
  background: #f5f9ff;
  border: 1px solid #dbe9ff;
  box-shadow: 0 1px 0 rgba(0,0,0,.04);
  color: #0a66c2;
  text-decoration: none;
  font-weight: 700;
}
.anchor-links--cards h3 a:hover{
  background: #e9f3ff;
}

.other-docs ul {
  list-style: none;
  padding-left: 0;
}
.other-docs li {
  margin: 5px 0;
}
.other-docs a {
  text-decoration: underline;
  color: #222;
}

/* === Other Docs: таблица и заголовок === */
.other-docs__title,
.other-docs h3,
.other-docs h4 {
  text-align: center;
  font-size: 1.5rem;   /* ~24px, можно поднять до 1.625rem если нужно крупнее */
  margin: 0 0 16px;
}



/* Ссылки внутри таблицы — аккуратные и кликабельные */
.other-docs .price-table.doc-table a {
  color: #0077cc;
  text-decoration: none;
}
.other-docs .price-table.doc-table a:hover {
  text-decoration: underline;
}
/* Используем стили таблицы цен, выравниваем текст посередине */
.other-docs .price-table.doc-table td,
.other-docs .price-table.doc-table th {
  text-align: center;
  padding: 12px 16px;
  vertical-align: middle;
}

/* (опционально) если где-то переопределяется, принудительно центрируем ссылки */
.other-docs .price-table.doc-table a {
  display: inline-block; /* чтобы надёжно центрировалось внутри td */
  text-align: center;
}

/* === FINAL CTA, MAP, FOOTER === */
.final-cta {
  padding: 40px 0;
  text-align: center;
  background: #e9ffe9;
}
/* Отступ сверху для Final CTA, чтобы отделить от предыдущего блока */
.final-cta {
  margin-top: 24px; /* можно 32px, если хочешь немного больше воздуха */
}

/* — Стиль текста внутри Final CTA http://spravku-vbasseyn.com — */
.final-cta p {
  font-weight: 700;       /* жирный */
  font-size: 1.5rem;
  line-height: 1.4;
  margin: 0 0 16px; /* чтобы был аккуратный отступ от кнопки */
}

.map {
  padding: 40px 0;
  text-align: center;
  background: #f0f0f0;
}
.map img {
  max-width: 100%;
  height: auto;
}
/* === FOOTER === */
.footer {
  padding: 30px 0;
  background: #333;
  color: white;
  text-align: center;
}
.footer a {
  color: #00c3ff;
  text-decoration: none;
  display: inline-block;
  margin-top: 10px;
}
.footer button {
  background: #00c3ff;
  color: white;
  border: none;
  padding: 10px 16px;
  border-radius: 4px;
  margin-top: 10px;
  cursor: pointer;
}
/* Лого в подвале — своя высота, чтобы не распирало шапку */
.footer .logo {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.footer .logo img.logo-img {
  display: block;
  height: 85px;   /* размер для ПК */
  width: auto;    /* сохраняем пропорции */
  max-width: none;
}

@media (max-width: 768px) {
  .footer .logo img.logo-img {
    height: 50px; /* отдельный размер для мобилы */
  }

}


/* === ADAPTIVE === */
@media (max-width: 768px) {
  .menu-toggle {
    display: flex;
  }
  .site-header .logo {
    order: 1;
  }
  #burger-menu {
    order: 2;
  }
  /* теперь меню выезжает сбоку */
 #mobileMenu {
  transform: translateX(100%); /* скрыто за правым краем */
  position: fixed;
  top: 0; right: 0; bottom: 0;
  width: 250px;
  display: flex;
  flex-direction: column;
  background: #fff;
  padding: 20px;
  box-shadow: -2px 0 4px rgba(0,0,0,0.1);
  transition: transform 0.3s ease;
  z-index: 1000;
}
#mobileMenu.open {
  transform: translateX(0);    /* выезжает на экран */
}

/* Моб. размер ЛОГОТИПА ТОЛЬКО В ШАПКЕ */
.site-header .logo img {
  height: 40px;
  width: auto;
}

/* Моб. размер ЛОГОТИПА В ФУТЕРЕ */
.footer .logo img.logo-img {
  height: 75px;   /* поставь нужное число */
  width: auto;
}
  .main-nav .nav-list {
    flex-direction: column;
    gap: 15px;
    margin-left: 0;
  }
  .visually-hidden-desktop {
    display: block;
    text-align: left;
    margin: 20px 0;
  }
  .contact-info {
    align-items: flex-start;
    margin: 20px 0;
  }
  .callback-btn {
    display: block;
    margin: 0;
  }
  .order-flex {
  flex-direction: column;    /* колонки вместо строки */
  align-items: center;       /* центрируем по горизонтали */
}
.order-image,
.order-form {
  width: 100%;               /* полная ширина, чтобы картинка не «давила» форму */
}
/* чтобы якорь не прятался под шапкой */
.text-block[id] { scroll-margin-top: 90px; }
}
@media (max-width: 600px) {
  .dual-input {
    flex-direction: column;
  }
}
