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

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

body {
    overflow-x: hidden;
}

::selection {
    background: rgba(255, 107, 74, 0.3);
    color: #f6f6f7;
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #14161b;
}
::-webkit-scrollbar-thumb {
    background: #373c44;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #FF6B4A;
}

/* ===== Navbar ===== */
#navbar {
    transition: background-color 0.4s ease, box-shadow 0.4s ease, backdrop-filter 0.4s ease;
}

#navbar.scrolled {
    background: rgba(10, 12, 16, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(255, 107, 74, 0.1), 0 4px 30px rgba(0, 0, 0, 0.3);
}

/* ===== Mobile Menu ===== */
#mobileMenu.open {
    transform: translateX(0);
}

.mobile-link {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease, color 0.3s ease;
}

#mobileMenu.open .mobile-link {
    opacity: 1;
    transform: translateY(0);
}

#mobileMenu.open .mobile-link:nth-child(1) { transition-delay: 0.1s; }
#mobileMenu.open .mobile-link:nth-child(2) { transition-delay: 0.15s; }
#mobileMenu.open .mobile-link:nth-child(3) { transition-delay: 0.2s; }
#mobileMenu.open .mobile-link:nth-child(4) { transition-delay: 0.25s; }
#mobileMenu.open .mobile-link:nth-child(5) { transition-delay: 0.3s; }
#mobileMenu.open .mobile-link:nth-child(6) { transition-delay: 0.35s; }

/* ===== Hero Animations ===== */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-12px); }
}

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

.hero-badge {
    animation: fadeInUp 0.8s ease forwards;
}

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

.hero-text {
    animation: fadeInUp 0.8s ease 0.3s forwards;
    opacity: 0;
}

.hero-cta {
    animation: fadeInUp 0.8s ease 0.45s forwards;
    opacity: 0;
}

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

.hero-image {
    animation: fadeInUp 1s ease 0.3s forwards;
    opacity: 0;
}

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

/* ===== Service Cards ===== */
.service-card {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease, border-color 0.5s ease, box-shadow 0.5s ease;
}

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

.service-card:nth-child(1) { transition-delay: 0s; }
.service-card:nth-child(2) { transition-delay: 0.08s; }
.service-card:nth-child(3) { transition-delay: 0.16s; }
.service-card:nth-child(4) { transition-delay: 0.24s; }
.service-card:nth-child(5) { transition-delay: 0.32s; }
.service-card:nth-child(6) { transition-delay: 0.4s; }

/* ===== Gallery ===== */
.gallery-item {
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.6s ease, transform 0.6s ease;
    cursor: pointer;
}

.gallery-item.visible {
    opacity: 1;
    transform: scale(1);
}

/* ===== Testimonial Cards ===== */
.testimonial-card {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease, border-color 0.5s ease;
}

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

.testimonial-card:nth-child(1) { transition-delay: 0s; }
.testimonial-card:nth-child(2) { transition-delay: 0.12s; }
.testimonial-card:nth-child(3) { transition-delay: 0.24s; }

/* ===== Buttons ===== */
a, button {
    -webkit-tap-highlight-color: transparent;
}

button, [type="text"], [type="email"], [type="tel"], [type="number"], textarea, select {
    font-family: inherit;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    html {
        scroll-padding-top: 70px;
    }
}

/* ===== Focus visible ===== */
*:focus-visible {
    outline: 2px solid #FF6B4A;
    outline-offset: 2px;
}

/* ===== 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;
    }
    .service-card, .testimonial-card, .gallery-item {
        opacity: 1;
        transform: none;
    }
}
