@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
    --ai-primary: #2563eb;
    --ai-primary-hover: #1d4ed8;
    --ai-accent: #06b6d4;
    --ai-purple: #8b5cf6;
    --ai-dark: #090d16;
    --ai-dark-nav: #0f172a;
    --ai-gray-bg: #f8fafc;
    --ai-text-main: #1e293b;
    --ai-text-muted: #64748b;
    --ai-gradient-hero: linear-gradient(135deg, #090d16 0%, #1e1b4b 50%, #090d16 100%);
    --ai-gradient-accent: linear-gradient(135deg, #2563eb 0%, #06b6d4 100%);
    --ai-gradient-pro: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 50%, #06b6d4 100%);
    --ai-shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    --ai-shadow-md: 0 10px 25px -5px rgba(37, 99, 235, 0.15);
    --ai-shadow-lg: 0 20px 35px -10px rgba(15, 23, 42, 0.22);
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Plus Jakarta Sans', sans-serif !important;
    background-color: #f8fafc !important;
    color: var(--ai-text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6, .navbar-brand {
    font-family: 'Outfit', sans-serif !important;
    letter-spacing: -0.02em;
}

/* AUTOMATIC 3D LEVITATION & SHIMMER KEYFRAMES */
@keyframes aiFloat3D {
    0% { transform: translateY(0px) rotateX(0deg); }
    50% { transform: translateY(-7px) rotateX(1deg); }
    100% { transform: translateY(0px) rotateX(0deg); }
}

@keyframes aiGlowPulse {
    0% { box-shadow: 0 0 15px rgba(6, 182, 212, 0.3); }
    50% { box-shadow: 0 0 30px rgba(37, 99, 235, 0.6); }
    100% { box-shadow: 0 0 15px rgba(6, 182, 212, 0.3); }
}

@keyframes aiShimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* TOP BAR */
.topnews {
    background: #090d16 !important;
    color: #fff !important;
    padding: 5px 0 !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 12px;
}
.ai-topbar-flex {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    height: 30px;
}
.newstab {
    background: var(--ai-gradient-accent) !important;
    color: #fff !important;
    font-weight: 700 !important;
    text-transform: uppercase;
    padding: 2px 10px !important;
    border-radius: 20px !important;
    font-size: 10px !important;
    letter-spacing: 0.5px;
    white-space: nowrap;
    animation: aiGlowPulse 4s infinite ease-in-out;
    display: flex;
    align-items: center;
    gap: 5px;
}
.ai-news-marquee-wrap {
    flex: 1;
    overflow: hidden;
    display: flex;
    align-items: center;
}
.newscontent marquee li {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #e2e8f0;
    font-size: 12px;
    font-weight: 500;
}
.newscontent marquee li a {
    color: #cbd5e1 !important;
    text-decoration: none;
}
.newscontent marquee li a:hover {
    color: #38bdf8 !important;
}

/* TOP RIGHT PORTAL BUTTONS */
.ai-top-buttons {
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}
.ai-btn-portal {
    padding: 3px 10px !important;
    border-radius: 20px !important;
    font-weight: 700 !important;
    font-size: 11px !important;
    color: #fff !important;
    text-decoration: none !important;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: all 0.25s ease !important;
}
.ai-btn-portal-patient {
    background: linear-gradient(135deg, #2563eb, #1d4ed8) !important;
}
.ai-btn-portal-patient:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.5) !important;
}
.ai-btn-portal-staff {
    background: linear-gradient(135deg, #10b981, #047857) !important;
}
.ai-btn-portal-staff:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.5) !important;
}

/* PRO HEADER & SINGLE-LINE NAVBAR SYSTEM */
header {
    background: #ffffff !important;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.06) !important;
    border-bottom: 2px solid #e2e8f0 !important;
    padding: 6px 0 !important;
    position: relative;
    z-index: 100;
}

.ai-header-single-line-flex {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
}

.logo-container {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}
.logo img {
    height: 42px !important;
    width: auto !important;
    transition: transform 0.3s ease;
}
.logo:hover img {
    transform: scale(1.04);
}

/* NAVIGATION PILLS */
.ai-nav-single-line-pills {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 5px;
    white-space: nowrap !important;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}
.ai-nav-single-line-pills::-webkit-scrollbar {
    display: none;
}

.ai-nav-pill-item {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 11px !important;
    border-radius: 20px !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    color: #334155 !important;
    text-decoration: none !important;
    transition: all 0.25s ease !important;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
}
.ai-nav-pill-item i {
    font-size: 12px;
    color: #2563eb;
    transition: color 0.2s ease;
}
.ai-nav-pill-item:hover {
    background: #eff6ff !important;
    color: var(--ai-primary) !important;
    border-color: #bfdbfe !important;
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 6px 15px rgba(37, 99, 235, 0.2);
}

.ai-nav-pill-item.active {
    background: linear-gradient(135deg, #2563eb, #06b6d4) !important;
    color: #ffffff !important;
    border-color: #2563eb !important;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.35) !important;
}
.ai-nav-pill-item.active i {
    color: #ffffff !important;
}

.btn-ai-modal-trigger {
    background: var(--ai-gradient-pro) !important;
    color: #fff !important;
    font-weight: 700 !important;
    font-size: 11px !important;
    padding: 4px 12px !important;
    border-radius: 20px !important;
    border: none !important;
    animation: aiGlowPulse 3s infinite ease-in-out;
    transition: all 0.3s ease !important;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    white-space: nowrap;
}
.btn-ai-modal-trigger:hover {
    transform: translateY(-2px) scale(1.05);
}

/* HERO & 3D QUICK CARDS */
.ai-hero-banner {
    background: var(--ai-gradient-hero);
    color: #fff;
    padding: 65px 0 55px 0;
    position: relative;
    overflow: hidden;
}
.ai-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 5px 16px;
    border-radius: 30px;
    font-size: 12px;
    font-weight: 600;
    color: #38bdf8;
    margin-bottom: 18px;
    animation: aiFloat3D 5s infinite ease-in-out;
}
.ai-hero-title {
    font-size: 42px;
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 16px;
    color: #fff;
}
.ai-hero-title span {
    background: linear-gradient(135deg, #38bdf8 0%, #818cf8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.ai-hero-subtitle {
    font-size: 15px;
    color: #94a3b8;
    max-width: 600px;
    margin-bottom: 25px;
}

/* 3D CARDS GRID WITH AUTOMATIC FLOAT & TILT */
.ai-quick-cards-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
    margin-top: -35px;
    position: relative;
    z-index: 20;
    perspective: 1000px;
}
.ai-action-card {
    background: #ffffff;
    border-radius: 18px;
    padding: 24px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    border: 1px solid #e2e8f0;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
    transform-style: preserve-3d;
}
.ai-action-card:nth-child(1) { animation: aiFloat3D 6s infinite ease-in-out 0s; }
.ai-action-card:nth-child(2) { animation: aiFloat3D 6s infinite ease-in-out 1.5s; }
.ai-action-card:nth-child(3) { animation: aiFloat3D 6s infinite ease-in-out 3s; }
.ai-action-card:nth-child(4) { animation: aiFloat3D 6s infinite ease-in-out 4.5s; }

.ai-action-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--ai-gradient-accent);
}
.ai-action-card:hover {
    transform: translateY(-10px) rotateX(4deg) rotateY(-2deg) scale(1.03) !important;
    box-shadow: 0 20px 40px rgba(37, 99, 235, 0.2) !important;
    border-color: var(--ai-accent);
}
.ai-card-icon {
    width: 50px;
    height: 50px;
    border-radius: 14px;
    background: #eff6ff;
    color: var(--ai-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-bottom: 16px;
    transition: all 0.3s ease;
    transform: translateZ(10px);
}
.ai-action-card:hover .ai-card-icon {
    background: var(--ai-gradient-accent);
    color: #fff;
    transform: translateZ(20px) scale(1.15);
}
.ai-card-title {
    font-size: 17px;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 6px;
}
.ai-card-desc {
    font-size: 13px;
    color: var(--ai-text-muted);
    margin-bottom: 14px;
    line-height: 1.6;
}
.ai-card-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 700;
    color: var(--ai-primary);
    text-decoration: none;
    transition: gap 0.2s ease;
}
.ai-card-btn:hover {
    gap: 10px;
}

