/* ===== Base & Utilities ===== */
html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
}

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

/* ===== Custom Scrollbar ===== */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0a1628;
}
::-webkit-scrollbar-thumb {
    background: #1e3f7a;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #2a529f;
}

/* ===== Animations ===== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

@keyframes bounceSlow {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(8px); }
}

.animate-fade-in {
    animation: fadeIn 0.8s ease-out forwards;
}

.animate-slide-up {
    animation: slideUp 0.8s ease-out forwards;
}

.animate-slide-up-delay {
    animation: slideUp 0.8s ease-out 0.15s forwards;
    opacity: 0;
}

.animate-slide-up-delay-2 {
    animation: slideUp 0.8s ease-out 0.3s forwards;
    opacity: 0;
}

.animate-bounce-slow {
    animation: bounceSlow 2s ease-in-out infinite;
}

/* ===== Scroll Reveal ===== */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.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; }

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

#navbar.scrolled {
    background: rgba(10, 22, 40, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.nav-link {
    position: relative;
}

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

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #14b8a6, #2dd4bf);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.service-card:hover::before {
    opacity: 1;
}

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

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

/* ===== Mobile Menu ===== */
#mobile-menu {
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.mobile-link {
    display: block;
    transition: all 0.2s ease;
}

.mobile-link:hover {
    padding-left: 12px;
}

/* ===== Responsive Typography ===== */
@media (max-width: 640px) {
    .font-serif {
        line-height: 1.2;
    }
}

/* ===== Print Styles ===== */
@media print {
    #navbar, #contact-form, button {
        display: none !important;
    }
    body {
        background: white !important;
        color: black !important;
    }
}
