/* === 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 {
    background: #7B2D3A;
    color: #FAF6F3;
}

/* === Scrollbar === */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #FAF6F3;
}
::-webkit-scrollbar-thumb {
    background: #7B2D3A;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #5c1f2a;
}

/* === Navigation === */
#navbar {
    background: transparent;
    transition: background 0.4s ease, box-shadow 0.4s ease, padding 0.4s ease;
}

#navbar.scrolled {
    background: rgba(250, 246, 243, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(123, 45, 58, 0.08);
}

.nav-link {
    position: relative;
}

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

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

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

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

/* Hamburger animation */
#menuBtn.active #menuIcon {
    transform: rotate(45deg) translate(5px, 5px);
}
#menuBtn.active #menuIcon2 {
    transform: rotate(-45deg) translate(5px, -5px);
}
#menuBtn.active #menuIcon3 {
    opacity: 0;
    width: 0;
}

/* === Hero Decorations === */
.hero-deco {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}

.hero-circle-1 {
    top: 10%;
    right: 5%;
    width: 400px;
    height: 400px;
    border: 1px solid rgba(123, 45, 58, 0.08);
    animation: float-slow 20s ease-in-out infinite;
}

.hero-circle-2 {
    top: 25%;
    right: 10%;
    width: 250px;
    height: 250px;
    border: 1px solid rgba(123, 45, 58, 0.06);
    animation: float-slow 15s ease-in-out infinite reverse;
}

.hero-circle-3 {
    bottom: 15%;
    left: 5%;
    width: 180px;
    height: 180px;
    background: radial-gradient(circle, rgba(123, 45, 58, 0.04) 0%, transparent 70%);
    animation: float-slow 18s ease-in-out infinite;
}

@keyframes float-slow {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    25% { transform: translate(15px, -20px) rotate(5deg); }
    50% { transform: translate(-10px, -35px) rotate(-3deg); }
    75% { transform: translate(-20px, -15px) rotate(2deg); }
}

/* === Floating Stat Cards === */
.floating-card {
    animation: float-card 6s ease-in-out infinite;
}

.card-1 {
    animation-delay: 0s;
}

.card-2 {
    animation-delay: -2s;
}

.card-3 {
    animation-delay: -4s;
}

@keyframes float-card {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-12px); }
}

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

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 20px;
    border: 1px solid transparent;
    transition: border-color 0.5s ease;
    pointer-events: none;
}

.service-card:hover::before {
    border-color: rgba(123, 45, 58, 0.2);
}

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

.gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(123, 45, 58, 0.4) 0%, transparent 60%);
    opacity: 0;
    transition: opacity 0.5s ease;
    border-radius: 16px;
}

.gallery-item:hover::after {
    opacity: 1;
}

/* === Scroll Reveal === */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

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

/* === Mobile Menu Overlay === */
@media (max-width: 767px) {
    #mobileMenu {
        background: rgba(250, 246, 243, 0.98);
        backdrop-filter: blur(20px);
    }
}

/* === Contact Form Focus States === */
input:focus, select:focus, textarea:focus {
    outline: none;
}

/* === Smooth image loading === */
img {
    background-color: #f0e6dc;
}

/* === Selection color override for dark sections === */
.bg-burgundy-950 ::selection {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
}

/* === Testimonial card hover === */
.bg-white\/5:hover {
    transform: translateY(-4px);
    transition: transform 0.4s ease, background 0.4s ease;
}

/* === CTA button hover lift === */
a[href="tel:+17044026879"] {
    display: inline-flex;
}

/* === Footer link hover underline === */
footer a {
    position: relative;
}

footer a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: #F5E6D3;
    transition: width 0.3s ease;
}

footer a:hover::after {
    width: 100%;
}
