/* ==================== PREMIUM UX / UI ENHANCEMENTS ==================== */

/* 1. Global Smooth Scrolling and Selection */
html {
  scroll-behavior: smooth;
}
::selection {
  background: var(--primary-color, #d49a89);
  color: white;
}

/* 2. Premium Button Hovers (Buttons and CTAs) */
.cta-button, .btn-seleccionar, .whatsapp-btn, button[type="submit"] {
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
  position: relative;
  overflow: hidden;
}
.cta-button:hover, .btn-seleccionar:hover, .whatsapp-btn:hover, button[type="submit"]:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 10px 20px rgba(0,0,0,0.12), 0 4px 8px rgba(0,0,0,0.06);
}
/* Shine effect on buttons */
.cta-button::after, .btn-seleccionar::after, button[type="submit"]::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.3) 50%, rgba(255,255,255,0) 100%);
  transform: skewX(-25deg);
  transition: all 0.75s;
}
.cta-button:hover::after, .btn-seleccionar:hover::after, button[type="submit"]:hover::after {
  left: 125%;
}

/* 4. Cards Elevation & Glassmorphism */
.service-card, .promotion-card, .team-card, .finding-card, .testimonial-card {
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  border: 1px solid rgba(255,255,255,0.1);
}
.service-card:hover, .promotion-card:hover, .team-card:hover, .finding-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 35px rgba(0,0,0,0.1), 0 5px 15px rgba(0,0,0,0.05);
}

/* 5. Header / Navbar Glassmorphism */
.header.scrolled {
  background: rgba(255, 255, 255, 0.85) !important;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255,255,255,0.3);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05);
}

/* 6. Form Inputs Focus States */
input, textarea, select {
  transition: all 0.3s ease;
  border: 2px solid transparent;
  background-color: #f8f9fa;
}
input:focus, textarea:focus, select:focus {
  background-color: #fff;
  border-color: var(--primary-color, #d49a89);
  box-shadow: 0 0 0 4px rgba(212, 154, 137, 0.15);
  outline: none;
}

/* 7. Image hover zoom */
.gallery-grid img, .carousel-slide img, .team-photo img {
  transition: transform 0.5s ease;
}
.gallery-grid img:hover, .carousel-slide img:hover, .team-photo img:hover {
  transform: scale(1.05);
}

/* 8. Micro-animations for icons */
.service-icon, .finding-icon i {
  transition: transform 0.3s ease, color 0.3s ease;
}
.service-card:hover .service-icon, .finding-card:hover .finding-icon i {
  transform: scale(1.2) rotate(5deg);
}

/* ==================== CAROUSEL GALLERY ALIGNMENT FIX ==================== */
.carousel-container {
    position: relative;
    width: 100%;
    max-width: 800px;
    margin: 20px auto;
}

.carousel-slide {
    position: relative;
    width: 100%;
    height: 400px; /* Base height */
    overflow: hidden;
    background-color: transparent;
    display: flex;
    justify-content: center;
    align-items: center;
}

.carousel-slide img {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    transform: none !important;
    object-fit: contain !important;
    margin: 0 !important;
    padding: 0 !important;
}

.carousel-container .prev-btn {
    left: 10px !important;
    z-index: 50 !important;
}

.carousel-container .next-btn {
    right: 10px !important;
    z-index: 50 !important;
}

@media (max-width: 768px) {
    .carousel-slide {
        height: 300px;
    }
}

/* ==================== FINDING CARDS SPACING FIX ==================== */
.finding-card {
    min-height: auto !important;
}

.finding-content {
    height: auto !important;
    padding: 24px 20px 20px 20px !important;
}

.finding-video-container {
    margin-bottom: 0 !important;
}

/* ==================== TESTIMONIALS VIDEO GRID ==================== */
.testimonials-book {
    width: min(100%, 980px);
    margin: 0 auto;
}

.testimonials-book-stage {
    position: relative;
    padding: clamp(0.65rem, 2vw, 1.25rem);
    perspective: 2200px;
    border: 1px solid #263b3b;
    border-radius: 0.75rem;
    background: linear-gradient(135deg, #526e68 0%, #233c3d 50%, #172b31 100%);
    box-shadow: 0 24px 52px rgba(18, 39, 42, 0.25), inset 0 0 0 2px rgba(239, 225, 193, 0.16);
}

.testimonials-book-stage::before,
.testimonials-book-stage::after {
    position: absolute;
    z-index: 2;
    top: 1.5rem;
    bottom: 1.5rem;
    width: 0.4rem;
    border-radius: 3px;
    background: repeating-linear-gradient(180deg, #f8f3e7 0, #f8f3e7 2px, #d6cfbe 3px, #fffdf6 4px);
    box-shadow: 0 2px 5px rgba(17, 29, 29, 0.25);
    content: "";
    pointer-events: none;
}

.testimonials-book-stage::before {
    left: 0.35rem;
}

.testimonials-book-stage::after {
    right: 0.35rem;
}

.testimonials-grid {
    position: relative;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: stretch;
    gap: 2px;
    margin: 0;
    overflow: visible;
    background: #7a8a7d;
    box-shadow: 0 4px 14px rgba(17, 29, 29, 0.3);
    transform-style: preserve-3d;
}

.testimonials-grid::before {
    position: absolute;
    z-index: 3;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 1.25rem;
    background: linear-gradient(90deg, rgba(48, 48, 37, 0.2), rgba(48, 48, 37, 0.38) 45%, rgba(255, 255, 255, 0.5) 50%, rgba(48, 48, 37, 0.3) 56%, rgba(48, 48, 37, 0.12));
    content: "";
    pointer-events: none;
    transform: translateX(-50%);
}

.testimonial-video-card {
    position: relative;
    grid-row: 1;
    width: 100%;
    min-width: 0;
    min-height: 500px !important;
    margin: 0;
    overflow: hidden;
    border: 0;
    border-radius: 0;
    background: #fffdf6;
    cursor: pointer;
    box-shadow: inset 0 0 36px rgba(110, 94, 67, 0.12);
    backface-visibility: visible;
}

.testimonial-video-card[hidden] {
    display: none !important;
}

.testimonial-video-card:not([hidden]):nth-of-type(odd) {
    grid-column: 1;
    border-radius: 0.2rem 0 0 0.2rem;
    box-shadow: inset -12px 0 16px -17px rgba(43, 31, 22, 0.8);
}

.testimonial-video-card:not([hidden]):nth-of-type(even) {
    grid-column: 2;
    border-radius: 0 0.2rem 0.2rem 0;
    box-shadow: inset 12px 0 16px -17px rgba(43, 31, 22, 0.8);
}

.testimonials-grid.testimonials-single-right > .testimonial-video-card:not([hidden]) {
    grid-column: 2;
}

.testimonial-video-card:hover {
    transform: none;
}

.testimonial-video-card:focus-visible {
    outline: 3px solid #1696a0;
    outline-offset: 3px;
}

.testimonial-video-card video {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 1;
}

.testimonial-video-card::after {
    position: absolute;
    right: 1.25rem;
    bottom: 1.25rem;
    left: 1.25rem;
    z-index: 1;
    padding: 2.4rem 0.9rem 0.8rem;
    background: linear-gradient(transparent, rgba(13, 29, 31, 0.78));
    color: #fff;
    content: "Testimonio en video";
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(1rem, 1.7vw, 1.25rem);
    font-weight: 700;
    letter-spacing: 0.02em;
    pointer-events: none;
}

.testimonial-video-card .play-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    background: rgba(21, 120, 126, 0.9);
    color: white;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 24px;
    backdrop-filter: blur(4px);
    opacity: 0.92;
    pointer-events: none;
}

.testimonials-turn-leaf {
    position: absolute;
    z-index: 5;
    top: 0;
    bottom: 0;
    width: calc(50% - 1px);
    transform-style: preserve-3d;
    pointer-events: none;
}

.testimonials-turn-leaf.turn-forward {
    right: 0;
    transform-origin: left center;
    animation: testimonialPageTurnForward 560ms cubic-bezier(0.55, 0.05, 0.35, 1) both;
}

.testimonials-turn-leaf.turn-backward {
    left: 0;
    transform-origin: right center;
    animation: testimonialPageTurnBackward 560ms cubic-bezier(0.55, 0.05, 0.35, 1) both;
}

.testimonials-turn-face {
    position: absolute;
    inset: 0;
    overflow: hidden;
    backface-visibility: hidden;
}

.testimonials-turn-back {
    transform: rotateY(180deg);
}

.testimonials-turn-page {
    width: 100%;
    height: 100%;
    min-height: 100% !important;
    border-radius: 0 !important;
    box-shadow: inset 12px 0 18px -18px rgba(43, 31, 22, 0.9) !important;
    backface-visibility: hidden;
}

.testimonials-turn-back .testimonials-turn-page {
    box-shadow: inset -12px 0 18px -18px rgba(43, 31, 22, 0.9) !important;
}

@keyframes testimonialPageTurnForward {
    0% { transform: rotateY(0); }
    50% { box-shadow: 0 10px 24px rgba(25, 18, 13, 0.35); }
    100% { transform: rotateY(-180deg); }
}

@keyframes testimonialPageTurnBackward {
    0% { transform: rotateY(0); }
    50% { box-shadow: 0 10px 24px rgba(25, 18, 13, 0.35); }
    100% { transform: rotateY(180deg); }
}

.testimonials-book-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    width: min(100%, 840px);
    margin: 1rem auto 0;
}

.testimonials-book-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    min-height: 46px;
    padding: 0.65rem 1rem;
    border: 1px solid #c9d9d5;
    border-radius: 999px;
    background: #fff;
    color: #18434a;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.testimonials-book-button:not(:disabled):hover {
    transform: translateY(-2px);
    background: #18434a;
    color: #fff;
}

