/* Custom Styles for Rede Hotel Ideal */

:root {
    --primary-blue: #1e40af;
}

html,
body {
    overflow-x: hidden;
    width: 100%;
    position: relative;
}


@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fade-in 1s ease-out forwards;
}

/* Swiper Customization - Removed Blue Override */

/* Elegant Hero Swiper Navigation Buttons */
.heroSwiper .hero-nav-btn {
    color: white !important;
    background: rgba(0, 0, 0, 0.2);
    width: 50px !important;
    height: 50px !important;
    border-radius: 50%;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
}

/* Show buttons when hovering the Swiper container */
.heroSwiper:hover .hero-nav-btn {
    opacity: 1;
}

.heroSwiper .hero-nav-btn:hover {
    background: rgba(0, 0, 0, 0.6);
    transform: scale(1.1);
}

.heroSwiper .hero-nav-btn::after {
    font-size: 20px !important;
    font-weight: bold;
}

/* Gallery Video Overlay */
.gallery-slide {
    position: relative !important;
}

.gallery-video {
    display: block;
    position: relative;
    z-index: 1;
}

.gallery-video::-webkit-media-controls {
    display: none !important;
}

.gallery-video::-webkit-media-controls-enclosure {
    display: none !important;
}

.gallery-video-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.35);
    transition: background 0.3s ease;
    cursor: pointer;
    z-index: 2;
}

.gallery-video-play-btn {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    border: 3px solid rgba(255, 255, 255, 0.85);
    color: #fff;
    font-size: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    backdrop-filter: blur(4px);
    transition: transform 0.2s ease, background 0.2s ease;
    padding-left: 5px;
    z-index: 3;
}

.gallery-video-play-btn:hover {
    transform: scale(1.12);
    background: rgba(255, 255, 255, 0.35);
}

.gallery-video-spinner {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    border: 3px solid rgba(255, 255, 255, 0.6);
    color: #fff;
    font-size: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
    z-index: 3;
    pointer-events: none;
}

.gallery-video-spinner i {
    animation: gallery-spin 1s linear infinite;
}

@keyframes gallery-spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* Video Progress Bar */
.video-progress-container {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 6px;
    background: rgba(0, 0, 0, 0.3);
    z-index: 10;
    cursor: pointer;
}

.video-progress-bar {
    height: 100%;
    width: 0%;
    background: #22c55e;
    transition: width 0.1s linear;
    box-shadow: 0 0 12px rgba(34, 197, 94, 0.6);
}

.gallery-video-fullscreen-btn {
    position: absolute;
    bottom: 14px;
    right: 14px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    border: 2px solid rgba(255, 255, 255, 0.6);
    color: #fff;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    backdrop-filter: blur(4px);
    transition: transform 0.2s ease, background 0.2s ease;
    z-index: 3;
}

.gallery-video-fullscreen-btn:hover {
    transform: scale(1.15);
    background: rgba(255, 255, 255, 0.3);
}

.gallery-img-slide {
    cursor: pointer;
}

/* Swiper nav outside overflow-hidden */
.unitGallery~.swiper-button-next,
.unitGallery~.swiper-button-prev {
    top: 50%;
    transform: translateY(-50%);
}

/* Lightbox */
.gallery-lightbox {
    position: fixed;
    inset: 0;
    z-index: 500;
    background: rgba(0, 0, 0, 0.92);
    display: none;
    align-items: center;
    justify-content: center;
}

.gallery-lightbox.is-open {
    display: flex;
}

.gallery-lightbox__content {
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 90vw;
    max-height: 88vh;
}

.gallery-lightbox__content img {
    max-width: 90vw;
    max-height: 88vh;
    object-fit: contain;
    border-radius: 12px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6);
    user-select: none;
}

.gallery-lightbox__close {
    position: absolute;
    top: 20px;
    right: 24px;
    color: #fff;
    font-size: 28px;
    background: none;
    border: none;
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.2s, transform 0.2s;
    z-index: 10;
}

.gallery-lightbox__close:hover {
    opacity: 1;
    transform: scale(1.15);
}

.gallery-lightbox__arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: #fff;
    font-size: 24px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    backdrop-filter: blur(4px);
    transition: background 0.2s, transform 0.2s;
    z-index: 10;
}

.gallery-lightbox__arrow:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-50%) scale(1.08);
}

.gallery-lightbox__arrow--prev {
    left: 20px;
}

.gallery-lightbox__arrow--next {
    right: 20px;
}

/* Lightbox — vídeo */
.gallery-lightbox__video-wrap {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 90vw;
    max-height: 88vh;
}

.gallery-lightbox__video {
    max-width: 90vw;
    max-height: 88vh;
    width: auto;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6);
    display: block;
    cursor: pointer;
}

.gallery-lightbox__video-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.35);
    z-index: 2;
    pointer-events: none;
}

.gallery-lightbox__video-overlay .gallery-video-play-btn {
    pointer-events: all;
}

