:root {
    --primary-color: #3b0d40;
    /* Logo Deep Purple */
    --primary-light: #5a2a60;
    /* Lighter Purple */
    --primary-dark: #2a092e;
    /* Darker Purple for hover */
    --accent-color: #f07c24;
    /* Logo Orange */
    --secondary-color: #4B4F58;
    /* Neutral Charcoal */
    --text-dark: #2d2d2d;
    --text-light: #666666;
    --white: #ffffff;
    --bg-light: #F9F9F9;
    --bg-warm: #fff8f2;
    /* Subtle orange tint for variety */
    --border-color: #e5e5e5;
    --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.05);
    /* Softer, more elegant shadow */
    --shadow-md: 0 8px 25px rgba(59, 13, 64, 0.1);
    /* Purple-tinted shadow */
    --transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    /* Smoother elegant transition */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--secondary-color);
    background: var(--white);
    line-height: 1.6;
    overflow-x: hidden;
}

ul {
    list-style: none;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

h1,
h2,
h3,
h4,
h5 {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 1em;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.text-center {
    text-align: center;
}

.mx-auto {
    margin-left: auto;
    margin-right: auto;
}

.bg-light {
    background-color: var(--bg-light);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    font-size: 15px;
}

.btn-primary {
    background: var(--primary-color);
    color: var(--white);
    border: 1px solid var(--primary-color);
}

.btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(59, 13, 64, 0.3);
}

.btn-outline {
    background: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

.btn-outline:hover {
    background: var(--primary-color);
    color: var(--white);
}

.btn-white {
    background: var(--white);
    color: var(--primary-color);
    transition: all 0.3s ease;
}

.btn-white:hover {
    background: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* Top Bar (Elegant Modern Refactor) */
.top-bar {
    background: #30084f;
    /* New Brand Purple Background */
    color: #ffffff;
    /* All text white */
    padding: 12px 0;
    font-size: 12px;
    font-weight: 500;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.top-bar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Left Side: Socials */
.top-left-socials {
    display: flex;
    align-items: center;
    gap: 15px;
}

.follow-us {
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 11px;
    opacity: 0.8;
}

.top-left-socials a {
    color: #ffffff;
    /* Icons White */
    font-size: 14px;
    transition: all 0.3s;
    opacity: 0.9;
}

.top-left-socials a:hover {
    color: var(--accent-color);
    /* Hover to Brand Orange */
    opacity: 1;
    transform: translateY(-2px);
}

/* Right Side: Contact & Portals */
.top-right-links {
    display: flex;
    align-items: center;
    gap: 20px;
}

.contact-link {
    color: #ffffff;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: color 0.3s;
}

.contact-link i {
    color: #ffffff;
    /* Icons White */
    font-size: 13px;
    opacity: 0.9;
}

.contact-link:hover {
    color: var(--accent-color);
}

.contact-link:hover i {
    color: var(--accent-color);
}

.top-right-links .divider {
    height: 15px;
    width: 1px;
    background: rgba(255, 255, 255, 0.3);
    margin: 0 5px;
}

.portal-link {
    color: #ffffff;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 11px;
    padding: 5px 15px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 20px;
    transition: all 0.3s;
    text-decoration: none;
}

.portal-link:hover {
    background: var(--white);
    color: #30084f;
    /* Text becomes header purple */
    border-color: var(--white);
}

/* Standardized Section Headers */
.section-header {
    margin-bottom: 50px;
    position: relative;
    z-index: 2;
}

.section-header h2 {
    font-size: 42px;
    line-height: 1.2;
    font-weight: 700;
    color: var(--primary-color);
    letter-spacing: -0.5px;
    margin-bottom: 20px;
}

.section-header p {
    font-size: 18px;
    color: var(--text-light);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.6;
}

.section-header .divider {
    height: 4px;
    width: 60px;
    background: var(--accent-color);
    border-radius: 2px;
    margin-bottom: 20px;
}

/* Header */
.mobile-extras {
    display: none;
}

.main-header {
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    top: 0;
    background: var(--white);
    z-index: 999;
    padding: 0;
    /* Reduced padding for slimmer look */
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
    /* Specific height for consistency */
}

.logo {
    display: flex;
    align-items: center;
    /* height: 100%; removed to let image control */
}

.logo img {
    height: 75px;
    margin-top: 10px;
    /* Prominent Logo Size */
    width: auto;
    object-fit: contain;
    transition: transform 0.3s;
}

.logo a:hover img {
    transform: scale(1.05);
}

.logo i {
    color: var(--primary-color);
}

.nav-menu ul {
    display: flex;
    gap: 30px;
}

.nav-menu a {
    font-weight: 500;
    font-size: 15px;
    color: var(--secondary-color);
}

.nav-menu a:hover {
    color: var(--accent-color);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.mobile-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
}

/* MODERN HERO SLIDER REFACTOR */
.hero-slider.modern-hero {
    position: relative;
    height: 680px;
    width: 100%;
    overflow: hidden;
    background: linear-gradient(135deg, #f9faff 0%, #f0f4f8 100%);
    /* Clean Light BG */
}

.slider-wrapper {
    height: 100%;
    width: 100%;
    position: relative;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.8s ease-in-out;
    visibility: hidden;
    /* Ensure it's not clickable when hidden */
}

.slide.active {
    opacity: 1;
    visibility: visible;
    z-index: 2;
}

/* Static Background Elements (Skeleton/Wireframe Texture) */
.slide-bg-static {
    position: absolute;
    width: 100%;
    height: 100%;
    /* Abstract Wireframe/Network Background */
    /* Abstract Wireframe/Network Background */
    background-image: url('https://images.unsplash.com/photo-1557683316-973673baf926?q=80&w=2000');
    /* Abstract geometric pattern */
    background-size: cover;
    background-position: center;
    z-index: 0;
    opacity: 0.1;
    filter: grayscale(100%);
    mix-blend-mode: multiply;
    /* Subtle texture only */
}

.slide-container-split {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    position: relative;
    z-index: 2;
    padding: 0 20px;
    gap: 40px;
}

/* LEFT: Text Content */
.hero-text {
    flex: 1;
    max-width: 600px;
    opacity: 0;
    transform: translateX(-50px);
    transition: all 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.slide.active .hero-text {
    opacity: 1;
    transform: translateX(0);
}

.hero-badge {
    display: inline-block;
    padding: 6px 16px;
    background: rgba(59, 13, 64, 0.1);
    color: var(--primary-color);
    font-weight: 600;
    border-radius: 30px;
    font-size: 13px;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.hero-text h1 {
    font-size: 58px;
    line-height: 1.15;
    color: var(--text-dark);
    margin-bottom: 20px;
    font-weight: 800;
    letter-spacing: -1px;
}

.text-gradient {
    background: linear-gradient(to right, var(--primary-color), #8e44ad);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-text p {
    font-size: 18px;
    color: var(--text-light);
    margin-bottom: 35px;
    line-height: 1.7;
    max-width: 90%;
}

.hero-cta-group {
    display: flex;
    gap: 15px;
}

.btn-lg {
    padding: 15px 35px;
    font-size: 16px;
    border-radius: 50px;
    /* Pill shape */
}

.btn-outline-dark {
    border: 2px solid #ddd;
    color: var(--secondary-color);
    background: transparent;
    font-weight: 600;
    transition: all 0.3s;
}

.btn-outline-dark:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-2px);
}

/* RIGHT: Image Visual */
.hero-image-visual {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    opacity: 0;
    transform: translateX(50px);
    transition: all 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) 0.2s;
    /* Delayed */
}

.slide.active .hero-image-visual {
    opacity: 1;
    transform: translateX(0);
}

.image-blob-wrap {
    position: relative;
    width: 500px;
    height: 500px;
    border-radius: 30px;
    /* Or complex border-radius for blob */
    overflow: visible;
    /* Allow badges to float out */
}

.image-blob-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 30px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
    /* Morphing blob animation optional */
}

/* Floating Badges */
.floating-badge {
    position: absolute;
    background: white;
    padding: 12px 20px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    font-weight: 600;
    color: var(--secondary-color);
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    z-index: 5;
    animation: float 4s ease-in-out infinite;
}

.floating-badge i {
    color: var(--accent-color);
    font-size: 18px;
}

.badge-1 {
    top: 40px;
    left: -30px;
    border-left: 4px solid var(--accent-color);
}

.badge-2 {
    bottom: 60px;
    right: -20px;
    border-left: 4px solid var(--primary-color);
    animation-delay: 2s;
}

@keyframes float {
    0% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }

    100% {
        transform: translateY(0);
    }
}

/* Mobile Responsive */
@media (max-width: 992px) {
    .slide-container-split {
        flex-direction: column;
        justify-content: center;
        text-align: center;
        padding-top: 40px;
    }

    .hero-text {
        align-items: center;
        margin-right: 0;
        transform: translateY(30px);
    }

    .hero-text h1 {
        font-size: 40px;
    }

    .hero-cta-group {
        justify-content: center;
    }

    .hero-image-visual {
        transform: translateY(30px);
        margin-top: 30px;
    }

    .image-blob-wrap {
        width: 100%;
        max-width: 400px;
        /* constrain on mobile */
        height: 300px;
    }

    .floating-badge {
        display: none;
        /* Hide badges on small screens to prevent overlap */
    }
}

/* Slider Indicators (Bullets) */
.slider-indicators {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    z-index: 10;
}

.indicator-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.2);
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.3s ease;
}

.indicator-dot.active {
    background: var(--accent-color);
    transform: scale(1.2);
    border-color: rgba(255, 255, 255, 0.5);
}

.indicator-dot:hover {
    background: var(--primary-color);
}

/* Search Overlay */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(48, 8, 79, 0.95);
    /* Theme Dark Purple */
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
}