.testimonials-book-button:focus-visible {
    outline: 3px solid #1696a0;
    outline-offset: 3px;
}

.testimonials-book-button:disabled {
    opacity: 0.48;
    cursor: not-allowed;
}

.testimonials-book-page-count {
    margin: 0;
    color: #46515a;
    font-size: 0.95rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

@media (max-width: 768px) {
    .testimonials-book-stage {
        padding: 0.55rem;
        border-radius: 0.55rem;
    }

    .testimonials-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 0;
    }

    .testimonials-grid::before {
        display: none;
    }

    .testimonial-video-card {
        min-height: 450px !important;
    }

    .testimonial-video-card:not([hidden]) {
        grid-column: 1;
        border-radius: 0.2rem;
    }

    .testimonials-turn-leaf {
        left: 0 !important;
        right: 0 !important;
        width: 100%;
        transform-origin: left center !important;
    }

    .testimonial-video-card .play-overlay {
        width: 35px;
        height: 35px;
        font-size: 14px;
    }

    .testimonials-book-button {
        min-height: 42px;
        gap: 0.35rem;
        padding: 0.55rem 0.75rem;
        font-size: 0.85rem;
    }

    .testimonials-book-page-count {
        font-size: 0.8rem;
        white-space: nowrap;
    }
}

@media (prefers-reduced-motion: reduce) {
    .testimonials-turn-leaf {
        animation-duration: 1ms;
    }
}

/* ==================== 1. AURORA HEALTH: GLOBAL BACKGROUND ==================== */
body {
    background-color: var(--light-color);
    position: relative;
}

body::before, body::after {
    content: '';
    position: fixed;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    z-index: -1;
    filter: blur(120px);
    opacity: 0.4;
    animation: float 20s infinite ease-in-out alternate;
    pointer-events: none;
}

body::before {
    top: -100px;
    left: -100px;
    background: radial-gradient(circle, var(--secondary-color), transparent 70%);
}

body::after {
    bottom: -150px;
    right: -100px;
    background: radial-gradient(circle, var(--primary-color-light), transparent 70%);
    animation-delay: -10s;
}

@keyframes float {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(100px, 150px) scale(1.2); }
}

/* ==================== 2. AURORA HEALTH: GLASSMORPHISM CARDS ==================== */
.service-card, .team-card, .finding-card, .promotion-card, .room-modal-card {
    background: rgba(255, 255, 255, 0.45) !important;
    backdrop-filter: blur(25px) !important;
    -webkit-backdrop-filter: blur(25px) !important;
    border: 1px solid rgba(255, 255, 255, 0.6) !important;
    box-shadow: 0 10px 30px rgba(27, 20, 100, 0.05), inset 0 0 0 1px rgba(255, 255, 255, 0.5) !important;
    border-radius: 24px !important;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease, border-color 0.4s ease !important;
}

.service-card:hover, .team-card:hover, .finding-card:hover, .promotion-card:hover, .room-modal-card:hover {
    transform: translateY(-12px) scale(1.02) !important;
    box-shadow: 0 20px 40px rgba(18, 159, 179, 0.15), inset 0 0 0 1px rgba(255, 255, 255, 0.8) !important;
    border-color: var(--secondary-color) !important;
    background: rgba(255, 255, 255, 0.75) !important;
}

.service-info, .team-info, .finding-content, .promo-info, .room-modal-info {
    background: transparent !important;
}

/* ==================== 3. MOBILE TABS SCROLLING FIX ==================== */
.tab-buttons-wrapper {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
    padding-bottom: 10px;
    margin-bottom: 5px;
    
    /* Fade edges to indicate scrolling */
    -webkit-mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
    mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
}

.tab-buttons-wrapper::-webkit-scrollbar {
    height: 6px;
}

.tab-buttons-wrapper::-webkit-scrollbar-track {
    background: rgba(0,0,0,0.05);
    border-radius: 10px;
}

.tab-buttons-wrapper::-webkit-scrollbar-thumb {
    background: rgba(18, 159, 179, 0.3);
    border-radius: 10px;
}

.tab-buttons {
    display: flex;
    flex-wrap: nowrap !important;
    gap: 10px;
    width: max-content;
    padding: 0 10px; /* Buffer for the mask */
}

.tab-btn {
    white-space: nowrap;
    flex-shrink: 0;
}

/* Hide scroll hint text on desktop, show on mobile */
.tabs-scroll-hint {
    display: none;
    text-align: center;
    font-size: 13px;
    color: var(--gray-500);
    margin-bottom: 15px;
    animation: pulseHint 2s infinite;
}

@media (max-width: 768px) {
    .tabs-scroll-hint {
        display: block;
    }
}

@keyframes pulseHint {
    0%, 100% { opacity: 0.6; transform: translateX(0); }
    50% { opacity: 1; transform: translateX(3px); }
}

/* ==================== 4. MODAL FIXES (Semantic divs instead of labels & visibility) ==================== */
/* ==================== 4. MODAL FIXES (Semantic divs instead of labels & visibility) ==================== */
.room-modal-option {
    display: none !important;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    width: 100%;
}

.room-modal-option.active {
    display: flex !important;
    opacity: 1;
    transform: none;
}

.rooms-modal-grid {
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    overflow-y: auto;
    max-height: 65vh;
    padding: 10px 20px 20px;
}

/* Modal Tabs Styling */
.modal-tabs-wrapper {
    padding: 20px 20px 0;
    background: transparent;
    border-bottom: 1px solid rgba(27, 20, 100, 0.08);
}

.modal-tabs-container {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 10px;
    padding-bottom: 15px;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}

.modal-tabs-container::-webkit-scrollbar {
    height: 4px;
}
.modal-tabs-container::-webkit-scrollbar-thumb {
    background: rgba(18, 159, 179, 0.3);
    border-radius: 10px;
}

.modal-tab-btn {
    padding: 10px 20px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.5);
    border: 1px solid rgba(27, 20, 100, 0.1);
    color: var(--primary-color-dark);
    font-weight: 600;
    font-size: 0.95rem;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.modal-tab-btn:hover {
    background: rgba(255, 255, 255, 0.8);
    border-color: var(--secondary-color);
}

.modal-tab-btn.active {
    background: var(--secondary-color);
    color: #fff;
    border-color: var(--secondary-color);
    box-shadow: 0 4px 15px rgba(18, 159, 179, 0.3);
}

/* Modal Content Compactness (Fit everything in one screen) */
.room-features {
    display: flex !important;
    flex-direction: column !important; /* Force 1 column as requested */
    gap: 0 !important;
    margin-bottom: 15px !important;
}

.room-features li {
    padding: 6px 0 !important;
    font-size: 0.85rem !important;
    margin: 0 !important;
    background: transparent !important;
    border: none !important;
    border-bottom: 1px solid rgba(27, 20, 100, 0.05) !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    display: flex !important;
    align-items: center !important;
    line-height: 1.2 !important;
}

.room-features li i {
    font-size: 0.8rem !important;
    margin-right: 8px !important;
}

@media (max-width: 768px) {
    .room-modal-image {
        height: 120px !important;
        margin-bottom: 10px !important;
    }
    
    .room-modal-info h4 {
        font-size: 1.2rem !important;
        margin-bottom: 5px !important;
    }
    
    .room-modal-info p {
        font-size: 0.85rem !important;
        line-height: 1.3 !important;
        margin-bottom: 10px !important;
    }
    
    .room-modal-card {
        padding: 15px !important;
    }
    
    .modal-tabs-wrapper {
        padding: 15px 15px 0 !important;
    }
    
    .rooms-modal-grid {
        padding: 10px 15px 15px !important;
        max-height: 70vh !important;
    }
}

/* Custom scrollbar for grid */
.rooms-modal-grid::-webkit-scrollbar {
    width: 6px;
}
.rooms-modal-grid::-webkit-scrollbar-track {
    background: rgba(0,0,0,0.05);
}
.rooms-modal-grid::-webkit-scrollbar-thumb {
    background: var(--secondary-color);
    border-radius: 10px;
}

/* ==================== 5. GLOBAL TYPOGRAPHY NORMALIZATION & SPACING FIX ==================== */
/* Force sensible clamp sizes for all headings globally */
h1, h2, h3, h4, h5, h6 {
    line-height: 1.2 !important;
    margin-top: 0 !important;
}

h1 { font-size: clamp(2rem, 3.5vw, 2.75rem) !important; }
h2 { font-size: clamp(1.625rem, 2.7vw, 2rem) !important; }
h3 { font-size: clamp(1.25rem, 2vw, 1.5rem) !important; }
h4 { font-size: clamp(1.1rem, 1.5vw, 1.25rem) !important; }
h5 { font-size: clamp(1rem, 1.5vw, 1.1rem) !important; }

