/* ===================================
   VO2physio — Custom Styles
   =================================== */

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

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

body {
    overflow-x: hidden;
}

/* Smooth scroll offset for fixed nav */
section[id] {
    scroll-margin-top: 80px;
}

/* Navigation */
.nav-logo-color {
    color: white;
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1.5px;
    background: #f9a8d4;
    transition: width 0.3s ease;
}

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

.nav-scrolled .nav-logo-color {
    color: #1c1917;
}

.nav-scrolled .nav-link {
    color: rgba(28, 25, 23, 0.85);
}

.nav-scrolled .nav-link:hover {
    color: #B85C38;
}

.nav-scrolled .nav-link::after {
    background: #B85C38;
}

.nav-scrolled #navbar {
    background: rgba(253, 251, 247, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(0,0,0,0.06);
}

/* Mobile Menu */
.mobile-menu-link {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease, color 0.2s ease;
}

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

.mobile-menu.open .mobile-menu-link:nth-child(1) { transition-delay: 0.05s; }
.mobile-menu.open .mobile-menu-link:nth-child(2) { transition-delay: 0.1s; }
.mobile-menu.open .mobile-menu-link:nth-child(3) { transition-delay: 0.15s; }
.mobile-menu.open .mobile-menu-link:nth-child(4) { transition-delay: 0.2s; }

/* Hero Animations */
.hero-headline,
.hero-subtitle,
.hero-desc,
.hero-cta,
.hero-stats {
    /* Default state visible for no-JS fallback */
    opacity: 1;
    transform: none;
}

@media (prefers-reduced-motion: no-preference) {
    .hero-headline {
        animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.2s both;
    }
    .hero-subtitle {
        animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.1s both;
    }
    .hero-desc {
        animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.35s both;
    }
    .hero-cta {
        animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.45s both;
    }
    .hero-stats {
        animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.55s both;
    }
}

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

/* Scroll Reveal (below fold only) */
.reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.revealed {
    opacity: 1;
    transform: none;
}

@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
    }
    .reveal.revealed {
        opacity: 1;
        transform: none;
    }
}

/* Service Cards */
.service-card {
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s ease;
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(184, 92, 56, 0.2);
}

/* About Section */
.about-images {
    perspective: 1000px;
}

.about-images img {
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.about-images:hover img {
    transform: rotateY(-2deg) scale(1.01);
}

/* Approach Steps */
.approach-step {
    transition: transform 0.3s ease;
}

.approach-step:hover {
    transform: translateX(6px);
}

/* Contact Form */
.contact-form input:focus,
.contact-form textarea:focus {
    border-color: #d4846a;
    box-shadow: 0 0 0 3px rgba(184, 92, 56, 0.1);
}

/* Custom selection color */
::selection {
    background: rgba(184, 92, 56, 0.2);
    color: #1c1917;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #B85C38;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .hero-headline {
        font-size: 2.75rem !important;
    }

    .hero-stats {
        flex-direction: column;
        gap: 0.75rem;
    }

    .hero-stats > div {
        border-left-width: 3px;
        padding-left: 0.75rem;
    }

    .about-images img {
        height: 350px !important;
    }

    .about-images .absolute.-bottom-8.-right-8 {
        position: relative;
        bottom: auto;
        right: auto;
        margin-top: 1rem;
    }
}

@media (max-width: 640px) {
    .service-card {
        padding: 1.5rem;
    }
}
