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

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

body {
    overflow-x: hidden;
}

/* Selection */
::selection {
    background: rgba(20, 200, 144, 0.3);
    color: #D8FDF3;
}

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

::-webkit-scrollbar-track {
    background: #040B18;
}

::-webkit-scrollbar-thumb {
    background: #152E54;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #14C890;
}

/* Navbar */
.nav-scrolled {
    background: rgba(4, 11, 24, 0.95) !important;
    backdrop-filter: blur(20px) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

/* Mobile menu */
.mobile-menu-open {
    opacity: 1 !important;
    pointer-events: all !important;
}

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

.menu-line.open:nth-child(2) {
    opacity: 0;
}

.menu-line.open:nth-child(3) {
    transform: rotate(-45deg) translate(4px, -4px);
    width: 1.4rem;
}

/* Service Cards */
.service-card {
    transform: translateY(0);
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(20, 200, 144, 0.1);
}

/* Testimonial Cards */
.testimonial-card {
    transform: translateY(0);
}

.testimonial-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

/* Gallery */
.gallery-item {
    cursor: pointer;
}

/* Scroll reveal animations */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger children */
.reveal-stagger > * {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    
    .reveal, .reveal-stagger > * {
        opacity: 1;
        transform: none;
        transition: none;
    }
    
    .gallery-item img {
        transition: none;
    }
}

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

.float-animation {
    animation: float 6s ease-in-out infinite;
}

/* Pulse glow */
@keyframes pulse-glow {
    0%, 100% { box-shadow: 0 0 20px rgba(20, 200, 144, 0.2); }
    50% { box-shadow: 0 0 40px rgba(20, 200, 144, 0.4); }
}

/* Gradient text utility */
.gradient-text {
    background: linear-gradient(135deg, #7DE8C4, #14C890);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

/* Button ripple effect */
.btn-ripple {
    position: relative;
    overflow: hidden;
}

.btn-ripple::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-ripple:active::after {
    width: 200px;
    height: 200px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .font-serif {
        line-height: 1.1;
    }
}