/* Specifically target the modal header to reduce the massive size and padding */
.modal-header {
    padding: 15px 20px !important;
    min-height: auto !important;
}

.modal-header h3 {
    margin: 0 !important;
    padding: 0 !important;
}

.modal-tabs-wrapper {
    padding: 10px 20px 0 !important;
    margin: 0 !important;
}

.rooms-modal-grid {
    padding: 5px 20px 10px !important;
    max-height: 85vh !important; /* Allow it to be slightly taller relative to viewport to avoid internal scrolling */
}

/* Unified Modal Card & Option Styles (Fixing HTML inconsistency) */
.room-modal-card, .room-modal-option.active {
    display: flex !important;
    flex-direction: column !important; /* Mobile First: Stack vertically */
    padding: 15px !important;
    gap: 15px !important;
    width: 100%;
    cursor: default;
}

/* Prevent double padding if nested */
.room-modal-option.active .room-modal-card {
    padding: 0 !important;
    margin: 0 !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

@media (min-width: 768px) {
    .modal-content {
        max-width: 950px !important;
    }

    .room-modal-card, .room-modal-option.active {
        padding: 20px 30px !important;
        flex-direction: row !important; /* Side by side on Desktop */
        justify-content: flex-start !important;
        align-items: center !important; 
    }
    
    .room-modal-image {
        flex: 0 0 260px !important; 
        max-width: 260px !important;
        min-width: 260px !important;
        margin-right: 40px !important;
        overflow: hidden !important;
        height: 200px !important; 
        border-radius: 12px !important;
    }

    /* Modal Content Compactness */
    .room-features {
        display: flex !important;
        flex-direction: column !important;
        gap: 8px !important; 
        margin-bottom: 12px !important;
    }
    .room-features li {
        margin-bottom: 0 !important;
        padding-bottom: 0 !important;
        border: none !important;
    }
    
    .show-more-btn { display: none !important; }
}

/* ==================== 6. SERVICES SEARCH ==================== */
.services-search-container {
    max-width: 700px;
    margin: 0 auto 30px;
    padding: 0 15px;
    position: relative;
}

.search-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 30px;
    padding: 5px 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.search-input-wrapper:focus-within {
    background: rgba(255, 255, 255, 0.9);
    border-color: var(--primary-color-light, #4bd1e3);
    box-shadow: 0 8px 32px rgba(18, 159, 179, 0.15), 0 0 0 3px rgba(18, 159, 179, 0.1);
    transform: translateY(-2px);
}

.search-icon {
    color: var(--primary-color);
    font-size: 1.1rem;
    margin-right: 15px;
}

#servicesSearch {
    flex: 1;
    background: transparent;
    border: none;
    padding: 12px 0;
    font-size: 1rem;
    color: var(--text-dark);
    outline: none;
    font-family: 'Inter', sans-serif;
}

#servicesSearch::placeholder {
    color: #888;
}

.clear-search-btn {
    background: none;
    border: none;
    color: #999;
    font-size: 1.1rem;
    cursor: pointer;
    padding: 5px 10px;
    transition: color 0.2s;
    outline: none;
}

.clear-search-btn:hover {
    color: #e74c3c;
}

.search-dropdown {
    position: absolute;
    top: 100%;
    left: 15px;
    right: 15px;
    background: #ffffff;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    margin-top: 5px;
    list-style: none;
    padding: 0;
    max-height: 350px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
}

.search-dropdown.active {
    display: block;
    animation: slideDown 0.2s ease;
}

.search-dropdown-item {
    padding: 15px 20px;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    display: flex;
    align-items: center;
    transition: background 0.2s;
    color: var(--text-dark);
}

.search-dropdown-item:last-child {
    border-bottom: none;
}

.search-dropdown-item:hover {
    background: #f8f9fa;
}

.search-dropdown-item i {
    color: var(--primary-color);
    margin-right: 15px;
    font-size: 1.1rem;
}

.search-dropdown-no-results {
    padding: 20px;
    text-align: center;
    color: var(--text-light);
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==================== 7. MURAL GALLERY (MASONRY GRID) ==================== */
.mural-container {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
    width: min(100%, 900px);
    margin: 0 auto;
    padding: 20px 0;
}

.mural-hidden {
    display: none !important;
}

@keyframes muralFadeIn {
    from { opacity: 0; transform: translateY(20px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.mural-container img {
    width: 100%;
    height: auto !important;
    display: block;
    min-width: 0;
    margin: 0;
    border-radius: 16px;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease, filter 0.4s ease;
    break-inside: avoid;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    filter: brightness(0.95);
    background-color: rgba(255, 255, 255, 0.1);
    animation: muralFadeIn 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.mural-container img:hover {
    transform: scale(1.03) translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
    filter: brightness(1.05);
    z-index: 10;
    position: relative;
}

.capsula-image-container {
    position: relative;
    height: 0;
    padding-bottom: 56.25%;
    margin-bottom: 20px;
    overflow: hidden;
    border: 1px solid rgba(27, 20, 100, 0.05);
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 8px 25px rgba(27, 20, 100, 0.08);
}

.capsula-image-container img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    object-fit: contain;
    cursor: pointer;
}

.capsula-description {
    white-space: pre-line;
}

#modalContent.capsula-modal-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    max-width: min(90vw, 900px);
    max-height: 95vh;
    overflow-y: auto;
}

.capsula-modal-caption {
    width: min(100%, 800px);
    padding: 0 16px 12px;
    color: #fff;
    text-align: center;
}

.capsula-modal-caption h2 {
    margin: 0;
    font-size: clamp(1.15rem, 2.5vw, 1.7rem);
}

.capsula-modal-caption p {
    margin: 8px 0 0;
    color: rgba(255, 255, 255, 0.88);
    line-height: 1.55;
    white-space: pre-line;
}

@media (max-width: 991px) {
    .mural-container {
        gap: 15px;
    }
    .mural-container img {
        border-radius: 12px;
    }
}

@media (max-width: 576px) {
    .mural-container {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }
    .mural-container img {
        border-radius: 8px;
    }

}

/* ==================== 8. FLOATING PROMO WIDGET ==================== */
.floating-promo-widget {
    position: fixed;
    bottom: 30px;
    left: 30px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white !important;
    padding: 15px; /* Aspecto circular por defecto */
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 0;
    box-shadow: 0 10px 30px rgba(18, 159, 179, 0.4);
    z-index: 999;
    text-decoration: none;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    animation: pulseGlow 2s infinite;
    overflow: hidden;
}

.floating-promo-widget:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 15px 40px rgba(18, 159, 179, 0.6);
    padding: 10px 20px; /* Se expande */
    gap: 15px;
}

.floating-promo-icon {
    font-size: 1.5rem;
    animation: bounceIcon 2s infinite;
}

.floating-promo-text {
    display: flex;
    flex-direction: column;
    max-width: 0;
    opacity: 0;
    white-space: nowrap;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.floating-promo-widget:hover .floating-promo-text {
    max-width: 250px;
    opacity: 1;
}

.floating-promo-title {
    font-weight: 700;
    font-size: 0.95rem;
    line-height: 1.2;
}

.floating-promo-timer {
    font-size: 0.8rem;
    opacity: 0.9;
    font-family: monospace;
    font-weight: 600;
    letter-spacing: 0.5px;
}

@keyframes pulseGlow {
    0% { box-shadow: 0 0 0 0 rgba(18, 159, 179, 0.6); }
    70% { box-shadow: 0 0 0 15px rgba(18, 159, 179, 0); }
    100% { box-shadow: 0 0 0 0 rgba(18, 159, 179, 0); }
}

@keyframes bounceIcon {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-5px); }
    60% { transform: translateY(-3px); }
}

@media (max-width: 768px) {
    .floating-promo-widget {
        bottom: 20px;
        left: 20px;
        padding: 8px 15px;
        gap: 10px;
    }
    .floating-promo-icon {
        font-size: 1.2rem;
    }
    .floating-promo-title {
        font-size: 0.85rem;
    }
    .floating-promo-timer {
        font-size: 0.75rem;
    }
}

/* ==================== 9. COMPACT LAYOUT & PROMO HEIGHT FIX ==================== */
/* Forzar que las tarjetas de promociones no se estiren */
.promotions-grid {
    align-items: flex-start !important;
}

.promotion-card {
    height: max-content !important;
    align-self: flex-start !important;
}

/* Reducir espacios entre secciones para hacer la web más compacta */
section:not(#hero):not(.hero-section) {
    padding: 50px 0 !important;
}

.section-header {
    margin-bottom: 30px !important;
}

.promotions-section {
    padding-bottom: 80px !important;
}

.team-section {
    padding-bottom: 20px !important;
}

.facilities-section {
    padding-top: 20px !important;
}

/* ==================== 10. EQUIPO Y SALAS (AJUSTES) ==================== */
/* Reducir espacio exagerado entre encabezados/filtros y tarjetas */
.specialty-filters-container {
    margin-bottom: 20px !important;
}

.team-grid-container,
.facilities-grid-container {
    padding-top: 0 !important;
}

/* Centrar las cuadrículas y reducir espacio con los bordes */
.team-grid,
.facilities-grid {
    justify-content: center !important;
    gap: 30px !important;
    max-width: 1100px;
    margin: 0 auto;
}

/* Reducir el tamaño de las letras gigantes en Equipo */
.team-card h3 {
    font-size: 1.25rem !important;
    line-height: 1.3 !important;
    margin: 15px 0 5px 0 !important;
}

.team-card p {
    font-size: 0.9rem !important;
}

/* Reducir texto en Salas */
.facility-card h3 {
    font-size: 1.25rem !important;
    margin-bottom: 10px !important;
}

/* ==================== 11. REDISEÑO CONTACTO Y UBICACIÓN ==================== */
.contact-top-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: start;
    max-width: 1100px;
    margin: 0 auto;
}

