/* Simple Responsive Modal (bootstrap-like) */
.modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 900;
    font-family: system-ui,-apple-system,"Segoe UI",Roboto,Ubuntu,"Helvetica Neue",Arial,sans-serif;
}

.modal--open {
    display: block;
}

.modal::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(15,23,42,.55);
    backdrop-filter: blur(3px);
}

.modal__dialog {
    position: relative;
    min-height: 100%;
    width: 100%;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    /* scroll exterior */
    overflow: auto;
    /* mantener padding simétrico cuando aparece el scrollbar */
    scrollbar-gutter: stable both-edges;
    padding: 1.8rem 1rem 1.2rem; /* menos espacio general */
}

.modal__panel {
    position: relative;
    background: #fff;
    width: 100%;
    max-width: 880px;
    border-radius: .85rem;
    box-shadow: 0 24px 50px -18px rgba(15,23,42,.42),0 10px 30px -10px rgba(15,23,42,.25);
    animation: modalFade .25s ease;
    display: flex;
    flex-direction: column;
}
/* Header del modal */
.modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: .8rem 1rem .55rem; /* compacto */
    border-bottom: 1px solid #e2e8f0;
}

.modal__title {
    margin: 0;
    font-size: 1.2rem; /* más grande */
    font-weight: 600;
    letter-spacing: .2px;
}

.modal__close {
    position: absolute;
    top: .55rem;
    right: .55rem;
    background: #fff;
    border: 1px solid #e2e8f0;
    width: 30px;
    height: 30px;
    border-radius: .55rem;
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    color: #475569;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .25s,border-color .25s,color .25s;
}

    .modal__close:hover, .modal__close:focus-visible {
        background: #f1f5f9;
        border-color: #d5dde6;
        color: #0f172a;
    }

.modal__body {
    padding: .75rem 1rem .95rem; /* menos padding interno */
    display: flex;
    flex-direction: column;
    gap: .75rem; /* menor separación */
    /* scroll interior */
    max-height: 70vh;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
    /* mantener padding cuando aparece el scrollbar */
    scrollbar-gutter: stable both-edges;
}
/* Footer del modal */
.modal__footer {
    padding: .55rem 1rem .7rem; /* compacto */
    border-top: 1px solid #e2e8f0;
    display: flex;
    gap: .6rem;
    justify-content: flex-end;
}

.modal__image-wrapper {
    display: inline-block; /* el wrapper se ajusta al ancho real de la imagen */
    width: auto;
    max-width: 100%;
    margin: 0 auto;
    border-radius: .8rem;
    background: #94a3b8;
}

#hotelModalImage {
    display: block;
    width: auto;         /* respeta tamaño intrínseco */
    max-width: 100%;     /* sin desbordar el contenedor */
    height: auto;        /* no forzar alto */
}

.modal__heading {
    margin: .2rem 0 .3rem;
    font-size: 1.08rem;
    font-weight: 600;
    letter-spacing: .4px;
}

.modal__row {
    display: flex;
    flex-wrap: wrap;
    gap: 1.2rem; /* menos separación entre columnas */
}

.modal__col {
    flex: 1 1 300px;
    min-width: 260px;
}

.modal__meta {
    margin: .15rem 0 .45rem;
    font-size: 1rem; /* más grande */
    line-height: 1.5;
}

.modal__list {
    list-style: disc;
    padding-left: 1.1rem;
    margin: .1rem 0 .5rem;
    font-size: 1rem; /* más grande */
    line-height: 1.5;
}

.modal__note {
    margin: .15rem 0 0;
    font-size: 1rem; /* más grande */
    line-height: 1.5;
}

.modal__actions {
    margin-top: .4rem;
    display: flex;
    gap: .6rem;
    justify-content: flex-end;
}

/* Modificador para centrar acciones */
.modal__actions--center { justify-content: center; }

.modal__panel strong {
    font-weight: 600;
}

@media (max-width:760px) {
    .modal__dialog {
        padding: 1.6rem .75rem 1.1rem;
    }

    .modal__body {
        padding: .7rem .9rem .9rem;
    }

    .modal__row {
        gap: 1rem;
    }

    #hotelModalImage {
        max-width: 100%;
        width: 100%; /* en móviles llenar ancho para mejor percepción */
    }
}

@media (max-width:520px) {
    .modal__dialog {
        padding: 1.4rem .55rem .9rem;
    }

    .modal__panel {
        border-radius: .75rem;
    }

    .modal__meta, .modal__list, .modal__note {
        font-size: .95rem; /* mantener legible en pantallas pequeñas */
    }
}

@keyframes modalFade {
    from {
        opacity: 0;
        transform: translateY(14px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}