.search-overlay.active {
    opacity: 1;
    visibility: visible;
}

.search-close {
    position: absolute;
    top: 40px;
    right: 40px;
    background: none;
    border: none;
    color: white;
    font-size: 30px;
    cursor: pointer;
    transition: transform 0.3s;
}

.search-close:hover {
    transform: rotate(90deg);
    color: var(--accent-color);
}

.search-container {
    text-align: center;
    width: 100%;
    max-width: 800px;
    padding: 20px;
}

.search-input {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 2px solid rgba(255, 255, 255, 0.2);
    font-size: 40px;
    color: white;
    padding: 10px 0;
    outline: none;
    text-align: center;
    font-weight: 300;
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.search-container p {
    color: rgba(255, 255, 255, 0.4);
    margin-top: 20px;
    font-size: 14px;
    letter-spacing: 1px;
}




/* Expandable Services Section */
.services-expanding-section {
    padding: 90px 0;
    background: var(--white);
}

.exp-card-container {
    display: flex;
    gap: 20px;
    height: 450px;
    margin-top: 50px;
}

.exp-card {
    flex: 1;
    border-radius: 20px;
    background-size: cover;
    background-position: center;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: flex 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    box-shadow: var(--shadow-sm);
}

.exp-card-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(131, 45, 112, 0.8), rgba(75, 79, 88, 0.9));
    /* Purple to Dark */
    opacity: 0.9;
    transition: opacity 0.4s ease;
}

.exp-card.active {
    flex: 3;
    /* Expand active card */
}

.exp-card:hover {
    flex: 3;
}

.exp-card:hover .exp-card-overlay {
    opacity: 0.7;
    background: linear-gradient(to bottom, rgba(131, 45, 112, 0.6), rgba(75, 79, 88, 0.8));
}

.exp-content {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 30px;
    color: var(--white);
    z-index: 2;
    transition: all 0.4s ease;
}

.exp-icon {
    font-size: 32px;
    margin-bottom: 20px;
    background: rgba(255, 255, 255, 0.2);
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    backdrop-filter: blur(5px);
}

.exp-card h3 {
    font-size: 20px;
    line-height: 1.3;
    margin-bottom: 15px;
    color: var(--white);
    white-space: normal;
    /* Allow wrapping */
}

.exp-desc {
    font-size: 15px;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 0;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: all 0.5s ease;
}

.exp-card:hover .exp-desc,
.exp-card.active .exp-desc {
    max-height: 100px;
    opacity: 1;
    margin-bottom: 20px;
}

.exp-card:hover .exp-arrow,
.exp-card.active .exp-arrow {
    opacity: 1;
    transform: translateX(0);
}

.exp-arrow {
    width: 40px;
    height: 40px;
    border: 2px solid rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateX(-20px);
    transition: all 0.4s ease;
}

/* Premium Purple Card Design */
.premium-purple-card {
    background: linear-gradient(135deg, #4a1c52 0%, #6e2776 50%, #3b0d40 100%);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.premium-purple-card .exp-card-overlay {
    background: none;
    /* Remove default overlay */
}

.premium-purple-card .exp-content {
    position: relative;
    z-index: 2;
    padding: 30px;
    width: 65%;
    /* Leave room for doctor image */
}

.premium-purple-card h3 {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 15px;
}

.premium-purple-card .exp-desc {
    font-size: 16px;
    opacity: 0.9;
}

.doctor-cutout {
    position: absolute;
    right: -20px;
    bottom: 0;
    height: 90%;
    width: 45%;
    z-index: 1;
    display: flex;
    align-items: flex-end;
}

.doctor-cutout img {
    height: 100%;
    width: auto;
    object-fit: contain;
}

.wave-bg {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 0;
    opacity: 0.3;
}

.premium-purple-card .exp-arrow {
    background: var(--white);
    color: var(--primary-color);
    border: none;
    margin-top: 20px;
}

@media (max-width: 768px) {
    .premium-purple-card .exp-content {
        width: 100%;
    }

    .doctor-cutout {
        opacity: 0.2;
        /* Fade out image on mobile to make text readable */
        right: -50px;
    }
}

/* Mobile: Stack them */
@media (max-width: 768px) {
    .exp-card-container {
        flex-direction: column;
        height: auto;
    }

    .exp-card {
        height: 250px;
        flex: none;
    }

    .exp-card.active,
    .exp-card:hover {
        flex: none;
    }

    .exp-desc {
        max-height: 100px;
        opacity: 1;
        margin-bottom: 10px;
    }

    .exp-arrow {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Process Section (Fixed) */
.section {
    padding: 90px 0;
}

.divider {
    height: 3px;
    width: 60px;
    background: var(--primary-color);
    margin: 20px auto;
}

/* Modern Process Section */
.process-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    /* Reduced min-width to fit mobile better */
    gap: 30px;
    margin-top: 60px;
    position: relative;
    z-index: 1;
}

.process-card {
    background: var(--white);
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03);
    /* Soft, airy shadow */
    transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    border: 1px solid rgba(0, 0, 0, 0.03);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
}

/* Hover Effect: Lift & Accent Border */
.process-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    opacity: 0;
    transition: opacity 0.4s ease;
}

