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

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

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Background Shapes */
.bg-shapes {
    z-index: 0;
}

.shape-1 {
    position: absolute;
    top: 15%;
    right: -5%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(255, 128, 160, 0.08) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 8s ease-in-out infinite;
}

.shape-2 {
    position: absolute;
    bottom: 20%;
    left: -8%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(130, 33, 33, 0.06) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 10s ease-in-out infinite reverse;
}

.shape-3 {
    position: absolute;
    top: 50%;
    left: 30%;
    width: 150px;
    height: 150px;
    background: rgba(255, 213, 221, 0.1);
    border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    animation: morph 12s ease-in-out infinite;
}

.shape-4 {
    position: absolute;
    top: 70%;
    right: 15%;
    width: 100px;
    height: 100px;
    background: rgba(130, 33, 33, 0.05);
    border-radius: 20% 80% 40% 60% / 50% 30% 70% 50%;
    animation: morph 15s ease-in-out infinite reverse;
}

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

@keyframes morph {
    0%, 100% { border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%; transform: rotate(0deg); }
    25% { border-radius: 58% 42% 66% 34% / 46% 64% 36% 54%; }
    50% { border-radius: 50% 50% 33% 67% / 55% 27% 73% 45%; transform: rotate(180deg); }
    75% { border-radius: 33% 67% 58% 42% / 63% 68% 32% 37%; }
}

/* Hero Shapes */
.hero-shape {
    position: absolute;
    animation: heroFloat 6s ease-in-out infinite;
}

.shape-circle-1 {
    top: 15%;
    left: 5%;
    width: 200px;
    height: 200px;
    border: 2px solid rgba(255, 128, 160, 0.2);
    border-radius: 50%;
    animation-delay: 0s;
}

.shape-circle-2 {
    top: 60%;
    right: 8%;
    width: 120px;
    height: 120px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    animation-delay: 2s;
}

.shape-circle-3 {
    bottom: 20%;
    left: 15%;
    width: 80px;
    height: 80px;
    background: rgba(255, 128, 160, 0.1);
    border-radius: 50%;
    animation-delay: 1s;
}

.shape-triangle {
    top: 25%;
    right: 20%;
    width: 0;
    height: 0;
    border-left: 40px solid transparent;
    border-right: 40px solid transparent;
    border-bottom: 70px solid rgba(255, 128, 160, 0.08);
    animation: heroFloat 8s ease-in-out infinite reverse;
}

.shape-dots {
    top: 40%;
    left: 8%;
    width: 100px;
    height: 100px;
    background-image: radial-gradient(circle, rgba(255, 128, 160, 0.3) 1px, transparent 1px);
    background-size: 15px 15px;
    animation: heroFloat 7s ease-in-out infinite;
}

@keyframes heroFloat {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    33% { transform: translateY(-15px) rotate(3deg); }
    66% { transform: translateY(10px) rotate(-2deg); }
}

/* Navigation */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #ff80a0, #dc4949);
    transition: width 0.3s ease;
}

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

/* Mobile Menu */
#mobileMenu {
    max-height: 0;
}

#mobileMenu.open {
    max-height: 400px;
}

.menu-line:last-child {
    transition-delay: 0.1s;
}

/* Navbar Scroll Effect */
#navbar.scrolled {
    background: rgba(255, 248, 245, 0.95);
    backdrop-filter: blur(20px);
    box-shadow: 0 4px 30px rgba(130, 33, 33, 0.08);
}

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

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #822121, #ff80a0);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

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

/* Step Cards */
.step-card {
    position: relative;
}

/* Scroll Reveal Animations (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; }
    .reveal-delay-6 { transition-delay: 0.6s; }
}

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

/* Selection */
::selection {
    background: rgba(130, 33, 33, 0.15);
    color: #450a0a;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #FFF8F5;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #822121, #ff80a0);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #992424, #ff4d7e);
}
