/* ============================================
   State Street Barber Shop — Custom Styles
   ============================================ */

/* Base & Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

body {
    font-feature-settings: "cv02", "cv03", "cv04", "cv11";
}

/* Selection Color */
::selection {
    background-color: #C05A3D;
    color: #FAF6F0;
}

/* ============================================
   Navbar
   ============================================ */
#navbar {
    background: transparent;
    transition: background-color 0.5s ease, box-shadow 0.5s ease, padding 0.5s ease;
}

#navbar.scrolled {
    background-color: rgba(28, 25, 23, 0.97);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05);
}

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

/* ============================================
   Hero Animations
   ============================================ */
.hero-tagline {
    animation: slideUp 0.8s ease forwards;
}

.hero-subtitle {
    animation: slideUp 0.8s ease 0.2s forwards;
    opacity: 0;
}

.hero-subtitle h1,
.hero-tagline,
.hero-subtitle {
    /* h1 is handled by overflow-hidden parent */
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   Marquee
   ============================================ */
.marquee-track {
    animation: marquee 30s linear infinite;
}

@keyframes marquee {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

/* ============================================
   Scroll Reveal (Progressive Enhancement)
   ============================================ */
@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal {
        opacity: 0;
        transform: translateY(40px);
        transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), 
                    transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    }
    
    .scroll-reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Always visible for reduced motion preference */
@media (prefers-reduced-motion: reduce) {
    .scroll-reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
}

/* ============================================
   Mobile Menu
   ============================================ */
.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.05s; }
#mobileMenu.open .mobile-link:nth-child(2) { transition-delay: 0.1s; }
#mobileMenu.open .mobile-link:nth-child(3) { transition-delay: 0.15s; }
#mobileMenu.open .mobile-link:nth-child(4) { transition-delay: 0.2s; }
#mobileMenu.open .mobile-link:nth-child(5) { transition-delay: 0.25s; }

/* Menu button animation */
#menuBtn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}

#menuBtn.active .menu-line:nth-child(2) {
    opacity: 0;
}

#menuBtn.active .menu-line:nth-child(3) {
    width: 24px;
    transform: rotate(-45deg) translate(4px, -4px);
}

/* ============================================
   Form Styles
   ============================================ */
select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2344403C' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

/* ============================================
   Focus Styles
   ============================================ */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 2px solid #C05A3D;
    outline-offset: 2px;
}

/* ============================================
   Custom Scrollbar
   ============================================ */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #FAF6F0;
}

::-webkit-scrollbar-thumb {
    background: #C05A3D;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #A84930;
}

/* ============================================
   Responsive Adjustments
   ============================================ */
@media (max-width: 767px) {
    .hero-tagline,
    .hero-subtitle {
        opacity: 1;
        transform: none;
    }
}

/* ============================================
   Print Styles
   ============================================ */
@media print {
    #navbar,
    .marquee-track,
    #contactForm {
        display: none;
    }
    
    body {
        background: white;
        color: black;
    }
}
