/*
Theme Name: My Theme
Theme URI: 3dzipper.ru
Author: Dmitriy Glushkov
Description: первая версия сайта
Version: 1.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: mytheme
*/

/* Reset */
ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Кнопка "Новая версия сайта" */
.header__new-version {
  margin-top: 10px;
}

.btn--new-version {
  display: inline-block;
  padding: 8px 16px;
  background: #007bff;
  color: white;
  text-decoration: none;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.3s ease;
  border: 2px solid #007bff;
}

.btn--new-version:hover {
  background: #0056b3;
  border-color: #0056b3;
  color: white;
  text-decoration: none;
}

.btn--new-version:active {
  transform: translateY(1px);
}

* {
  scrollbar-width: 0.8rem;
  scrollbar-color: black !important;
}

/* --- OVERRIDE: Показываем стрелки Swiper на мобильных --- */
@media (max-width: 768px) {
  .swiper__nav--mod .swiper-button-next,
  .swiper__nav--mod .swiper-button-prev {
    display: flex !important;
  }
  .footer__nav-list {
    flex-wrap: wrap; /* Перенос на маленьких экранах */
    gap: 8px 15px; /* Разные отступы по осям */
  }
  .footer__nav-list a {
    font-size: 1.6rem; /* Уменьшение размера */
  }
  .footer__nav-list .separator {
    display: none; /* Скрыть разделители на мобильных */
  }

  /* Мобильные стили для кнопки "Новая версия сайта" */
  .header__new-version {
    margin-top: 8px;
    text-align: center;
  }

  .btn--new-version {
    padding: 10px 20px;
    font-size: 16px;
    width: 100%;
    max-width: 200px;
    text-align: center;
  }
}

@media (min-width: 1200px) {
  .footer__nav-list {
    gap: 25px; /* Увеличить отступы */
  }
}

.footer__navigation {
  padding: 20px 0;
  background: #f8f9fa;
  display: flex;
  justify-content: center;
  width: 100%;
  margin: 20px auto;
}

.footer__nav-list,
.footer__nav-list ul {
  /* Двойной селектор для повышения специфичности */
  display: flex;
  justify-content: center;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 15px;
}

.footer__nav-list a {
  color: #333;
  font-size: 2rem;
  text-decoration: none;
  transition: all 0.3s;
}

.footer__nav-list .separator {
  color: #999;
  user-select: none;
}

.footer__nav-list a:hover {
  color: #007bff; /* Цвет текста при наведении */
}

.footer__nav-list a.active {
  color: #0056b3;
  font-weight: 600;
}

.footer__nav-list {
  display: flex !important; /* Принудительно переопределяем ruby-text */
  flex-direction: row !important; /* Явно задаем направление */
}

/* Стили для навигации в футере */
.footer__navigation {
  margin: 20px 0;
  text-align: center;
}

.footer__nav-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer__nav-list li {
  margin: 0 15px;
  position: relative;
}

.footer__nav-list li:not(:last-child)::after {
  content: "|";
  position: absolute;
  right: -15px;
  top: 0;
  color: rgba(255, 255, 255, 0.5);
}

.footer__nav-list a {
  color: #fff;
  text-decoration: none;
  font-size: 16px;
  transition: color 0.3s ease;
}

.footer__nav-list a:hover {
  color: #e2c6ba;
  text-decoration: none;
}

@media (max-width: 768px) {
  .footer__nav-list {
    flex-direction: column;
  }

  .footer__nav-list li {
    margin: 5px 0;
  }

  .footer__nav-list li:not(:last-child)::after {
    display: none;
  }
}

/* Стили для хлебных крошек */
.breadcrumbs {
  padding: 10px 0;
  margin-bottom: 20px;
  font-size: 14px;
  color: #666;
  background-color: #f8f8f8;
  border-radius: 4px;
  padding-left: 15px;
}

.breadcrumbs a {
  color: #333;
  text-decoration: none;
  transition: color 0.3s ease;
}

.breadcrumbs a:hover {
  color: #e2c6ba;
  text-decoration: underline;
}

.breadcrumbs-separator {
  margin: 0 5px;
  color: #999;
}

/* Стили для 404-страницы */
.error-page {
  padding: 50px 0;
  text-align: center;
}

.error-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 30px;
  background-color: #f9f9f9;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.error-page h1 {
  font-size: 120px;
  margin: 0;
  color: #e2c6ba;
  line-height: 1;
}

.error-page h2 {
  font-size: 32px;
  margin-top: 0;
  margin-bottom: 20px;
  color: #333;
}

.error-page p {
  font-size: 18px;
  margin-bottom: 30px;
  color: #666;
}

.error-actions {
  margin-bottom: 30px;
}

.error-actions .btn {
  display: inline-block;
  padding: 12px 24px;
  background-color: #e2c6ba;
  color: #fff;
  text-decoration: none;
  border-radius: 4px;
  margin-bottom: 20px;
  transition: background-color 0.3s;
}

