/* Lightbox2: фиксируем оверлей и контейнер по viewport (без прыжков скролла,
   без "пустого места сверху" на длинных страницах) и центрируем содержимое.
   Стили применяются только когда lightbox реально открыт — lightbox.js при
   `disableScrolling: true` добавляет на body класс `lb-disable-scrolling`.
   Размеры картинки задаёт сам плагин через опции lightbox.option ниже. */
body.lb-disable-scrolling .lightboxOverlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 100000 !important;
}
body.lb-disable-scrolling #lightbox.lightbox {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    padding: max(16px, 4vh) 0 0 0 !important;
    margin: 0 !important;
    box-sizing: border-box !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    /* Не center: иначе при появлении/скрытии полосы подписи весь блок
       пересчитывает середину и картинка прыгает вверх/вниз. */
    justify-content: flex-start !important;
    text-align: center !important;
    z-index: 100001 !important;
    pointer-events: none;
}
body.lb-disable-scrolling #lightbox.lightbox .lb-outerContainer,
body.lb-disable-scrolling #lightbox.lightbox .lb-dataContainer {
    pointer-events: auto;
    margin: 0 auto !important;
    flex-shrink: 0;
}

/* Полоса подписи ВСЕГДА в потоке: lightbox2 на changeImage делает
   .lb-dataContainer.hide(), из‑за чего картинка прыгает по вертикали
   (flex-center), а потом fadeIn возвращает текст и сдвигает фото вверх.
   !important перебивает inline display:none от jQuery .hide(). */
#lightbox .lb-dataContainer {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    min-height: 56px !important;
    height: 56px !important;
    max-height: 56px !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    padding-top: 8px !important;
}
#lightbox .lb-data .lb-details {
    line-height: 1.25;
    min-height: 40px;
}
#lightbox .lb-data .lb-caption {
    display: -webkit-box !important;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    overflow: hidden;
    line-height: 1.25em;
    max-height: 2.5em;
    min-height: 1.25em;
    font-size: 13px;
    font-weight: 700;
    opacity: 1 !important;
}
#lightbox .lb-data .lb-number {
    display: block !important;
    padding-bottom: 0 !important;
    margin-top: 2px;
    opacity: 1 !important;
}

/* ===========================================================================
   Плавная смена картинок в лайтбоксе.

   1) `transition` на .lb-outerContainer — мягкое изменение размера контейнера
      между картинками разного аспект-рейтио (плагин меняет width/height
      через jQuery .animate, transition его не перекрывает, но добавляет
      аккуратное easing на сам контейнер на случай ручных изменений).
   2) `.lb-slide-enter` — keyframes-анимация slide+fade, навешивается из JS
      на <img.lb-image> при КАЖДОЙ смене картинки (next/prev).
      Анимация перезапускается удалением класса → reflow → добавлением.
   =========================================================================== */
#lightbox .lb-outerContainer{
    transition: width 350ms cubic-bezier(.25,.46,.45,.94),
                height 350ms cubic-bezier(.25,.46,.45,.94);
}
#lightbox .lb-image{
    will-change: transform, opacity;
}
#lightbox .lb-image.lb-slide-enter{
    animation: lb-slide-enter 500ms cubic-bezier(.25,.46,.45,.94);
}
@keyframes lb-slide-enter{
    from{ opacity: 0; transform: translateX(40px); }
    to  { opacity: 1; transform: translateX(0); }
}
/* На случай предпочтения «без анимаций» — отключаем slide */
@media (prefers-reduced-motion: reduce){
    #lightbox .lb-outerContainer{ transition: none; }
    #lightbox .lb-image.lb-slide-enter{ animation: none; }
}
/* Стили для правого столбца с ценой на странице экскурсии - встроены для гарантированной загрузки */
:root {
    --auth-panel-height: 72px;
}

/* Основной контейнер для двухколоночной структуры */
.main-content {
    display: flex;
    gap: 30px;
    align-items: flex-start;
}

/* Левый столбец с основным контентом */
.ex-main {
    flex: 1;
    max-width: calc(100% - 360px);
    min-width: 0;
}
.blog-page .ex-main, .exc-page .ex-main {
    flex: 1;
    max-width: 100%;
    display: flex !important;
}
.blog-page-inner {
    width: 100%;
}
.blog-page-inner .blog-main-image img{
    width: 100%;
    border-radius: 8px;
}

