/* ===== Custom Styles for Head Turners Window Tint ===== */

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

/* Navbar Scroll Effect */
#navbar.scrolled {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

/* Mobile Menu Animation */
#mobile-menu.open {
    max-height: 400px;
}

.menu-line {
    transition: all 0.3s ease;
}

#menu-btn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

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

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

/* Service Card Hover */
.service-card {
    transform: translateY(0);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.service-card:hover {
    transform: translateY(-8px);
}

/* Gallery Item Hover */
.gallery-item {
    height: 280px;
}

.gallery-item img {
    transition: transform 0.7s ease;
}

/* Back to Top Button */
#back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

/* Fade In Animation */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Input Focus Styles */
input:focus,
select:focus,
textarea:focus {
    border-color: #800020 !important;
    box-shadow: 0 0 0 3px rgba(128, 0, 32, 0.1) !important;
}

/* Remove default select arrow and add custom */
select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%234A4A4A' 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 12px center;
    background-size: 16px;
    padding-right: 40px;
}

/* Mobile Link Hover */
.mobile-link {
    display: block;
    padding: 8px 0;
    border-bottom: 1px solid #f3f4f6;
}

.mobile-link:last-child {
    border-bottom: none;
}

/* Subtle gradient overlay on hero for better text readability */
#hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 120px;
    background: linear-gradient(to top, rgba(26, 26, 26, 0.3), transparent);
    pointer-events: none;
}

/* Prevent layout shift on images */
img {
    max-width: 100%;
    height: auto;
}

/* Selection color */
::selection {
    background-color: #800020;
    color: #FDF0F5;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

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

::-webkit-scrollbar-thumb {
    background: #800020;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #5a0017;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .gallery-item {
        height: 220px;
    }
    
    #hero h1 {
        font-size: 2.5rem;
    }
    
    .service-card {
        margin-bottom: 1rem;
    }
}

@media (min-width: 1024px) {
    .gallery-item {
        height: 320px;
    }
}
