/* =============================================
   YOVA Landing Page v2 — Glassmorphism Premium
   ============================================= */

/* ---------- CSS Variables ---------- */
:root {
    --bg-primary: #1a1a2e;
    --bg-secondary: #16213e;
    --bg-tertiary: #0f3460;

    --glass-bg: rgba(255, 255, 255, 0.06);
    --glass-bg-hover: rgba(255, 255, 255, 0.10);
    --glass-border: rgba(255, 255, 255, 0.10);
    --glass-border-hover: rgba(255, 255, 255, 0.18);

    --accent: #6366f1;
    --accent-light: #818cf8;
    --accent-secondary: #8b5cf6;

    --gradient-start: #E1306C;
    --gradient-mid: #ff2d6b;
    --gradient-end: #F77737;

    --text-primary: rgba(255, 255, 255, 0.95);
    --text-secondary: rgba(255, 255, 255, 0.6);
    --text-tertiary: rgba(255, 255, 255, 0.4);

    --radius-card: 16px;
    --radius-btn: 14px;
    --radius-small: 8px;

    --blur: 20px;
    --glow-accent: 0 0 30px rgba(99, 102, 241, 0.3);
    --glow-gradient: 0 0 40px rgba(225, 48, 108, 0.25);

    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ---------- Gradient Text ---------- */
.gradient-text {
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ---------- Glass Card Base ---------- */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--blur));
    -webkit-backdrop-filter: blur(var(--blur));
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-card);
    transition: var(--transition);
}

.glass-card:hover {
    background: var(--glass-bg-hover);
    border-color: var(--glass-border-hover);
}

/* ---------- Section Base ---------- */
.section-header {
    text-align: center;
    margin-bottom: 64px;
}

.section-tag {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--accent-light);
    margin-bottom: 16px;
    padding: 6px 16px;
    background: rgba(99, 102, 241, 0.12);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 100px;
}

.section-title {
    font-size: clamp(2rem, 5vw, 2.8rem);
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 16px;
    letter-spacing: -0.02em;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 560px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ---------- Scroll Reveal ---------- */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* =============================================
   NAVBAR
   ============================================= */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 16px 0;
    transition: var(--transition);
}

.navbar.scrolled {
    background: rgba(26, 26, 46, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    padding: 10px 0;
}

.navbar-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.navbar-logo {
    display: flex;
    align-items: flex-end;
    gap: 0;
}

.navbar-logo-img {
    height: 36px;
    width: auto;
}

.navbar-logo-text {
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    line-height: 1;
    margin-left: -7px;
    margin-bottom: -2px;
    color: var(--text-primary);
}

.navbar-links {
    display: flex;
    align-items: center;
    gap: 32px;
}

.navbar-links a {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: var(--transition);
}

.navbar-links a:hover {
    color: var(--text-primary);
}

.btn-nav-cta {
    padding: 8px 20px !important;
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end)) !important;
    color: white !important;
    border-radius: var(--radius-btn) !important;
    font-weight: 600 !important;
    font-size: 0.85rem !important;
}

.btn-nav-cta:hover {
    box-shadow: var(--glow-gradient);
    transform: translateY(-1px);
}

/* Mobile toggle */
.navbar-mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.navbar-mobile-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: var(--transition);
}

.navbar-mobile-menu {
    display: none;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 20px 24px;
    background: rgba(26, 26, 46, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
}

.navbar-mobile-menu a {
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.navbar-mobile-menu.open {
    display: flex;
}

@media (max-width: 768px) {
    .navbar-links {
        display: none;
    }

    .navbar-mobile-toggle {
        display: flex;
    }
}

/* =============================================
   HERO
   ============================================= */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 120px 24px 80px;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background: linear-gradient(160deg, var(--bg-primary) 0%, var(--bg-secondary) 40%, var(--bg-tertiary) 100%);
    z-index: 0;
}

#particles-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

/* Floating orbs */
.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.4;
    z-index: 0;
}

.orb-1 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, var(--accent) 0%, transparent 70%);
    top: -100px;
    right: -100px;
    animation: float-orb 15s ease-in-out infinite;
}

.orb-2 {
    width: 350px;
    height: 350px;
    background: radial-gradient(circle, var(--accent-secondary) 0%, transparent 70%);
    bottom: -50px;
    left: -100px;
    animation: float-orb 18s ease-in-out infinite reverse;
}

.orb-3 {
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, var(--gradient-start) 0%, transparent 70%);
    top: 40%;
    left: 60%;
    animation: float-orb 12s ease-in-out infinite 3s;
}

.orb-4 {
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, var(--gradient-end) 0%, transparent 70%);
    top: 20%;
    left: 10%;
    animation: float-orb 20s ease-in-out infinite 5s;
    opacity: 0.25;
}

@keyframes float-orb {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(30px, -20px) scale(1.05); }
    50% { transform: translate(-20px, 30px) scale(0.95); }
    75% { transform: translate(20px, 20px) scale(1.02); }
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 720px;
}

.hero-logo-wrapper {
    margin-bottom: 32px;
    display: flex;
    flex-direction: row;
    align-items: flex-end;
    justify-content: center;
    gap: 0;
}

.hero-logo {
    height: 190px;
    width: auto;
    filter: drop-shadow(0 0 30px rgba(225, 48, 108, 0.3));
    animation: logo-glow 3s ease-in-out infinite;
}

.hero-app-name {
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    line-height: 1;
    margin-left: -90px;
    margin-bottom: -2px;
    color: var(--text-primary);
}

@keyframes logo-glow {
    0%, 100% { filter: drop-shadow(0 0 20px rgba(225, 48, 108, 0.3)); }
    50% { filter: drop-shadow(0 0 40px rgba(225, 48, 108, 0.5)); }
}

.hero-title {
    font-size: clamp(2.5rem, 8vw, 4.2rem);
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin-bottom: 20px;
}

.hero-subtitle {
    font-size: clamp(1rem, 2.5vw, 1.2rem);
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 40px;
}

.hero-cta {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.store-badge,
.store-badge-large {
    display: inline-block;
    transition: var(--transition);
}

.store-badge:hover,
.store-badge-large:hover {
    transform: translateY(-2px);
    filter: brightness(1.15);
}

.store-badge .store-svg {
    height: 44px;
    width: auto;
}

.store-badge-large .store-svg {
    height: 52px;
    width: auto;
}

.hero-scroll-indicator {
    margin-top: 60px;
}

.scroll-line {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, var(--text-tertiary), transparent);
    margin: 0 auto;
    animation: scroll-pulse 2s ease-in-out infinite;
}

@keyframes scroll-pulse {
    0%, 100% { opacity: 0.5; transform: scaleY(1); }
    50% { opacity: 1; transform: scaleY(1.3); }
}

/* =============================================
   WHY YOVA — Sticky Phone + Scroll Panels
   ============================================= */
.why-section {
    padding: 120px 0 0;
    position: relative;
    overflow: visible;
}

.why-headline {
    text-align: center;
    margin-bottom: 40px;
    padding: 0 24px;
}

.why-headline h2 {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.03em;
}

/* --- Sticky Layout --- */
.why-sticky-wrap {
    display: flex;
    gap: 80px;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 48px;
    position: relative;
}

.why-phone-col {
    flex: 0 0 380px;
    position: relative;
}

.why-phone-sticky {
    position: sticky;
    top: calc(50vh - 290px);
    padding-bottom: 80px;
}

.why-panels-col {
    flex: 1;
    min-width: 0;
}

/* --- Demo phone inside why section --- */
.why-phone-sticky .demo-phone {
    transform: scale(0.95);
    transform-origin: top left;
}
.why-phone-sticky .demo-wrapper {
    margin: 0;
    padding: 0;
}
.why-phone-sticky .demo-phone-glow {
    display: none;
}
.why-phone-sticky .demo-hint {
    display: none;
}

/* --- Why Dots (hidden on desktop, shown on mobile) --- */
.why-dots {
    display: none;
}
.why-swipe-hint {
    display: none;
}

/* --- Mobile split text (hidden on desktop) --- */
.why-mobile-title,
.why-mobile-info {
    display: none;
}

/* --- Text Panels --- */
.why-panel {
    min-height: 80vh;
    display: flex;
    align-items: center;
    padding: 40px 0;
}

.why-panel:last-child {
    min-height: 60vh;
}

.why-panel-inner {
    max-width: 520px;
}

.why-panel-tag {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--gradient-start);
    margin-bottom: 20px;
    padding: 6px 14px;
    background: rgba(225, 48, 108, 0.08);
    border: 1px solid rgba(225, 48, 108, 0.15);
    border-radius: 100px;
}

.why-panel h3 {
    font-size: clamp(2.2rem, 4vw, 3.2rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin-bottom: 20px;
}

.why-panel p {
    font-size: 1.15rem;
    color: var(--text-secondary);
    line-height: 1.8;
}

/* Active panel highlight */
.why-panel.active .why-panel-inner {
    opacity: 1;
}

/* --- "Essaye maintenant" panel --- */
.why-panel-tag-accent {
    color: #6366f1;
    background: rgba(99, 102, 241, 0.1);
    border-color: rgba(99, 102, 241, 0.2);
}

.why-try-hint {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 24px;
    padding: 12px 16px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    font-size: 0.85rem;
    color: var(--text-tertiary);
    animation: why-hint-pulse 2s ease-in-out infinite;
}

@keyframes why-hint-pulse {
    0%, 100% { opacity: 0.7; }
    50% { opacity: 1; }
}

/* --- Chat ride button: small icon only in why section --- */
.why-phone-sticky .demo-chat-ride-btn span {
    display: none;
}
.why-phone-sticky .demo-chat-ride-btn {
    min-width: 28px;
    width: 28px;
    height: 28px;
    padding: 0;
    gap: 0;
    border-radius: 50%;
    justify-content: center;
}

/* --- Interactive mode: enable pointer events on cloned phone --- */
.why-phone-sticky .demo-phone {
    pointer-events: none;
}

.why-interactive .demo-phone {
    pointer-events: auto;
    cursor: pointer;
}

.why-interactive .demo-phone-frame {
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.3), 0 0 30px rgba(99, 102, 241, 0.15);
    transition: box-shadow 0.4s ease;
}

