/* ============================================
   STICKY HEADER
   ============================================ */

.header {
    transition: box-shadow 0.3s ease;
}

.header--sticky {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    margin-top: 0 !important;
    z-index: 10000;
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.12);
    animation: headerSlideDown 0.25s ease;
}

@keyframes headerSlideDown {
    from { transform: translateY(-100%); }
    to   { transform: translateY(0); }
}

/* ============================================
   МОДАЛЬНОЕ ОКНО ОБЪЕКТОВ (АДАПТИВНОЕ)
   ============================================ */

/* Оверлей модального окна */
.modal.object-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    padding: 20px;
    overflow-y: auto;
}

.modal.object-modal.open {
    opacity: 1;
    visibility: visible;
}

/* Окно модального окна */
.object-modal__window {
    position: relative;
    width: 100%;
    max-width: 900px;
    max-height: 90vh;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    transform: translateY(-20px);
    transition: transform 0.3s ease;
}

.modal.object-modal.open .object-modal__window {
    transform: translateY(0);
}

/* Обертка контента */
.object-modal__wrapper {
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    padding: 0;
}

.object-modal__wrapper::-webkit-scrollbar {
    width: 8px;
}

.object-modal__wrapper::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.object-modal__wrapper::-webkit-scrollbar-thumb {
    background: #098594;
    border-radius: 4px;
}

/* Галерея */
.object-modal__gallery {
    position: relative;
    width: 100%;
    height: 400px;
}

.object-modal__gallery-img {
    height: 400px;
    overflow: hidden;
}

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

.object-modal__gallery--onlyone {
    height: 400px;
}

.object-modal__gallery--onlyone .swiper-slide {
    height: 100%;
}

/* Пагинация и стрелки */
.object-modal__pagination {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.object-modal__arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.3s ease;
}

.object-modal__arrow:hover {
    background: #fff;
}

.object-modal__arrow.prev {
    left: 15px;
}

.object-modal__arrow.next {
    right: 15px;
}

/* Контент */
.object-modal__content {
    padding: 30px;
}

.object-modal__title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 15px;
    color: #333;
}

.object-modal__text-content {
    margin-bottom: 20px;
}

.object-modal__text {
    font-size: 16px;
    line-height: 1.6;
    color: #666;
}

/* Теги */
.object-modal__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}

.object-modal__tags .components__tag {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 8px 12px;
    background: #f5f5f5;
    border-radius: 20px;
    font-size: 14px;
    color: #333;
}

.object-modal__tags .components__tag img {
    width: 16px;
    height: 16px;
}

/* Цена */
.object-modal__price {
    font-size: 20px;
    font-weight: 700;
    color: #098594;
    margin-bottom: 20px;
}

/* Кнопка */
.object-modal__btn {
    display: inline-block;
    padding: 12px 30px;
    background: #098594;
    color: #fff;
    border-radius: 8px;
    font-weight: 600;
    font-size: 16px;
    transition: background 0.3s ease;
    cursor: pointer;
    border: none;
}

.object-modal__btn:hover {
    background: #0C4644;
}

/* Кнопка закрытия */
.modal__close {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 100;
    transition: background 0.3s ease;
}

.modal__close:hover {
    background: #fff;
}

.modal__close img {
    width: 20px;
    height: 20px;
}

/* ============================================
   АДАПТИВ ДЛЯ ПЛАНШЕТОВ (768px - 1024px)
   ============================================ */
@media (max-width: 1024px) {
    .modal.object-modal {
        padding: 15px;
    }

    .object-modal__window {
        max-width: 800px;
        max-height: 85vh;
    }

    .object-modal__gallery {
        height: 350px;
    }

    .object-modal__gallery-img {
        height: 350px;
    }

    .object-modal__gallery--onlyone {
        height: 350px;
    }

    .object-modal__content {
        padding: 25px;
    }

    .object-modal__title {
        font-size: 22px;
    }

    .object-modal__text {
        font-size: 15px;
    }
}

/* ============================================
   АДАПТИВ ДЛЯ МОБИЛЬНЫХ (< 768px)
   ============================================ */
