/* --- Адаптивная вёрстка для страницы пляжа --- */

/* Базовые настройки для планшетов и десктопов */
@media (max-width: 1280px) {
    .b-main {
        padding: 0 20px 50px;
    }
    
    .b-text4 {
        padding: 30px 35px;
        margin-left: auto;
        margin-right: auto;
    }
    
    .map-wrapper {
        margin: 0 10px;
    }
}

/* Показываем кнопку меню и скрываем навигацию при ширине меньше 1200px */
@media (max-width: 1200px) {
    .headerLine {
        justify-content: flex-end;
    }
    
    .nav {
        display: none;
    }
    
    .nav-button {
        display: block;
        position: relative;
        z-index: 1001;
        background: rgba(255, 255, 255, 0.2);
        backdrop-filter: blur(8px);
        border: none;
        cursor: pointer;
        padding: 12px;
        border-radius: 12px;
        transition: all 0.3s ease;
        margin-left: auto;
    }
    
    .nav-button:hover {
        background: rgba(255, 255, 255, 0.3);
        transform: scale(1.05);
    }
    
    .but-in-img {
        width: 28px;
        height: 28px;
        display: block;
        filter: brightness(0) invert(1);
    }
    
    /* Открытое меню */
    .headerLine.open .nav {
        display: flex !important;
        flex-direction: column;
        position: fixed;
        top: 0;
        right: 0;
        bottom: 0;
        width: 300px;
        background: linear-gradient(135deg, #1e2a2a 0%, #2c3e3e 100%);
        backdrop-filter: blur(20px);
        z-index: 1000;
        padding: 100px 30px 40px;
        gap: 20px;
        animation: slideInRight 0.3s ease-out;
        border-radius: 0;
        margin: 0;
        box-shadow: -5px 0 25px rgba(0, 0, 0, 0.2);
    }
    
    @keyframes slideInRight {
        from {
            opacity: 0;
            transform: translateX(100%);
        }
        to {
            opacity: 1;
            transform: translateX(0);
        }
    }
    
    .headerLine.open .navitem {
        color: #fff;
        font-size: 20px;
        font-weight: 500;
        padding: 12px 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.2);
        text-align: left;
        letter-spacing: 1px;
        transition: all 0.3s ease;
    }
    
    .headerLine.open .navitem:hover {
        color: #e6c87a;
        border-bottom-color: #e6c87a;
        padding-left: 10px;
    }
    
    .headerLine.open .navitem::after {
        display: none;
    }
    
    /* Кнопка закрытия в открытом меню */
    .headerLine.open .nav-button {
        position: fixed;
        top: 20px;
        right: 20px;
        z-index: 1002;
        background: rgba(255, 255, 255, 0.2);
    }
    
    .headerLine.open .nav-button .but-in-img {
        filter: brightness(0) invert(1);
    }
    
    /* Скрываем телефон в мобильной версии */
    .phone {
        display: none;
    }
    
    /* Исправляем наслоение и центрируем текст */
    .b-section-first {
        margin-top: 30px;
        text-align: center;
    }
    
    .b-text3 {
        margin-top: 0;
        font-size: 42px;
        position: relative;
        z-index: 1;
        text-align: center;
        display: block;
    }
    
    .b-text4 {
        margin: 0 auto 50px auto;
        font-size: 18px;
        padding: 28px 30px;
        text-align: center;
        max-width: 800px;
    }
    
    .text8 {
        font-size: 38px;
        text-align: center;
    }
    
    .b-map {
        width: 100%;
        height: 400px;
    }
    
    .sec-nav {
        margin-left: 0;
    }
}

/* Планшеты (768px - 1200px) */
@media (max-width: 992px) {
    .hero-title {
        font-size: 44px;
    }
    
    .b-text3 {
        font-size: 48px;
    }
    
    .b-text4 {
        font-size: 17px;
        padding: 25px 28px;
    }
    
    .text8 {
        font-size: 36px;
    }
    
    .swiper-button-prev,
    .swiper-button-next {
        width: 36px;
        height: 36px;
        background: transparent !important;
        backdrop-filter: none;
    }
    
    .swiper-button-prev::after,
    .swiper-button-next::after {
        font-size: 28px;
        color: rgba(255, 255, 255, 0.8);
    }
    
    .swiper-button-prev:hover::after,
    .swiper-button-next:hover::after {
        color: #c4a15b;
    }
}

/* Мобильные устройства (до 768px) */
@media (max-width: 768px) {
    .header {
        height: 60vh;
        min-height: 450px;
    }
    
    .hero-title {
        font-size: 32px;
    }
    
    .b-main {
        padding: 0 15px 40px;
    }
    
    .b-section-first {
        margin-top: 20px;
        text-align: center;
    }
    
    .b-text3 {
        font-size: 36px;
        text-align: center;
    }
    
    .b-text3::after {
        width: 50px;
        margin-top: 15px;
    }
    
    .b-text4 {
        font-size: 15px;
        padding: 20px 20px;
        margin: 0 auto 40px auto;
        border-radius: 20px;
        text-align: center;
    }
    
    .text8 {
        font-size: 30px;
        margin-bottom: 25px;
        text-align: center;
    }
    
    .b-block1 {
        margin-bottom: 50px;
    }
    
    .b-map {
        height: 320px;
    }
    
    .map-wrapper {
        border-radius: 20px;
        margin: 0;
    }
    
    /* Стрелки слайдера без кружочков */
    .swiper-button-prev,
    .swiper-button-next {
        width: 32px;
        height: 32px;
        background: transparent !important;
        backdrop-filter: none;
    }
    
    .swiper-button-prev::after,
    .swiper-button-next::after {
        font-size: 24px;
        color: rgba(255, 255, 255, 0.8);
    }
    
    .swiper-button-prev {
        left: 10px !important;
    }
    
    .swiper-button-next {
        right: 10px !important;
    }
    
    /* Футер по левой стороне */
    .footerLine {
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
        gap: 35px;
        padding-bottom: 30px;
    }
    
    .sec-nav,
    .third-nav {
        text-align: left;
        margin: 0;
        padding: 0;
    }
    
    .footer-list {
        padding: 0;
        list-style: none;
    }
    
    .footer-list li {
        margin-bottom: 10px;
    }
    
    .adres p {
        margin-top: 8px;
    }
}