/* Правый столбец с ценой */
.excursion-sidebar, .exc-page-sidebar, .blog-page-sidebar {
    width: 340px !important;
    flex-shrink: 0;
    position: sticky !important;
    top: 20px !important;
    margin-left: 30px !important;
    height: max-content;
}
.excursion-sidebar ul, .exc-page-sidebar ul, .blog-page-sidebar ul{
    padding: 0;
    list-style-type: none;
}
.excursion-sidebar ul a, .exc-page-sidebar ul a, .blog-page-sidebar ul a{
    text-decoration: none !important;
    color: #333;
}

/* Блок с ценой */
.excursion-price-block {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Контейнер для цены */
.price-container {
    text-align: center;
}

.price-container h2, .booking-block h2{
    text-align: center;
    font-size: 21px;
    display: block;
    margin: 0;
    background: #efefef;
    padding: 5px;
    margin-bottom: 5px;
    border-radius: 3px;
}

.sp-price-line{
    margin-bottom: 0;
}

/* Отображение цены в одну строчку */
.price-display {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 5px;
    flex-wrap: wrap;
}

/* Обычная цена */
.regular-price {
    font-size: 24px;
    font-weight: 700;
    color: #00a7ff;
}

/* Оригинальная цена (зачеркнутая) */
.original-price {
    font-size: 24px;
    font-weight: 700;
    color: #000;
    text-decoration: line-through;
    text-decoration-color: #e74c3c;
    text-decoration-thickness: 2px;
    margin-right: 10px;
}

/* Специальная цена */
.special-price {
    font-size: 24px;
    font-weight: 700;
    color: #00a7ff;
}

/* Текст "От" и "за человека" */
.price-text {
    font-size: 16px;
    color: #333;
    font-weight: 400;
}

/* Случай когда цена не указана */
.no-price {
    font-size: 16px;
    color: #999;
    font-style: italic;
}

/* Блок бронирования */
.booking-block {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.booking-block .select-date-right{
    margin: 15px 0 15px 0;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Селектор даты и времени */
.date-selector, .time-selector {
    margin-bottom: 10px;
}

.people-selector {
    margin-bottom: 10px;
}

.date-button {
    width: 100%;
    padding: 8px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    background: #fff;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 16px;
    color: #333;
    transition: all 0.3s ease;
    font-size: 14px !important;
}

.date-button:hover {
    border-color: #00a7ff;
    background: #f8f9ff;
}

.date-button:focus {
    outline: none;
    border-color: #00a7ff;
    box-shadow: 0 0 0 3px rgba(0, 167, 255, 0.1);
}

.date-text {
    font-weight: 400;
    font-size: 14px;
}

.date-arrow {
    display: inline-block;
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid #666;
    transition: transform 0.3s ease;
}

.date-button.active .date-arrow {
    transform: rotate(180deg);
}

/* Заблокированные кнопки шагов */
.date-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background: #f5f5f5;
    border-color: #d0d0d0;
    pointer-events: none;
}

.date-button:disabled:hover {
    border-color: #d0d0d0;
    background: #f5f5f5;
}

.date-button:disabled .date-text {
    color: #999;
}

.date-button:disabled .date-arrow {
    opacity: 0.5;
}

/* Кнопки бронирования и связи */
.booking-actions {
    margin: 20px 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn-book, .btn-contact {
    width: 100%;
    padding: 8px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-book {
    background-color: #00a7ff;
    color: white;
}

.btn-book:hover {
    background-color: #0088cc;
}

.btn-book:disabled, .btn-book[disabled] {
    background-color: #b5e5ff;
    color: #fff;
    cursor: not-allowed;
    opacity: 0.8;
}

.btn-contact {
    background-color: #f8f9fa;
    color: #333;
    border: 2px solid #e0e0e0;
}

.btn-contact:hover {
    background-color: #e9ecef;
    border-color: #00a7ff;
}

.btn-book-sticky {
    display: none;
}

/* Промокод */
.promo-code-section {
    margin: 10px 0 0;
    padding: 0px;
    background-color: transparent;
    border-radius: 8px;
}

.promo-input-group {
    display: flex;
    flex-direction: row;
    gap: 10px;
}
.promo-toggle-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: flex-end;
    margin-top: 8px;
    padding: 8px 14px;
    border: 1px dashed #00a7ff;
    border-radius: 8px;
    background: #f3fbff;
    color: #007fc2;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s ease;
}
.promo-toggle-btn:hover {
    background: #e2f6ff;
    border-style: solid;
}

.promo-input {
    flex: 1;
    padding: 8px 20px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
}

.btn-outline {
    background-color: transparent;
    color: #00a7ff;
    border: 2px solid #00a7ff;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-outline:hover {
    background-color: #00a7ff;
    color: white;
}

/* Сумма заказа */
.order-summary {
    margin: 20px 0;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.order-total {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: stretch;
}

.total-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.total-amount {
    font-weight: 600;
    font-size: 16px;
}

.original-total .original-amount {
    color: #999;
    text-decoration: line-through;
    text-decoration-color: #e74c3c;
    text-decoration-thickness: 2px;
}

.final-total .final-amount {
    color: #00a7ff;
    font-size: 18px;
}
#order-summary .promo-code-section {
    width: 100%;
}
#order-summary .promo-input-group {
    justify-content: flex-end;
}
#order-summary .promo-input {
    min-width: 0;
    max-width: 210px;
}
#order-summary #apply-promo-btn {
    white-space: nowrap;
}

