/* StarPath Diagnostics & Pathology Software - Core Stylesheet */
/* Color Palette Harmonized with Star Diagnostic Centre Logo:
   - Primary: #002a6d (Star Navy Blue - dominant logo text & star core)
   - Secondary: #059669 (Diagnostic Emerald Green - from 'Diagnostic Centre' & medical cross)
   - Accent Cyan: #00a8e8 (Star Cyan - glowing star outer contour)
   - Dark Star Navy: #00122e (Midnight Star Navy - topbar & dark contrast backgrounds)
*/
:root {
    --sp-primary: #002a6d;
    --sp-primary-dark: #001c4a;
    --sp-primary-light: #e6eef9;
    --sp-secondary: #059669;
    --sp-secondary-hover: #047857;
    --sp-accent-cyan: #00a8e8;
    --sp-dark: #00122e;
    --sp-slate: #334155;
    --sp-light: #f8fafc;
    --sp-border: #e2e8f0;
    --sp-card-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.08), 0 1px 2px -1px rgb(0 0 0 / 0.05);

    /* Bootstrap 5 Theme Overrides */
    --bs-primary: #002a6d;
    --bs-primary-rgb: 0, 42, 109;
    --bs-secondary: #059669;
    --bs-secondary-rgb: 5, 150, 105;
    --bs-link-color: #002a6d;
    --bs-link-hover-color: #059669;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #1e293b;
    background-color: #f8fafc;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
    color: var(--sp-dark);
    font-weight: 600;
    letter-spacing: -0.02em;
}