/* --- Responsive --- */
@media (max-width: 1200px) {
    .why-sticky-wrap {
        gap: 50px;
        padding: 0 32px;
    }
    .why-phone-col {
        flex: 0 0 320px;
    }
    .why-phone-sticky .demo-phone {
        transform: scale(0.82);
    }
}

@media (max-width: 1024px) {
    .why-sticky-wrap {
        gap: 40px;
    }
    .why-phone-col {
        flex: 0 0 280px;
    }
    .why-phone-sticky .demo-phone {
        transform: scale(0.72);
    }
}

@media (max-width: 768px) {
    .why-section {
        height: 100vh;
        height: 100dvh;
        padding: 0;
        overflow: hidden;
        display: flex;
        flex-direction: column;
    }
    .why-headline {
        display: none;
    }
    .why-sticky-wrap {
        flex: 1;
        min-height: 0;
        display: flex;
        flex-direction: column;
        padding: 0;
        gap: 0;
        width: 100%;
        overflow: visible;
    }
    .why-phone-col {
        flex: 1;
        min-height: 0;
        width: 100%;
        display: flex;
        justify-content: center;
        align-items: center;
        overflow: visible;
    }
    .why-phone-sticky {
        position: relative;
        top: auto;
        padding-bottom: 0;
        display: flex;
        justify-content: center;
        align-items: center;
    }
    .why-phone-sticky .demo-phone {
        transform: scale(0.55);
        transform-origin: center center;
    }
    .why-panels-col {
        display: none;
    }
    /* Mobile title — above phone */
    .why-mobile-title {
        display: flex;
        align-items: flex-end;
        justify-content: center;
        flex: none;
        text-align: center;
        padding: 70px 24px 12px;
        min-height: 120px;
    }
    .why-mobile-title h3 {
        font-size: clamp(1.5rem, 5vw, 2rem);
        font-weight: 800;
        line-height: 1.1;
        letter-spacing: -0.03em;
    }
    .why-mobile-title.fading { opacity: 0; transition: opacity 0.15s ease; }
    .why-mobile-title.visible { opacity: 1; transition: opacity 0.15s ease; }
    /* Mobile info — badge + desc below phone */
    .why-mobile-info {
        display: flex;
        flex-direction: column;
        align-items: center;
        flex: none;
        text-align: center;
        padding: 8px 24px 16px;
    }
    .why-mobile-info .why-panel-tag {
        margin-bottom: 6px;
    }
    .why-mobile-info p {
        font-size: 0.82rem;
        line-height: 1.4;
        color: var(--text-secondary);
    }
    .why-mobile-info.fading { opacity: 0; transition: opacity 0.15s ease; }
    .why-mobile-info.visible { opacity: 1; transition: opacity 0.15s ease; }
    /* Dots indicator — vertical on the right side of the phone */
    .why-dots {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 10px;
        position: absolute;
        right: 16px;
        top: 50%;
        transform: translateY(-50%);
        z-index: 10;
    }
    .why-dot {
        width: 8px;
        height: 8px;
        border-radius: 50%;
        background: rgba(255, 255, 255, 0.2);
        transition: var(--transition);
    }
    .why-dot.active {
        background: var(--gradient-start);
        box-shadow: 0 0 8px rgba(225, 48, 108, 0.4);
    }
    /* Swipe hint — hidden on mobile (vertical scroll replaces it) */
    .why-swipe-hint {
        display: none;
    }
}

@keyframes whySwipePulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

@keyframes whySwipeSlide {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(6px); }
}

/* =============================================
   FEATURES — Bento Grid
   ============================================= */
.features {
    padding: 120px 0;
    position: relative;
}

.features-bento {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 0;
}

.feature-span-2 {
    grid-column: span 2;
}

/* ---------- Feature Card Big ---------- */
.feature-card-big {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    cursor: default;
}

.feature-card-big:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3), var(--glow-accent);
}

.feature-card-visual {
    height: 220px;
    position: relative;
    overflow: hidden;
    background: linear-gradient(180deg, rgba(15, 15, 30, 0.6) 0%, rgba(15, 52, 96, 0.3) 100%);
    border-bottom: 1px solid var(--glass-border);
}

.feature-card-text {
    padding: 24px;
}

.feature-card-text h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: -0.01em;
}

.feature-card-text p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.feature-icon-small {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(139, 92, 246, 0.15));
    border-radius: 10px;
    border: 1px solid rgba(99, 102, 241, 0.2);
    margin-bottom: 14px;
}

.feature-icon-small svg {
    width: 18px;
    height: 18px;
    color: var(--accent-light);
}

/* ---------- Feature Mini Map ---------- */
.feature-mini-map {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.fmm-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
    background-size: 28px 28px;
}

.fmm-dot {
    position: absolute;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.5);
}

.fmm-av-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.fmm-dot::after {
    display: none;
}

.fmm-dot-1 { top: 28%; left: 65%; animation: rider-float 4s ease-in-out infinite; }
.fmm-dot-2 { top: 55%; left: 25%; animation: rider-float 5s ease-in-out infinite 1s; }
.fmm-dot-3 { top: 70%; left: 72%; animation: rider-float 3.5s ease-in-out infinite 0.5s; }

.fmm-dot-you {
    top: 42%; left: 48%;
    width: 26px;
    height: 26px;
    border-color: var(--gradient-start);
    box-shadow: 0 0 10px rgba(225, 48, 108, 0.5);
    z-index: 2;
}

.fmm-line {
    position: absolute;
    height: 1px;
    background: linear-gradient(90deg, rgba(99, 102, 241, 0.3), transparent);
    transform-origin: left center;
}

.fmm-line-1 {
    top: 42%;
    left: 48%;
    width: 80px;
    transform: rotate(-15deg);
}

.fmm-line-2 {
    top: 42%;
    left: 48%;
    width: 100px;
    transform: rotate(20deg);
    background: linear-gradient(90deg, rgba(225, 48, 108, 0.3), transparent);
}

@keyframes rider-float {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(3px, -4px); }
}

@keyframes ping {
    0% { transform: scale(1); opacity: 0.4; }
    100% { transform: scale(2.5); opacity: 0; }
}

/* ---------- Feature Mini Chat ---------- */
.feature-mini-chat {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    padding: 16px 14px;
    gap: 8px;
    justify-content: center;
}

.fmc-bubble {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 14px;
    font-size: 0.75rem;
    max-width: 85%;
    animation: chat-appear 0.4s ease-out both;
}

.fmc-bubble:nth-child(1) { animation-delay: 0.2s; }
.fmc-bubble:nth-child(2) { animation-delay: 0.6s; }
.fmc-bubble:nth-child(3) { animation-delay: 1s; }

.fmc-bubble-in {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.06);
    align-self: flex-start;
    border-bottom-left-radius: 4px;
}

.fmc-bubble-out {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.25), rgba(139, 92, 246, 0.2));
    border: 1px solid rgba(99, 102, 241, 0.2);
    align-self: flex-end;
    border-bottom-right-radius: 4px;
}

.fmc-lock {
    font-size: 0.6rem;
    opacity: 0.5;
}

.fmc-voice {
    display: flex;
    align-items: center;
    gap: 3px;
}

.fmc-voice-bar {
    width: 3px;
    height: 12px;
    background: var(--accent-light);
    border-radius: 2px;
    animation: voice-wave 1s ease-in-out infinite;
}

.fmc-voice-bar:nth-child(1) { height: 8px; animation-delay: 0s; }
.fmc-voice-bar:nth-child(2) { height: 14px; animation-delay: 0.1s; }
.fmc-voice-bar:nth-child(3) { height: 10px; animation-delay: 0.2s; }
.fmc-voice-bar:nth-child(4) { height: 16px; animation-delay: 0.15s; }
.fmc-voice-bar:nth-child(5) { height: 8px; animation-delay: 0.25s; }
.fmc-voice-bar:nth-child(6) { height: 12px; animation-delay: 0.3s; }
.fmc-voice-bar:nth-child(7) { height: 6px; animation-delay: 0.1s; }

.fmc-voice span {
    font-size: 0.65rem;
    color: var(--text-secondary);
    margin-left: 4px;
}

.fmc-bubble:has(.fmc-transcript-text) {
    flex-wrap: wrap;
}

.fmc-transcript-text {
    flex-basis: 100%;
    font-size: 0.55rem;
    color: var(--text-secondary);
    font-style: italic;
    line-height: 1.3;
}

.fmc-typing {
    display: flex;
    gap: 4px;
    align-self: flex-start;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 14px;
    animation: chat-appear 0.4s ease-out both;
    animation-delay: 1.4s;
}

.fmc-typing span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--text-secondary);
    animation: typing-dot 1.2s ease-in-out infinite;
}

.fmc-typing span:nth-child(2) { animation-delay: 0.2s; }
.fmc-typing span:nth-child(3) { animation-delay: 0.4s; }

.fmc-e2e-badge {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.6rem;
    color: #34d399;
    background: rgba(52, 211, 153, 0.1);
    border: 1px solid rgba(52, 211, 153, 0.2);
    padding: 3px 10px;
    border-radius: 100px;
    white-space: nowrap;
}

@keyframes chat-appear {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes voice-wave {
    0%, 100% { transform: scaleY(0.5); }
    50% { transform: scaleY(1); }
}

@keyframes typing-dot {
    0%, 100% { opacity: 0.3; transform: translateY(0); }
    50% { opacity: 1; transform: translateY(-3px); }
}

/* ---------- Feature Mini Call ---------- */
.feature-mini-call {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 16px;
}

.fmcall-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.fmcall-user {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    position: relative;
}

.fmcall-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 700;
    color: white;
}

.fmcall-user span {
    font-size: 0.7rem;
    color: var(--text-secondary);
}

.fmcall-user.speaking .fmcall-avatar {
    box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.5);
    animation: speaking-pulse 1.5s ease-in-out infinite;
}

.fmcall-av-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.fmcall-wave {
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: calc(100% - 48px);
    border-radius: 50%;
    border: 2px solid rgba(52, 211, 153, 0.3);
    animation: wave-expand 2s ease-out infinite;
}

.fmcall-ptt {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.fmcall-ptt-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent), var(--accent-secondary));
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.4);
    animation: ptt-glow 2s ease-in-out infinite;
}

