/* =========================================
   CALENDLY CTA — CSS Scale Trick for
   desktop layout in compact container
   ========================================= */

.cs-cal-section {
    position: relative !important;
    width: 100% !important;
    min-height: 700px !important;
    background: #0a0a0a !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    overflow: hidden !important;
    padding: 30px 2px !important;
}

/* Fade-to-black edges — aggressive so glow stays contained */
.cs-cal-edge-fade-top,
.cs-cal-edge-fade-bottom {
    position: absolute !important;
    left: 0 !important; right: 0 !important;
    height: 150px !important;
    z-index: 15 !important;
    pointer-events: none !important;
}
.cs-cal-edge-fade-top {
    top: 0 !important;
    background: linear-gradient(to bottom, #050505 0%, #050505 40%, transparent 100%) !important;
}
.cs-cal-edge-fade-bottom {
    bottom: 0 !important;
    background: linear-gradient(to top, #050505 0%, #050505 40%, transparent 100%) !important;
}

/* ── BACKGROUND GLOWS (tight to box) ── */
.cs-cal-bg-glows {
    position: absolute !important; inset: 0 !important;
    z-index: 1 !important; pointer-events: none !important;
}
.cs-cal-glow-base {
    position: absolute !important; top: 50% !important; left: 50% !important;
    transform: translate(-50%, -50%) !important;
    width: 780px !important; height: 490px !important;
    background: radial-gradient(ellipse at center, rgba(16,185,129,0.12) 0%, rgba(16,185,129,0.03) 50%, transparent 75%) !important;
    filter: blur(30px) !important;
    animation: cs-cal-base-breathe 8s ease-in-out infinite alternate !important;
}
@keyframes cs-cal-base-breathe {
    0% { opacity: 0.7; transform: translate(-50%,-50%) scale(0.97); }
    100% { opacity: 1; transform: translate(-50%,-50%) scale(1.04); }
}
.cs-cal-glow-core {
    position: absolute !important; top: 50% !important; left: 50% !important;
    transform: translate(-50%, -50%) !important;
    width: 450px !important; height: 350px !important;
    background: radial-gradient(ellipse at center, rgba(193,233,78,0.1) 0%, transparent 60%) !important;
    filter: blur(25px) !important;
    animation: cs-cal-core-breathe 4.5s ease-in-out infinite alternate !important;
}
@keyframes cs-cal-core-breathe {
    0% { transform: translate(-50%,-50%) scale(0.9); opacity: 0.4; }
    100% { transform: translate(-50%,-50%) scale(1.1); opacity: 1; }
}
.cs-cal-lime-streak {
    position: absolute !important; width: 350px !important; height: 350px !important;
    background: radial-gradient(circle at center, rgba(193,233,78,0.1) 0%, transparent 55%) !important;
    filter: blur(30px) !important; animation: cs-cal-orbit 16s linear infinite !important;
}
.cs-cal-teal-orb {
    position: absolute !important; width: 300px !important; height: 300px !important;
    background: radial-gradient(circle at center, rgba(13,148,136,0.08) 0%, transparent 60%) !important;
    filter: blur(25px) !important; animation: cs-cal-orbit-reverse 20s linear infinite !important;
}
.cs-cal-emerald-drift {
    position: absolute !important; width: 280px !important; height: 280px !important;
    background: radial-gradient(circle at center, rgba(16,185,129,0.07) 0%, transparent 60%) !important;
    filter: blur(30px) !important; animation: cs-cal-drift 14s ease-in-out infinite alternate !important;
}
@keyframes cs-cal-orbit { 0% { transform: translate(-12%,-12%) rotate(0deg); } 100% { transform: translate(12%,12%) rotate(360deg); } }
@keyframes cs-cal-orbit-reverse { 0% { transform: translate(10%,-10%) rotate(0deg); } 100% { transform: translate(-10%,10%) rotate(-360deg); } }
@keyframes cs-cal-drift { 0% { transform: translate(0,0) scale(0.95); opacity: 0.5; } 50% { transform: translate(-25px,15px) scale(1.05); opacity: 1; } 100% { transform: translate(20px,-10px) scale(0.97); opacity: 0.6; } }

.cs-cal-ember {
    position: absolute !important; width: 3px !important; height: 3px !important;
    border-radius: 50% !important; background: #c1e94e !important;
    filter: blur(0.5px) !important; opacity: 0 !important;
    animation: cs-cal-float-up 7s ease-in-out infinite !important;
}
.cs-cal-ember--teal { background: #10b981 !important; width: 2px !important; height: 2px !important; }
@keyframes cs-cal-float-up {
    0% { transform: translateY(0) scale(1); opacity: 0; } 12% { opacity: 0.8; }
    50% { opacity: 0.5; } 100% { transform: translateY(-250px) scale(0.2); opacity: 0; }
}

/* ── ECLIPSE GLOW (ready state, tight) ── */
.cs-cal-eclipse-wrap {
    position: absolute !important; top: 50% !important; left: 50% !important;
    transform: translate(-50%,-50%) !important;
    width: 100% !important; max-width: 780px !important; height: 490px !important;
    z-index: 5 !important; pointer-events: none !important;
    opacity: 0 !important; transition: opacity 2.5s ease !important;
}
.cs-cal-section.is-ready .cs-cal-eclipse-wrap { opacity: 1 !important; }
.cs-cal-intense-glow {
    position: absolute !important; inset: -15px !important;
    background:
        radial-gradient(ellipse at center, rgba(193,233,78,0.1) 0%, transparent 55%),
        radial-gradient(circle at 25% 35%, rgba(16,185,129,0.07) 0%, transparent 45%),
        radial-gradient(circle at 75% 65%, rgba(16,185,129,0.07) 0%, transparent 45%) !important;
    filter: blur(25px) !important; animation: cs-cal-aurora 7s ease-in-out infinite alternate !important;
}
@keyframes cs-cal-aurora { 0% { transform: scale(1) rotate(0deg); opacity: 0.7; } 100% { transform: scale(1.04) rotate(2deg); opacity: 1; } }

/* ── GLASS BOX ── */
.cs-cal-widget-wrap {
    position: relative !important; z-index: 10 !important;
    width: 100% !important; max-width: 760px !important; min-height: 472px !important;
    opacity: 1 !important;
    transform: scale(0.97) translateY(10px) !important;
    transition: all 2s cubic-bezier(0.16,1,0.3,1) !important;
    background: rgba(5,5,5,0.5) !important; border-radius: 12px !important;
    overflow: hidden !important; border: 1px solid rgba(193,233,78,0.08) !important;
    backdrop-filter: blur(20px) !important; box-shadow: 0 0 50px rgba(0,0,0,0.8) !important;
}
.cs-cal-section.is-ready .cs-cal-widget-wrap {
    transform: scale(1) translateY(0) !important;
    border-color: rgba(193,233,78,0.2) !important;
    box-shadow: 0 0 50px rgba(16,185,129,0.1), 0 0 25px rgba(193,233,78,0.03) !important;
}

/* ── LOGO LAYER (always visible, behind Calendly) ── */
.cs-cal-logo-layer {
    position: absolute !important; inset: 0 !important;
    z-index: 1 !important; border-radius: 12px !important;
    overflow: hidden !important; pointer-events: none !important;
}
.cs-cal-logo-layer canvas {
    position: absolute !important; inset: 0 !important;
    width: 100% !important; height: 100% !important; z-index: 2 !important;
    opacity: 0 !important; transition: opacity 2s ease 0.5s !important;
}
.cs-cal-section.in-view .cs-cal-logo-layer canvas { opacity: 1 !important; }

.cs-cal-ghost-logo {
    position: absolute !important; top: 50% !important; left: 50% !important;
    width: 240px !important; height: 240px !important;
    z-index: 1 !important; opacity: 0 !important;
    pointer-events: none !important;
    transform: translate(-50%, -50%) scale(0.6) !important;
    transition: opacity 2.5s ease, transform 3s cubic-bezier(0.16, 1, 0.3, 1) !important;
}
.cs-cal-section.in-view .cs-cal-ghost-logo {
    opacity: 0.3 !important;
    transform: translate(-50%, -50%) scale(1) !important;
    animation: cs-cal-logo-drift 22s ease-in-out infinite alternate !important;
    animation-delay: 3s !important;
}
@keyframes cs-cal-logo-drift {
    0%   { transform: translate(-50%,-50%) scale(1) rotate(-1.5deg); }
    33%  { transform: translate(-49%,-51%) scale(1.03) rotate(0.5deg); }
    66%  { transform: translate(-51%,-49%) scale(0.98) rotate(-0.8deg); }
    100% { transform: translate(-50%,-50%) scale(1.02) rotate(1deg); }
}
.cs-cal-ghost-logo svg { width: 100% !important; height: 100% !important; overflow: visible !important; }

/* Logo aura pulses */
.cs-cal-aura-lg { animation: cs-cal-aura-pulse 5s infinite ease-in-out !important; transform-origin: center !important; transform-box: fill-box !important; }
.cs-cal-aura-md { animation: cs-cal-aura-pulse 6s infinite ease-in-out !important; animation-delay: 1s !important; transform-origin: center !important; transform-box: fill-box !important; }
@keyframes cs-cal-aura-pulse { 0% { opacity: 0.5; transform: scale(1); } 50% { opacity: 0.85; transform: scale(1.12); } 100% { opacity: 0.5; transform: scale(1); } }

/* Logo spaceships */
.cs-cal-ship-cw { animation: cs-cal-orb-cw var(--dur) infinite linear !important; transform-origin: var(--cx) var(--cy) !important; }
.cs-cal-ship-ccw { animation: cs-cal-orb-ccw var(--dur) infinite linear !important; transform-origin: var(--cx) var(--cy) !important; }
@keyframes cs-cal-orb-cw { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes cs-cal-orb-ccw { from { transform: rotate(360deg); } to { transform: rotate(0deg); } }

/* Corner brackets */
.cs-cal-corner {
    position: absolute !important; width: 35px !important; height: 35px !important;
    z-index: 3 !important; opacity: 0 !important;
    transition: opacity 1.5s ease 1s !important;
}
.cs-cal-section.in-view .cs-cal-corner { animation: cs-cal-corner-pulse 3s ease-in-out infinite alternate !important; }
.cs-cal-corner--tl { top: 12px !important; left: 12px !important; border-top: 1px solid #c1e94e !important; border-left: 1px solid #c1e94e !important; }
.cs-cal-corner--tr { top: 12px !important; right: 12px !important; border-top: 1px solid #c1e94e !important; border-right: 1px solid #c1e94e !important; animation-delay: 0.75s !important; }
.cs-cal-corner--bl { bottom: 12px !important; left: 12px !important; border-bottom: 1px solid #10b981 !important; border-left: 1px solid #10b981 !important; animation-delay: 1.5s !important; }
.cs-cal-corner--br { bottom: 12px !important; right: 12px !important; border-bottom: 1px solid #10b981 !important; border-right: 1px solid #10b981 !important; animation-delay: 2.25s !important; }
@keyframes cs-cal-corner-pulse { 0% { opacity: 0.2; } 100% { opacity: 0.6; } }

/* Status text */
.cs-cal-box-status {
    position: absolute !important; bottom: 20px !important; left: 50% !important;
    transform: translateX(-50%) !important; z-index: 4 !important;
    font-family: 'JetBrains Mono', monospace !important; font-size: 9px !important;
    letter-spacing: 0.5em !important; text-transform: uppercase !important;
    color: rgba(193,233,78,0.5) !important; white-space: nowrap !important;
    transition: opacity 1s ease !important;
}
.cs-cal-section.is-ready .cs-cal-box-status { opacity: 0 !important; }

/* ── CALENDLY SCALE TRICK ──
   Render at 1100px so Calendly shows desktop layout,
   then CSS scale it down to fit the glass box */
.cs-cal-cal-wrap {
    position: absolute !important;
    top: 0 !important; left: 0 !important;
    width: 100% !important; height: 470px !important;
    z-index: 5 !important;
    overflow: hidden !important;
    opacity: 0 !important;
    transition: opacity 1.2s ease !important;
}
.cs-cal-section.is-ready .cs-cal-cal-wrap { opacity: 1 !important; }

.cs-cal-cal-wrap .calendly-inline-widget {
    width: 1100px !important;
    height: 680px !important;
    transform: scale(var(--cal-scale, 0.69)) !important;
    transform-origin: top left !important;
}

/* Hard clamp: no matter what Calendly's widget.js measures the parent at,
   the embedded iframe can never push beyond the wrap. Belt and braces
   against the v1.2.17 race condition where the iframe is created before
   the responsive CSS finishes applying. */
.cs-cal-cal-wrap iframe {
    max-width: 100% !important;
}

/* ── MOBILE (v1.2.5) ──
   Abandon the scale trick on phones. It produced a broken hitbox because
   pointer events still hit the pre-transform 1100x680 bounding box. Instead
   use Calendly's native responsive embed: the widget fills the glass box
   at 100% width with a generous min-height. Chrome (corners, logo, status,
   ghost SVG) is preserved and simply wraps a taller rectangle. */
@media (max-width: 768px) {
    .cs-cal-section {
        min-height: auto !important;
        padding: 28px 16px !important;
    }
    .cs-cal-widget-wrap {
        max-width: calc(100vw - 32px) !important;
        width: calc(100vw - 32px) !important;
        min-height: 700px !important;
        height: auto !important;
        border-radius: 12px !important;
    }
    /* Kill the scale-trick positioning: let Calendly flow naturally */
    .cs-cal-cal-wrap {
        position: relative !important;
        top: auto !important;
        left: auto !important;
        width: 100% !important;
        height: auto !important;
        min-height: 680px !important;
        overflow: visible !important;
    }
    .cs-cal-cal-wrap .calendly-inline-widget {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        height: 680px !important;
        min-height: 680px !important;
        transform: none !important;
        transform-origin: 0 0 !important;
    }
    .cs-cal-cal-wrap .calendly-inline-widget iframe {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
    }
    .cs-cal-logo-layer { border-radius: 12px !important; }
    .cs-cal-ghost-logo { width: 140px !important; height: 140px !important; }
    .cs-cal-section.in-view .cs-cal-ghost-logo { opacity: 0.22 !important; }
    .cs-cal-corner { width: 18px !important; height: 18px !important; }
    .cs-cal-corner--tl { top: 6px !important; left: 6px !important; }
    .cs-cal-corner--tr { top: 6px !important; right: 6px !important; }
    .cs-cal-corner--bl { bottom: 6px !important; left: 6px !important; }
    .cs-cal-corner--br { bottom: 6px !important; right: 6px !important; }
    .cs-cal-box-status { font-size: 7px !important; letter-spacing: 0.2em !important; bottom: 10px !important; }
}

@media (max-width: 520px) {
    .cs-cal-section { padding: 22px 12px !important; }
    .cs-cal-widget-wrap {
        max-width: calc(100vw - 24px) !important;
        width: calc(100vw - 24px) !important;
        min-height: 720px !important;
        border-radius: 10px !important;
    }
    .cs-cal-cal-wrap .calendly-inline-widget {
        height: 700px !important;
        min-height: 700px !important;
    }
    .cs-cal-logo-layer { border-radius: 10px !important; }
    .cs-cal-ghost-logo { width: 110px !important; height: 110px !important; }
}

@media (max-width: 380px) {
    .cs-cal-section { padding: 18px 8px !important; }
    .cs-cal-widget-wrap {
        max-width: calc(100vw - 16px) !important;
        width: calc(100vw - 16px) !important;
        min-height: 740px !important;
    }
    .cs-cal-cal-wrap .calendly-inline-widget {
        height: 720px !important;
        min-height: 720px !important;
    }
}

/* ── CELLSIOR OVERRIDE ──
   Strip the ambient glow layer so the CTA sits on plain #050505 and blends
   with the rest of the site. Keeps the glass widget, logo, and particles. */
.cs-cal-bg-glows,
.cs-cal-eclipse-wrap,
.cs-cal-edge-fade-top,
.cs-cal-edge-fade-bottom {
  display: none !important;
}
