/* ============================================================
   calendars.css
   Estilos para el popover del calendario NeoBookings
   (NeoPriceRangeCalendar)
   ============================================================ */


/* ==========================================================================
   POPOVER CONTENEDOR
   ========================================================================== */

#neo-mask-daterange-popover {
    position: absolute;
    left: 0;
    z-index: 300;
    margin: 4px 0;
}

/* Popover arriba */
#neo-mask-daterange-popover.popover--above {
    bottom: 100%;
    top: auto;
}

/* Popover abajo */
#neo-mask-daterange-popover.popover--below {
    top: 100%;
    bottom: auto;
}

/* Oculto */
#neo-mask-daterange-popover.d-none {
    display: none !important;
}

/* Wrapper del calendario (contiene header + calendario) */
.neo-calendar-wrapper {
    position: relative;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(30, 24, 16, 0.12), 0 2px 8px rgba(30, 24, 16, 0.08);
    overflow: hidden;
}

/* Header del calendario: título + botón cerrar — oculto en desktop */
.neo-calendar-header {
    display: none;
}

/* Contenedor del calendario */
#neo-mask-daterange {
    overflow: hidden;
}


/* ==========================================================================
   OVERRIDE VARIABLES DEL CALENDARIO NEO — Paleta Cabau Hotels
   El calendario usa CSS custom properties --npc-* que podemos sobreescribir.
   ========================================================================== */

#neo-mask-daterange {
    --npc-calendar-bg: #ffffff;
    --npc-selected-bg: var(--neo-primary, #3e5250);
    --npc-selected-text: #ffffff;
    --npc-selected-hover-bg: var(--neo-dark, #1E1810);
    --npc-cell-hover-bg: var(--neo-dark, #1E1810);
    --npc-range-highlighted-bg: rgba(62, 82, 80, 0.12);
    --npc-range-highlighted-hover-bg: var(--neo-dark, #1E1810);
    --npc-today-indicator: var(--neo-primary, #3e5250);
    --npc-day-text: var(--neo-dark, #1E1810);
    --npc-day-text-hover: #ffffff;
    --npc-weekday-text: var(--neo-neutral, #62615C);
    --npc-nav-hover-bg: var(--neo-bg, #F8F7F3);
    --npc-summary-button-bg: var(--neo-primary, #3e5250);
    --npc-summary-button-text: #ffffff;
    --npc-summary-button-hover-bg: var(--neo-dark, #1E1810);
    --npc-summary-button-hover-text: #ffffff;
    --npc-summary-button-radius: 8px;
    --npc-summary-date-text: var(--neo-dark, #1E1810);
    --npc-summary-label-text: var(--neo-neutral, #62615C);
    --npc-summary-separator-border: #e0e0e0;
    --npc-price-text: var(--neo-primary, #3e5250);
}


/* ==========================================================================
   RESPONSIVE — Tablet y móvil (≤ 922px)
   ========================================================================== */

@media (max-width: 922px) {

    #neo-mask-daterange-popover {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        bottom: 0 !important;
        right: 0 !important;
        width: 100% !important;
        height: 100% !important;
        z-index: 9999 !important;
        margin: 0 !important;
        background: #fff;
    }

    #neo-mask-daterange-popover.d-none {
        display: none !important;
    }

    .neo-calendar-wrapper {
        width: 100% !important;
        height: 100% !important;
        max-width: none !important;
        border-radius: 0 !important;
        box-shadow: none !important;
        display: flex !important;
        flex-direction: column !important;
    }

    /* Header visible en móvil: título "Fechas" + × */
    .neo-calendar-header {
        display: flex !important;
        align-items: center;
        justify-content: space-between;
        padding: 16px 20px;
        border-bottom: 1px solid #e0e0e0;
        flex-shrink: 0;
    }

    .neo-calendar-header__title {
        font-size: 16px;
        font-weight: 600;
        color: var(--neo-dark, #1E1810);
    }

    /* La × del header del calendario */
    .neo-calendar-header .popup-close {
        position: static !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        width: 36px !important;
        height: 36px !important;
        font-size: 24px !important;
        color: var(--neo-dark, #1E1810) !important;
        background: transparent !important;
        border: none !important;
        padding: 0 !important;
        cursor: pointer !important;
    }

    #neo-mask-daterange {
        flex: 1;
        overflow-y: auto;
        border-radius: 0;
    }
}
