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

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

body {
    margin: 0;
    overflow-x: hidden;
}

::selection {
    background: rgba(20, 184, 166, 0.3);
    color: #f8fafc;
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0a0f1a;
}
::-webkit-scrollbar-thumb {
    background: #1e293b;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #334155;
}

/* ===== Scroll Animations ===== */
.reveal-up,
.reveal-left,
.reveal-right {
    opacity: 1;
    transform: none;
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-up {
    transform: translateY(0);
}

.reveal-left {
    transform: translateX(0);
}

.reveal-right {
    transform: translateX(0);
}

@media (prefers-reduced-motion: no-preference) {
    .reveal-up {
        opacity: 0;
        transform: translateY(40px);
    }
    .reveal-left {
        opacity: 0;
        transform: translateX(-40px);
    }
    .reveal-right {
        opacity: 0;
        transform: translateX(40px);
    }
}

/* ===== Navbar ===== */
#navbar {
    background: transparent;
}

#navbar.scrolled {
    background: rgba(10, 15, 26, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(148, 163, 184, 0.06);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    width: 0;
    height: 1px;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

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

/* ===== Mobile Menu ===== */
.mobile-menu.active {
    opacity: 1;
    pointer-events: all;
}

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

.mobile-menu.active .mobile-link {
    opacity: 1;
    transform: translateY(0);
}

.mobile-menu.active .mobile-link:nth-child(1) { transition-delay: 0.1s; }
.mobile-menu.active .mobile-link:nth-child(2) { transition-delay: 0.15s; }
.mobile-menu.active .mobile-link:nth-child(3) { transition-delay: 0.2s; }
.mobile-menu.active .mobile-link:nth-child(4) { transition-delay: 0.25s; }
.mobile-menu.active .mobile-link:nth-child(5) { transition-delay: 0.3s; }

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

#menuBtn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(3px, 3px);
}
#menuBtn.active .menu-line:nth-child(2) {
    opacity: 0;
}
#menuBtn.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(3px, -3px);
    width: 1.25rem;
}

/* ===== Scroll Indicator ===== */
@keyframes scrollDown {
    0% { top: -24px; opacity: 0; }
    50% { opacity: 1; }
    100% { top: 48px; opacity: 0; }
}

.scroll-line {
    animation: scrollDown 2s ease-in-out infinite;
}

/* ===== Form Styles ===== */
input:focus,
select:focus,
textarea:focus {
    border-color: rgba(20, 184, 166, 0.6) !important;
    box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.1);
}

select option {
    background: #0f172a;
    color: #e2e8f0;
}

/* ===== Button Hover Glow ===== */
button[type="submit"]:hover {
    box-shadow: 0 0 30px rgba(245, 200, 66, 0.3);
}

/* ===== Image Hover Container ===== */
.group:hover img {
    transform: scale(1.05);
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    #hero h1 {
        font-size: 3rem;
    }

    #hero h1 span {
        display: inline;
    }

    .reveal-up,
    .reveal-left,
    .reveal-right {
        opacity: 1;
        transform: none;
    }
}
