/* ========================================
   A-class Pharmacy — Custom Styles
   ======================================== */

/* Base */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

/* Selection */
::selection {
    background: rgba(232, 98, 63, 0.3);
    color: #f7f7f8;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #14141c;
}
::-webkit-scrollbar-thumb {
    background: #333341;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #454556;
}

/* ========================================
   Navigation
   ======================================== */
#navbar {
    background: transparent;
}

#navbar.scrolled {
    background: rgba(10, 10, 15, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(51, 51, 65, 0.5);
}

/* Mobile menu animations */
.mobile-link {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease, color 0.3s ease;
}

#mobileMenu.open .mobile-link {
    opacity: 1;
    transform: translateY(0);
}

#mobileMenu.open .mobile-link:nth-child(1) { transition-delay: 0.1s; }
#mobileMenu.open .mobile-link:nth-child(2) { transition-delay: 0.15s; }
#mobileMenu.open .mobile-link:nth-child(3) { transition-delay: 0.2s; }
#mobileMenu.open .mobile-link:nth-child(4) { transition-delay: 0.25s; }
#mobileMenu.open .mobile-link:nth-child(5) { transition-delay: 0.3s; }

/* Hamburger */
.menu-line {
    display: block;
}

#menuToggle.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(3px, 3px);
}
#menuToggle.active .menu-line:nth-child(2) {
    opacity: 0;
}
#menuToggle.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(3px, -3px);
    width: 1.25rem;
}

/* ========================================
   Hero Section
   ======================================== */
#hero {
    position: relative;
}

/* ========================================
   Service Cards
   ======================================== */
.service-card {
    transition: transform 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

/* ========================================
   Value Cards
   ======================================== */
.value-card {
    transition: transform 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}

.value-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

/* ========================================
   Form Inputs
   ======================================== */
input:focus,
textarea:focus {
    box-shadow: 0 0 0 3px rgba(232, 98, 63, 0.15);
}

/* ========================================
   Scroll Reveal Animations
   (Progressive enhancement — content visible without JS)
   ======================================== */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 1;
        transform: none;
    }
}

/* ========================================
   Responsive Adjustments
   ======================================== */
@media (max-width: 767px) {
    .font-serif {
        font-size: clamp(1.75rem, 5vw, 2.5rem);
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .service-card,
    .value-card {
        padding: 2rem;
    }
}

/* ========================================
   Focus Visible (Accessibility)
   ======================================== */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #e8623f;
    outline-offset: 2px;
    border-radius: 4px;
}

/* ========================================
   Print Styles
   ======================================== */
@media print {
    nav, #contact, footer {
        display: none;
    }
    body {
        background: white;
        color: #1e1e28;
    }
    .font-serif {
        color: #1e1e28;
    }
}
