/* <WHITE GRADIENT IN THE BOTTOM OF EACH ROOM'S MAIN PHOTO> */
.img-gradient{
    position:relative;
    display:inline-block;
}
.img-gradient:after {
    content:'';
    position:absolute;
    left:0; bottom:0;
    width:100%; height:128px;
    display:inline-block;
    background: -moz-linear-gradient(top, rgba(255,255,255,0) 0%, rgba(255, 255, 255, 1) 100%); /* FF3.6+ */
    background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(255,255,255, 0)), color-stop(100%,rgba(255,255,255,1))); /* Chrome,Safari4+ */
    background: -webkit-linear-gradient(top, rgba(255,255,255,0) 0%,rgba(255,255,255, 1) 100%); /* Chrome10+,Safari5.1+ */
    background: -o-linear-gradient(top, rgba(255,255,255,0) 0%,rgba(255,255,255, 1) 100%); /* Opera 11.10+ */
    background: -ms-linear-gradient(top, rgba(255,255,255,0) 0%,rgba(255,255,255, 1) 100%); /* IE10+ */
    background: linear-gradient(to bottom, rgba(255,255,255,0) 0%,rgba(255,255,255, 1) 100%); /* W3C */
    filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#ffffff',GradientType=0 ); /* IE6-9 */
}
.img-gradient img {
    display:block;
}
/* </WHITE GRADIENT IN THE BOTTOM OF EACH ROOM'S MAIN PHOTO> */


.room_gallery_item.inactive , .room_gallery_item.inactive span, .room_gallery_item.inactive em {
    width:0px;
    visibility: hidden;
    opacity: 0;
}

.room_gallery_item.active , .room_gallery_item.active span, .room_gallery_item.active em {
    margin: 1px 1px 0px 0px;
    visibility:visible;
    opacity: 1;
    width:100px;
}

.room_gallery_item{
    float: left;
    text-align:center;
    font-size: 12px;
    transition: width 0.25s, visibility 0.5s, opacity 0.5s linear;
    text-align: center;
}