/* Информация об экскурсии */
.info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #e0e0e0;
    white-space: nowrap;
}

.info-item:last-child {
    border-bottom: none;
}

.info-label {
    font-weight: 500;
    color: #666;
    font-size: 14px;
    width: 100%;
}

.info-value {
    font-weight: 600;
    color: #333;
    font-size: 14px;
    text-align: right;
}

.excursion-info {
    padding: 0;
}

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
    .main-content {
        flex-direction: column;
        gap: 20px;
    }
    
    .ex-main {
        max-width: 100%;
    }
    
    .excursion-sidebar, .blog-page-sidebar {
        width: 100%;
        position: static;
        order: -1;
    }
    
    .excursion-price-block {
        margin-bottom: 0;
    }
    
    .excursion-sidebar, .exc-page-sidebar, .blog-page-sidebar{
        margin-left: 0 !important;
    }
}

@media (max-width: 1023px) {
    body {
        padding-bottom: calc(env(safe-area-inset-bottom, 0px) + var(--auth-panel-height, 72px) + 120px);
    }

    .excursion-sidebar,
    .booking-block {
        padding-bottom: calc(var(--auth-panel-height, 72px) + 40px);
    }

    .booking-actions {
        position: relative;
        margin-bottom: calc(var(--auth-panel-height, 72px) + 40px);
    }

    .btn-book.btn-book-sticky,
    .booking-actions .btn-book.btn-book-sticky {
        display: block;
        position: fixed !important;
        left: 0;
        right: 0;
        bottom: 0;
        bottom: env(safe-area-inset-bottom, 0px);
        width: 100%;
        width: 100vw;
        margin: 0;
        z-index: 2100;
        box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
        border-radius: 0;
        height: 50px;
    }

    .btn-book.btn-book-sticky:disabled,
    .booking-actions .btn-book.btn-book-sticky:disabled {
        box-shadow: none;
    }

    .booking-actions .btn-book:not(.btn-book-sticky) {
        margin-bottom: 8px;
    }
}

/* Стили для выбранной даты и времени */
.selected-date-summary {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 5px;
    margin-bottom: 20px;
}

.selected-time-summary {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 5px;
    margin-bottom: 20px;
}

.selected-date-info, .selected-time-info {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 5px;
    border-radius: 6px;
}

.selected-date-info:hover, .selected-time-info:hover {
    background: #e9ecef;
}

.selected-date-label, .selected-time-label {
    font-weight: 600;
    color: #333;
}

.selected-date-value, .selected-time-value {
    font-weight: 700;
    color: #00a7ff;
    font-size: 16px;
}

/* Модальное окно календаря */
.calendar-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 10px;
}

.calendar-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    cursor: pointer;
}

.calendar-popup {
    position: relative;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    max-width: 100%;
    width: 960px;
    max-height: 90vh;
    overflow-y: auto;
    z-index: 1001;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #e0e0e0;
    background: #f8f9fa;
}

.calendar-header #modal-title {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

#modal-title-step {
    color: #00a7ff;
}

