/* =========================================
   1. СБРОС СТИЛЕЙ И ПЕРЕМЕННЫЕ
   ========================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --color-primary: #1a1a1a;
    --color-secondary: #ff6b6b;
    --color-accent: #4ecdc4;
    --color-text: #333;
    --color-text-light: #777;
    --color-bg: #fff;
    --color-bg-light: #f5f5f5;
    --font-main: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    --transition: all 0.3s ease;
}

body {
    font-family: var(--font-main);
    color: var(--color-text);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

section {
    padding: 80px 0;
}

/* Заголовкам нужен плотнее интервал, чем тексту: иначе две строки выглядят как два заголовка */
h1, h2, h3, h4, h5 {
    line-height: 1.25;
}

.section-title {
    font-size: clamp(28px, 5vw, 42px);
    text-align: center;
    text-wrap: balance;
    margin-bottom: 48px;
    font-weight: 700;
}

/* Заглушки для картинок (пока нет фото) */
.image-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: #fff;
}
.image-placeholder i { font-size: 60px; margin-bottom: 10px; opacity: 0.7; }
.image-placeholder span { font-size: 14px; opacity: 0.9; }
.image-placeholder.large i { font-size: 80px; }
.image-placeholder.small i { font-size: 30px; margin-bottom: 0; }

.map-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: #fff;
}
.map-placeholder i { font-size: 60px; margin-bottom: 10px; opacity: 0.7; }

/* =========================================
   2. ШАПКА (HEADER)
   ========================================= */
.header {
    position: fixed;
    top: 0; left: 0; right: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    padding: 15px 0;
}

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

.nav-menu {
    display: flex;
    gap: 30px;
}

.nav-link {
    color: #fff;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.8;
}

.nav-link:hover {
    opacity: 1;
    color: var(--color-secondary);
}

.nav-contact {
    display: flex;
    align-items: center;
    gap: 15px;
}

.phone {
    color: #fff;
    font-size: 16px;
    font-weight: 600;
}

.whatsapp {
    color: #25D366;
    font-size: 24px;
}

.whatsapp:hover { transform: scale(1.1); }

/* =========================================
   3. ГЛАВНЫЙ БАННЕР И БАННЕРЫ СТРАНИЦ
   ========================================= */
.hero {
    position: relative;
    height: 100vh;
    background: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('../images/hero-bg.jpg');
    background-image: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), image-set(url('../images/hero-bg.webp') type('image/webp'), url('../images/hero-bg.jpg') type('image/jpeg'));
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: #fff;
}

.hero-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.4);
}

.hero-content {
    position: relative;
    z-index: 1;
    padding: 0 20px;
}

.hero-subtitle {
    font-size: 14px;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 20px;
    opacity: 0.9;
}

.hero-title {
    font-size: clamp(32px, 8vw, 64px);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 40px;
    text-transform: uppercase;
}

.hero-btn {
    display: inline-block;
    padding: 15px 40px;
    background: var(--color-secondary);
    color: #fff;
    border-radius: 30px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.hero-scroll {
    position: absolute;
    bottom: 30px; left: 50%;
    transform: translateX(-50%);
    animation: bounce 2s infinite;
}
.hero-scroll i { font-size: 30px; opacity: 0.7; }

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
    40% { transform: translateX(-50%) translateY(-10px); }
    60% { transform: translateX(-50%) translateY(-5px); }
}

.page-banner {
    position: relative;
    height: 400px;
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), #2a2a2a;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 60px;
}

.page-banner h1 {
    color: #fff;
    font-size: clamp(32px, 6vw, 48px);
    text-transform: uppercase;
    letter-spacing: 3px;
    text-align: center;
}

/* =========================================
   4. ГЛАВНАЯ: КВАРТИРЫ
   ========================================= */
.apartments-section { background: var(--color-bg); }

.apartments-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.apartment-card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: var(--transition);
    cursor: pointer;
}

.apartment-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.2);
}

.apartment-image {
    position: relative;
    height: 250px;
    overflow: hidden;
}

.apartment-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.apartment-card:hover .apartment-image img {
    transform: scale(1.05);
}