.contact-location-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    align-items: stretch;
    max-width: 1200px;
    margin: 0 auto;
}

.info-card.contact-direct-card {
    background-color: var(--white);
    padding: 25px;
    border-radius: var(--border-radius);
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.info-card.contact-direct-card h4 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.2rem;
}

@media (max-width: 800px) {
    .contact-top-grid,
    .contact-location-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

/* ==================== 12. MEJORAS DEL FOOTER ==================== */
.footer {
    padding: 70px 0 20px 0 !important;
    border-top: 4px solid var(--primary-color) !important;
    background: linear-gradient(to right, #0B0636, #1B1464) !important;
}

.footer-title {
    color: var(--white) !important;
    font-size: 1.15rem !important;
    margin-bottom: 25px !important;
    position: relative;
    padding-bottom: 12px;
}

.footer-title::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 40px;
    height: 3px;
    background: var(--secondary-color);
    border-radius: 2px;
}

.footer-description {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.6;
    margin-top: 15px;
}

.contact-social {
    display: flex;
    gap: 15px;
}

.contact-social a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255,255,255,0.1);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.contact-social a:hover {
    background-color: var(--secondary-color);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(18, 159, 179, 0.4);
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1) !important;
    margin-top: 40px !important;
    padding-top: 20px !important;
}

/* ==================== 13. IMÁGENES DE PROMOCIONES COMPLETAS ==================== */
.promotion-card .service-media-container {
    aspect-ratio: auto !important;
    height: auto !important;
    background: transparent !important;
}

.promotion-card .service-media-container img {
    object-fit: contain !important;
    height: auto !important;
    max-height: none !important;
    width: 100% !important;
    display: block;
}

#promociones .service-cards-grid {
    align-items: stretch !important;
    grid-auto-rows: 1fr;
}

#promociones .promotion-card {
    align-self: stretch !important;
    height: 100% !important;
    max-width: none !important;
}

#promociones .promotion-card .service-media-container {
    display: flex;
    align-items: center;
    justify-content: center;
    height: clamp(240px, 32vw, 360px) !important;
    min-height: clamp(240px, 32vw, 360px);
    max-height: clamp(240px, 32vw, 360px);
}

#promociones .promotion-card .service-media-container img {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
}

#promociones .promotion-card .service-info {
    flex: 1 1 auto;
}

#promociones .service-cards-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
    gap: clamp(18px, 3vw, 30px);
}

#promociones .promotion-card {
    border: 1px solid rgba(18, 159, 179, 0.2);
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 16px 36px rgba(27, 20, 100, 0.1);
}

#promociones .promotion-card::before {
    height: 5px;
}

#promociones .promotion-card .service-media-container {
    height: auto !important;
    min-height: 0;
    max-height: none;
    flex: 0 0 auto;
    height: clamp(320px, 36vw, 400px) !important;
    padding: 10px;
    background: #f7fbfc;
}

#promociones .promotion-card .service-media-container img {
    border-radius: 14px;
}

#promociones .promotion-card .service-info {
    gap: 12px;
    padding: 22px 24px 24px;
}

#promociones .promotion-card .service-info h3 {
    margin: 0;
    font-size: clamp(1.2rem, 2vw, 1.45rem) !important;
    line-height: 1.3 !important;
}

#promociones .promotion-card .promo-text-content {
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.55;
}

#promociones .promotion-card .promo-price-tag {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px 14px;
    width: 100%;
    margin: 2px 0;
    padding: 14px 16px;
    border: 1px solid rgba(18, 159, 179, 0.16);
    border-radius: 16px;
    background: linear-gradient(135deg, #f2fbfc, #f6f4ff);
}

#promociones .promotion-card .before-price {
    font-size: 0.875rem;
}

#promociones .promotion-card .actual-price {
    color: var(--primary-color-dark);
    font-size: clamp(1.45rem, 4vw, 1.9rem);
    line-height: 1.15;
    text-align: right;
    white-space: nowrap;
}

#promociones .promotion-card .service-actions-row {
    margin-top: auto;
}

#promociones .promotion-card .whatsapp-btn {
    min-height: 50px;
    border-radius: 14px;
    font-size: 0.95rem;
}

@media (max-width: 480px) {
    #promociones .promotion-card .service-media-container {
        height: clamp(320px, 95vw, 380px) !important;
        padding: 8px;
    }

    #promociones .promotion-card .service-info {
        gap: 10px;
        padding: 18px;
    }

    #promociones .promotion-card .promo-price-tag {
        padding: 12px;
        gap: 8px;
    }

    #promociones .promotion-card .before-price {
        font-size: 0.8rem;
    }

    #promociones .promotion-card .actual-price {
        font-size: 1.45rem;
    }
}

/* Promotions: clearer value, pricing, and consultation action */
#promociones {
    padding-block: clamp(3rem, 7vw, 5.5rem);
    background:
        radial-gradient(ellipse at 50% 0, rgba(18, 159, 179, 0.08), transparent 55%),
        linear-gradient(180deg, #f8fcfd 0%, #fff 45%);
}

#promociones .global-time-banner {
    width: min(100% - 24px, 680px);
    margin: 0 auto clamp(2rem, 5vw, 3.5rem);
    padding: clamp(16px, 3vw, 22px);
    border-radius: 20px;
}

#promociones .flash-content { gap: 8px; }
#promociones .flash-icon { font-size: 1.5rem; }
#promociones .flash-text {
    font-size: clamp(0.85rem, 2.5vw, 1rem);
    line-height: 1.4;
}
#promociones .flash-content {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: clamp(12px, 2.5vw, 22px);
}

#promociones .promo-countdown-copy {
    display: grid;
    justify-items: start;
    gap: 5px;
    min-width: 0;
}

#promociones .promo-countdown-copy .flash-text {
    text-align: left;
}

#promociones .promo-countdown-dates {
    color: rgba(255, 255, 255, 0.9);
    font-size: clamp(0.78rem, 2vw, 0.95rem);
    font-weight: 600;
}

#promociones .promo-countdown-badge {
    display: grid;
    place-items: center;
    min-width: 116px;
    padding: 10px 16px;
    border: 2px solid rgba(255, 255, 255, 0.75);
    border-radius: 16px;
    background: #fff;
    color: #1b1464;
    box-shadow: 0 6px 18px rgba(8, 20, 55, 0.22);
    text-align: center;
}

#promociones .promo-countdown-number {
    font-size: clamp(1.7rem, 4vw, 2.35rem);
    font-weight: 900;
    line-height: 1;
}

#promociones .promo-countdown-label {
    margin-top: 4px;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

#promociones .promo-countdown-badge.is-last-day {
    border-color: #ffe0d6;
    background: #fff0eb;
    color: #a52c12;
    animation: promo-countdown-pulse 1.8s ease-in-out infinite;
}

@keyframes promo-countdown-pulse {
    50% { transform: scale(1.045); box-shadow: 0 8px 24px rgba(165, 44, 18, 0.32); }
}

#promociones .live-countdown-clock { padding: 7px 16px; }
#promociones .countdown-unit { min-width: clamp(42px, 8vw, 58px); }
#promociones .countdown-num { font-size: clamp(1.25rem, 3vw, 1.65rem); }

#promociones .section-header {
    max-width: 760px;
    margin: 0 auto clamp(1.75rem, 4vw, 2.75rem);
    padding-inline: 12px;
}

#promociones .section-header h2 {
    margin-bottom: 10px;
    font-size: clamp(1.8rem, 4vw, 2.65rem);
    line-height: 1.12;
}

#promociones .section-subtitle {
    max-width: 650px;
    font-size: clamp(0.98rem, 2vw, 1.1rem);
}

@media (max-width: 560px) {
    #promociones .flash-content {
        grid-template-columns: auto minmax(0, 1fr);
    }

    #promociones .promo-countdown-badge {
        grid-column: 1 / -1;
        justify-self: center;
        min-width: min(100%, 210px);
        padding: 10px 24px;
    }
}

@media (prefers-reduced-motion: reduce) {
    #promociones .promo-countdown-badge.is-last-day {
        animation: none;
    }
}

#promociones .service-cards-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr));
    align-items: stretch;
    gap: clamp(18px, 3vw, 28px);
    max-width: 1020px;
    padding-inline: 12px;
}