.booking-step-title-inline {
    margin: 0 0 16px 0;
    padding: 8px 12px;
    border-bottom: 1px solid #e8e8e8;
    font-size: 1rem;
    background: #00a7ff;
    border-radius: 5px;
    text-align: center;
}
.booking-step-title-inline span {
    color: #ffffff;
    font-weight: 600;
}

.close-calendar {
    background: none;
    border: none;
    font-size: 24px;
    color: #666;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.2s ease;
}

.close-calendar:hover {
    background: #e0e0e0;
}

/* Блок с кнопками шагов внутри модального окна */
.modal-steps-navigation {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 10px 0 0;
    border-bottom: none;
}

.modal-step-button {
    width: 100%;
    padding: 8px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    background: #fff;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    color: #333;
    transition: all 0.3s ease;
}

.modal-step-button:hover:not(:disabled) {
    border-color: #00a7ff;
    background: #f8f9ff;
}

.modal-step-button:focus:not(:disabled) {
    outline: none;
    border-color: #00a7ff;
    box-shadow: 0 0 0 3px rgba(0, 167, 255, 0.1);
}

.modal-step-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background: #f5f5f5;
    border-color: #d0d0d0;
    pointer-events: none;
}

.modal-step-button:disabled:hover {
    border-color: #d0d0d0;
    background: #f5f5f5;
}

.modal-step-button:disabled .modal-step-text {
    color: #999;
}

.modal-step-button.active {
    border-color: #00a7ff;
    background: #f0f8ff;
}

.modal-step-button.active .modal-step-arrow {
    transform: rotate(180deg);
}

.modal-step-text {
    font-weight: 400;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.modal-step-icon {
    width: 16px;
    height: 16px;
    display: inline-block;
}

.modal-step-arrow {
    display: inline-block;
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid #666;
    transition: transform 0.3s ease;
}

.modal-step-button.active .modal-step-arrow {
    border-top-color: #00a7ff;
}

.calendar-content {
    padding: 20px;
}

.modal-buttons {
    display: flex;
    justify-content: center;
    gap: 0;
    padding-top: 10px;
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    flex: 1;
}

.btn-primary {
    background: #00a7ff;
    color: #fff;
}

.btn-primary:hover:not(:disabled) {
    background: #0088cc;
}

.btn-primary:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.btn-secondary {
    background: #f8f9fa;
    color: #333;
    border: 1px solid #e0e0e0;
}

.btn-secondary:hover:not(:disabled) {
    background: #e9ecef;
}

/* Типы билетов */
.ticket-types-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.ticket-type-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border: 1px solid #e6e6e6;
    border-radius: 10px;
    padding: 5px 12px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    transition: box-shadow 0.2s ease, transform 0.1s ease;
}

.ticket-type-row:hover {
    box-shadow: 0 4px 14px rgba(0,0,0,0.1);
}

.ticket-type-info {
    display: flex;
    flex-direction: column;
}

.ticket-type-name {
    font-size: 15px;
    font-weight: 600;
    color: #333;
}

.ticket-type-price {
    display: flex;
    align-items: baseline;
}

.ticket-type-price .currency {
    font-size: 12px;
    color: #777;
}

.ticket-types-wrapper.tickets-step-tour-layout {
    display: flex;
    align-items: center;
    gap: 24px;
}

.ticket-types-wrapper.tickets-step-excursion-layout {
    display: block;
}

.ticket-types-wrapper.tickets-step-tour-layout .ticket-types-container {
    flex: 0 1 auto;
    grid-template-columns: 1fr;
}

.tickets-step-inline-total {
    display: flex;
    justify-content: flex-end;
    margin-top: 16px;
}

.tickets-step-inline-total .total-summary {
    width: 100%;
    justify-content: flex-end;
}

.tickets-step-inline-total .total-summary-content {
    max-width: 460px;
}

/* Для тура: название и цена билета — серые и не жирные */
.ticket-types-wrapper.tickets-step-tour-layout .ticket-type-info,
.ticket-types-wrapper.tickets-step-tour-layout .ticket-type-name,
.ticket-types-wrapper.tickets-step-tour-layout .ticket-type-price,
.ticket-types-wrapper.tickets-step-tour-layout .ticket-type-price .regular-price,
.ticket-types-wrapper.tickets-step-tour-layout .ticket-type-price .special-price,
.ticket-types-wrapper.tickets-step-tour-layout .ticket-type-price .original-price,
.ticket-types-wrapper.tickets-step-tour-layout .ticket-type-price .currency {
    color: #888 !important;
    font-weight: 400 !important;
}