.fmcall-ptt-btn svg {
    width: 20px;
    height: 20px;
    color: white;
}

.fmcall-ptt span {
    font-size: 0.65rem;
    color: var(--text-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

@keyframes speaking-pulse {
    0%, 100% { box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.5); }
    50% { box-shadow: 0 0 0 6px rgba(52, 211, 153, 0.2); }
}

@keyframes wave-expand {
    0% { transform: scale(1); opacity: 0.4; }
    100% { transform: scale(1.5); opacity: 0; }
}

@keyframes ptt-glow {
    0%, 100% { box-shadow: 0 0 15px rgba(99, 102, 241, 0.3); }
    50% { box-shadow: 0 0 30px rgba(99, 102, 241, 0.6); }
}

/* ---------- Feature Mini Geo ---------- */
.feature-mini-geo {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fmg-zone {
    position: relative;
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fmg-zone-ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 2px dashed rgba(99, 102, 241, 0.3);
    animation: zone-pulse 3s ease-in-out infinite;
}

.fmg-zone-ring-2 {
    inset: -16px;
    border-color: rgba(99, 102, 241, 0.15);
    animation-delay: 0.5s;
}

.fmg-zone-center {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--accent), var(--accent-secondary));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.4);
}

.fmg-zone-center svg {
    width: 18px;
    height: 18px;
}

.fmg-label {
    position: absolute;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.65rem;
    font-weight: 600;
    color: var(--accent-light);
    white-space: nowrap;
    background: rgba(99, 102, 241, 0.15);
    padding: 2px 8px;
    border-radius: 6px;
}

.fmg-rider-entering {
    position: absolute;
    bottom: 28%;
    right: 18%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    animation: rider-enter 4s ease-in-out infinite;
}

.fmg-rider-icon {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #34d399;
    box-shadow: 0 0 8px #34d399;
}

.fmg-notif {
    font-size: 0.6rem;
    background: rgba(52, 211, 153, 0.15);
    color: #34d399;
    padding: 2px 8px;
    border-radius: 6px;
    white-space: nowrap;
    animation: notif-appear 4s ease-in-out infinite;
}

@keyframes zone-pulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.05); opacity: 1; }
}

@keyframes rider-enter {
    0%, 20% { transform: translate(30px, 20px); opacity: 0; }
    40%, 70% { transform: translate(0, 0); opacity: 1; }
    90%, 100% { transform: translate(0, 0); opacity: 0; }
}

@keyframes notif-appear {
    0%, 35% { opacity: 0; transform: translateY(4px); }
    45%, 65% { opacity: 1; transform: translateY(0); }
    80%, 100% { opacity: 0; transform: translateY(-4px); }
}

/* ---------- Feature Mini Groups ---------- */
.feature-mini-groups {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    padding: 16px 14px;
    gap: 8px;
    justify-content: center;
}

.fmgrp-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.04);
}

.fmgrp-avatars {
    display: flex;
    margin-right: 2px;
}

.fmgrp-av {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.6rem;
    font-weight: 700;
    color: white;
    border: 2px solid var(--bg-primary);
    margin-left: -6px;
}

.fmgrp-av:first-child {
    margin-left: 0;
}

.fmgrp-count {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.55rem;
    font-weight: 700;
    color: var(--text-secondary);
    background: rgba(255, 255, 255, 0.08);
    border: 2px solid var(--bg-primary);
    margin-left: -6px;
}

.fmgrp-info {
    flex: 1;
    min-width: 0;
}

.fmgrp-info strong {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.fmgrp-info span {
    font-size: 0.65rem;
    color: var(--text-tertiary);
}

.fmgrp-live {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #34d399;
    box-shadow: 0 0 6px #34d399;
    animation: live-blink 2s ease-in-out infinite;
}

@keyframes live-blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

/* ---------- Feature Mini Poll (Sondages & RDV) ---------- */
.feature-mini-poll {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 20px 24px;
    gap: 10px;
}

.fmpoll-question {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.fmpoll-options {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.fmpoll-option {
    position: relative;
    display: flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    overflow: hidden;
}

.fmpoll-option.voted {
    border-color: rgba(99, 102, 241, 0.3);
}

.fmpoll-bar {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: var(--poll-width);
    background: linear-gradient(90deg, rgba(99, 102, 241, 0.15), rgba(139, 92, 246, 0.08));
    border-radius: 8px;
    animation: poll-fill 1.5s ease-out forwards;
    transform-origin: left;
}

@keyframes poll-fill {
    from { transform: scaleX(0); }
    to { transform: scaleX(1); }
}

.fmpoll-label {
    position: relative;
    z-index: 1;
    font-size: 0.75rem;
    color: var(--text-primary);
    flex: 1;
}

.fmpoll-pct {
    position: relative;
    z-index: 1;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--accent-light);
}

.fmpoll-rdv {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 8px;
    background: linear-gradient(135deg, rgba(225, 48, 108, 0.12), rgba(247, 119, 55, 0.08));
    border: 1px solid rgba(225, 48, 108, 0.2);
    font-size: 0.72rem;
    color: var(--text-secondary);
}

.fmpoll-rdv svg {
    color: var(--gradient-start);
    flex-shrink: 0;
}

/* ---------- Feature Mini Invite (QR Code) ---------- */
.feature-mini-invite {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    padding: 20px;
}

.fminv-qr {
    width: 100px;
    height: 100px;
    position: relative;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.fminv-qr-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
    width: 60px;
    height: 60px;
}

.fminv-qr-block {
    border-radius: 3px;
    animation: qr-flicker 3s ease-in-out infinite;
}

.fminv-qr-block.b1 { background: var(--accent-light); animation-delay: 0s; }
.fminv-qr-block.b2 { background: rgba(255,255,255,0.15); animation-delay: 0.2s; }
.fminv-qr-block.b3 { background: var(--accent-light); animation-delay: 0.4s; }
.fminv-qr-block.b4 { background: rgba(255,255,255,0.15); animation-delay: 0.1s; }
.fminv-qr-block.b5 { background: rgba(255,255,255,0.08); animation-delay: 0.3s; }
.fminv-qr-block.b6 { background: rgba(255,255,255,0.15); animation-delay: 0.5s; }
.fminv-qr-block.b7 { background: var(--accent-light); animation-delay: 0.2s; }
.fminv-qr-block.b8 { background: rgba(255,255,255,0.15); animation-delay: 0.4s; }
.fminv-qr-block.b9 { background: var(--accent-light); animation-delay: 0.6s; }

@keyframes qr-flicker {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.fminv-qr-logo {
    position: absolute;
    width: 24px;
    height: 24px;
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 900;
    color: white;
}

.fminv-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.fminv-link-icon {
    color: var(--accent-light);
    flex-shrink: 0;
}

.fminv-link span {
    font-size: 0.7rem;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.fminv-copy {
    font-size: 0.65rem;
    font-weight: 600;
    color: var(--accent-light);
    padding: 4px 10px;
    border-radius: 6px;
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.2);
    white-space: nowrap;
    flex-shrink: 0;
}

/* ---------- Feature Mini Vocal (Messages vocaux) ---------- */
.feature-mini-vocal {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    padding: 20px;
}

.fmvoc-waveform {
    display: flex;
    align-items: center;
    gap: 3px;
    height: 50px;
}

.fmvoc-bar {
    width: 4px;
    border-radius: 2px;
    background: linear-gradient(180deg, var(--accent-light), var(--accent-secondary));
    animation: vocal-wave 1.2s ease-in-out infinite;
}

.fmvoc-bar:nth-child(1)  { height: 20px; animation-delay: 0s; }
.fmvoc-bar:nth-child(2)  { height: 35px; animation-delay: 0.1s; }
.fmvoc-bar:nth-child(3)  { height: 25px; animation-delay: 0.2s; }
.fmvoc-bar:nth-child(4)  { height: 45px; animation-delay: 0.15s; }
.fmvoc-bar:nth-child(5)  { height: 30px; animation-delay: 0.25s; }
.fmvoc-bar:nth-child(6)  { height: 50px; animation-delay: 0.1s; }
.fmvoc-bar:nth-child(7)  { height: 35px; animation-delay: 0.3s; }
.fmvoc-bar:nth-child(8)  { height: 20px; animation-delay: 0.2s; }
.fmvoc-bar:nth-child(9)  { height: 40px; animation-delay: 0.05s; }
.fmvoc-bar:nth-child(10) { height: 28px; animation-delay: 0.35s; }
.fmvoc-bar:nth-child(11) { height: 15px; animation-delay: 0.15s; }
.fmvoc-bar:nth-child(12) { height: 22px; animation-delay: 0.25s; }

@keyframes vocal-wave {
    0%, 100% { transform: scaleY(1); }
    50% { transform: scaleY(0.4); }
}

.fmvoc-duration {
    font-size: 0.75rem;
    color: var(--text-tertiary);
    font-weight: 600;
}

.fmvoc-transcript {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.fmvoc-transcript-icon {
    color: var(--accent-light);
    flex-shrink: 0;
}

.fmvoc-transcript span {
    font-size: 0.7rem;
    color: var(--text-secondary);
    font-style: italic;
}

/* ---------- Feature Mini Sports (Multi-sport) ---------- */
.feature-mini-sports {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.fmsport-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    width: 100%;
    max-width: 220px;
}

.fmsport-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 12px 8px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    transition: var(--transition);
}

.fmsport-item.active {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(139, 92, 246, 0.1));
    border-color: rgba(99, 102, 241, 0.3);
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.15);
}

.fmsport-item span {
    font-size: 1.5rem;
}

.fmsport-item small {
    font-size: 0.6rem;
    color: var(--text-tertiary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.fmsport-item.active small {
    color: var(--accent-light);
}

/* ---------- Feature Mini Backgrounds (Fonds animés) ---------- */
.feature-mini-backgrounds {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 20px;
    overflow: hidden;
}

.fmbg-preview {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.2), rgba(118, 75, 162, 0.15));
    overflow: hidden;
}

.fmbg-particle {
    position: absolute;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(129, 140, 248, 0.6);
    animation: bg-float 4s ease-in-out infinite;
}

.fmbg-particle:nth-child(1) { top: 20%; left: 15%; animation-delay: 0s; }
.fmbg-particle:nth-child(2) { top: 60%; left: 80%; animation-delay: 0.5s; width: 4px; height: 4px; }
.fmbg-particle:nth-child(3) { top: 40%; left: 45%; animation-delay: 1s; width: 8px; height: 8px; }
.fmbg-particle:nth-child(4) { top: 75%; left: 25%; animation-delay: 1.5s; }
.fmbg-particle:nth-child(5) { top: 15%; left: 70%; animation-delay: 2s; width: 5px; height: 5px; }
.fmbg-particle:nth-child(6) { top: 85%; left: 55%; animation-delay: 0.8s; width: 3px; height: 3px; }
.fmbg-particle:nth-child(7) { top: 35%; left: 90%; animation-delay: 1.3s; }
.fmbg-particle:nth-child(8) { top: 55%; left: 10%; animation-delay: 2.5s; width: 7px; height: 7px; }

@keyframes bg-float {
    0%, 100% { transform: translateY(0) scale(1); opacity: 0.6; }
    50% { transform: translateY(-15px) scale(1.3); opacity: 1; }
}

.fmbg-label {
    position: relative;
    z-index: 1;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-primary);
    padding: 6px 14px;
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.fmbg-thumbnails {
    position: relative;
    z-index: 1;
    display: flex;
    gap: 8px;
}

.fmbg-thumb {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    transition: var(--transition);
    cursor: pointer;
}

.fmbg-thumb.active {
    border-color: white;
    box-shadow: 0 0 12px rgba(255, 255, 255, 0.3);
}

/* ---------- Feature Cards Responsive ---------- */
@media (max-width: 1024px) {
    .features-bento {
        grid-template-columns: repeat(2, 1fr);
    }
    .feature-span-2 {
        grid-column: span 2;
    }
}

@media (max-width: 600px) {
    .features-bento {
        grid-template-columns: 1fr;
    }
    .feature-span-2 {
        grid-column: span 1;
    }
    .feature-card-visual {
        height: 180px;
    }
}

/* =============================================
   INTERACTIVE DEMO
   ============================================= */
.demo {
    padding: 120px 0;
    position: relative;
}

.demo-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
}