#promociones .promotion-card {
    overflow: hidden;
    border: 1px solid #e2eaf2;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 12px 34px rgba(30, 58, 95, 0.09);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

#promociones .promotion-card:hover {
    transform: translateY(-5px);
    border-color: rgba(18, 159, 179, 0.38);
    box-shadow: 0 20px 42px rgba(30, 58, 95, 0.15);
}

#promociones .promotion-card::before { height: 4px; }

#promociones .promotion-card .service-media-container {
    position: relative;
    display: flex;
    height: clamp(280px, 32vw, 370px) !important;
    min-height: 0;
    max-height: none;
    align-items: center;
    justify-content: center;
    padding: 18px;
    background: linear-gradient(145deg, #f0f8fa, #f6f5fc);
}

#promociones .promotion-card .service-media-container img {
    width: 100% !important;
    height: 100% !important;
    border-radius: 12px;
    object-fit: contain !important;
}

#promociones .promo-savings-badge {
    position: absolute;
    top: 16px;
    left: 16px;
    z-index: 2;
    display: inline-flex;
    min-height: 36px;
    align-items: center;
    gap: 7px;
    padding: 7px 12px;
    border: 2px solid #fff;
    border-radius: 999px;
    background: #b42318;
    color: #fff;
    box-shadow: 0 5px 14px rgba(127, 29, 29, 0.22);
    font-size: 0.88rem;
    font-weight: 800;
}

#promociones .promotion-card .service-info {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    gap: 12px;
    padding: 22px 24px 24px;
}

#promociones .promotion-card .service-info h3 {
    margin: 0;
    color: #172554;
    font-size: clamp(1.2rem, 2vw, 1.45rem) !important;
    line-height: 1.3 !important;
}

#promociones .promotion-card .promo-text-content {
    margin: 0;
    color: #475569;
    font-size: 0.95rem;
    line-height: 1.55;
}

#promociones .promotion-card .promo-price-tag {
    display: flex;
    width: 100%;
    align-items: stretch;
    justify-content: space-between;
    gap: 12px;
    margin: 2px 0 0;
    padding: 14px 16px;
    border: 1px solid #d9e8ef;
    border-radius: 16px;
    background: linear-gradient(135deg, #f4fbfc, #f7f5ff);
}

#promociones .promotion-card .before-price,
#promociones .promotion-card .actual-price {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 3px;
    text-decoration: none;
}

#promociones .promotion-card .before-price {
    color: #64748b;
    font-size: 0.92rem;
    font-weight: 600;
}

#promociones .promotion-card .before-price > span { text-decoration: line-through; }

#promociones .promotion-card .actual-price {
    color: #172554;
    font-size: clamp(1.5rem, 4vw, 1.85rem);
    font-weight: 900;
    line-height: 1.1;
    text-align: right;
    white-space: nowrap;
}

#promociones .promotion-card .before-price small,
#promociones .promotion-card .actual-price small {
    color: #64748b;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

#promociones .promotion-card .promo-savings-detail {
    display: flex;
    align-items: center;
    gap: 7px;
    margin: -4px 0 0;
    color: #087443;
    font-size: 0.9rem;
    font-weight: 800;
}

#promociones .promotion-card .service-actions-row {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: auto;
    padding-top: 4px;
}

#promociones .promotion-card .whatsapp-btn {
    display: flex;
    width: 100%;
    min-height: 52px;
    align-items: center;
    justify-content: center;
    gap: 9px;
    border-radius: 14px;
    background: linear-gradient(135deg, #0b7a4b, #08613e);
    box-shadow: 0 8px 18px rgba(8, 97, 62, 0.2);
    color: #fff;
    font-size: 1rem;
    font-weight: 800;
    text-align: center;
    text-decoration: none;
}

#promociones .promotion-card .whatsapp-btn:hover {
    background: linear-gradient(135deg, #096b41, #064e32);
}

#promociones .promotion-card .promo-response-hint {
    color: #64748b;
    font-size: 0.78rem;
    text-align: center;
}

@media (max-width: 575px) {
    #promociones .global-time-banner {
        width: calc(100% - 24px);
        padding: 14px 10px;
        border-radius: 16px;
    }

    #promociones .live-countdown-clock {
        gap: 4px;
        padding: 7px 9px;
    }

    #promociones .countdown-unit { min-width: 42px; }
    #promociones .countdown-num { font-size: 1.3rem; }
    #promociones .countdown-label { font-size: 0.55rem; }

    #promociones .service-cards-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 18px;
        padding-inline: 8px;
    }

    #promociones .promotion-card .service-media-container {
        height: clamp(250px, 78vw, 330px) !important;
        padding: 12px;
    }

    #promociones .promo-savings-badge {
        top: 12px;
        left: 12px;
        min-height: 32px;
        font-size: 0.8rem;
    }

    #promociones .promotion-card .service-info {
        gap: 10px;
        padding: 18px;
    }

    #promociones .promotion-card .promo-price-tag {
        gap: 8px;
        padding: 12px;
    }

    #promociones .promotion-card .actual-price { font-size: 1.45rem; }
}

@media (max-width: 360px) {
    #promociones .promotion-card .promo-price-tag {
        flex-direction: column;
        align-items: flex-start;
    }

    #promociones .promotion-card .actual-price {
        align-items: flex-start;
        text-align: left;
    }
}

/* Responsive headings and cards for Salas and the welcome gallery */
#salas .salas-content h1 {
    font-size: clamp(1.5rem, 5vw, 2.75rem) !important;
    line-height: 1.15 !important;
    overflow-wrap: anywhere;
}

#salas .salas-content {
    padding-inline: clamp(1.5rem, 5vw, 4rem);
}

#salas .salas-subtitle {
    max-width: 720px;
    margin: 0 auto clamp(1.5rem, 4vw, 3rem);
    padding: 0 0.5rem;
    font-size: clamp(0.95rem, 2.5vw, 1.25rem);
    line-height: 1.55;
}

#salas .salas-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
    align-items: stretch;
}

#salas .sala-video h2 {
    font-size: clamp(1.125rem, 3vw, 1.45rem) !important;
    line-height: 1.25 !important;
    overflow-wrap: anywhere;
}

#salas .sala-info {
    padding: clamp(1rem, 3vw, 1.75rem);
}

#galeria .parents-gallery .gallery-subtitle {
    max-width: 100%;
    margin-inline: auto;
    font-size: clamp(1.2rem, 4vw, 1.6rem) !important;
    line-height: 1.25 !important;
    overflow-wrap: anywhere;
}

#galeria .parents-gallery .gallery-text {
    max-width: 700px;
    margin-bottom: clamp(1rem, 3vw, 3rem);
    font-size: clamp(0.875rem, 2.2vw, 1.05rem);
    line-height: 1.6;
}

/* Keep the primary booking action visible while the navigation collapses. */
.navbar {
    min-height: 60px;
}

.nav-logo {
    flex: 0 0 auto;
}

.nav-menu {
    flex: 1 1 auto;
    min-width: 0;
    justify-content: flex-end;
    gap: clamp(0.2rem, 0.55vw, 0.65rem);
}

.nav-menu .nav-link {
    padding-inline: clamp(0.2rem, 0.4vw, 0.5rem);
    white-space: nowrap;
}

.nav-booking {
    flex: 0 0 auto;
    width: auto;
    white-space: nowrap;
    text-decoration: none;
    margin-left: clamp(0.35rem, 0.8vw, 0.75rem);
    padding: 0.65rem 1rem;
}

@media (max-width: 1200px) {
    .navbar {
        min-height: 68px;
        gap: 0.75rem;
    }

    .nav-menu {
        display: none;
    }

    .nav-menu.active {
        display: flex;
        position: absolute;
        top: 100%;
        right: 0;
        bottom: auto;
        left: 0;
        width: 100%;
        height: calc(100vh - 60px);
        height: calc(100dvh - 60px);
        max-height: calc(100vh - 60px);
        max-height: calc(100dvh - 60px);
        z-index: 1002;
        overflow-x: hidden;
        overflow-y: auto;
        overscroll-behavior: contain;
        flex-direction: column;
        align-items: stretch;
        justify-content: flex-start;
        gap: 0;
        margin: 0;
        padding: 0.75rem 1rem 1.5rem;
        background: linear-gradient(180deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    }

    .nav-menu .nav-item {
        width: 100%;
        margin: 0;
    }

    .nav-menu .nav-link {
        width: 100%;
        min-height: 48px;
        justify-content: center;
        padding: 0.75rem 1rem;
        white-space: normal;
        text-align: center;
    }

    .nav-menu .nav-link::after {
        display: none;
    }

    .nav-booking {
        margin-left: auto;
        width: auto;
        margin-block: 0;
        padding: 0.6rem 0.9rem;
        font-size: 0.85rem;
    }

    .hamburger {
        display: flex;
        flex: 0 0 40px;
        width: 40px;
        height: 40px;
        padding: 0.55rem;
    }

    .hamburger .bar {
        height: 3px;
    }
}

@media (max-width: 360px) {
    .navbar {
        gap: 0.4rem;
        padding-inline: 0.6rem;
    }

    .nav-logo img {
        height: 38px;
    }

    .nav-booking {
        gap: 0.35rem;
        margin-left: auto;
        padding: 0.55rem 0.65rem;
        font-size: 0.75rem;
    }
}

@media (max-width: 1024px) {
    #servicios .tab-buttons-wrapper {
        display: block !important;
        width: 100% !important;
        overflow: visible !important;
        padding: 0;
        margin: 0;
        -webkit-mask-image: none;
        mask-image: none;
    }

    #servicios .tab-buttons {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: 100% !important;
        max-width: 100% !important;
        overflow: visible !important;
        justify-content: stretch !important;
        gap: 8px !important;
        margin: 0 !important;
        padding: 6px !important;
        border-radius: 20px !important;
        white-space: normal !important;
    }

    #servicios .tab-btn {
        min-width: 0;
        min-height: 48px;
        justify-content: center !important;
        padding: 10px 8px !important;
        white-space: normal !important;
        text-align: center;
        line-height: 1.25;
    }
}

