/* ========================================
   Brite Smile Dental — Custom Styles
   Classic & Elegant · Navy + Gold
   ======================================== */

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    min-height: 100vh;
    overflow-x: hidden;
}

::selection {
    background-color: #c9a84c;
    color: #1b2a4a;
}

/* --- Scrollbar --- */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f0f3f9;
}
::-webkit-scrollbar-thumb {
    background: #c9a84c;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #b08d30;
}

/* --- Animations --- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in-up {
    animation-name: fadeInUp;
    animation-duration: 0.7s;
    animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
    animation-fill-mode: both;
}

@keyframes scrollLine {
    0% {
        opacity: 0;
        transform: scaleY(0);
        transform-origin: top;
    }
    50% {
        opacity: 1;
        transform: scaleY(1);
        transform-origin: top;
    }
    51% {
        transform-origin: bottom;
    }
    100% {
        opacity: 0;
        transform: scaleY(0);
        transform-origin: bottom;
    }
}

.animate-scroll-line {
    animation: scrollLine 1.8s ease-in-out infinite;
}

/* --- Scroll Reveal --- */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .animate-fade-in-up {
        animation: none;
        opacity: 1;
        transform: none;
    }
    .reveal {
        transition: none;
        opacity: 1;
        transform: none;
    }
    .animate-scroll-line {
        animation: none;
        opacity: 0.5;
    }
    html {
        scroll-behavior: auto;
    }
}

/* --- Navigation --- */
.nav-link-text {
    /* Initial state for light nav */
    color: #1b2a4a;
}

#site-header.scrolled .nav-link-text {
    color: #1b2a4a;
}

#site-header.scrolled {
    background-color: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(27, 42, 74, 0.08), 0 4px 20px rgba(27, 42, 74, 0.06);
}

#site-header.scrolled .nav-link-text {
    color: #1b2a4a;
}

#site-header.scrolled .font-serif,
#site-header.scrolled .block.font-sans {
    color: #1b2a4a;
}

/* --- Mobile Menu --- */
#mobile-menu.open {
    transform: translateX(0);
}

.mobile-nav-link {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.3s ease, transform 0.3s ease, color 0.3s ease;
}

#menu-toggle[aria-expanded="true"] #bar1 {
    transform: rotate(45deg) translate(4px, 4px);
}
#menu-toggle[aria-expanded="true"] #bar2 {
    opacity: 0;
}
#menu-toggle[aria-expanded="true"] #bar3 {
    transform: rotate(-45deg) translate(4px, -4px);
}

/* --- Form Focus States --- */
input:focus,
textarea:focus {
    outline: none;
}

/* --- Print --- */
@media print {
    #site-header, #mobile-menu, .animate-scroll-line {
        display: none !important;
    }
    body {
        color: #000;
        background: #fff;
    }
}