/* FOOTER */
footer {
    background: #090d16 !important;
    color: #94a3b8 !important;
    padding-top: 55px !important;
    border-top: 3px solid var(--ai-primary);
}
footer h3.fo-title {
    color: #fff !important;
    font-weight: 700 !important;
    font-size: 17px !important;
    margin-bottom: 18px !important;
}

/* FIX FOOTER MENU OVERLAP & LAYOUT */
footer .f1-list {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

footer .f1-list li {
    width: 100% !important;
    float: none !important;
    display: block !important;
    padding: 0 !important;
    margin-bottom: 10px !important;
    position: static !important;
}

footer .f1-list li a {
    color: #cbd5e1 !important;
    text-decoration: none !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    font-size: 13.5px !important;
    font-weight: 500 !important;
    transition: all 0.2s ease !important;
}

footer .f1-list li a:hover {
    color: #38bdf8 !important;
    transform: translateX(4px);
}

footer a {
    color: #cbd5e1 !important;
    transition: all 0.2s ease;
}
footer a:hover {
    color: #38bdf8 !important;
}
.copy-right {
    background: #04070d !important;
    padding: 16px 0 !important;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* ========================================================== */
/* ULTRA-MODERN DYNAMIC HOMEPAGE & FEATURE CARDS ENHANCEMENT */
/* ========================================================== */

/* BROKEN FA5 ICON FALLBACKS IN FA4 */
i.fa-brain::before, i.fa-robot::before, i.fa-microchip::before, i.fa-headset::before, i.fa-atom::before {
    font-family: 'FontAwesome' !important;
}
i.fa-brain::before { content: "\f080" !important; } /* fa-bar-chart */
i.fa-robot::before { content: "\f085" !important; } /* fa-cogs */
i.fa-microchip::before { content: "\f1e6" !important; } /* fa-plug */
i.fa-headset::before { content: "\f095" !important; } /* fa-phone */

/* ANIMATED PULSE & LEVITATION KEYFRAMES */
@keyframes aiPulseGreen {
    0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4); }
    70% { box-shadow: 0 0 0 10px rgba(16, 185, 129, 0); }
    100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

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

/* TOP PILL BADGE */
[class*="badge"], [style*="YOUR HOSPITAL MEDICAL RESEARCH"] {
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    background: linear-gradient(135deg, #eff6ff 0%, #e0f2fe 100%) !important;
    border: 1px solid #bfdbfe !important;
    color: #2563eb !important;
    font-weight: 700 !important;
    font-size: 11.5px !important;
    letter-spacing: 0.6px !important;
    text-transform: uppercase !important;
    padding: 6px 16px !important;
    border-radius: 30px !important;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.08) !important;
    transition: all 0.3s ease !important;
}
[class*="badge"]:hover, [style*="YOUR HOSPITAL MEDICAL RESEARCH"]:hover {
    transform: translateY(-2px) scale(1.02) !important;
    box-shadow: 0 6px 18px rgba(37, 99, 235, 0.18) !important;
}

/* SECTION TITLES & TEXT */
.container h1, .container h2, .container h3 {
    font-family: 'Outfit', sans-serif !important;
    font-weight: 800 !important;
    color: #0f172a !important;
    letter-spacing: -0.03em !important;
    line-height: 1.25 !important;
}

/* DYNAMIC 3D FEATURE CARDS (100% Cashless & AI Diagnostics) */
[style*="100% Cashless"], [style*="AI Diagnostics"], [class*="card"] {
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1) !important;
    border-radius: 18px !important;
    background: #ffffff !important;
    box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.07), 0 4px 6px -2px rgba(15, 23, 42, 0.03) !important;
    position: relative !important;
    overflow: hidden !important;
}