/* Блок итога за билеты на шаге тура — жирный и синий */
.ticket-types-wrapper.tickets-step-tour-layout .ticket-type-price.tickets-step-tour-total,
.ticket-types-wrapper.tickets-step-tour-layout .ticket-type-price.tickets-step-tour-total .regular-price,
.ticket-types-wrapper.tickets-step-tour-layout .ticket-type-price.tickets-step-tour-total .currency {
    color: #00a7ff !important;
    font-weight: 600 !important;
}

.tickets-step-tour-total {
    flex-shrink: 0;
}

.ticket-quantity-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.quantity-btn {
    width: 34px;
    height: 34px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background: #f9fbfd;
    color: #333;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    line-height: 1;
    transition: all 0.2s ease;
}

.quantity-btn:hover {
    background: #f0f7ff;
    border-color: #00a7ff;
    color: #00a7ff;
}

.ticket-quantity {
    width: 56px;
    height: 34px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    text-align: center;
    font-size: 15px;
    padding: 0 6px;
}

/* Шаг "Номера" (туры с проживанием) */
.rooms-step-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
.rooms-step-block {
    padding: 10px;
    border-radius: 8px;
    background: #fff;
    box-shadow: 4px 4px 12px 0 rgba(0,0,0,.15);
}
.rooms-step-block-left {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.rooms-step-block-header { font-weight: 700; }
.rooms-step-left-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}
.rooms-step-price-default {
    color: #777;
    font-weight: 600;
    font-size: 21px;
}
.rooms-step-total-line.rooms-step-total-active {
    color: #00a7ff;
    font-weight: 600;
    font-size: 21px;
}
.rooms-step-total-line.rooms-step-total-inactive {
    color: #777;
    font-size: 14px;
}
.rooms-step-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}
.rooms-step-controls .quantity-btn {
    width: 34px;
    height: 34px;
}
.rooms-count-input {
    width: 56px;
    height: 34px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    text-align: center;
    font-size: 15px;
    padding: 0 6px;
}
.rooms-step-block-right {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.rooms-step-tour-title { font-weight: 700; }
.rooms-step-info-line { margin: 0; font-size: 14px; }
.rooms-step-choose-line { margin: 0; font-size: 14px; }
/* Блок промокода и итога на шаге «Итого к оплате» */
#total-step #total-summary {
    margin-top: 0;
    justify-content: flex-end;
}
#total-step .total-summary-content {
    width: 100%;
    max-width: 460px;
}
#total-step .modal-promo-code-section {
    width: 100%;
}
#total-step .modal-promo-code-section .promo-input-group {
    justify-content: flex-end;
    flex-wrap: wrap;
}
#total-step .modal-promo-code-section .promo-input {
    max-width: 220px;
}
/* Подпись «Номера:» на вкладке с выбранными номерами */
.selected-rooms-label {
    font-weight: 600;
    color: #333;
}
@media (max-width: 767px) {
    .selected-rooms-label { display: none !important; }
}
@media (max-width: 600px) {
    .rooms-step-grid { grid-template-columns: 1fr; }
}

