/* ===== Custom Styles for AnC Mold Finishing Service ===== */

/* Base & Typography */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

/* Selection Color */
::selection {
    background-color: rgba(65, 181, 163, 0.3);
    color: #fff;
}

/* ===== Navbar ===== */
#navbar {
    backdrop-filter: blur(0px);
    -webkit-backdrop-filter: blur(0px);
}

#navbar.scrolled {
    background-color: rgba(4, 8, 16, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* Mobile Menu */
.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.05s; }
#mobileMenu.open .mobile-link:nth-child(2) { transition-delay: 0.1s; }
#mobileMenu.open .mobile-link:nth-child(3) { transition-delay: 0.15s; }
#mobileMenu.open .mobile-link:nth-child(4) { transition-delay: 0.2s; }
#mobileMenu.open .mobile-link:nth-child(5) { transition-delay: 0.25s; }

/* Menu Button Animation */
.menu-line {
    display: block;
}

#menuBtn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}

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

#menuBtn.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(4px, -4px);
    width: 24px;
}

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

.floating-card:nth-child(2) {
    animation-delay: -1s;
}

.floating-card:nth-child(3) {
    animation-delay: -3s;
}

.floating-card:nth-child(4) {
    animation-delay: -5s;
}

@keyframes float {
    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;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(65, 181, 163, 0), transparent);
    transition: all 0.5s ease;
}

.service-card:hover::before {
    background: linear-gradient(90deg, transparent, rgba(65, 181, 163, 0.6), transparent);
}

/* ===== Process Steps ===== */
.process-step {
    position: relative;
}

.process-step:hover .w-20 {
    background-color: rgba(65, 181, 163, 0.2);
    border-color: rgba(65, 181, 163, 0.5);
    transition: all 0.4s ease;
}

/* ===== Scroll Reveal Animations ===== */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal[data-reveal] {
    opacity: 0;
    transform: translateY(40px);
}

@media (prefers-reduced-motion: no-preference) {
    .reveal[data-reveal] {
        opacity: 0;
        transform: translateY(40px);
    }
    
    .reveal[data-reveal].revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Stagger delays */
.reveal[data-reveal="1"] { transition-delay: 0.1s; }
.reveal[data-reveal="2"] { transition-delay: 0.2s; }
.reveal[data-reveal="3"] { transition-delay: 0.3s; }
.reveal[data-reveal="4"] { transition-delay: 0.4s; }
.reveal[data-reveal="5"] { transition-delay: 0.5s; }
.reveal[data-reveal="6"] { transition-delay: 0.6s; }

/* ===== Custom Scrollbar ===== */
::-webkit-scrollbar {
    width: 8px;
}

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

::-webkit-scrollbar-thumb {
    background: rgba(65, 181, 163, 0.3);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(65, 181, 163, 0.5);
}

/* ===== Form Styles ===== */
select option {
    background-color: #040810;
    color: #fff;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .floating-card {
        display: none;
    }
    
    #hero {
        min-height: auto;
        padding-top: 100px;
        padding-bottom: 80px;
    }
}

/* ===== Focus Visible ===== */
:focus-visible {
    outline: 2px solid rgba(65, 181, 163, 0.6);
    outline-offset: 2px;
}