/* Phone frame */
.demo-phone {
    position: relative;
}

.demo-phone-frame {
    width: 320px;
    height: 640px;
    background: #0d0d1a;
    border-radius: 44px;
    border: 3px solid rgba(255, 255, 255, 0.12);
    overflow: hidden;
    position: relative;
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.05),
        0 30px 80px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.demo-notch {
    width: 130px;
    height: 30px;
    background: #0d0d1a;
    border-radius: 0 0 18px 18px;
    margin: 0 auto;
    position: relative;
    z-index: 20;
}

.demo-screen {
    position: absolute;
    inset: 0;
    border-radius: 41px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    background: linear-gradient(180deg, #1a1a2e 0%, #0f3460 100%);
}

/* Status bar */
.demo-statusbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 24px 4px;
    font-size: 11px;
    font-weight: 600;
    position: relative;
    z-index: 15;
}

.demo-statusbar-right {
    display: flex;
    gap: 4px;
    align-items: center;
}

.demo-signal {
    width: 14px;
    height: 10px;
    background: linear-gradient(to right,
        white 18%, transparent 18% 22%,
        white 22% 38%, transparent 38% 42%,
        white 42% 58%, transparent 58% 62%,
        white 62% 78%, transparent 78% 82%,
        white 82%
    );
    opacity: 0.7;
    border-radius: 1px;
}

.demo-battery {
    width: 20px;
    height: 9px;
    border: 1.5px solid rgba(255, 255, 255, 0.7);
    border-radius: 2px;
    position: relative;
}

.demo-battery::after {
    content: '';
    position: absolute;
    right: -4px;
    top: 2px;
    width: 2px;
    height: 3px;
    background: rgba(255, 255, 255, 0.7);
    border-radius: 0 1px 1px 0;
}

.demo-battery::before {
    content: '';
    position: absolute;
    left: 2px;
    top: 2px;
    right: 3px;
    bottom: 2px;
    background: #34d399;
    border-radius: 1px;
}

/* ---------- Demo Pages ---------- */
.demo-page {
    display: none;
    flex-direction: column;
    flex: 1;
    position: absolute;
    top: 40px;
    left: 0;
    right: 0;
    bottom: 78px;
    overflow: hidden;
    animation: page-enter 0.3s ease-out;
}

.demo-page.active {
    display: flex;
}

.demo-page.exit-left {
    display: flex;
    animation: page-exit 0.3s ease-in forwards;
}

@keyframes page-enter {
    from { opacity: 0; transform: translateX(20px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes page-exit {
    from { opacity: 1; transform: translateX(0); }
    to { opacity: 0; transform: translateX(-20px); }
}

/* ---------- HOME Screen ---------- */

/* Avatar images (DiceBear) */
.demo-av-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

/* Sharing section card (shown after START RIDE) */
.demo-sharing-section {
    display: none;
    flex-direction: column;
    margin: 0;
    padding: 12px;
    background: rgba(30, 30, 50, 0.95);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    animation: modal-fade-in 0.3s ease;
}
.demo-sharing-section.active {
    display: flex;
}

.demo-sharing-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}
.demo-sharing-header-left {
    display: flex;
    align-items: center;
    gap: 6px;
}
.demo-sharing-pulse {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #10b981;
    animation: ride-pulse 1.2s ease-in-out infinite;
}
.demo-sharing-title {
    font-size: 0.75rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.95);
}
.demo-sharing-badge {
    background: rgba(16, 185, 129, 0.9);
    padding: 1px 7px;
    border-radius: 8px;
    font-size: 0.6rem;
    font-weight: 700;
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-shadow: 0 2px 6px rgba(16, 185, 129, 0.4);
}
.demo-sharing-stop-all {
    font-size: 0.6rem;
    font-weight: 600;
    color: #ef4444;
    padding: 4px 10px;
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 8px;
    cursor: pointer;
}
.demo-sharing-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.demo-sharing-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 8px 10px;
}
.demo-sharing-item-left {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 0;
}
.demo-sharing-item-av {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.55rem;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
}
.demo-sharing-item-name {
    font-size: 0.7rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.95);
    white-space: nowrap;
}
.demo-sharing-live-tiny {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #48A9A6;
    animation: ride-pulse 1.2s ease-in-out infinite;
    flex-shrink: 0;
}
.demo-sharing-item-members {
    font-size: 0.6rem;
    color: var(--text-tertiary);
    white-space: nowrap;
}
.demo-sharing-item-close {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(239, 68, 68, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 700;
    color: #ef4444;
    cursor: pointer;
    flex-shrink: 0;
    margin-left: 6px;
}

.demo-home-weather-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 4px 12px 0;
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    backdrop-filter: blur(10px);
}

.demo-home-avatar {
    width: 38px;
    height: 38px;
    min-width: 38px;
    border-radius: 19px;
    overflow: hidden;
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    border: 2px solid rgba(255, 255, 255, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 700;
    color: white;
}

.demo-home-weather-info {
    flex: 1;
    min-width: 0;
}

.demo-home-salut {
    font-size: 0.95rem;
    font-weight: 700;
    color: white;
}

.demo-home-weather-row {
    display: flex;
    align-items: center;
    gap: 3px;
    margin-top: 1px;
}

.demo-home-temp {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.demo-home-cond {
    font-size: 0.65rem;
    color: var(--text-tertiary);
}

.demo-home-sep {
    color: var(--text-tertiary);
    font-size: 0.65rem;
    margin: 0 1px;
}

.demo-home-loc {
    font-size: 0.65rem;
    color: var(--text-tertiary);
}

.demo-home-settings-btn {
    width: 34px;
    height: 34px;
    min-width: 34px;
    border-radius: 17px;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.demo-home-settings-btn svg {
    color: var(--text-secondary);
}

.demo-home-content {
    flex: 1;
    overflow-y: auto;
    scrollbar-width: none;
    padding: 10px 12px 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.demo-home-content::-webkit-scrollbar { display: none; }

/* Mini map */
.demo-home-minimap {
    position: relative;
    width: 100%;
    height: 140px;
    min-height: 140px;
    flex-shrink: 0;
    border-radius: 16px;
    overflow: hidden;
    background: #1a2332;
    cursor: pointer;
}

.demo-home-minimap-bg {
    position: absolute;
    inset: 0;
    background:
        /* Main roads */
        linear-gradient(25deg, transparent 48%, rgba(70,90,120,0.4) 48.5%, rgba(70,90,120,0.4) 49.5%, transparent 50%),
        linear-gradient(130deg, transparent 30%, rgba(60,80,110,0.3) 30.5%, rgba(60,80,110,0.3) 31.5%, transparent 32%),
        linear-gradient(80deg, transparent 60%, rgba(55,75,100,0.25) 60.5%, rgba(55,75,100,0.25) 61%, transparent 61.5%),
        /* Secondary roads */
        linear-gradient(170deg, transparent 20%, rgba(50,65,90,0.2) 20.3%, rgba(50,65,90,0.2) 20.6%, transparent 20.9%),
        linear-gradient(-30deg, transparent 55%, rgba(50,65,90,0.2) 55.3%, rgba(50,65,90,0.2) 55.6%, transparent 55.9%),
        linear-gradient(60deg, transparent 75%, rgba(50,65,90,0.2) 75.3%, rgba(50,65,90,0.2) 75.6%, transparent 75.9%),
        /* Terrain areas */
        radial-gradient(ellipse at 20% 40%, rgba(34,60,50,0.35) 0%, transparent 50%),
        radial-gradient(ellipse at 70% 25%, rgba(34,60,50,0.25) 0%, transparent 40%),
        radial-gradient(ellipse at 50% 70%, rgba(30,45,55,0.3) 0%, transparent 45%),
        /* Base */
        linear-gradient(180deg, #1a2332 0%, #1e2b3d 50%, #1a2535 100%);
}

/* minimap-bg already styled above */

.demo-minimap-avatar {
    position: absolute;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.4);
    overflow: hidden;
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.5);
}
.demo-minimap-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}
.demo-minimap-you {
    width: 26px;
    height: 26px;
    border-color: var(--gradient-start);
    box-shadow: 0 0 10px rgba(225, 48, 108, 0.5);
    z-index: 2;
}

/* QUI RIDE section */
.demo-home-qui-ride {
    background: #1a1a2e;
    border-radius: 16px;
    padding: 10px;
    border: 1.5px solid rgba(139, 92, 246, 0.25);
}

.demo-home-qui-ride-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 6px;
}

.demo-home-qui-ride-icon {
    width: 26px;
    height: 26px;
    min-width: 26px;
    border-radius: 8px;
    background: linear-gradient(135deg, #8b5cf6, #6366f1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.demo-home-qui-ride-title {
    flex: 1;
    font-size: 0.85rem;
    font-weight: 700;
    color: white;
}

.demo-home-qui-ride-count {
    background: rgba(99, 102, 241, 0.2);
    border-radius: 14px;
    padding: 3px 10px;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--accent-light);
}

/* Rider group inside QUI RIDE */
.demo-home-rider-group {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 6px;
}

.demo-home-rider-group-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
}

