/* ========================================
   DR. SHO BHANA MD — Custom Styles
   ======================================== */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
    background: #2a3f6b;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #0f172a;
}

/* Selection color */
::selection {
    background: #34d399;
    color: #0f172a;
}

/* ========================================
   NAVBAR
   ======================================== */
#navbar {
    transition: background-color 0.4s ease, box-shadow 0.4s ease, padding 0.4s ease;
}

#navbar.scrolled {
    background-color: rgba(255, 255, 255, 0.97);
    box-shadow: 0 1px 20px rgba(15, 23, 42, 0.08);
    backdrop-filter: blur(12px);
}

#navbar.scrolled .nav-link {
    color: #1e2d4a;
}

#navbar.scrolled .nav-link:hover {
    color: #059669;
    background-color: #f0fdf7;
}

#navbar.scrolled .font-display,
#navbar.scrolled .font-sans {
    color: #0f172a;
}

#navbar.scrolled span {
    color: #475569;
}

/* ========================================
   FLOATING CARDS (HERO)
   ======================================== */
.floating-card {
    animation: float 6s ease-in-out infinite;
}

.floating-card:nth-child(2) {
    animation-delay: -2s;
    animation-duration: 5s;
}

.floating-card:nth-child(3) {
    animation-delay: -4s;
    animation-duration: 7s;
}

.floating-card:nth-child(4) {
    animation-delay: -1s;
    animation-duration: 5.5s;
}

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

/* ========================================
   SERVICE CARDS
   ======================================== */
.service-card {
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #34d399, #0ea5e9);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.service-card:hover::before {
    transform: scaleX(1);
}

/* ========================================
   BACK TO TOP
   ======================================== */
.back-to-top {
    transition: opacity 0.3s ease, transform 0.3s ease, background-color 0.3s ease;
}

.back-to-top.visible {
    opacity: 1;
    pointer-events: auto;
}

.back-to-top:hover {
    transform: translateY(-2px);
}

/* ========================================
   MOBILE MENU
   ======================================== */
.mobile-link {
    transition: background-color 0.2s ease, color 0.2s ease;
}

/* ========================================
   SCROLL REVEAL ANIMATIONS
   (Progressive enhancement — content visible without JS)
   ======================================== */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 1;
        transform: translateY(0);
        transition: opacity 0.7s ease, transform 0.7s ease;
    }
    
    .reveal.from-left {
        transform: translateX(0);
    }
    
    .reveal.from-right {
        transform: translateX(0);
    }
}

/* ========================================
   RESPONSIVE TWEAKS
   ======================================== */
@media (max-width: 640px) {
    .floating-card {
        display: none;
    }
}

/* ========================================
   ACCESSIBILITY
   ======================================== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* Focus visible styles */
:focus-visible {
    outline: 2px solid #34d399;
    outline-offset: 2px;
}

/* ========================================
   FORM STYLES
   ======================================== */
input:focus,
textarea:focus {
    box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.15);
}