.page-title {
    font-size: 1.35rem;
    font-weight: 600;
    margin-bottom: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Global Bootstrap Utility Overrides for Star Theme */
.text-primary {
    color: #002a6d !important;
}

.text-success {
    color: #059669 !important;
}

.bg-primary {
    background-color: #002a6d !important;
}

.bg-primary-subtle {
    background-color: #e6eef9 !important;
    color: #002a6d !important;
}

.border-primary {
    border-color: #002a6d !important;
}

.btn-primary {
    background-color: #002a6d !important;
    border-color: #002a6d !important;
    color: #ffffff !important;
    font-weight: 500;
    transition: all 0.2s ease-in-out;
}

.btn-primary:hover, .btn-primary:focus, .btn-primary:active {
    background-color: #001c4a !important;
    border-color: #001c4a !important;
    color: #ffffff !important;
    box-shadow: 0 4px 12px rgba(0, 42, 109, 0.28);
}

.btn-outline-primary {
    color: #002a6d !important;
    border-color: #002a6d !important;
    font-weight: 500;
    transition: all 0.2s ease-in-out;
}

.btn-outline-primary:hover, .btn-outline-primary:focus, .btn-outline-primary:active {
    background-color: #002a6d !important;
    border-color: #002a6d !important;
    color: #ffffff !important;
    box-shadow: 0 4px 12px rgba(0, 42, 109, 0.22);
}

.btn-success {
    background-color: #059669 !important;
    border-color: #059669 !important;
}

.btn-success:hover {
    background-color: #047857 !important;
    border-color: #047857 !important;
}

/* Medical Hero Slider Banner (Increased Height & Star Palette) */
.medical-hero-slider {
    position: relative;
    overflow: hidden;
    background: #00122e;
    box-shadow: 0 6px 18px rgba(0, 18, 46, 0.16);
}

.medical-hero-slider .carousel-item {
    background-color: #00122e;
    text-align: center;
}

.medical-hero-slider .banner-slide-img {
    width: 100%;
    height: 520px;
    max-height: 580px;
    object-fit: cover;
    display: block;
    margin: 0 auto;
}

@media (min-width: 1400px) {
    .medical-hero-slider .banner-slide-img {
        height: 560px;
        max-height: 600px;
    }
}

@media (max-width: 991.98px) {
    .medical-hero-slider .banner-slide-img {
        height: 380px;
        max-height: 420px;
    }
}

@media (max-width: 767.98px) {
    .medical-hero-slider .banner-slide-img {
        min-height: 240px;
        height: 280px;
        max-height: 300px;
        object-fit: cover;
    }
}

.medical-hero-slider .carousel-indicators {
    margin-bottom: 1.1rem;
    z-index: 4;
}

.medical-hero-slider .carousel-indicators [data-bs-target] {
    width: 28px;
    height: 6px;
    border-radius: 4px;
    background-color: rgba(255, 255, 255, 0.45);
    border: none;
    transition: all 0.25s ease-in-out;
}

.medical-hero-slider .carousel-indicators .active {
    width: 52px;
    background-color: #00a8e8;
}

.medical-hero-slider .carousel-control-prev,
.medical-hero-slider .carousel-control-next {
    width: 6%;
    z-index: 4;
    opacity: 0.85;
}

.medical-hero-slider .carousel-control-prev-icon,
.medical-hero-slider .carousel-control-next-icon {
    width: 2.8rem;
    height: 2.8rem;
    background-color: rgba(0, 18, 46, 0.75);
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 50%;
    background-size: 45%;
    backdrop-filter: blur(4px);
    transition: all 0.2s;
}

.medical-hero-slider .carousel-control-prev:hover .carousel-control-prev-icon,
.medical-hero-slider .carousel-control-next:hover .carousel-control-next-icon {
    background-color: #002a6d;
    border-color: #00a8e8;
    transform: scale(1.08);
}

.quick-booking-card {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 10px 25px -5px rgba(0, 42, 109, 0.08), 0 8px 10px -6px rgba(0, 42, 109, 0.04);
    border: 1px solid #e2e8f0;
}

/* Star Theme Topbar & Navbar */
.top-contact-bar {
    background: #00122e;
    color: #cbd5e1;
    font-size: 0.85rem;
    padding: 6px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.top-contact-bar a {
    color: #cbd5e1;
    text-decoration: none;
    transition: color 0.15s ease;
}

.top-contact-bar a:hover {
    color: #38bdf8;
}

.navbar-starpath {
    background: #ffffff;
    border-bottom: 1px solid var(--sp-border);
    box-shadow: 0 2px 4px rgba(0, 42, 109, 0.04);
    padding: 0.5rem 0;
}

.header-logo-img {
    height: 64px;
    max-height: 72px;
    width: auto;
    object-fit: contain;
    display: block;
}

@media (max-width: 768px) {
    .header-logo-img {
        height: 52px;
        max-height: 58px;
    }
}

.footer-logo-img {
    height: 64px;
    max-height: 72px;
    width: auto;
    object-fit: contain;
    display: block;
}

.navbar-starpath .navbar-brand {
    font-weight: 700;
    font-size: 1.25rem;
    color: #002a6d;
    letter-spacing: -0.01em;
    padding-top: 0;
    padding-bottom: 0;
}

.navbar-starpath .nav-link {
    font-size: 0.95rem;
    font-weight: 500;
    color: #334155;
    padding: 0.5rem 0.85rem !important;
    transition: color 0.15s ease;
}

.navbar-starpath .nav-link:hover {
    color: #059669;
}

.navbar-starpath .nav-link.active {
    color: #002a6d;
    font-weight: 600;
}

/* Cards & Surfaces - Animated Attractive Hover */
.card {
    border: 1px solid var(--sp-border);
    border-radius: 10px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 2px rgba(0, 0, 0, 0.03);
    background-color: #ffffff;
    transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), 
                box-shadow 0.28s cubic-bezier(0.16, 1, 0.3, 1), 
                border-color 0.28s ease;
    position: relative;
}

.card:hover {
    box-shadow: 0 10px 24px -4px rgba(0, 42, 109, 0.14), 0 4px 8px -2px rgba(0, 0, 0, 0.04);
    border-color: #93b4e6;
}

.card-header {
    background-color: #ffffff;
    border-bottom: 1px solid var(--sp-border);
    font-weight: 600;
    padding: 0.85rem 1.25rem;
}

/* Feature Highlight Cards (Homepage Top Banner Grid) */
.feature-highlight-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.25rem 1rem;
    text-align: center;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    cursor: default;
}

.feature-highlight-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 32px -6px rgba(0, 42, 109, 0.18), 0 6px 12px -2px rgba(0, 0, 0, 0.05);
    border-color: #00a8e8;
}

.feature-highlight-card i {
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), color 0.25s ease;
    display: inline-block;
}

.feature-highlight-card:hover i {
    transform: scale(1.22) translateY(-3px);
}

/* Service Package Cards */
.service-package-card {
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
}

.service-package-card:hover {
    transform: translateY(-7px);
    box-shadow: 0 18px 36px -8px rgba(0, 42, 109, 0.18), 0 8px 16px -4px rgba(0, 0, 0, 0.05);
    border-color: #002a6d;
}

.service-package-card .btn-outline-secondary {
    transition: all 0.25s ease;
}

.service-package-card:hover .btn-outline-secondary {
    background-color: #002a6d;
    border-color: #002a6d;
    color: #ffffff;
    transform: scale(1.03);
}

/* Info Box / Content Cards */
.info-box-card {
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

.info-box-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 14px 28px -6px rgba(0, 42, 109, 0.14), 0 6px 10px -3px rgba(0, 0, 0, 0.04);
    border-color: #059669;
}