.demo-home-rg-avatar {
    width: 30px;
    height: 30px;
    min-width: 30px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 700;
    color: white;
}

.demo-home-rg-name {
    font-size: 0.8rem;
    font-weight: 600;
    color: white;
    flex: 1;
}

.demo-home-rg-count {
    font-size: 0.6rem;
    color: var(--text-tertiary);
}

.demo-home-rider-card {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 6px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    cursor: pointer;
    transition: var(--transition);
    margin-top: 3px;
}

.demo-home-rider-card:hover {
    background: rgba(255, 255, 255, 0.1);
}

.demo-home-rider-avatar {
    width: 24px;
    height: 24px;
    min-width: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 700;
    color: white;
}

.demo-home-rider-info {
    flex: 1;
}

.demo-home-rider-info strong {
    font-size: 0.8rem;
    font-weight: 600;
}

.demo-home-rider-speed {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.6rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.demo-home-speed-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
}

.demo-home-speed-dot.active {
    background: #10b981;
}

.demo-home-speed-dot.stopped {
    background: #f59e0b;
}

/* ---------- Map Screen ---------- */
.demo-map-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 18px;
}

.demo-map-header h3 {
    font-size: 1.1rem;
    font-weight: 700;
}

.demo-map-live-badge {
    font-size: 0.6rem;
    font-weight: 700;
    color: #34d399;
    background: rgba(52, 211, 153, 0.15);
    padding: 3px 10px;
    border-radius: 100px;
    letter-spacing: 1px;
    animation: live-blink 2s ease-in-out infinite;
}

.demo-map-area {
    flex: 1;
    position: relative;
    margin: 4px 12px;
    border-radius: 16px;
    overflow: hidden;
}

.demo-map-bg {
    position: absolute;
    inset: 0;
    background:
        /* Main roads */
        linear-gradient(25deg, transparent 44%, rgba(70,90,120,0.5) 44.5%, rgba(70,90,120,0.5) 45.5%, transparent 46%),
        linear-gradient(130deg, transparent 25%, rgba(60,80,110,0.4) 25.5%, rgba(60,80,110,0.4) 26.5%, transparent 27%),
        linear-gradient(80deg, transparent 55%, rgba(55,75,100,0.35) 55.5%, rgba(55,75,100,0.35) 56%, transparent 56.5%),
        linear-gradient(-15deg, transparent 65%, rgba(60,80,110,0.3) 65.3%, rgba(60,80,110,0.3) 65.8%, transparent 66.3%),
        /* Secondary roads */
        linear-gradient(170deg, transparent 15%, rgba(50,65,90,0.25) 15.3%, rgba(50,65,90,0.25) 15.6%, transparent 15.9%),
        linear-gradient(-30deg, transparent 50%, rgba(50,65,90,0.25) 50.3%, rgba(50,65,90,0.25) 50.6%, transparent 50.9%),
        linear-gradient(60deg, transparent 70%, rgba(50,65,90,0.25) 70.3%, rgba(50,65,90,0.25) 70.6%, transparent 70.9%),
        linear-gradient(110deg, transparent 35%, rgba(50,65,90,0.2) 35.3%, rgba(50,65,90,0.2) 35.6%, transparent 35.9%),
        /* Terrain / park areas */
        radial-gradient(ellipse at 25% 35%, rgba(34,60,50,0.4) 0%, transparent 35%),
        radial-gradient(ellipse at 65% 20%, rgba(34,60,50,0.3) 0%, transparent 30%),
        radial-gradient(ellipse at 45% 65%, rgba(30,50,55,0.35) 0%, transparent 40%),
        radial-gradient(ellipse at 80% 75%, rgba(34,55,50,0.25) 0%, transparent 30%),
        /* Water */
        radial-gradient(ellipse at 15% 80%, rgba(25,45,75,0.3) 0%, transparent 25%),
        /* Base */
        linear-gradient(180deg, #1a2332 0%, #1e2b3d 50%, #1a2535 100%);
}

/* Map markers - avatar + speed callout */
.demo-map-marker {
    position: absolute;
    z-index: 5;
    display: flex;
    flex-direction: column;
    align-items: center;
    transform: translate(-50%, -100%);
}

.demo-map-marker-bubble {
    display: flex;
    align-items: center;
    gap: 5px;
    background: #1e1e3f;
    border-radius: 20px;
    padding: 3px 8px 3px 3px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    white-space: nowrap;
}

.demo-map-marker-av {
    width: 26px;
    height: 26px;
    min-width: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.6rem;
    font-weight: 700;
    color: white;
    border: 2px solid;
}

.demo-map-marker-info {
    display: flex;
    flex-direction: column;
    padding-right: 2px;
}

.demo-map-marker-name {
    font-size: 0.6rem;
    font-weight: 600;
    color: white;
    line-height: 1.2;
}

.demo-map-marker-speed {
    display: flex;
    align-items: center;
    gap: 3px;
    font-size: 0.5rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.7);
}

.demo-marker-speed-dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
}

.demo-map-marker-pointer {
    width: 8px;
    height: 8px;
    background: #1e1e3f;
    transform: rotate(45deg);
    margin-top: -5px;
    box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

/* You marker (highlighted) */
.demo-map-marker-you {
    z-index: 10;
}

.you-bubble {
    background: linear-gradient(135deg, rgba(225, 48, 108, 0.4), rgba(247, 119, 55, 0.4));
    border: 1px solid rgba(225, 48, 108, 0.5);
    box-shadow: 0 2px 14px rgba(225, 48, 108, 0.3);
}

.you-av {
    background: linear-gradient(135deg, #e1306c, #f77737) !important;
    border-color: #ef4444 !important;
}

.you-pointer {
    background: linear-gradient(135deg, rgba(225, 48, 108, 0.4), rgba(247, 119, 55, 0.4));
}

.demo-map-zone {
    position: absolute;
    top: 15%;
    right: 10%;
    width: 80px;
    height: 80px;
    border: 1.5px dashed rgba(99, 102, 241, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(99, 102, 241, 0.05);
}

.demo-map-zone span {
    font-size: 0.6rem;
    color: var(--accent-light);
    font-weight: 500;
}

.demo-map-toast {
    position: absolute;
    bottom: 16px;
    left: 12px;
    right: 12px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 10px 16px;
    font-size: 0.75rem;
    color: var(--text-primary);
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 10;
}

.demo-map-toast.show {
    transform: translateY(0);
    opacity: 1;
}

.demo-map-toast strong {
    color: var(--accent-light);
}

/* ---------- Geofence Zone Overlay ---------- */
.demo-geofence-overlay {
    position: absolute;
    inset: 0;
    z-index: 8;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.5s ease;
    display: flex;
    flex-direction: column;
}

.demo-geofence-overlay.show {
    opacity: 1;
}

/* Zone circles on map */
.demo-geofence-zone {
    position: absolute;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.demo-geofence-ring {
    width: 90px;
    height: 90px;
    border-radius: 50%;
}

.demo-geofence-ring.active {
    border: 2px solid rgba(79, 172, 254, 0.6);
    background: rgba(79, 172, 254, 0.1);
}

.demo-geofence-ring.inactive {
    width: 60px;
    height: 60px;
    border: 1.5px dashed rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.03);
}

.demo-geofence-zone.small .demo-geofence-ring {
    width: 55px;
    height: 55px;
}

.demo-geofence-pulse {
    position: absolute;
    width: 90px;
    height: 90px;
    border-radius: 50%;
    border: 2px solid rgba(79, 172, 254, 0.3);
    animation: geofence-pulse 2s ease-out infinite;
}

@keyframes geofence-pulse {
    0% { transform: scale(1); opacity: 0.6; }
    100% { transform: scale(1.8); opacity: 0; }
}

.demo-geofence-label {
    margin-top: 6px;
    font-size: 0.5rem;
    font-weight: 700;
    color: #4facfe;
    letter-spacing: 0.5px;
    white-space: nowrap;
    text-shadow: 0 1px 4px rgba(0,0,0,0.8);
}

.demo-geofence-label.inactive {
    color: rgba(255, 255, 255, 0.35);
}

/* Hide map clutter when geofence overlay is active */
.demo-geofence-overlay.show ~ .demo-map-toast,
.demo-geofence-overlay.show ~ .demo-map-area .demo-map-marker,
.demo-geofence-overlay.show ~ .demo-map-area .demo-map-marker-bubble {
    opacity: 0 !important;
    transition: opacity 0.3s ease;
}

/* Also hide via parent: when overlay.show exists, fade out map header + markers + zone labels */
.demo-page-map:has(.demo-geofence-overlay.show) .demo-map-header,
.demo-page-map:has(.demo-geofence-overlay.show) .demo-map-marker,
.demo-page-map:has(.demo-geofence-overlay.show) .demo-map-zone,
.demo-page-map:has(.demo-geofence-overlay.show) .demo-map-toast {
    opacity: 0;
    transition: opacity 0.3s ease;
}


/* Dedicated header for zones mode */
.demo-geofence-overlay::before {
    content: 'Mes zones automatiques';
    display: block;
    padding: 8px 18px;
    font-size: 0.8rem;
    font-weight: 700;
    color: #fff;
    opacity: 0;
    transition: opacity 0.4s ease 0.1s;
}

.demo-geofence-overlay.show::before {
    opacity: 1;
}

/* Bottom panel: zone list */
.demo-geofence-panel {
    position: absolute;
    bottom: 8px;
    left: 8px;
    right: 8px;
    background: rgba(26, 26, 46, 0.92);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 12px 12px 8px;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1) 0.2s;
}

.demo-geofence-overlay.show .demo-geofence-panel {
    transform: translateY(0);
}

.demo-geofence-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    padding: 0 4px;
}

.demo-geofence-panel-header strong {
    font-size: 0.7rem;
    font-weight: 700;
    color: #fff;
}

.demo-geofence-panel-add {
    font-size: 0.6rem;
    font-weight: 600;
    color: #4facfe;
}

/* Zone list items */
.demo-geofence-panel-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 10px;
    border-radius: 12px;
    margin-bottom: 4px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.demo-geofence-panel-item.active {
    background: rgba(79, 172, 254, 0.1);
    border-color: rgba(79, 172, 254, 0.15);
}

.demo-geofence-item-left {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.demo-geofence-item-icon {
    width: 28px;
    height: 28px;
    min-width: 28px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.4);
}

.demo-geofence-item-icon.active {
    background: rgba(79, 172, 254, 0.15);
    color: #4facfe;
}

.demo-geofence-item-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.demo-geofence-item-info strong {
    font-size: 0.62rem;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.demo-geofence-item-info span {
    font-size: 0.5rem;
    color: var(--text-tertiary);
}

.demo-geofence-panel-item.active .demo-geofence-item-info span {
    color: #43e97b;
}

/* Toggle switch */
.demo-geofence-toggle {
    width: 32px;
    height: 18px;
    min-width: 32px;
    border-radius: 9px;
    background: rgba(255, 255, 255, 0.12);
    position: relative;
    transition: background 0.2s;
}

.demo-geofence-toggle.on {
    background: #4facfe;
}

.demo-geofence-toggle-dot {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #fff;
    transition: transform 0.2s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.demo-geofence-toggle.on .demo-geofence-toggle-dot {
    transform: translateX(14px);
}

/* ---------- Shared: Big title header ---------- */
.demo-big-title {
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: -0.3px;
}

.demo-header-btns {
    display: flex;
    gap: 6px;
}

.demo-header-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.demo-header-btn:hover {
    background: rgba(255, 255, 255, 0.15);
}

.demo-header-btn svg {
    color: var(--text-secondary);
}

/* Shared search bar */
.demo-search-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 14px 8px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 14px;
}

.demo-search-bar svg {
    color: var(--text-tertiary);
    flex-shrink: 0;
}

.demo-search-bar span {
    font-size: 0.78rem;
    color: var(--text-tertiary);
}

/* Shared speed dot */
.demo-speed-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
}

.demo-speed-dot.green {
    background: #10b981;
}

/* ---------- Friends Screen ---------- */
.demo-friends-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 16px 2px;
}