.process-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(59, 13, 64, 0.08);
    /* Purple tint shadow */
}

.process-card:hover::before {
    opacity: 1;
}

/* Watermark Number */
.step-number {
    position: absolute;
    top: -10px;
    right: 20px;
    font-size: 80px;
    font-weight: 800;
    color: rgba(0, 0, 0, 0.03);
    /* Subtle watermark */
    line-height: 1;
    font-family: 'Arial', sans-serif;
    /* Geometric font */
    z-index: 0;
    transition: all 0.4s ease;
}

.process-card:hover .step-number {
    color: rgba(240, 124, 36, 0.1);
    /* Orange tint on hover */
    transform: scale(1.1);
}

.icon-wrap {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #fdfbfd 0%, #f4eff5 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    font-size: 28px;
    margin-bottom: 25px;
    position: relative;
    z-index: 1;
    transition: all 0.4s ease;
}

.process-card:hover .icon-wrap {
    background: var(--primary-color);
    color: white;
    transform: rotateY(180deg);
    /* Fun flip effect */
}

.process-card:hover .icon-wrap i {
    transform: rotateY(-180deg);
    /* Keep icon upright */
}

.process-card h3 {
    font-size: 20px;
    margin-bottom: 12px;
    font-weight: 700;
    position: relative;
    z-index: 1;
}

.process-card p {
    font-size: 15px;
    color: var(--text-light);
    line-height: 1.6;
    position: relative;
    z-index: 1;
}

/* AI Section */
.ai-section {
    background: var(--primary-color);
    color: var(--white);
    padding: 100px 0;
    overflow: hidden;
}

.ai-wrapper {
    display: flex;
    align-items: center;
    gap: 60px;
}

.ai-content {
    flex: 1;
}

.ai-visual {
    flex: 1;
}

.ai-visual img {
    width: 100%;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: perspective(1000px) rotateY(-10deg);
}

.ai-visual img:hover {
    transform: perspective(1000px) rotateY(0deg);
    transition: var(--transition);
}

.ai-content h2 {
    color: var(--white);
    font-size: 42px;
    margin-bottom: 20px;
}

.ai-content p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 18px;
    margin-bottom: 30px;
}

.tag {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 12px;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Specialties Section */
/* Modern Specialties - Vertical Focused Cards */
.specialties-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    /* Allow 2 columns on smaller mobiles */
    /* Optimised width */
    gap: 20px;
    margin-top: 50px;
}

.specialty-item {
    background: var(--white);
    padding: 25px 15px;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
    display: flex;
    flex-direction: column;
    /* Vertical Stack */
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 15px;
    font-weight: 600;
    color: var(--secondary-color);
    font-size: 15px;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.04);
    position: relative;
    overflow: hidden;
}

/* Hover Focus Effect */
.specialty-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--primary-color);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.specialty-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(59, 13, 64, 0.12);
    /* Deep purple shadow */
    border-color: transparent;
}

.specialty-item:hover::before {
    opacity: 1;
}

.specialty-item i {
    font-size: 28px;
    /* Larger Icon */
    color: var(--accent-color);
    /* Orange Accent */
    margin-bottom: 5px;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.specialty-item:hover i {
    transform: scale(1.2);
    color: var(--primary-color);
    /* Switch to Purple on hover */
}


/* Responsive Grid: 4 columns for unified layout */
@media (min-width: 992px) {

    .specialties-grid,
    .ehr-card-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Tablet/Mobile fallbacks */
@media (max-width: 991px) {

    .specialties-grid,
    .ehr-card-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
}

.mt-40 {
    margin-top: 40px;
}

/* Modern EHR Section */
.ehr-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    /* WIDER columns for landscape logos */
    gap: 30px;
    /* More breathing room */
    margin-top: 50px;
}



.ehr-card {
    background: var(--white);
    border-radius: 12px;
    border: 1px solid #f0f0f0;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.02);
    padding: 30px;
    /* Increased padding */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 180px;
    /* Balanced height */
    height: auto;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

/* Hover Border Effect */
.ehr-card::after {
    content: '';
    position: absolute;
    inset: 0;
    border: 2px solid var(--accent-color);
    border-radius: 12px;
    opacity: 0;
    transform: scale(0.95);
    transition: all 0.3s ease;
    pointer-events: none;
}

.ehr-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.08);
}

.ehr-card:hover::after {
    opacity: 1;
    transform: scale(1);
}

/* Text Styling Fix for EHRs */
.ehr-card h3 {
    font-size: 18px !important;
    /* Override inline styles if needed for consistency */
    text-align: center;
    margin: 0;
    transition: transform 0.3s ease;
    word-break: break-word;
    /* Prevent cutting */
    max-width: 100%;
}

.ehr-card:hover h3 {
    transform: scale(1.05);
}

/* Handle Images if they exist */
.ehr-card img {
    max-width: 95%;
    /* Use more space */
    max-height: 100px;
    /* Much larger logos */
    object-fit: contain;
    filter: none;
    /* Show full color by default for prominence */
    opacity: 1;
    /* Fully visible */
    transition: all 0.3s ease;
}

.ehr-card:hover img {
    filter: grayscale(0);
    opacity: 1;
}

/* Nationwide Section */
.nationwide-section {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    position: relative;
    padding: 80px 0;
    overflow: hidden;
}

/* Abstract Map Background Placeholder */
.nationwide-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('https://upload.wikimedia.org/wikipedia/commons/3/32/Blank_US_Map_(states_only).svg');
    /* SVG Map Placeholder */
    background-size: cover;
    background-position: center;
    opacity: 0.1;
    pointer-events: none;
}

.states-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    max-width: 900px;
    margin: 0 auto;
}

.state-btn {
    background: rgba(255, 255, 255, 0.1);
    color: var(--white);
    padding: 10px 25px;
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: var(--transition);
    font-size: 14px;
}

.state-btn:hover {
    background: var(--white);
    color: var(--primary-color);
}

/* Data-driven Testimonials Logic */
.testimonial-slide {
    display: none;
    animation: fadeSlide 0.8s ease-in-out;
}

.testimonial-slide.active {
    display: block;
}

