/* ============================================
   DR. RYAN SHINGLER — WESTGATE CLINIC
   Custom Styles
   ============================================ */

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    margin: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ============================================
   HERO ANIMATIONS
   ============================================ */
.hero-anim {
    opacity: 0;
    transform: translateY(24px);
    animation: heroFadeIn 0.8s ease forwards;
}

.hero-anim:nth-child(1) { animation-delay: 0.1s; }
.hero-anim:nth-child(2) { animation-delay: 0.25s; }
.hero-anim:nth-child(3) { animation-delay: 0.4s; }
.hero-anim:nth-child(4) { animation-delay: 0.55s; }
.hero-anim:nth-child(5) { animation-delay: 0.7s; }
.hero-anim:nth-child(6) { animation-delay: 0.85s; }

@keyframes heroFadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   SCROLL REVEAL ANIMATIONS
   (Progressive enhancement — content visible without JS)
   ============================================ */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================
   NAVBAR
   ============================================ */
#navbar {
    will-change: box-shadow;
}

#navbar.scrolled {
    box-shadow: 0 1px 0 rgba(10, 22, 40, 0.08);
}

/* ============================================
   MOBILE MENU
   ============================================ */
.mobile-link {
    position: relative;
}

.mobile-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    width: 0;
    height: 1px;
    background: #d4a853;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.mobile-link:hover::after {
    width: 100%;
}

/* ============================================
   FORM STYLES
   ============================================ */
input::placeholder,
textarea::placeholder {
    color: rgba(255, 255, 255, 0.2);
}

input:focus,
textarea:focus {
    outline: none;
}

/* ============================================
   IMAGE OPTIMIZATION
   ============================================ */
img {
    max-width: 100%;
    height: auto;
}

/* ============================================
   FOCUS VISIBLE
   ============================================ */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #d4a853;
    outline-offset: 2px;
}

/* ============================================
   REDUCED MOTION
   ============================================ */
@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;
    }
    
    .reveal {
        opacity: 1;
        transform: none;
    }
    
    .hero-anim {
        opacity: 1;
        transform: none;
    }
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 767px) {
    .font-serif {
        font-size: 2rem;
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    html {
        font-size: 15px;
    }
}

@media (min-width: 1024px) {
    html {
        font-size: 16px;
    }
}

/* ============================================
   SELECTION
   ============================================ */
::selection {
    background: #d4a853;
    color: #0a1628;
}

::-moz-selection {
    background: #d4a853;
    color: #0a1628;
}

/* ============================================
   SUBTLE BACKGROUND PATTERNS
   ============================================ */
section.bg-navy-900::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(ellipse at 20% 50%, rgba(212, 168, 83, 0.06) 0%, transparent 60%);
    pointer-events: none;
}