.apartment-badge {
    position: absolute;
    top: 15px; right: 15px;
    background: var(--btn-primary, #d6393f); /* белый текст на коралловом читался плохо (2.8:1) */
    color: #fff;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.apartment-info { padding: 25px; }
.apartment-info h3 { font-size: 20px; margin-bottom: 10px; color: var(--color-primary); }
.apartment-desc { color: var(--color-text-light); font-size: 14px; margin-bottom: 15px; }

.apartment-location {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--color-text-light);
    font-size: 14px;
}
.apartment-location i { color: var(--color-secondary); }

/* =========================================
   5. ГЛАВНАЯ: РАСПОЛОЖЕНИЕ И УСЛУГИ
   ========================================= */
.location-section { background: var(--color-bg-light); }

.location-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.location-text h2 { text-align: left; margin-bottom: 20px; }
.location-text > p { margin-bottom: 28px; color: var(--color-text-light); }
.location-item { margin-bottom: 24px; }
.location-item:last-child { margin-bottom: 0; }
.location-item h4 { font-size: 20px; margin-bottom: 8px; color: var(--color-primary); }
.location-item p { color: var(--color-text-light); font-size: 15px; margin-bottom: 0; }

.location-map {
    height: 400px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.services-section { background: var(--color-bg); }
.services-section .section-title { margin-bottom: 16px; }
.services-subtitle {
    text-align: center;
    text-wrap: balance;
    max-width: 700px;
    margin: 0 auto 48px;
    color: var(--color-text-light);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px 32px;
}

.service-item { text-align: center; padding: 24px; }

.service-icon {
    width: 80px; height: 80px;
    margin: 0 auto 20px;
    background: var(--color-bg-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}
.service-icon i { font-size: 32px; color: var(--color-secondary); }

.service-item:hover .service-icon {
    background: var(--color-secondary);
    transform: rotateY(360deg);
}
.service-item:hover .service-icon i { color: #fff; }

.service-item h4 { font-size: 20px; margin-bottom: 8px; color: var(--color-primary); }
.service-item p { color: var(--color-text-light); font-size: 15px; line-height: 1.6; }

/* =========================================
   6. ГЛАВНАЯ: ОТЗЫВЫ
   ========================================= */
.reviews-section {
    position: relative;
    background: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), #3a3a3a;
    background-size: cover;
    background-position: center;
    color: #ffffff;
    padding: 100px 0;
}

.reviews-slider { max-width: 800px; margin: 0 auto; text-align: center; }

.review-item { display: none; animation: fadeIn 0.5s; }
.review-item.active { display: block; }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.review-text { font-size: 20px; line-height: 1.8; margin-bottom: 30px; font-style: italic }
.review-author { font-weight: 600; color: var(--color-secondary); }

.reviews-dots { display: flex; justify-content: center; gap: 10px; margin-top: 30px; }
.dot {
    width: 12px; height: 12px;
    background: #fdfafab9;
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
}
.dot.active { background: var(--color-secondary); }

/* =========================================
   7. СТРАНИЦА КВАРТИРЫ
   ========================================= */
.apartment-page { padding-top: 80px; }

/* ===== ГАЛЕРЕЯ ФОТО (СЛАЙДЕР) ===== */
.apartment-gallery { background: #f5f5f5; padding: 40px 0; }

.gallery-slider {
    max-width: 1000px;
    margin: 0 auto;
}

.gallery-main {
    position: relative;
    margin-bottom: 20px;
}

.main-image {
    width: 100%;
    max-height: 80vh;         /* максимальная высота - 80% от высоты экрана */
    border-radius: 10px;
    overflow: hidden;
    background: #000;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.main-image img {
    width: 100%;
    height: auto;
    max-height: 60vh;         /* ограничиваем высоту фото */
    object-fit: contain;      /* показываем фото целиком */
    display: block;
    transition: opacity 0.3s ease;
}

/* Стрелки навигации основного фото */
.gallery-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(255,255,255,0.9);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    color: var(--color-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    z-index: 10;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.gallery-arrow:hover {
    background: var(--color-secondary);
    color: #fff;
    transform: translateY(-50%) scale(1.1);
}

.gallery-arrow-left { left: 20px; }
.gallery-arrow-right { right: 20px; }

/* Счётчик фото */
.gallery-counter {
    position: absolute;
    bottom: 20px;
    right: 20px;
    background: rgba(0,0,0,0.7);
    color: #fff;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
}

/* Лента миниатюр */
.gallery-thumbnails-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
}

.gallery-thumbnails {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 10px 0;
    flex: 1;
    scrollbar-width: thin;
    scrollbar-color: var(--color-secondary) #ddd;
}

/* Стилизация скроллбара для Chrome/Safari */
.gallery-thumbnails::-webkit-scrollbar {
    height: 8px;
}
.gallery-thumbnails::-webkit-scrollbar-track {
    background: #ddd;
    border-radius: 4px;
}
.gallery-thumbnails::-webkit-scrollbar-thumb {
    background: var(--color-secondary);
    border-radius: 4px;
}

.thumbnail {
    flex-shrink: 0;
    width: 120px;
    height: 90px;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: var(--transition);
    border: 3px solid transparent;
    opacity: 0.7;
}

.thumbnail:hover {
    opacity: 1;
    transform: translateY(-3px);
}

.thumbnail.active {
    border-color: var(--color-secondary);
    opacity: 1;
}

.thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Стрелки для ленты миниатюр */
.thumb-arrow {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    background: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 16px;
    color: var(--color-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.thumb-arrow:hover {
    background: var(--color-secondary);
    color: #fff;
}

/* ===== ДЕТАЛИ КВАРТИРЫ ===== */
.apartment-details { padding: 60px 0; }

.details-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 50px;
}

.apartment-meta {
    display: flex; flex-wrap: wrap; gap: 30px;
    margin-bottom: 40px; padding: 20px;
    background: var(--color-bg-light); border-radius: 10px;
}
.meta-item { display: flex; align-items: center; gap: 10px; font-size: 16px; }
.meta-item i { color: var(--color-secondary); font-size: 20px; }

.apartment-description, .apartment-amenities, .apartment-rules { margin-bottom: 40px; }
.apartment-description h3, .apartment-amenities h3, .apartment-rules h3 {
    font-size: 24px; margin-bottom: 20px; color: var(--color-primary);
}
.apartment-description p { font-size: 16px; line-height: 1.8; color: var(--color-text-light); }

.amenities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}
.amenity-item {
    display: flex; align-items: center; gap: 15px;
    padding: 15px; background: var(--color-bg-light);
    border-radius: 8px; transition: var(--transition);
}
.amenity-item:hover { background: var(--color-secondary); color: #fff; transform: translateX(5px); }
.amenity-item i { font-size: 24px; color: var(--color-secondary); }
.amenity-item:hover i { color: #fff; }

.rules-list { list-style: none; }
.rules-list li {
    display: flex; align-items: center; gap: 15px;
    padding: 15px 0; border-bottom: 1px solid #eee; color: var(--color-text-light);
}
.rules-list li:last-child { border-bottom: none; }
.rules-list i { color: var(--color-secondary); font-size: 20px; }

/* Виджет бронирования на странице квартиры */
.booking-widget {
    position: sticky; top: 100px;
    background: #fff; padding: 30px;
    border-radius: 10px; box-shadow: 0 5px 30px rgba(0,0,0,0.1);
}
.booking-widget h3 { font-size: 24px; margin-bottom: 20px; text-align: center; }

.price-info {
    text-align: center; margin-bottom: 30px;
    padding: 20px; background: var(--color-bg-light); border-radius: 8px;
}
.price-amount { font-size: 36px; font-weight: 700; color: var(--color-secondary); }
.price-period { font-size: 16px; color: var(--color-text-light); }

.booking-contact { margin-top: 30px; text-align: center; }
.booking-contact p { margin-bottom: 15px; color: var(--color-text-light); }

.btn-primary, .btn-whatsapp {
    display: block; padding: 12px 20px; border-radius: 8px;
    text-align: center; font-weight: 600; margin-bottom: 10px; transition: var(--transition);
}
.btn-primary { background: var(--color-secondary); color: #fff; }
.btn-whatsapp { background: #25D366; color: #fff; }
/* Карта на странице квартиры */
.apartment-map-section { padding: 60px 0; background: var(--color-bg-light); }
.apartment-map-section h2 { text-align: center; margin-bottom: 40px; }
.map-container { border-radius: 10px; overflow: hidden; box-shadow: 0 5px 20px rgba(0,0,0,0.1); }
.map-canvas { height: 500px; background: #fff; }

/* ===== АДАПТИВНОСТЬ ГАЛЕРЕИ ===== */
@media (max-width: 768px) {
    .main-image {
        height: 300px;
    }
    
    .gallery-arrow {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    
    .gallery-arrow-left { left: 10px; }
    .gallery-arrow-right { right: 10px; }
    
    .thumbnail {
        width: 100px;
        height: 75px;
    }
    
    .thumb-arrow {
        display: none; /* На мобильных скрываем стрелки, используем свайп */
    }
}

@media (max-width: 480px) {
    .main-image {
        height: 250px;
    }
    
    .gallery-counter {
        bottom: 10px;
        right: 10px;
        font-size: 12px;
        padding: 6px 12px;
    }
}

/* =========================================
   8. СТРАНИЦА БРОНИРОВАНИЯ
   ========================================= */
.booking-section { padding: 80px 0; background: var(--color-bg); }

.booking-container {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 50px;
    align-items: start;
}

.booking-info h2 { font-size: 32px; margin-bottom: 20px; color: var(--color-primary); }
.booking-info > p { color: var(--color-text-light); margin-bottom: 40px; font-size: 16px; }

/* Класс .booking-steps есть и в виджете квартиры, где он горизонтальный (ниже в этом файле):
   здесь шаги идут столбиком, иначе текст сжимался до буквы в строке */
.booking-info .booking-steps { display: block; margin-bottom: 40px; }
.step { display: flex; gap: 20px; margin-bottom: 30px; }
.step-number {
    width: 50px; height: 50px;
    background: var(--btn-primary, #d6393f); color: #fff;
    border-radius: 50%; display: flex; align-items: center; justify-content: center;
    font-size: 24px; font-weight: 700; flex-shrink: 0;
}
.step-content h4 { font-size: 18px; margin-bottom: 5px; color: var(--color-primary); }
.step-content p { color: var(--color-text-light); font-size: 14px; }

.booking-apartments h3 { font-size: 20px; margin-bottom: 20px; color: var(--color-primary); }
.booking-apt-link {
    display: flex; align-items: center; gap: 15px;
    padding: 15px; background: var(--color-bg-light);
    border-radius: 8px; margin-bottom: 10px; transition: var(--transition);
}
.booking-apt-link:hover { background: var(--color-secondary); color: #fff; transform: translateX(10px); }
.booking-apt-link i { font-size: 24px; color: var(--color-secondary); }
.booking-apt-link:hover i { color: #fff; }

.booking-calendar {
    background: #fff; padding: 30px;
    border-radius: 10px; box-shadow: 0 5px 30px rgba(0,0,0,0.1);
}

.booking-alternative { padding: 80px 0; background: var(--color-bg-light); text-align: center; }
.booking-alternative h2 { font-size: 32px; margin-bottom: 15px; color: var(--color-primary); }
.booking-alternative > p { color: var(--color-text-light); margin-bottom: 40px; font-size: 16px; }

.contact-methods {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px; max-width: 1000px; margin: 0 auto;
}
.contact-method {
    display: flex; align-items: center; gap: 20px;
    padding: 30px; background: #fff;
    border-radius: 10px; box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: var(--transition);
}
.contact-method:hover { transform: translateY(-10px); box-shadow: 0 15px 40px rgba(0,0,0,0.2); }
.contact-method i { font-size: 40px; color: var(--color-secondary); }
.contact-method h4 { font-size: 18px; margin-bottom: 5px; color: var(--color-primary); }
.contact-method p { color: var(--color-text-light); font-size: 14px; }

/* =========================================
   9. СТРАНИЦА КОНТАКТОВ
   ========================================= */
.contacts-section { padding: 80px 0; background: var(--color-bg); }

.contacts-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.contacts-info h2, .contacts-form h2 { font-size: 32px; margin-bottom: 15px; color: var(--color-primary); }
.contacts-info > p, .contacts-form > p { color: var(--color-text-light); margin-bottom: 40px; font-size: 16px; }

.contact-card {
    display: flex; gap: 20px; padding: 25px;
    background: var(--color-bg-light); border-radius: 10px;
    margin-bottom: 20px; transition: var(--transition);
}
.contact-card:hover { transform: translateX(10px); box-shadow: 0 5px 20px rgba(0,0,0,0.1); }

.contact-icon {
    width: 60px; height: 60px;
    background: var(--color-secondary); color: #fff;
    border-radius: 50%; display: flex; align-items: center; justify-content: center;
    font-size: 24px; flex-shrink: 0;
}

.contact-details h4 { font-size: 18px; margin-bottom: 5px; color: var(--color-primary); }
.contact-details a { color: var(--color-secondary); font-weight: 600; font-size: 16px; }
.contact-details p { color: var(--color-text-light); font-size: 14px; margin-top: 5px; }

.contact-person {
    display: flex; gap: 20px; padding: 25px;
    background: linear-gradient(135deg, var(--color-secondary), #ff5252);
    border-radius: 10px; color: #fff; margin-top: 30px;
}
.person-avatar {
    width: 60px; height: 60px;
    background: rgba(255,255,255,0.2); border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 24px; flex-shrink: 0;
}
.person-info h4 { font-size: 20px; margin-bottom: 5px; }
.person-info p { opacity: 0.9; font-size: 14px; }

/* Форма */
.form { background: var(--color-bg-light); padding: 40px; border-radius: 10px; }
.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 8px; font-weight: 600; color: var(--color-primary); }
.form-group input, .form-group select, .form-group textarea {
    width: 100%; padding: 12px 15px; border: 2px solid #ddd;
    border-radius: 8px; font-size: 16px; font-family: inherit; transition: var(--transition);
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    outline: none; border-color: var(--color-secondary);
}
.form-group textarea { resize: vertical; }

.btn-submit {
    width: 100%; padding: 15px;
    background: var(--color-secondary); color: #fff;
    border: none; border-radius: 8px;
    font-size: 16px; font-weight: 600; cursor: pointer; transition: var(--transition);
}
/* Карта на странице контактов */
.map-section { padding: 80px 0; background: var(--color-bg-light); }
.map-section h2 { text-align: center; font-size: 32px; margin-bottom: 40px; color: var(--color-primary); }

.map-locations {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}
.location-card {
    background: #fff; padding: 30px;
    border-radius: 10px; box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}
.location-card h4 { font-size: 20px; margin-bottom: 15px; color: var(--color-primary); }
.location-card h4 i { color: var(--color-secondary); margin-right: 10px; }
.location-card p { color: var(--color-text-light); margin-bottom: 10px; }
.location-card .coords { font-size: 14px; color: var(--color-secondary); font-weight: 600; }

/* =========================================
   10. ФУТЕР
   ========================================= */
.footer {
    background: var(--color-primary);
    color: #fff;
    padding: 60px 0 30px;
    text-align: center;
}

.footer-content h4 { font-size: 14px; letter-spacing: 2px; text-transform: uppercase; margin-bottom: 20px; opacity: 0.8; }
.footer-phone { display: block; font-size: 28px; font-weight: 700; color: #ffc107; margin-bottom: 10px; }
.footer-email { display: block; font-size: 18px; color: #ffc107; margin-bottom: 30px; }
.footer-name { font-size: 14px; letter-spacing: 1px; margin-bottom: 30px; opacity: 0.8; }

.footer-social { display: flex; justify-content: center; gap: 20px; margin-bottom: 30px; }
.footer-social a {
    width: 50px; height: 50px;
    background: rgba(255,255,255,0.1); border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 20px; transition: var(--transition);
}
.footer-social a:hover { background: var(--color-secondary); transform: translateY(-5px); }

.footer-copyright { font-size: 12px; opacity: 0.6; margin-top: 30px; }

/* =========================================
   11. АДАПТИВНОСТЬ (МЕДИА ЗАПРОСЫ)
   ========================================= */
@media (max-width: 992px) {
    .location-content,
    .details-grid,
    .booking-container,
    .contacts-grid {
        grid-template-columns: 1fr;
    }
    
    .booking-calendar { order: -1; }
    .booking-widget { position: static; }
    .main-image { height: 300px; }
}

@media (max-width: 768px) {
    .nav-menu { display: none; } /* Здесь потом можно добавить бургер-меню */

    section { padding: 56px 0; }
    .section-title { margin-bottom: 32px; }
    .services-subtitle { margin-bottom: 32px; }
    .location-content { gap: 32px; }
    .location-map { height: 300px; }

    /* Шесть услуг в одну колонку занимали почти 2200 пикселей прокрутки */
    .services-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 12px; }
    .service-item { padding: 16px 4px; }
    .service-icon { width: 64px; height: 64px; margin-bottom: 12px; }
    .service-icon i { font-size: 26px; }
    .service-item h4 { font-size: 17px; }
    .service-item p { font-size: 14px; line-height: 1.5; }

    .contact-methods,
    .apartment-meta,
    .amenities-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-title { font-size: 32px; }
    .form { padding: 20px; }
}

/* =========================================
   12. СОВРЕМЕННАЯ СТРАНИЦА КВАРТИРЫ
   ========================================= */

/* Простая шапка */
.header-simple {
    position: sticky;
    top: 0;
    background: #fff;
    border-bottom: 1px solid #eee;
    z-index: 1000;
    padding: 15px 0;
}

.nav-simple {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
}

.logo {
    font-size: 22px;
    font-weight: 700;
    color: var(--color-primary);
    white-space: nowrap; /* иначе в тесной шапке домик уезжает на отдельную строку */
    flex-shrink: 0;
}

.nav-simple .nav-link {
    color: var(--color-text);
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    opacity: 1;
    text-transform: none;
    letter-spacing: 0;
}

.nav-simple .nav-link:hover {
    color: var(--color-secondary);
}

/* Длинная почта не помещается в шапку: остаётся аватар с инициалами */
@media (max-width: 1240px) {
    .nav-simple .user-info { display: none; }
}

.phone-simple {
    color: var(--color-primary);
    font-weight: 600;
    font-size: 16px;
}

/* Тёмная шапка .header: телефон белый на всех страницах. В светлой .header-simple остаётся тёмным */
.header .phone-simple {
    color: white;
}

/* Основная страница */
.apartment-page-modern {
    padding: 30px 0 60px;
    background: #f5f5f7;
    min-height: 100vh;
}

/* Заголовок квартиры */
.apartment-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.apartment-header h1 {
    font-size: 32px;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 8px;
}

.apartment-address {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--color-text-light);
    font-size: 15px;
}

.apartment-address i {
    color: var(--color-secondary);
}

.apartment-rating {
    display: flex;
    align-items: center;
    gap: 15px;
}

.rating-badge {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #e8f5e9;
    padding: 8px 15px;
    border-radius: 8px;
}

.rating-score {
    font-size: 18px;
    font-weight: 700;
    color: #2e7d32;
}

.rating-text {
    font-size: 14px;
    color: #2e7d32;
    font-weight: 500;
}

.reviews-count {
    color: var(--color-text-light);
    font-size: 14px;
}

/* Галерея */
.gallery-modern {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 10px;
    height: 450px;
    margin-bottom: 30px;
    border-radius: 12px;
    overflow: hidden;
}

.gallery-main-photo {
    position: relative;
    cursor: pointer;
    overflow: hidden;
    background: #000;
}

.gallery-main-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gallery-main-photo:hover img {
    transform: scale(1.02);
}

.gallery-side {
    display: flex;
    flex-direction: column;
    gap: 10px;
    position: relative;
}

.gallery-side-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    flex: 1;
}

.side-photo {
    overflow: hidden;
    cursor: pointer;
    background: #000;
}

.side-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.side-photo:hover img {
    transform: scale(1.05);
}

.all-photos-btn {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background: rgba(0,0,0,0.75);
    color: #fff;
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background 0.2s;
}

.all-photos-btn:hover {
    background: rgba(0,0,0,0.9);
}

/* Сетка контента */
.apartment-content-grid {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 30px;
    align-items: start;
}

/* Левая колонка */
.apartment-info-column {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.info-section {
    background: #fff;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.info-section h2 {
    font-size: 24px;
    margin-bottom: 20px;
    color: var(--color-primary);
    font-weight: 700;
}

.info-section h3 {
    font-size: 20px;
    margin-bottom: 15px;
    color: var(--color-primary);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.info-section h3 i {
    color: var(--color-secondary);
}

/* Характеристики */
.features-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    background: #fff;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: #f5f5f7;
    border-radius: 20px;
    font-size: 14px;
    color: var(--color-text);
    font-weight: 500;
}

.feature-item i {
    color: var(--color-text-light);
    font-size: 16px;
}

/* Описание */
.description-text {
    font-size: 16px;
    line-height: 1.7;
    color: var(--color-text);
}

/* Спальные места */
.beds-info {
    color: var(--color-text-light);
    margin-bottom: 20px;
    font-size: 14px;
}

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

.bed-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px;
    background: #f5f5f7;
    border-radius: 10px;
}

.bed-item i {
    font-size: 28px;
    color: var(--color-text-light);
}

.bed-item span {
    font-size: 14px;
    color: var(--color-text-light);
    margin-left: auto;
}

.bed-item p {
    font-size: 15px;
    font-weight: 500;
    color: var(--color-primary);
    margin: 0;
}

/* Удобства */
.amenities-grid-modern {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.amenity-tag {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: #f5f5f7;
    border-radius: 20px;
    font-size: 14px;
    color: var(--color-text);
}

.amenity-tag i {
    color: var(--color-text-light);
}

/* Детали по категориям */
.details-grid-3col {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.details-grid-3col p {
    padding: 8px 0;
    color: var(--color-text);
    font-size: 14px;
}

.details-grid-2col {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.details-grid-2col p {
    color: var(--color-text);
    font-size: 14px;
}

/* Правила */
.rules-info {
    margin-bottom: 20px;
}

.rule-time {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: #f5f5f7;
    border-radius: 20px;
    font-size: 14px;
    color: var(--color-text);
}

.rules-list-modern {
    list-style: none;
    margin-bottom: 20px;
}

.rules-list-modern li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #eee;
    font-size: 14px;
    color: var(--color-text);
}

.rules-list-modern li:last-child {
    border-bottom: none;
}

.rules-list-modern i {
    color: #e74c3c;
    font-size: 16px;
    margin-top: 2px;
}

.deposit-info {
    background: #fff8e1;
    padding: 15px;
    border-radius: 8px;
    border-left: 3px solid #ffc107;
}

.deposit-info strong {
    color: var(--color-primary);
    font-size: 14px;
}

.deposit-info p {
    color: var(--color-text-light);
    font-size: 13px;
    margin: 5px 0 0;
}

/* Карта */
.map-address {
    color: var(--color-secondary);
    margin-bottom: 15px;
    font-size: 14px;
}

.map-container-modern {
    border-radius: 10px;
    overflow: hidden;
    height: 400px;
    background: #eee;
}

.map-modern {
    width: 100%;
    height: 100%;
}

/* Отзывы */
.reviews-summary {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 30px;
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid #eee;
}

.reviews-overall {
    text-align: center;
}

.overall-score {
    font-size: 48px;
    font-weight: 700;
    color: #2e7d32;
    line-height: 1;
}

.overall-text {
    font-size: 16px;
    font-weight: 600;
    color: var(--color-primary);
    margin: 5px 0;
}

.overall-count {
    font-size: 13px;
    color: var(--color-text-light);
}

.reviews-bars {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.review-bar {
    display: grid;
    grid-template-columns: 1fr 120px 40px;
    align-items: center;
    gap: 15px;
    font-size: 14px;
}

.review-bar .bar {
    height: 6px;
    background: #eee;
    border-radius: 3px;
    overflow: hidden;
}

.review-bar .bar-fill {
    height: 100%;
    background: #2e7d32;
    border-radius: 3px;
}

.review-bar span:last-child {
    font-weight: 600;
    color: var(--color-primary);
}

.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.review-card {
    padding: 20px;
    background: #f5f5f7;
    border-radius: 10px;
}

.review-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.review-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--btn-primary, #d6393f);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 16px;
}

.review-author-info h5 {
    font-size: 15px;
    font-weight: 600;
    color: var(--color-primary);
    margin-bottom: 3px;
}

.review-meta {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 12px;
    color: var(--color-text-light);
}

.review-rating-badge {
    background: #e8f5e9;
    color: #2e7d32;
    padding: 3px 8px;
    border-radius: 10px;
    font-weight: 600;
}

.review-text {
    font-size: 14px;
    line-height: 1.6;
    color: var(--color-text);
}

/* Правая колонка - виджет бронирования */
.booking-sidebar {
    position: sticky;
    top: 90px;
}

.booking-widget-modern {
    background: #fff;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    margin-bottom: 20px;
}

.widget-price {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 20px;
}

.price-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--color-primary);
}

.price-period {
    font-size: 14px;
    color: var(--color-text-light);
}

.widget-price i {
    color: var(--color-text-light);
    font-size: 14px;
    cursor: help;
}

.booking-dates {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
}

.date-field {
    padding: 12px;
    border-right: 1px solid #ddd;
}

.date-field:last-child {
    border-right: none;
}

.date-field label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--color-primary);
    margin-bottom: 5px;
}

.date-field input {
    width: 100%;
    border: none;
    outline: none;
    font-size: 14px;
    color: var(--color-text);
    background: transparent;
    cursor: pointer;
}

.guests-field {
    margin-bottom: 15px;
}

.guests-field label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--color-primary);
    margin-bottom: 5px;
}

.guests-select {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
}

.guests-select i:first-child {
    color: var(--color-text-light);
}

.guests-select i:last-child {
    margin-left: auto;
    color: var(--color-text-light);
}

.phone-field {
    display: flex;
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 10px;
}

.country-code {
    padding: 12px 15px;
    background: #f5f5f7;
    border-right: 1px solid #ddd;
    font-size: 14px;
}

.phone-field input {
    flex: 1;
    border: none;
    outline: none;
    padding: 12px;
    font-size: 14px;
}

.phone-note {
    font-size: 12px;
    color: var(--color-text-light);
    margin-bottom: 20px;
    line-height: 1.4;
}

.book-button {
    width: 100%;
    padding: 15px;
    background: var(--color-primary);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: background 0.2s;
    margin-bottom: 15px;
}

.payment-info {
    text-align: center;
    font-size: 13px;
    color: var(--color-text-light);
    margin-bottom: 20px;
}

.cashback-info {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px;
    background: #fff3f0;
    border-radius: 8px;
    margin-bottom: 15px;
}

.cashback-icon {
    font-size: 28px;
}

.cashback-info strong {
    font-size: 14px;
    color: var(--color-primary);
    display: block;
}

.cashback-info p {
    font-size: 12px;
    color: var(--color-text-light);
    margin: 0;
}

.agreement-note {
    font-size: 11px;
    color: var(--color-text-light);
    line-height: 1.5;
    margin: 0;
}

.agreement-note a {
    color: var(--color-secondary);
    text-decoration: underline;
}

/* Карточка хозяина */
.owner-card {
    background: #fff;
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}
.owner-card[hidden] { display: none; }

.owner-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
    min-width: 0;
}

.owner-avatar {
    flex: 0 0 64px;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--btn-primary, #d6393f);
    color: #fff;
    font-size: 26px;
    font-weight: 600;
    line-height: 1;
}
.owner-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.owner-who { min-width: 0; }

.owner-header h4 {
    font-size: 18px;
    font-weight: 600;
    color: var(--color-primary);
    margin: 0 0 3px;
    overflow-wrap: anywhere;
}

.owner-status {
    font-size: 13px;
    color: var(--color-text-light);
    margin: 0;
}

.owner-info {
    list-style: none;
    margin: 0;
    padding: 18px 0 0;
    border-top: 1px solid #eee;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.owner-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 14px;
    color: var(--color-text);
    overflow-wrap: anywhere;
}

.owner-item i {
    color: var(--color-text-light);
    width: 16px;
    margin-top: 3px;
    flex: 0 0 16px;
}

/* Раздел «О хозяине» в профиле администратора */
.host-edit { max-width: 560px; }
.host-edit-avatar { display: flex; align-items: center; gap: 18px; margin-bottom: 22px; flex-wrap: wrap; }
.host-edit-avatar .owner-avatar { flex-basis: 84px; width: 84px; height: 84px; font-size: 34px; }
.host-edit-btns { display: flex; gap: 10px; flex-wrap: wrap; }
.host-edit .form-group { margin-bottom: 18px; }
.host-edit .form-group small { display: block; margin-top: 6px; color: #999; }
.host-status { margin-top: 14px; font-size: 14px; min-height: 20px; }
.host-status.ok { color: #2e7d32; }
.host-status.error { color: #c62828; }

/* Простой футер */
.footer-simple {
    background: #fff;
    padding: 20px 0;
    text-align: center;
    border-top: 1px solid #eee;
    color: var(--color-text-light);
    font-size: 14px;
}

/* Адаптивность */
@media (max-width: 1024px) {
    .apartment-content-grid {
        grid-template-columns: 1fr;
    }
    
    .booking-sidebar {
        position: static;
    }
    
    .gallery-modern {
        height: 350px;
    }
}

@media (max-width: 768px) {
    .nav-simple .nav-menu {
        display: none;
    }
    
    .gallery-modern {
        grid-template-columns: 1fr;
        height: auto;
    }
    
    .gallery-main-photo {
        height: 250px;
    }
    
    .gallery-side-grid {
        display: none;
    }
    
    .apartment-header {
        flex-direction: column;
    }
    
    .apartment-header h1 {
        font-size: 24px;
    }
    
    .reviews-summary {
        grid-template-columns: 1fr;
    }
    
    .details-grid-3col {
        grid-template-columns: 1fr;
    }
    
    .info-section {
        padding: 20px;
    }
}

/* =========================================
   13. ЛАЙТБОКС (ПРОСМОТР ФОТО)
   ========================================= */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.lightbox.active {
    display: flex;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 45px;
    height: 45px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    z-index: 10;
}

.lightbox-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.lightbox-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    z-index: 10;
}

.lightbox-arrow:hover {
    background: rgba(255, 255, 255, 0.25);
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 75vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 75vh;
    object-fit: contain;
    border-radius: 8px;
}

.lightbox-counter {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 13px;
    font-weight: 600;
}

/* Миниатюры в лайтбоксе */
.lightbox-thumbnails {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 10px;
    max-width: 80%;
    width: 600px;
}

.lightbox-thumbs-container {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 5px;
    flex: 1;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.3) transparent;
}

.lightbox-thumbs-container::-webkit-scrollbar {
    height: 6px;
}

.lightbox-thumbs-container::-webkit-scrollbar-track {
    background: transparent;
}

.lightbox-thumbs-container::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.3);
    border-radius: 3px;
}

.lightbox-thumb {
    flex-shrink: 0;
    width: 80px;
    height: 60px;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    opacity: 0.6;
    transition: all 0.2s;
}

.lightbox-thumb:hover {
    opacity: 1;
}

.lightbox-thumb.active {
    border-color: #fff;
    opacity: 1;
}

.lightbox-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.lightbox-thumb-arrow {
    flex-shrink: 0;
    width: 35px;
    height: 35px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.lightbox-thumb-arrow:hover {
    background: rgba(255, 255, 255, 0.25);
}

/* Адаптивность лайтбокса */
@media (max-width: 768px) {
    .lightbox-arrow {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    
    .lightbox-prev {
        left: 10px;
    }
    
    .lightbox-next {
        right: 10px;
    }
    
    .lightbox-close {
        top: 10px;
        right: 10px;
        width: 40px;
        height: 40px;
    }
    
    .lightbox-thumbnails {
        width: 90%;
        bottom: 10px;
    }
    
    .lightbox-thumb {
        width: 60px;
        height: 45px;
    }
    
    .lightbox-content img {
        max-height: 65vh;
    }
}

/* =========================================
   14. СЕЛЕКТОР ГОСТЕЙ
   ========================================= */
.guests-select {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    position: relative;
    background: #fff;
    transition: border-color 0.2s;
}

.guests-select:hover {
    border-color: var(--color-secondary);
}

.guests-select i:first-child {
    color: var(--color-text-light);
}

.guests-select i:last-child {
    margin-left: auto;
    color: var(--color-text-light);
    transition: transform 0.2s;
}

.guests-select.open i:last-child {
    transform: rotate(180deg);
}

/* Выпадающее окно */
.guests-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    z-index: 100;
    padding: 15px;
    animation: dropdownOpen 0.2s ease;
}

.guests-dropdown.active {
    display: block;
}

@keyframes dropdownOpen {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.guest-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid #eee;
}

.guest-row:last-of-type {
    border-bottom: none;
}

.guest-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.guest-info strong {
    font-size: 15px;
    color: var(--color-primary);
}

.guest-info span {
    font-size: 12px;
    color: var(--color-text-light);
}

/* Счётчики */
.guest-controls {
    display: flex;
    align-items: center;
    gap: 15px;
}

.guest-controls button {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid #ddd;
    background: #fff;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    color: var(--color-primary);
}

.guest-controls button:hover:not(:disabled) {
    border-color: var(--color-secondary);
    color: var(--color-secondary);
}

.guest-controls button:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.guest-controls span {
    font-size: 16px;
    font-weight: 600;
    min-width: 20px;
    text-align: center;
    color: var(--color-primary);
}

/* Переключатель (switch) для животных */
.switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 24px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: var(--color-secondary);
}

input:checked + .slider:before {
    transform: translateX(20px);
}

/* Плашка описания животного */
.pets-description {
    margin-top: 15px;
    padding: 15px;
    background: #fff8e1;
    border-radius: 10px;
    border-left: 3px solid #ffc107;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        max-height: 0;
    }
    to {
        opacity: 1;
        max-height: 300px;
    }
}

.pets-notice {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 13px;
    color: var(--color-text);
    margin: 0 0 12px 0;
    line-height: 1.5;
}

.pets-notice i {
    color: #ffc107;
    font-size: 16px;
    margin-top: 2px;
}

.pets-description textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    margin-bottom: 12px;
    outline: none;
    transition: border-color 0.2s;
}

.pets-description textarea:focus {
    border-color: var(--color-secondary);
}

.send-pet-request {
    width: 100%;
    padding: 12px;
    background: var(--color-primary);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.2s;
}

.send-pet-request:hover {
    background: #000;
}

.send-pet-request.sent {
    background: #2e7d32;
    pointer-events: none;
}

/* Кнопка "Готово" */
.guests-done {
    width: 100%;
    padding: 12px;
    background: #f5f5f7;
    color: var(--color-primary);
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 10px;
    transition: background 0.2s;
}

.guests-done:hover {
    background: #e5e5e7;
}

/* Родительский контейнер должен быть relative */
.guests-field {
    position: relative;
    margin-bottom: 15px;
}

.guests-field label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--color-primary);
    margin-bottom: 5px;
}

/* =========================================
   15. КАЛЕНДАРЬ БРОНИРОВАНИЯ
   ========================================= */
.booking-calendar-section {
    margin-bottom: 15px;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    background: #fff;
    transition: border-color 0.2s;
}

.calendar-header:hover {
    border-color: var(--color-secondary);
}

.calendar-trigger {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.calendar-trigger i {
    font-size: 24px;
    color: var(--color-text-light);
}

.calendar-trigger label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--color-primary);
    margin-bottom: 3px;
}

.selected-dates {
    font-size: 14px;
    color: var(--color-text);
    font-weight: 500;
}

.selected-dates .placeholder {
    color: var(--color-text-light);
}

.calendar-header i:last-child {
    color: var(--color-text-light);
    transition: transform 0.3s;
}

.calendar-header.active i:last-child {
    transform: rotate(180deg);
}

.calendar-dropdown {
    display: none;
    margin-top: 8px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    overflow: hidden;
    animation: dropdownOpen 0.3s ease;
}

.calendar-dropdown.active {
    display: block;
}

.calendar-wrapper {
    padding: 20px;
}

.calendar-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.calendar-nav button {
    width: 36px;
    height: 36px;
    border: none;
    background: #f5f5f7;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    color: var(--color-primary);
}

.calendar-nav button:hover {
    background: var(--color-secondary);
    color: #fff;
}

.calendar-nav span {
    font-size: 16px;
    font-weight: 600;
    color: var(--color-primary);
    text-transform: capitalize;
}

.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
    margin-bottom: 10px;
}