/* Forms */
.form-label {
    font-weight: 500;
    font-size: 0.875rem;
    color: #334155;
    margin-bottom: 0.35rem;
}

.form-control, .form-select {
    border-color: #cbd5e1;
    border-radius: 6px;
    font-size: 0.9rem;
    padding: 0.55rem 0.85rem;
}

.form-control:focus, .form-select:focus {
    border-color: #002a6d;
    box-shadow: 0 0 0 3px rgba(0, 42, 109, 0.15);
}

/* DataTables Styling Overrides */
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter {
    margin-bottom: 0.85rem;
    font-size: 0.875rem;
}

.dataTables_wrapper .dataTables_filter input {
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 0.35rem 0.65rem;
    margin-left: 0.5rem;
}

.dataTables_wrapper .dataTables_filter input:focus {
    border-color: #002a6d;
    outline: none;
    box-shadow: 0 0 0 2px rgba(0, 42, 109, 0.15);
}

.table > :not(caption) > * > * {
    padding: 0.75rem 0.85rem;
}

.table thead th {
    font-size: 0.825rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    font-weight: 600;
    color: #475569;
    background-color: #f8fafc;
    border-bottom: 2px solid #e2e8f0;
}

/* Table Responsive Wrapper & Touch Scroll */
.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    width: 100%;
    margin-bottom: 0.5rem;
}

@media (max-width: 767.98px) {
    .dataTables_wrapper .dataTables_length,
    .dataTables_wrapper .dataTables_filter {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
        margin-bottom: 0.5rem;
    }
    .dataTables_wrapper .dataTables_filter input {
        width: 100% !important;
        margin-left: 0 !important;
        margin-top: 0.25rem;
    }
    .dataTables_wrapper .dataTables_info,
    .dataTables_wrapper .dataTables_paginate {
        display: flex;
        justify-content: center;
        width: 100%;
        margin-top: 0.5rem;
    }
}

/* Badges */
.badge-status-completed {
    background-color: #dcfce7;
    color: #166534;
}
.badge-status-pending {
    background-color: #fef3c7;
    color: #92400e;
}
.badge-status-inprogress {
    background-color: #e0f2fe;
    color: #075985;
}

/* Admin Top Navbar */
.navbar-dark.bg-dark {
    background-color: #00122e !important;
    border-bottom: 1px solid #002052 !important;
}

/* Admin Sidebar & Layout (Rich Star Navy & Emerald Highlights) */
.admin-sidebar {
    width: 250px;
    background: #00122e !important;
    color: #ffffff !important;
    border-right: 1px solid #002052;
    z-index: 1045;
}

@media (min-width: 992px) {
    .admin-sidebar {
        min-height: calc(100vh - 56px);
    }
}

.sidebar-section-title {
    color: #ffffff !important;
    font-weight: 700 !important;
    font-size: 0.74rem !important;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 0.6rem 1.1rem 0.25rem 1.1rem;
    opacity: 0.95;
}

.admin-sidebar .nav-link {
    color: #ffffff !important;
    font-weight: 600 !important;
    font-size: 0.9rem;
    padding: 0.65rem 1rem;
    border-radius: 6px;
    margin: 2px 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: background-color 0.15s ease-in-out;
}

.admin-sidebar .nav-link i {
    color: #00a8e8 !important;
    font-size: 1.05rem;
}

.admin-sidebar .nav-link:hover {
    background: #002257 !important;
    color: #ffffff !important;
}

.admin-sidebar .nav-link.active {
    background: #002a6d !important;
    color: #ffffff !important;
    font-weight: 700 !important;
    box-shadow: 0 2px 6px rgba(0, 42, 109, 0.45);
    border-left: 3px solid #059669;
}

.admin-sidebar .nav-link.active i {
    color: #ffffff !important;
}

.admin-sidebar .nav-link-logout {
    color: #fca5a5 !important;
    font-weight: 700 !important;
    margin-top: 0.5rem;
}

.admin-sidebar .nav-link-logout:hover {
    background: #450a0a !important;
    color: #ffffff !important;
}

.admin-sidebar .nav-link-logout i {
    color: #fca5a5 !important;
}

.admin-content {
    flex: 1;
    min-width: 0;
    max-width: 100%;
    width: 100%;
    background: #f8fafc;
    padding: 0.85rem;
    overflow-x: hidden;
}

@media (min-width: 768px) {
    .admin-content {
        padding: 1.5rem;
    }
}

/* Report Print Styling */
@media print {
    body {
        background: #ffffff !important;
        font-size: 12pt;
    }
    .no-print {
        display: none !important;
    }
    .report-sheet {
        border: none !important;
        box-shadow: none !important;
        padding: 0 !important;
    }
}

