/**
 * Landing theme — airtime mesh + WebGL plasma shader background.
 */
:root {
    --mm-air-bg: #0b0e14;
    --mm-air-mesh-blue: rgba(59, 130, 246, 0.15);
    --mm-air-mesh-purple: rgba(139, 92, 246, 0.1);
    --mm-air-mesh-pink: rgba(236, 72, 153, 0.05);
    --mm-air-shader-opacity: 1;
    --mm-air-glass: rgba(255, 255, 255, 0.05);
    --mm-air-border: rgba(255, 255, 255, 0.1);
    --mm-air-orange: #f47d31;
    --mm-air-blue: #3b82f6;
    --mm-air-text: #ffffff;
    --mm-air-text-secondary: rgba(255, 255, 255, 0.72);
}

html.mm-airtime-theme,
html.mm-airtime-theme body {
    background: transparent !important;
    background-image: none !important;
}

.mm-bg-mesh,
.bg-mesh {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 100dvh;
    max-height: 100dvh;
    z-index: 0;
    pointer-events: none;
    background:
        radial-gradient(ellipse at 20% 20%, var(--mm-air-mesh-blue) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, var(--mm-air-mesh-purple) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, var(--mm-air-mesh-pink) 0%, transparent 70%),
        var(--mm-air-bg);
}

.mm-shader-bg-canvas,
.shader-bg-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100dvh;
    max-height: 100dvh;
    z-index: 1;
    pointer-events: none;
    display: block;
    opacity: var(--mm-air-shader-opacity);
}

body.mm-airtime-theme > *:not(.mm-bg-mesh):not(.bg-mesh):not(.mm-shader-bg-canvas):not(.shader-bg-canvas):not(.mm-quote-popup-overlay):not(.mmbot-root):not(.mm-sub-toast):not(.mm-scroll-top) {
    position: relative;
    z-index: 2;
}

/* Keep chatbot fixed on the bottom-right above the shader stack. */
body.mm-airtime-theme .mmbot-root,
.mmbot-root {
    position: fixed !important;
    right: 1.25rem !important;
    left: auto !important;
    bottom: 1.25rem !important;
    z-index: 99999 !important;
}

body.mm-airtime-theme .mm-sub-toast {
    position: fixed !important;
    z-index: 1400 !important;
}

body.mm-airtime-theme .mm-scroll-top {
    position: fixed !important;
    z-index: 1500 !important;
}

/* Soften shell chrome so the animated mesh shows through */
body.mm-airtime-theme.member-shell #member-sidebar,
body.mm-airtime-theme.admin-shell #admin-sidebar {
    background: rgba(11, 14, 20, 0.78) !important;
}

body.mm-airtime-theme.member-shell > .flex,
body.mm-airtime-theme.admin-shell > .flex {
    background: transparent;
}

/* Quote popup (trading motivation) */
.mm-quote-popup-overlay {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    background: color-mix(in srgb, var(--mm-air-bg) 60%, transparent);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    opacity: 0;
    transition: opacity 0.35s ease;
    pointer-events: none;
}

.mm-quote-popup-overlay[hidden] {
    display: none !important;
    pointer-events: none !important;
}

.mm-quote-popup-overlay--visible {
    opacity: 1;
    pointer-events: auto;
}

.mm-quote-popup-card {
    position: relative;
    width: min(94vw, 460px);
    padding: 2.75rem 2rem 2rem;
    text-align: center;
    border-radius: 24px;
    border: 1px solid color-mix(in srgb, var(--mm-air-orange) 35%, var(--mm-air-border));
    background:
        linear-gradient(
            165deg,
            color-mix(in srgb, var(--mm-air-orange) 10%, var(--mm-air-glass)) 0%,
            var(--mm-air-glass) 45%,
            color-mix(in srgb, var(--mm-air-blue) 12%, var(--mm-air-glass)) 100%
        );
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.14),
        0 24px 80px rgba(0, 0, 0, 0.45),
        0 0 60px rgba(249, 115, 22, 0.12);
    overflow: hidden;
    transform: translateY(24px) scale(0.94);
    opacity: 0;
    transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.4s ease;
}

.mm-quote-popup-overlay--visible .mm-quote-popup-card {
    transform: translateY(0) scale(1);
    opacity: 1;
}

.mm-quote-popup-card__glow {
    position: absolute;
    inset: -40%;
    pointer-events: none;
    background: conic-gradient(
        from 0deg,
        transparent 0%,
        rgba(249, 115, 22, 0.14) 12%,
        transparent 28%,
        rgba(59, 130, 246, 0.12) 55%,
        transparent 70%,
        rgba(168, 85, 247, 0.1) 88%,
        transparent 100%
    );
    animation: mm-quote-glow-spin 14s linear infinite;
}

@keyframes mm-quote-glow-spin {
    to { transform: rotate(360deg); }
}

.mm-quote-popup-close {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    z-index: 2;
    width: 2.1rem;
    height: 2.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 1px solid var(--mm-air-border);
    background: var(--mm-air-glass);
    color: var(--mm-air-text-secondary);
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
    transition: color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.mm-quote-popup-close:hover {
    color: var(--mm-air-text);
    border-color: var(--mm-air-orange);
    transform: rotate(90deg);
}

.mm-quote-popup-orb {
    position: relative;
    z-index: 1;
    width: 118px;
    height: 118px;
    margin: 0 auto 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mm-quote-popup-orb img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    object-position: center;
    border-radius: 0;
    background: transparent;
    filter: drop-shadow(0 0 16px rgba(249, 115, 22, 0.5));
}

.mm-quote-popup-orb__ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 1px dashed color-mix(in srgb, var(--mm-air-orange) 65%, transparent);
    animation: mm-quote-ring-spin 9s linear infinite;
}

.mm-quote-popup-orb__ring--reverse {
    inset: 8px;
    border-color: color-mix(in srgb, var(--mm-air-blue) 60%, transparent);
    border-style: dotted;
    animation-direction: reverse;
    animation-duration: 6s;
}

@keyframes mm-quote-ring-spin {
    to { transform: rotate(360deg); }
}

.mm-quote-popup-eyebrow {
    position: relative;
    z-index: 1;
    margin-bottom: 0.9rem;
    font-size: 0.6875rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.28em;
    background: linear-gradient(90deg, var(--mm-air-orange), var(--mm-air-blue));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.mm-quote-popup-text {
    position: relative;
    z-index: 1;
    margin: 0 0 1rem;
    font-size: 1.125rem;
    font-weight: 600;
    line-height: 1.55;
    color: var(--mm-air-text);
}

.mm-quote-popup-author {
    position: relative;
    z-index: 1;
    margin-bottom: 1.5rem;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: var(--mm-air-text-secondary);
}

.mm-quote-popup-cta {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    min-height: 2.75rem;
    padding: 0.7rem 1.35rem;
    border-radius: 12px;
    border: 1px solid color-mix(in srgb, var(--mm-air-orange) 55%, transparent);
    background: linear-gradient(135deg, rgba(244, 125, 49, 0.92), rgba(234, 88, 12, 0.88));
    color: #fff;
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 10px 28px rgba(244, 125, 49, 0.28);
    transition: transform 0.2s ease, filter 0.2s ease;
}

.mm-quote-popup-cta:hover {
    transform: translateY(-1px);
    filter: brightness(1.05);
}

@media (max-width: 480px) {
    .mm-quote-popup-card {
        padding: 2.25rem 1.25rem 1.5rem;
    }

    .mm-quote-popup-text {
        font-size: 1rem;
    }
}