.calendar-weekdays div {
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: var(--color-text-light);
    padding: 8px 0;
}

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
}

.calendar-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}

.calendar-day:not(.empty):not(.booked) {
    background: #f5f5f7;
}

.calendar-day:not(.empty):not(.booked):hover {
    background: var(--color-secondary);
    color: #fff;
}

.calendar-day.booked {
    background: #ffebee;
    color: #c62828;
    cursor: not-allowed;
    opacity: 0.6;
}

.calendar-day.booked::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(45deg);
    width: 70%;
    height: 2px;
    background: #c62828;
}

.calendar-day.selected {
    background: var(--color-secondary);
    color: #fff;
    font-weight: 600;
}

.calendar-day.in-range {
    background: #ffe0b2;
}

.calendar-day.today {
    border: 2px solid var(--color-secondary);
}

.calendar-day.empty {
    cursor: default;
}

/* Легенда */
.calendar-legend {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--color-text-light);
}

.legend-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.legend-dot.available {
    background: #f5f5f7;
    border: 1px solid #ddd;
}

.legend-dot.booked {
    background: #ffebee;
    border: 1px solid #c62828;
}

.legend-dot.selected {
    background: var(--color-secondary);
}

/* Загрузка */
.calendar-loading {
    display: none;
    text-align: center;
    padding: 20px;
    color: var(--color-text-light);
}