[style*="100% Cashless"]:hover, [style*="AI Diagnostics"]:hover {
    transform: translateY(-8px) scale(1.025) !important;
    box-shadow: 0 20px 40px -10px rgba(37, 99, 235, 0.2), 0 8px 16px -4px rgba(37, 99, 235, 0.1) !important;
    border-color: #2563eb !important;
}

/* DOCTOR / FEATURED IMAGE CONTAINER WITH 3D HOVER TILT */
.img-responsive, [style*="border-radius"][style*="box-shadow"], div:has(> img) {
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

/* FLOATING DARK BADGE OVER IMAGE */
[style*="Your Hospital Super Specialty Wing"], [style*="4.9/5 Rating"] {
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35) !important;
    border-radius: 16px !important;
    transition: all 0.3s ease !important;
}

[style*="4.9/5 Rating"] {
    animation: aiPulseGreen 3s infinite ease-in-out !important;
}

/* ========================================================== */
/* COMPREHENSIVE RESPONSIVE MEDIA QUERIES FOR TABLET & MOBILE */
/* ========================================================== */

/* TABLET SCREENS (768px - 1024px) */
@media (max-width: 1024px) {
    .ai-quick-cards-grid {
        grid-template-columns: repeat(2, 1fr);
        margin-top: -20px;
    }
    .ai-hero-title {
        font-size: 34px;
    }
    .logo img {
        height: 38px !important;
    }
}

/* MOBILE PHONES (< 768px) */
@media (max-width: 767px) {
    .topnews {
        padding: 4px 0 !important;
    }
    .ai-topbar-flex {
        flex-direction: column;
        height: auto;
        gap: 6px;
        align-items: flex-start;
    }
    .ai-top-buttons {
        width: 100%;
        justify-content: space-between;
    }
    .ai-header-single-line-flex {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    .ai-nav-single-line-pills {
        width: 100%;
        justify-content: flex-start;
        padding-bottom: 4px;
    }
    .ai-hero-banner {
        padding: 35px 0 30px 0;
        text-align: center;
    }
    .ai-hero-title {
        font-size: 26px;
        line-height: 1.25;
    }
    .ai-hero-subtitle {
        font-size: 13px;
        margin: 0 auto 20px auto;
    }
    .ai-quick-cards-grid {
        grid-template-columns: 1fr;
        gap: 14px;
        margin-top: 15px;
    }
    .stat-number {
        font-size: 26px;
    }
    .stat-label {
        font-size: 11px;
    }
}
