/* ==========================================================================
   Room Details Modern Layout
   This file styles only the main room presentation area on room-details.php.
   The booking form and header/navigation are intentionally left untouched.
   ========================================================================== */

.room-details-layout {
    align-items: flex-start;
}

.room-details-page {
    background:
        radial-gradient(circle at top left, rgba(164, 117, 67, 0.12), transparent 28%),
        radial-gradient(circle at top right, rgba(143, 96, 55, 0.1), transparent 26%),
        linear-gradient(180deg, #fbf6ee 0%, #fffdfa 24%, #f7efe4 100%);
    overflow-x: hidden;
}

.room-details-page .breadcrumb-section {
    padding-top: 42px;
    padding-bottom: 30px;
}

.room-details-page .room-details-section.spad {
    padding-top: 34px;
}

.room-details-section {
    position: relative;
}

.room-details-section::before,
.room-details-section::after {
    content: "";
    position: absolute;
    top: 3rem;
    width: 110px;
    height: 110px;
    opacity: 0.14;
    pointer-events: none;
    background:
        radial-gradient(circle at center, transparent 36%, rgba(151, 103, 61, 0.55) 37%, rgba(151, 103, 61, 0.55) 40%, transparent 41%),
        linear-gradient(45deg, transparent 46%, rgba(151, 103, 61, 0.5) 47%, rgba(151, 103, 61, 0.5) 53%, transparent 54%),
        linear-gradient(-45deg, transparent 46%, rgba(151, 103, 61, 0.5) 47%, rgba(151, 103, 61, 0.5) 53%, transparent 54%);
    border-radius: 24px;
    transform: rotate(45deg);
}

.room-details-section::before {
    left: -1.5rem;
}

.room-details-section::after {
    right: -1.5rem;
}

.room-details-main {
    margin-bottom: 2rem;
}

.room-booking-sidebar {
    margin-bottom: 2rem;
}

.room-gallery-card {
    background: linear-gradient(180deg, #ffffff 0%, #fbfaf7 100%);
    border-radius: 30px;
    padding: 18px;
    box-shadow: 0 24px 60px rgba(18, 47, 94, 0.08);
    overflow: hidden;
    margin-bottom: 0.75rem;
    border: 1px solid rgba(139, 102, 71, 0.08);
}

.room-gallery-shell {
    position: relative;
    margin: 0;
    padding: 0;
}

.room-gallery-stage {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    background: #111;
    margin: 0;
    padding: 0;
}

.room-hero-image {
    width: 100% !important;
    height: clamp(320px, 44vw, 560px) !important;
    object-fit: cover !important;
    display: block !important;
    border-radius: 24px;
}

.room-gallery-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 1rem;
    background: linear-gradient(
        180deg,
        rgba(16, 19, 24, 0.38) 0%,
        rgba(16, 19, 24, 0.08) 32%,
        rgba(16, 19, 24, 0) 60%
    );
    pointer-events: none;
}

.room-gallery-count {
    min-width: 58px;
    height: 36px;
    padding: 0 0.9rem;
    border-radius: 999px;
    background: rgba(23, 26, 31, 0.62);
    color: #fff;
    font-size: 0.93rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(8px);
}

.room-gallery-actions {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    pointer-events: auto;
}

.room-gallery-arrow,
.room-gallery-expand {
    width: 42px;
    height: 42px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.94);
    color: #253148;
    box-shadow: 0 12px 28px rgba(18, 47, 94, 0.15);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.2s ease, background-color 0.2s ease;
}

.room-gallery-arrow:hover,
.room-gallery-expand:hover {
    transform: translateY(-1px);
    background: #fff;
}

.room-gallery-thumbs {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.85rem;
    margin-top: 0.95rem;
}

.room-gallery-thumb {
    display: block !important;
    width: 100% !important;
    height: 104px !important;
    border: 0 !important;
    padding: 0 !important;
    border-radius: 18px !important;
    overflow: hidden !important;
    background: #111 !important;
    box-shadow: 0 16px 28px rgba(18, 47, 94, 0.08);
    cursor: pointer;
    position: relative;
}

.room-gallery-thumb img {
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    object-fit: cover !important;
    display: block !important;
}

.room-gallery-thumb::after {
    content: "";
    position: absolute;
    inset: 0;
    border: 2px solid transparent;
    border-radius: 18px;
    transition: border-color 0.2s ease, background-color 0.2s ease;
}

.room-gallery-thumb.is-active::after {
    border-color: rgba(43, 101, 187, 0.95);
    background: linear-gradient(180deg, rgba(47, 110, 203, 0.04), rgba(47, 110, 203, 0.18));
}

.room-gallery-lightbox[hidden] {
    display: none !important;
}

.room-gallery-lightbox {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(10, 14, 22, 0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.room-gallery-lightbox img {
    max-width: min(1100px, 92vw);
    max-height: 86vh;
    object-fit: contain;
    border-radius: 20px;
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.35);
}

.room-gallery-lightbox-close,
.room-gallery-lightbox-nav {
    position: absolute;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.94);
    color: #1e2430;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.room-gallery-lightbox-close {
    top: 24px;
    right: 24px;
    width: 44px;
    height: 44px;
}

.room-gallery-lightbox-nav {
    top: 50%;
    transform: translateY(-50%);
    width: 52px;
    height: 52px;
    font-size: 1.4rem;
}

.js-room-gallery-lightbox-prev {
    left: 24px;
}

.js-room-gallery-lightbox-next {
    right: 24px;
}

