/* === Базовые сбросы и настройки === */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  height: 100%;
}

/* Пуленепробиваемый макет страницы с помощью CSS Grid */
body {
  font-family: 'Roboto', sans-serif;
  font-weight: 300;
  font-size: 1.1rem;
  letter-spacing: 0.01em;
  background-color: #000;
  color: #fff;
  max-width: 100%;
  height: 100vh;
  height: 100dvh; 
  display: grid; 
  grid-template-rows: auto 1fr auto; /* Шапка, Основной контент (гибкий), Футер */
  overflow: hidden; /* ГАРАНТИРУЕМ ОТСУТСТВИЕ СКРОЛЛА НА BODY */
}

/* === Общий контейнер === */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
  width: 100%;
}

/* === Хедер === */
.site-header {
  background-color: #000;
  width: 100%;
  padding: 0 0.8rem;
  z-index: 10;
  position: relative;
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.8rem 0;
  height: 3.2rem;
}

.logo-group {
  display: flex;
  align-items: center;
}

.logo {
  height: 2rem;
  margin-right: 0.625rem;
}

.site-title {
  font-family: 'Oxanium', sans-serif;
  font-weight: 500;
  font-size: 1.55rem;
  letter-spacing: -0.025em;
  text-decoration: none;
  color: #fff;
  padding-top: 0.05rem;
  display: inline-block;
  font-display: optional; 
}

/* === Навигация === */
.main-nav {
  display: flex;
  align-items: center;
}

.nav-links {
  display: flex;
  gap: 1.5rem;
  list-style: none;
  font-family: 'Roboto', sans-serif;
  font-weight: 300;
  font-size: 1.1rem;
  letter-spacing: 0.02em;
}

.nav-links a {
  color: #fff;
  text-decoration: none;
  position: relative;
}

.nav-links a:hover,
.nav-links a:focus,
.nav-links a.active {
  border-bottom: 2px solid #fff;
}

.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 20px;
  height: 15px;
  background: none;
  border: none;
  cursor: pointer;
}

.hamburger span {
  display: block;
  height: 2px;
  background: #fff;
}

/* === Основной контент === */
main {
  min-height: 0; 
  display: flex;
  flex-direction: column;
}

/* === Футер === */
.site-footer {
  width: 100%;
  background-color: #000;
  height: 1.2rem;
  z-index: 5;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.3rem 1rem;
  font-family: 'Roboto', sans-serif;
  font-weight: 300;
  font-size: 0.8rem;
  font-size-adjust: cap-height 0.5;
  height: 100%;
}

.footer-right a {
  color: #fff;
  text-decoration: none;
  font-size: 0.8rem;
}

/* === Стили для плавной загрузки изображений === */
.lazy-image {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.4s ease-in-out, transform 0.4s ease-in-out;
}

.lazy-image.loaded {
  opacity: 1;
  transform: translateY(0);
}


/* === СТИЛИ ДЛЯ КОНКРЕТНЫХ СТРАНИЦ === */
.hero-section {
  height: 100%; width: 100%; overflow: hidden;
}
.hero-image {
  width: 100%; height: 100%; object-fit: cover; object-position: center;
}
.affiliates-content {
  display: flex; flex-direction: row; flex: 1; min-height: 0; overflow: hidden;
}
.affiliates-left, .affiliates-right, .contact-right {
  flex: 1; overflow: hidden;
}
.affiliates-left img {
  width: 100%; height: 100%; object-fit: cover; object-position: center;
}
/* --- ВОССТАНОВЛЕНО: Оригинальный стиль заголовка --- */
.right-column-title {
  font-family: 'Oxanium', sans-serif; 
  font-size: 1.8rem; 
  color: #fff; 
  margin-bottom: 1rem; 
  letter-spacing: -0.025em; 
  flex-shrink: 0; 
  font-weight: 400; 
  text-align: left;
}

.page-ordernow .affiliates-right {
  display: flex;
  flex-direction: column;
  padding: 1.5rem 1.5rem 0; 
}

