/* ============================================================
   REVAMP.CSS : WebMar Studio Visual Refresh
   Motion-forward, Motionfly-inspired design layer.
   NEVER change brand color tokens. Only ADD neutral tints,
   blur accents, spacing refinements, and motion definitions.
   Loaded after all existing CSS : inherits all custom props.
   ============================================================ */

/* ============================================================
   DESIGN TOKENS : spacing scale, motion timings, type scale
   ============================================================ */
:root {
    /* Motion timings */
    --ease-expo-out:   cubic-bezier(0.16, 1, 0.3, 1);
    --ease-back-out:   cubic-bezier(0.34, 1.56, 0.64, 1);
    --ease-smooth:     cubic-bezier(0.25, 0.46, 0.45, 0.94);

    --dur-fast:   0.25s;
    --dur-base:   0.55s;
    --dur-slow:   0.85s;
    --dur-crawl:  1.1s;

    /* Section rhythm */
    --section-gap: clamp(5rem, 8vw + 1rem, 9rem);

    /* Soft tints : NO hue change; just opacity overlays of brand colors */
    --tint-ocean-5:  rgba(10, 77, 104, 0.05);
    --tint-ocean-8:  rgba(10, 77, 104, 0.08);
    --tint-aqua-6:   rgba(5, 191, 219, 0.06);
    --tint-aqua-12:  rgba(5, 191, 219, 0.12);
    --tint-coral-8:  rgba(255, 140, 66, 0.08);

    /* Blur glow radii */
    --glow-aqua:  0 0 60px rgba(5, 191, 219, 0.18);
    --glow-ocean: 0 0 80px rgba(10, 77, 104, 0.22);
}

/* ============================================================
   BODY FADE-IN : cinematic first-paint entry
   ============================================================ */
html, body {
    overflow-x: hidden;
}

body {
    opacity: 0;
    animation: bodyReveal 0.6s var(--ease-smooth) 0.05s forwards;
}

@keyframes bodyReveal {
    to { opacity: 1; }
}

/* Safety net: revamp.js force-sets opacity:1 on load in case the animation
   is paused (background tab, throttled mobile browser, etc). */

/* ============================================================
   SCROLL REVEAL : universal section-element entrance
   Applied by revamp.js via IntersectionObserver.
   Extend: add .rv-up, .rv-left, .rv-right, .rv-scale
   ============================================================ */
.rv-hidden {
    opacity: 0;
    transform: translateY(44px);
    transition:
        opacity var(--dur-slow) var(--ease-expo-out),
        transform var(--dur-slow) var(--ease-expo-out);
}

.rv-hidden.rv-scale-init {
    opacity: 0;
    transform: translateY(24px) scale(0.96);
    transition:
        opacity var(--dur-base) var(--ease-expo-out),
        transform var(--dur-base) var(--ease-expo-out);
}

.rv-hidden.rv-left-init {
    opacity: 0;
    transform: translateX(-32px);
    transition:
        opacity var(--dur-slow) var(--ease-expo-out),
        transform var(--dur-slow) var(--ease-expo-out);
}

.rv-hidden.rv-right-init {
    opacity: 0;
    transform: translateX(32px);
    transition:
        opacity var(--dur-slow) var(--ease-expo-out),
        transform var(--dur-slow) var(--ease-expo-out);
}

.rv-visible {
    opacity: 1 !important;
    transform: none !important;
}

/* ============================================================
   HERO SECTION ENHANCEMENTS
   ============================================================ */

/* Ensure hero-content is a positioned ancestor for the blob */
.hero-content {
    position: relative;
}

/* Soft gradient blob behind hero text. Clamped on mobile to prevent overflow. */
.hero-content {
    overflow: visible;
}