/* Quick facts strip under the hero image. */
.room-summary-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
    background: #fffdf9;
    border: 1px solid rgba(36, 93, 170, 0.1);
    border-radius: 22px;
    box-shadow: 0 16px 40px rgba(18, 47, 94, 0.08);
    margin-bottom: 1.75rem;
    overflow: hidden;
}

.room-summary-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.2rem 1.3rem;
    min-height: 96px;
}

.room-summary-item + .room-summary-item {
    border-left: 1px solid rgba(36, 93, 170, 0.12);
}

.room-summary-icon {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #2f6ecb;
    background: rgba(47, 110, 203, 0.08);
    font-size: 1rem;
    flex-shrink: 0;
}

.room-summary-item strong {
    display: block;
    color: #1e2430;
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.3;
}

.room-summary-item > div > span {
    display: block;
    color: #6e7785;
    font-size: 0.92rem;
    line-height: 1.35;
}

.room-summary-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #2f6ecb;
    font-size: 1rem;
    line-height: 1;
}

.room-summary-icon i {
    display: block;
    line-height: 1;
    margin: 0;
}

/* Main content card below the summary strip. */
.room-content-card {
    background: linear-gradient(180deg, #ffffff 0%, #fdfbf8 100%);
    border-radius: 24px;
    padding: 2.1rem 2rem 2.25rem;
    box-shadow: 0 20px 56px rgba(18, 47, 94, 0.08);
    border: 1px solid rgba(139, 102, 71, 0.08);
}

.room-modern-title {
    font-family: 'Lora', serif;
    font-size: clamp(2rem, 3.2vw, 3rem);
    line-height: 1.15;
    color: #21242d;
    margin: 0 0 0.65rem;
}

.room-modern-price {
    font-family: 'Lora', serif;
    color: #2f6ecb;
    font-size: clamp(1.7rem, 2.8vw, 2.4rem);
    line-height: 1.15;
    margin: 0 0 1.4rem;
}

.room-modern-price span {
    font-family: 'Cabin', sans-serif;
    font-size: 0.82em;
    color: #3f6fb3;
}

.room-amenity-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.6rem;
}

.room-amenity-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.62rem 0.95rem;
    border-radius: 999px;
    background: #ffffff;
    border: 1px solid rgba(47, 110, 203, 0.14);
    color: #37414f;
    font-size: 0.95rem;
    box-shadow: 0 6px 16px rgba(18, 47, 94, 0.06);
}

.room-amenity-badge i {
    color: #2f6ecb;
}

.room-details-copy {
    max-width: 720px;
}

.room-detail-row {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
}

.room-detail-row:last-child {
    margin-bottom: 0;
}

.room-detail-label {
    min-width: 92px;
    font-weight: 700;
    color: #21242d;
    letter-spacing: 0.01em;
}

.room-detail-value {
    color: #505865;
    line-height: 1.95;
    font-size: 1rem;
}

.room-detail-row-description .room-detail-value p {
    margin: 0;
}

@media (max-width: 1199.98px) {
    .room-summary-strip {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .room-summary-item:nth-child(3),
    .room-summary-item:nth-child(4) {
        border-top: 1px solid rgba(36, 93, 170, 0.12);
    }

    .room-summary-item:nth-child(3) {
        border-left: none;
    }
}

@media (max-width: 991.98px) {
    .room-booking-sidebar {
        margin-top: 0.5rem;
    }

    .room-content-card {
        padding: 1.7rem 1.4rem 1.8rem;
    }

    .room-details-section::before,
    .room-details-section::after {
        display: none;
    }

    .room-details-page .breadcrumb-section {
        padding-top: 32px;
        padding-bottom: 20px;
    }

    .room-details-page .room-details-section.spad {
        padding-top: 24px;
    }
}

@media (max-width: 767.98px) {
    .room-details-page .breadcrumb-section {
        padding-top: 24px;
        padding-bottom: 14px;
    }

    .room-details-page .room-details-section.spad {
        padding-top: 18px;
    }

    .room-details-page .breadcrumb-text h2 {
        margin-bottom: 8px;
    }

    .room-gallery-card {
        padding: 12px;
        border-radius: 22px;
    }

    .room-gallery-stage,
    .room-hero-image {
        border-radius: 18px;
    }

    .room-gallery-thumbs {
        display: flex !important;
        grid-template-columns: none !important;
        gap: 0.75rem;
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 0.25rem;
        scroll-snap-type: x proximity;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
    }

    .room-gallery-thumbs::-webkit-scrollbar {
        height: 6px;
    }

    .room-gallery-thumbs::-webkit-scrollbar-thumb {
        background: rgba(47, 110, 203, 0.35);
        border-radius: 999px;
    }

    .room-gallery-thumb {
        flex: 0 0 160px;
        width: 160px !important;
        height: 86px !important;
        scroll-snap-align: start;
    }

    .room-gallery-lightbox {
        padding: 1rem;
    }

    .room-gallery-lightbox-nav {
        width: 42px;
        height: 42px;
    }

    .room-summary-strip {
        grid-template-columns: 1fr;
    }

    .room-summary-item + .room-summary-item {
        border-left: none;
        border-top: 1px solid rgba(36, 93, 170, 0.12);
    }

    .room-summary-item:nth-child(3),
    .room-summary-item:nth-child(4) {
        border-top: 1px solid rgba(36, 93, 170, 0.12);
    }

    .room-detail-row {
        flex-direction: column;
        gap: 0.35rem;
    }

    .room-detail-label {
        min-width: 0;
    }
}
