/* ========================================
   Sandy's Barber Shop — Custom Styles
   ======================================== */

/* Base & Reset */
*, *::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-color: rgba(196, 144, 42, 0.2);
    color: #0a192f;
}

/* ========================================
   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);
    backdrop-filter: blur(20px);
    box-shadow: 0 1px 30px rgba(10, 25, 47, 0.08);
}

#navbar.scrolled .font-serif {
    color: #0a192f !important;
}

#navbar.scrolled .menu-line {
    background-color: #0a192f !important;
}

#navbar.scrolled a:not(.px-10) {
    color: #1a3a6b !important;
}

#navbar.scrolled a:not(.px-10):hover {
    color: #c4902a !important;
}

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

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

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

/* Hamburger Animation */
.menu-active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

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

.menu-active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(3px, -3px);
    width: 1.5rem;
}

/* ========================================
   Service Cards
   ======================================== */
.service-card {
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #c4902a, #f2e0a0, #c4902a);
    opacity: 0;
    transition: opacity 0.5s ease;
}

.service-card:hover::before {
    opacity: 1;
}

/* ========================================
   Gallery
   ======================================== */
.gallery-item {
    position: relative;
}

/* ========================================
   Testimonial Cards
   ======================================== */
.testimonial-card {
    position: relative;
}

.testimonial-card::after {
    content: '"';
    position: absolute;
    top: -10px;
    right: 24px;
    font-family: 'Playfair Display', serif;
    font-size: 8rem;
    color: rgba(196, 144, 42, 0.06);
    line-height: 1;
    pointer-events: none;
}

/* ========================================
   Scroll Reveal Animations
   (Progressive Enhancement — content visible without JS)
   ======================================== */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 1;
        transform: translateY(0);
        transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), 
                    transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    }

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

    .reveal-delay-1 { transition-delay: 0.1s; }
    .reveal-delay-2 { transition-delay: 0.2s; }
    .reveal-delay-3 { transition-delay: 0.3s; }
    .reveal-delay-4 { transition-delay: 0.4s; }
    .reveal-delay-5 { transition-delay: 0.5s; }
}

/* ========================================
   Form Styles
   ======================================== */
input:focus,
textarea:focus {
    outline: none;
}

input::placeholder,
textarea::placeholder {
    color: #94a3b8;
}

/* ========================================
   Smooth Scroll Offset for Anchors
   ======================================== */
section[id] {
    scroll-margin-top: 80px;
}

/* ========================================
   Responsive Adjustments
   ======================================== */
@media (max-width: 768px) {
    #hero h1 {
        font-size: 2.75rem;
    }

    .service-card {
        padding: 1.5rem;
    }

    .testimonial-card {
        padding: 1.5rem;
    }

    .testimonial-card::after {
        font-size: 5rem;
        right: 16px;
        top: -5px;
    }
}

@media (max-width: 480px) {
    #hero h1 {
        font-size: 2.25rem;
    }

    .grid-cols-2.gap-6 > * {
        gap: 1rem;
    }
}

/* ========================================
   Print Styles
   ======================================== */
@media print {
    #navbar,
    #contactForm,
    .reveal {
        display: none !important;
    }

    body {
        color: #000;
        background: #fff;
    }
}