@media (max-width: 480px) {
    #servicios .tab-btn {
        gap: 6px;
        padding-inline: 6px !important;
        font-size: 0.82rem !important;
    }
}

@media (max-width: 767px) {
    .premium-modal .modal-content {
        width: calc(100% - 24px) !important;
        max-width: 560px !important;
        max-height: 94vh !important;
        max-height: 94dvh !important;
        margin: 3vh auto !important;
    }

    .premium-modal .modal-header {
        flex: 0 0 auto;
        padding: 12px 48px 12px 14px !important;
    }

    .premium-modal .modal-header h3 {
        font-size: clamp(1rem, 4vw, 1.125rem) !important;
        line-height: 1.3 !important;
        overflow-wrap: anywhere;
    }

    .modal-option-selector {
        grid-template-columns: max-content minmax(0, 1fr);
        gap: 8px;
        padding: 12px 14px 8px;
        font-size: 0.85rem;
    }

    .modal-option-menu {
        max-height: min(260px, 40vh);
    }

    .modal-option-item {
        min-height: 40px;
        padding: 8px 10px;
        font-size: 0.875rem;
    }

    .premium-modal .room-modal-info h4 {
        font-size: 1.125rem !important;
    }

    .premium-modal .room-modal-info p {
        font-size: 0.9rem !important;
    }

    .premium-modal .room-modal-info li {
        font-size: 0.875rem !important;
    }

    .premium-modal .modal-tabs-wrapper {
        flex: 0 0 auto;
        padding: 10px 12px 0 !important;
        overflow: visible !important;
    }

    .premium-modal .modal-tabs-container {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 6px !important;
        width: 100%;
        overflow: visible !important;
        padding: 0 0 10px !important;
    }

    .premium-modal .modal-tab-btn {
        min-width: 0;
        width: 100%;
        min-height: 40px;
        padding: 7px 6px !important;
        font-size: clamp(0.72rem, 3vw, 0.85rem) !important;
        line-height: 1.2;
        white-space: normal !important;
        overflow-wrap: anywhere;
    }

    .premium-modal .rooms-modal-grid {
        flex: 1 1 auto;
        min-height: 0;
        max-height: none !important;
        padding: 10px 12px 14px !important;
        overflow-x: hidden !important;
    }

    .premium-modal .room-modal-option.active,
    .premium-modal .room-modal-card,
    .premium-modal .room-modal-info {
        min-width: 0;
        width: 100%;
        box-sizing: border-box;
    }

    .premium-modal .room-modal-card {
        gap: 10px !important;
        padding: 12px !important;
    }

    .premium-modal .room-modal-image {
        height: clamp(130px, 38vw, 190px) !important;
        margin: 0 0 4px !important;
    }

    .premium-modal .room-modal-info {
        padding: 0 !important;
    }

    .premium-modal .room-features {
        grid-template-columns: minmax(0, 1fr) !important;
        padding: 0 !important;
    }
}

#contacto .contact-location-divider {
    margin: clamp(2rem, 5vw, 3.75rem) 0;
    border-top: 1px solid var(--border-color);
    opacity: 0.5;
}

#contacto .contact-location-single {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: stretch;
    gap: 1.25rem;
    width: min(100%, 1080px);
    margin: 0 auto;
}

#contacto .location-visual-header {
    grid-column: 1 / -1;
    margin-bottom: 0;
    text-align: center;
}

#contacto .location-visual-header h3 {
    margin: 0 0 0.65rem;
    color: var(--primary-color);
    font-size: clamp(1.25rem, 2.8vw, 1.7rem);
    line-height: 1.25;
}

#contacto .location-visual-header p {
    max-width: 760px;
    margin: 0 auto;
    color: var(--text-light);
    font-size: 0.98rem;
    line-height: 1.55;
}

#contacto .google-maps-btn {
    display: inline-flex;
    justify-content: center;
    width: min(100%, 520px);
    min-height: 48px;
    margin-top: 1.1rem;
    padding: 0.75rem 1.25rem;
    border-radius: 12px;
    background: var(--primary-color);
    color: #fff;
    text-align: center;
}

#contacto .contact-map {
    display: flex;
    align-items: stretch;
    width: 100%;
    height: auto;
    min-height: 340px;
    margin: 0;
    overflow: hidden;
    border: 1px solid rgba(27, 20, 100, 0.08);
    border-radius: 18px;
    background: #edf4f2;
    box-shadow: 0 12px 32px rgba(27, 20, 100, 0.08);
}

#contacto .contact-map svg {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 340px;
}

#contacto .location-video-wrapper {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
    margin: 0;
    padding: 1rem;
    border: 1px solid rgba(27, 20, 100, 0.08);
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 12px 32px rgba(27, 20, 100, 0.08);
    text-align: center;
}

#contacto .location-video-wrapper h4 {
    margin: 0 0 0.8rem;
    color: var(--primary-color);
    font-size: 1.1rem;
}

#contacto .location-video-wrapper video {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 12px;
    background: #111;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    object-fit: cover;
}

#contacto .location-video-wrapper figcaption {
    margin-top: 0.75rem;
    color: var(--text-light);
    font-size: 0.88rem;
    line-height: 1.45;
}

@media (max-width: 720px) {
    #contacto .contact-location-single {
        grid-template-columns: minmax(0, 1fr);
        gap: 1rem;
    }

    #contacto .location-visual-header {
        grid-column: auto;
    }

    #contacto .contact-map,
    #contacto .contact-map svg {
        min-height: 260px;
    }

    #contacto .contact-map svg {
        height: auto;
    }
}

/* Editorial photo layout for the doctor's gallery; the baby gallery keeps its grid. */
#galeria .doctor-gallery {
    padding: clamp(1.5rem, 4vw, 3.5rem);
    overflow: hidden;
    background:
        radial-gradient(circle at 100% 0, rgba(18, 159, 179, 0.09), transparent 28rem),
        #fff;
}

#galeria .doctor-gallery-heading {
    max-width: 760px;
    margin: 0 auto clamp(1.5rem, 3vw, 2.5rem);
}

#galeria .doctor-gallery-kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.8rem;
    color: #087180;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

#galeria .doctor-gallery-kicker::before {
    width: 1.75rem;
    height: 2px;
    background: currentColor;
    content: "";
}

#galeria .doctor-gallery .gallery-subtitle {
    max-width: 680px;
    margin: 0 auto 0.9rem;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(2rem, 4vw, 3.35rem);
    font-weight: 600;
    line-height: 1.05;
    letter-spacing: -0.035em;
}

#galeria .doctor-gallery .gallery-text {
    position: relative;
    max-width: 620px;
    margin: 0 auto;
    padding: 0 1.25rem;
    color: #42525b;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(1rem, 1.7vw, 1.2rem);
    font-style: italic;
    line-height: 1.65;
}

#galeria .doctor-gallery-mural {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-auto-rows: clamp(150px, 18vw, 220px);
    gap: clamp(0.55rem, 1.3vw, 1rem);
    width: min(100%, 1100px);
    padding: 0;
    margin: 0 auto;
}

#galeria .doctor-gallery-mural img {
    width: 100%;
    height: 100% !important;
    min-width: 0;
    min-height: 0;
    margin: 0;
    border-radius: 0.65rem;
    object-fit: cover;
    object-position: center 35%;
    box-shadow: 0 8px 24px rgba(11, 28, 48, 0.12);
    filter: none;
    cursor: zoom-in !important;
    animation: none;
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}

#galeria .doctor-gallery-mural img:hover {
    z-index: 1;
    box-shadow: 0 16px 34px rgba(11, 28, 48, 0.2);
    filter: none;
    transform: scale(1.025);
}

#galeria .doctor-gallery-mural .mural-featured {
    grid-column: span 2;
    grid-row: span 2;
    object-position: center 30%;
}

#galeria .doctor-gallery .mural-load-more {
    margin-top: 1.5rem !important;
}

#galeria .doctor-gallery .mural-load-more .cta-button {
    min-height: 48px;
    padding: 0.75rem 1.5rem !important;
    border-radius: 999px !important;
    font-weight: 700 !important;
}

