/* =========================================
   1. GLOBAL VARIABLES (CHICAGO AIC PALETTE)
   ========================================= */
:root {
    --aic-midnight: #022B3A;
    --aic-ocean: #1F7A8C;
    --aic-sky: #BFDBF7;
    --aic-cloud: #E1E5F2;
    --aic-white: #ffffff;
}

/* =========================================
   1.1 GLOBAL MOBILE OVERFLOW FIX
   ========================================= */
html, body {
    overflow-x: hidden; /* The magic bullet for horizontal scroll bugs */
    width: 100%;
    position: relative;
}

/* =========================================
   1.5 GLOBAL TYPOGRAPHY (POPPINS)
   ========================================= */
body {
    font-family: 'Poppins', sans-serif;
    color: #4a5568; /* A soft, readable slate gray for body text */
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', sans-serif;
    color: var(--aic-midnight); /* Forces headings to use your Midnight Teal */
}

/* =========================================
   2. NAVIGATION
   ========================================= */
.navbar {
    background-color: var(--aic-white);
    box-shadow: 0 2px 15px rgba(0,0,0,0.05);
}

.navbar .nav-link {
    color: var(--aic-midnight) !important;
    font-weight: 500;
    transition: color 0.3s ease;
}

.navbar .nav-link:hover {
    color: var(--aic-ocean) !important;
}

/* =========================================
   2.1 FLOATING NAV RESPONSIVE SHAPE
   ========================================= */
.aic-floating-nav {
    /* Mobile: A clean, soft-rounded rectangle that expands beautifully */
    border-radius: 1.5rem; 
    transition: all 0.3s ease;
}

@media (min-width: 992px) {
    .aic-floating-nav {
        /* Desktop: The perfect sleek pill shape */
        border-radius: 50rem; 
    }
}

/* =========================================
   3. FULL-SCREEN VIDEO HERO
   ========================================= */
.hero-section {
    position: relative;
    height: 100vh; /* Forces full screen height */
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    color: var(--aic-white);
}

.video-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
}

.video-background video {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Prevents stretching */
}

/* The Midnight Teal color overlay */
.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--aic-midnight);
    opacity: 0.65; /* Adjust 0.0 to 1.0 for darker/lighter tint */
    z-index: -1;
}

/* Custom Button */
.btn-aic-ocean {
    background-color: var(--aic-ocean);
    color: var(--aic-white);
    border: none;
    transition: all 0.3s ease;
}

.btn-aic-ocean:hover {
    background-color: #155b69; /* Slightly darker ocean on hover */
    color: var(--aic-white);
    transform: translateY(-2px);
}

/* =========================================
   4. INTERACTIVE ROOM EXPLORER
   ========================================= */
.room-explorer {
    position: relative;
    display: inline-block;
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(2, 43, 58, 0.15); /* Soft Midnight Teal shadow */
}

.hotspot {
    position: absolute;
    z-index: 10;
    cursor: pointer;
    width: 30px;
    height: 30px;
    transform: translate(-50%, -50%); /* Centers the dot exactly on your % coordinates */
}

/* The Solid Inner Dot */
.hotspot-dot {
    width: 16px;
    height: 16px;
    background-color: var(--aic-ocean);
    border: 2px solid var(--aic-white);
    border-radius: 50%;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
}

/* The Radiating Pulse Animation */
.hotspot::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    background-color: var(--aic-ocean);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: pulse-ring 2s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
    z-index: 1;
}

@keyframes pulse-ring {
    0% { transform: translate(-50%, -50%) scale(0.8); opacity: 0.8; }
    100% { transform: translate(-50%, -50%) scale(2.5); opacity: 0; }
}

