/* ========================================
   The Home Upgrade Team — 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 Color */
::selection {
    background-color: #C2410C;
    color: #ffffff;
}

/* ========================================
   Animations
   ======================================== */

/* Hero entrance animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
}

/* Scroll reveal animations */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

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

/* ========================================
   Navigation
   ======================================== */

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1.5px;
    background-color: #C2410C;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Navbar scroll state */
.navbar-scrolled {
    background-color: rgba(255, 255, 255, 0.97) !important;
    backdrop-filter: blur(10px);
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
}

.navbar-scrolled .nav-link {
    color: #1a1a1a;
}

.navbar-scrolled .font-serif {
    color: #1a1a1a !important;
}

/* ========================================
   Mobile Menu
   ======================================== */

.mobile-link {
    display: block;
    padding: 0.5rem 0;
    border-bottom: 1px solid #f0f0f0;
}

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

/* ========================================
   Buttons
   ======================================== */

button, a.button {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

button::before,
a.button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    transition: left 0.5s ease;
}

button:hover::before,
a.button:hover::before {
    left: 100%;
}

/* ========================================
   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 12 12' fill='none'%3E%3Cpath d='M3 4.5l3 3 3-3' stroke='%23737373' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

select:focus {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 7.5l3-3 3 3' stroke='%23C2410C' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

/* ========================================
   Image Hover Effects
   ======================================== */

img {
    display: block;
    max-width: 100%;
}

/* ========================================
   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;
    }
}

/* ========================================
   Responsive Adjustments
   ======================================== */

@media (max-width: 768px) {
    .font-serif {
        line-height: 1.15;
    }
}

/* ========================================
   Utility: Smooth transitions for all interactive elements
   ======================================== */

a, button, input, select, textarea {
    transition: all 0.3s ease;
}

/* ========================================
   Print Styles
   ======================================== */

@media print {
    nav, .scroll-reveal, #contact-form, iframe {
        display: none !important;
    }
    
    body {
        color: #000;
        background: #fff;
    }
}