.error-actions .btn:hover {
  background-color: #d1b5a9;
}

.search-form-container {
  max-width: 500px;
  margin: 20px auto;
}

.search-form-container h3 {
  margin-bottom: 15px;
  font-size: 22px;
}

.popular-pages {
  margin-top: 30px;
  text-align: left;
}

.popular-pages h3 {
  font-size: 22px;
  margin-bottom: 15px;
}

.popular-pages ul {
  list-style: none;
  padding: 0;
}

.popular-pages li {
  margin-bottom: 10px;
}

.popular-pages a {
  color: #e2c6ba;
  text-decoration: none;
  font-size: 16px;
  transition: color 0.3s;
}

.popular-pages a:hover {
  color: #d1b5a9;
  text-decoration: underline;
}

/* Стили для меню футера */
.footer-menu {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  text-align: center;
  padding: 10px 0;
  width: 100%;
  background-color: #e2e6ea; /* Светло-серый фон как на скриншоте */
}

.footer-menu a {
  color: #333; /* Темный цвет для текста */
  text-decoration: none;
  font-size: 11.52px; /* Размер шрифта */
  transition: color 0.3s ease;
  margin: 0 5px;
  font-weight: normal;
}

.footer-menu a:hover {
  color: #0056b3; /* Синий цвет при наведении */
  text-decoration: underline;
}

.footer__navigation {
  display: flex;
  justify-content: center;
  width: 100%;
  margin: 0;
  background: transparent;
  padding: 0;
}

.container .footer__navigation {
  margin-bottom: 0;
  padding-bottom: 0;
}

@media (max-width: 768px) {
  .footer-menu {
    flex-direction: row; /* Сохраняем горизонтальную ориентацию */
  }

  .footer-menu a {
    margin: 5px;
  }
}

/* Стили для нового футера */
.footer-new {
  background-color: #f4f4f4;
  color: #333;
}

/* Раздел с картой */
.footer-map-section {
  margin: 20px 0;
  padding: 0 30px;
  box-sizing: border-box;
}

.footer-map-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 auto;
  border-spacing: 15px;
}

.footer-map-table td {
  vertical-align: top;
  padding: 0 10px;
  width: 33.33%; /* Три равные колонки */
}

.map-cell {
  padding-right: 15px;
}

.info-cell {
  padding: 0 15px;
}

.contact-cell {
  padding-left: 15px;
}

.info-table,
.contact-table {
  width: 100%;
  border-collapse: collapse;
}