.demo-friends-list {
    flex: 1;
    overflow-y: auto;
    scrollbar-width: none;
    padding: 0 10px;
}
.demo-friends-list::-webkit-scrollbar { display: none; }

.demo-friend-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 6px;
    height: 68px;
    border-radius: 12px;
    cursor: pointer;
    transition: var(--transition);
    box-sizing: border-box;
}

.demo-friend-item:hover {
    background: rgba(255, 255, 255, 0.04);
}

.demo-friend-av-wrap {
    position: relative;
    flex-shrink: 0;
}

.demo-friend-avatar {
    width: 50px;
    height: 50px;
    min-width: 50px;
    border-radius: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    font-weight: 700;
    color: white;
}

.demo-friend-live-dot {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #10b981;
    border: 2.5px solid #1a1a2e;
}

.demo-friend-sport-badge {
    position: absolute;
    top: -2px;
    right: -2px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: rgba(26, 26, 46, 0.9);
    border: 1.5px solid rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.55rem;
    line-height: 1;
}

.demo-friend-info {
    flex: 1;
    min-width: 0;
}

.demo-friend-name-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.demo-friend-name-row strong {
    font-size: 0.9rem;
    font-weight: 600;
}

.demo-friend-unread {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #ef4444;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.55rem;
    font-weight: 700;
    color: white;
    box-shadow: 0 0 6px rgba(239, 68, 68, 0.4);
}

.demo-friend-speed-row {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 1px;
}

.demo-friend-speed-row span {
    font-size: 0.65rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.demo-friend-preview {
    font-size: 0.7rem;
    color: var(--text-tertiary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 1px;
}

.demo-friend-time {
    margin-left: 6px;
    font-size: 0.6rem;
    color: var(--text-tertiary);
}

/* ---------- Chat Screen ---------- */
.demo-chat-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    background: rgba(26, 26, 46, 0.95);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.demo-chat-back {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0.6;
    transition: var(--transition);
    flex-shrink: 0;
}

.demo-chat-back:hover {
    opacity: 1;
}

.demo-chat-back svg {
    width: 18px;
    height: 18px;
}

.demo-chat-avatar-header {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 700;
    color: white;
}

.demo-chat-title {
    flex: 1;
    min-width: 0;
}

.demo-chat-title strong {
    display: block;
    font-size: 0.85rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.demo-chat-e2e {
    font-size: 0.6rem;
    color: #34d399;
}

.demo-chat-header-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.demo-chat-walkie-btn,
.demo-chat-video-btn,
.demo-chat-call-btn,
.demo-chat-menu-btn {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
}

.demo-chat-walkie-btn:hover,
.demo-chat-video-btn:hover,
.demo-chat-call-btn:hover,
.demo-chat-menu-btn:hover {
    background: rgba(255, 255, 255, 0.15);
}

.demo-chat-call-btn svg {
    width: 14px;
    height: 14px;
    color: #34d399;
}

.demo-chat-video-btn svg {
    width: 14px;
    height: 14px;
    color: #818cf8;
}

.demo-chat-walkie-btn svg {
    color: var(--accent-light);
}

.demo-chat-menu-btn svg {
    width: 14px;
    height: 14px;
    color: var(--text-secondary);
}

.demo-chat-messages {
    flex: 1;
    overflow-y: auto;
    scrollbar-width: none;
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    gap: 10px;
}
.demo-chat-messages::-webkit-scrollbar { display: none; }

.demo-msg {
    display: flex;
    gap: 8px;
    max-width: 85%;
}

.demo-msg-in {
    align-self: flex-start;
}

.demo-msg-out {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.demo-msg-avatar {
    width: 28px;
    height: 28px;
    min-width: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 700;
    color: white;
    margin-top: 2px;
}

.demo-msg-body {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 16px 16px 16px 4px;
    padding: 8px 12px;
}

.demo-msg-out .demo-msg-body {
    background: #6366f1;
    border-radius: 16px 16px 4px 16px;
}

.demo-msg-name {
    display: block;
    font-size: 0.65rem;
    font-weight: 600;
    color: var(--accent-light);
    margin-bottom: 2px;
}

.demo-msg-body p {
    font-size: 0.8rem;
    line-height: 1.4;
}

.demo-msg-time {
    display: block;
    font-size: 0.6rem;
    color: var(--text-tertiary);
    margin-top: 3px;
    text-align: right;
}

.demo-msg-out .demo-msg-time {
    color: rgba(255, 255, 255, 0.6);
}

/* Chat bubble — outgoing */
.demo-msg-out-wrap {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}
.demo-msg-bubble-out {
    background: #6366f1;
    border-radius: 16px 16px 4px 16px;
    padding: 8px 12px;
    font-size: 0.8rem;
    line-height: 1.4;
    color: #fff;
}

/* Chat bubble — incoming (plain text) */
.demo-msg-bubble-in {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 16px 16px 16px 4px;
    padding: 8px 12px;
    font-size: 0.8rem;
    line-height: 1.4;
    color: #fff;
}

/* Poll message — wider */
.demo-msg:has(.demo-msg-poll) {
    max-width: 95%;
}

/* Voice message */
.demo-msg-voice {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 0;
}

.demo-voice-play {
    font-size: 0.7rem;
    color: var(--accent-light);
    cursor: pointer;
}

.demo-voice-waves {
    display: flex;
    align-items: center;
    gap: 2px;
}

.demo-voice-waves span {
    width: 3px;
    border-radius: 2px;
    background: var(--accent-light);
    animation: voice-wave 1s ease-in-out infinite;
}

.demo-voice-waves span:nth-child(1) { height: 8px; animation-delay: 0s; }
.demo-voice-waves span:nth-child(2) { height: 14px; animation-delay: 0.1s; }
.demo-voice-waves span:nth-child(3) { height: 10px; animation-delay: 0.2s; }
.demo-voice-waves span:nth-child(4) { height: 16px; animation-delay: 0.15s; }
.demo-voice-waves span:nth-child(5) { height: 8px; animation-delay: 0.25s; }
.demo-voice-waves span:nth-child(6) { height: 12px; animation-delay: 0.3s; }
.demo-voice-waves span:nth-child(7) { height: 6px; animation-delay: 0.1s; }
.demo-voice-waves span:nth-child(8) { height: 10px; animation-delay: 0.2s; }

.demo-voice-dur {
    font-size: 0.65rem;
    color: var(--text-secondary);
}

/* Voice message with transcription */
.demo-msg-voice-transcript {
    margin-top: 4px;
    padding: 4px 8px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 8px;
    border-left: 2px solid var(--accent-light);
}

.demo-voice-transcript-label {
    display: flex;
    align-items: center;
    gap: 3px;
    font-size: 0.5rem;
    font-weight: 600;
    color: var(--accent-light);
    margin-bottom: 2px;
    letter-spacing: 0.3px;
}

.demo-voice-transcript-text {
    font-size: 0.7rem;
    color: var(--text-secondary);
    font-style: italic;
    line-height: 1.3;
}

/* Chat input */
.demo-chat-input {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 10px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.demo-chat-plus-btn {
    width: 30px;
    height: 30px;
    min-width: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #4281A4;
    border-radius: 50%;
    cursor: pointer;
}

.demo-chat-plus-btn svg {
    color: white;
}

.demo-chat-ride-btn {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 6px 10px;
    background: #10b981;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 700;
    color: white;
    cursor: pointer;
    white-space: nowrap;
    transition: var(--transition);
}

.demo-chat-ride-btn svg {
    flex-shrink: 0;
}

.demo-chat-ride-btn:hover {
    background: #059669;
}

.demo-chat-input-field {
    flex: 1;
    padding: 7px 12px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    font-size: 0.72rem;
    color: var(--text-tertiary);
    min-width: 0;
}

.demo-chat-send {
    width: 30px;
    height: 30px;
    min-width: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--accent-light);
    border-radius: 50%;
    cursor: pointer;
}

.demo-chat-send svg {
    width: 13px;
    height: 13px;
    color: white;
}

/* ---------- Group Screen ---------- */
.demo-group-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 16px 2px;
}

/* Discover banner */
.demo-group-discover {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 6px 14px 8px;
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 16px;
    cursor: pointer;
    transition: var(--transition);
}

.demo-group-discover:hover {
    background: rgba(255, 255, 255, 0.12);
}

.demo-group-discover-icon {
    width: 34px;
    height: 34px;
    min-width: 34px;
    border-radius: 10px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    display: flex;
    align-items: center;
    justify-content: center;
}

.demo-group-discover-text {
    flex: 1;
}

.demo-group-discover-text strong {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: white;
}

.demo-group-discover-text span {
    font-size: 0.65rem;
    color: var(--text-tertiary);
}

.demo-group-discover svg:last-child {
    color: var(--text-tertiary);
}

.demo-group-list {
    flex: 1;
    overflow-y: auto;
    scrollbar-width: none;
    padding: 0 10px;
}
.demo-group-list::-webkit-scrollbar { display: none; }

.demo-group-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 6px;
    height: 68px;
    border-radius: 12px;
    cursor: pointer;
    transition: var(--transition);
    box-sizing: border-box;
}

.demo-group-item:hover {
    background: rgba(255, 255, 255, 0.04);
}

.demo-group-av-wrap {
    position: relative;
    flex-shrink: 0;
}

.demo-group-avatar {
    width: 48px;
    height: 48px;
    min-width: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    font-weight: 700;
    color: white;
}

.demo-group-live-dot {
    position: absolute;
    bottom: -1px;
    right: -1px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #10b981;
    border: 2.5px solid #1a1a2e;
}

.demo-group-info {
    flex: 1;
    min-width: 0;
}

.demo-group-name-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.demo-group-name-row strong {
    font-size: 0.9rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.demo-group-unread {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #ef4444;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.55rem;
    font-weight: 700;
    color: white;
    box-shadow: 0 0 6px rgba(239, 68, 68, 0.4);
    flex-shrink: 0;
}

.demo-group-riding-row {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 1px;
}

.demo-group-riding-row span {
    font-size: 0.65rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.demo-group-preview {
    font-size: 0.7rem;
    color: var(--text-tertiary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 1px;
}

.demo-group-sender {
    font-weight: 500;
    color: var(--text-secondary);
}

.demo-group-time {
    margin-left: 6px;
    font-size: 0.6rem;
    color: var(--text-tertiary);
}

/* IN RIDE badge */
.demo-group-inride-badge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    background: #10b981;
    color: white;
    font-size: 0.5rem;
    font-weight: 700;
    padding: 1px 6px;
    border-radius: 6px;
    letter-spacing: 0.5px;
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.5);
    margin-left: 4px;
    flex-shrink: 0;
}

.demo-inride-dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: white;
}

/* ---- Special messages: Je Ride, RDV, Sondage, Event ---- */
.demo-msg-special {
    display: flex;
    align-items: center;
    gap: 6px;
}

.demo-msg-special-out {
    justify-content: flex-end;
}

/* Je Ride status message */
.demo-msg-ride-status {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 14px;
    font-size: 0.72rem;
    font-weight: 600;
    color: white;
}

.demo-msg-ride-status.active {
    background: linear-gradient(135deg, #34C759, #30D158);
    box-shadow: 0 2px 10px rgba(52, 199, 89, 0.3);
}

.demo-msg-ride-status.inactive {
    background: linear-gradient(135deg, #8E8E93, #AEAEB2);
}

.demo-ride-status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: white;
    animation: ride-pulse 1.5s ease-in-out infinite;
}

@keyframes ride-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.7); }
}