.hero-content::before {
    content: '';
    position: absolute;
    top: -80px;
    left: -120px;
    width: min(600px, 90vw);
    height: min(600px, 90vw);
    max-width: 100%;
    background: radial-gradient(
        ellipse at center,
        rgba(5, 191, 219, 0.12) 0%,
        rgba(10, 77, 104, 0.06) 45%,
        transparent 70%
    );
    border-radius: 50%;
    pointer-events: none;
    z-index: -1;
    animation: blobFloat 14s ease-in-out infinite;
}

@media (max-width: 768px) {
    .hero-content::before {
        top: -40px;
        left: -10vw;
        width: 80vw;
        height: 80vw;
    }
}

@keyframes blobFloat {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33%       { transform: translate(40px, -30px) scale(1.05); }
    66%       { transform: translate(-20px, 20px) scale(0.96); }
}

/* Animated underline on the hero highlight title line */
.title-line.highlight {
    position: relative;
    display: inline-block;
}

.title-line.highlight::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--gradient-light);
    border-radius: 2px;
    animation: underlineGrow 0.9s var(--ease-expo-out) 0.7s forwards;
}

@keyframes underlineGrow {
    to { width: 100%; }
}

/* Hero floating cards : lift + glow on hover */
.floating-card {
    border: 1px solid rgba(255, 255, 255, 0.6);
    transition:
        box-shadow var(--dur-base) var(--ease-expo-out),
        border-color var(--dur-base) var(--ease-expo-out),
        transform 0.6s var(--ease-expo-out);
}

.floating-card:hover {
    border-color: var(--aqua);
    box-shadow: 0 30px 60px -15px rgba(10, 77, 104, 0.3), var(--glow-aqua);
}

/* ============================================================
   NAV ENHANCEMENTS
   ============================================================ */
.nav {
    transition:
        background var(--dur-base) var(--ease-smooth),
        box-shadow var(--dur-base) var(--ease-smooth),
        padding var(--dur-base) var(--ease-smooth);
}

.nav-container {
    transition: padding var(--dur-base) var(--ease-smooth);
}

.nav.scrolled {
    box-shadow: 0 1px 0 rgba(10, 77, 104, 0.08), 0 4px 24px rgba(10, 77, 104, 0.08);
}

.nav.scrolled .nav-container {
    padding-top: 0.6rem;
    padding-bottom: 0.6rem;
}

/* ============================================================
   SECTION LABEL : pill badge reveal feel
   ============================================================ */
.section-label {
    animation: none; /* controlled by rv- classes */
    transition: transform var(--dur-base) var(--ease-back-out);
}

/* ============================================================
   SECTION TITLE : tighter display rhythm
   ============================================================ */
.section-title {
    line-height: 1.15;
    letter-spacing: -0.01em;
}

/* ============================================================
   SECTION DIVIDERS : soft gradient fade instead of hard break
   Each white section transitions into the next via a thin
   gradient overlay at the bottom edge.
   ============================================================ */
.section {
    position: relative;
}

.section + .section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(10, 77, 104, 0.10) 20%,
        rgba(5, 191, 219, 0.18) 50%,
        rgba(10, 77, 104, 0.10) 80%,
        transparent 100%
    );
    pointer-events: none;
    z-index: 1;
    opacity: 0;
    transition: opacity 0.6s var(--ease-smooth);
}

/* Reveal the divider when the section is in view */
.section.in-view + .section::before,
.section + .section.in-view::before {
    opacity: 1;
}

/* ============================================================
   BUTTON ENHANCEMENTS
   ============================================================ */

/* Magnetic wrapper: JS will apply transform here */
.btn-mag-wrapper {
    display: inline-block;
    transition: transform 0.4s var(--ease-expo-out);
}

/* Scale-down on press for all buttons */
.btn:active {
    transform: scale(0.97) translateY(1px) !important;
}

/* Border glow on focus-visible */
.btn:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(5, 191, 219, 0.5);
}

/* Primary button : stop pulsing after hover, add glow layer */
.btn-primary {
    position: relative;
    isolation: isolate;
}