@keyframes fadeSlide {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Updated Testimonials (Carousel Layout) */
.testimonials-slider-layout {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 50px;
    margin-top: 40px;
    background: var(--white);
    padding: 50px;
    border-radius: 20px;
    box-shadow: var(--shadow-sm);
}

.testimonial-content {
    flex: 1;
}

.quote-icon {
    font-size: 40px;
    color: var(--primary-color);
    margin-bottom: 20px;
    opacity: 0.3;
}

.testimonial-text {
    font-size: 20px;
    font-style: italic;
    color: var(--text-dark);
    margin-bottom: 30px;
    line-height: 1.6;
}

.testimonial-author h4 {
    margin-bottom: 5px;
    color: var(--primary-color);
    font-size: 18px;
}

.testimonial-author span {
    font-size: 14px;
    color: var(--text-light);
}

.testimonial-image {
    flex: 0 0 300px;
}

/* Testimonial Images & Controls */
.image-frame {
    width: 250px;
    height: 250px;
    border-radius: 50%;
    overflow: hidden;
    border: 10px solid #f0f0f0;
    box-shadow: var(--shadow-md);
    position: relative;
    transition: all 0.5s ease;
}

.image-frame.blob-shape {
    border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%;
    animation: blob-bounce 6s ease-in-out infinite alternate;
}

@keyframes blob-bounce {
    0% {
        border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%;
    }

    100% {
        border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
    }
}

.image-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.3s ease;
}

.testimonial-dots {
    display: flex;
    justify-content: center;
    margin-top: 30px;
    gap: 12px;
}

.dot {
    width: 12px;
    height: 12px;
    background-color: #ddd;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active,
.dot:hover {
    background-color: var(--primary-color);
    transform: scale(1.2);
}

@media (max-width: 768px) {
    .testimonials-slider-layout {
        flex-direction: column-reverse;
        padding: 30px;
        text-align: center;
    }

    .testimonial-image {
        margin-bottom: 20px;
    }

    .quote-icon {
        display: block;
        margin: 0 auto 20px;
    }
}

/* Blog Section */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.blog-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.blog-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-md);
}

.blog-img {
    height: 200px;
    background-size: cover;
    background-position: center;
}

.blog-content {
    padding: 25px;
}

.blog-date {
    font-size: 12px;
    color: var(--primary-color);
    font-weight: 600;
    text-transform: uppercase;
    display: block;
    margin-bottom: 10px;
}

.blog-content h3 {
    font-size: 18px;
    margin-bottom: 15px;
    line-height: 1.4;
    color: var(--text-dark);
}

