/* ========================================
   Crescent Community Hospital - Logo Palette
   ======================================== */

:root {
    --primary-color: #0078b8;
    --primary-2: #00c2d1;
    --secondary-color: #003b78;
    --ink: #102235;
    --muted: #5e7282;
    --soft: #e9f8fb;
    --soft-2: #f7fcfd;
    --line: #cfe7ee;
    --panel: #ffffff;
    --success: #00a99d;
    --shadow: 0 22px 55px rgba(0, 59, 120, 0.16);
    --radius: 18px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--ink);
    font-family: "Inter", "Segoe UI", Roboto, Arial, sans-serif;
    line-height: 1.55;
    background:
        radial-gradient(circle at 4% 0%, rgba(0, 194, 209, 0.22), transparent 28rem),
        radial-gradient(circle at 96% 6%, rgba(0, 120, 184, 0.24), transparent 30rem),
        linear-gradient(180deg, #f2fbfd 0%, #ffffff 44%);
}

img {
    max-width: 100%;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s ease, background-color 0.2s ease, transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

a:hover {
    color: var(--primary-color);
}

.container,
.hero-section .container {
    max-width: 1280px;
}

/* ========================================
   NAVIGATION
   ======================================== */

.navbar {
    position: sticky;
    top: 0;
    z-index: 20;
    min-height: 124px;
    align-items: flex-end;
    padding-top: 30px;
    padding-bottom: 0;
    background: rgba(255, 255, 255, 0.96) !important;
    border-bottom: 1px solid rgba(0, 120, 184, 0.1);
    box-shadow: 0 16px 38px rgba(0, 59, 120, 0.1) !important;
    backdrop-filter: blur(18px);
}

.navbar::before {
    content: "Saida Plaza Building, Muratina Road, Eastleigh North, Nairobi     Open 24/7     Call +254 768 366 205";
    position: absolute;
    inset: 0 0 auto 0;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    background: linear-gradient(90deg, #003b78, #0078b8 52%, #00b9c9);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.01em;
}

.navbar::after {
    content: "Committed to care";
    position: absolute;
    top: 0;
    right: max(1.2rem, calc((100vw - 1280px) / 2));
    height: 30px;
    display: flex;
    align-items: center;
    color: white;
    font-size: 0.76rem;
    font-weight: 700;
}

.navbar .container {
    min-height: 94px;
}

.navbar-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    color: var(--secondary-color) !important;
    font-size: 1.34rem;
    font-weight: 900;
    letter-spacing: -0.03em;
}

.navbar-brand img {
    width: 200px;
    height: 88px;
    object-fit: contain;
    border-radius: 50%;
    filter: drop-shadow(0 8px 16px rgba(0, 120, 184, 0.18));
}

.navbar-nav {
    align-items: center;
    gap: 0.38rem;
}

.nav-link {
    color: var(--secondary-color) !important;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 800;
    padding: 0.68rem 0.95rem !important;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color) !important;
    background: rgba(0, 194, 209, 0.1);
}

.navbar-toggler {
    border: 0;
    border-radius: 999px;
    background: var(--primary-color);
    padding: 0.58rem 0.7rem;
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 194, 209, 0.2);
}

/* ========================================
   HOME HERO
   ======================================== */