.report-sheet {
    background: #ffffff;
    max-width: 820px;
    margin: 0 auto;
    padding: 30px;
    border: 1px solid var(--sp-border);
    border-radius: 6px;
}

/* Laboratory Gallery Grid & Card Styling */
.gallery-card {
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid #e2e8f0;
    background: #ffffff;
}

.gallery-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px -6px rgba(0, 42, 109, 0.15);
    border-color: #002a6d;
}

.gallery-card .gallery-img-wrap {
    height: 220px;
    background: #00122e;
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.gallery-card .gallery-img-wrap img {
    transition: transform 0.35s ease;
}

.gallery-card:hover .gallery-img-wrap img {
    transform: scale(1.05);
}

.gallery-card .gallery-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 18, 46, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.gallery-card:hover .gallery-overlay {
    opacity: 1;
}

/* Dashboard KPI Stat Cards */
.kpi-stat-card {
    transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), 
                box-shadow 0.28s cubic-bezier(0.16, 1, 0.3, 1), 
                border-color 0.25s ease;
    border-radius: 10px;
}

.kpi-stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px -4px rgba(0, 42, 109, 0.16);
    border-color: #00a8e8 !important;
}

/* Custom Medical Pagination Styling */
.pagination {
    gap: 4px;
}

.pagination .page-link {
    border-radius: 6px !important;
    border: 1px solid #e2e8f0;
    color: #002a6d;
    font-weight: 500;
    padding: 0.38rem 0.75rem;
    transition: all 0.2s ease;
}

.pagination .page-link:hover {
    background-color: #e6eef9;
    border-color: #00a8e8;
    color: #002a6d;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 42, 109, 0.1);
}

.pagination .page-item.active .page-link {
    background-color: #002a6d;
    border-color: #002a6d;
    color: #ffffff;
    font-weight: 700;
    box-shadow: 0 4px 10px rgba(0, 42, 109, 0.25);
}

.pagination .page-item.disabled .page-link {
    color: #94a3b8;
    background-color: #f8fafc;
    border-color: #f1f5f9;
}

/* Star Brand Footer (Themed with Star Navy Logo Colors) */
.star-footer {
    background-color: #00122e !important;
    color: #cbd5e1;
    border-top: 3px solid #002a6d;
}

.star-footer h6, .star-footer h5 {
    color: #ffffff !important;
    letter-spacing: -0.01em;
}

.star-footer p, .star-footer .footer-text {
    color: #94a3b8;
}

.star-footer a {
    color: #cbd5e1;
    text-decoration: none;
    transition: all 0.2s ease;
}

.star-footer a:hover {
    color: #38bdf8 !important;
}

.star-footer .footer-logo-badge {
    background: #ffffff;
    padding: 8px 16px;
    border-radius: 8px;
    display: inline-block;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
}

.star-footer .footer-bottom-bar {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #94a3b8;
}

.star-footer .footer-bottom-bar a {
    color: #cbd5e1;
}

.star-footer .footer-bottom-bar a:hover {
    color: #38bdf8;
}

/* Internal Pages Top Banner */
.page-top-banner {
    position: relative;
    background: linear-gradient(135deg, #00122e 0%, #001a4e 45%, #002a6d 100%);
    padding: 3.25rem 0;
    overflow: hidden;
    border-bottom: 3px solid #002a6d;
    box-shadow: 0 4px 20px rgba(0, 18, 46, 0.2);
}

.page-top-banner::before {
    content: "";
    position: absolute;
    top: -50%;
    right: -10%;
    width: 480px;
    height: 480px;
    background: radial-gradient(circle, rgba(0, 168, 232, 0.18) 0%, rgba(0, 168, 232, 0) 70%);
    border-radius: 50%;
    pointer-events: none;
}

.page-top-banner::after {
    content: "";
    position: absolute;
    bottom: -60%;
    left: 5%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(5, 150, 105, 0.15) 0%, rgba(5, 150, 105, 0) 70%);
    border-radius: 50%;
    pointer-events: none;
}

.page-top-banner .banner-breadcrumb {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 50rem;
    padding: 0.45rem 1.15rem;
    display: inline-flex;
}

.page-top-banner .banner-breadcrumb a {
    color: #e2e8f0;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.875rem;
    transition: color 0.2s ease;
}

.page-top-banner .banner-breadcrumb a:hover {
    color: #38bdf8 !important;
}

.page-top-banner .banner-breadcrumb .breadcrumb-item + .breadcrumb-item::before {
    color: rgba(255, 255, 255, 0.45);
}

.page-top-banner .banner-breadcrumb .breadcrumb-item.active {
    color: #38bdf8;
    font-weight: 600;
    font-size: 0.875rem;
}