/* The Frosted Glass Tooltip */
.hotspot-tooltip {
    position: absolute;
    bottom: 120%;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    width: max-content;
    max-width: 240px;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(8px); /* The frosted glass magic */
    -webkit-backdrop-filter: blur(8px);
    padding: 1rem;
    border-radius: 0.75rem;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    border: 1px solid rgba(255,255,255,0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    pointer-events: none; /* Prevents the tooltip from flickering if hovered */
}

/* Tooltip Typography */
.hotspot-tooltip strong {
    color: var(--aic-midnight);
    display: block;
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
}

.hotspot-tooltip p {
    color: #555;
    font-size: 0.875rem;
    margin: 0;
    line-height: 1.4;
    white-space: normal;
}

/* Show Tooltip on Hover */
.hotspot:hover .hotspot-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

/* =========================================
   5. FEATURE CARDS (Why Choose Us)
   ========================================= */
.section-bg {
    background-color: var(--aic-cloud); /* The soft Cloud Gray background */
}

.feature-card {
    position: relative;
    border-radius: 1rem;
    padding: 3rem 1.5rem;
    height: 100%;
    min-height: 380px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    display: flex;
    flex-direction: column;
    justify-content: center;
    border: none;
}

/* The Image Background Layer */
.feature-card-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94); /* Smooth, cinematic zoom */
    z-index: 0;
}

.feature-card:hover .feature-card-bg {
    transform: scale(1.08);
}

/* The Midnight Teal Overlay */
.feature-card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--aic-midnight);
    opacity: 0.75; /* Dark enough to make white text completely readable */
    transition: opacity 0.3s ease;
    z-index: 1;
}

.feature-card:hover .feature-card-overlay {
    opacity: 0.85; /* Darkens slightly on hover to focus attention on the text */
}

/* The Content Container */
.feature-card-content {
    position: relative;
    z-index: 2;
    color: var(--aic-white);
}

/* Frosted Glass Icon Wrapper */
.feature-icon-wrapper {
    width: 75px;
    height: 75px;
    background-color: rgba(255, 255, 255, 0.1); 
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem auto;
    backdrop-filter: blur(4px); /* Adds a subtle blur to the image directly behind the icon */
    -webkit-backdrop-filter: blur(4px);
}

.feature-icon {
    font-size: 1.8rem;
    color: var(--aic-sky); 
}

/* =========================================
   6. SEAMLESS PATH TO CARE (Stepper & Pledge)
   ========================================= */

/* The Vertical Timeline Stepper */
.process-stepper {
    position: relative;
    padding-left: 20px;
}

.process-stepper::before {
    content: '';
    position: absolute;
    left: 20px;
    top: 10px;
    bottom: 20px;
    width: 2px;
    background-color: var(--aic-cloud);
    z-index: 1;
}

.step {
    position: relative;
    display: flex;
    align-items: flex-start;
    margin-bottom: 2.5rem;
    z-index: 2;
}

.step-number {
    width: 45px;
    height: 45px;
    flex-shrink: 0;
    background-color: var(--aic-white);
    border: 3px solid var(--aic-ocean);
    color: var(--aic-ocean);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
    margin-left: -22.5px; /* Pulls the circle left to center over the line */
    margin-right: 20px;
    box-shadow: 0 4px 10px rgba(31, 122, 140, 0.2);
    transition: all 0.3s ease;
}

.step:hover .step-number {
    background-color: var(--aic-ocean);
    color: var(--aic-white);
    transform: scale(1.1);
}

.step-content h5 {
    color: var(--aic-midnight);
    font-weight: 700;
    margin-bottom: 0.5rem;
}

/* The Inverted Pledge Card */
.pledge-card-wrapper {
    perspective: 1000px;
}