.blog-content a {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.blog-content a:hover {
    gap: 10px;
}

/* Responsive Adjustments for New Sections */
@media (max-width: 768px) {
    .testimonials-slider-layout {
        flex-direction: column-reverse;
        text-align: center;
        padding: 30px;
    }

    .testimonial-image {
        flex: auto;
    }

    .image-frame {
        margin: 0 auto;
    }

    .specialties-grid {
        grid-template-columns: 1fr 1fr;
    }

    .ehr-card-grid {
        grid-template-columns: 1fr 1fr;
    }
}

/* Testimonials Section - Soft Warm Background */
.testimonials {
    background: linear-gradient(135deg, #fffbf7 0%, #fff 100%);
    position: relative;
}

/* FAQ Section - Clean White with subtle separation */
.faq-section {
    background: #ffffff;
    border-top: 1px solid #f0f0f0;
}

.faq-container {
    max-width: 800px;
    margin: 40px auto 0;
}

.faq-item {
    background: var(--white);
    border-bottom: 1px solid #eee;
    transition: all 0.3s ease;
}

.faq-item:hover {
    background: #fafafa;
}

.faq-question {
    padding: 25px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    font-size: 16px;
}

.faq-question:hover {
    color: var(--primary-color);
}

.faq-answer {
    display: none;
    padding: 0 20px 20px;
    font-size: 14px;
    color: var(--text-light);
}

.faq-item.active .faq-answer {
    display: block;
    animation: fadeIn 0.3s ease;
}

/* Consultation / Contact Section */
.consultation-section {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    /* Distinct gray-blue tint */
    border-top: 1px solid #dee2e6;
    padding: 80px 0;
}

.consultation-content h2 {
    color: var(--primary-color);
    font-size: 36px;
    margin-bottom: 30px;
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
    transition: transform 0.3s;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Modern Footer */
.main-footer {
    background: linear-gradient(to bottom, #1d0520, #0f0211);
    color: #a0a0a0;
    padding: 80px 0 20px;
    font-size: 15px;
    position: relative;
    overflow: hidden;
}

/* Subtle background accent */
.main-footer::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(240, 124, 36, 0.05) 0%, transparent 70%);
    z-index: 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 60px;
    position: relative;
    z-index: 1;
}

.footer-col h4 {
    color: var(--white);
    font-size: 18px;
    margin-bottom: 25px;
    position: relative;
    display: inline-block;
}

/* Underline decoration for titles */
.footer-col h4::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -8px;
    width: 30px;
    height: 2px;
    background: var(--accent-color);
}

.footer-logo img {
    height: 50px;
    margin-bottom: 20px;
    filter: brightness(0) invert(1);
    /* Ensure white logo */
    opacity: 0.9;
}

.footer-col p {
    line-height: 1.8;
    margin-bottom: 20px;
    max-width: 300px;
}

.footer-col ul li {
    margin-bottom: 12px;
}

.footer-col ul li a {
    color: #a0a0a0;
    transition: all 0.3s ease;
    display: inline-block;
}

.footer-col ul li a:hover {
    color: var(--accent-color);
    transform: translateX(5px);
}

.footer-socials {
    display: flex;
    gap: 15px;
    margin-top: 25px;
}

.footer-socials a {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: all 0.3s ease;
}

.footer-socials a:hover {
    background: var(--accent-color);
    border-color: var(--accent-color);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(240, 124, 36, 0.3);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 25px;
    text-align: center;
    font-size: 14px;
    color: #666;
}

/* Contact Icons */
.footer-col ul li i {
    color: var(--accent-color);
    width: 20px;
    margin-right: 10px;
}



/* Simple Dropdown Menu (e.g. States We Serve) */
.dropdown-menu.simple-menu {
    width: 250px;
    padding: 10px 0;
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: #fff;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border-radius: 0 0 8px 8px;
    border-top: 3px solid var(--primary-color);
    z-index: 1000;
}

.dropdown-menu.simple-menu li {
    display: block;
    width: 100%;
    margin: 0;
}

.dropdown-menu.simple-menu a {
    padding: 12px 20px;
    display: block;
    color: var(--text-dark);
    font-size: 14px;
    border-bottom: 1px solid #f5f5f5;
    transition: all 0.3s ease;
    text-transform: none;
    font-weight: 500;
}

.dropdown-menu.simple-menu a:last-child {
    border-bottom: none;
}

.dropdown-menu.simple-menu a:hover {
    background: #f9f9f9;
    color: var(--accent-color);
    padding-left: 25px;
}

/* Desktop Hover Logic */
@media (min-width: 993px) {
    .nav-menu li.dropdown:hover .dropdown-menu.simple-menu {
        display: block;
        animation: slideDown 0.3s ease;
    }
}

/* Responsive */
@media (max-width: 992px) {
    .top-bar {
        display: block;
        text-align: center;
        padding: 5px 0;
        height: auto;
    }

    .top-bar .container {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 0;
        /* Zero gap between rows */
    }

    /* Hide 'Follow Us' text to save space/clutter */
    .follow-us {
        display: none;
    }

    .top-left-socials {
        justify-content: center;
        margin-bottom: 2px;
        gap: 15px;
    }

    .top-left-socials a {
        font-size: 11px;
        width: 20px;
        height: 20px;
    }

    .top-right-links {
        justify-content: center;
        flex-wrap: wrap;
        gap: 5px;
        /* Minimal horizontal gap */
        width: 100%;
        line-height: 1.2;
    }

    /* Tighter break */
    .top-right-links .divider {
        flex-basis: 100%;
        width: 100%;
        height: 1px;
        /* Visible hairline separator? or 0 */
        background: rgba(255, 255, 255, 0.1);
        margin: 2px 0;
        display: block;
    }

    .contact-link {
        font-size: 11px;
        /* Very small */
        padding: 0;
    }

    .portal-link {
        margin-top: 2px;
        padding: 4px 10px;
        font-size: 10px;
        line-height: 1;
        height: auto;
    }

    .social-links {
        justify-content: center;
        margin-bottom: 5px;
        width: 100%;
        display: flex;
        gap: 15px;
    }

    /* Header Layout Refactor for Mobile (Centered Logo) */
    .main-header .container {
        padding: 0 20px;
        display: grid;
        grid-template-columns: 50px 1fr 50px;
        /* Left action, Center Logo, Right action */
        align-items: center;
        height: 70px;
    }

    .logo {
        display: flex;
        justify-content: center;
        align-items: center;
        width: 100%;
        grid-column: 2;
        /* Center column */
    }

    .logo img {
        height: 50px;
        /* Adjusted magnitude */
        margin: 0;
    }

    /* Move Toggle to Left */
    .mobile-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 40px;
        height: 40px;
        font-size: 24px;
        color: var(--primary-color);
        background: none;
        border: none;
        padding: 0;
        grid-column: 1;
        margin: 0;
        z-index: 1100;
        position: relative;
        cursor: pointer;
    }

    /* Fix button position when menu is open so it travels with viewport */
    .mobile-toggle.active {
        position: fixed;
        top: 25px;
        /* Adjust vertical alignment to match header */
        left: 15px;
        /* Adjust horizontal alignment */
    }

    /* Move Search/CTA to Right */
    .header-actions {
        display: flex;
        justify-content: flex-end;
        gap: 15px;
        grid-column: 3;
        /* Right column */
    }

    /* Hide Desktop CTA Button on Mobile */
    .header-actions .btn {
        display: none;
    }

    /* Ensure icons are visible */
    #searchTrigger {
        font-size: 20px;
    }

    /* Full Screen Mobile Menu Refactor (Transcure Replica) */
    .nav-menu {
        display: block;
        position: fixed;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100vh;
        background: #ffffff;
        /* White background */
        padding-top: 80px;
        /* Standard header height */
        transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        flex-direction: column;
        z-index: 1000;
        overflow-y: auto;
    }

    .nav-menu.active {
        left: 0 !important;
        /* Force override */
    }

    .nav-menu ul {
        flex-direction: column;
        gap: 0;
        width: 100%;
        padding: 0;
        /* No wrapper padding */
    }

    .nav-menu li {
        width: 100%;
        border-bottom: none;
        margin-bottom: 0;
    }

    .nav-menu li a {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 14px 20px;
        /* Exact Transcure Padding */
        font-family: 'Poppins', sans-serif;
        font-size: 15px;
        /* Exact Transcure Size */
        color: rgb(28, 36, 75);
        /* Transcure Navy */
        font-weight: 400;
        background: transparent;
        border-bottom: none;
    }

    .nav-menu li a:hover,
    .nav-menu li a:active {
        background: rgb(249, 250, 253);
        /* Subtle hover bg */
        color: rgb(28, 36, 75);
    }

    /* Mobile Extras Styling */
    .mobile-extras {
        display: block;
        padding: 20px 25px;
        background: #fdfdfd;
        border-top: 5px solid var(--primary-color);
        /* Separation */
    }

    .mobile-contact {
        display: block;
        padding: 8px 0 !important;
        /* Override link padding */
        font-size: 14px !important;
        color: var(--text-light) !important;
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .mobile-contact i {
        color: var(--accent-color);
        width: 20px;
    }

    .mobile-cta.btn {
        display: block;
        width: 100%;
        text-align: center;
        margin-top: 15px;
        margin-bottom: 30px;
        /* Added spacing */
        padding: 12px;
        font-size: 16px;
    }

    /* Mega Menu / Dropdown Mobile - ACCORDION ANIMATION */
    .mega-menu {
        position: static;
        display: block;
        /* Always in DOM for animation */
        max-height: 0;
        opacity: 0;
        overflow: hidden;
        visibility: hidden;
        box-shadow: none;
        border: none;
        background: #f8f9fa;
        background: #f8f9fa;
        padding: 0 !important;
        /* Force reset */
        margin: 0 !important;
        min-height: 0 !important;
        border: none !important;
        /* No padding when closed */
        width: 100%;
        transform: none;
        left: auto;
        transition: all 0.5s cubic-bezier(0.25, 1, 0.5, 1);
        /* Accordion Ease */
    }

    /* Important: Override hover effects for mobile - STRICTLY CLICK ONLY */
    .nav-menu li.dropdown:hover .dropdown-menu.mega-menu {
        max-height: 0;
        opacity: 0;
        visibility: hidden;
        padding: 0;
    }

    /* Only show when the parent LI has the 'active' class (set by JS click) */
    .nav-menu li.dropdown.active .mega-menu {
        display: block !important;
        max-height: 2000px !important;
        /* Force override hover */
        opacity: 1 !important;
        visibility: visible !important;
        padding: 10px 0 !important;
    }

    @keyframes slideDown {
        from {
            opacity: 0;
            transform: translateY(-10px);
        }

        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    /* --- AGGRESSIVE MOBILE FLATTENING & STABILITY FIX --- */

    /* 1. Stop Floating/Jumping */
    .dropdown-menu.mega-menu {
        position: static !important;
        float: none !important;
        display: block;
        /* Keep block for transition */
        width: 100% !important;
        min-width: 100% !important;
        max-width: 100% !important;
        box-shadow: none !important;
        border: none !important;
        background: transparent !important;
        margin: 0 !important;
        transform: none !important;
        /* Props controlled by main rule above */
    }

    /* 2. Show when active */
    .nav-menu li.dropdown.active .mega-menu {
        /* Props controlled by main rule above */
    }

    /* Mobile Styles for Simple Dropdown */
    .dropdown-menu.simple-menu {
        position: static !important;
        display: block;
        /* For animation */
        max-height: 0;
        opacity: 0;
        overflow: hidden;
        visibility: hidden;
        width: 100% !important;
        box-shadow: none !important;
        border: none !important;
        background: transparent !important;
        padding-left: 0 !important;
        padding-top: 0 !important;
        padding-bottom: 0 !important;
        margin: 0 !important;
        min-height: 0 !important;
        border: none !important;
        border-left: 3px solid #f0f0f0 !important;
        transition: all 0.5s cubic-bezier(0.25, 1, 0.5, 1);
    }

    .nav-menu li.dropdown.active .dropdown-menu.simple-menu {
        max-height: 1000px;
        opacity: 1;
        visibility: visible;
        padding-left: 20px !important;
        padding-top: 10px;
        padding-bottom: 10px;
    }

    .dropdown-menu.simple-menu a {
        padding: 10px 15px !important;
        font-size: 14px !important;
    }

    /* 3. Flatten Grid & Columns */
    .mega-menu-grid,
    .mega-col {
        display: block !important;
        width: 100% !important;
        padding: 0 !important;
        margin: 0 !important;
        height: auto !important;
    }

    /* 4. Fix Item Styling & Remove Hover Jitters */
    .mega-item {
        display: block !important;
        width: 100% !important;
        padding: 12px 0 12px 30px !important;
        margin: 0 !important;
        border-bottom: 1px solid rgba(0, 0, 0, 0.03) !important;
        background: transparent !important;
        transition: none !important;
        box-sizing: border-box !important;
    }

    .mega-item:hover,
    .mega-item:active {
        background: transparent !important;
        color: inherit !important;
    }

    .mega-text h4 {
        font-size: 14px !important;
        color: #555 !important;
        font-weight: 400 !important;
        margin: 0 !important;
    }

    /* 5. Hide Icons/Footer absolutely */
    .mega-item .mega-icon,
    .mega-text p,
    .mega-footer,
    .mega-menu .cta-btn {
        display: none !important;
    }

    /* Prevent flashing/jerking by removing transitions */
    .dropdown-menu.mega-menu {
        transition: none !important;
    }

    /* Ensure link creates full tap area */
    .nav-menu li.dropdown>a {
        width: 100%;
        cursor: pointer;
    }

    .nav-menu li.dropdown>a {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .nav-menu li.dropdown>a i {
        transition: transform 0.3s;
    }

    .nav-menu li.dropdown.active>a i {
        transform: rotate(180deg);
    }

    /* Ensure specific styling for slide content adjustments */

    .hero-slider {
        height: auto;
        min-height: auto;
        /* Remove 100vh constraint */
        padding-top: 20px;
        /* Reduced space */
        padding-bottom: 30px;
    }

    /* Fix Second Slide Not Appearing & Spacing */


    .slide.active {
        display: block;
    }

    /* Reduce Mobile Heading Size */
    .hero-text h1 {
        font-size: 32px !important;
        line-height: 1.2;
    }

    /* Reduce Mobile Button Size */
    .hero-cta-group .btn {
        padding: 10px 24px !important;
        font-size: 14px !important;
    }

    /* Global Section Spacing Reduction for Mobile */
    .section,
    .consultation-section,
    .main-footer,
    .dark-cta-section,
    .ai-section,
    .services-expanding-section {
        padding: 40px 0 !important;
        /* Reduced from 80px/90px */
    }

    .section-header {
        margin-bottom: 30px;
    }

    .section-header h2 {
        font-size: 28px !important;
        /* Reduced from 42px */
        margin-bottom: 15px;
    }

    .section-header p {
        font-size: 16px;
    }

    /* Fix Slider Alignment: Removing double padding */
    .slide {
        display: none;
        position: relative;
        height: auto;
        padding: 0 !important;
        /* Remove wrapper padding */
        opacity: 1 !important;
        visibility: visible !important;
    }

    .slide-container-split {
        height: auto;
        padding: 30px 15px !important;
        /* Standard side padding */
        flex-direction: column !important;
        justify-content: center;
        gap: 30px;
        width: 100%;
        /* Ensure full width */
    }

    /* Force Order & Center Alignment for Mobile */
    .hero-text {
        order: 1;
        text-align: center;
        width: 100%;
        margin: 0;
        padding: 0 15px;
        align-items: center;
    }

    .hero-image-visual {
        order: 2;
        width: 100%;
        margin-top: 20px;
        justify-content: center;
    }

    .image-blob-wrap {
        width: 280px;
        /* Smaller blob for mobile */
        height: 280px;
        margin: 0 auto;
    }

    .ai-wrapper {
        flex-direction: column;
    }

    .testimonials-layout {
        grid-template-columns: 1fr;
    }

    .video-testimonial {
        height: 250px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }
}

/* --- DESKTOP SPECIFIC STYLES (Min-Width 993px) --- */
@media (min-width: 993px) {

    /* Restore Hover for Desktop */
    .nav-menu li.dropdown:hover .dropdown-menu.mega-menu {
        display: block;
        opacity: 1;
        visibility: visible;
        animation: slideDown 0.3s ease;
    }
}

/* Consultation Form Section */
/* Consultation Form Section (Refactored) */
.consultation-section {
    padding: 80px 0;
    background-color: var(--white);
}

.consultation-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 60px;
    align-items: center;
}

@media (max-width: 900px) {
    .consultation-grid {
        grid-template-columns: 1fr;
        /* Stack vertically */
        gap: 40px;
    }

    .consultation-image {
        order: -1;
        /* Show image first on mobile for engagement */
        height: 300px;
    }
}

.consultation-content h2 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 30px;
    color: var(--secondary-color);
    /* Dark Text */
}