.calendar-loading.active {
    display: block;
}

.calendar-loading i {
    font-size: 24px;
    margin-right: 10px;
    color: var(--color-secondary);
}

/* Адаптивность */
@media (max-width: 768px) {
    .calendar-wrapper {
        padding: 15px;
    }
    
    .calendar-legend {
        flex-direction: column;
        gap: 10px;
    }
}

/* =========================================
   16. ЯНДЕКС КАРТЫ
   ========================================= */
#main-map,
#apartment-map {
    width: 100%;
    height: 100%;
    min-height: 400px;
    border-radius: 10px;
    overflow: hidden;
}

.map-balloon h4 {
    margin: 0 0 10px 0;
    color: var(--color-primary);
    font-size: 16px;
}

.map-balloon p {
    margin: 0 0 10px 0;
    color: var(--color-text-light);
    font-size: 14px;
}

.map-link {
    display: inline-block;
    color: var(--color-secondary);
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
}

.map-link:hover {
    text-decoration: underline;
}

/* Контейнер для карты на главной */
.main-map-container {
    height: 500px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

/* Адаптивность */
@media (max-width: 768px) {
    .main-map-container {
        height: 350px;
    }
    
    #main-map,
    #apartment-map {
        min-height: 300px;
    }
}

/* Профиль пользователя на светлой шапке */
.user-profile-wrapper {
    background: #1f1f24 !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18) !important;
}