.pledge-card {
    background-color: var(--aic-midnight);
    color: var(--aic-white);
    border-radius: 1.5rem;
    padding: 3.5rem 2.5rem;
    box-shadow: 0 25px 50px rgba(2, 43, 58, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
}

/* Subtle background accent for the card */
.pledge-card::after {
    content: '\f48b'; /* FontAwesome Handshake Icon */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    bottom: -30px;
    right: -20px;
    font-size: 12rem;
    color: var(--aic-white);
    opacity: 0.03;
    z-index: 0;
    transform: rotate(-15deg);
}

.pledge-card h3, .pledge-card p, .pledge-signature {
    position: relative;
    z-index: 1;
}

.pledge-signature {
    font-family: 'Times New Roman', serif; /* Gives a classic, formal signature look */
    font-style: italic;
    font-size: 1.4rem;
    color: var(--aic-sky);
    margin-top: 2rem;
    border-top: 1px solid rgba(191, 219, 247, 0.2);
    padding-top: 1.5rem;
}

/* =========================================
   7. INTERACTIVE CLINIC HUB
   ========================================= */

/* The Roster Tabs */
.location-tab {
    background: transparent;
    border: none;
    border-left: 4px solid var(--aic-cloud);
    text-align: left;
    padding: 1.25rem 1.5rem;
    border-radius: 0 1rem 1rem 0;
    color: var(--aic-midnight);
    transition: all 0.3s ease;
    cursor: pointer;
    outline: none;
}

.location-tab:hover {
    background: rgba(191, 219, 247, 0.2); /* Soft Sky hover */
    border-left-color: var(--aic-sky);
}

.location-tab.active {
    border-left-color: var(--aic-ocean);
    background: rgba(31, 122, 140, 0.05); /* Very light Ocean tint */
    color: var(--aic-ocean);
}

.location-tab h4 {
    transition: color 0.3s ease;
}

.location-tab.active h4 {
    color: var(--aic-ocean);
}

/* The Viewing Stage */
.location-stage {
    height: 500px;
    background-color: var(--aic-midnight);
}

.location-panel {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    opacity: 0;
    visibility: hidden;
    z-index: 1;
}

.location-panel.active {
    opacity: 1;
    visibility: visible;
    z-index: 2;
}

.location-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -2;
}

/* A gradient overlay so the white text is always perfectly readable over the photo */
.location-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Darkens the bottom to 100% opacity, and carries it higher up the image */
    background: linear-gradient(to top, rgba(2, 43, 58, 1) 0%, rgba(2, 43, 58, 0.8) 50%, rgba(2, 43, 58, 0.4) 100%);
    z-index: -1;
}

.location-info {
    position: relative;
    z-index: 3;
}

/* =========================================
   7.1 SLEEK LOCATION INFO TYPOGRAPHY
   ========================================= */
.location-panel {
    /* Ensures the inner content is perfectly centered horizontally */
    align-items: center; 
}

.location-info {
    position: relative;
    z-index: 3;
    text-align: center;
    padding: 2rem 2rem 3.5rem 2rem; /* The 3.5rem bottom padding floats it up! */
    max-width: 90%; 
}

.location-info h3 {
    font-size: 2.2rem; /* Sleeker than the old display-6 */
    font-weight: 500; /* Drops the heavy bold for a cleaner look */
    letter-spacing: 0.5px;
}

.location-info p {
    font-size: 1rem; /* Drops the bulky fs-5 */
    font-weight: 300; /* Beautifully light and breezy */
    color: rgba(255, 255, 255, 0.9);
}

/* Subtle icon spacing adjustments for the centered layout */
.location-info i {
    margin-right: 8px;
    font-size: 0.9rem;
}

/* =========================================
   8. MIDNIGHT FOOTER
   ========================================= */
.footer-links a {
    color: var(--aic-cloud);
    text-decoration: none;
    transition: all 0.3s ease;
    opacity: 0.85;
}

.footer-links a:hover {
    color: var(--aic-sky);
    opacity: 1;
    padding-left: 6px; /* A sleek, premium nudge effect on hover */
}

/* =========================================
   9. SMART ASSIST RESPONSIVE POSITIONING
   ========================================= */
.aic-toast-pos {
    bottom: 0;
}

/* Add this right below your .aic-toast-pos rule */
#smart-assist-toast .toast {
    max-width: calc(100vw - 2rem); /* Keeps it safely inside the screen edges */
}

@media (max-width: 991px) {
    .aic-toast-pos {
        bottom: 100px; 
    }
}

/* =========================================
   10. PREMIUM ACCORDION (Inner Pages)
   ========================================= */
.aic-accordion .accordion-item {
    border: none;
    margin-bottom: 1.5rem;
    border-radius: 1rem !important;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
    background-color: var(--aic-white);
}

.aic-accordion .accordion-button {
    background-color: var(--aic-white);
    color: var(--aic-midnight);
    font-size: 1.25rem;
    padding: 1.5rem 2rem;
    box-shadow: none !important;
    transition: all 0.3s ease;
}