@media (max-width: 768px) {
    .modal.object-modal {
        padding: 0;
        align-items: flex-end;
    }

    .object-modal__window {
        max-width: 100%;
        max-height: 95vh;
        border-radius: 12px 12px 0 0;
        transform: translateY(100%);
    }

    .modal.object-modal.open .object-modal__window {
        transform: translateY(0);
    }

    .object-modal__wrapper {
        max-height: 95vh;
    }

    .object-modal__gallery {
        height: 280px;
    }

    .object-modal__gallery-img {
        height: 280px;
    }

    .object-modal__gallery--onlyone {
        height: 280px;
    }

    .object-modal__arrow {
        width: 40px;
        height: 40px;
    }

    .object-modal__arrow.prev {
        left: 10px;
    }

    .object-modal__arrow.next {
        right: 10px;
    }

    .object-modal__content {
        padding: 20px;
    }

    .object-modal__title {
        font-size: 20px;
    }

    .object-modal__text {
        font-size: 14px;
    }

    .object-modal__tags {
        gap: 8px;
    }

    .object-modal__tags .components__tag {
        padding: 6px 10px;
        font-size: 13px;
    }

    .object-modal__price {
        font-size: 18px;
    }

    .object-modal__btn {
        width: 100%;
        padding: 14px 20px;
        font-size: 15px;
    }

    .modal__close {
        top: 10px;
        right: 10px;
        width: 35px;
        height: 35px;
    }

    .modal__close img {
        width: 18px;
        height: 18px;
    }
}

/* ============================================
   АДАПТИВ ДЛЯ МАЛЕНЬКИХ МОБИЛЬНЫХ (< 480px)
   ============================================ */
@media (max-width: 480px) {
    .object-modal__gallery {
        height: 220px;
    }

    .object-modal__gallery-img {
        height: 220px;
    }

    .object-modal__gallery--onlyone {
        height: 220px;
    }

    .object-modal__content {
        padding: 15px;
    }

    .object-modal__title {
        font-size: 18px;
    }

    .object-modal__text {
        font-size: 13px;
    }

    .object-modal__tags .components__tag {
        padding: 5px 8px;
        font-size: 12px;
    }

    .object-modal__price {
        font-size: 16px;
    }

    .object-modal__btn {
        padding: 12px 15px;
        font-size: 14px;
    }
}

/* ============================================
   ГОРИЗОНТАЛЬНАЯ ОРИЕНТАЦИЯ МОБИЛЬНЫХ
   ============================================ */
@media (max-height: 500px) and (orientation: landscape) {
    .modal.object-modal {
        align-items: center;
    }

    .object-modal__window {
        max-height: 90vh;
    }

    .object-modal__gallery {
        height: 180px;
    }

    .object-modal__gallery-img {
        height: 180px;
    }

    .object-modal__gallery--onlyone {
        height: 180px;
    }

    .object-modal__content {
        padding: 15px;
    }
}

/* ============================================
   HERO ВИДЖЕТЫ (REQUEST + PROFILE)
   Закреплены справа внизу на всех экранах
   ============================================ */

/* Виджет запроса - КНОПКА СНИЗУ СПРАВА */
.hero__request {
    position: fixed;
    right: 15px;
    bottom: 110px;
    width: auto;
    max-width: 280px;
    background: #ffffff;
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    z-index: 1001;
    display: none;
}

.hero__request.visible {
    display: block !important;
}

/* Кнопка закрытия */
.hero__request-close {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 24px;
    height: 24px;
    background: #f5f5f5;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
    padding: 0;
    z-index: 10;
}

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

.hero__request-close svg {
    width: 12px;
    height: 12px;
}

.hero__request-text {
    margin: 0 0 10px 0;
    padding-right: 20px;
    font-size: 12px;
    line-height: 1.4;
    color: #333;
}

.hero__request-text b {
    font-weight: 700;
    display: block;
    margin-bottom: 4px;
    font-size: 13px;
}

.hero__request-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 8px 12px;
    background: #098594;
    color: #fff;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 12px;
    transition: background 0.3s ease, transform 0.2s ease;
    gap: 6px;
}