.user-email {
    color: white !important;
}

.user-role {
    color: rgba(255, 255, 255, 0.85) !important;
}

.user-avatar {
    background: rgba(255, 255, 255, 0.2) !important;
}

/* Кнопки «Войти» и «Выйти» оформлены в css/buttons.css */

/* ===== Календарь бронирования v2 (минимализм) ===== */
.calendar-days .calendar-day {
    border: 0;
    padding: 0;
    font: inherit;
    font-size: 14px;
    color: inherit;
    background: transparent;
    flex-direction: column;
    line-height: 1.1;
}
.calendar-days .calendar-day:not(.empty):not(.booked):not(.closed):not(.past):not(.dim):not(:disabled):hover {
    background: #f1f1f3;
    color: inherit;
}
.calendar-days .calendar-day.past,
.calendar-days .calendar-day.dim {
    color: #c4c4c9;
    cursor: default;
    background: transparent;
}
.calendar-days .calendar-day.booked {
    background: transparent;
    color: #b0b0b6;
    text-decoration: line-through;
    opacity: 1;
    cursor: not-allowed;
}
.calendar-days .calendar-day.booked::after { display: none; }
.calendar-days .calendar-day.closed {
    background: repeating-linear-gradient(135deg, #f3f3f5 0 4px, #fff 4px 8px);
    color: #b0b0b6;
    cursor: not-allowed;
}
.calendar-days .calendar-day.in-range { background: #f1f1f3; border-radius: 0; }
.calendar-days .calendar-day.selected {
    background: #1d1d1f;
    color: #fff;
    border-radius: 8px;
}
.calendar-days .calendar-day.today:not(.selected) { box-shadow: inset 0 0 0 1px #1d1d1f; }
.calendar-days .calendar-day .cal-price {
    font-size: 9px;
    margin-top: 2px;
    color: #8a8a90;
}
.calendar-days .calendar-day.selected .cal-price { color: #d0d0d4; }
.legend-dot.closed { background: repeating-linear-gradient(135deg, #e4e4e8 0 2px, #fff 2px 4px); border: 1px solid #d8d8dc; }
.legend-dot.selected { background: #1d1d1f; }
.calendar-nav button:disabled { opacity: .3; cursor: default; }

.booking-hint {
    margin: 10px 2px 0;
    font-size: 13px;
    color: #6e6e73;
    min-height: 18px;
}
.booking-hint.error { color: #c62828; }
.booking-summary { display: none; }
.booking-summary.active {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 12px 0 4px;
    padding: 12px 14px;
    border: 1px solid #e5e5e8;
    border-radius: 10px;
    font-size: 15px;
}
.booking-summary small { display: block; color: #8a8a90; font-size: 12px; margin-top: 2px; }
.booking-summary strong { font-size: 18px; }

/* ===== Окно подтверждения номера и успешной брони ===== */
.pc-lock { overflow: hidden; }
.pc-overlay {
    position: fixed; inset: 0; z-index: 10001;
    display: none; align-items: center; justify-content: center;
    background: rgba(0, 0, 0, .45); padding: 16px;
}
.pc-overlay.open { display: flex; }
.pc-box {
    position: relative; width: 100%; max-width: 400px;
    background: #fff; border-radius: 14px; padding: 28px 24px 22px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, .2);
}
.pc-close {
    position: absolute; top: 10px; right: 12px; border: 0; background: none;
    font-size: 26px; line-height: 1; color: #8a8a90; cursor: pointer;
}
.pc-title { margin: 0 0 8px; font-size: 20px; font-weight: 600; color: #1d1d1f; }
.pc-text, .pc-sent { margin: 0 0 16px; font-size: 14px; line-height: 1.45; color: #6e6e73; }
.pc-field { display: block; margin-bottom: 12px; font-size: 13px; color: #6e6e73; }
.pc-field[hidden], .pc-step[hidden] { display: none; }
.pc-field input {
    display: block; width: 100%; margin-top: 5px; padding: 11px 12px;
    border: 1px solid #d8d8dc; border-radius: 9px; font-size: 16px; color: #1d1d1f;
    box-sizing: border-box;
}
.pc-field input:focus { outline: none; border-color: #1d1d1f; }
.pc-code { letter-spacing: 4px; text-align: center; font-size: 20px !important; }
.pc-btn {
    width: 100%; padding: 12px; border: 0; border-radius: 9px;
    background: #1d1d1f; color: #fff; font-size: 15px; font-weight: 500; cursor: pointer;
}
.pc-btn:disabled { opacity: .5; cursor: default; }
.pc-links { display: flex; justify-content: space-between; margin-top: 12px; }
.pc-link {
    border: 0; background: none; padding: 4px 0; font-size: 13px;
    color: #6e6e73; cursor: pointer; text-decoration: underline;
}
.pc-link:disabled { opacity: .5; cursor: default; text-decoration: none; }
.pc-error { min-height: 18px; margin: 12px 0 0; font-size: 13px; color: #c62828; }
.pc-info { margin: 4px 0 18px; border-top: 1px solid #eee; }
.pc-info div { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid #eee; font-size: 14px; }
.pc-info span { color: #8a8a90; }
.pc-info strong { text-align: right; font-weight: 500; }
.pc-box > .pc-link { display: block; margin: 10px auto 0; }
.calendar-legend { flex-wrap: wrap; gap: 6px 14px; }

/* ===== Юридические страницы ===== */
.legal { padding: 50px 0 70px; background: #fff; }
.legal-body { max-width: 820px; }
.legal-body h2 { margin: 34px 0 12px; font-size: 21px; color: var(--color-primary); }
.legal-body p, .legal-body li { font-size: 16px; line-height: 1.7; color: #3a3a3d; }
.legal-body ul { padding-left: 22px; margin: 10px 0; }
.legal-body li { margin-bottom: 8px; }
.legal-body a { color: var(--color-secondary); }
.legal-date { color: #8a8a90; font-size: 14px; }
.legal-todo { background: #fff3b0; padding: 1px 6px; border-radius: 4px; font-size: 14px; }
.footer-legal { margin: 14px 0 4px; font-size: 14px; }
.footer-legal a { color: inherit; opacity: .85; text-decoration: underline; }
.consent-check { display: flex; gap: 8px; align-items: flex-start; margin: 12px 0; font-size: 13px; line-height: 1.4; color: #6e6e73; text-align: left; }
.consent-check input { margin-top: 2px; flex: 0 0 auto; width: auto; }
.consent-check a { color: inherit; text-decoration: underline; }
.contact-status { min-height: 20px; margin: 8px 0; font-size: 14px; }
.contact-status.ok { color: #2e7d32; }
.contact-status.error { color: #c62828; }
.pc-consent-field[hidden] { display: none; }

/* Забыли пароль */
.auth-forgot-link { display: block; text-align: center; margin-top: 12px; font-size: 14px; color: #6b6b70; text-decoration: none; }
.auth-forgot-link:hover { color: var(--color-primary); text-decoration: underline; }
.reset-page { padding: 60px 0 90px; background: #fff; }
.reset-card { max-width: 420px; margin: 0 auto; padding: 0 16px; }
.reset-card h2 { margin: 0 0 10px; font-size: 24px; color: var(--color-primary); }
.reset-card p { color: #3a3a3d; line-height: 1.6; }
.reset-card .form-group { margin: 18px 0; }
.reset-card label { display: block; margin-bottom: 6px; font-size: 14px; color: #3a3a3d; }
.reset-card input { width: 100%; box-sizing: border-box; padding: 12px 14px; border: 1px solid #d5d5d9; border-radius: 8px; font-size: 16px; }
.reset-card .auth-submit-btn { width: 100%; }
.reset-status { margin-top: 16px; padding: 12px 14px; border-radius: 8px; font-size: 15px; display: none; }
.reset-status.show { display: block; }
.reset-status.ok { background: #e8f5e9; color: #2e7d32; }
.reset-status.err { background: #fdecea; color: #c62828; }
.reset-back { display: block; text-align: center; margin-top: 18px; color: #6b6b70; }
/* Длинные заголовки баннера не должны раздвигать страницу на телефоне */
.page-banner h1 { overflow-wrap: anywhere; }
@media (max-width: 480px) {
    .page-banner { height: 240px; }
    .page-banner h1 { font-size: 24px; letter-spacing: 1px; padding: 0 4px; }
}

/* Страница квартиры на телефоне: колонки не шире экрана */
.apartment-info-column, .booking-sidebar { min-width: 0; }
@media (max-width: 1024px) {
    .apartment-content-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 768px) {
    .reviews-summary, .details-grid-3col { grid-template-columns: minmax(0, 1fr); }
    .reviews-summary > * { min-width: 0; }
}
.reviews-summary-inner { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 50px; align-items: stretch; }
@media (max-width: 768px) {
    .reviews-summary-inner { grid-template-columns: minmax(0, 1fr); gap: 24px; }
}
/* Длинные слова в отзывах переносятся, а не растягивают страницу */
.reviews-list { overflow-wrap: anywhere; }
.reviews-list div { min-width: 0; }


/* =========================================
   СОСТОЯНИЯ ИНТЕРФЕЙСА, КНОПКИ, КАРТОЧКИ, 404
   ========================================= */
.ui-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    min-height: 44px; padding: 0 22px; border-radius: 8px;
    font-size: 15px; font-weight: 600; line-height: 1; text-decoration: none;
    border: 1px solid transparent; cursor: pointer; font-family: inherit;
    transition: background .2s, color .2s, border-color .2s, box-shadow .2s;
}
.ui-btn:focus-visible { outline: 3px solid rgba(255,107,107,.45); outline-offset: 2px; }
.ui-btn:disabled { opacity: .6; cursor: default; }
.ui-btn-primary { background: var(--color-secondary); color: #fff; }
.ui-btn-primary:hover:not(:disabled) { background: #f55757; }
.ui-btn-ghost { background: #fff; color: var(--color-primary); border-color: #d5d5da; }
.ui-btn-ghost:hover { border-color: var(--color-primary); }

/* Скелетоны */
.ui-skel {
    background: linear-gradient(90deg, #ececf0 25%, #f6f6f9 37%, #ececf0 63%);
    background-size: 400% 100%;
    animation: ui-shimmer 1.4s ease infinite;
    border-radius: 6px;
}
@keyframes ui-shimmer { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }
@media (prefers-reduced-motion: reduce) { .ui-skel { animation: none; } }
.ui-skel-card { pointer-events: none; cursor: default; }
.ui-skel-card:hover { transform: none; box-shadow: 0 5px 20px rgba(0,0,0,0.1); }
.ui-skel-img { height: 250px; border-radius: 0; }
.ui-skel-info { padding: 25px; display: grid; gap: 12px; }
.ui-skel-block { display: grid; gap: 12px; padding: 8px 0; }
.ui-skel-line { height: 14px; }
.ui-w40 { width: 40%; } .ui-w60 { width: 60%; } .ui-w75 { width: 75%; } .ui-w90 { width: 90%; }

/* Ошибка и пустой список */
.ui-state {
    grid-column: 1 / -1;
    text-align: center; padding: 48px 20px; color: var(--color-text-light);
}
.ui-state > i { font-size: 38px; color: #b9b9c3; margin-bottom: 14px; display: block; }
.ui-state-error > i { color: var(--color-secondary); }
.ui-state-title { font-size: 20px; color: var(--color-primary); margin: 0 0 8px; }
.ui-state-text { margin: 0 auto 20px; max-width: 420px; font-size: 15px; line-height: 1.5; }

/* Карточка квартиры на главной: целиком ссылка */
a.apartment-card { display: block; color: inherit; text-decoration: none; }
a.apartment-card:focus-visible { outline: 3px solid rgba(255,107,107,.55); outline-offset: 3px; }
.apartment-image { background: #e9e9ee; }
.apt-noimage {
    position: absolute; inset: 0; display: none; align-items: center; justify-content: center;
    flex-direction: column; gap: 8px; background: #ececf0; color: #9a9aa6; font-size: 13px;
}
.apt-noimage i { font-size: 34px; }
.apartment-image.is-empty .apt-noimage { display: flex; }
.apartment-image.is-empty img { display: none; }
.apt-rating {
    position: absolute; left: 15px; top: 15px; display: inline-flex; align-items: center; gap: 5px;
    background: rgba(255,255,255,.95); color: var(--color-primary);
    padding: 6px 10px; border-radius: 16px; font-size: 13px; font-weight: 700;
    box-shadow: 0 2px 8px rgba(0,0,0,.15);
}
.apt-rating i { color: #f5a623; font-size: 12px; }
.apt-rating small { font-weight: 500; color: var(--color-text-light); }
.apt-facts { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 0 0 12px; padding: 0; list-style: none; font-size: 13px; color: var(--color-text-light); }
.apt-facts li { display: inline-flex; align-items: center; gap: 6px; }
.apt-facts i { color: var(--color-secondary); width: 14px; text-align: center; }
.apt-price-row { display: flex; align-items: baseline; gap: 6px; margin-top: 14px; padding-top: 14px; border-top: 1px solid #eee; }
.apt-price-from { font-size: 13px; color: var(--color-text-light); }
.apt-price-value { font-size: 24px; font-weight: 800; color: var(--color-primary); }
.apt-price-unit { font-size: 14px; color: var(--color-text-light); }
.apartment-info .apartment-desc {
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

/* Страница 404 */
.notfound { min-height: 70vh; display: flex; align-items: center; padding: 140px 0 80px; background: #fff; }
.notfound-inner { text-align: center; }
.notfound-code { font-size: clamp(88px, 22vw, 170px); font-weight: 800; line-height: 1; color: #ececf0; letter-spacing: -2px; }
.notfound h1 { font-size: clamp(24px, 5vw, 34px); margin: 10px 0 12px; color: var(--color-primary); }
.notfound p { color: var(--color-text-light); max-width: 460px; margin: 0 auto 28px; line-height: 1.6; }
.notfound-actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }

/* Страница квартиры: «не найдена» / ошибка загрузки */
.apartment-page-modern.has-problem > *:not(#apartment-problem) { display: none !important; }
.apartment-problem { padding-top: 150px; padding-bottom: 90px; min-height: 60vh; }
.ui-btn-sm { min-height: 32px; padding: 0 12px; font-size: 13px; border-radius: 6px; margin-left: 6px; }
.ui-skel-day { height: 38px; border-radius: 8px; }


/* ===== Окно «Заявка принята» / «Бронь подтверждена» ===== */
.done-box { max-height: 92vh; overflow-y: auto; text-align: left; }
.done-icon { width: 56px; height: 56px; margin: 0 auto 12px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 28px; font-weight: 700; color: #fff; background: #12793f; }
.done-icon.is-wait { background: #b25e00; }
.done-title, .done-lead { text-align: center; }
.done-number { display: flex; align-items: center; gap: 10px; margin: 0 0 14px; padding: 10px 12px; background: #f6f6f8; border-radius: 10px; font-size: 14px; }
.done-number span { color: #6e6e73; }
.done-number strong { font-size: 18px; margin-right: auto; }
.done-copy { border: 0; background: none; color: #d6393f; font-size: 13px; text-decoration: underline; cursor: pointer; padding: 6px; min-height: 36px; }
.done-pay { margin-top: -6px; }
.done-pay div:last-child { border-bottom: 0; }
.done-next { margin: 0 0 14px; padding: 12px 14px; background: #f6f6f8; border-radius: 10px; font-size: 13px; line-height: 1.5; color: #3a3a3d; }
.done-next ul { margin: 6px 0 0; padding-left: 18px; }
.done-next li + li { margin-top: 4px; }
a.pc-btn.done-call { display: flex; align-items: center; justify-content: center; text-decoration: none; box-sizing: border-box; }
.done-box .pc-link { display: block; margin: 10px auto 0; }
.done-box .pc-info strong { overflow-wrap: anywhere; }
.done-box:focus { outline: none; }

/* ===== Шаги бронирования и итог цены ===== */
.booking-steps { list-style: none; margin: 0 0 14px; padding: 0; display: flex; gap: 6px; }
.booking-steps li { flex: 1 1 0; min-width: 0; display: flex; align-items: center; gap: 6px; padding: 8px 8px; border-radius: 10px; background: #f6f6f8; color: #6e6e73; font-size: 12px; line-height: 1.2; }
.booking-steps .bs-num { flex: 0 0 22px; width: 22px; height: 22px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: #dcdce2; color: #3a3a3d; font-size: 12px; font-weight: 700; }
.booking-steps .bs-text { min-width: 0; overflow-wrap: anywhere; }
.booking-steps li.is-current { background: #fdeaea; color: #1a1a1a; font-weight: 600; }
.booking-steps li.is-current .bs-num { background: #d6393f; color: #fff; }
.booking-steps li.is-done { color: #12793f; }
.booking-steps li.is-done .bs-num { background: #12793f; color: transparent; position: relative; }
.booking-steps li.is-done .bs-num::after { content: '✓'; position: absolute; color: #fff; }
.booking-summary .bs-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.booking-summary .bs-pay { margin-top: 10px; padding-top: 10px; border-top: 1px dashed #dcdce2; font-size: 13px; }
.booking-summary .bs-pay div { display: flex; justify-content: space-between; gap: 12px; padding: 2px 0; }
.booking-summary .bs-pay span { color: #6e6e73; }
.booking-summary .bs-nights { margin-top: 8px; font-size: 13px; }
.booking-summary .bs-nights summary { cursor: pointer; color: #6e6e73; min-height: 28px; }
.booking-summary .bs-nights ul { list-style: none; margin: 4px 0 0; padding: 0; max-height: 160px; overflow-y: auto; }
.booking-summary .bs-nights li { display: flex; justify-content: space-between; padding: 3px 0; }
@media (max-width: 400px) {
    .booking-steps li { flex-direction: column; align-items: flex-start; gap: 4px; }
}
.booking-summary.active { display: block; }

/* Переход «Забронировать снова»: виджет не должен прятаться под закреплённой шапкой */
#booking-widget { scroll-margin-top: 90px; }
