/* ============================================
   Hard Rock Granite and Tile — Custom Styles
   ============================================ */

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

::selection {
    background-color: rgba(13, 148, 136, 0.2);
    color: #0f766e;
}

/* --- Scrollbar --- */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0f172a;
}
::-webkit-scrollbar-thumb {
    background: #0d9488;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #14b8a6;
}

/* --- Navigation --- */
#navbar {
    background: transparent;
}

#navbar.scrolled {
    background: rgba(8, 14, 26, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05);
}

#navbar.scrolled .nav-logo-text,
#navbar.scrolled .nav-logo-path {
    color: #f8fafc;
}

#navbar.scrolled .nav-link {
    color: rgba(248, 250, 252, 0.7);
}

#navbar.scrolled .nav-link:hover {
    color: #5eead4;
}

.nav-link {
    color: rgba(255, 255, 255, 0.7);
}

.nav-link:hover {
    color: #5eead4;
}

.nav-logo-text {
    color: #f8fafc;
}

.nav-logo-path {
    stroke: #f8fafc;
}

/* --- Mobile Menu --- */
#mobileMenu.open {
    opacity: 1;
    pointer-events: all;
}

#mobileMenu.closed {
    opacity: 0;
    pointer-events: none;
}

.mobile-nav-link {
    color: rgba(255, 255, 255, 0.8);
    transition: color 0.3s ease;
}

.mobile-nav-link:hover {
    color: #5eead4;
}

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

.service-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #0d9488, #14b8a6);
    transition: width 0.5s ease;
}

.service-card:hover::after {
    width: 100%;
}

/* --- Gallery --- */
.gallery-item {
    cursor: pointer;
}

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

.testimonial-card::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 20px;
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 8rem;
    color: rgba(13, 148, 136, 0.1);
    line-height: 1;
    pointer-events: none;
}

/* --- Scroll Reveal Animations --- */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.hidden-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.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; }

/* --- 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.hidden-reveal {
        opacity: 1;
        transform: none;
    }
}

/* --- Footer Logo --- */
.footer-logo-path {
    stroke: #f8fafc;
}

/* --- Form Focus States --- */
input:focus,
select:focus,
textarea:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.1);
}

/* --- Button Hover Effects --- */
button[type="submit"]:active {
    transform: scale(0.98);
}

/* --- Responsive Adjustments --- */
@media (max-width: 768px) {
    #hero h1 {
        font-size: 3rem;
    }
    
    #hero h1 br {
        display: none;
    }
    
    #hero h1::after {
        content: 'Built to Last';
        display: block;
        font-size: 0.5em;
        margin-top: 0.2em;
    }
    
    .service-card::after {
        display: none;
    }
}

@media (min-width: 769px) {
    #hero h1 br {
        display: block;
    }
    
    #hero h1::after {
        content: '';
        display: none;
    }
}