/* Шаг номеров: гостиница + галерея + номер + количество */
.rooms-step-hotel-section { margin-bottom: 0; }
.rooms-step-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}
.rooms-step-hotel-name-row { justify-content: space-between; }
.rooms-step-hotel-name-wrap {
    position: relative;
    flex: 0;
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    cursor: pointer;
}
.rooms-step-hotel-name {
    font-weight: 600;
    color: #333;
    font-size: 15px;
    white-space: nowrap;
}
.rooms-step-hotel-dropdown-arrow {
    margin-left: 4px;
    flex-shrink: 0;
}
.rooms-step-hotel-dropdown {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    margin-top: 4px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 1000;
    min-width: 180px;
    max-height: 240px;
    overflow-y: auto;
}
.rooms-step-hotel-dropdown-item {
    display: block;
    width: 100%;
    padding: 8px 14px;
    text-align: left;
    border: none;
    background: none;
    cursor: pointer;
    font-size: 14px;
}
.rooms-step-hotel-dropdown-item:hover { background: #f0f8ff; }
.rooms-step-hotel-image-row { justify-content: center; position: relative; }
.rooms-step-hotel-image-row .rooms-step-slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
}
.rooms-step-hotel-image-row #rooms-step-hotel-img-prev { left: 8px; }
.rooms-step-hotel-image-row #rooms-step-hotel-img-next { right: 8px; }
.rooms-step-hotel-image-wrap {
    flex: 1;
    min-width: 0;
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: #f5f5f5;
    border-radius: 8px;
    overflow: hidden;
    touch-action: pan-y;
}
.rooms-step-hotel-image-wrap a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    cursor: pointer;
}
.rooms-step-hotel-photo {
    width: 100%;
    height: auto;
    display: block;
}
.rooms-step-room-name-row { justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 12px; }
.rooms-step-room-name-row .rooms-step-room-name { flex: 1; text-align: center; font-size: 15px; font-weight: 600; }
.rooms-step-room-name-row .rooms-step-slider-arrow { flex-shrink: 0; }
.rooms-step-room-image-row { position: relative; margin-bottom: 12px; }
.rooms-step-room-image-row .rooms-step-slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
}
.rooms-step-room-image-row #rooms-step-room-img-prev { left: 8px; }
.rooms-step-room-image-row #rooms-step-room-img-next { right: 8px; }
.rooms-step-room-image-wrap {
    flex: 1;
    min-width: 0;
    position: relative;
    border-radius: 8px;
    touch-action: pan-y;
}
.rooms-step-room-image-track-wrap {
    width: 100%;
    height: 180px;
    overflow: hidden;
    border-radius: 8px;
    background: #f5f5f5;
}
.rooms-step-room-image-track {
    display: flex;
    height: 100%;
    transition: transform 0.3s ease;
}
.rooms-step-room-image-slide {
    flex: 0 0 100%;
    width: 100%;
    height: 100%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f5;
}
.rooms-step-room-image-slide a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    cursor: pointer;
}
.rooms-step-room-image-slide img {
    width: 100%;
    object-fit: contain;
    display: block;
}
.rooms-step-quantity-row { align-items: center; flex-wrap: wrap; gap: 10px; }
.rooms-step-quantity-label { font-weight: 600; font-size: 14px; }
.rooms-step-total-wrap { display: flex; flex-direction: column; gap: 2px; }
.rooms-step-slider-arrow {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.rooms-step-slider-arrow:hover { background: #f5f5f5; }

/* Краткое описание гостиницы: 4 строки по умолчанию (мобильная и десктоп), кнопка "Больше", ссылка "Раскрыть подробнее" скрыта по умолчанию, показывается после "Больше" */
.rooms-step-hotel-desc-wrap { margin-bottom: 4px; }
.rooms-step-hotel-desc-more-btn {
    border: none;
    padding: 0;
    font-size: 14px;
    cursor: pointer;
    margin-bottom: 8px;
    font-weight: bold;
    background: #d9d9d9;
    width: 100%;
    padding: 7px;
    border-radius: 7px;
    color: #000000;
    text-decoration: none;
}
.rooms-step-hotel-description--collapsed {
    display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 4; overflow: hidden;
}
.rooms-step-hotel-desc-wrap.expanded .rooms-step-hotel-description--collapsed {
    -webkit-line-clamp: unset; display: block;
}
.rooms-step-hotel-desc-wrap.expanded .rooms-step-hotel-desc-more-btn { display: none !important; }
.rooms-step-hotel-desc-wrap.expanded .rooms-step-hotel-more-link { display: inline-block !important; }

/* Краткое описание номера: 4 строки по умолчанию (мобильная и десктоп), кнопка "Больше" (тот же стиль, что у гостиницы) */
.rooms-step-room-desc-wrap { margin-bottom: 4px; }
.rooms-step-room-description--collapsed {
    display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 4; overflow: hidden;
}
.rooms-step-room-desc-wrap.expanded .rooms-step-room-description--collapsed {
    -webkit-line-clamp: unset; display: block;
}
.rooms-step-room-desc-wrap.expanded #rooms-step-room-desc-more-btn { display: none !important; }

/* Модальное окно "Все гостиницы" */
.all-hotels-modal {
    position: fixed;
    inset: 0;
    z-index: 10002;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.all-hotels-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.5);
}
.all-hotels-popup {
    position: relative;
    background: #fff;
    border-radius: 12px;
    max-width: 520px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    padding: 20px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.2);
}
.all-hotels-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
}
.all-hotels-hotel-name { margin: 0; font-size: 18px; flex: 1; text-align: center; }
.all-hotels-nav-arrow {
    width: 40px;
    height: 40px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.all-hotels-nav-arrow:hover { background: #f5f5f5; }
.all-hotels-hotel-image-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    position: relative;
    touch-action: pan-y;
}
.all-hotels-hotel-image-wrap .all-hotels-img-prev,
.all-hotels-hotel-image-wrap .all-hotels-img-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
}
.all-hotels-hotel-image-wrap .all-hotels-img-prev { left: 8px; }
.all-hotels-hotel-image-wrap .all-hotels-img-next { right: 8px; }
.all-hotels-hotel-image {
    flex: 1;
    max-height: 220px;
    object-fit: contain;
    border-radius: 8px;
    background: #f5f5f5;
}
.all-hotels-rooms-slider-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    position: relative;
    touch-action: pan-y;
}
.all-hotels-rooms-slider-wrap .all-hotels-room-prev,
.all-hotels-rooms-slider-wrap .all-hotels-room-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
}
.all-hotels-rooms-slider-wrap .all-hotels-room-prev { left: 8px; }
.all-hotels-rooms-slider-wrap .all-hotels-room-next { right: 8px; }
.all-hotels-rooms-slider-wrap .all-hotels-rooms-slider { margin: 0 44px; }
.all-hotels-rooms-label { font-weight: 600; flex-shrink: 0; }
.all-hotels-rooms-slider {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 8px 0;
    flex: 1;
    min-width: 0;
}
.all-hotels-room-card {
    flex: 0 0 auto;
    width: 100px;
    text-align: center;
    cursor: pointer;
    border: 2px solid transparent;
    border-radius: 8px;
    padding: 6px;
}
.all-hotels-room-card.active { border-color: #00a7ff; background: #f0f8ff; }
.all-hotels-room-card img {
    width: 100%;
    height: 70px;
    object-fit: cover;
    border-radius: 6px;
    display: block;
}
.all-hotels-room-card .all-hotels-room-card-name { font-size: 11px; margin-top: 4px; }
.all-hotels-room-gallery-hint { font-size: 12px; color: #666; margin-bottom: 12px; }
.all-hotels-choose-btn { width: 100%; }

/* Селект предоплаты */
#prepayment-select.date-button {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    position: relative;
    padding-right: 36px;
}

#prepayment-select-wrapper{
    position: relative;
}
#prepayment-select-wrapper::after {
    content: "";
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 6px solid #666666;
    pointer-events: none;
}