/* Custom Scrollbar for Modal */
.custom-scrollbar::-webkit-scrollbar {
    width: 6px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Booking Modal Unit Card Selection */
.booking-unit-card.active {
    background: rgba(255, 255, 255, 0.15) !important;
    border-color: var(--primary) !important;
    box-shadow: 0 0 25px rgba(90, 15, 20, 0.4);
}

.booking-unit-card.active .selection-indicator {
    opacity: 1 !important;
    transform: scale(1) !important;
}

/* Modal States */
#bookingModal.flex {
    display: flex !important;
}

#bookingModal.active #bookingModalOverlay {
    opacity: 1;
}

#bookingModal.active #bookingModalDialog {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

/* Modal Open Body Lock */
body.modal-open {
    overflow: hidden;
}

/* Feedback de toque no mobile (Simula o hover de desktop) */
.booking-unit-card.touch-active {
    background-color: rgba(255, 255, 255, 0.1) !important;
    transform: scale(0.98);
}

/* About Slider Glassmorphism Navigation */
.about-swiper-btn {
    width: 44px !important;
    height: 44px !important;
    background: rgba(255, 255, 255, 0.15) !important;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white !important;
    transition: all 0.3s ease;
    opacity: 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.about-swiper:hover .about-swiper-btn {
    opacity: 1;
}

.about-swiper-btn:hover {
    background: rgba(255, 255, 255, 0.35) !important;
}

.about-swiper-btn::after {
    font-size: 16px !important;
    font-weight: bold;
}

@media (max-width: 768px) {
    .about-swiper-btn {
        opacity: 0.8;
        width: 36px !important;
        height: 36px !important;
    }

    .about-swiper-btn::after {
        font-size: 14px !important;
    }
}

/* --- Novos Estilos para o Hero e Slider (Fusão Atmosférica) --- */
.hotsite-hero,
.heroSwiper .swiper-slide {
    min-height: 400px;
    background-color: #0c0c0e;
    /* Fundo base muito escuro */
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

/* Camada de Fundo Dinâmica (Luz de Fundo Espelhada) */
.hotsite-hero::before,
.heroSwiper .swiper-slide::before {
    content: '';
    position: absolute;
    width: 110%;
    height: 110%;
    top: -5%;
    left: -5%;
    background-image: var(--hero-bg);
    background-size: cover;
    background-position: center;
    filter: blur(60px) brightness(0.6) saturate(1.4);
    z-index: 1;
    opacity: 0.8;
}

.hero-main-img {
    width: 100%;
    max-height: 85vh;
    object-fit: contain;
    z-index: 10;
    position: relative;
    opacity: 0;
    transition: opacity 0.8s ease;

    /* A MÁGICA: Máscara que suaviza as bordas da foto para fundir com o fundo */
    -webkit-mask-image: radial-gradient(ellipse at center, black 40%, transparent 95%);
    mask-image: radial-gradient(ellipse at center, black 40%, transparent 95%);
}

.heroSwiper .hero-main-img {
    height: auto;
    /* Permite que a imagem defina a altura do slide dinamicamente */
}

/* Bloqueia cliques em slides inativos para não "roubarem" o hover do botão ativo */
.heroSwiper .swiper-slide:not(.swiper-slide-active) {
    pointer-events: none !important;
}

.heroSwiper .marker-overlay {
    background: radial-gradient(circle, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0) 70%);
    z-index: 20;
    pointer-events: none;
}

/* O conteúdo só é clicável se o slide for o ativo */
.heroSwiper .swiper-slide-active .marker-overlay > * {
    pointer-events: auto !important;
}

.heroSwiper .btn-primary {
    transition: transform 0.7s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.7s ease, background-color 0.4s ease !important;
    will-change: transform;
}

.heroSwiper .btn-primary:hover {
    background-color: var(--primary-hover) !important;
    transform: scale(1.08) !important; /* Move-se em direção ao usuário (zoom 3D) */
    /* Sombra complexa: Sombra de profundidade (preta) + Aura de luz (vermelha) */
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.4), 0 0 30px rgba(225, 6, 0, 0.35) !important;
    color: #FFFFFF !important;
}

.hero-main-img.loaded {
    opacity: 1;
}

.hotsite-hero.color-loaded {
    /* Opcional: Adicionar um leve gradiente para dar profundidade */
    background-image: radial-gradient(circle at center, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.2) 100%);
}

/* Ajustes para Telas Pequenas (Mobile) */
@media (max-width: 768px) {

    .hotsite-hero,
    .heroSwiper,
    .heroSwiper .swiper-wrapper,
    .heroSwiper .swiper-slide {
        height: 60vh !important;
        /* Força a altura ignorando o inline-style do Swiper autoHeight */
        min-height: auto;
    }

    .hero-main-img {
        height: 100% !important;
        width: 100% !important;
        object-fit: cover !important;
        /* No mobile, preenchemos o container */
        object-position: center;
        max-height: none;

        /* Removemos a máscara de suavização no mobile para o preenchimento cover ser total */
        -webkit-mask-image: none !important;
        mask-image: none !important;
    }

    .heroSwiper .marker-overlay {
        background: rgba(0, 0, 0, 0.3);
        /* Overlay simples no mobile para legibilidade */
    }
}