.challenges-list {
    margin-bottom: 35px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.challenge-item {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 16px;
    position: relative;
    padding-left: 35px;
    user-select: none;
    color: var(--text-color);
    /* Dark Gray Text */
}

.challenge-item input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    left: 0;
    height: 20px;
    width: 20px;
    background-color: transparent;
    border: 2px solid var(--primary-color);
    /* Primary Color Border */
    border-radius: 4px;
    transition: all 0.2s ease;
}

.challenge-item:hover input~.checkmark {
    background-color: rgba(0, 0, 0, 0.05);
}

.challenge-item input:checked~.checkmark {
    background-color: var(--primary-color);
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.challenge-item input:checked~.checkmark:after {
    display: block;
}

.challenge-item .checkmark:after {
    left: 6px;
    top: 2px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    /* 2 columns for inputs looks better in this width */
    gap: 15px;
    margin-bottom: 25px;
}

.form-row input {
    width: 100%;
    padding: 12px 20px;
    border-radius: 8px;
    border: 1px solid #ddd;
    outline: none;
    font-size: 15px;
    font-family: 'Poppins', sans-serif;
    transition: border-color 0.3s;
}

.form-row input:focus {
    border-color: var(--primary-color);
}

.form-cta-btn {
    padding: 14px 40px;
    font-size: 16px;
    width: auto;
    /* Not full width */
    border-radius: 8px;
    /* Inherits .btn-primary styles */
}

.consultation-image img {
    width: 100%;
    border-radius: 20px;
    box-shadow: var(--shadow-lg);
    object-fit: cover;
    height: 100%;
    max-height: 500px;
}

@media (max-width: 992px) {
    .consultation-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .consultation-image {
        order: -1;
        /* Image on top for mobile/tablet? Or bottom? Let's keep content first. */
        display: none;
        /* Often cleaner to hide large images on mobile forms, or keep it. Let's keep it but stack. */
        display: block;
        order: 1;
    }
}

@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
    }

    .form-cta-btn {
        width: 100%;
    }
}