.rateDescription { color:#4f4f4f; padding: 5px 0px; }
.selectRoom .rateDescription { color:#fff; }

.otaReviews {
    width: 100%;
    position: absolute;
    bottom: 1px;
    right: 0px;
    background: #fafafa;
    text-align: center;
    padding: 5px;
    font-size: .65rem !important;
    color: #c3c3c3;
}
.otaReviews strong { font-size: 120%; }
.selectRoom .otaReviews { background: #24d3a0; color:#93f7da; }

.otaCost .text-muted { color:#bcbcbc !important; }
.otaCost .badge-secondary { background: none !important; border: solid 1px #e8e8e8; }
.selectRoom .otaCost .text-muted { color:#fff !important; }
.selectRoom .otaCost .text-muted.bestPriceTitle { background:#56e8bd !important; }

.otaCost .otaLogos img {
    filter: grayscale(100%);
    opacity: 0.5;
    height: 30px !important;
}

@media (max-width: 768px) {
    .otaLogos, .rateDescription {
        text-align: center;
        padding-bottom: 20px;
    }
}

.bedbathBox {
    text-align: center;
    background: #f7f7fc;
    /* background: rgb(0,159,177); */
    padding: .2rem;
    border-radius: .75rem;
}

.bedbathBox h3, .bedbathBox h6, .bedbathBox em, .bedbathBox p { color:#4a4b65; font-size: 1rem; margin: 0px; }

/* DISABLES THE ROOM CONTAINER ACCORDION */
a.disabled {
    pointer-events: none;
    cursor: default;
}

.swalnewsearch {
    padding: .55rem 1.2rem !important;
    font-size: 0.90rem !important;
    direction: ltr;
}
.swalnewsearch::before {
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    content: "\f060";
    margin-right: 10px;
}
.swalproceed {
    padding: .55rem 1.2rem !important;
    font-size: 0.90rem !important;
    direction: rtl;
}
.swalproceed::after {
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    content: "\f164";
    margin-left: 10px;
}

.roomsAvailablePreviewRoomTitleSuccess {
    background: #0d906a;
    display: block;
}

.roomsAvailablePreviewRoomTitleDanger {
    background: #bb002e;
    display: block;
}

.roomsAvailablePreviewRoomPersonsSuccess {
    background: #2dae88;
    display: block;
}

.roomsAvailablePreviewRoomPersonsDanger {
    background: #e33761;
    display: block;
}

.sortLabel {
    margin-top: 35px;
    text-align: right;
}
.sortDropdown {
    padding-right: 25px;
}

@media (max-width: 767.98px) {
    .sortLabel {
        margin-top: 0px;
        text-align: center;
    }
    .sortDropdown {
        margin-top: 10px;
        margin-bottom: 25px;
        padding: 0px 25px;
    }
}


.timeline-wrapper {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    align-items: flex-start;
    position: relative;
    margin-bottom: 2rem;
}

.timeline-wrapper::before {
    content: "";
    position: absolute;
    top: 40px;
    left: 0;
    right: 0;
    height: 2px;
    background: #e9e9e9;
    z-index: 0;
}

.stay-block {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0 10px;
    z-index: 1;
}

.stay-label {
    font-size: 13px;
    font-weight: bold;
    text-align: center;
}

.stay-line {
    width: 2px;
    height: 20px;
    background: #e9e9e9;
    margin-bottom: 10px;
}

.stay-card {
    width: 240px;
}

.arrow-icon {
    display: flex;
    align-items: center;
    margin: 0 10px;
}

.arrow-icon i {
    color: #007bff;
}

.roomLocation {
    height: fit-content; 
    margin: auto 0;
}

@media (max-width: 767px) {
    .timeline-wrapper {
        flex-direction: column;
        align-items: center;
    }

    .timeline-wrapper::before {
        display: none;
    }

    .arrow-icon {
        margin: 10px 0;
    }

    .stay-line {
        display: none;
    }

    .wrapFlex {
        flex-wrap: wrap;
        justify-content: center;
        text-align: center;
    }

    .wrapFlex .nav-heading {
        width: 100%;
    }

    .roomLocation {
        margin: 0 auto;
    }
}

.carousel-control-prev-icon::after,
.carousel-control-next-icon::after {
    background-color: red;
}

.step2 .s2-toolbar{
    border-radius:14px;
    margin:10px 0 14px; 
    padding:10px 12px;
    border:1px solid rgba(0,0,0,.06);
    background:#fff;
    box-shadow:0 8px 28px rgba(0,0,0,.08);
}

.step2 .s2-ages-menu{
    padding:5px;
    min-width:380px;
    max-width:95vw;
    border:1px solid rgba(0,0,0,.08); 
    box-shadow:0 14px 40px rgba(0,0,0,.14);
    border-radius:12px;
}
@media (max-width:767px) {
    .step2 .s2-ages-menu {
       min-width:280px; 
       max-width:95vw;
       left: -30px;
    }

    .step2 .card-body {
        padding: 0.45rem;
    }
}

.step2 .s2-ages-actions{
    display:flex;
    justify-content:flex-end;
    gap:8px; 
    padding-top:8px;
    border-top:1px dashed #e5e7eb;
    margin-top:8px;
}

.s2-roomAgePicker .agePicker {
    margin: 10px 0 !important;
}

.s2-roomAgePicker .agePicker .form-group {
    margin-bottom: 0;
}

.step2 .dropdown-menu {
    transform: translate3d(-65px, 64px, 0px);
}

.rate-offer-wrap {
	display: inline;
}

.rate-offer-badge {
	display: inline-flex !important;
	align-items: center;
	width: auto !important;
	max-width: max-content;
	white-space: nowrap;
	vertical-align: middle;
	margin-left: 5px;
}

/* Mobile only */
@media (max-width: 575.98px) {
	.rate-offer-wrap {
		display: block;
		margin-top: 5px;
		text-align: center;
	}

	.rate-offer-badge {
		margin-left: 0;
	}
}

/* Digitelia Booking Engine - Map Split View */
@media (min-width: 992px) {

    .step2 .collapse.show:has(> .digitelia-map-container:not(.d-none)) {
        display: grid !important;
        grid-template-columns: minmax(0, 50%) minmax(0, 50%);
        grid-template-rows: auto minmax(0, 1fr);
        height: min(85vh, 900px);
        min-height: 600px;
        align-items: stretch;
    }

    /* Results toolbar */
    .step2 .collapse.show:has(> .digitelia-map-container:not(.d-none)) > .row {
        grid-column: 1 / -1;
        grid-row: 1;
    }

    /* Independent scrolling on the left */
    .step2 .collapse.show:has(> .digitelia-map-container:not(.d-none)) > .resultBox {
        display: block !important;
        grid-column: 1;
        grid-row: 2;
        min-width: 0;
        min-height: 0;
        overflow-y: auto;
        overscroll-behavior-y: contain;
    }

    /* Map stays on the right */
    .step2 .collapse.show > .digitelia-map-container:not(.d-none) {
        grid-column: 2;
        grid-row: 2;
        position: relative;
        top: auto;
        height: 100%;
        min-height: 0;
        min-width: 0;
    }

    /* Google Map fills its container */
    .step2 .digitelia-map-container:not(.d-none) > div[id^="digiteliaMap"] {
        height: 100% !important;
    }
}

/* Append to step2.css. These styles belong only to the map interface. */
.step2 .digitelia-map-container { position: relative; }
.step2 .digitelia-map-container > div[id^="digiteliaMap"] { position: relative; z-index: 0; }
.step2 .dt-map-message {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(255, 255, 255, .94);
    color: #344052;
    text-align: center;
}
.step2 .dt-map-message[hidden] { display: none !important; }
.dt-map-marker {
    background: #fff;
    color: #344052;
    border: 1px solid #ddd;
    border-radius: 25px;
    padding: 8px 14px;
    font-size: 14px;
    font-weight: 700;
    box-shadow: 0 3px 10px rgba(0, 0, 0, .2);
    white-space: nowrap;
    cursor: pointer;
}
.dt-map-marker-unavailable { background: #777; color: #fff; border-color: #666; }
.dt-map-marker-active { outline: 3px solid var(--mainColor1, #3099aa); outline-offset: 2px; }
.step2 .roomContainer.dt-map-room-active { scroll-margin-top: 120px; }
.step2 .roomContainer.dt-map-room-active > article {
    outline: 2px solid var(--mainColor1, #3099aa);
}
.dt-map-popup { width: 260px; max-width: calc(100vw - 96px); color: #344052; }
.dt-map-popup-photo { height: 140px; background-size: cover; background-position: center; border-radius: 8px; }
.dt-map-popup h5 { margin: 12px 0 6px; font-size: 16px; overflow-wrap: anywhere; }
.dt-map-popup-status { margin-bottom: 8px; font-size: 15px; font-weight: 600; }
.dt-map-popup-note { margin-bottom: 12px; font-size: 12px; line-height: 1.4; }
.dt-map-popup .btn { white-space: normal; }

.dt-map-marker {
    background: #fff;
    color: #344052;
    border: 1px solid #ddd;
    border-radius: 22px;
    padding: 6px 12px;
    min-width: 64px;
    min-height: 44px;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    line-height: 1.1;
    box-shadow: 0 3px 10px rgba(0,0,0,.20);
    cursor: pointer;
    white-space: normal;
}

.dt-map-marker-from {
    display: block;
    font-size: 11px;
    font-weight: 600;
    opacity: .80;
    margin-bottom: 2px;
}

.dt-map-marker-price {
    display: block;
    font-size: 16px;
    font-weight: 800;
}

.dt-map-marker-unavailable {
    background: #dc3545;
    border-color: #c82333;
    color: #fff;
    padding: 8px 12px;
    max-width: 130px;
}

.dt-map-marker-room {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    white-space: normal;
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.2;
    max-width: 104px;
}

.dt-map-popup {
    position: relative;
    width: 260px;
    max-width: calc(100vw - 96px);
    color: #344052;
    padding-top: 4px;
}

.dt-map-popup-close {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 28px;
    height: 28px;
    border: 0;
    background: transparent;
    color: #666;
    font-size: 28px;
    line-height: 1;
    padding: 0;
    cursor: pointer;
    z-index: 5;
}

.dt-map-popup-close:hover {
    color: #111;
}

.dt-map-popup-photo {
    margin-top: 10px;
    height: 140px;
    background-size: cover;
    background-position: center;
    border-radius: 8px;
}

/* Map popups: fit their content without horizontal scrolling */
.step2 .digitelia-map-container .dt-map-popup {
    width: 260px;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
    white-space: normal;
    overflow-wrap: anywhere;
    padding: 0 12px 12px 0;
}

.step2 .digitelia-map-container .dt-map-popup > * {
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
}

.step2 .digitelia-map-container .dt-map-popup .btn {
    width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
}

/* Only our popup content, not the map or its controls */
.step2 .digitelia-map-container .gm-style-iw-d:has(.dt-map-popup) {
    overflow-x: hidden !important;
    overflow-y: auto !important;
}

/* Map View: compact room cards and slim results scrollbar */
@media (min-width: 992px) {

    /* Map View: larger room photos */
    .step2 .collapse.show:has(> .digitelia-map-container:not(.d-none))
    > .resultBox .roomContainer > article.card-horizontal
    > :is(.card-img-top, .card-img-bottom) {
        width: 45% !important;
        max-width: 45% !important;
        flex: 0 0 45% !important;
        min-width: 0;
        background-size: cover;
        background-position: center;
        background-repeat: no-repeat;
    }

    /* Room information: applies to all room cards */
    .step2 .collapse.show:has(> .digitelia-map-container:not(.d-none))
    > .resultBox .roomContainer > article.card-horizontal > .card-body {
        padding: 0 5px !important;
        flex: 1 1 0;
        min-width: 0;
    }

    /* Slim scrollbar, only inside the map-view results list */
    .step2 .collapse.show:has(> .digitelia-map-container:not(.d-none))
    > .resultBox {
        --dt-map-scroll-thumb: var(--mainColor1, #63898f);
        --dt-map-scroll-track: #edf3f4;

        scrollbar-width: thin;
        scrollbar-color:
            var(--dt-map-scroll-thumb)
            var(--dt-map-scroll-track);

        scrollbar-gutter: stable;
    }

    /* Stronger brand color while interacting with the list */
    .step2 .collapse.show:has(> .digitelia-map-container:not(.d-none))
    > .resultBox:is(:hover, :focus-within) {
        --dt-map-scroll-thumb: var(--mainColor1, #006773);
    }

    /* Fallback for browsers using WebKit scrollbar styling */
    .step2 .collapse.show:has(> .digitelia-map-container:not(.d-none))
    > .resultBox::-webkit-scrollbar {
        width: 8px;
        height: 8px;
    }

    .step2 .collapse.show:has(> .digitelia-map-container:not(.d-none))
    > .resultBox::-webkit-scrollbar-track {
        background: var(--dt-map-scroll-track);
        border-radius: 999px;
    }

    .step2 .collapse.show:has(> .digitelia-map-container:not(.d-none))
    > .resultBox::-webkit-scrollbar-thumb {
        background: var(--dt-map-scroll-thumb);
        border: 1px solid var(--dt-map-scroll-track);
        border-radius: 999px;
    }
}

/* Popup: close button over the photo, without an empty header */
.step2 .digitelia-map-container .dt-map-popup {
    position: relative;
    margin: 0;
    padding: 0;
    max-width: 100%;
    box-sizing: border-box;
}

.step2 .digitelia-map-container .dt-map-popup-photo {
    margin-top: 0;
}

.step2 .digitelia-map-container .dt-map-popup > .dt-map-popup-close {
    position: absolute !important;
    top: 5px !important;
    right: 5px !important;
    bottom: auto !important;
    left: auto !important;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;

    margin: 0 !important;
    padding: 0 !important;
    transform: none !important;

    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.96);
    color: #344052;

    font-family: Arial, sans-serif;
    font-size: 26px;
    line-height: 1;

    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.18);
    cursor: pointer;
    z-index: 10;
}

.step2 .digitelia-map-container .dt-map-popup-close:hover {
    background: #fff;
    color: #111;
}

.step2 .digitelia-map-container .dt-map-popup-close:focus-visible {
    outline: 2px solid var(--mainColor1, #3099aa);
    outline-offset: 2px;
}

/* Without a photo, leave enough space so the button cannot cover the title */
.step2 .digitelia-map-container
.dt-map-popup:not(:has(> .dt-map-popup-photo)) {
    padding-top: 36px;
}

/* Results toolbar: map/list button and sorting on the same row */

.step2 .dt-results-actions {
    display: flex;
    flex-wrap: nowrap;
    align-items: stretch;
    gap: 8px;
    min-width: 0;
}

/* Button uses only the space required by its label */
.step2 .dt-results-actions > .showMap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    flex: 0 0 auto;
    width: auto;
    height: 38px;
    margin: 0;
    padding: 6px 10px;
    white-space: nowrap;
}

/* Sorting takes the remaining space */
.step2 .dt-results-actions > .dt-results-sort {
    flex: 1 1 0;
    width: auto;
    min-width: 0;
    flex-wrap: nowrap;
}

.step2 .dt-results-actions .dt-results-sort > select {
    height: 38px;
    min-width: 0;
}

.step2 .dt-results-actions .input-group-text {
    height: 100%;
    margin: 0;
    padding: 0 10px;
}

/* Compact spacing on phones */
@media (max-width: 575.98px) {
    .step2 .dt-results-actions > .showMap,
    .step2 .dt-results-actions .dt-results-sort > select {
        font-size: 12px;
    }

    .step2 .dt-results-actions > .showMap {
        padding: 6px 8px;
    }

    .step2 .dt-results-actions .input-group-text {
        padding: 0 8px;
    }
}

/* Zero padding only on Google InfoWindows containing our popup */
.gm-style-iw.gm-style-iw-c:has(.dt-map-popup),
.gm-style-iw-d:has(> .dt-map-popup) {
    padding: 5px !important;
    padding-inline: 5px !important;
    padding-block: 5px !important;
}

/* =========================================================
   DIGITELIA MAP VIEW — CONTAINER-AWARE COMPACT RATES
   Applies only when desktop Map View is active.
   The regular List View and mobile view remain unchanged.
   ========================================================= */

@media (min-width: 992px) {
    .step2 .collapse.show:has(> .digitelia-map-container:not(.d-none)) > .resultBox {
        container: map-results / inline-size;
    }
}

@container map-results (max-width: 900px) {
    .roomContainer {
        margin-bottom: 12px;
    }

    .roomContainer .rateContainer {
        padding-top: 6px;
        padding-bottom: 6px;
        margin-bottom: 8px;
        min-width: 0;
    }

    /* Existing Bootstrap columns stack only inside narrow Map View. */
    .roomContainer .rateContainer > .col-md-9.col-lg-10,
    .roomContainer .rateContainer > .col-md-3.col-lg-2 {
        flex: 0 0 100%;
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }

    .roomContainer .rateContainer > .col-md-9.col-lg-10 {
        padding-right: 0;
    }

    .roomContainer .rateContainer > .col-md-3.col-lg-2 {
        padding: 0;
        margin-top: 4px;
    }

    /* Full rate details remain available in the existing rate modal. */
    .roomContainer .rateContainer .rateDescription.d-md-block {
        display: -webkit-box !important;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 2;
        overflow: hidden;
        line-height: 1.4;
        max-height: 2.8em;
        padding: 0;
        margin: 3px 0 5px;
        text-align: left;
    }

    .roomContainer .rateContainer h2.font-size-base {
        margin-bottom: 4px !important;
        line-height: 1.3;
        overflow-wrap: anywhere;
    }

    /* A single compact price/CTA row for offer and regular rates. */
    .roomContainer .rateContainer > .col-md-3.col-lg-2 > .row {
        display: flex;
        align-items: stretch;
        flex-wrap: nowrap;
        gap: 8px;
        margin: 0;
    }

    /* Booking button fills the entire action area height */
    .roomContainer .rateContainer
    > .col-md-3.col-lg-2 > .row > .col-4.col-md-12 {
        display: flex;
        align-items: stretch;
    }

    .roomContainer .rateContainer .rateButton {
        width: 100%;
        height: 100%;
        min-height: 60px;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 8px 12px;
        border-radius: 8px;
        font-size: 14px;
        font-weight: 600;
    }

    .roomContainer .rateContainer > .col-md-3.col-lg-2 > .row
    > .badge-secondary.col-8.col-md-12 {
        flex: 1 1 0;
        width: auto;
        max-width: none;
        min-width: 0;
        margin: 0;
        padding: 6px 8px;
        border-radius: 8px;
    }

    .roomContainer .rateContainer > .col-md-3.col-lg-2 > .row
    > .col-4.col-md-12 {
        flex: 0 0 112px;
        width: 112px;
        max-width: 112px;
        min-width: 0;
        padding: 0;
    }

    .roomContainer .rateButton {
        width: 100%;
        min-height: 32px;
        white-space: nowrap;
    }

    .roomContainer .rateContainer .badge-secondary .my-2 {
        margin-top: 3px !important;
        margin-bottom: 3px !important;
    }

    .roomContainer .rateContainer .badge-secondary .d-flex {
        flex-wrap: wrap;
        justify-content: center;
        gap: 2px 6px;
    }

    .roomContainer .rateContainer .badge-secondary .d-flex > * {
        white-space: nowrap;
    }
}
/* Digitelia Map View: animated desktop map expansion (list remains in DOM). */
.step2 .dt-map-expand-toggle { display: none; }
@media (min-width: 992px) {
    .step2 .digitelia-map-container:not(.d-none) > .dt-map-expand-toggle {
        display: inline-flex;
        position: absolute;
        z-index: 5;
        top: 12px;
        left: 12px;
        align-items: center;
        justify-content: center;
        width: 39px;
        height: 39px;
        border: 1px solid rgba(0,0,0,.08);
        border-radius: 8px;
        background: #fff;
        color: var(--mainColor1, #344052);
        box-shadow: 0 2px 8px rgba(0,0,0,.15);
        cursor: pointer;
    }
    .step2 .digitelia-map-container .dt-map-expand-toggle:hover {
        background: #f6f8fa;
    }
    .step2 .digitelia-map-container .dt-map-expand-toggle:focus-visible {
        outline: 2px solid var(--mainColor1, #3099aa);
        outline-offset: 2px;
    }
    .step2 .collapse.show:has(> .digitelia-map-container:not(.d-none)) {
        transition: grid-template-columns 320ms ease;
    }
    .step2 .collapse.show.dt-map-expanded:has(> .digitelia-map-container:not(.d-none)) {
        grid-template-columns: minmax(0, 0fr) minmax(0, 1fr);
    }
    .step2 .collapse.show:has(> .digitelia-map-container:not(.d-none)) > .resultBox {
        transition: opacity 180ms ease;
    }
    .step2 .collapse.show.dt-map-expanded > .resultBox {
        opacity: 0;
        pointer-events: none;
        overflow: hidden;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
}
@media (prefers-reduced-motion: reduce) {
    .step2 .collapse.show:has(> .digitelia-map-container:not(.d-none)) {
        transition: none;
    }
}
