/* =========================================
   1. GLOBAL & BASE STYLES
   ========================================= */
   body {
    background-color: #faf8f5;
    color: #333333; 
}

.section-header {
    font-size: 3rem;
}

/* =========================================
   2. HEADER, NAVIGATION & BUTTONS
   ========================================= */
#mainNav {
    background-color: transparent !important;
    padding: 25px 0;
    border-bottom: 2px solid transparent !important; 
    transition: all 0.3s ease-in-out;
}

.navbar-brand {
    position: relative;
    height: 40px; 
    width: 200px; 
    border: none !important;
    outline: none !important;
    padding: 0;
    display: flex;
    align-items: center;
}

.nav-logo {
    position: absolute;
    top: 50%;
    left: -20%;
    transform: translateY(-50%); 
    height: 300px; 
    width: auto;
    object-fit: contain;
    transition: all 0.3s ease-in-out;
    filter: brightness(0) invert(1); 
}

#mainNav.scrolled {
    background-color: #ffffff !important;
    padding: 15px 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    border-bottom: 2px solid #d8b688 !important; 
}

#mainNav.scrolled .nav-logo {
    height: 230px; 
    filter: none; 
}

#mainNav .navbar-nav {
    transform: translateX(50px); 
}

#mainNav .nav-link, 
#mainNav .nav-icon-btn {
    color: #ffffff !important;
    font-weight: 600;
    transition: color 0.3s ease-in-out;
}

#mainNav .nav-link {
    font-size: 1.4rem;
    padding: 0.5rem 1rem !important; 
}

#mainNav .nav-icon-btn {
    font-size: 1.7rem;
    background: transparent;
    border: none;
}

#mainNav.scrolled .nav-link, 
#mainNav.scrolled .nav-icon-btn {
    color: var(--primary-blue, #163654) !important;
}

/* Header Right Actions & Book Button */
.header-right-actions {
    transform: translateX(80px); 
}

.btn-header-book {
    background-color: #d8b688;
    color: #ffffff;
    border: none;
    padding: 12px 32px;
    border-radius: 50px;
    font-size: 1.3rem;
    font-weight: 600;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.btn-header-book:hover {
    background-color: #c4a173;
    color: #ffffff;
    transform: translateY(-2px);
}

/* Active Page Highlight */
#mainNav .nav-link.active {
    color: #d8b688 !important;
    text-shadow: 0 0 10px rgba(216, 182, 136, 0.3); 
}

#mainNav.scrolled .nav-link.active {
    color: #d8b688 !important;
}

/* Header Hover Effects */
#mainNav .nav-link:hover,
#mainNav .nav-icon-btn:hover {
    transform: translateY(-2px);
}

/* =========================================
   3. TOP HERO SECTION
   ========================================= */
.hero-section {
    height: 70vh;
    min-height: 350px;
    width: 100%; 
    background-image: linear-gradient(to bottom, rgba(250, 248, 245, 0) 60%, rgba(250, 248, 245, 1) 100%), url('../images/bg-about.jpg');
    background-size: cover !important;
    background-position: center 20%;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.hero-overlay { 
    position: absolute; 
    inset: 0; 
    background: linear-gradient(to bottom, rgba(0, 0, 0, .7) 0%, rgba(0, 0, 0, .4) 100%, rgba(250, 248, 245, 1) 100%); 
}

.hero-content { 
    position: relative; 
    z-index: 2; 
    text-align: center; 
}

.hero-title { 
    font-size: 4rem; 
    color: #ffffff; 
    margin-bottom: 2rem; 
    text-shadow: 0 4px 15px rgba(0,0,0,0.3); 
    position: relative; 
    display: inline-block; 
}

/* Vanishing underline for TOP hero */
.hero-title::after {
    content: '';
    position: absolute;
    bottom: -5px; 
    left: 0;
    width: 100%;
    height: 4px; 
    background-color: #d8b688; 
    border-radius: 2px;
    animation: swipeUnderline 1s ease-in-out forwards;
}

@keyframes swipeUnderline {
    0% { transform: scaleX(0); transform-origin: left; }
    40% { transform: scaleX(1); transform-origin: left; }
    60% { transform: scaleX(1); transform-origin: right; }
    100% { transform: scaleX(0); transform-origin: right; }
}

/* =========================================
   4. ABOUT SECTION (MAGAZINE COLLAGE)
   ========================================= */
.image-collage-wrapper {
    position: relative;
    margin-bottom: 2rem;
}

.collage-main {
    display: block;
    width: 85%;
    height: 450px;
    object-fit: cover;
    object-position: center 80%;
    border-radius: 12px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    position: relative;
    z-index: 1;
}

.collage-sub {
    display: block;
    position: absolute;
    bottom: -40px; 
    width: 55% !important;
    height: 280px !important;
    object-fit: cover !important;
    object-position: 70% center !important;
    border-radius: 8px;
    box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.4);
    z-index: 2;
}