/* Dark CTA Section */
.dark-cta-section {
    position: relative;
    background-image: url('https://images.unsplash.com/photo-1551076805-e1869033e561?ixlib=rb-1.2.1&auto=format&fit=crop&w=1950&q=80');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    /* Parallax effect */
    padding: 100px 0;
    color: white;
    text-align: center;
}

.dark-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(26, 26, 26, 0.85);
    /* Very Dark tint */
    z-index: 1;
}

.dark-cta-section .container {
    position: relative;
    z-index: 2;
}

.cta-content h2 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 20px;
    color: white;
}

.cta-content p {
    font-size: 18px;
    margin-bottom: 35px;
    color: rgba(255, 255, 255, 0.9);
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.cta-btn {
    padding: 15px 45px;
    font-size: 18px;
    border-radius: 50px;
    background: #58165d;
    /* Dark Purple Accent */
    border: 2px solid #58165d;
    color: white;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.cta-btn:hover {
    background: transparent;
    border-color: white;
    color: white;
    transform: translateY(-3px);
}

/* --- Global Background Refinement for Readability --- */
/* Alternating "Gray" and "Darker Gray" (interpreted as noticeable contrast) */

/* Default Section/Body - Lightest Gray */
body {
    background-color: #f9f9f9;
}

/* White Sections (Cards or Specific Areas) */
.section.bg-white,
.ehr-section {
    background-color: #ffffff !important;
}

/* Light Gray Sections */
.section.bg-light,
.testimonials,
.process-section {
    background-color: #f4f6f8 !important;
    /* Cool Light Gray */
}

/* Darker Gray Sections (for valid contrast) */
.specialties-section {
    background-color: #e9ecef !important;
    /* Distinct Darker Gray */
}

.consultation-section {
    background-color: #ffffff !important;
    /* Keep form section clean white for input visibility */
}

/* Ensure process cards and others pop against these backgrounds */
.process-card,
.ehr-card,
.blog-card,
.faq-item {
    background-color: #ffffff;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    /* Soften shadows */
    border: 1px solid rgba(0, 0, 0, 0.03);

    .form-cta-btn {
        width: 100%;
    }
}

/* Navigation Mega Menu */
.nav-menu ul li {
    position: relative;
}

/* Mega Menu Container */
.dropdown-menu.mega-menu {
    position: absolute;
    top: 100%;
    left: -150px;
    /* Shift left to center visually relative to link */
    width: 650px;
    /* Wide mega menu */
    background: white;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    border-radius: 12px;
    padding: 25px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px);
    transition: all 0.3s ease;
    display: block;
    z-index: 1000;
    border-top: 4px solid var(--primary-color);
    /* Top accent bar like screenshot */
}

/* Show Dropdown on Hover */
.nav-menu li.dropdown:hover .dropdown-menu.mega-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.mega-menu-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.mega-col {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.mega-item {
    display: flex !important;
    /* Override nav link generic styles */
    align-items: flex-start;
    gap: 15px;
    padding: 10px;
    border-radius: 8px;
    transition: background 0.2s;
    text-decoration: none;
}

.mega-item:hover {
    background-color: #f9f9f9;
}

/* Icon Styling */
.mega-icon {
    font-size: 20px;
    color: var(--primary-color);
    width: 30px;
    padding-top: 3px;
}

.mega-item:hover .mega-icon {
    transform: scale(1.1);
    transition: transform 0.2s;
}

/* Text Styling */
.mega-text h4 {
    font-size: 15px;
    font-weight: 600;
    color: #333;
    margin: 0 0 5px 0;
    transition: color 0.2s;
}

.mega-item:hover .mega-text h4 {
    color: var(--primary-color);
}

.mega-text p {
    font-size: 12px;
    color: #777;
    margin: 0;
    line-height: 1.4;
    white-space: normal;
    /* Allow wrapping */
}

/* Mega Menu Footer Link */
.mega-footer {
    border-top: 1px solid #eee;
    margin-top: 20px;
    padding-top: 15px;
    text-align: center;
}

.mega-footer a {
    color: var(--primary-color) !important;
    font-weight: 700 !important;
    font-size: 14px !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mega-footer a:hover {
    text-decoration: underline;
}

/* Scroll to Top Button */
#scrollTopBtn {
    display: none;
    position: fixed;
    bottom: 20px;
    right: 30px;
    z-index: 99;
    font-size: 18px;
    border: none;
    outline: none;
    background-color: var(--primary-color);
    color: white;
    cursor: pointer;
    padding: 15px;
    border-radius: 50%;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    transition: background-color 0.3s, transform 0.3s;
}

#scrollTopBtn:hover {
    background-color: var(--secondary-color);
    transform: translateY(-5px);
}

.ehr-hidden,
.specialty-hidden {
    display: none;
}

/* Footer */
.main-footer {
    background-color: #30084f;
    /* Brand Purple */
    background-image: url('https://images.unsplash.com/photo-1579546929518-9e396f3cc809?auto=format&fit=crop&q=80&w=2000');
    /* Subtle Texture */
    background-blend-mode: overlay;
    background-position: center;
    background-size: cover;
    color: var(--white);
    padding: 70px 0 30px;
    position: relative;
    /* Ensure text pops */
}

.main-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(48, 8, 79, 0.92);
    /* Heavy Overlay to keep it dark */
    pointer-events: none;
    z-index: 1;
}

.main-footer .container {
    position: relative;
    z-index: 2;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 50px;
}

.footer-logo img {
    height: 80px;
    /* Prominent Footer Logo */
    width: auto;
    margin-bottom: 20px;
    opacity: 1;
    /* Full opacity */
    filter: brightness(0) invert(1);
    /* Ensure it's white if not already */
}

.footer-col h4 {
    font-size: 18px;
    margin-bottom: 20px;
    color: var(--accent-color);
    /* Orange Headings */
}

.footer-col ul li {
    margin-bottom: 12px;
}

.footer-col ul li a {
    color: rgba(255, 255, 255, 0.8);
    transition: var(--transition);
}

.footer-col ul li a:hover {
    color: var(--accent-color);
    padding-left: 5px;
}