.demo-ride-join-btn {
    background: rgba(255, 255, 255, 0.25);
    padding: 3px 10px;
    border-radius: 10px;
    font-size: 0.6rem;
    font-weight: 600;
    cursor: pointer;
    margin-left: 4px;
}

/* RDV message */
.demo-msg-rdv {
    background: linear-gradient(135deg, #4281A4, #48A9A6);
    border-radius: 12px;
    padding: 8px 10px;
    margin-top: 4px;
}

.demo-msg-out .demo-msg-rdv {
    background: linear-gradient(135deg, #6366f1, #818cf8);
    border-radius: 16px 16px 4px 16px;
}

.demo-rdv-header {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.55rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.8);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.demo-rdv-title {
    font-size: 0.78rem;
    font-weight: 700;
    color: white;
    margin-bottom: 6px;
}

.demo-rdv-actions {
    display: flex;
    gap: 6px;
}

.demo-rdv-action {
    display: flex;
    align-items: center;
    gap: 3px;
    font-size: 0.6rem;
    color: white;
    background: rgba(255, 255, 255, 0.2);
    padding: 3px 8px;
    border-radius: 8px;
    cursor: pointer;
}

/* Sondage message */
.demo-msg-poll {
    background: rgba(255, 149, 0, 0.08);
    border: 1px solid rgba(255, 149, 0, 0.2);
    border-radius: 12px;
    padding: 8px 10px;
    margin-top: 4px;
}

.demo-poll-header {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.55rem;
    font-weight: 700;
    color: #FF9500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.demo-poll-question {
    font-size: 0.78rem;
    font-weight: 700;
    color: white;
    margin-bottom: 6px;
}

.demo-poll-option {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 8px;
    padding: 5px 8px;
    margin-bottom: 3px;
    overflow: hidden;
    font-size: 0.65rem;
}

.demo-poll-bar {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    background: rgba(255, 149, 0, 0.15);
    border-radius: 8px;
    transition: width 0.5s ease;
}

.demo-poll-option.voted .demo-poll-bar {
    background: rgba(255, 149, 0, 0.25);
}

.demo-poll-label {
    position: relative;
    z-index: 1;
    color: var(--text-secondary);
    font-weight: 500;
}

.demo-poll-option.voted .demo-poll-label {
    color: #FF9500;
    font-weight: 600;
}

.demo-poll-pct {
    position: relative;
    z-index: 1;
    color: var(--text-tertiary);
    font-weight: 600;
    font-size: 0.6rem;
    flex-shrink: 0;
}

.demo-poll-votes {
    font-size: 0.55rem;
    color: var(--text-tertiary);
    margin-top: 4px;
    text-align: center;
}

/* Événement message */
.demo-msg-event {
    display: flex;
    gap: 8px;
    background: linear-gradient(135deg, #5856D6, #AF52DE);
    border-radius: 12px;
    padding: 8px 10px;
    margin-top: 4px;
}

.demo-event-date {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 4px 8px;
    min-width: 36px;
}

.demo-event-day {
    font-size: 0.9rem;
    font-weight: 800;
    color: white;
    line-height: 1;
}

.demo-event-month {
    font-size: 0.5rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
    text-transform: uppercase;
}

.demo-event-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.demo-event-label {
    display: flex;
    align-items: center;
    gap: 3px;
    font-size: 0.5rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.7);
    letter-spacing: 0.5px;
}

.demo-event-title {
    font-size: 0.75rem;
    font-weight: 700;
    color: white;
}

.demo-event-details {
    display: flex;
    gap: 6px;
    font-size: 0.55rem;
    color: rgba(255, 255, 255, 0.8);
}

.demo-event-join-btn {
    background: rgba(255, 255, 255, 0.25);
    padding: 2px 10px;
    border-radius: 8px;
    font-size: 0.6rem;
    font-weight: 600;
    color: white;
    cursor: pointer;
    align-self: flex-start;
    margin-top: 2px;
}

/* ---------- Call Screen ---------- */
.demo-page-call {
    background: linear-gradient(180deg, #0f0f1e 0%, #1a1a2e 100%);
    align-items: center;
    gap: 12px;
    padding: 0 20px 20px;
}

.demo-call-header {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 10px 0;
}

.demo-call-back {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
}

.demo-call-back:hover {
    background: rgba(255, 255, 255, 0.2);
}

.demo-call-back svg {
    width: 18px;
    height: 18px;
}

.demo-call-header-info {
    flex: 1;
}

.demo-call-title {
    font-size: 1rem;
    font-weight: 700;
}

.demo-call-timer {
    font-size: 0.75rem;
    color: #34d399;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

.demo-call-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
    flex: 1;
    align-content: center;
}

.demo-call-user {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    position: relative;
}

.demo-call-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    font-weight: 700;
    color: white;
}

.demo-call-user span {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.demo-call-user.speaking .demo-call-avatar {
    box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.5), 0 0 20px rgba(52, 211, 153, 0.3);
    animation: speaking-pulse 1.5s ease-in-out infinite;
}

.demo-call-wave {
    position: absolute;
    width: 72px;
    height: 72px;
    top: -4px;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 50%;
    border: 2px solid rgba(52, 211, 153, 0.3);
    animation: wave-expand 2s ease-out infinite;
}

/* Call controls */
.demo-call-controls {
    display: flex;
    gap: 20px;
    align-items: center;
    justify-content: center;
    padding-bottom: 10px;
}

.demo-call-control-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.demo-call-control-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

.demo-call-ptt-btn {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 0 24px rgba(99, 102, 241, 0.4);
    animation: ptt-glow 2s ease-in-out infinite;
}

.demo-call-hangup-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #ef4444;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 0 16px rgba(239, 68, 68, 0.3);
}

/* Special message wrapper (no bubble background) */
.demo-msg-special-wrap {
    display: flex;
    flex-direction: column;
    max-width: 100%;
}

/* ---------- RIDE Modal (bottom sheet) ---------- */
.demo-ride-modal {
    display: none;
    position: absolute;
    inset: 0;
    z-index: 50;
    border-radius: 41px;
    overflow: hidden;
}

.demo-ride-modal.open {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.demo-ride-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    animation: modal-fade-in 0.3s ease;
}

.demo-ride-modal-sheet {
    position: relative;
    background: linear-gradient(180deg, rgba(26, 26, 46, 0.97), rgba(15, 52, 96, 0.98));
    border-radius: 20px 20px 0 0;
    padding: 12px 16px 24px;
    max-height: 75%;
    overflow: hidden;
    animation: modal-sheet-up 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.demo-ride-modal-handle {
    width: 36px;
    height: 4px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
    margin: 0 auto 12px;
}

.demo-ride-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.demo-ride-modal-header span {
    font-size: 1rem;
    font-weight: 700;
    color: white;
}

.demo-ride-modal-x {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    font-size: 1rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
}

.demo-ride-modal-x:hover {
    background: rgba(255, 255, 255, 0.2);
}

.demo-ride-modal-section {
    margin-bottom: 16px;
}

.demo-ride-modal-section-title {
    font-size: 0.6rem;
    font-weight: 700;
    color: var(--text-tertiary);
    letter-spacing: 1px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.demo-ride-modal-badge {
    font-size: 0.5rem;
    background: rgba(255, 255, 255, 0.1);
    padding: 1px 6px;
    border-radius: 8px;
    font-weight: 600;
}

.demo-ride-modal-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px;
    border-radius: 12px;
    cursor: pointer;
    transition: var(--transition);
}

.demo-ride-modal-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.demo-ride-modal-av {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    color: white;
}

.demo-ride-modal-item span {
    flex: 1;
    font-size: 0.85rem;
    font-weight: 500;
    color: white;
}

.demo-ride-modal-online {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10b981;
    flex-shrink: 0;
}

.demo-ride-check {
    width: 22px;
    height: 22px;
    min-width: 22px;
    border-radius: 6px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.demo-ride-check.checked {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    border-color: transparent;
}

.demo-ride-check.checked::after {
    content: '\2713';
    color: white;
    font-size: 0.7rem;
    font-weight: 700;
}

.demo-ride-modal-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    border-radius: 14px;
    font-size: 0.9rem;
    font-weight: 700;
    color: white;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(99, 102, 241, 0.4);
    transition: var(--transition);
}

.demo-ride-modal-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5);
}