/* Active State for the Accordion */
.aic-accordion .accordion-button:not(.collapsed) {
    background-color: var(--aic-ocean);
    color: var(--aic-white);
}

.aic-accordion .accordion-button::after {
    filter: brightness(0) saturate(100%) invert(18%) sepia(26%) saturate(1915%) hue-rotate(156deg) brightness(96%) contrast(97%); /* Midnight Teal Chevron */
}

.aic-accordion .accordion-button:not(.collapsed)::after {
    filter: brightness(0) invert(1); /* White Chevron when active */
}

.aic-accordion .accordion-body {
    color: #555;
    font-size: 1.05rem;
    line-height: 1.8;
}

/* Checklist Styling */
.checklist {
    list-style: none;
    padding-left: 0;
}

.checklist li {
    position: relative;
    padding-left: 2rem;
    margin-bottom: 1rem;
}

.checklist li::before {
    content: '\f00c'; /* FontAwesome Check */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    left: 0;
    color: var(--aic-ocean);
}

/* =========================================
   11. MIDNIGHT CTA HUB
   ========================================= */
.hub-card {
    background-color: var(--aic-midnight);
    border-radius: 1.5rem;
    padding: 4rem 3rem;
    box-shadow: 0 20px 40px rgba(2, 43, 58, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* =========================================
   12. MEDICAL SERVICE CARDS (Image Backgrounds)
   ========================================= */
.medical-service-card {
    position: relative;
    border-radius: 1.25rem;
    padding: 3rem 2rem;
    height: 100%;
    min-height: 520px; /* Gives plenty of room for lists and images */
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    display: flex;
    flex-direction: column;
    border: none;
    color: var(--aic-white); /* Forces all child text to white */
}

/* The Image Background Layer */
.service-card-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    z-index: 0;
}

.medical-service-card:hover .service-card-bg {
    transform: scale(1.08); /* Cinematic zoom */
}

/* The Midnight Teal Overlay (Darker for Readability) */
.service-card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--aic-midnight);
    opacity: 0.8; /* Keeps the text perfectly legible */
    transition: opacity 0.3s ease;
    z-index: 1;
}

.medical-service-card:hover .service-card-overlay {
    opacity: 0.9; /* Darkens slightly on hover */
}

/* The Content Container */
.service-card-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.medical-service-card hr {
    border-color: rgba(255, 255, 255, 0.2);
    margin: 1.5rem 0;
}

/* Med Badges (Frosted Glass Version for dark backgrounds) */
.med-badge-light {
    display: inline-block;
    padding: 0.45rem 1.1rem;
    font-size: 0.85rem;
    background-color: rgba(255, 255, 255, 0.1); /* Frosted Glass */
    color: var(--aic-cloud);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 50rem;
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 500;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.med-badge-light:hover {
    background-color: var(--aic-sky); /* Pops with Soft Sky on hover */
    color: var(--aic-midnight);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(191, 219, 247, 0.4);
}

/* =========================================
   13. CAREERS UI (Culture & Job Cards)
   ========================================= */
.culture-card {
    background: var(--aic-white);
    border-radius: 1rem;
    padding: 2.5rem 1.5rem;
    height: 100%;
    box-shadow: 0 10px 30px rgba(0,0,0,0.03);
    border: 1px solid rgba(2, 43, 58, 0.05);
    transition: all 0.3s ease;
}

.culture-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(31, 122, 140, 0.1);
    border-color: rgba(31, 122, 140, 0.2);
}

.job-card {
    background: var(--aic-white);
    border-radius: 1.25rem;
    padding: 2.5rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    border: 1px solid rgba(2, 43, 58, 0.05);
    margin-bottom: 2rem;
    transition: box-shadow 0.3s ease;
}

.job-card:hover {
    box-shadow: 0 15px 40px rgba(2, 43, 58, 0.1);
}

.job-details-wrapper {
    background: rgba(225, 229, 242, 0.3); /* Ultra-light Cloud Gray */
    border-radius: 1rem;
    padding: 2rem;
    margin-top: 1.5rem;
    border: 1px solid rgba(31, 122, 140, 0.1);
}