.info-table th,
.contact-table th {
  padding: 8px 5px 3px;
  text-align: left;
  font-size: 10px;
  font-weight: 700;
  color: #333;
  text-transform: uppercase;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.info-table td,
.contact-table td {
  padding: 5px;
  vertical-align: top;
}

.info-table p,
.contact-table p {
  margin: 2px 0;
  font-size: 10px;
  color: #666;
  line-height: 1.3;
}

.info-table a,
.contact-table a {
  color: #333;
  text-decoration: none;
  transition: color 0.3s;
  font-size: 10px;
}

.info-table a:hover,
.contact-table a:hover {
  color: #000;
  text-decoration: underline;
}

.messenger-icons {
  display: flex;
  gap: 8px;
  margin-top: 3px;
}

.messenger-icon {
  width: 24px;
  height: 24px;
}

/* Основной блок футера */
.footer-main {
  background-color: #333;
  color: #fff;
  padding: 30px 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
}

.footer-block {
  margin-bottom: 15px;
}

.footer-block h3 {
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 15px;
  color: #fff;
}

.company-info {
  margin-bottom: 15px;
}

.footer-logo {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
}

.footer-logo img {
  margin-right: 8px;
  max-width: 32px;
  height: auto;
}

.footer-logo span {
  font-size: 13px;
  font-weight: 600;
}

.company-info p {
  margin: 3px 0;
  color: #aaa;
  font-size: 11px;
}

.company-info a {
  color: #fff;
  text-decoration: none;
  font-size: 11px;
}

.company-info a:hover {
  text-decoration: underline;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 6px;
}

.footer-links a {
  color: #aaa;
  text-decoration: none;
  transition: color 0.3s;
  font-size: 11px;
}

.footer-links a:hover {
  color: #fff;
}

.news-list .news-item {
  margin-bottom: 10px;
}

.news-date {
  font-size: 10px;
  color: #aaa;
  margin-bottom: 3px;
}

.news-title {
  color: #aaa;
  text-decoration: none;
  transition: color 0.3s;
  display: block;
  line-height: 1.3;
  font-size: 11px;
}

.news-title:hover {
  color: #fff;
}

.subscribe-form {
  margin-top: 12px;
}

.form-row {
  margin-bottom: 10px;
}

.form-row:first-child {
  display: flex;
}

.subscribe-form input[type="email"] {
  flex: 1;
  padding: 6px 8px;
  border: none;
  background-color: #444;
  color: #fff;
  border-radius: 4px 0 0 4px;
  font-size: 11px;
}

.subscribe-form button {
  width: 30px;
  background-color: #666;
  border: none;
  color: #fff;
  font-size: 14px;
  cursor: pointer;
  border-radius: 0 4px 4px 0;
  transition: background-color 0.3s;
}

.subscribe-form button:hover {
  background-color: #888;
}

.checkbox-row {
  display: flex;
  align-items: flex-start;
  font-size: 10px;
  color: #aaa;
}

.checkbox-row input {
  margin-right: 5px;
  margin-top: 2px;
}

.checkbox-row a {
  color: #fff;
  text-decoration: none;
  font-size: 10px;
}

.checkbox-row a:hover {
  text-decoration: underline;
}

/* Нижняя часть футера */
.footer-bottom {
  background-color: #222;
  padding: 15px 0;
  font-size: 10px;
  color: #aaa;
  text-align: center;
}

.copyright {
  color: #777;
}

@media (max-width: 992px) {
  .footer-map-section {
    padding: 0 15px;
  }

  .footer-map-table,
  .footer-map-table tbody,
  .footer-map-table tr,
  .footer-map-table td {
    display: block;
    width: 100%;
  }

  .map-cell,
  .info-cell,
  .contact-cell {
    padding: 0;
    margin-bottom: 15px;
  }
}

@media (max-width: 768px) {
  /* Мобильные стили для header'а */
  .header__inner {
    flex-direction: column;
    text-align: center;
  }

  .header__logo {
    width: 100% !important;
    margin-bottom: 20px;
  }

  .header__data {
    width: 100%;
  }

  .header__data-content {
    flex-direction: column;
    align-items: center;
  }

  .header__social {
    margin-top: 15px;
  }

  .header__contacts {
    margin-top: 15px;
  }

  .footer-map-section {
    padding: 0 10px;
  }

  .info-table,
  .contact-table,
  .info-table tbody,
  .contact-table tbody,
  .info-table tr,
  .contact-table tr {
    display: block;
    width: 100%;
  }

  .info-table th,
  .info-table td,
  .contact-table th,
  .contact-table td {
    display: block;
    width: 100%;
    box-sizing: border-box;
  }

  .info-table th,
  .contact-table th {
    border-bottom: none;
    padding-bottom: 0;
  }

  .info-table td,
  .contact-table td {
    padding-top: 3px;
    margin-bottom: 10px;
  }

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

/* Стили для табличного футера */
.footer-table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  color: #fff;
}

.footer-table th {
  padding: 10px 8px;
  text-align: left;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-table td {
  padding: 10px 8px;
  vertical-align: top;
  border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-table td:last-child {
  border-right: none;
}

.footer-table ul.footer-links {
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-table .footer-links li {
  margin-bottom: 6px;
}

.footer-table .footer-links a {
  color: #aaa;
  text-decoration: none;
  transition: color 0.3s;
  font-size: 11px;
}

.footer-table .footer-links a:hover {
  color: #fff;
}

.footer-table .company-info p {
  margin: 3px 0;
  color: #aaa;
  font-size: 11px;
}

.footer-table .subscribe-form {
  margin-top: 12px;
}

@media (max-width: 992px) {
  .footer-table {
    display: block;
    overflow-x: auto;
  }
}

@media (max-width: 768px) {
  .footer-table,
  .footer-table thead,
  .footer-table tbody,
  .footer-table th,
  .footer-table td,
  .footer-table tr {
    display: block;
  }

  .footer-table th {
    position: absolute;
    top: -9999px;
    left: -9999px;
  }

  .footer-table td {
    position: relative;
    padding-left: 45%;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    min-height: auto;
    padding-top: 8px;
    padding-bottom: 8px;
  }

  .footer-table td:before {
    position: absolute;
    top: 10px;
    left: 8px;
    width: 40%;
    padding-right: 8px;
    white-space: nowrap;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 11px;
  }

  .footer-table td:nth-of-type(1):before {
    content: "О компании";
  }
  .footer-table td:nth-of-type(2):before {
    content: "Услуги";
  }
  .footer-table td:nth-of-type(3):before {
    content: "Информация";
  }
  .footer-table td:nth-of-type(4):before {
    content: "Новости";
  }
  .footer-table td:nth-of-type(5):before {
    content: "Покупателям";
  }
}

@media (max-width: 576px) {
  /* Стили для очень маленьких экранов */
  .header__mode {
    font-size: 14px;
    margin-bottom: 8px;
  }

  .btn--new-version {
    padding: 12px 24px;
    font-size: 18px;
    max-width: 250px;
  }

  .header__logo a {
    font-size: 18px;
  }

  .logo__img {
    width: 40px !important;
  }
  .footer-table td {
    padding-left: 8px;
    padding-top: 40px;
  }

  .footer-table td:before {
    top: 10px;
    left: 8px;
  }
}
