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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
}

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

#navbar.scrolled {
    background: rgba(250, 249, 247, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
}

/* ===== Hero Animations ===== */
.hero-tag {
    animation: slideUp 0.8s ease forwards;
    animation-delay: 0.2s;
    opacity: 0;
}

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

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

.hero-cta {
    animation: slideUp 0.8s ease forwards;
    animation-delay: 0.8s;
    opacity: 0;
}

.hero-info {
    animation: slideUp 0.8s ease forwards;
    animation-delay: 1s;
    opacity: 0;
}

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

/* ===== Floating Card ===== */
.floating-card {
    animation: float 4s ease-in-out infinite;
}

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

/* ===== Section Animations (scroll-triggered) ===== */
.section-tag,
.section-title,
.section-subtitle {
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.section-tag.visible,
.section-title.visible,
.section-subtitle.visible {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* ===== Service Cards ===== */
.service-card {
    transition: opacity 0.6s ease, transform 0.6s ease, box-shadow 0.5s ease;
}

.service-card.visible {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

.service-card {
    transform: translateY(30px);
}

/* ===== About Section ===== */
.about-image,
.about-content {
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.about-image.visible,
.about-content.visible {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

.about-image,
.about-content {
    transform: translateY(40px);
}

/* ===== Gallery ===== */
.gallery-item {
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.gallery-item.visible {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

.gallery-item {
    transform: translateY(30px);
}

/* ===== Testimonials ===== */
.testimonial-card {
    transition: opacity 0.6s ease, transform 0.6s ease, box-shadow 0.5s ease;
}

.testimonial-card.visible {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

.testimonial-card {
    transform: translateY(30px);
}

.testimonial-card:hover {
    box-shadow: 0 20px 60px rgba(157, 23, 77, 0.08);
}

/* ===== CTA Section ===== */
.cta-tag,
.cta-title,
.cta-subtitle,
.cta-buttons {
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.cta-tag.visible,
.cta-title.visible,
.cta-subtitle.visible,
.cta-buttons.visible {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

.cta-tag,
.cta-title,
.cta-subtitle,
.cta-buttons {
    transform: translateY(30px);
}

/* ===== Contact ===== */
.contact-info,
.contact-map {
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.contact-info.visible,
.contact-map.visible {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

.contact-info,
.contact-map {
    transform: translateY(40px);
}

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

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

/* ===== Mobile Menu Links ===== */
.mobile-link {
    transition: opacity 0.4s ease, transform 0.4s ease;
}

/* ===== Menu Button Animation ===== */
#menuBtn.active .menu-line:nth-child(1) {
    top: 50%;
    transform: rotate(45deg);
}

#menuBtn.active .menu-line:nth-child(2) {
    opacity: 0;
}

#menuBtn.active .menu-line:nth-child(3) {
    top: 50%;
    transform: rotate(-45deg);
    width: 1.5rem;
    left: 50%;
    transform: translateX(-50%) rotate(-45deg);
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.75rem !important;
    }
    
    .floating-card {
        position: relative;
        bottom: auto;
        left: auto;
        margin-top: 1rem;
        max-width: 100%;
    }
    
    .section-title {
        font-size: 2.5rem !important;
    }
    
    .cta-title {
        font-size: 2.25rem !important;
    }
}

@media (max-width: 640px) {
    .hero-title {
        font-size: 2.25rem !important;
    }
}

/* ===== 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;
    }
    
    .hero-tag,
    .hero-title,
    .hero-subtitle,
    .hero-cta,
    .hero-info {
        opacity: 1 !important;
        animation: none !important;
    }
    
    .service-card,
    .testimonial-card,
    .gallery-item {
        opacity: 1 !important;
        transform: none !important;
    }
    
    .about-image,
    .about-content,
    .contact-info,
    .contact-map {
        opacity: 1 !important;
        transform: none !important;
    }
    
    .cta-tag,
    .cta-title,
    .cta-subtitle,
    .cta-buttons {
        opacity: 1 !important;
        transform: none !important;
    }
    
    .floating-card {
        animation: none !important;
    }
}

/* ===== Selection ===== */
::selection {
    background: rgba(157, 23, 77, 0.15);
    color: #831443;
}

::-moz-selection {
    background: rgba(157, 23, 77, 0.15);
    color: #831443;
}