.demo-ride-modal-count {
    font-size: 0.65rem;
    background: rgba(255, 255, 255, 0.2);
    padding: 2px 8px;
    border-radius: 10px;
}

/* Modal success state */
.demo-ride-modal-success {
    display: none;
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    z-index: 55;
    border-radius: 41px;
}

.demo-ride-modal-success.show {
    display: flex;
    animation: modal-fade-in 0.3s ease;
}

.demo-ride-success-circle {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, #34C759, #30D158);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
    box-shadow: 0 0 30px rgba(52, 199, 89, 0.5);
    animation: success-pop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.demo-ride-success-text {
    font-size: 1.2rem;
    font-weight: 800;
    color: white;
}

.demo-ride-success-sub {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

@keyframes modal-fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes modal-sheet-up {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

@keyframes success-pop {
    0% { transform: scale(0); }
    100% { transform: scale(1); }
}

/* ---------- Ride Toast ---------- */
.demo-ride-toast {
    position: absolute;
    top: 60px;
    left: 50%;
    transform: translateX(-50%) translateY(-20px);
    background: rgba(239, 68, 68, 0.9);
    backdrop-filter: blur(10px);
    color: white;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 8px 20px;
    border-radius: 20px;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 30;
    pointer-events: none;
}

.demo-ride-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ---------- Tab Bar (5 positions, floating rounded) ---------- */
.demo-tabbar {
    position: absolute;
    bottom: 8px;
    left: 10px;
    right: 10px;
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 0 4px;
    background: rgba(26, 26, 46, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1.5px solid rgba(255, 255, 255, 0.2);
    border-radius: 30px;
    z-index: 20;
    height: 56px;
    box-sizing: border-box;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.15);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

/* Hide tab bar when chat or call page is active */
.demo-screen:has(.demo-page-chat.active) .demo-tabbar,
.demo-screen:has(.demo-page-call.active) .demo-tabbar {
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
}

/* Chat/call pages take full height (no tabbar space) */
.demo-page-chat.active,
.demo-page-call.active {
    bottom: 0;
}

.demo-tab {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    cursor: pointer;
    opacity: 0.4;
    transition: var(--transition);
    padding: 2px 8px;
    flex: 1;
}

.demo-tab.active {
    opacity: 1;
}

.demo-tab svg {
    width: 20px;
    height: 20px;
}

.demo-tab.active svg {
    color: var(--accent-light);
}

.demo-tab span {
    font-size: 9px;
    font-weight: 500;
}

.demo-tab.active span {
    color: var(--accent-light);
}

.demo-tab-badge-wrap {
    position: relative;
    display: inline-flex;
}

.demo-tab-badge {
    position: absolute;
    top: -4px;
    right: -8px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #ef4444;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.5rem;
    font-weight: 700;
    color: white;
}

/* RIDE button (central, elevated) */
.demo-tab-ride {
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transform: translateY(-6px);
    position: relative;
    flex: 1;
}

.demo-ride-button {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    border: 2px solid rgba(255, 255, 255, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow:
        0 4px 20px rgba(239, 68, 68, 0.5),
        0 0 40px rgba(239, 68, 68, 0.2);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.demo-ride-button:hover {
    transform: scale(1.08);
    box-shadow:
        0 6px 28px rgba(239, 68, 68, 0.6),
        0 0 50px rgba(239, 68, 68, 0.3);
}

.demo-ride-button:active {
    transform: scale(0.95);
}

.demo-tab-ride.ride-active .demo-ride-button {
    animation: ride-pulse 1s ease-in-out;
}

.demo-tab-ride.ride-started .demo-ride-button {
    background: linear-gradient(135deg, #10b981, #34d399);
    box-shadow:
        0 4px 20px rgba(16, 185, 129, 0.5),
        0 0 40px rgba(16, 185, 129, 0.2);
}

.demo-tab-ride.ride-started .demo-ride-button:hover {
    box-shadow:
        0 6px 28px rgba(16, 185, 129, 0.6),
        0 0 50px rgba(16, 185, 129, 0.3);
}

@keyframes ride-pulse {
    0% { transform: scale(1); box-shadow: 0 4px 20px rgba(239,68,68,0.5), 0 0 40px rgba(239,68,68,0.2); }
    30% { transform: scale(1.2); box-shadow: 0 6px 40px rgba(239,68,68,0.8), 0 0 80px rgba(239,68,68,0.4); }
    100% { transform: scale(1); box-shadow: 0 4px 20px rgba(239,68,68,0.5), 0 0 40px rgba(239,68,68,0.2); }
}

/* Phone glow */
.demo-phone-glow {
    position: absolute;
    inset: -40px;
    border-radius: 80px;
    background: radial-gradient(
        ellipse at center,
        rgba(99, 102, 241, 0.12) 0%,
        transparent 60%
    );
    z-index: -1;
    animation: phone-glow-pulse 4s ease-in-out infinite;
}

@keyframes phone-glow-pulse {
    0%, 100% { opacity: 0.6; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.05); }
}

/* Demo hint */
.demo-hint {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    color: var(--text-tertiary);
    animation: hint-bounce 2s ease-in-out infinite;
}

.demo-hint svg {
    width: 16px;
    height: 16px;
    color: var(--text-tertiary);
}

@keyframes hint-bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-4px); }
}

/* Demo responsive */
@media (max-width: 400px) {
    .demo-phone-frame {
        width: 280px;
        height: 560px;
        border-radius: 36px;
    }

    .demo-screen {
        border-radius: 33px;
    }
}

/* =============================================
   SECURITY
   ============================================= */
.security {
    padding: 120px 0;
    position: relative;
}

.security-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.security-card {
    padding: 32px;
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.security-icon {
    width: 48px;
    height: 48px;
    min-width: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(52, 211, 153, 0.1);
    border: 1px solid rgba(52, 211, 153, 0.2);
    border-radius: 12px;
}

.security-icon svg {
    width: 22px;
    height: 22px;
    color: #34d399;
}

.security-card h3 {
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.security-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

@media (max-width: 768px) {
    .security-grid {
        grid-template-columns: 1fr;
    }
}


/* =============================================
   DOWNLOAD CTA
   ============================================= */
.download {
    padding: 120px 0;
}

.download-card {
    position: relative;
    padding: 80px 40px;
    text-align: center;
    overflow: hidden;
    border: 1px solid rgba(99, 102, 241, 0.15);
}

.download-content {
    position: relative;
    z-index: 2;
}

.download-logo {
    height: 56px;
    width: auto;
    margin: 0 auto 24px;
    filter: drop-shadow(0 0 20px rgba(225, 48, 108, 0.3));
}

.download-card .section-title {
    margin-bottom: 12px;
}

.download-card .section-subtitle {
    margin-bottom: 36px;
}

.download-badges {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.download-glow {
    position: absolute;
    top: -50%;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 200%;
    background: radial-gradient(
        ellipse at center,
        rgba(99, 102, 241, 0.08) 0%,
        transparent 60%
    );
    z-index: 1;
}

/* =============================================
   FOOTER
   ============================================= */
.footer {
    padding: 80px 0 40px;
    border-top: 1px solid var(--glass-border);
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 60px;
    margin-bottom: 60px;
}

.footer-logo {
    height: 40px;
    width: auto;
    margin-bottom: 12px;
}

.footer-tagline {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.footer-col h4 {
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-primary);
    margin-bottom: 16px;
}

.footer-col a {
    display: block;
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 10px;
    transition: var(--transition);
}

.footer-col a:hover {
    color: var(--text-primary);
}

.footer-social {
    display: flex;
    gap: 12px;
    margin-top: 8px;
}

.footer-social a {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    transition: var(--transition);
    margin-bottom: 0;
}

.footer-social a:hover {
    background: var(--glass-bg-hover);
    border-color: var(--glass-border-hover);
    transform: translateY(-2px);
}

.footer-social svg {
    width: 16px;
    height: 16px;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 32px;
    border-top: 1px solid var(--glass-border);
}

.footer-bottom p {
    font-size: 0.8rem;
    color: var(--text-tertiary);
}

.footer-made {
    color: var(--text-tertiary);
}

@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .footer-links {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-bottom {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .footer-links {
        grid-template-columns: 1fr;
    }
}