.hero__request-btn:hover {
    background: #0C4644;
    transform: scale(1.02);
}

.hero__request-btn:active {
    transform: scale(0.98);
}

.hero__request-btn img {
    width: 30px;
    height: 30px;
    flex-shrink: 0;
}

/* Кнопка профиля - КРУГЛАЯ ИКОНКА ВНИЗУ СПРАВА */
.hero__profile {
    position: fixed;
    right: 15px;
    bottom: 15px;
    width: 56px;
    height: 56px;
    z-index: 1002;
    cursor: pointer;
}

.hero__profile-inner {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    background: #f5f5f5;
}

.hero__profile-inner:hover {
    transform: scale(1.08);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.hero__profile-inner:active {
    transform: scale(0.95);
}

.hero__profile-inner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

/* ============================================
   АДАПТИВ ДЛЯ ПЛАНШЕТОВ (768px - 1024px)
   ============================================ */
@media (min-width: 769px) and (max-width: 1024px) {
    .hero__request {
        right: 85px;
        bottom: 105px;
        max-width: 300px;
        padding: 16px;
    }

    .hero__profile {
        right: 20px;
        bottom: 20px;
        width: 60px;
        height: 60px;
    }
}

/* ============================================
   АДАПТИВ ДЛЯ ДЕСКТОПА (> 1024px)
   ============================================ */
@media (min-width: 1025px) {
    .hero__request {
        right: 15px;
        bottom: 115px;
        max-width: 300px;
        padding: 16px;
    }

    .hero__request-text {
        font-size: 13px;
    }

    .hero__request-text b {
        font-size: 14px;
    }

    .hero__request-btn {
        padding: 0px 14px;
        font-size: 13px;
    }

    .hero__profile {
        right: 90px;
        bottom: 20px;
        width: 80px;
        height: 80px;
    }
}

/* ============================================
   АДАПТИВ ДЛЯ МОБИЛЬНЫХ (< 768px)
   ============================================ */
@media (max-width: 768px) {
    .hero__request {
        right: 12px;
        bottom: 75px;
        max-width: 260px;
        padding: 12px;
        border-radius: 12px;
    }

    .hero__request-close {
        top: 6px;
        right: 6px;
        width: 22px;
        height: 22px;
    }

    .hero__request-close svg {
        width: 10px;
        height: 10px;
    }

    .hero__request-text {
        font-size: 11px;
        margin-bottom: 8px;
    }

    .hero__request-text b {
        font-size: 12px;
    }

    .hero__request-btn {
        padding: 0px 12px;
        font-size: 11px;
    }

    .hero__request-btn img {
        width: 14px;
        height: 14px;
    }

    .hero__profile {
        right: 12px;
        bottom: 12px;
        width: 50px;
        height: 50px;
    }
}

/* ============================================
   АДАПТИВ ДЛЯ МАЛЕНЬКИХ МОБИЛЬНЫХ (< 480px)
   ============================================ */
@media (max-width: 480px) {
    .hero__request {
        right: 10px;
        bottom: 72px;
        max-width: 260px;
        padding: 12px;
        border-radius: 12px;
    }

    .hero__request-text {
        font-size: 11px;
        margin-bottom: 8px;
    }

    .hero__request-text b {
        font-size: 12px;
    }

    .hero__request-btn {
        padding: 9px 12px;
        font-size: 11px;
        border-radius: 8px;
    }

    .hero__request-btn img {
        width: 15px;
        height: 15px;
    }

    .hero__profile {
        right: 10px;
        bottom: 10px;
        width: 46px;
        height: 46px;
    }
}

/* ============================================
   ГОРИЗОНТАЛЬНАЯ ОРИЕНТАЦИЯ
   ============================================ */
@media (max-height: 500px) and (orientation: landscape) {
    .hero__request {
        right: 10px;
        bottom: 60px;
        max-width: 250px;
        padding: 10px;
    }

    .hero__profile {
        right: 10px;
        bottom: 8px;
        width: 42px;
        height: 42px;
    }
}
