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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    overflow-x: hidden;
}

::selection {
    background-color: rgba(161, 54, 75, 0.2);
    color: #5a202c;
}

/* ===== Navbar Scroll State ===== */
#navbar.scrolled {
    box-shadow: 0 1px 20px rgba(90, 32, 44, 0.08);
}

/* ===== Mobile Menu ===== */
.mobile-link {
    display: block;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(90, 32, 44, 0.1);
}

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

/* ===== 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, #5a202c, #fbbf24);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.5s ease;
}

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

/* ===== Testimonial Cards ===== */
.bg-white.rounded-2xl.p-8 {
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.bg-white.rounded-2xl.p-8:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(90, 32, 44, 0.1) !important;
}

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

/* ===== Back to Top ===== */
#back-to-top.visible {
    opacity: 1;
    pointer-events: all;
}

/* ===== Reduced Motion ===== */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .service-card::before {
        transform: scaleX(1);
    }
}

/* ===== Responsive Adjustments ===== */
@media (max-width: 768px) {
    .font-serif {
        font-size: clamp(1.75rem, 5vw, 2.5rem);
    }
}