@media (max-width: 600px) {
    #galeria .doctor-gallery {
        padding: 1.35rem 1rem;
        border-radius: 1.25rem;
    }

    #galeria .doctor-gallery-heading {
        margin-bottom: 1.25rem;
        text-align: left;
    }

    #galeria .doctor-gallery .gallery-subtitle {
        margin-inline: 0;
        font-size: clamp(1.8rem, 8vw, 2.5rem) !important;
    }

    #galeria .doctor-gallery .gallery-text {
        margin-inline: 0;
        padding-inline: 0;
        font-size: 1rem;
    }

    #galeria .doctor-gallery-mural {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        grid-auto-rows: clamp(130px, 42vw, 180px);
        gap: 0.55rem;
    }

    #galeria .doctor-gallery-mural .mural-featured {
        grid-column: span 2;
        grid-row: span 2;
    }

    #galeria .doctor-gallery-mural img:nth-child(6n):not(.mural-hidden) {
        grid-column: span 2;
    }

    #galeria .doctor-gallery-mural img {
        border-radius: 0.55rem;
    }
}

#galeria .parents-gallery {
    padding: clamp(1.5rem, 4vw, 3.5rem);
    overflow: hidden;
    background:
        radial-gradient(circle at 0 100%, rgba(232, 160, 176, 0.12), transparent 28rem),
        #fff;
}

#galeria .parents-gallery-heading {
    max-width: 760px;
    margin: 0 auto clamp(1.5rem, 3vw, 2.5rem);
}

#galeria .parents-gallery-kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.8rem;
    color: #9a4560;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

#galeria .parents-gallery-kicker::before {
    width: 1.75rem;
    height: 2px;
    background: currentColor;
    content: "";
}

#galeria .parents-gallery .gallery-subtitle {
    max-width: 680px;
    margin: 0 auto 0.9rem;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(2rem, 4vw, 3.35rem) !important;
    font-weight: 600;
    line-height: 1.05 !important;
    letter-spacing: -0.035em;
}

#galeria .parents-gallery .gallery-text {
    max-width: 620px;
    margin: 0 auto;
    padding: 0 1.25rem;
    color: #42525b;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(1rem, 1.7vw, 1.2rem) !important;
    font-style: italic;
    line-height: 1.65;
}

#galeria .parents-gallery-mural {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-auto-rows: clamp(150px, 18vw, 220px);
    gap: clamp(0.55rem, 1.3vw, 1rem);
    width: min(100%, 1100px);
    padding: 0;
    margin: 0 auto;
}

#galeria .parents-gallery-mural img {
    width: 100%;
    height: 100% !important;
    min-width: 0;
    min-height: 0;
    margin: 0;
    border-radius: 0.65rem;
    object-fit: cover;
    object-position: center;
    box-shadow: 0 8px 24px rgba(11, 28, 48, 0.12);
    filter: none;
    cursor: zoom-in !important;
    animation: none;
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}

#galeria .parents-gallery-mural img:hover {
    z-index: 1;
    box-shadow: 0 16px 34px rgba(11, 28, 48, 0.2);
    filter: none;
    transform: scale(1.025);
}

#galeria .parents-gallery-mural .mural-featured {
    grid-column: span 2;
    grid-row: span 2;
    object-position: center 38%;
}

#galeria .parents-gallery .mural-load-more {
    margin-top: 1.5rem !important;
}

#galeria .parents-gallery .mural-load-more .cta-button {
    min-height: 48px;
    padding: 0.75rem 1.5rem !important;
    border-radius: 999px !important;
    font-weight: 700 !important;
}

@media (max-width: 600px) {
    #galeria .parents-gallery {
        padding: 1.35rem 1rem;
        border-radius: 1.25rem;
    }

    #galeria .parents-gallery-heading {
        margin-bottom: 1.25rem;
        text-align: left;
    }

    #galeria .parents-gallery .gallery-subtitle {
        margin-inline: 0;
        font-size: clamp(1.8rem, 8vw, 2.5rem) !important;
    }

    #galeria .parents-gallery .gallery-text {
        margin-inline: 0;
        padding-inline: 0;
        font-size: 1rem !important;
    }

    #galeria .parents-gallery-mural {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        grid-auto-rows: clamp(130px, 42vw, 180px);
        gap: 0.55rem;
    }

    #galeria .parents-gallery-mural .mural-featured {
        grid-column: span 2;
        grid-row: span 2;
    }

    #galeria .parents-gallery-mural img:nth-child(6n):not(.mural-hidden) {
        grid-column: span 2;
    }

    #galeria .parents-gallery-mural img {
        border-radius: 0.55rem;
    }
}

#capsulas .section-header {
    margin-bottom: clamp(1.5rem, 4vw, 2.5rem);
}

#capsulas .capsulas-magazine {
    width: min(100%, 980px);
    margin: 0 auto;
}

#capsulas .capsulas-book-stage {
    position: relative;
    perspective: 2200px;
    padding: clamp(0.7rem, 2vw, 1.35rem);
    border: 1px solid #3e2a22;
    border-radius: 0.65rem;
    background:
        linear-gradient(135deg, #715141 0%, #3c2923 45%, #634435 100%);
    box-shadow: 0 26px 55px rgba(37, 24, 19, 0.24), inset 0 0 0 2px rgba(230, 207, 166, 0.2);
}

#capsulas .capsulas-book-stage::before,
#capsulas .capsulas-book-stage::after {
    position: absolute;
    z-index: 2;
    top: 1.8rem;
    bottom: 1.8rem;
    width: 0.45rem;
    border-radius: 3px;
    background: repeating-linear-gradient(180deg, #eee8d8 0, #eee8d8 2px, #d8d0be 3px, #f8f4e9 4px);
    box-shadow: 0 2px 5px rgba(24, 16, 12, 0.22);
    content: "";
    pointer-events: none;
}

#capsulas .capsulas-book-stage::before {
    left: 0.4rem;
}

#capsulas .capsulas-book-stage::after {
    right: 0.4rem;
}

#capsulas .capsulas-grid-magazine {
    position: relative;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 2px;
    align-items: stretch;
    margin: 0;
    overflow: visible;
    background: #8e7860;
    box-shadow: 0 4px 14px rgba(24, 16, 12, 0.3);
    transform-style: preserve-3d;
}

#capsulas .capsulas-grid-magazine::before {
    position: absolute;
    z-index: 3;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 1.25rem;
    background: linear-gradient(90deg, rgba(66, 49, 34, 0.15), rgba(64, 46, 31, 0.3) 46%, rgba(255, 255, 255, 0.55) 50%, rgba(87, 65, 44, 0.22) 56%, rgba(66, 49, 34, 0.12));
    content: "";
    pointer-events: none;
    transform: translateX(-50%);
}

#capsulas .capsulas-grid-magazine > .capsulas-magazine-page {
    grid-row: 1;
    width: 100%;
    min-width: 0;
    min-height: 390px !important;
    margin: 0;
    overflow: hidden;
    border: 0 !important;
    border-radius: 0 !important;
    background:
        repeating-linear-gradient(0deg, rgba(117, 96, 66, 0.025) 0, rgba(117, 96, 66, 0.025) 1px, transparent 1px, transparent 6px),
        #fffefa !important;
    box-shadow: none !important;
    backface-visibility: visible;
}

#capsulas .capsulas-grid-magazine > .capsulas-magazine-page[hidden] {
    display: none !important;
}

#capsulas .capsulas-grid-magazine > .capsulas-magazine-page:not([hidden]):nth-of-type(odd) {
    grid-column: 1;
    border-radius: 0.12rem 0 0 0.12rem !important;
    box-shadow: inset -12px 0 16px -17px rgba(43, 31, 22, 0.8) !important;
}

#capsulas .capsulas-grid-magazine > .capsulas-magazine-page:not([hidden]):nth-of-type(even) {
    grid-column: 2;
    border-radius: 0 0.12rem 0.12rem 0 !important;
    box-shadow: inset 12px 0 16px -17px rgba(43, 31, 22, 0.8) !important;
}

#capsulas .capsulas-grid-magazine.capsulas-single-right > .capsulas-magazine-page:not([hidden]) {
    grid-column: 2;
}

#capsulas .capsulas-grid-magazine > .capsulas-magazine-page:hover {
    transform: none !important;
    border-color: transparent !important;
    background-color: #fffefa !important;
}

#capsulas .capsulas-grid-magazine .finding-content {
    align-items: center;
    padding: clamp(1rem, 2.3vw, 2rem) !important;
}

#capsulas .capsulas-grid-magazine .finding-content h3 {
    width: 100%;
    min-height: 2.8em;
    margin: 0 auto 0.9rem;
    color: #27214f;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(1.05rem, 1.7vw, 1.45rem);
    font-weight: 700;
    line-height: 1.25;
    text-align: center;
}

#capsulas .capsulas-grid-magazine .capsula-image-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: auto;
    max-height: 63vh;
    min-height: 0;
    margin: 0 auto;
    padding: 0.25rem;
    overflow: hidden;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

#capsulas .capsulas-grid-magazine .capsula-image-container img {
    position: static;
    inset: auto;
    display: block;
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: calc(63vh - 0.5rem);
    object-fit: contain;
    cursor: zoom-in;
}

#capsulas .capsulas-grid-magazine .capsula-description {
    width: min(100%, 700px);
    margin: 1rem auto 0;
    color: #42525b;
    line-height: 1.65;
    text-align: left;
}