/* === ИСПРАВЛЕННЫЕ СТИЛИ ДЛЯ КНОПОК УСЛУГ === */
.page-ordernow .services-list {
  flex-grow: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  width: 100%; 
  overflow-y: auto; /* Включаем скролл */
  overflow-x: hidden;
  gap: 0.75rem; /* Отступы между кнопками */
  padding: 0 15px 0 0; /* Отступ справа для скроллбара */
  margin: 0;
}

/* --- ВОССТАНОВЛЕННЫЕ СТИЛИ КНОПОК УСЛУГ С УЛУЧШЕННЫМИ АНИМАЦИЯМИ --- */
.page-ordernow .service-item {
  flex-shrink: 0;
  border: 2px solid #333; 
  background: linear-gradient(135deg, #111 0%, #222 50%, #111 100%); 
  border-radius: 0.75rem; 
  box-shadow: 0 4px 16px rgba(0,0,0,0.3), inset 0 1px 0 rgba(255,255,255,0.1); 
  font-family: 'Roboto', sans-serif; 
  font-weight: 400; 
  color: #fff; 
  cursor: pointer; 
  width: 100%; 
  display: flex; 
  align-items: center; 
  position: relative; 
  overflow: hidden; /* Обрезаем анимации по краям */
  justify-content: flex-start; 
  text-align: left; 
  padding: clamp(0.7rem, 2vh, 1rem) 1.2rem;
  font-size: clamp(0.85rem, 2.2vh, 1.1rem);
  min-height: 50px;
  transition: all 0.2s ease-in-out;
  will-change: transform, box-shadow, border-color, background;
}

/* Анимация свечения при наведении */
.page-ordernow .service-item::before { 
  content: ''; 
  position: absolute; 
  top: 0; 
  left: -100%; 
  width: 100%; 
  height: 100%; 
  background: linear-gradient(90deg, transparent, rgba(102, 229, 255, 0.2), transparent); 
  transition: left 0.5s ease-in-out;
  z-index: 1;
}

.page-ordernow .service-item:hover::before { 
  left: 100%; 
}

.page-ordernow .service-item:hover {
  background: linear-gradient(135deg, #2c1a2e 0%, #21163e 50%, #1a0f60 100%); 
  box-shadow: 0 8px 32px rgba(153, 50, 204, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 0 0 1px rgba(153, 50, 204, 0.5); 
  border-color: #9932cc;
  /* Убрано смещение - только цвет и тень */
  transform: none;
}

.page-ordernow .service-item:active { 
  /* Убрано смещение - только визуальные эффекты */
  transform: none;
  box-shadow: 0 6px 24px rgba(153, 50, 204, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 0 0 1px rgba(153, 50, 204, 0.5);
}

/* Текст кнопки поверх анимации */
.page-ordernow .service-item > * {
  position: relative;
  z-index: 2;
}


.page-about .contact-right, .page-contact .contact-right { display: flex; flex-direction: column; padding: 1.5rem 1.5rem 0.5rem; }
.contact-text { flex-grow: 1; min-height: 0; overflow-y: auto; font-size: clamp(0.85rem, 2vh, 1.05rem); line-height: 1.5; margin-right: -1rem; padding-right: 1rem; }
.contact-text p { margin-bottom: clamp(0.5rem, 2vh, 1rem); }
.about-text p { text-align: justify; }
.about-text p:last-of-type { text-align: center; }
.contact-icons { flex-shrink: 0; display: flex; justify-content: center; align-items: center; width: 100%; margin-top: clamp(0.5rem, 2vh, 1.5rem); }
.contact-icons a { position: relative; padding: 0 clamp(0.5rem, 2vw, 1rem); }
.contact-icons a:not(:first-child)::before { content: ''; position: absolute; left: 0; top: 50%; transform: translateY(-50%); width: 2px; height: 50%; background: linear-gradient( to bottom, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.25), rgba(255, 255, 255, 0) ); border-radius: 2px; }
.contact-icon { height: clamp(28px, 6vw, 40px); width: auto; transition: transform 0.3s ease; }
.contact-icons a[href*="affiliatefix"] .contact-icon { width: clamp(85px, 22vw, 140px); height: auto; }
.contact-icon:hover { transform: scale(1.1); }
.page-affiliates .affiliates-right, .page-404 .affiliates-right { display: flex; justify-content: center; align-items: center; font-family: 'Oxanium', sans-serif; font-size: clamp(2rem, 4vw, 2.5rem); text-align: center; padding: 2rem; }

/* 
==========================================================================
  ИЗМЕНЕННАЯ ВЕРСИЯ СТИЛЕЙ МОДАЛЬНЫХ ОКОН (СОГЛАСНО СКРИНШОТУ)
==========================================================================
*/
/* 1. Оверлей. */
.modal {
  display: none; /* Изначально скрыт */
  opacity: 0;
  transition: opacity 0.2s ease-in-out;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.9);
  z-index: 1000;
  padding: 2rem 1rem; /* Добавлено больше вертикального пространства */
  /* display: flex; <-- Добавляется через JS */
  justify-content: center;
  align-items: center;
}

/* 2. Контейнер-обертка для модального окна (теперь невидимый) */
.modal-content {
  background: transparent;
  border: none;
  box-shadow: none;
  border-radius: 0;
  max-width: 900px;
  width: 100%;
  max-height: 100%;
  overflow: visible; /* Позволяет свечению кнопки выходить за пределы */
  display: flex;
  flex-direction: column;
}

/* 3. Основные блоки контента (теперь это видимый бокс) */
.modal-1-layout, .modal-single-column {
    background: #1C1C1E; /* Сплошной темный фон как на скриншоте */
    border: 1px solid #383838; /* Тонкая рамка */
    border-radius: 8px; /* Смягченные углы */
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.7); /* Более выраженная тень */
    flex-grow: 1;
    min-height: 0;
    overflow-y: auto; /* Здесь будет скролл */
    padding: 2rem;
}
.modal-1-layout {
    display: flex;
    gap: 2rem;
}
.modal-left-column { flex: 0 0 220px; }
.modal-right-column { flex: 1; min-width: 0; }
.desktop-only-btn { display: none; }
.text-container h3 { margin-top: 0; }

/* 4. Футер модального окна (контейнер для кнопки) */
.modal-fixed-footer {
    flex-shrink: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem 0 0 0; /* Отступ сверху для отделения кнопки от контента */
    border-top: none;
    background-color: transparent;
}

/* Общие стили для заголовков */
.modal-content h3 {
  font-family: 'Oxanium', sans-serif;
  font-size: 1.6rem;
  font-weight: 500;
  margin-bottom: 1.5rem;
}

/* Остальные стили */
.modal .close {
    position: absolute;
    top: 0.8rem;
    right: 0.8rem;
    font-size: 2.5rem;
    font-weight: 300;
    cursor: pointer;
    color: #aaa;
    transition: all 0.3s ease;
    z-index: 1002;
    background: none;
    border: none;
    padding: 0.5rem;
    line-height: 0.5;
    width: auto; /* Сброс старых стилей */
    height: auto; /* Сброс старых стилей */
    display: block; /* Сброс flex */
}
.modal .close:hover {
    color: #fff;
    background: none;
    transform: scale(1.1);
    border-color: transparent; /* Убедимся, что рамка не появляется при наведении */
}

.modal-content p, .modal-content li { font-size: 0.9rem !important; line-height: 1.5 !important; margin-bottom: 1rem; }

.book-cover {
    width: 100%;
    height: auto;
    border-radius: 0.5rem;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
    border: none; /* Убрана рамка */
    cursor: pointer;
    transition: transform 0.3s ease;
    margin-bottom: 1.5rem;
}
.book-cover:hover { transform: scale(1.02); }

.order-now-btn {
    background: linear-gradient(90deg, #a044ff 0%, #6a3093 100%);
    color: #fff;
    border: none;
    padding: 0.8rem 2.5rem;
    font-size: 1.1rem;
    font-weight: 500;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    font-family: 'Oxanium', sans-serif;
    letter-spacing: 0.02em;
    box-shadow: 0 0 25px 3px rgba(160, 68, 255, 0.55); /* Эффект свечения */
    text-align: center;
}
.order-now-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 0 35px 8px rgba(160, 68, 255, 0.6);
    background: linear-gradient(90deg, #ad5aff 0%, #7c38a8 100%);
}
.order-now-btn.disabled {
    background: linear-gradient(135deg, #5a5a5a 0%, #3a3a3a 100%);
    box-shadow: none;
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
}

.modal-section { margin: 1.5rem 0 0 0; padding: 1.2rem; border-radius: 0.8rem; border-left: 4px solid; }
.modal-section.warning { background: rgba(255, 193, 7, 0.08); border-left-color: #ffc107; }
.modal-section.success { background: rgba(76, 175, 80, 0.08); border-left-color: #4caf50; }
.modal-section.info { background: rgba(33, 150, 243, 0.08); border-left-color: #2196f3; }
.modal-section.pricing { background: rgba(156, 39, 176, 0.08); border-left-color: #9c27b0; }
.modal-section h4 { margin: 0 0 0.8rem 0; font-size: 1.1rem; font-weight: 500; }
.modal-section.warning h4 { color: #ffc107; }
.modal-section.success h4 { color: #4caf50; }
.modal-section.info h4 { color: #2196f3; }
.modal-section.pricing h4 { color: #9c27b0; }

.modal-fixed-footer .order-now-btn {
    width: auto;
    max-width: 400px;
    font-size: 1.1rem;
    padding: 0.8rem 2.5rem;
}
.pricing-list { list-style: none; padding: 0; margin: 1.5rem 0; }
.pricing-list li { padding: 0.75rem 0; border-bottom: 1px solid #333; }
.pricing-list li:first-child { padding-top: 0; }
.pricing-list li:last-child { border-bottom: none; padding-bottom: 0; }
.pricing-list strong { color: #8a2be2; }
.modal-disclaimer { font-style: italic; opacity: 0.8; margin-top: 1.5rem; margin-bottom: 0; }

.fullscreen-overlay { display: none; opacity: 0; transition: opacity 0.2s; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.95); z-index: 2000; justify-content: center; align-items: center; padding: 2rem; }
.fullscreen-image { max-width: 90%; max-height: 90%; border-radius: 0.5rem; box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8); }
.fullscreen-close { position: absolute; top: 2rem; right: 2rem; font-size: 2.5rem; color: #fff; cursor: pointer; background: rgba(0, 0, 0, 0.5); border-radius: 50%; width: 60px; height: 60px; display: flex; align-items: center; justify-content: center; transition: all 0.3s ease; }
.fullscreen-close:hover { background: rgba(0, 0, 0, 0.8); transform: scale(1.1); }

.page-404 .hero-section { position: relative; }
.page-404 .overlay-texts { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 2; pointer-events: none; display: flex; flex-direction: column; justify-content: center; align-items: center; }
.page-404 .overlay-texts .top-text { font-family: 'Oxanium', sans-serif; font-size: 2rem; margin-bottom: 2rem; }
.page-404 .overlay-texts .bottom-text { font-family: 'Roboto', sans-serif; font-size: 1.1rem; color: #ccc; }
@media (max-width: 768px) { .page-404 .overlay-texts .top-text { font-size: 1.4rem; } .page-404 .overlay-texts .bottom-text { font-size: 1rem; } }

/* === Кастомный скроллбар === */
.modal-1-layout, .modal-single-column, .page-ordernow .services-list, .contact-text, .page-ordernow .affiliates-right, .page-about .contact-right, .page-contact .contact-right, .page-tcdark main, .page-tclight main, .modal-right-column {
  scrollbar-width: thin;
  scrollbar-color: #666 #111;
}
.modal-1-layout::-webkit-scrollbar, .modal-single-column::-webkit-scrollbar, .page-ordernow .services-list::-webkit-scrollbar, .contact-text::-webkit-scrollbar, .page-ordernow .affiliates-right::-webkit-scrollbar, .page-about .contact-right::-webkit-scrollbar, .page-contact .contact-right::-webkit-scrollbar, .page-tcdark main::-webkit-scrollbar, .page-tclight main::-webkit-scrollbar, .modal-right-column::-webkit-scrollbar { 
  width: 8px; 
}
.modal-1-layout::-webkit-scrollbar-thumb, .modal-single-column::-webkit-scrollbar-thumb, .page-ordernow .services-list::-webkit-scrollbar-thumb, .contact-text::-webkit-scrollbar-thumb, .page-ordernow .affiliates-right::-webkit-scrollbar-thumb, .page-about .contact-right::-webkit-scrollbar-thumb, .page-contact .contact-right::-webkit-scrollbar-thumb, .page-tcdark main::-webkit-scrollbar-thumb, .page-tclight main::-webkit-scrollbar-thumb, .modal-right-column::-webkit-scrollbar-thumb { 
  background-color: #666; 
  border-radius: 4px; 
}
.modal-1-layout::-webkit-scrollbar-track, .modal-single-column::-webkit-scrollbar-track, .page-ordernow .services-list::-webkit-scrollbar-track, .contact-text::-webkit-scrollbar-track, .page-ordernow .affiliates-right::-webkit-scrollbar-track, .page-about .contact-right::-webkit-scrollbar-track, .page-contact .contact-right::-webkit-scrollbar-track, .page-tcdark main::-webkit-scrollbar-track, .page-tclight main::-webkit-scrollbar-track, .modal-right-column::-webkit-scrollbar-track { 
  background-color: #111; 
}

/* === МОБИЛЬНАЯ АДАПТАЦИЯ (до 900px) === */
@media (max-width: 900px) {
  .site-header { position: sticky; top: 0; }
  .nav-links { display: none; flex-direction: column; background-color: #000; position: absolute; top: 100%; right: 0; width: 100%; padding: 1rem; border-top: 1px solid #333; }
  .nav-links.open { display: flex; }
  .hamburger { display: flex; }
  .site-title { font-size: 1.2rem; }
  .footer-inner { font-size: clamp(0.5rem, 2.4vw, 0.75rem); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .footer-right a { font-size: inherit; }
  
  .page-ordernow .affiliates-content, .page-about .affiliates-content, .page-contact .affiliates-content, .page-affiliates .affiliates-content, .page-404 .affiliates-content { display: grid; grid-template-columns: 1fr; grid-template-rows: 30vh minmax(0, 1fr); flex-direction: unset; }
  .page-ordernow .affiliates-left, .page-about .affiliates-left, .page-contact .affiliates-left, .page-affiliates .affiliates-left, .page-404 .affiliates-left { min-height: 0; }
  .page-ordernow .affiliates-right, .page-about .contact-right, .page-contact .contact-right, .page-affiliates .affiliates-right, .page-404 .affiliates-right { min-height: 0; padding: 1rem 1rem 0 1rem; overflow: hidden; }
  .page-ordernow .services-list { 
    overflow-y: auto; 
    padding: 0 15px 1rem 0;
  }
  .page-ordernow .service-item { padding: 1.2vh 3vmin; font-size: clamp(12px, 3vmin, 16px); }
  .page-about .contact-right, .page-contact .contact-right { overflow-y: hidden; }
  .page-about .contact-text, .page-contact .contact-text { overflow-y: auto; }
  .page-ordernow .right-column-title, .page-about .right-column-title, .page-contact .right-column-title { text-align: center; font-size: clamp(1.2rem, 4.5vw, 1.5rem); }

  .modal { padding: calc(3.2rem + 1rem) 1rem 1rem 1rem; }
  .modal .close { top: calc((3.2rem + 1rem) / 2 - 17px); right: 1rem; }
  .modal-1-layout, .modal-single-column { padding: 1.5rem; }
  .modal-1-layout { flex-direction: column; gap: 1rem; }
  
  /* --- НАЧАЛО: ФИНАЛЬНОЕ ИСПРАВЛЕНИЕ ДЛЯ ПОРТРЕТНОЙ ВЕРСИИ --- */
  /* Конкретное правило ТОЛЬКО для левой колонки в ПЕРВОМ модальном окне */
  #modal1 .modal-left-column {
    flex: none; /* Убираем гибкость, т.к. размер задан через .book-cover */
    display: flex; /* Включаем flex-контейнер */
    justify-content: center; /* Центрируем обложку по горизонтали */
  }
  /* --- КОНЕЦ: ФИНАЛЬНОЕ ИСПРАВЛЕНИЕ ДЛЯ ПОРТРЕТНОЙ ВЕРСИИ --- */
  
  .book-cover { width: 160px; margin-bottom: 0; }
  
  .fullscreen-close { top: 1rem; right: 1rem; font-size: 2rem; width: 50px; height: 50px; }
}

/* === АДАПТАЦИЯ К ГОРИЗОНТАЛЬНОЙ ОРИЕНТАЦИИ (ТЕЛЕФОНЫ И ПЛАНШЕТЫ) === */
/* Правило срабатывает для всех устройств в альбомной ориентации, где высота меньше 800px */
@media (orientation: landscape) and (max-height: 800px) {
  .site-header { position: relative; }
  .page-ordernow .affiliates-content, .page-about .affiliates-content, .page-contact .affiliates-content, .page-affiliates .affiliates-content, .page-404 .affiliates-content { display: flex; flex-direction: row; grid-template-rows: unset; }
  .page-ordernow .affiliates-left, .page-ordernow .affiliates-right, .page-about .affiliates-left, .page-about .contact-right, .page-contact .affiliates-left, .page-contact .contact-right, .page-affiliates .affiliates-left, .page-affiliates .affiliates-right, .page-404 .affiliates-left, .page-404 .affiliates-right { flex-basis: 50%; min-width: 0; }
  .page-ordernow .affiliates-right, .page-about .contact-right, .page-contact .contact-right { overflow-y: auto; padding: 1rem; }
  
  /* === ИСПРАВЛЕННЫЕ СТИЛИ ДЛЯ ЛАНДСКЕЙПА === */
  .page-ordernow .services-list {
    overflow-y: auto;
    padding: 0 15px 0 0;
    gap: 0.5rem;
  }
  
  .page-ordernow .right-column-title, .page-about .right-column-title, .page-contact .right-column-title { text-align: left; margin: 0 0 1rem 0; font-size: clamp(1.1rem, 3.5vh, 1.4rem); }
  .page-ordernow .service-item { padding: 0.8vh 2vmin; font-size: clamp(11px, 2.5vh, 14px); }

  /* --- НАЧАЛО: ФИНАЛЬНОЕ РЕШЕНИЕ для #modal1 в ландшафтном режиме --- */
  
  /* 1. Возвращаем модальному окну горизонтальное расположение колонок */
  #modal1 .modal-1-layout {
    flex-direction: row; 
    gap: 1rem;
    overflow: hidden; /* 2. ЗАПРЕЩАЕМ скролл для всего родительского контейнера. */
    align-items: stretch; /* Заставляет обе колонки растянуться на 100% высоты родителя */
    /* 3. Убираем правый отступ у родителя, чтобы скроллбар прижался к краю */
    padding: 1.5rem 0 1.5rem 1.5rem;
  }

  /* 4. Настраиваем Область 1 (левая колонка с картинкой) */
  #modal1 .modal-left-column {
    flex: 0 0 160px; /* Фиксированная ширина */
    display: flex; /* Включаем flex для внутреннего центрирования картинки */
    align-items: center; /* Центрируем картинку по вертикали */
    justify-content: center;
    flex-direction: initial; 
    align-self: initial;
  }
  
  #modal1 .book-cover {
    margin-bottom: 0; /* Убираем лишний отступ */
  }

  /* 5. Настраиваем Область 2 (правая колонка с текстом) */
  #modal1 .modal-right-column {
    flex: 1 1 0; /* Позволяем колонке занимать все оставшееся место */
    overflow-y: auto; /* 6. РАЗРЕШАЕМ вертикальный скролл ТОЛЬКО для этой колонки */
    min-height: 0; /* Техническое свойство для корректной работы overflow */
    /* 7. Возвращаем правый отступ, чтобы текст не прилипал к скроллбару */
    padding-right: 1.5rem;
  }
  /* --- КОНЕЦ: ФИНАЛЬНОЕ РЕШЕНИЕ --- */
}

/* === ОЧЕНЬ БОЛЬШИЕ ЭКРАНЫ (от 1400px) === */
@media (min-width: 1400px) {
  .page-ordernow .service-item { font-size: clamp(1.2rem, 1.3vw, 1.8rem); padding: clamp(1.2rem, 1.8vh, 2rem) clamp(1.2rem, 1.8vw, 2rem); }
  .right-column-title { font-size: clamp(2.2rem, 4vh, 2.5rem); }
}

/* === СТИЛИ ДЛЯ СТРАНИЦЫ УСЛОВИЙ И ПОЛОЖЕНИЙ (T&C) === */
.page-tcdark main, .page-tclight main { overflow-y: auto; padding: 0 1rem; }
.terms-content { padding-top: clamp(1.5rem, 5vw, 3rem); padding-bottom: clamp(1.5rem, 5vw, 3rem); font-family: 'Roboto', sans-serif; font-weight: 300; max-width: 1200px; margin: 0 auto; }
.terms-content h1 { font-family: 'Oxanium', sans-serif; font-size: clamp(1.5rem, 4vw, 2.2rem); text-align: center; margin-bottom: clamp(1.5rem, 5vw, 3rem); letter-spacing: -0.025em; font-weight: 500; }
.terms-content h2 { font-family: 'Oxanium', sans-serif; font-size: clamp(1.0rem, 2.5vw, 1.3rem); margin-top: clamp(1.5rem, 4vw, 2.5rem); margin-bottom: 1rem; font-weight: 500; border-bottom: 1px solid #444; padding-bottom: 0.5rem; }
.terms-content p, .terms-content li { font-size: clamp(0.75rem, 1.5vw, 0.95rem); line-height: 1.7; margin-bottom: 1rem; }
.terms-content li { margin-left: 1.5rem; }
.terms-content ul, .terms-content ol { padding-left: 1.5rem; }
.terms-content ul ul, .terms-content ol ol { margin-top: 0.5rem; }
.terms-content a { text-decoration: underline; transition: color 0.2s ease-in-out; }
.terms-content a:hover { text-decoration: none; }
body.page-tclight { background-color: #ffffff; color: #1c1e21; }
.page-tclight main { background-color: #ffffff; }
.page-tclight .terms-content { background-color: #ffffff; padding-left: clamp(1rem, 4vw, 2.5rem); padding-right: clamp(1rem, 4vw, 2.5rem); border-radius: 8px; box-shadow: 0 4px 20px rgba(0,0,0,0.05); }
.page-tclight .terms-content h2 { border-bottom-color: #ddd; }
.page-tclight .terms-content a { color: #0056b3; }
.page-tclight .terms-content a:hover { color: #003d80; }
.page-tclight .footer-inner, .page-tclight .footer-right a { color: #fff; }
.page-tcdark .terms-content a { color: #8ab4f8; }
.page-tcdark .terms-content a:hover { color: #b3ceff; }