.left-collage {
    padding-bottom: 30px;
    padding-right: 30px;
}

.left-collage .collage-sub {
    right: 0; 
}

.right-collage {
    padding-bottom: 30px;
    padding-left: 30px;
    display: flex;
    justify-content: flex-end; 
}

.right-collage .collage-sub {
    left: 0; 
}

/* =========================================
   5. DOCTORS SECTION
   ========================================= */
.doctor-card {
    background-color: var(--primary-blue, #163654); 
    color: white;
    border-radius: 12px; 
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.doctor-img {
    height: 100%;
    min-height: 450px;
    object-fit: cover;
    width: 100%;
}

.doctor-info-wrapper {
    padding: 4rem 2rem; 
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
}

.doctor-name {
    font-size: 3rem; 
    color: #ffffff;
    margin-bottom: 0.5rem;
}

.doctor-divider {
    width: 150px;
    height: 3px;
    background-color: #d8b688;
    margin-bottom: 2rem;
    border-radius: 2px;
}

.doctor-subtitle {
    color: #d8b688;
    font-size: 1.8rem; 
    font-weight: 600;
    margin-bottom: 0.5rem;
    letter-spacing: 1px;
}

.doctor-text {
    font-size: 1.4rem; 
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 1.5rem;
}

.doctor-list li {
    position: relative;
    margin-bottom: 1rem; 
    font-size: 1.4rem; 
    color: rgba(255, 255, 255, 0.9);
    list-style-type: none !important; 
}

.doctor-list li::before {
    content: '✓'; 
    color: #d8b688;
    position: absolute;
    left: -30px;
    font-weight: 900;
    font-size: 1.4rem; 
}

/* =========================================
   6. PRE-FOOTER CTA SECTION
   ========================================= */
.cta-floating-section {
    position: relative;
    height: 70vh;
    min-height: 400px;
    width: 100%; 
    background-image: url('../images/main-bg.jpg');
    background-size: cover !important;
    background-position: center 30%;
    background-repeat: no-repeat;
}

.cta-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(250, 248, 245, .5) 0%, rgba(250, 248, 245, .2) 10%, rgba(0, 0, 0, .8) 100%);
    z-index: 1; 
}

.cta-glass-card {
    background: rgba(255, 255, 255, 0.90); 
    border-radius: 12px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    backdrop-filter: blur(10px); 
    -webkit-backdrop-filter: blur(10px);
}