#capsulas .capsulas-turn-leaf {
    position: absolute;
    z-index: 5;
    top: 0;
    bottom: 0;
    width: calc(50% - 1px);
    transform-style: preserve-3d;
    pointer-events: none;
}

#capsulas .capsulas-turn-leaf.turn-forward {
    right: 0;
    transform-origin: left center;
    animation: capsulePageTurnForward 560ms cubic-bezier(0.55, 0.05, 0.35, 1) both;
}

#capsulas .capsulas-turn-leaf.turn-backward {
    left: 0;
    transform-origin: right center;
    animation: capsulePageTurnBackward 560ms cubic-bezier(0.55, 0.05, 0.35, 1) both;
}

#capsulas .capsulas-turn-leaf-face {
    position: absolute;
    inset: 0;
    overflow: hidden;
    backface-visibility: hidden;
}

#capsulas .capsulas-turn-leaf-back {
    transform: rotateY(180deg);
}

#capsulas .capsulas-grid-magazine .capsulas-turn-page {
    width: 100%;
    height: 100%;
    min-width: 0;
    min-height: 100%;
    margin: 0;
    overflow: hidden;
    border: 0 !important;
    border-radius: 0 !important;
    background:
        repeating-linear-gradient(0deg, rgba(117, 96, 66, 0.025) 0, rgba(117, 96, 66, 0.025) 1px, transparent 1px, transparent 6px),
        #fffefa !important;
    box-shadow: inset 12px 0 18px -18px rgba(43, 31, 22, 0.9) !important;
    backface-visibility: hidden;
    transform: none;
}

#capsulas .capsulas-grid-magazine .capsulas-turn-leaf-back .capsulas-turn-page {
    box-shadow: inset -12px 0 18px -18px rgba(43, 31, 22, 0.9) !important;
}

@keyframes capsulePageTurnForward {
    0% { transform: rotateY(0); }
    50% { box-shadow: 0 10px 24px rgba(25, 18, 13, 0.35); }
    100% { transform: rotateY(-180deg); }
}

@keyframes capsulePageTurnBackward {
    0% { transform: rotateY(0); }
    50% { box-shadow: 0 10px 24px rgba(25, 18, 13, 0.35); }
    100% { transform: rotateY(180deg); }
}

#capsulas .capsulas-book-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    width: min(100%, 840px);
    margin: 1rem auto 0;
}

#capsulas .capsulas-book-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    min-height: 46px;
    padding: 0.65rem 1rem;
    border: 1px solid #d6d2e6;
    border-radius: 999px;
    background: #fff;
    color: #21195b;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

#capsulas .capsulas-book-button:not(:disabled):hover {
    transform: translateY(-2px);
    background: #21195b;
    color: #fff;
}

#capsulas .capsulas-book-button:focus-visible {
    outline: 3px solid #129fb3;
    outline-offset: 3px;
}

#capsulas .capsulas-book-button:disabled {
    opacity: 0.48;
    cursor: not-allowed;
}

#capsulas .capsulas-book-page-count {
    margin: 0;
    color: #46515a;
    font-size: 0.95rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

@media (max-width: 600px) {
    #capsulas .capsulas-book-stage {
        padding: 0.55rem;
        border-radius: 0.55rem;
    }

    #capsulas .capsulas-book-stage::before,
    #capsulas .capsulas-book-stage::after {
        top: 1.25rem;
        bottom: 1.25rem;
        width: 0.3rem;
    }

    #capsulas .capsulas-book-stage::before {
        left: 0.25rem;
    }

    #capsulas .capsulas-book-stage::after {
        right: 0.25rem;
    }

    #capsulas .capsulas-grid-magazine {
        grid-template-columns: minmax(0, 1fr);
        gap: 0;
    }

    #capsulas .capsulas-grid-magazine::before {
        display: none;
    }

    #capsulas .capsulas-grid-magazine > .capsulas-magazine-page:not([hidden]) {
        grid-column: 1;
        border-radius: 0.12rem !important;
        box-shadow: inset 8px 0 14px -15px rgba(43, 31, 22, 0.8) !important;
    }

    #capsulas .capsulas-turn-leaf {
        left: 0 !important;
        right: 0 !important;
        width: 100%;
        transform-origin: left center !important;
    }

    #capsulas .capsulas-grid-magazine .finding-content {
        padding: 1rem !important;
    }

    #capsulas .capsulas-grid-magazine .finding-content h3 {
        margin-bottom: 0.8rem;
        min-height: 0;
        font-size: 1.2rem;
    }

    #capsulas .capsulas-grid-magazine .capsula-image-container {
        max-height: 65vh;
        padding: 0.35rem;
    }

    #capsulas .capsulas-grid-magazine .capsula-image-container img {
        max-height: calc(65vh - 0.7rem);
    }

    #capsulas .capsulas-grid-magazine .capsulas-turn-page .capsula-image-container {
        max-height: 65vh;
    }

    #capsulas .capsulas-grid-magazine .capsulas-turn-page .capsula-image-container img {
        max-height: calc(65vh - 0.7rem);
    }

    #capsulas .capsulas-book-controls {
        gap: 0.5rem;
    }

    #capsulas .capsulas-book-button {
        min-height: 42px;
        gap: 0.35rem;
        padding: 0.55rem 0.75rem;
        font-size: 0.85rem;
    }

    #capsulas .capsulas-book-page-count {
        font-size: 0.8rem;
        white-space: nowrap;
    }
}

@media (prefers-reduced-motion: reduce) {
    #capsulas .capsulas-grid-magazine .capsulas-turn-leaf {
        animation-duration: 1ms;
    }
}

    .modal-option-selector {
        display: grid;
        grid-template-columns: max-content minmax(0, 1fr);
        align-items: center;
        gap: 12px;
        padding: 16px 20px 10px;
        color: var(--primary-color-dark);
        font-size: 0.9rem;
        line-height: 1.3;
        font-weight: 700;
    }

    .modal-option-label {
        white-space: nowrap;
    }

    .modal-option-control {
        position: relative;
        min-width: 0;
    }

    .modal-option-select {
        position: relative;
        display: flex;
        align-items: center;
        width: 100%;
        min-height: 48px;
        margin-top: 0;
        padding: 10px 40px 10px 14px;
        border: 1px solid rgba(27, 20, 100, 0.2);
        border-radius: 10px;
        background: #fff;
        color: var(--primary-color-dark);
        font: inherit;
        font-weight: 700;
        line-height: 1.3;
        text-align: left;
        cursor: pointer;
        overflow: hidden;
    }

    .modal-option-current-label {
        display: -webkit-box;
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 2;
    }

    .modal-option-select::after {
        position: absolute;
        top: 50%;
        right: 16px;
        width: 8px;
        height: 8px;
        border-right: 2px solid currentColor;
        border-bottom: 2px solid currentColor;
        content: '';
        transform: translateY(-70%) rotate(45deg);
    }

    .modal-option-menu {
        position: absolute;
        z-index: 5;
        top: calc(100% + 4px);
        right: 0;
        left: 0;
        max-height: min(280px, 45vh);
        overflow-y: auto;
        padding: 6px;
        border: 1px solid rgba(27, 20, 100, 0.16);
        border-radius: 12px;
        background: #fff;
        box-shadow: 0 12px 28px rgba(27, 20, 100, 0.18);
    }

    .modal-option-menu[hidden] {
        display: none;
    }

    .modal-option-item {
        display: block;
        width: 100%;
        min-height: 42px;
        padding: 9px 12px;
        border: 0;
        border-radius: 8px;
        background: transparent;
        color: var(--primary-color-dark);
        font: inherit;
        font-weight: 600;
        line-height: 1.35;
        text-align: left;
        cursor: pointer;
    }

    .premium-modal .modal-header h3 {
        font-size: clamp(1.05rem, 2.2vw, 1.25rem) !important;
        line-height: 1.25 !important;
    }

    .premium-modal .room-modal-info h4 {
        font-size: clamp(1.125rem, 2vw, 1.25rem) !important;
        line-height: 1.25 !important;
    }

    .premium-modal .room-modal-info p {
        font-size: 0.95rem !important;
        line-height: 1.55 !important;
    }

    .premium-modal .room-modal-info li {
        font-size: 0.9rem !important;
        line-height: 1.4 !important;
    }

    .premium-modal .room-modal-info .btn-seleccionar {
        font-size: 0.95rem !important;
        line-height: 1.3 !important;
    }

    .modal-option-item:hover,
    .modal-option-item:focus-visible,
    .modal-option-item.selected {
        background: rgba(18, 159, 179, 0.1);
        color: var(--primary-color-dark);
    }

    .modal-option-item:focus-visible {
        outline: 2px solid var(--secondary-color);
        outline-offset: -2px;
    }

    .modal-option-select:focus-visible,
    .room-compare-select:focus-visible,
    .faq-item summary:focus-visible {
        outline: 3px solid var(--secondary-color);
        outline-offset: 2px;
    }

@media (max-width: 767px) {
    .modal-option-select {
        min-height: 44px;
        padding: 8px 32px 8px 10px;
    }

    .modal-option-select::after {
        right: 12px;
        width: 7px;
        height: 7px;
    }
}