.hero-section {
    position: relative;
    isolation: isolate;
    min-height: 660px;
    overflow: hidden;
    background:
        radial-gradient(circle at 78% 52%, rgba(0, 194, 209, 0.18), transparent 16rem),
        linear-gradient(90deg, #f3fbfd 0%, #ffffff 54%, #e6f7fb 100%);
}

.hero-section::before {
    content: "";
    position: absolute;
    width: 34rem;
    height: 34rem;
    right: 10%;
    bottom: -12rem;
    border-radius: 50%;
    background: rgba(0, 194, 209, 0.14);
    z-index: -1;
}

.hero-section .row {
    min-height: 660px !important;
}

.hero-content {
    max-width: 650px;
    padding: 3rem 0;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
    font-size: 0.82rem;
    font-weight: 900;
}

.hero-content h1 {
    margin-bottom: 1.3rem;
    color: var(--secondary-color);
    font-size: clamp(3.15rem, 7vw, 6.45rem);
    font-weight: 900;
    line-height: 0.92;
    letter-spacing: -0.065em;
}

.hero-content .lead {
    max-width: 520px;
    margin-bottom: 2rem;
    color: var(--muted);
    font-size: 1.02rem;
}

.hero-search {
    display: grid;
    grid-template-columns: minmax(150px, 1fr) minmax(150px, 1fr) auto;
    gap: 0.4rem;
    width: min(610px, 100%);
    padding: 0.42rem;
    background: white;
    border: 1px solid var(--line);
    border-radius: 999px;
    box-shadow: 0 18px 40px rgba(0, 120, 184, 0.13);
}

.hero-search .form-select {
    min-height: 46px;
    border: 0;
    box-shadow: none;
}

.hero-search .btn {
    display: inline-flex;
    min-width: 145px;
    align-items: center;
    justify-content: center;
}

.hero-visual {
    position: relative;
    min-height: 600px;
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

.hero-visual::before {
    content: "";
    position: absolute;
    width: min(88%, 520px);
    aspect-ratio: 1;
    bottom: 0;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(0, 194, 209, 0.18), rgba(0, 59, 120, 0.08));
    z-index: 0;
}

.hero-visual img {
    position: relative;
    z-index: 1;
    max-height: 590px;
    width: min(100%, 520px);
    object-fit: cover;
    object-position: center top;
    border-radius: 42% 42% 0 0;
    filter: drop-shadow(0 26px 42px rgba(82, 67, 170, 0.14));
}

.specialty-badge {
    position: absolute;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.8rem 1rem;
    color: var(--secondary-color);
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid var(--line);
    border-radius: 999px;
    box-shadow: var(--shadow);
    font-size: 0.86rem;
    font-weight: 900;
}

.specialty-badge i {
    color: var(--primary-color);
}

.badge-cardiology {
    top: 30%;
    left: 3%;
}

.badge-neurology {
    bottom: 20%;
    left: 0;
}

.badge-orthopedics {
    right: 0;
    bottom: 23%;
}

/* ========================================
   BANNERS FOR INNER PAGES
   ======================================== */

.hero-banner {
    position: relative;
    min-height: 260px;
    display: flex;
    align-items: center;
    overflow: hidden;
    background:
        linear-gradient(90deg, rgba(243, 251, 253, 0.98) 0%, rgba(243, 251, 253, 0.9) 50%, rgba(243, 251, 253, 0.5) 100%),
        url("public/care-team.png") center right / cover !important;
}

body:has(#departmentFilter) .hero-banner {
    background-image:
        linear-gradient(90deg, rgba(243, 251, 253, 0.98) 0%, rgba(243, 251, 253, 0.88) 50%, rgba(243, 251, 253, 0.45) 100%),
        url("public/hero-doctor.png") !important;
}

body:has(#serviceFilter) .hero-banner {
    background-image:
        linear-gradient(90deg, rgba(243, 251, 253, 0.98) 0%, rgba(243, 251, 253, 0.88) 50%, rgba(243, 251, 253, 0.45) 100%),
        url("public/community-health.png") !important;
}

body:has(#deptTabs) .hero-banner {
    background-image:
        linear-gradient(90deg, rgba(243, 251, 253, 0.98) 0%, rgba(243, 251, 253, 0.88) 50%, rgba(243, 251, 253, 0.45) 100%),
        url("public/surgical-team.png") !important;
}

body:has(#categoryFilter) .hero-banner {
    background-image:
        linear-gradient(90deg, rgba(243, 251, 253, 0.98) 0%, rgba(243, 251, 253, 0.88) 50%, rgba(243, 251, 253, 0.45) 100%),
        url("public/community-health.png") !important;
}

.hero-banner h1 {
    color: var(--secondary-color);
    font-size: clamp(2.4rem, 5vw, 4.5rem);
    font-weight: 900;
    letter-spacing: -0.055em;
}

.hero-banner p {
    max-width: 560px;
    color: var(--muted);
}

/* ========================================
   BUTTONS, FORMS, FILTERS
   ======================================== */

.btn {
    border-radius: 999px;
    font-size: 0.86rem;
    font-weight: 900;
}

.btn-primary {
    color: white;
    background: linear-gradient(135deg, var(--primary-2), var(--primary-color));
    border-color: transparent;
    padding: 0.78rem 1.45rem;
    box-shadow: 0 16px 30px rgba(0, 120, 184, 0.25);
}

.btn-primary:hover {
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 20px 36px rgba(0, 120, 184, 0.32);
}

.btn-light,
.btn-outline-primary {
    color: var(--primary-color);
    background: white;
    border-color: var(--line);
    padding: 0.72rem 1.35rem;
}

.btn-light:hover,
.btn-outline-primary:hover {
    color: white;
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.form-control,
.form-select {
    min-height: 46px;
    color: var(--ink);
    border: 1px solid var(--line);
    border-radius: 999px;
    font-size: 0.86rem;
    font-weight: 700;
    padding: 0.7rem 1rem;
    background-color: white;
}

textarea.form-control {
    border-radius: 14px;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(0, 194, 209, 0.14);
}

.form-label {
    color: var(--secondary-color);
    font-weight: 800;
}

.filter-section {
    background: white !important;
    border-bottom: 1px solid var(--line);
}

.filter-section h3,
.doctors-section h2,
.departments-section h2 {
    color: var(--secondary-color);
    font-weight: 900;
    letter-spacing: -0.04em;
}

/* ========================================
   HOME SECTIONS
   ======================================== */

.features-section,
.about-section,
.home-services,
.doctors-section,
.services-section,
.news-section,
.department-details,
.departments-section {
    background: white !important;
}

.feature-card {
    min-height: 116px;
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--secondary-color);
    background: white;
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: 0 10px 28px rgba(82, 67, 170, 0.06);
}

.feature-card:hover {
    color: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.feature-icon {
    width: 3rem;
    height: 3rem;
    display: inline-grid;
    flex: 0 0 auto;
    place-items: center;
    color: var(--primary-color) !important;
    border: 1px solid rgba(0, 194, 209, 0.36);
    border-radius: 11px;
    font-size: 1.6rem !important;
}

.feature-card h5 {
    margin: 0;
    color: inherit;
    font-weight: 900;
    letter-spacing: -0.03em;
}

.about-photo {
    position: relative;
}

.about-photo img {
    width: 100%;
    height: 360px;
    object-fit: cover;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.rating-card {
    position: absolute;
    right: 1rem;
    bottom: -1rem;
    width: 180px;
    padding: 0.9rem;
    background: white;
    border: 1px solid var(--line);
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.rating-card strong {
    display: block;
    color: var(--secondary-color);
    font-size: 0.9rem;
}

.rating-card span {
    display: block;
    color: var(--success);
    font-size: 0.82rem;
}

.rating-card small {
    color: var(--muted);
    font-size: 0.7rem;
}

.about-section h2,
.home-services h2,
.cta-section h2 {
    color: var(--secondary-color);
    font-size: clamp(2rem, 4vw, 3.2rem);
    font-weight: 900;
    line-height: 1.04;
    letter-spacing: -0.055em;
}

.about-section p,
.home-services p,
.cta-section p,
.text-muted {
    color: var(--muted) !important;
}

.about-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    align-items: center;
    margin-top: 1.6rem;
}

.doctor-signature {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--secondary-color);
    font-weight: 800;
}

.doctor-signature img {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    object-fit: cover;
}

.home-services {
    background: linear-gradient(180deg, white 0%, #f2fbfd 100%) !important;
}

.service-preview-card {
    min-height: 230px;
    padding: 1.8rem;
    background: white;
    border: 1px solid var(--line);
    border-radius: 12px;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.service-preview-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0, 194, 209, 0.48);
    box-shadow: var(--shadow);
}

.service-preview-card i {
    color: var(--primary-color);
    font-size: 2rem;
}

.service-preview-card h5 {
    margin-top: 1.6rem;
    color: var(--secondary-color);
    font-weight: 900;
}

.service-preview-card p {
    min-height: 54px;
    font-size: 0.88rem;
}

.service-preview-card a {
    color: var(--secondary-color);
    font-size: 0.82rem;
    font-weight: 900;
}

.service-preview-card a:hover {
    color: var(--primary-color);
}

.cta-section {
    overflow: hidden;
    background:
        radial-gradient(circle at 78% 45%, rgba(0, 194, 209, 0.2), transparent 18rem),
        linear-gradient(90deg, #f2fbfd 0%, #e9f8fb 100%) !important;
}

.recommend-list {
    display: grid;
    gap: 0.9rem;
    margin-top: 1.6rem;
}

.recommend-list div {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    max-width: 420px;
    padding: 1rem;
    color: var(--secondary-color);
    background: rgba(255, 255, 255, 0.76);
    border: 1px solid var(--line);
    border-radius: 12px;
    font-weight: 900;
}

.recommend-list i {
    color: var(--primary-color);
}

.hello-card {
    position: relative;
    min-height: 360px;
    overflow: hidden;
    padding: 2rem;
    color: white;
    background: linear-gradient(135deg, #003b78, #0078b8 60%, #00b9c9);
    border-radius: 20px;
    box-shadow: var(--shadow);
}

.hello-card span,
.hello-card strong {
    position: relative;
    z-index: 1;
    display: block;
    font-weight: 900;
    letter-spacing: -0.05em;
}

.hello-card span {
    font-size: 3rem;
}

.hello-card strong {
    font-size: 1.7rem;
}

.hello-card img {
    position: absolute;
    right: 0;
    bottom: 0;
    width: 58%;
    height: 90%;
    object-fit: cover;
    object-position: top center;
    border-radius: 18px 0 18px 0;
}

/* ========================================
   EXISTING PAGE CARDS
   ======================================== */

.card,
.dept-list-item {
    border: 1px solid var(--line) !important;
    border-radius: 12px;
    background: white;
    box-shadow: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover,
.dept-list-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow) !important;
}

.service-item {
    min-height: 250px;
    background: #f8f7fd;
}

.service-item .card-body {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 1.8rem;
}

.service-item i,
.dept-list-item h5,
.text-primary {
    color: var(--primary-color) !important;
}

.service-item .card-title,
.news-item .card-title,
.doctor-item .card-title,
.department-card h2,
.department-card h5 {
    color: var(--secondary-color);
    font-weight: 900;
    letter-spacing: -0.03em;
}

.service-item .btn,
.news-item .btn {
    margin-top: auto;
}

.doctor-item {
    overflow: hidden;
    border: 0 !important;
    border-radius: 14px;
}

.doctor-item img {
    height: 300px;
    object-fit: cover;
}

.doctor-item .card-body {
    min-height: 118px;
    background: linear-gradient(135deg, #003b78, #0078b8) !important;
}

.doctor-item .card-title {
    color: white;
}

.doctor-item small {
    color: rgba(255, 255, 255, 0.75);
}

.news-item {
    overflow: hidden;
    border: 0 !important;
}

.news-item img {
    height: 255px;
    object-fit: cover;
}

.department-card {
    padding: 4rem 0;
}

.department-card img {
    width: 100%;
    max-height: 420px;
    object-fit: cover;
    border-radius: 16px !important;
    box-shadow: var(--shadow);
}

.dept-list-item {
    padding: 1.4rem;
}

.dept-list-item ul li {
    padding: 0.95rem 0;
    border-bottom: 1px solid var(--line);
}

.dept-list-item ul li:last-child {
    border-bottom: 0;
}

.dept-list-item ul li a {
    color: var(--secondary-color);
    font-weight: 800;
}

.dept-list-item .fa-arrow-right {
    display: inline-grid;
    width: 1.55rem;
    height: 1.55rem;
    place-items: center;
    color: white !important;
    background: var(--primary-color);
    border-radius: 50%;
    font-size: 0.7rem;
}

.emergency-section {
    background: #f2fbfd !important;
}

.emergency-section img {
    border-radius: 16px !important;
    box-shadow: var(--shadow);
}

/* ========================================
   TABS, MODALS, FOOTER
   ======================================== */

.nav-tabs {
    gap: 0.5rem;
    border-bottom: 1px solid var(--line);
}

.nav-tabs .nav-link {
    border: 1px solid var(--line);
    border-radius: 999px;
    background: white;
}

.nav-tabs .nav-link.active,
.nav-tabs .nav-link:hover {
    color: white !important;
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.tab-pane {
    padding: 2rem 0;
}

.pagination .page-link {
    color: var(--primary-color);
    border-color: var(--line);
    font-weight: 900;
}

.page-item.active .page-link {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.modal-content {
    border: 0;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.modal-header {
    border: 0;
    background: var(--primary-color) !important;
}

.modal-title {
    color: white;
    font-weight: 900;
}

.modal-body {
    padding: 2rem;
}

.footer {
    position: relative;
    overflow: hidden;
    margin-top: 0;
    background:
        radial-gradient(circle at 80% 30%, rgba(0, 194, 209, 0.16), transparent 18rem),
        linear-gradient(135deg, #061b2b, #003b78) !important;
}

.footer h5 {
    color: white;
    font-weight: 900;
}

.footer p,
.footer a,
.footer .text-muted {
    color: rgba(255, 255, 255, 0.72) !important;
}

.footer a:hover {
    color: white !important;
}

.footer .fab,
.social-links a {
    display: inline-grid;
    width: 2rem;
    height: 2rem;
    place-items: center;
    color: white !important;
    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 50%;
}

.footer .fab {
    width: auto;
    height: auto;
    border: 0;
}

/* ========================================
   UTILITIES AND RESPONSIVE
   ======================================== */

.bg-primary {
    background-color: var(--primary-color) !important;
}

.bg-dark {
    background-color: #061b2b !important;
}

.bg-light {
    background-color: var(--soft-2) !important;
}

.bg-teal {
    background-color: var(--primary-color) !important;
}

.text-danger {
    color: #f05d7c !important;
}

.text-success {
    color: var(--success) !important;
}

.shadow-sm {
    box-shadow: 0 12px 30px rgba(0, 59, 120, 0.08) !important;
}

.rounded-3 {
    border-radius: 16px !important;
}

[hidden],
.is-hidden {
    display: none !important;
}

.fade-in {
    animation: fadeIn 0.28s ease both;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 1199px) {
    .navbar::before,
    .navbar::after,
    .navbar .navbar-nav::after {
        display: none;
    }

    .navbar {
        min-height: 92px;
        padding-top: 0;
        align-items: center;
    }
}

@media (max-width: 991px) {
    .navbar-collapse {
        margin-top: 0.8rem;
        padding: 1rem;
        background: white;
        border: 1px solid var(--line);
        border-radius: 16px;
    }

    .navbar-nav {
        align-items: stretch;
    }

    .hero-section,
    .hero-section .row {
        min-height: auto !important;
    }

    .hero-section {
        padding: 3rem 0 0;
    }

    .hero-search {
        grid-template-columns: 1fr;
        border-radius: 20px;
        padding: 0.75rem;
    }

    .hero-visual {
        min-height: 480px;
        margin-top: 1rem;
    }

    .hero-visual img {
        max-height: 470px;
    }

    .specialty-badge {
        font-size: 0.76rem;
        padding: 0.62rem 0.8rem;
    }
}

@media (max-width: 767px) {
    .hero-content h1 {
        font-size: clamp(2.8rem, 16vw, 4.4rem);
    }

    .hero-visual {
        min-height: 390px;
    }

    .hero-visual img {
        max-height: 380px;
        width: min(92%, 380px);
    }

    .badge-cardiology {
        top: 18%;
        left: 0;
    }

    .badge-neurology {
        bottom: 17%;
        left: 0;
    }

    .badge-orthopedics {
        right: 0;
        bottom: 20%;
    }

    .about-photo img {
        height: 300px;
    }

    .hello-card img {
        width: 64%;
    }

    .doctor-item img,
    .news-item img {
        height: 240px;
    }

    .nav-tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
    }

    .nav-tabs .nav-link {
        white-space: nowrap;
    }
}

@media (max-width: 575px) {
    .navbar-brand {
        font-size: 1.12rem;
    }

    .navbar-brand img {
        width: 220px;
        height: 60px;
    }

    .hero-section {
        padding-top: 2rem;
    }

    .feature-card {
        min-height: 92px;
    }

    .about-actions {
        gap: 1rem;
    }

    .rating-card {
        position: static;
        margin: -1.2rem 1rem 0 auto;
    }
}

/* ========================================
   Reference-Inspired UI Refresh
   Keeps Crescent Logo Palette
   ======================================== */

:root {
    --primary-color: #0078b8;
    --primary-2: #00c2d1;
    --secondary-color: #003b78;
    --ink: #102235;
    --muted: #5e7282;
    --soft: #e9f8fb;
    --soft-2: #f7fcfd;
    --line: #cfe7ee;
    --shadow: 0 18px 42px rgba(0, 59, 120, 0.12);
}

body {
    background:
        linear-gradient(180deg, #f2fbfd 0%, #ffffff 26%, #f6fbff 100%);
}

.container,
.hero-section .container {
    max-width: 1160px;
}

.navbar {
    min-height: 104px;
    padding-top: 28px;
    background: rgba(255, 255, 255, 0.98) !important;
    border-bottom: 1px solid #cfe7ee;
    box-shadow: 0 10px 28px rgba(0, 59, 120, 0.08) !important;
}

.navbar::before {
    height: 28px;
    background: linear-gradient(90deg, #003b78, #0078b8 52%, #00b9c9);
    font-size: 0.74rem;
}

.navbar::after {
    height: 28px;
}

.navbar .container {
    min-height: 76px;
}

.navbar-brand img {
    width: 200px;
    height: 74px;
}

.nav-link {
    color: #2f2a35 !important;
    font-size: 0.82rem;
    padding: 0.56rem 0.78rem !important;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color) !important;
    background: #e9f8fb;
}

.hero-section {
    min-height: auto;
    padding: 2.2rem 0 3.2rem;
    background:
        linear-gradient(90deg, #f2fbfd 0%, #ffffff 54%, #e9f8fb 100%);
}

.hero-section .row {
    min-height: 520px !important;
}

.hero-content {
    max-width: 570px;
}

.hero-content h1 {
    font-size: clamp(2.55rem, 5vw, 4.4rem);
    letter-spacing: -0.045em;
}

.eyebrow {
    color: var(--primary-color);
}

.hero-search {
    border-color: #cfe7ee;
    box-shadow: 0 14px 34px rgba(0, 120, 184, 0.1);
}

.hero-visual {
    min-height: 500px;
    padding: 1.2rem;
}

.hero-visual::before {
    width: min(86%, 470px);
    background: #e9f8fb;
    border-radius: 34px;
}

.hero-visual img {
    max-height: 470px;
    width: min(100%, 500px);
    border-radius: 18px;
    box-shadow: var(--shadow);
    filter: none;
}

.specialty-badge {
    color: #102235;
    border-color: #cfe7ee;
    box-shadow: 0 12px 26px rgba(0, 120, 184, 0.12);
}

.btn-primary {
    background: linear-gradient(135deg, #00c2d1, #0078b8);
    box-shadow: 0 14px 26px rgba(0, 120, 184, 0.22);
}

.btn-primary:hover {
    background: #00649a;
    box-shadow: 0 18px 34px rgba(0, 120, 184, 0.28);
}

.features-section {
    background: #ffffff !important;
}

.feature-card,
.service-preview-card,
.card,
.dept-list-item {
    border-color: #cfe7ee !important;
    border-radius: 14px;
    box-shadow: 0 12px 28px rgba(0, 59, 120, 0.06);
}

.feature-card {
    min-height: 104px;
}

.feature-icon,
.service-preview-card i,
.recommend-list i,
.specialty-badge i,
.service-item i,
.dept-list-item h5,
.text-primary {
    color: var(--primary-color) !important;
}

.about-section,
.home-services,
.insurance-section {
    background: #f2fbfd !important;
}

.about-section h2,
.home-services h2,
.cta-section h2,
.insurance-section h2 {
    color: #003b78;
    font-size: clamp(1.9rem, 3.4vw, 2.7rem);
    letter-spacing: -0.04em;
}

.about-photo img,
.department-card img,
.emergency-section img {
    border-radius: 16px !important;
    box-shadow: var(--shadow);
}

.rating-card {
    border-color: #cfe7ee;
}

.home-services {
    background: #ffffff !important;
}

.service-preview-card {
    background: #fff;
}

.service-preview-card:hover,
.feature-card:hover,
.card:hover,
.dept-list-item:hover {
    box-shadow: 0 22px 45px rgba(0, 59, 120, 0.13) !important;
}

.cta-section {
    background:
        radial-gradient(circle at 50% 20%, rgba(0, 194, 209, 0.12), transparent 16rem),
        linear-gradient(180deg, #f3fbff 0%, #ffffff 100%) !important;
}

.recommend-list div {
    background: #f2fbfd;
    border-color: #cfe7ee;
}

.hello-card {
    background: linear-gradient(135deg, #003b78, #0078b8 60%, #00b9c9);
}

.insurance-section {
    background: #e9f8fb !important;
}

.section-heading {
    max-width: 680px;
    margin-inline: auto;
}

.section-heading h2 {
    margin-bottom: 0.5rem;
    font-weight: 900;
}

.insurance-marquee {
    position: relative;
    overflow: hidden;
    padding: 0.25rem 0;
    mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.insurance-track {
    display: flex;
    width: max-content;
    gap: 1rem;
    animation: insuranceSlide 32s linear infinite;
}

.insurance-marquee:hover .insurance-track {
    animation-play-state: paused;
}

.insurance-logo {
    width: 178px;
    min-height: 92px;
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    color: var(--secondary-color);
    background: #ffffff;
    border: 1px solid #d9ecf6;
    border-radius: 12px;
    box-shadow: 0 12px 24px rgba(22, 82, 112, 0.08);
    font-size: 1.35rem;
    font-weight: 950;
    letter-spacing: -0.03em;
}

.insurance-logo span {
    margin-left: 0.35rem;
    padding: 0.15rem 0.38rem;
    color: white;
    background: var(--primary-color);
    border-radius: 999px;
    font-size: 0.62rem;
    letter-spacing: 0;
}

.aar-logo {
    color: #0f6f9f;
}

.jubilee-logo {
    color: #d02c2f;
}

.britam-logo {
    color: #244a9b;
}

.cic-logo {
    color: #0d8b62;
}

.madison-logo {
    color: #7b2c82;
}

.apa-logo {
    color: #e36b2c;
}

.minet-logo {
    color: #00649a;
}

@keyframes insuranceSlide {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(calc(-50% - 0.5rem));
    }
}

.hero-banner {
    background:
        linear-gradient(90deg, rgba(242, 251, 253, 0.98) 0%, rgba(242, 251, 253, 0.9) 52%, rgba(242, 251, 253, 0.55) 100%),
        url("public/care-team.png") center right / cover !important;
}

.doctor-item .card-body {
    background: linear-gradient(135deg, #003b78, #0078b8) !important;
}

.nav-tabs .nav-link.active,
.nav-tabs .nav-link:hover,
.page-item.active .page-link,
.modal-header {
    background: #0078b8 !important;
    border-color: #0078b8 !important;
}

.footer {
    background:
        radial-gradient(circle at 80% 30%, rgba(0, 194, 209, 0.16), transparent 18rem),
        linear-gradient(135deg, #061b2b, #003b78) !important;
}

@media (max-width: 991px) {
    .navbar {
        min-height: 86px;
    }

    .hero-section .row {
        min-height: auto !important;
    }

    .hero-visual {
        min-height: 440px;
    }

    .insurance-logo {
        width: 160px;
    }
}

@media (max-width: 575px) {
    .navbar-brand img {
        width: 220px;
        height: 58px;
    }

    .hero-search {
        border-radius: 18px;
    }

.insurance-logo {
        width: 145px;
        min-height: 78px;
        font-size: 1.12rem;
    }
}

/* ========================================
   Homepage Hero Motion
   ======================================== */

.hero-section::after {
    content: "";
    position: absolute;
    inset: 8% auto auto 42%;
    width: min(42vw, 520px);
    aspect-ratio: 1;
    border-radius: 50%;
    background:
        radial-gradient(circle, rgba(0, 194, 209, 0.2) 0%, rgba(0, 120, 184, 0.08) 42%, transparent 70%);
    filter: blur(6px);
    opacity: 0.8;
    z-index: -1;
    animation: heroGlowDrift 14s ease-in-out infinite alternate;
}

.hero-content .eyebrow,
.hero-content h1,
.hero-content .lead,
.hero-search {
    opacity: 0;
    animation: heroCopyRise 0.8s ease forwards;
}

.hero-content .eyebrow {
    animation-delay: 0.05s;
}

.hero-content h1 {
    animation-delay: 0.18s;
}

.hero-content .lead {
    animation-delay: 0.31s;
}

.hero-search {
    animation-delay: 0.45s;
}

.hero-visual::before {
    animation: heroHaloPulse 7s ease-in-out infinite;
}

.hero-visual img {
    animation: heroDoctorFloat 6s ease-in-out infinite;
    transform-origin: center bottom;
}

.specialty-badge {
    animation: heroBadgeFloat 5.5s ease-in-out infinite;
}

.badge-cardiology {
    animation-delay: 0.2s;
}

.badge-neurology {
    animation-delay: 0.9s;
}

.badge-orthopedics {
    animation-delay: 1.5s;
}

.hero-search .btn {
    position: relative;
    overflow: hidden;
}

.hero-search .btn::after {
    content: "";
    position: absolute;
    inset: -40% auto -40% -70%;
    width: 55%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.45), transparent);
    transform: skewX(-18deg);
    animation: heroButtonShine 4.8s ease-in-out infinite;
}

@keyframes heroCopyRise {
    from {
        opacity: 0;
        transform: translateY(18px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes heroDoctorFloat {
    0%,
    100% {
        transform: translateY(0) scale(1);
    }
    50% {
        transform: translateY(-12px) scale(1.01);
    }
}

@keyframes heroBadgeFloat {
    0%,
    100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes heroHaloPulse {
    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.055);
        opacity: 0.72;
    }
}

@keyframes heroGlowDrift {
    from {
        transform: translate3d(-18px, -8px, 0) scale(0.96);
    }
    to {
        transform: translate3d(22px, 18px, 0) scale(1.05);
    }
}

@keyframes heroButtonShine {
    0%,
    58% {
        left: -70%;
    }
    78%,
    100% {
        left: 120%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hero-section::after,
    .hero-content .eyebrow,
    .hero-content h1,
    .hero-content .lead,
    .hero-search,
    .hero-visual::before,
    .hero-visual img,
    .specialty-badge,
    .hero-search .btn::after {
        animation: none !important;
    }

    .hero-content .eyebrow,
    .hero-content h1,
    .hero-content .lead,
    .hero-search {
        opacity: 1;
    }
}