.footer-socials {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.footer-socials a {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: var(--transition);
}

.footer-socials a:hover {
    background: var(--accent-color);
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
}

.footer-bottom a {
    color: inherit;
    transition: all 0.3s ease;
    text-decoration: none;
    margin: 0 5px;
}

.footer-bottom a:hover {
    color: var(--accent-color);
    text-decoration: underline;
}

/* Mega Menu Styles */
.mega-item {
    display: flex !important;
    /* Override nav link generic styles */
    align-items: flex-start;
    gap: 15px;
    padding: 10px;
    border-radius: 8px;
    transition: background 0.2s;
    text-decoration: none;
}

.mega-item:hover {
    background-color: #f9f9f9;
}

/* Icon Styling */
.mega-icon {
    font-size: 20px;
    color: var(--primary-color);
    width: 30px;
    padding-top: 3px;
}

.mega-item:hover .mega-icon {
    transform: scale(1.1);
    transition: transform 0.2s;
}

/* Text Styling */
.mega-text h4 {
    font-size: 15px;
    font-weight: 600;
    color: #333;
    margin: 0 0 5px 0;
    transition: color 0.2s;
}

.mega-item:hover .mega-text h4 {
    color: var(--accent-color);
}

.mega-text p {
    font-size: 12px;
    color: #777;
    margin: 0;
    line-height: 1.4;
    white-space: normal;
    /* Allow wrapping */
}

/* Mega Menu Footer Link */
.mega-footer {
    border-top: 1px solid #eee;
    margin-top: 20px;
    padding-top: 15px;
    text-align: center;
}

.mega-footer a {
    color: var(--primary-color) !important;
    font-weight: 700 !important;
    font-size: 14px !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mega-footer a:hover {
    text-decoration: underline;
    color: var(--accent-color) !important;
}

/* Scroll to Top Button */
/* Scroll to Top Button - Modern */
#scrollTopBtn {
    display: none;
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 999;
    /* Ensure it's on top */
    width: 50px;
    height: 50px;
    border: none;
    outline: none;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    cursor: pointer;
    border-radius: 50%;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    backdrop-filter: blur(5px);
    /* Glass effect if transparent */
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

#scrollTopBtn:hover {
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 8px 25px rgba(106, 27, 154, 0.5);
    /* Glow effect */
}

/* Optional Pulse Animation */
@keyframes btnPulse {
    0% {
        box-shadow: 0 0 0 0 rgba(106, 27, 154, 0.7);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(106, 27, 154, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(106, 27, 154, 0);
    }
}

#scrollTopBtn.visible {
    display: flex;
    /* Use flex to center icon */
    animation: btnPulse 2s infinite;
}

.ehr-hidden,
.specialty-hidden {
    display: none;
}



/* Nationwide Section - Premium Design */
.nationwide-section {
    position: relative;
    padding: 100px 0;
    overflow: hidden;
    color: var(--white);
    /* Premium dark background with map texture & parallax */
    background:
        linear-gradient(to bottom, rgba(2, 6, 23, 0.95), rgba(15, 23, 42, 0.85)),
        url('https://images.unsplash.com/photo-1451187580459-43490279c0fa?auto=format&fit=crop&q=80&w=2000');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

/* Hide simple SVG overlay, using high-res image instead */
.map-overlay {
    display: none;
}

.nationwide-section .container {
    position: relative;
    z-index: 2;
}

.nationwide-section .section-header h2 {
    color: var(--white);
    font-size: 42px;
    /* Largers */
    font-weight: 800;
    letter-spacing: -1px;
    text-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.nationwide-section .section-header p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.9);
}

.nationwide-section .divider {
    background: var(--accent-color);
    width: 80px;
    height: 4px;
    border-radius: 2px;
    margin: 25px auto;
}

/* States Grid */
.states-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-top: 60px;
}

.state-card {
    background: rgba(255, 255, 255, 0.03);
    /* Subtle Glassmorphism */
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 35px 25px;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    /* Bouncy transition */
    cursor: pointer;
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.state-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 100%);
    opacity: 0;
    transition: opacity 0.4s;
}

.state-card:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-12px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 20px rgba(var(--accent-color-rgb), 0.3);
    /* Assuming accent color usage */
    border-color: var(--accent-color);
}

.state-card:hover::before {
    opacity: 1;
}

.state-card i {
    font-size: 36px;
    background: linear-gradient(45deg, var(--accent-color), #ff8f00);
    /* Gradient Icon */
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 25px;
    transition: all 0.4s ease;
    display: inline-block;
}

.state-card:hover i {
    transform: scale(1.2) rotate(5deg);
    filter: drop-shadow(0 5px 15px var(--accent-color));
}

.state-card h3 {
    font-size: 22px;
    font-weight: 700;
    margin: 0;
    color: var(--white);
    letter-spacing: 0.5px;
}

/* Hidden States Logic */
.state-hidden {
    display: none;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.state-hidden.visible {
    display: block;
    /* Used for JS toggle, might need layout fix */
}

/* Animation for revealing states */
@keyframes fadeInUpState {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.state-reveal {
    animation: fadeInUpState 0.6s ease forwards;
}

/* Button Refinement */
.btn-outline-light {
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: var(--white);
    background: transparent;
    transition: all 0.3s ease;
}

.btn-outline-light:hover {
    background: var(--white);
    color: var(--primary-color);
    border-color: var(--white);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.2);
}

/* Mobile Responsiveness for Nationwide */
@media (max-width: 768px) {
    .nationwide-section {
        padding: 60px 0;
    }

    .nationwide-section .section-header h2 {
        font-size: 28px;
    }

    .states-grid {
        grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
        /* Smaller cards on mobile */
        gap: 15px;
    }

    .state-card {
        padding: 20px 15px;
    }

    .state-card i {
        font-size: 24px;
        margin-bottom: 10px;
    }

    .state-card h3 {
        font-size: 16px;
    }
}

/* Book an Appointment form - privacy text (same on all services/specialties) */
.form-privacy-text {
    font-size: 12px;
    color: #666;
    text-align: center;
    margin-top: 15px;
    margin-bottom: 0;
    line-height: 1.5;
    display: block;
}

.form-privacy-text a {
    color: var(--primary-color);
    text-decoration: underline;
}

.form-privacy-text a:hover {
    color: var(--accent-color);
}

/* Privacy / Cookie Consent Popup - sticky at bottom */
.privacy-consent-popup {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: linear-gradient(135deg, var(--primary-color) 0%, #1a0525 100%);
    color: #fff;
    box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.2);
    padding: 20px 24px;
    transform: translateY(100%);
    transition: transform 0.4s ease;
}

.privacy-consent-popup.show {
    transform: translateY(0);
}

.privacy-consent-inner {
    max-width: 1200px;
    margin: 0 auto;
}

.privacy-consent-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}

.privacy-consent-text {
    flex: 1;
    min-width: 280px;
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.95);
}

.privacy-consent-icon {
    color: var(--accent-color);
    margin-right: 8px;
}

.privacy-consent-text a {
    color: var(--accent-color);
    text-decoration: underline;
}

.privacy-consent-text a:hover {
    color: #fff;
}

.privacy-consent-btns {
    display: flex;
    gap: 12px;
    flex-shrink: 0;
}

.privacy-consent-btns .btn {
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 8px;
}

.privacy-consent-btns .btn-primary {
    background: var(--accent-color);
    border-color: var(--accent-color);
    color: #fff;
}

.privacy-consent-btns .btn-primary:hover {
    background: #ff8c3a;
    border-color: #ff8c3a;
    color: #fff;
}

.btn-outline-privacy {
    background: transparent;
    border: 2px solid rgba(255, 255, 255, 0.6);
    color: #fff;
}

.btn-outline-privacy:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: #fff;
    color: #fff;
}

@media (max-width: 768px) {
    .privacy-consent-popup {
        padding: 16px 20px;
    }
    .privacy-consent-content {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }
    .privacy-consent-text {
        min-width: 100%;
    }
    .privacy-consent-btns {
        justify-content: center;
    }
}