/* ===================================
   E Frey Plumbing Company — Styles
   =================================== */

/* 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: #b83232;
    color: #fff;
}

/* Navbar */
.nav-fixed {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 50;
    background: transparent;
    transition: background 0.3s ease, box-shadow 0.3s ease, padding 0.3s ease;
    padding-top: 0;
}

.nav-fixed.scrolled {
    background: rgba(30, 24, 22, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05);
    padding-top: 0;
}

.nav-fixed.scrolled .font-serif,
.nav-fixed.scrolled .text-warm-800,
.nav-fixed.scrolled .text-sm {
    color: #fff !important;
}

.nav-fixed.scrolled .text-burgundy-700 {
    color: #f9d0d0 !important;
}

/* Mobile menu */
.mobile-menu-link {
    display: block;
    text-align: center;
    padding: 0.5rem;
    transition: color 0.2s ease;
}

.mobile-menu-link:hover {
    color: #f9d0d0;
}

/* Floating cards */
@keyframes float-slow {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-12px) rotate(0.5deg); }
}

@keyframes float-medium {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-8px) rotate(-0.5deg); }
}

@keyframes float-fast {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-16px) rotate(0.5deg); }
}

.animate-float-slow {
    animation: float-slow 6s ease-in-out infinite;
}

.animate-float-medium {
    animation: float-medium 4.5s ease-in-out infinite;
}

.animate-float-fast {
    animation: float-fast 3.5s ease-in-out infinite;
}

/* Scroll reveals (progressive enhancement) */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.7s ease, transform 0.7s ease;
    }

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

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

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

.service-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #7f2020, #ff5f45);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.service-card:hover::after {
    transform: scaleX(1);
}

/* Smooth focus */
input:focus,
select:focus,
textarea:focus {
    outline: none;
}

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

::-webkit-scrollbar-track {
    background: #1e1816;
}

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

::-webkit-scrollbar-thumb:hover {
    background: #9a2525;
}

/* Mobile menu animation */
#mobile-menu {
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

#mobile-menu.open {
    transform: translateX(0);
}

/* Image hover */
img {
    max-width: 100%;
    height: auto;
}

/* Print styles */
@media print {
    .nav-fixed,
    #mobile-menu,
    .animate-float-slow,
    .animate-float-medium,
    .animate-float-fast {
        display: none !important;
    }

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