#prepayment-select::-ms-expand { display: none; }

/* Адрес отправления */
.departure-address-section {
    margin-bottom: 15px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
}

.departure-address-section .info-item {
    border-bottom: none;
    padding: 0;
}

@media (max-width: 768px) {
    .ticket-types-container {
        grid-template-columns: 1fr;
    }
    .tickets-step-inline-total {
        justify-content: stretch;
    }
    .tickets-step-inline-total .total-summary-content {
        max-width: none;
        width: 100%;
    }
    
    .regular-price{
        font-size: 15px;
    }
    
    .selected-date-summary{
        margin-bottom: 10px;
        padding: 0 5px;
    }
    
    .selected-time-summary{
        margin-bottom: 10px;
        padding: 0 5px;
    }
    
    .modal-buttons{
        padding-top: 0;
        border-top: none;
        margin-top: 10px;
    }
    
    .calendar-popup {
        max-width: 95vw;
        max-height: initial;
        height: calc(100vh - 20px);
        overflow-y: auto;
    }
    
    .calendar-header {
        padding: 2px 15px;
    }
    
    .calendar-content {
        padding: 15px;
        padding-bottom: 400px;
    }
    
    .date-button {
        padding: 10px 12px;
        font-size: 14px;
    }
}

/* Начальное скрытие шагов брони. !important перекрывает .calendar-modal/.contact-modal { display:flex }
   из styles.css, который подключается позже: иначе окно вспыхивает до скрипта.
   В iframe брони правило body.booking-embed-mode #calendar-modal.calendar-modal { display:flex !important }
   специфичнее и окно остаётся открытым. Скрипт снимает класс и пишет style.display. */
.is-hidden { display: none !important; }
