*, *::before, *::after {
    box-sizing: border-box;
}

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

body {
    overflow-x: hidden;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #fefdfb;
}
::-webkit-scrollbar-thumb {
    background: #f8c3c9;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #e56370;
}

/* Selection color */
::selection {
    background: #fce3e6;
    color: #7B2D3B;
}

/* Hero animations */
.hero-badge {
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
    animation-delay: 0.2s;
}

.hero-title {
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
    animation-delay: 0.4s;
}

.hero-subtitle {
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
    animation-delay: 0.6s;
}

.hero-ctas {
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
    animation-delay: 0.8s;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

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

/* Navbar */
.navbar-scrolled {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(20px);
    box-shadow: 0 1px 20px rgba(123, 45, 59, 0.08);
}

.navbar-scrolled .nav-link {
    color: #4b5563;
}

.navbar-scrolled .logo-text {
    color: #7B2D3B;
}

/* Service card hover image effect */
.service-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 16px;
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
}

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

/* Mobile menu animation */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, opacity 0.3s ease;
    opacity: 0;
}

#mobile-menu.open {
    max-height: 400px;
    opacity: 1;
}

/* Testimonial card hover */
.testimonial-card:hover .quote-icon {
    transform: scale(1.1) rotate(-5deg);
}

/* Button ripple effect */
button, a {
    -webkit-tap-highlight-color: transparent;
}

/* Parallax-like subtle movement for hero */
#hero {
    will-change: transform;
}

/* Subtle grain texture overlay for hero */
#hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
    pointer-events: none;
    z-index: 1;
}

#hero > .relative {
    z-index: 2;
}

/* Floating animation for decorative elements */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.float-anim {
    animation: float 4s ease-in-out infinite;
}

/* Pulse ring for CTA buttons */
@keyframes pulse-ring {
    0% { box-shadow: 0 0 0 0 rgba(123, 45, 59, 0.3); }
    70% { box-shadow: 0 0 0 10px rgba(123, 45, 59, 0); }
    100% { box-shadow: 0 0 0 0 rgba(123, 45, 59, 0); }
}

.cta-pulse {
    animation: pulse-ring 2s ease-out infinite;
}

/* Loading skeleton */
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* Print styles */
@media print {
    nav, #contact-form, .scroll-reveal { display: none; }
    body { color: #000; background: #fff; }
}