.btn-primary::after {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    background: var(--gradient-ocean);
    opacity: 0;
    z-index: -1;
    filter: blur(12px);
    transition: opacity var(--dur-base) var(--ease-smooth);
}

.btn-primary:hover::after {
    opacity: 0.5;
}

/* ============================================================
   SERVICE CARDS : border highlight on hover
   ============================================================ */
.service-card {
    border: 1px solid transparent;
    transition:
        transform 0.4s var(--ease-expo-out),
        box-shadow 0.4s var(--ease-expo-out),
        border-color 0.4s var(--ease-smooth);
}

.service-card:hover {
    border-color: rgba(5, 191, 219, 0.35);
    transform: translateY(-8px);
    box-shadow: 0 24px 48px -12px rgba(10, 77, 104, 0.18), var(--glow-aqua);
}

/* ============================================================
   TESTIMONIAL CARDS : reveal + lift
   ============================================================ */
.testimonial-card {
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-xl);
    transition:
        transform 0.4s var(--ease-expo-out),
        box-shadow 0.4s var(--ease-expo-out),
        border-color 0.35s var(--ease-smooth);
}

.testimonial-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 40px -10px rgba(10, 77, 104, 0.15);
    border-color: rgba(5, 191, 219, 0.3);
}

/* ============================================================
   WOD COMPARISON CARDS : enhanced hover depth
   Extends packages.css existing border/bg styles.
   ============================================================ */
.wod-new-way:hover {
    box-shadow: 0 16px 40px -8px rgba(5, 191, 219, 0.25), var(--glow-aqua) !important;
    transform: translateY(-6px) !important;
}

.wod-old-way:hover {
    box-shadow: 0 12px 30px -6px rgba(220, 38, 38, 0.12) !important;
    transform: translateY(-4px) !important;
}

/* ============================================================
   GEO CARDS : stronger hover
   ============================================================ */
.geo-card {
    transition:
        transform 0.4s var(--ease-expo-out),
        box-shadow 0.4s var(--ease-expo-out),
        border-color 0.35s var(--ease-smooth);
}

.geo-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 40px -8px rgba(10, 77, 104, 0.14), var(--glow-aqua);
}

/* ============================================================
   PACKAGE CARDS : lift + glow
   ============================================================ */
.package-card {
    transition:
        transform 0.4s var(--ease-expo-out),
        box-shadow 0.4s var(--ease-expo-out),
        border-color 0.4s var(--ease-smooth);
}

.package-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 24px 50px -12px rgba(10, 77, 104, 0.2);
}

.package-card-featured:hover {
    box-shadow: 0 28px 56px -14px rgba(5, 191, 219, 0.3), var(--glow-aqua);
}

/* ============================================================
   PORTFOLIO ITEMS : uniform reveal treatment
   ============================================================ */
.portfolio-item {
    transition:
        transform 0.4s var(--ease-expo-out),
        box-shadow 0.4s var(--ease-expo-out);
}

.portfolio-item:hover {
    transform: translateY(-4px);
}

/* ============================================================
   CURSOR ACCENT : small dot follower on desktop
   Hidden on touch/mobile. Subtle aqua ring.
   ============================================================ */
@media (min-width: 1024px) and (hover: hover) and (pointer: fine) {
    .rv-cursor {
        position: fixed;
        top: 0;
        left: 0;
        width: 14px;
        height: 14px;
        border: 2px solid rgba(5, 191, 219, 0.7);
        border-radius: 50%;
        pointer-events: none;
        z-index: 9990;
        will-change: transform;
        backface-visibility: hidden;
        mix-blend-mode: multiply;
        transition:
            width 0.3s var(--ease-expo-out),
            height 0.3s var(--ease-expo-out),
            border-color 0.3s var(--ease-smooth),
            opacity 0.25s ease;
    }

    .rv-cursor.rv-cursor-hover {
        width: 36px;
        height: 36px;
        border-color: rgba(5, 191, 219, 0.5);
        background: rgba(5, 191, 219, 0.06);
    }

    .rv-cursor.rv-cursor-click {
        width: 10px;
        height: 10px;
        border-color: rgba(255, 140, 66, 0.8);
    }
}