/* Маленькие мобильные устройства (до 576px) */
@media (max-width: 576px) {
    .header {
        height: 55vh;
        min-height: 400px;
    }
    
    .hero-title {
        font-size: 28px;
    }
    
    .b-section-first {
        margin-top: 15px;
        text-align: center;
    }
    
    .b-text3 {
        font-size: 32px;
        text-align: center;
    }
    
    .b-text4 {
        font-size: 14px;
        padding: 18px 16px;
        margin: 0 auto 35px auto;
        border-radius: 20px;
    }
    
    .text8 {
        font-size: 26px;
        text-align: center;
    }
    
    .b-map {
        height: 280px;
    }
    
    .swiper-pagination-bullet {
        width: 8px;
        height: 8px;
    }
    
    .swiper-pagination-bullet-active {
        width: 20px;
    }
    
    .last-zag h2 {
        font-size: 20px;
    }
    
    .btn-primary {
        padding: 10px 28px;
        font-size: 14px;
    }
    
    /* Футер по левой стороне */
    .footerLine {
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
        gap: 35px;
    }
    
    .sec-nav,
    .third-nav {
        text-align: left;
        width: 100%;
    }
    
    .footer-list {
        padding: 0;
    }
    
    .foot-zag,
    .foot-zag-sec {
        font-size: 18px;
        margin-bottom: 15px;
    }
    
    .navitem2,
    .foot-num,
    .foot-mail,
    .adres p,
    .text-foot1,
    .text-mail {
        font-size: 13px;
    }
}

/* Очень маленькие телефоны (до 480px) */
@media (max-width: 480px) {
    .hero-title {
        font-size: 24px;
    }
    
    .b-text3 {
        font-size: 28px;
    }
    
    .b-text4 {
        font-size: 13px;
        padding: 16px 14px;
    }
    
    .text8 {
        font-size: 24px;
    }
    
    .swiper-button-prev,
    .swiper-button-next {
        width: 28px;
        height: 28px;
    }
    
    .swiper-button-prev::after,
    .swiper-button-next::after {
        font-size: 20px;
    }
    
    .last-zag h2 {
        font-size: 18px;
    }
    
    .btn-primary {
        padding: 8px 24px;
        font-size: 13px;
    }
    
    .footerLine {
        gap: 30px;
    }
}

/* Горизонтальная ориентация на мобильных */
@media (max-width: 768px) and (orientation: landscape) {
    .header {
        height: 85vh;
        min-height: 350px;
    }
    
    .hero-title {
        font-size: 28px;
    }
    
    .b-section-first {
        margin-top: 10px;
        text-align: center;
    }
    
    .b-text3 {
        font-size: 32px;
    }
    
    .b-text4 {
        margin-bottom: 30px;
    }
    
    .swiper-button-prev,
    .swiper-button-next {
        transform: translateY(0);
        top: 50%;
    }
    
    .footerLine {
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
    }
}

/* Планшеты в альбомной ориентации */
@media (min-width: 769px) and (max-width: 1024px) and (orientation: landscape) {
    .header {
        height: 70vh;
    }
    
    .hero-title {
        font-size: 48px;
    }
    
    .b-section-first {
        margin-top: 20px;
        text-align: center;
    }
    
    .b-text3 {
        font-size: 48px;
    }
    
    .b-text4 {
        font-size: 18px;
        padding: 30px 40px;
    }
    
    .footerLine {
        flex-direction: row;
        justify-content: flex-start;
        gap: 50px;
    }
}

/* Большие экраны */
@media (min-width: 1920px) {
    .b-main {
        max-width: 1400px;
    }
    
    .hero-title {
        font-size: 64px;
    }
    
    .b-section-first {
        margin-top: 40px;
    }
    
    .b-text3 {
        font-size: 68px;
    }
    
    .b-text4 {
        font-size: 20px;
        max-width: 900px;
    }
    
    .text8 {
        font-size: 52px;
    }
}

/* Стили для открытого меню на десктопе (если нужно) */
@media (min-width: 1201px) {
    .nav-button {
        display: none;
    }
    
    /* Исправляем наслоение на больших экранах */
    .b-section-first {
        margin-top: 40px;
    }
    
    .b-text3 {
        margin-top: 0;
        position: relative;
        top: 0;
    }
}

/* Дополнительно: убираем фон и кружочки у стрелок везде */
.swiper-button-prev,
.swiper-button-next {
    background: transparent !important;
    backdrop-filter: none;
}

.swiper-button-prev::after,
.swiper-button-next::after {
    font-size: 32px;
    font-weight: 300;
    color: rgba(255, 255, 255, 0.7);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.swiper-button-prev:hover::after,
.swiper-button-next:hover::after {
    color: #c4a15b;
}