.cta-floating-heading {
    color: var(--primary-blue, #163654); 
    font-size: 2.8rem; 
    line-height: 1.2;
}

.cta-floating-subtext {
    color: #444444;
    font-size: 1.2rem;
    line-height: 1.6;
}

/* =========================================
   7. SCROLL REVEAL ANIMATIONS
   ========================================= */
.fade-up {
    opacity: 0;
    transform: translateY(50px); 
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
    will-change: opacity, transform; 
}

.fade-up.is-visible {
    opacity: 1;
    transform: translateY(0); 
}

.delay-1 {
    transition-delay: .2s; 
}

/* =========================================
   8. MEDIA QUERIES (MOBILE RESPONSIVE)
   ========================================= */
@media (max-width: 991px) {
    .hero-title { font-size: 3rem; }
    .cta-floating-heading { font-size: 2.2rem; }
    .cta-floating-section { min-height: 500px; }
    
    .collage-main {
        width: 90% !important;
        height: 350px !important;
    }
    .collage-sub {
        width: 65% !important;
        height: 220px !important;
        bottom: -20px;
        border-width: 6px; 
    }
}

/* =========================================
   9. FOOTER SECTION (REFINED)
   ========================================= */
.site-footer {
    background-color: #163654;
    color: #ffffff;
    border-top: 3px solid #d8b688; 
    padding: 0; 
}

/* Logo & Brand Column */
.footer-col-brand {
    padding-right: 70px; 
}

.footer-logo {
    width: 350px; 
    height: 270px; 
    object-fit: contain; 
    display: block;
    margin: -25px auto -50px auto !important; 
}

.footer-brand-text {
    margin-left: 0 !important; 
    margin-top: 10px;
    text-align: center;
}

.footer-socials {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 15px;
    position: relative; 
    z-index: 50; 
}

.footer-socials a {
    color: #ffffff;
    font-size: 1.5rem;
    display: inline-block;
    transition: transform 0.3s ease, color 0.3s ease; 
}

.footer-socials a:hover {
    transform: translateY(-5px);
}

/* Common Text & Heading Styles */
.footer-heading {
    color: #d8b688;
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-subheading {
    color: #d8b688;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 10px;
}

.footer-text {
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 20px;
}

.footer-text a {
    color: rgba(255, 255, 255, 0.75);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-text a:hover {
    color: #d8b688;
}

/* Navigation Links */
.footer-links {
    list-style: none;
    padding: 10px;
    line-height: 40px;
    font-size: 1.2rem;
    margin-left: -15px;
    margin-top: -13px;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.75);
    text-decoration: none;
    font-size: 1.1rem;
    display: inline-block; 
    transition: transform 0.3s ease;
}

.footer-links a.active {
    color: #d8b688;
}

.footer-links a:hover {
    transform: translateY(-5px) !important;
    color: rgba(255, 255, 255, 0.75) !important;
}

/* Column Structure & Spacing */
.footer-col-pages, 
.footer-col-eastwood, 
.footer-col-stamesa {
    margin-top: 50px;
}

.footer-col-pages {
    padding-left: 40px; 
    padding-right: 30px; 
}

.footer-col-eastwood {
    margin-left: -30px;
    padding-left: 40px; 
    border-left: 1px solid rgba(216, 182, 136, 0.2); 
}

.footer-col-stamesa {
    padding-left: 90px; 
}

.footer-bottom {
    background: rgba(0,0,0,0.2);
    padding: 10px 0;
    margin-top: 10px;
    border-top: 1px solid rgba(255,255,255,0.1);
}

/* Footer Mobile Adjustments */
@media (max-width: 991px) {
    .footer-col-pages, 
    .footer-col-eastwood, 
    .footer-col-stamesa {
        padding-left: 15px;
        text-align: center;
        margin-bottom: 30px;
        margin-left: 0;
        border-left: none;
    }
    .footer-col-brand {
        padding-right: 0;
    }
    .footer-links a:hover { 
        padding-left: 0; 
    }
}

/* =========================================
   NAVBAR MOBILE LAYOUT (below xxl / 1400px)
   ========================================= */
@media (max-width: 1399.98px) {

    /* Hamburger → LEFT */
    .nav-mobile-start {
        order: 1;
    }

    /* Logo → CENTER */
    .navbar-brand {
        order: 2;
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
    }

    /* Icons + Book Now → RIGHT */
    .nav-mobile-end {
        order: 3;
    }

    /* Make #mainNav the positioning parent for the drawer panel */
    #mainNav {
        position: relative !important;
        overflow: visible !important;
    }

    /* ── DEFAULT: Hamburger uses white strokes (on transparent/hero bg) ── */
    .navbar-toggler {
        border-color: rgba(255, 255, 255, 0.6) !important;
        position: relative;
        z-index: 10001;
        background: transparent !important;
    }

    .navbar-toggler-icon {
        background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255%2c 255%2c 255%2c 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
    }

    /* ── SCROLLED: Hamburger uses dark strokes ── */
    #mainNav.scrolled .navbar-toggler {
        border-color: rgba(22, 54, 84, 0.4) !important;
    }

    #mainNav.scrolled .navbar-toggler-icon {
        background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%2822%2c 54%2c 84%2c 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
    }

    /* ── MENU OPEN: Navbar background becomes white ── */
    #mainNav.menu-open {
        background-color: #ffffff !important;
        border-bottom: none !important;
        box-shadow: none !important;
        padding: 15px 0 !important;
    }

    /* ── MENU OPEN: Hamburger uses gold strokes ── */
    #mainNav.menu-open .navbar-toggler {
        border-color: rgba(216, 182, 136, 0.7) !important;
        background: transparent !important;
    }

    #mainNav.menu-open .navbar-toggler-icon {
        background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28216%2c 182%2c 136%2c 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
    }

    /* ── MENU OPEN: Logo shows in color (removes white filter) ── */
    #mainNav.menu-open .nav-logo {
        filter: none !important;
    }

    /* ── MENU OPEN: Icons switch to gold ── */
    #mainNav.menu-open .nav-icon-btn {
        color: #d8b688 !important;
    }

    /* Smaller Book Now for mobile header */
    .btn-header-book-sm {
        padding: 8px 18px;
        font-size: 1.1rem;
        position: relative;
        z-index: 10001;
    }

    /* Keep icons above the drawer panel */
    .nav-mobile-end .nav-icon-btn {
        position: relative;
        z-index: 10001;
    }

    /* Hide the desktop right actions on mobile */
    .header-right-actions {
        display: none !important;
    }

    /* ── Hide drawer when collapsed ── */
    #navbarNav:not(.show) {
        display: none !important;
    }

    /* ── DRAWER: Full-width white panel that slides down ── */
    #navbarNav.show {
        position: absolute;
        /* 
         * KEY FIX: top is set to 100% so the drawer starts BELOW the navbar bar,
         * not at top:0 which caused it to cover the hamburger/icons row.
         * The navbar height varies (scrolled = ~60px, default = ~90px),
         * so we use top: 100% to always anchor below the current navbar height.
         */
        top: 100%;
        left: 0;
        width: 100%;
        height: auto;

        background-color: #ffffff;
        border-radius: 0 0 12px 12px;
        border-top: 2px solid rgba(216, 182, 136, 0.3);
        box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);

        display: flex !important;
        flex-direction: column;
        align-items: center;

        /* Removed the large top padding (was 80px) since drawer now starts below navbar */
        padding: 8px 24px 28px;

        z-index: 9999;

        animation: drawerSlideDown 0.3s ease forwards;
    }

    @keyframes drawerSlideDown {
        from {
            opacity: 0;
            transform: translateY(-8px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    /* Nav list inside the drawer */
    #navbarNav.show .navbar-nav {
        flex-direction: column;
        align-items: center;
        gap: 0 !important;
        transform: none !important;
        width: 100%;
    }

    /* Each nav item in the drawer */
    #navbarNav.show .nav-item {
        width: 100%;
        text-align: center;
        opacity: 0;
        transform: translateY(8px);
        animation: itemFadeUp 0.3s ease forwards;
    }

    /* Staggered entrance delays */
    #navbarNav.show .nav-item:nth-child(1) { animation-delay: 0.05s; }
    #navbarNav.show .nav-item:nth-child(2) { animation-delay: 0.10s; }
    #navbarNav.show .nav-item:nth-child(3) { animation-delay: 0.15s; }
    #navbarNav.show .nav-item:nth-child(4) { animation-delay: 0.20s; }

    @keyframes itemFadeUp {
        to { opacity: 1; transform: translateY(0); }
    }

    /* Thin divider between nav items */
    #navbarNav.show .nav-item + .nav-item {
        border-top: 1px solid rgba(22, 54, 84, 0.08);
    }

    /* Nav links in the drawer */
    #navbarNav.show .nav-link {
        color: var(--primary-blue, #163654) !important;
        font-size: 1.2rem !important;
        text-align: center;
        padding: 16px 20px !important;
        letter-spacing: 0.3px;
        transition: color 0.2s ease !important;
        display: block;
    }

    #navbarNav.show .nav-link:hover {
        color: #d8b688 !important;
        transform: none;
    }

    #navbarNav.show .nav-link.active {
        color: #d8b688 !important;
        font-weight: 700;
    }

    /* Hide the Book Now button inside the drawer */
    .nav-mobile-drawer-book {
        display: none !important;
    }
}