/* ============================================================
   SCROLL PROGRESS : refinement (already exists in JS,
   this just makes it a bit thicker and adds a glow)
   ============================================================ */

/* The progress bar is injected inline by immersive-interactions.js.
   We intercept it via the class we'll add in revamp.js. */
.rv-scroll-bar {
    height: 3px !important;
    background: linear-gradient(90deg, var(--deep-ocean), var(--teal), var(--aqua), var(--coral)) !important;
    box-shadow: 0 0 8px rgba(5, 191, 219, 0.4);
}

/* ============================================================
   SOCIAL PROOF : result number pop
   ============================================================ */
.result-number {
    transition: transform 0.3s var(--ease-back-out);
}

.testimonial-card:hover .result-number {
    transform: scale(1.08);
}

/* ============================================================
   ABOUT SECTION : paragraph rhythm
   ============================================================ */
.about-paragraph {
    line-height: 1.85;
}

/* ============================================================
   WOD PRICE TAGS : hover float
   ============================================================ */
.wod-price-tag {
    transition:
        transform 0.35s var(--ease-back-out),
        box-shadow 0.35s var(--ease-smooth);
    cursor: default;
}

.wod-price-tag:hover {
    transform: translateY(-3px) scale(1.04);
    box-shadow: 0 8px 20px rgba(10, 77, 104, 0.15);
}

/* ============================================================
   REDUCED MOTION : full disable of all new animations
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
    body {
        animation: none !important;
        opacity: 1 !important;
    }

    .rv-hidden,
    .rv-hidden.rv-scale-init,
    .rv-hidden.rv-left-init,
    .rv-hidden.rv-right-init {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }

    .hero-content::before {
        animation: none !important;
    }

    .title-line.highlight::after {
        animation: none !important;
        width: 100%;
    }

    .rv-cursor {
        display: none !important;
    }

    .btn:active { transform: none !important; }

    .floating-card,
    .service-card,
    .testimonial-card,
    .wod-old-way,
    .wod-new-way,
    .geo-card,
    .package-card,
    .portfolio-item,
    .wod-price-tag {
        transition: none !important;
    }
}

/* ============================================================
   STAGGER UTILITIES : applied dynamically by revamp.js
   ============================================================ */
.rv-stagger-1 { transition-delay: 0.08s; }
.rv-stagger-2 { transition-delay: 0.16s; }
.rv-stagger-3 { transition-delay: 0.24s; }
.rv-stagger-4 { transition-delay: 0.32s; }
.rv-stagger-5 { transition-delay: 0.40s; }
.rv-stagger-6 { transition-delay: 0.48s; }

/* ============================================================
   FOOTER POLISH : consistent spacing across all pages.
   Fluid column gap, even alignment, calmer hierarchy.
   ============================================================ */
.footer-content {
    gap: clamp(2rem, 5vw, 5rem) !important;
    align-items: start;
}

.footer-content > div {
    align-self: start;
    min-width: 0;
}

.footer-column h4 {
    margin-bottom: 1.25rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    font-size: 0.85rem;
    opacity: 0.95;
}

.footer-column a {
    padding: 0.4rem 0;
    font-size: 0.95rem;
}

.footer-brand p {
    margin-bottom: 1.25rem;
}

.footer-contact > div {
    margin-bottom: 0.85rem;
}

.footer-contact .icon {
    width: 18px;
    height: 18px;
    color: var(--aqua, #05BFDB);
    flex-shrink: 0;
}

@media (min-width: 1280px) {
    .footer-content {
        grid-template-columns: 2.4fr 1fr 1.2fr 1fr;
    }
}

@media (max-width: 900px) {
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
        gap: 2.5rem !important;
    }
    .footer-brand {
        grid-column: 1 / -1;
    }
}

@media (max-width: 560px) {
    .footer-content {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
}
