:root {
    --bg: #07060f;
    --bg2: #0e0c1c;
    --bg3: #13112a;
    --accent: #a855f7;
    --accent2: #ec4899;
    --accent3: #06b6d4;
    --text: #f1f0fa;
    --muted: #8880a8;
    --border: rgba(168, 85, 247, 0.18);
    --card: rgba(255, 255, 255, 0.04);
    --card-border: rgba(255, 255, 255, 0.08);
    --glow: 0 0 40px rgba(168, 85, 247, 0.25);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    font-family: 'DM Sans', sans-serif;
    background: var(--bg);
    color: var(--text);
    overflow-x: hidden;
    line-height: 1.6;
    min-height: 100vh;
    min-height: 100dvh;
    padding-left: env(safe-area-inset-left, 0px);
    padding-right: env(safe-area-inset-right, 0px);
}

/* ─── NOISE OVERLAY ─── */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
    pointer-events: none;
    z-index: 1000;
    opacity: 0.4;
}

/* ─── NAV ─── */
nav.site-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: calc(1rem + env(safe-area-inset-top, 0px)) max(5vw, env(safe-area-inset-right, 0px)) 1rem max(5vw, env(safe-area-inset-left, 0px));
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.75rem;
    background: rgba(7, 6, 15, 0.75);
    backdrop-filter: blur(16px);
    border-bottom: 0.5px solid var(--border);
}

/* Logo + hamburger: occupa lo spazio orizzontale così il brand resta a sinistra e il drawer non lo schiaccia */
.nav-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex: 1 1 auto;
    min-width: 0;
}

a.logo {
    text-decoration: none;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    min-width: 0;
    flex-shrink: 0;
}

.logo-text {
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    font-size: 1.3rem;
    letter-spacing: -0.02em;
    background: linear-gradient(135deg, #a855f7, #ec4899);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo-beta {
    flex-shrink: 0;
    align-self: center;
    margin-left: 0.1rem;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: rgba(233, 213, 255, 0.98);
    padding: 0.2rem 0.48rem;
    border-radius: 999px;
    border: 0.5px solid rgba(168, 85, 247, 0.42);
    background: rgba(168, 85, 247, 0.16);
    line-height: 1;
    white-space: nowrap;
}

.logo img {
    width: 26px;
    height: 26px;
    flex: 0 0 auto;
    filter: drop-shadow(0 10px 20px rgba(168, 85, 247, 0.35));
}

.nav-menu-btn {
    display: none;
    position: relative;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0.5px solid var(--card-border);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.06);
    cursor: pointer;
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
}

.nav-menu-btn span {
    display: block;
    width: 20px;
    height: 2px;
    border-radius: 2px;
    background: rgba(241, 240, 250, 0.9);
    transition:
        transform 0.32s cubic-bezier(0.22, 1, 0.36, 1),
        opacity 0.22s ease,
        top 0.32s cubic-bezier(0.22, 1, 0.36, 1),
        left 0.32s cubic-bezier(0.22, 1, 0.36, 1),
        margin 0.32s cubic-bezier(0.22, 1, 0.36, 1);
    transform-origin: center;
}

/* Hamburger → X (menu aperto) */
.site-nav.nav-open .nav-menu-btn {
    gap: 0;
}

.site-nav.nav-open .nav-menu-btn span:nth-child(1),
.site-nav.nav-open .nav-menu-btn span:nth-child(3) {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 20px;
    margin-left: -10px;
    margin-top: -1px;
}

.site-nav.nav-open .nav-menu-btn span:nth-child(1) {
    transform: rotate(45deg);
}

.site-nav.nav-open .nav-menu-btn span:nth-child(2) {
    position: absolute;
    left: 50%;
    width: 0;
    height: 0;
    margin: 0;
    opacity: 0;
    transform: scale(0);
    overflow: hidden;
    pointer-events: none;
}

.site-nav.nav-open .nav-menu-btn span:nth-child(3) {
    transform: rotate(-45deg);
}

.nav-menu-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1899;
    background: var(--bg);
}

.site-nav.nav-open .nav-menu-backdrop {
    display: block;
}

nav ul.nav-main-list {
    list-style: none;
    display: flex;
    gap: 2rem;
    align-items: center;
    margin: 0 0 0 auto;
    padding: 0;
    min-width: 0;
}

nav ul.nav-main-list a {
    color: var(--muted);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 400;
    letter-spacing: 0.01em;
    transition: color 0.2s;
}

nav ul.nav-main-list a:hover {
    color: var(--text);
}

.nav-cta {
    background: var(--accent) !important;
    color: #fff !important;
    padding: 0.55rem 1.3rem;
    border-radius: 100px;
    font-size: 0.85rem !important;
    font-weight: 500 !important;
    -webkit-text-fill-color: #fff !important;
    transition: opacity 0.2s !important;
}

.nav-cta:hover {
    opacity: 0.85 !important;
}

/* ─── HERO ─── */
.hero {
    min-height: 100vh;
    min-height: 100dvh;
    min-height: -webkit-fill-available;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 8rem max(5vw, env(safe-area-inset-left)) 6rem max(5vw, env(safe-area-inset-right));
    position: relative;
    overflow: hidden;
}

.hero-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
}

.orb1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(168, 85, 247, 0.2) 0%, transparent 70%);
    top: -150px;
    left: -100px;
}

.orb2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(236, 72, 153, 0.15) 0%, transparent 70%);
    bottom: -100px;
    right: -100px;
}

.orb3 {
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.12) 0%, transparent 70%);
    top: 30%;
    left: 60%;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(168, 85, 247, 0.12);
    border: 0.5px solid rgba(168, 85, 247, 0.35);
    border-radius: 100px;
    padding: 0.4rem 1rem;
    font-size: 0.8rem;
    color: #c084fc;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    font-weight: 500;
    margin-bottom: 2rem;
    position: relative;
}

.badge-dot {
    width: 6px;
    height: 6px;
    background: #a855f7;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.4;
        transform: scale(0.7);
    }
}

.hero h1 {
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    font-size: clamp(2.8rem, 7vw, 6rem);
    line-height: 1.05;
    letter-spacing: -0.04em;
    margin-bottom: 1.5rem;
    position: relative;
}

.hero h1 span {
    background: linear-gradient(135deg, #a855f7 0%, #ec4899 50%, #06b6d4 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    max-width: 580px;
    color: var(--muted);
    font-size: 1.1rem;
    font-weight: 300;
    line-height: 1.7;
    margin-bottom: 2.5rem;
    position: relative;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
    position: relative;
}

.btn-primary {
    background: linear-gradient(135deg, #a855f7, #ec4899);
    color: #fff;
    border: none;
    padding: 0.85rem 2rem;
    border-radius: 100px;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    font-family: 'DM Sans', sans-serif;
    letter-spacing: 0.01em;
    transition: transform 0.2s, opacity 0.2s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-primary:hover {
    transform: translateY(-2px);
    opacity: 0.92;
}

.btn-secondary {
    background: transparent;
    color: var(--text);
    border: 0.5px solid var(--card-border);
    padding: 0.85rem 2rem;
    border-radius: 100px;
    font-size: 0.95rem;
    font-weight: 400;
    cursor: pointer;
    font-family: 'DM Sans', sans-serif;
    transition: border-color 0.2s, background 0.2s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-secondary:hover {
    border-color: var(--accent);
    background: rgba(168, 85, 247, 0.06);
}

/* ─── MAP MOCKUP ─── */
.map-section {
    padding: 0 max(5vw, env(safe-area-inset-left)) 8rem max(5vw, env(safe-area-inset-right));
    position: relative;
}

/* Contiene mappa + popup: stesso box di prima per position:absolute della scheda desktop */
.map-shell {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
    width: 100%;
}

.map-container {
    max-width: 900px;
    margin: 0 auto;
    background: var(--bg3);
    border-radius: 24px;
    border: 0.5px solid var(--card-border);
    overflow: hidden;
    position: relative;
    box-shadow: 0 40px 120px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.map-topbar {
    background: rgba(255, 255, 255, 0.04);
    border-bottom: 0.5px solid var(--card-border);
    padding: 1rem 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.7rem;
}

.map-topbar-search-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    width: 100%;
    min-width: 0;
}

.map-use-location-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    width: 100%;
    padding: 0.52rem 1rem;
    border-radius: 10px;
    border: 0.5px solid rgba(168, 85, 247, 0.38);
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.14), rgba(236, 72, 153, 0.08));
    color: #f3e8ff;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.84rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, transform 0.12s ease;
    -webkit-tap-highlight-color: transparent;
}

.map-use-location-btn:hover {
    border-color: rgba(192, 132, 252, 0.55);
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.22), rgba(236, 72, 153, 0.12));
    box-shadow: 0 4px 18px rgba(168, 85, 247, 0.2);
}

.map-use-location-btn:active {
    transform: scale(0.99);
}

.map-use-location-btn .map-use-location-icon {
    font-size: 1rem;
    line-height: 1;
}

.map-dots {
    display: flex;
    gap: 6px;
}

.map-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.d1 {
    background: #ff5f57;
}

.d2 {
    background: #febc2e;
}

.d3 {
    background: #28c840;
}

.map-search {
    flex: 1;
    background: rgba(255, 255, 255, 0.06);
    border: 0.5px solid var(--card-border);
    border-radius: 8px;
    padding: 0.45rem 1rem;
    color: var(--muted);
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.radius-control {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.radius-control .radius-track {
    display: inline-flex;
    align-items: center;
}

.map-body {
    display: grid;
    grid-template-columns: 300px 1fr;
    height: 480px;
}

.map-sidebar {
    border-right: 0.5px solid var(--card-border);
    overflow-y: auto;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    scrollbar-width: thin;
    scrollbar-color: rgba(168, 85, 247, 0.5) transparent;
}

.map-sidebar::-webkit-scrollbar {
    width: 6px;
}

.map-sidebar::-webkit-scrollbar-track {
    background: transparent;
}

.map-sidebar::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, rgba(168, 85, 247, 0.55), rgba(236, 72, 153, 0.35));
    border-radius: 100px;
    border: 2px solid transparent;
    background-clip: content-box;
}

.map-sidebar::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, rgba(168, 85, 247, 0.8), rgba(236, 72, 153, 0.55));
    background-clip: content-box;
}

.club-card {
    background: rgba(255, 255, 255, 0.04);
    border: 0.5px solid var(--card-border);
    border-radius: 12px;
    padding: 0.9rem 1rem;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}

.club-card:hover,
.club-card.active {
    border-color: rgba(168, 85, 247, 0.5);
    background: rgba(168, 85, 247, 0.06);
}

.club-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.4rem;
}

.club-name {
    font-family: 'Syne', sans-serif;
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--text);
}

.club-stars {
    font-size: 0.7rem;
    color: #eab308;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    min-height: 1rem;
    min-width: 1rem;
}

.club-stars-loader {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(234, 179, 8, 0.22);
    border-top-color: #eab308;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
    vertical-align: middle;
    flex-shrink: 0;
}

.club-stars-empty {
    color: var(--muted);
    letter-spacing: 0;
    font-size: 0.75rem;
}

.club-meta {
    font-size: 0.75rem;
    color: var(--muted);
    margin-bottom: 0.6rem;
}

.club-tags {
    display: flex;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.tag {
    font-size: 0.65rem;
    padding: 0.2rem 0.55rem;
    border-radius: 100px;
    font-weight: 500;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.tag-music {
    background: rgba(168, 85, 247, 0.2);
    color: #c084fc;
}

.tag-hot {
    background: rgba(236, 72, 153, 0.2);
    color: #f472b6;
}

.tag-free {
    background: rgba(6, 182, 212, 0.2);
    color: #22d3ee;
}

.tag-vip {
    background: rgba(234, 179, 8, 0.2);
    color: #facc15;
}

.tag-ai {
    background: linear-gradient(135deg, rgba(234, 179, 8, 0.25), rgba(168, 85, 247, 0.25));
    color: #fbbf24;
    font-weight: 700;
}

.club-card.sponsored {
    border-color: rgba(234, 179, 8, 0.45);
    background: linear-gradient(135deg, rgba(234, 179, 8, 0.06), rgba(168, 85, 247, 0.04));
    position: relative;
}

.club-card.sponsored:hover,
.club-card.sponsored.active {
    border-color: rgba(234, 179, 8, 0.7);
    background: linear-gradient(135deg, rgba(234, 179, 8, 0.1), rgba(168, 85, 247, 0.07));
}

.sponsored-label {
    font-size: 0.58rem;
    font-weight: 700;
    color: #fbbf24;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 0.3rem;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.crowd-bar {
    margin-top: 0.6rem;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 100px;
    height: 4px;
    overflow: hidden;
}

.crowd-fill {
    height: 100%;
    border-radius: 100px;
    background: linear-gradient(90deg, #a855f7, #ec4899);
    transition: width 0.5s;
}

.crowd-label {
    display: flex;
    justify-content: space-between;
    font-size: 0.65rem;
    color: var(--muted);
    margin-top: 0.3rem;
}

.club-card--compact {
    padding: 0.62rem 0.78rem;
}

.club-card--compact .club-card-header {
    margin-bottom: 0.28rem;
}

.club-card--compact .club-meta {
    margin-bottom: 0.35rem;
}

.club-card--compact .club-tags {
    margin-bottom: 0.15rem;
}

/* MAP VISUALIZATION */
.map-view {
    position: relative;
    background: #0f0e1d;
    overflow: hidden;
}

.map-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(168, 85, 247, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(168, 85, 247, 0.04) 1px, transparent 1px);
    background-size: 40px 40px;
    pointer-events: none;
    z-index: 2;
}

.map-roads {
    position: absolute;
    inset: 0;
}

/* REAL MAP (Leaflet) */
.leaflet-map {
    position: absolute;
    inset: 0;
    z-index: 1;
}

/* Keep Leaflet controls consistent with style */
.map-view .leaflet-control-zoom a {
    background: rgba(14, 12, 28, 0.92);
    border: 0.5px solid rgba(168, 85, 247, 0.25);
    color: var(--text);
    backdrop-filter: blur(10px);
}

.map-view .leaflet-control-zoom a:hover {
    background: rgba(168, 85, 247, 0.10);
}

.map-view .leaflet-control-attribution {
    background: rgba(14, 12, 28, 0.65);
    border: 0.5px solid rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.65);
    backdrop-filter: blur(10px);
}

.map-view .leaflet-popup-content-wrapper,
.map-view .leaflet-popup-tip {
    background: rgba(14, 12, 28, 0.96);
    border: 0.5px solid rgba(168, 85, 247, 0.35);
    color: var(--text);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.map-view .leaflet-popup-content {
    margin: 10px 12px;
    font-family: 'DM Sans', sans-serif;
}

/* Caricamento dati mappa: overlay (attivo solo su mobile via JS + CSS) */
.map-fetch-status {
    position: absolute;
    left: 50%;
    bottom: max(12px, env(safe-area-inset-bottom, 0px));
    transform: translateX(-50%);
    z-index: 650;
    display: none;
    align-items: center;
    gap: 0.5rem;
    padding: 0.42rem 0.75rem 0.42rem 0.55rem;
    max-width: min(340px, calc(100% - 20px));
    border-radius: 999px;
    background: rgba(14, 12, 28, 0.78);
    border: 0.5px solid rgba(168, 85, 247, 0.32);
    box-shadow: 0 10px 36px rgba(0, 0, 0, 0.42);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    font-size: 0.78rem;
    color: rgba(248, 250, 252, 0.95);
    pointer-events: none;
    line-height: 1.25;
}

.map-fetch-status.map-fetch-status--on {
    display: flex;
}

.map-fetch-status .map-fetch-spin {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    border: 2.5px solid rgba(168, 85, 247, 0.22);
    border-top-color: #c084fc;
    border-radius: 50%;
    animation: spin 0.65s linear infinite;
}

.map-fetch-status .map-fetch-line {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 600;
    letter-spacing: 0.01em;
}

.map-fetch-status .map-fetch-sub {
    display: block;
    font-size: 0.68rem;
    font-weight: 500;
    color: rgba(226, 232, 240, 0.62);
    margin-top: 0.06rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.map-fetch-status>span:last-of-type {
    min-width: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
}

@media (min-width: 769px) {
    .map-fetch-status.map-fetch-status--on {
        display: none !important;
    }
}

.map-sidebar-load-placeholder {
    display: none;
    width: 100%;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 0.35rem 0;
    box-sizing: border-box;
}

.map-sidebar-load-placeholder .map-sidebar-load-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(168, 85, 247, 0.35);
    animation: mapFetchDot 0.9s ease-in-out infinite;
}

.map-sidebar-load-placeholder .map-sidebar-load-dot:nth-child(2) {
    animation-delay: 0.15s;
}

.map-sidebar-load-placeholder .map-sidebar-load-dot:nth-child(3) {
    animation-delay: 0.3s;
}

@keyframes mapFetchDot {

    0%,
    80%,
    100% {
        opacity: 0.28;
        transform: scale(0.92);
    }

    40% {
        opacity: 1;
        transform: scale(1);
    }
}

.leaflet-popup-close-button {
    color: rgba(255, 255, 255, 0.8) !important;
}

/* Leaflet markers styled like the mock pins */
.fmn-pin {
    position: relative;
    transform: translate(-50%, -100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    pointer-events: auto;
    user-select: none;
}

.fmn-pin-bubble {
    background: linear-gradient(135deg, #a855f7, #ec4899);
    border-radius: 12px 12px 12px 2px;
    padding: 0.38rem 0.72rem;
    font-size: 0.75rem;
    font-weight: 700;
    font-family: 'Syne', sans-serif;
    color: #fff;
    white-space: nowrap;
    box-shadow: 0 8px 30px rgba(168, 85, 247, 0.45);
    border: 0.5px solid rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(6px);
}

.fmn-pin-stem {
    width: 2px;
    height: 10px;
    background: rgba(168, 85, 247, 0.9);
}

.fmn-pin-dot {
    width: 7px;
    height: 7px;
    border-radius: 999px;
    background: rgba(168, 85, 247, 0.95);
    box-shadow: 0 0 0 6px rgba(168, 85, 247, 0.12);
}

.leaflet-marker-icon.fmn-marker {
    background: transparent !important;
    border: none !important;
}

.fmn-pin:hover {
    transform: translate(-50%, -100%) scale(1.06);
    transition: transform 160ms ease;
}

.pin {
    position: absolute;
    transform: translate(-50%, -100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    transition: transform 0.2s;
}

.pin:hover {
    transform: translate(-50%, -100%) scale(1.15);
}

.pin-bubble {
    background: linear-gradient(135deg, #a855f7, #ec4899);
    border-radius: 12px 12px 12px 2px;
    padding: 0.35rem 0.65rem;
    font-size: 0.7rem;
    font-weight: 600;
    font-family: 'Syne', sans-serif;
    color: #fff;
    white-space: nowrap;
    box-shadow: 0 4px 20px rgba(168, 85, 247, 0.4);
}

.pin-bubble.cyan {
    background: linear-gradient(135deg, #06b6d4, #0891b2);
    box-shadow: 0 4px 20px rgba(6, 182, 212, 0.4);
}

.pin-bubble.pink {
    background: linear-gradient(135deg, #ec4899, #db2777);
    box-shadow: 0 4px 20px rgba(236, 72, 153, 0.4);
}

.pin-stem {
    width: 2px;
    height: 8px;
    background: #a855f7;
}

.pin.cyan .pin-stem {
    background: #06b6d4;
}

.pin.pink .pin-stem {
    background: #ec4899;
}

.pin-dot {
    width: 6px;
    height: 6px;
    background: #a855f7;
    border-radius: 50%;
}

.pin.cyan .pin-dot {
    background: #06b6d4;
}

.pin.pink .pin-dot {
    background: #ec4899;
}

.user-location {
    position: absolute;
    width: 20px;
    height: 20px;
    background: rgba(6, 182, 212, 0.2);
    border: 2px solid #06b6d4;
    border-radius: 50%;
    transform: translate(-50%, -50%);
}

.user-location::after {
    content: '';
    position: absolute;
    inset: 3px;
    background: #06b6d4;
    border-radius: 50%;
}

.user-pulse {
    position: absolute;
    width: 40px;
    height: 40px;
    background: rgba(6, 182, 212, 0.15);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: ripple 2s infinite;
}

@keyframes ripple {
    0% {
        transform: translate(-50%, -50%) scale(0.5);
        opacity: 1;
    }

    100% {
        transform: translate(-50%, -50%) scale(2);
        opacity: 0;
    }
}

/* Angolo basso-destra: desktop usa --fmn-detail-* aggiornate da JS rispetto a .map-shell; finché non girano, fallback 16px */
.detail-popup {
    position: fixed;
    left: auto;
    right: var(--fmn-detail-right, 16px);
    bottom: var(--fmn-detail-bottom, 16px);
    background: #0a0b14;
    border: 1px solid rgba(168, 85, 247, 0.55);
    border-radius: 18px;
    padding: 1.05rem 1.15rem 1rem;
    width: min(300px, calc(100vw - 32px));
    max-width: min(300px, calc(100vw - 32px));
    backdrop-filter: blur(14px);
    box-shadow:
        0 12px 40px rgba(0, 0, 0, 0.55),
        0 0 0 1px rgba(168, 85, 247, 0.22),
        0 0 32px rgba(168, 85, 247, 0.2);
    z-index: 1150;
}

.popup-name-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.5rem;
}

.popup-name {
    font-family: 'Syne', sans-serif;
    font-weight: 700;
    font-size: 1.05rem;
    line-height: 1.2;
    color: var(--text);
    margin: 0;
    flex: 1;
}

.popup-disco {
    font-size: 1.35rem;
    line-height: 1;
    flex-shrink: 0;
    opacity: 0.92;
    filter: drop-shadow(0 0 6px rgba(255, 255, 255, 0.15));
    cursor: pointer;
    background: none;
    border: none;
    padding: 0.15rem;
    margin: -0.15rem -0.15rem 0 0;
    border-radius: 10px;
    transition: background 0.15s ease, transform 0.12s ease;
}

.popup-disco:hover {
    background: rgba(255, 255, 255, 0.08);
}

.popup-disco:active {
    transform: scale(0.92);
}

.popup-live {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.72rem;
    color: #c4b5fd;
    font-weight: 500;
    margin-top: 0.4rem;
    margin-bottom: 0.75rem;
    letter-spacing: 0.02em;
}

.popup-live-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #a855f7;
    box-shadow: 0 0 10px rgba(168, 85, 247, 0.85);
    flex-shrink: 0;
}

.popup-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.78rem;
    padding: 0.45rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--muted);
}

.popup-row:last-of-type {
    border-bottom: none;
}

.popup-row strong {
    color: var(--text);
    font-weight: 600;
    text-align: right;
}

.popup-vai {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: center;
    margin-top: 1rem;
    padding: 0.68rem 1rem;
    border: none;
    border-radius: 14px;
    font-family: 'DM Sans', sans-serif;
    font-weight: 700;
    font-size: 0.88rem;
    color: #fff;
    cursor: pointer;
    background: linear-gradient(to right, #a855f7, #ec4899);
    box-shadow: 0 6px 24px rgba(168, 85, 247, 0.38);
    transition: filter 0.15s ease, transform 0.12s ease;
}

.popup-vai:hover {
    filter: brightness(1.06);
}

.popup-vai:active {
    transform: scale(0.98);
}

/* Scelta app mappe (sostituisce alert/confirm nativo) */
.fmn-maps-sheet {
    position: fixed;
    inset: 0;
    z-index: 1250;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: stretch;
    padding: 0;
    font-family: 'DM Sans', sans-serif;
}

.fmn-maps-sheet[hidden] {
    display: none !important;
}

.fmn-maps-sheet__backdrop {
    position: absolute;
    inset: 0;
    border: 0;
    padding: 0;
    margin: 0;
    background: rgba(5, 6, 12, 0.72);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    cursor: pointer;
}

.fmn-maps-sheet__panel {
    position: relative;
    z-index: 1;
    margin: 0;
    max-height: min(85vh, 420px);
    background: linear-gradient(165deg, rgba(18, 19, 32, 0.98) 0%, #0a0b14 100%);
    border: 1px solid rgba(168, 85, 247, 0.45);
    border-bottom: none;
    border-radius: 22px 22px 0 0;
    padding: 1.35rem 1.25rem calc(1.15rem + env(safe-area-inset-bottom));
    box-shadow:
        0 -12px 48px rgba(0, 0, 0, 0.55),
        0 0 0 1px rgba(168, 85, 247, 0.15);
}

.fmn-maps-sheet__grab {
    width: 40px;
    height: 4px;
    border-radius: 99px;
    background: rgba(255, 255, 255, 0.12);
    margin: -0.35rem auto 1rem;
}

.fmn-maps-sheet__close {
    position: absolute;
    top: 0.85rem;
    right: 0.75rem;
    width: 2.25rem;
    height: 2.25rem;
    border: none;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.06);
    color: var(--muted);
    font-size: 1.35rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease, color 0.15s ease;
}

.fmn-maps-sheet__close:hover {
    background: rgba(255, 255, 255, 0.12);
    color: var(--text);
}

.fmn-maps-sheet__title {
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    font-size: 1.15rem;
    color: var(--text);
    margin: 0 2.5rem 0.35rem 0;
    letter-spacing: -0.02em;
}

.fmn-maps-sheet__subtitle {
    font-size: 0.92rem;
    color: #e9d5ff;
    margin: 0 0 0.25rem;
    line-height: 1.35;
    font-weight: 600;
}

.fmn-maps-sheet__hint {
    font-size: 0.78rem;
    color: var(--muted);
    margin: 0 0 1.1rem;
}

.fmn-maps-sheet__actions {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.fmn-maps-sheet__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.85rem 1rem;
    border-radius: 14px;
    font-family: inherit;
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    border: 1px solid transparent;
    transition: filter 0.15s ease, transform 0.12s ease, box-shadow 0.15s ease;
}

.fmn-maps-sheet__btn:active {
    transform: scale(0.99);
}

.fmn-maps-sheet__btn--google {
    color: #fff;
    background: linear-gradient(135deg, #1a73e8 0%, #0d47a1 100%);
    box-shadow: 0 6px 22px rgba(26, 115, 232, 0.35);
}

.fmn-maps-sheet__btn--google:hover {
    filter: brightness(1.05);
}

.fmn-maps-sheet__btn--apple {
    color: var(--text);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.14);
}

.fmn-maps-sheet__btn--apple:hover {
    background: rgba(255, 255, 255, 0.12);
}

.fmn-maps-sheet__cancel {
    display: block;
    width: 100%;
    margin-top: 0.85rem;
    padding: 0.6rem;
    border: none;
    background: none;
    color: var(--muted);
    font-family: inherit;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    border-radius: 10px;
    transition: color 0.15s ease, background 0.15s ease;
}

.fmn-maps-sheet__cancel:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.05);
}

@media (min-width: 560px) {
    .fmn-maps-sheet {
        justify-content: center;
        align-items: center;
        padding: 1rem;
    }

    .fmn-maps-sheet__panel {
        width: min(380px, 100%);
        border-radius: 22px;
        border: 1px solid rgba(168, 85, 247, 0.45);
        padding: 1.35rem 1.35rem 1.25rem;
        max-height: none;
    }

    .fmn-maps-sheet__grab {
        display: none;
    }
}

/* ─── STATS ─── */
.stats-section {
    padding: 2rem max(5vw, env(safe-area-inset-left)) 8rem max(5vw, env(safe-area-inset-right));
}

.stats-grid {
    max-width: 900px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: var(--card-border);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    overflow: hidden;
}

.stat-item {
    background: var(--bg);
    padding: 2rem;
    text-align: center;
}

.stat-num {
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    font-size: 2.2rem;
    background: linear-gradient(135deg, #a855f7, #ec4899);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1;
    margin-bottom: 0.4rem;
}

.stat-label {
    font-size: 0.8rem;
    color: var(--muted);
    letter-spacing: 0.03em;
}

/* Loading dots al posto della X (onda verticale) */
.stat-num .stat-loading {
    display: inline-flex;
    align-items: flex-end;
    gap: 0.32rem;
    line-height: 1;
}

.stat-num .stat-loading .dot {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: linear-gradient(135deg, #a855f7, #ec4899);
    opacity: 0.75;
    transform: translateY(0);
    animation: statDotWave 0.95s ease-in-out infinite;
}

.stat-num .stat-loading .dot:nth-child(2) {
    animation-delay: 0.12s;
    opacity: 0.6;
}

.stat-num .stat-loading .dot:nth-child(3) {
    animation-delay: 0.24s;
    opacity: 0.5;
}

@keyframes statDotWave {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-9px);
    }
}

/* Reviews cards */
.review-card {
    background: rgba(255, 255, 255, 0.04);
    border: 0.5px solid var(--card-border);
    border-radius: 16px;
    padding: 1rem 1rem;
}

.review-top {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.35rem;
}

.review-venue {
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    letter-spacing: -0.02em;
    font-size: 1rem;
}

.review-rating {
    font-size: 0.85rem;
    color: #fbbf24;
    letter-spacing: 1px;
    white-space: nowrap;
}

.review-meta {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.55);
    margin-bottom: 0.6rem;
}

.review-text {
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.92rem;
    line-height: 1.55;
    white-space: pre-wrap;
}

.review-empty {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.92rem;
    font-style: italic;
}

/* Reviews split (community vs Google) */
.reviews-split {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    max-width: 1000px;
}
.reviews-col {
    background: rgba(255, 255, 255, 0.02);
    border: 0.5px solid rgba(168, 85, 247, 0.14);
    border-radius: 18px;
    padding: 1rem 1rem;
}
.reviews-col-title {
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    letter-spacing: -0.02em;
    font-size: 0.95rem;
    margin-bottom: 0.85rem;
    color: rgba(241, 240, 250, 0.92);
}
.features-grid.reviews-grid {
    grid-template-columns: 1fr;
    max-width: none;
}

@media (max-width: 980px) {
    .reviews-split {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .reviews-col {
        padding: 0.9rem 0.9rem;
    }
}

/* ─── FEATURES ─── */
.section {
    padding: 6rem max(5vw, env(safe-area-inset-left)) 6rem max(5vw, env(safe-area-inset-right));
}

.section-label {
    font-size: 0.75rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #a855f7;
    font-weight: 500;
    margin-bottom: 1rem;
}

.section-title {
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    font-size: clamp(1.8rem, 4vw, 3rem);
    letter-spacing: -0.03em;
    line-height: 1.1;
    margin-bottom: 1rem;
}

.section-desc {
    color: var(--muted);
    font-size: 1rem;
    max-width: 500px;
    line-height: 1.7;
    margin-bottom: 3rem;
    font-weight: 300;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    max-width: 900px;
}

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

    #features .features-grid details.feature-card--soon {
        order: 1;
    }
}

/* Funzionalità: illustrazione ballo1.png più grande, fusione morbida con lo sfondo (--bg) */
#features.section {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    background-color: var(--bg);
}

#features .features-bg-media {
    position: absolute;
    right: 0;
    bottom: 0;
    z-index: 0;
    pointer-events: none;
    max-width: min(96vw, 1240px);
    max-height: min(90vh, 920px);
    width: auto;
    height: auto;
    object-fit: contain;
    object-position: right bottom;
    transform: translateX(clamp(0.5rem, 4vw, 2.5rem));
    opacity: 0.94;
    mix-blend-mode: multiply;
    -webkit-mask-image: linear-gradient(to right,
            transparent 0%,
            rgba(0, 0, 0, 0.2) 5%,
            rgba(0, 0, 0, 0.65) 14%,
            #000 26%,
            #000 100%);
    mask-image: linear-gradient(to right,
            transparent 0%,
            rgba(0, 0, 0, 0.2) 5%,
            rgba(0, 0, 0, 0.65) 14%,
            #000 26%,
            #000 100%);
    -webkit-mask-size: 100% 100%;
    mask-size: 100% 100%;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
}

#features.section>*:not(.features-bg-media) {
    position: relative;
    z-index: 1;
}

@media (max-width: 1024px) {
    #features .features-bg-media {
        max-width: min(100vw, 720px);
        max-height: min(58vh, 560px);
        opacity: 0.9;
        transform: translateX(clamp(0.75rem, 6vw, 2.75rem));
        -webkit-mask-image: linear-gradient(to right, transparent 0%, rgba(0, 0, 0, 0.45) 12%, #000 28%, #000 100%);
        mask-image: linear-gradient(to right, transparent 0%, rgba(0, 0, 0, 0.45) 12%, #000 28%, #000 100%);
    }
}

#features details.feature-card {
    background: var(--card);
    border: 0.5px solid var(--card-border);
    border-radius: 16px;
    padding: 1.5rem;
    transition:
        border-color 0.38s ease,
        background 0.38s ease,
        box-shadow 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

#features details.feature-card:hover {
    border-color: rgba(168, 85, 247, 0.35);
    background: rgba(168, 85, 247, 0.04);
}

#features .feature-card-fx {
    display: none;
}

#features details.feature-card>summary {
    list-style: none;
    cursor: default;
}

#features details.feature-card>summary::-webkit-details-marker {
    display: none;
}

#features details.feature-card .feature-card-chev {
    display: none;
    flex-shrink: 0;
    width: 1.75rem;
    height: 1.75rem;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-size: 0.65rem;
    color: var(--muted);
    border: 0.5px solid var(--card-border);
    background: rgba(255, 255, 255, 0.04);
}

#features details.feature-card[open]>summary .feature-card-chev {
    transform: rotate(180deg);
    border-color: rgba(168, 85, 247, 0.45);
    background: rgba(168, 85, 247, 0.12);
    color: #e9d5ff;
}

.feature-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

.icon-purple {
    background: rgba(168, 85, 247, 0.15);
}

.icon-pink {
    background: rgba(236, 72, 153, 0.15);
}

.icon-cyan {
    background: rgba(6, 182, 212, 0.15);
}

.icon-yellow {
    background: rgba(234, 179, 8, 0.15);
}

.icon-green {
    background: rgba(34, 197, 94, 0.15);
}

.icon-orange {
    background: rgba(249, 115, 22, 0.15);
}

.feature-title {
    font-family: 'Syne', sans-serif;
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

#features details.feature-card>summary .feature-title {
    margin-bottom: 0;
}

.badge-soon {
    display: inline-block;
    font-size: 0.6rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0.2rem 0.5rem;
    border-radius: 6px;
    background: rgba(168, 85, 247, 0.15);
    color: #c084fc;
    border: 0.5px solid rgba(168, 85, 247, 0.3);
    margin-left: 0.4rem;
    vertical-align: middle;
}

.feature-card--soon {
    position: relative;
}

.badge-soon--tr {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    margin-left: 0;
    vertical-align: unset;
    z-index: 2;
}

.feature-desc {
    font-size: 0.85rem;
    color: var(--muted);
    line-height: 1.6;
    font-weight: 300;
}

@media (min-width: 1025px) {
    #features details.feature-card>summary {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        pointer-events: none;
    }

    #features details.feature-card--soon>summary {
        display: block;
        cursor: default;
    }

    #features details.feature-card .feature-card-chev {
        display: none !important;
    }

    #features details.feature-card>summary .feature-icon {
        margin-bottom: 1rem;
    }

    #features details.feature-card--soon>summary .feature-icon {
        margin-bottom: 1rem;
    }

    #features details.feature-card--soon>summary .feature-title {
        margin-bottom: 0.5rem;
    }

    #features details.feature-card .feature-desc-animate {
        display: block;
    }

    #features details.feature-card .feature-desc-animate>.feature-desc {
        opacity: 1;
        transform: none;
        filter: none;
        transition: none;
        overflow: visible;
    }
}

@media (max-width: 1024px) {
    #features details.feature-card {
        position: relative;
        padding: 0.95rem 1.05rem;
    }

    #features details.feature-card>summary {
        display: flex;
        align-items: center;
        gap: 0.85rem;
        width: 100%;
        min-height: 48px;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
    }

    #features details.feature-card .feature-card-chev {
        display: inline-flex;
        margin-left: auto;
        transition:
            transform 0.48s cubic-bezier(0.34, 1.25, 0.64, 1),
            background 0.35s ease,
            border-color 0.35s ease,
            color 0.35s ease,
            box-shadow 0.4s ease;
    }

    #features details.feature-card>summary .feature-icon {
        margin-bottom: 0;
        flex-shrink: 0;
        transition: transform 0.45s cubic-bezier(0.34, 1.2, 0.64, 1), box-shadow 0.4s ease;
    }

    #features details.feature-card[open]>summary .feature-icon {
        transform: scale(1.06);
        box-shadow: 0 6px 20px rgba(168, 85, 247, 0.2);
    }

    #features details.feature-card>summary .feature-title {
        flex: 1;
        min-width: 0;
        font-size: 0.95rem;
        line-height: 1.25;
        transition: color 0.35s ease;
    }

    #features details.feature-card[open]>summary .feature-title {
        color: rgba(250, 250, 255, 0.98);
    }

    /* Altezza disclosure animata (grid 0fr → 1fr) */
    #features details.feature-card .feature-desc-animate {
        display: grid;
        grid-template-rows: 0fr;
        transition: grid-template-rows 0.52s cubic-bezier(0.33, 1, 0.32, 1);
    }

    #features details.feature-card[open] .feature-desc-animate {
        grid-template-rows: 1fr;
    }

    #features details.feature-card .feature-desc-animate>.feature-desc {
        overflow: hidden;
        min-height: 0;
        margin-top: 0.85rem;
        padding-top: 0.85rem;
        border-top: 0.5px solid var(--card-border);
        opacity: 0;
        transform: translateY(12px);
        transition:
            opacity 0.42s cubic-bezier(0.22, 1, 0.36, 1) 0.06s,
            transform 0.5s cubic-bezier(0.22, 1, 0.36, 1) 0.05s,
            border-color 0.35s ease;
    }

    #features details.feature-card[open] .feature-desc-animate>.feature-desc {
        opacity: 1;
        transform: translateY(0);
        border-top-color: rgba(168, 85, 247, 0.28);
    }

    #features details.feature-card[open] {
        overflow: hidden;
        border-color: rgba(168, 85, 247, 0.5);
        background: linear-gradient(165deg, rgba(168, 85, 247, 0.1) 0%, rgba(168, 85, 247, 0.04) 42%, rgba(14, 12, 28, 0.2) 100%);
        box-shadow:
            0 0 0 1px rgba(168, 85, 247, 0.18),
            0 18px 46px rgba(0, 0, 0, 0.38),
            0 4px 14px rgba(168, 85, 247, 0.12);
    }

    #features .features-grid .feature-card-fx {
        display: block;
        position: absolute;
        inset: 0;
        z-index: 0;
        pointer-events: none;
        border-radius: inherit;
        overflow: hidden;
    }

    #features details.feature-card>summary,
    #features details.feature-card .feature-desc-animate {
        position: relative;
        z-index: 1;
    }

    #features details.feature-card .feature-card-fx span {
        position: absolute;
        top: 14%;
        left: 50%;
        width: 1.25rem;
        height: 1.25rem;
        display: flex;
        align-items: center;
        justify-content: center;
        opacity: 0;
        will-change: transform, opacity;
    }

    #features details.feature-card .feature-card-fx span::before {
        display: block;
        line-height: 1;
    }

    #features details.feature-card:not([open]) .feature-card-fx span {
        animation: none;
        opacity: 0;
        transform: none;
    }

    #features details.feature-card[open] .feature-card-fx span {
        animation: featureFxFall 1.08s cubic-bezier(0.28, 0.65, 0.37, 0.98) forwards;
    }

    #features details.feature-card .feature-card-fx span:nth-child(1) {
        left: 6%;
        animation-delay: 0s;
        --fx-dx: -10px;
        --fx-r: -14deg;
    }

    #features details.feature-card .feature-card-fx span:nth-child(2) {
        left: 18%;
        animation-delay: 0.06s;
        --fx-dx: 14px;
        --fx-r: 10deg;
    }

    #features details.feature-card .feature-card-fx span:nth-child(3) {
        left: 30%;
        animation-delay: 0.12s;
        --fx-dx: -6px;
        --fx-r: 4deg;
    }

    #features details.feature-card .feature-card-fx span:nth-child(4) {
        left: 42%;
        animation-delay: 0.03s;
        --fx-dx: 8px;
        --fx-r: -6deg;
    }

    #features details.feature-card .feature-card-fx span:nth-child(5) {
        left: 54%;
        animation-delay: 0.09s;
        --fx-dx: -12px;
        --fx-r: 12deg;
    }

    #features details.feature-card .feature-card-fx span:nth-child(6) {
        left: 66%;
        animation-delay: 0.15s;
        --fx-dx: 6px;
        --fx-r: -8deg;
    }

    #features details.feature-card .feature-card-fx span:nth-child(7) {
        left: 78%;
        animation-delay: 0.05s;
        --fx-dx: 11px;
        --fx-r: 7deg;
    }

    #features details.feature-card .feature-card-fx span:nth-child(8) {
        left: 88%;
        animation-delay: 0.11s;
        --fx-dx: -5px;
        --fx-r: -11deg;
    }

    #features details.feature-card .feature-card-fx span:nth-child(9) {
        left: 12%;
        animation-delay: 0.18s;
        --fx-dx: 9px;
        --fx-r: 5deg;
    }

    #features details.feature-card .feature-card-fx span:nth-child(10) {
        left: 72%;
        animation-delay: 0.02s;
        --fx-dx: -9px;
        --fx-r: 14deg;
    }

    #features details.feature-fx-theme--pulse .feature-card-fx span::before {
        content: '●';
        font-size: 0.52rem;
        color: #c084fc;
        text-shadow: 0 0 10px rgba(168, 85, 247, 0.65);
    }

    #features details.feature-fx-theme--music .feature-card-fx span::before {
        content: '♪';
        font-size: 0.95rem;
        color: #f9a8d4;
        text-shadow: 0 0 8px rgba(244, 114, 182, 0.45);
    }

    #features details.feature-fx-theme--coin .feature-card-fx span::before {
        content: '€';
        font-size: 0.82rem;
        font-weight: 800;
        color: #67e8f9;
        text-shadow: 0 0 8px rgba(34, 211, 238, 0.4);
    }

    #features details.feature-fx-theme--stars .feature-card-fx span::before {
        content: '★';
        font-size: 0.88rem;
        color: #fde047;
        text-shadow: 0 0 10px rgba(250, 204, 21, 0.55);
    }

    #features details.feature-fx-theme--car .feature-card-fx span::before {
        content: '🚗';
        font-size: 0.72rem;
    }

    #features details.feature-fx-theme--spark .feature-card-fx span::before {
        content: '✨';
        font-size: 0.72rem;
    }

    #features .feature-soon-pill {
        font-size: 0.55rem;
        padding: 0.15rem 0.4rem;
    }
}

@media (max-width: 1024px) and (prefers-reduced-motion: reduce) {
    #features details.feature-card .feature-desc-animate {
        transition: none !important;
    }

    #features details.feature-card .feature-desc-animate>.feature-desc {
        transition: none !important;
    }

    #features details.feature-card .feature-card-chev {
        transition: transform 0.15s linear !important;
    }

    #features details.feature-card[open]>summary .feature-icon {
        transform: none !important;
        box-shadow: none !important;
    }

    #features details.feature-card[open] {
        transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease !important;
    }

    #features .feature-card-fx {
        display: none !important;
    }
}

.feature-soon-pill {
    margin-left: 0.2rem;
    flex-shrink: 0;
    align-self: center;
}

@media (min-width: 1025px) {
    #features details.feature-card--soon .feature-soon-pill {
        position: absolute;
        top: 1.25rem;
        right: 1.25rem;
        margin-left: 0;
        z-index: 2;
    }
}

/* ─── HOW IT WORKS ─── */
.how-section {
    padding: 6rem max(5vw, env(safe-area-inset-left)) 6rem max(5vw, env(safe-area-inset-right));
    background: var(--bg2);
    border-top: 0.5px solid var(--card-border);
    border-bottom: 0.5px solid var(--card-border);
}

.steps {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 2.35rem;
    max-width: min(560px, 100%);
    margin: 3rem auto 0;
    position: relative;
}

.step {
    position: relative;
    max-width: min(100%, 420px);
}

/* 01 sx, 02 dx, 03 sx, 04 dx, 05 sx */
.step:nth-child(1),
.step:nth-child(3),
.step:nth-child(5) {
    align-self: flex-start;
    text-align: left;
}

.step:nth-child(2),
.step:nth-child(4) {
    align-self: flex-end;
    text-align: right;
}

.step.step-5 {
    margin-top: clamp(0.9rem, 2.5vw, 1.85rem);
}

.step-5-inner {
    position: relative;
    max-width: min(100%, 420px);
    padding-top: 1.65rem;
}

/* "In futuro" sopra il cerchio 05 (mobile: ancora un po' più vicino al 05) */
.step-5-inner .step-5-badge {
    position: absolute;
    top: -0.38rem;
    left: 28px;
    transform: translateX(-50%);
    margin-left: 0;
    white-space: nowrap;
    z-index: 2;
}

.step-5-idea-cta-wrap {
    text-align: center;
    margin-top: 1.15rem;
}

@media (max-width: 1023px) {
    .step-5-idea-cta-wrap {
        margin-top: 1.42rem;
    }
}

.step-num {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--bg);
    border: 0.5px solid var(--card-border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    font-size: 1.1rem;
    margin: 0 0 1rem 0;
    position: relative;
    z-index: 1;
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.15), rgba(236, 72, 153, 0.15));
    color: #c084fc;
}

.step:nth-child(1) .step-num,
.step:nth-child(3) .step-num,
.step:nth-child(5) .step-num {
    margin-right: auto;
}

.step:nth-child(2) .step-num,
.step:nth-child(4) .step-num {
    margin-left: auto;
    margin-right: 0;
}

.step-title {
    font-family: 'Syne', sans-serif;
    font-weight: 700;
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
}

.step-desc {
    font-size: 0.8rem;
    color: var(--muted);
    line-height: 1.6;
}

/* Desktop: 5 passi in fila con linea orizzontale sotto i cerchi (allineati) */
@media (min-width: 1024px) {
    .how-section .steps {
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: flex-start;
        justify-content: space-between;
        gap: 0.5rem;
        max-width: min(1120px, 100%);
        margin-left: auto;
        margin-right: auto;
        padding-top: 0.25rem;
        --how-step-head: 2.05rem;
        isolation: isolate;
    }

    .how-section .steps::before {
        content: '';
        position: absolute;
        left: 10%;
        right: 10%;
        /* Asse verticale al centro del cerchio (56px): sotto l’area badge + metà altezza */
        top: calc(var(--how-step-head) + 28px);
        height: 2px;
        border-radius: 2px;
        transform: translateY(-50%);
        background: linear-gradient(90deg,
                rgba(168, 85, 247, 0.15),
                rgba(168, 85, 247, 0.45) 20%,
                rgba(236, 72, 153, 0.4) 80%,
                rgba(236, 72, 153, 0.12));
        z-index: -1;
        pointer-events: none;
    }

    .how-section .step {
        flex: 1 1 0;
        min-width: 0;
        max-width: none;
        align-self: flex-start !important;
        text-align: center;
        position: relative;
        z-index: 0;
        padding: 0 0.25rem;
    }

    /* Sfondo opaco sul cerchio: altrimenti la linea si vede attraverso il gradiente semi-trasparente */
    .how-section .step-num {
        z-index: 1;
        background: var(--bg2);
        border: 0.5px solid rgba(168, 85, 247, 0.42);
        color: #d8b4fe;
        box-shadow:
            inset 0 0 0 1px rgba(168, 85, 247, 0.18),
            inset 0 0 22px rgba(236, 72, 153, 0.08);
    }

    .how-section .step-5-inner .step-5-badge {
        z-index: 2;
    }

    .how-section .step:not(.step-5) .step-num {
        margin-top: var(--how-step-head);
    }

    .how-section .step .step-num,
    .how-section .step:nth-child(1) .step-num,
    .how-section .step:nth-child(2) .step-num,
    .how-section .step:nth-child(3) .step-num,
    .how-section .step:nth-child(4) .step-num,
    .how-section .step:nth-child(5) .step-num {
        margin-left: auto;
        margin-right: auto;
    }

    .how-section .step.step-5 {
        margin-top: 0;
    }

    .how-section .step-5-inner {
        max-width: none;
        margin-left: auto;
        margin-right: auto;
        padding-top: 0;
        position: relative;
        min-height: calc(var(--how-step-head) + 56px);
    }

    .how-section .step-5-inner .step-5-badge {
        position: absolute;
        top: -1.9rem;
        left: 50%;
        transform: translateX(-50%);
        margin: 0;
    }

    .how-section .step.step-5 .step-num {
        margin-top: var(--how-step-head);
    }

    .how-section .step-title {
        font-size: 0.88rem;
    }

    .how-section .step-desc {
        font-size: 0.74rem;
        line-height: 1.45;
    }

    .how-section .step-5-idea-cta-wrap .btn-primary {
        padding: 0.65rem 1.15rem;
        font-size: 0.85rem;
    }
}

/* ─── PRICING ─── */
.pricing-section {
    padding: 6rem max(5vw, env(safe-area-inset-left)) 6rem max(5vw, env(safe-area-inset-right));
}

.pricing-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    max-width: 700px;
    margin-top: 3rem;
}

.plan-card {
    background: var(--card);
    border: 0.5px solid var(--card-border);
    border-radius: 20px;
    padding: 2rem;
    position: relative;
    overflow: hidden;
    transition: transform 0.2s;
}

.plan-card:hover {
    transform: translateY(-4px);
}

.plan-card.featured {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.12), rgba(236, 72, 153, 0.08));
    border-color: rgba(168, 85, 247, 0.4);
}

.plan-popular {
    position: absolute;
    top: 1.2rem;
    right: 1.2rem;
    background: linear-gradient(135deg, #a855f7, #ec4899);
    border-radius: 100px;
    padding: 0.25rem 0.75rem;
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #fff;
}

.plan-name {
    font-size: 0.8rem;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 0.75rem;
}

.plan-price {
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    font-size: 2.5rem;
    line-height: 1;
    letter-spacing: -0.03em;
    margin-bottom: 0.25rem;
}

.plan-price sup {
    font-size: 1.2rem;
    vertical-align: super;
    font-weight: 700;
}

.plan-period {
    font-size: 0.8rem;
    color: var(--muted);
    margin-bottom: 1.5rem;
}

.plan-features {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin-bottom: 1.75rem;
}

.plan-features li {
    font-size: 0.85rem;
    color: var(--muted);
    display: flex;
    gap: 0.5rem;
    align-items: flex-start;
}

.plan-features li span:first-child {
    color: #a855f7;
    font-size: 0.9rem;
    flex-shrink: 0;
    margin-top: 1px;
}

/* ─── SOCIAL ─── */
.social-section {
    padding: 6rem max(5vw, env(safe-area-inset-left)) 6rem max(5vw, env(safe-area-inset-right));
    background: var(--bg2);
    border-top: 0.5px solid var(--card-border);
    border-bottom: 0.5px solid var(--card-border);
}

/* Ordine verticale: stats → funzionalità → come funziona → community → recensioni */
.home-mid-flow {
    display: flex;
    flex-direction: column;
}

.social-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    max-width: 900px;
    align-items: center;
    margin-top: 3rem;
}

.chat-mockup {
    background: rgba(255, 255, 255, 0.03);
    border: 0.5px solid var(--card-border);
    border-radius: 20px;
    overflow: hidden;
}

.chat-header {
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 0.5px solid var(--card-border);
    padding: 1rem 1.2rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.chat-avatar-group {
    display: flex;
}

.chat-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1.5px solid var(--bg2);
    margin-left: -8px;
    font-size: 0.65rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-avatar:first-child {
    margin-left: 0;
}

.av1 {
    background: linear-gradient(135deg, #a855f7, #7c3aed);
}

.av2 {
    background: linear-gradient(135deg, #ec4899, #db2777);
}

.av3 {
    background: linear-gradient(135deg, #06b6d4, #0891b2);
}

.av4 {
    background: linear-gradient(135deg, #eab308, #ca8a04);
}

.chat-group-name {
    font-family: 'Syne', sans-serif;
    font-weight: 700;
    font-size: 0.9rem;
}

.chat-group-sub {
    font-size: 0.7rem;
    color: var(--muted);
}

.chat-messages {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.msg {
    display: flex;
    gap: 0.5rem;
    align-items: flex-end;
}

.msg.self {
    flex-direction: row-reverse;
}

.msg-av {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    font-size: 0.55rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.msg-bubble {
    max-width: 75%;
    padding: 0.5rem 0.75rem;
    border-radius: 14px;
    font-size: 0.8rem;
    line-height: 1.4;
}

.msg-bubble.other {
    background: rgba(255, 255, 255, 0.07);
    color: var(--text);
    border-radius: 14px 14px 14px 4px;
}

.msg-bubble.self {
    background: linear-gradient(135deg, #7c3aed, #a855f7);
    color: #fff;
    border-radius: 14px 14px 4px 14px;
}

.chat-input-bar {
    border-top: 0.5px solid var(--card-border);
    padding: 0.75rem 1rem;
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.chat-input-inner {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 0.55rem;
    min-width: 0;
    background: rgba(255, 255, 255, 0.05);
    border: 0.5px solid var(--card-border);
    border-radius: 100px;
    padding: 0.38rem 0.85rem 0.38rem 0.75rem;
}

a.chat-input-inner {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}

a.chat-input-inner:hover {
    border-color: rgba(168, 85, 247, 0.35);
    background: rgba(255, 255, 255, 0.07);
}

.chat-input {
    flex: 1;
    min-width: 0;
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0.12rem 0;
    font-size: 0.8rem;
    color: var(--muted);
    font-family: 'DM Sans', sans-serif;
    outline: none;
}

.chat-send-link {
    text-decoration: none;
    display: flex;
    flex-shrink: 0;
    align-items: center;
}

.chat-send {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #a855f7, #ec4899);
    border-radius: 50%;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 0.8rem;
}

/* ─── CTA ─── */
.cta-section {
    padding: 8rem max(5vw, env(safe-area-inset-left)) 8rem max(5vw, env(safe-area-inset-right));
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta-section .orb1 {
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 700px;
    height: 400px;
    background: radial-gradient(ellipse, rgba(168, 85, 247, 0.15) 0%, transparent 70%);
}

.cta-section h2 {
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    font-size: clamp(2rem, 5vw, 4rem);
    letter-spacing: -0.04em;
    line-height: 1.05;
    margin-bottom: 1.5rem;
    position: relative;
}

.cta-section h2 span {
    background: linear-gradient(135deg, #a855f7, #ec4899);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.cta-section p {
    color: var(--muted);
    font-size: 1rem;
    margin-bottom: 2.5rem;
    position: relative;
    font-weight: 300;
}

/* ─── FOOTER ─── */
footer {
    border-top: 0.5px solid var(--card-border);
    padding: 3rem max(5vw, env(safe-area-inset-left)) calc(3rem + env(safe-area-inset-bottom, 0px)) max(5vw, env(safe-area-inset-right));
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 2rem;
}

.footer-copy {
    font-size: 0.8rem;
    color: var(--muted);
}

.footer-links {
    display: flex;
    gap: 1.5rem;
}

.footer-links a {
    font-size: 0.8rem;
    color: var(--muted);
    text-decoration: none;
    transition: color 0.2s;
}

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

/* ─── BANNER POPUP ─── */
.banner-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.banner-overlay.visible {
    opacity: 1;
    pointer-events: all;
}

.banner-card {
    background: var(--bg2);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 2.4rem 2rem;
    max-width: 440px;
    width: 90%;
    text-align: center;
    position: relative;
    box-shadow: var(--glow), 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: bannerIn 0.5s ease both;
}

@keyframes bannerIn {
    from {
        opacity: 0;
        transform: scale(0.92) translateY(20px);
    }

    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.banner-close {
    position: absolute;
    top: 0.8rem;
    right: 0.8rem;
    background: rgba(255, 255, 255, 0.06);
    border: 0.5px solid var(--card-border);
    color: var(--muted);
    width: 30px;
    height: 30px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.banner-close:hover {
    background: rgba(255, 255, 255, 0.12);
    color: var(--text);
}

.banner-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #fbbf24;
    background: rgba(234, 179, 8, 0.12);
    border: 0.5px solid rgba(234, 179, 8, 0.3);
    border-radius: 999px;
    padding: 0.25rem 0.75rem;
    margin-bottom: 1rem;
}

.banner-card h2 {
    font-family: 'Syne', sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 0.6rem;
    color: var(--text);
}

.banner-card h2 span {
    background: linear-gradient(135deg, var(--accent), var(--accent2));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.banner-card p {
    color: var(--muted);
    font-size: 0.88rem;
    line-height: 1.55;
    margin-bottom: 1.4rem;
}

.banner-actions {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.banner-actions a {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.2rem;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.15s, box-shadow 0.15s;
}

.banner-actions a:hover {
    transform: translateY(-1px);
}

.banner-btn-primary {
    background: linear-gradient(135deg, var(--accent), var(--accent2));
    color: #fff;
    border: none;
    box-shadow: 0 4px 20px rgba(168, 85, 247, 0.3);
}

.banner-btn-secondary {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--card-border);
    color: var(--text);
}

.banner-btn-secondary:hover {
    border-color: var(--accent);
}

.banner-divider {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin: 0.2rem 0;
    color: var(--muted);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.banner-divider::before,
.banner-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--card-border);
}

/* ─── ANIMATIONS ─── */
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes featureFxFall {
    0% {
        transform: translate3d(0, 0, 0) rotate(var(--fx-r, 0deg)) scale(0.45);
        opacity: 0;
    }

    12% {
        opacity: 1;
    }

    100% {
        transform: translate3d(var(--fx-dx, 0px), min(16vh, 8.5rem), 0) rotate(calc(var(--fx-r, 0deg) + 20deg)) scale(1);
        opacity: 0;
    }
}

.fade-up {
    animation: fadeUp 0.7s ease both;
}

.delay-1 {
    animation-delay: 0.1s;
}

.delay-2 {
    animation-delay: 0.2s;
}

.delay-3 {
    animation-delay: 0.35s;
}

.delay-4 {
    animation-delay: 0.5s;
}

/* ─── RESPONSIVE ─── */
/* Nav tablet / iPad (es. Air ~820px verticale): hamburger + drawer fino a 1024px */
@media (max-width: 1024px) {
    .nav-menu-btn {
        display: inline-flex;
    }

    /* Menu aperto: sopra rumore (1000), popup mappa (1100), ecc. — sotto cookie (2000) */
    .site-nav.nav-open {
        z-index: 1900;
        background: transparent;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        /* la barra logo+hamburger è .nav-top fixed; evita doppio riempimento sopra */
        padding-top: 0;
        padding-bottom: 0;
    }

    /* Barra brand fuori dal flusso del drawer: resta in alto a sinistra sul viewport, sopra al pannello */
    .site-nav.nav-open .nav-top {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        z-index: 1903;
        flex: none;
        width: 100%;
        max-width: none;
        box-sizing: border-box;
        padding: calc(0.9rem + env(safe-area-inset-top, 0px)) max(4.5vw, env(safe-area-inset-right, 0px)) 0.9rem max(4.5vw, env(safe-area-inset-left, 0px));
        margin: 0;
        background: var(--bg);
        border-bottom: 0.5px solid var(--border);
        box-shadow: 0 6px 20px rgba(0, 0, 0, 0.35);
    }

    nav ul.nav-main-list {
        position: fixed;
        top: 0;
        right: 0;
        z-index: 1901;
        width: min(19.5rem, 86vw);
        max-width: 100%;
        min-width: 0;
        flex-shrink: 0;
        height: 100vh;
        height: 100dvh;
        margin: 0;
        padding: calc(4.85rem + env(safe-area-inset-top, 0px)) 1.35rem calc(2rem + env(safe-area-inset-bottom, 0px));
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        background: var(--bg);
        border-left: 0.5px solid rgba(168, 85, 247, 0.28);
        box-shadow: -12px 0 48px rgba(0, 0, 0, 0.45);
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        transform: translateX(102%);
        transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
    }

    .site-nav.nav-open ul.nav-main-list {
        transform: translateX(0);
    }

    nav ul.nav-main-list li {
        border-bottom: 0.5px solid rgba(255, 255, 255, 0.06);
    }

    nav ul.nav-main-list li:last-child {
        border-bottom: none;
    }

    nav ul.nav-main-list a {
        display: flex;
        align-items: center;
        min-height: 48px;
        padding: 0.35rem 0;
        font-size: 1rem;
    }

    nav ul.nav-main-list li:last-child {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        padding-top: 0.35rem;
        padding-bottom: 0.25rem;
    }

    nav ul.nav-main-list a.nav-cta {
        display: inline-flex !important;
        align-items: center;
        justify-content: center;
        width: auto;
        max-width: 100%;
        min-height: 44px;
        padding: 0.5rem 1.15rem !important;
        box-sizing: border-box;
        margin-left: -0.45rem;
        margin-right: auto;
    }

    nav.site-nav {
        padding: calc(0.9rem + env(safe-area-inset-top, 0px)) max(4.5vw, env(safe-area-inset-right, 0px)) 0.9rem max(4.5vw, env(safe-area-inset-left, 0px));
    }

    .logo-text {
        font-size: 1.12rem;
    }

    .logo-beta {
        font-size: 0.56rem;
        padding: 0.16rem 0.4rem;
    }
}

@media (max-width: 768px) {
    .map-body {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto;
        height: auto;
    }

    /* Mappa sopra, elenco locali sotto (ordine visivo indipendente dal DOM) */
    .map-body .map-view {
        grid-row: 1;
    }

    .map-body .map-sidebar {
        grid-row: 2;
    }

    .map-sidebar {
        display: flex;
        max-height: 280px;
        border-right: none;
        border-top: 0.5px solid var(--card-border);
        border-bottom: none;
        -webkit-overflow-scrolling: touch;
    }

    .map-topbar {
        padding: 0.55rem 0.75rem;
        gap: 0.45rem;
        align-items: stretch;
    }

    .map-use-location-btn {
        padding: 0.4rem 0.75rem;
        font-size: 0.76rem;
        border-radius: 8px;
        gap: 0.35rem;
    }

    .map-use-location-btn .map-use-location-icon {
        font-size: 0.92rem;
    }

    .map-topbar .map-dots {
        display: none;
    }

    .map-search {
        padding: 0.32rem 0.5rem;
        gap: 0.35rem;
        border-radius: 7px;
    }

    #mapSearchInput {
        font-size: 0.78rem !important;
    }

    .radius-control {
        gap: 0.28rem;
    }

    .radius-control>span:first-of-type {
        margin-left: 0.25rem !important;
        font-size: 0.66rem !important;
    }

    #radiusKmPill {
        font-size: 0.68rem !important;
        padding: 0.12rem 0.42rem !important;
    }

    #mapSearchClear {
        width: 26px !important;
        height: 26px !important;
        border-radius: 7px !important;
    }

    #radiusKmRange {
        width: 92px !important;
    }

    /* Card “Caricamento” iniziale: meno ingombro su tablet/phone */
    #clubCardLoading .club-tags,
    #clubCardLoading .crowd-bar,
    #clubCardLoading .crowd-label {
        display: none !important;
    }

    #clubCardLoading {
        padding: 0.5rem 0.7rem !important;
    }

    #clubCardLoading .club-meta {
        margin-bottom: 0 !important;
    }

    .map-sidebar .map-sidebar-load-placeholder {
        display: flex;
        min-height: 44px;
    }

    .map-view {
        height: 380px;
    }

    .map-sidebar .club-card {
        padding: 0.62rem 0.72rem;
    }

    .map-sidebar .club-name {
        font-size: 0.82rem;
    }

    .map-sidebar .club-meta {
        font-size: 0.7rem;
        margin-bottom: 0.45rem;
    }

    .map-sidebar .tag {
        font-size: 0.58rem;
        padding: 0.12rem 0.42rem;
    }

    .map-sidebar .crowd-bar {
        margin-top: 0.45rem;
        height: 3px;
    }

    .map-sidebar .crowd-label {
        font-size: 0.6rem;
    }

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

    .pricing-grid {
        grid-template-columns: 1fr;
    }

    .social-grid {
        grid-template-columns: 1fr;
    }

    footer {
        grid-template-columns: 1fr;
    }
}

/* ─── MOBILE MODE (tutto il sito) ─── */
@media (max-width: 820px) {
    nav.site-nav {
        padding: calc(0.9rem + env(safe-area-inset-top, 0px)) max(4.5vw, env(safe-area-inset-right, 0px)) 0.9rem max(4.5vw, env(safe-area-inset-left, 0px));
    }

    .map-topbar {
        gap: 0.65rem;
    }

    .map-topbar-search-row {
        flex-wrap: wrap;
    }

    .map-search {
        width: 100%;
    }
}

@media (max-width: 640px) {
    .section {
        padding-top: 4.25rem;
        padding-bottom: 4.25rem;
    }

    .logo-text {
        font-size: 1.12rem;
    }

    .logo-beta {
        font-size: 0.56rem;
        padding: 0.16rem 0.4rem;
    }

    .hero {
        padding: 8.5rem max(5vw, env(safe-area-inset-left)) 5.5rem max(5vw, env(safe-area-inset-right));
    }

    .hero-buttons {
        width: 100%;
        max-width: 22rem;
        flex-direction: column;
        align-items: stretch;
    }

    .hero-buttons .btn-primary,
    .hero-buttons .btn-secondary {
        width: 100%;
        justify-content: center;
        min-height: 48px;
    }

    .map-container {
        border-radius: 18px;
    }

    .map-body {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto;
        height: auto;
    }

    .map-body .map-view {
        grid-row: 1;
    }

    .map-body .map-sidebar {
        grid-row: 2;
    }

    /* Lista sotto la mappa, scroll orizzontale */
    .map-sidebar {
        display: flex;
        max-height: none;
        border-right: none;
        border-top: 0.5px solid var(--card-border);
        border-bottom: none;
        overflow-x: auto;
        overflow-y: hidden;
        flex-direction: row;
        gap: 0.55rem;
        padding: 0.62rem 0.7rem;
        scroll-snap-type: x mandatory;
    }

    .map-sidebar .club-card {
        min-width: 172px;
        max-width: 172px;
        padding: 0.48rem 0.55rem;
        scroll-snap-align: start;
    }

    .map-sidebar .club-name {
        font-size: 0.74rem;
        line-height: 1.25;
    }

    .map-sidebar .club-stars {
        font-size: 0.58rem;
        letter-spacing: 0.5px;
    }

    .map-sidebar .club-stars-loader {
        width: 12px;
        height: 12px;
        border-width: 1.5px;
    }

    .map-sidebar .club-meta {
        font-size: 0.65rem;
        margin-bottom: 0.32rem;
    }

    .map-sidebar .tag {
        font-size: 0.52rem;
        padding: 0.1rem 0.34rem;
    }

    .map-sidebar .crowd-bar {
        margin-top: 0.32rem;
        height: 3px;
    }

    .map-sidebar .crowd-label {
        font-size: 0.55rem;
        margin-top: 0.22rem;
    }

    .map-sidebar .sponsored-label {
        font-size: 0.52rem;
        margin-bottom: 0.22rem;
    }

    .map-topbar {
        padding: 0.45rem 0.55rem;
        gap: 0.35rem;
    }

    .map-use-location-btn {
        padding: 0.36rem 0.55rem;
        font-size: 0.72rem;
    }

    .map-search {
        padding: 0.28rem 0.42rem;
        gap: 0.28rem;
        border-radius: 6px;
    }

    #mapSearchInput {
        font-size: 0.74rem !important;
    }

    .radius-control {
        gap: 0.22rem;
    }

    .radius-control>span:first-of-type {
        margin-left: 0.15rem !important;
        font-size: 0.62rem !important;
    }

    #radiusKmPill {
        font-size: 0.64rem !important;
        padding: 0.1rem 0.36rem !important;
    }

    #mapSearchClear {
        width: 24px !important;
        height: 24px !important;
        font-size: 0.75rem !important;
    }

    #clubCardLoading .club-tags,
    #clubCardLoading .crowd-bar,
    #clubCardLoading .crowd-label {
        display: none !important;
    }

    #clubCardLoading {
        padding: 0.45rem 0.55rem !important;
    }

    #clubCardLoading .club-meta {
        margin-bottom: 0 !important;
    }

    .map-sidebar .map-sidebar-load-placeholder {
        display: flex;
        min-height: 48px;
        flex-shrink: 0;
    }

    .map-view {
        height: 440px;
    }

    #radiusKmRange {
        width: 130px !important;
    }

    /* Slider verticale su cellulare (trascinabile in verticale) */
    .radius-control {
        margin-left: auto;
        gap: 0.4rem;
        align-items: center;
    }

    .radius-control .radius-track {
        width: 24px;
        height: 72px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        background: rgba(255, 255, 255, 0.04);
        border: 0.5px solid var(--card-border);
        border-radius: 8px;
    }

    #radiusKmRange {
        width: 72px !important;
        transform: rotate(-90deg);
        transform-origin: center;
    }
}

/* Scheda dettaglio su telefono: tutto visibile senza scroll interno (griglia 2 col + fixed) */
@media (max-width: 768px) {
    .detail-popup {
        position: fixed;
        bottom: max(10px, env(safe-area-inset-bottom, 0px));
        left: 50%;
        right: auto;
        transform: translateX(-50%);
        width: min(calc(100vw - 18px), 360px);
        max-width: min(calc(100vw - 18px), 360px);
        padding: 0.42rem 0.5rem 0.48rem;
        border-radius: 12px;
        max-height: none;
        overflow: visible;
        overflow-x: hidden;
        border: 1px solid rgba(168, 85, 247, 0.55);
        box-shadow:
            0 10px 32px rgba(0, 0, 0, 0.5),
            0 0 0 1px rgba(168, 85, 247, 0.28),
            0 0 28px rgba(168, 85, 247, 0.22);
        z-index: 1100;
        display: grid;
        grid-template-columns: 1fr 1fr;
        column-gap: 0.45rem;
        row-gap: 0.12rem;
        align-content: start;
    }

    .detail-popup .popup-name-row,
    .detail-popup .popup-live,
    .detail-popup .popup-vai {
        grid-column: 1 / -1;
    }

    .detail-popup .popup-name {
        font-size: 0.82rem;
        line-height: 1.18;
    }

    .detail-popup .popup-name-row {
        gap: 0.3rem;
        align-items: flex-start;
    }

    .detail-popup .popup-disco {
        font-size: 1rem;
        padding: 0.06rem;
    }

    .detail-popup .popup-live {
        font-size: 0.58rem;
        margin-top: 0.12rem;
        margin-bottom: 0.2rem;
        gap: 0.22rem;
    }

    .detail-popup .popup-live-dot {
        width: 4px;
        height: 4px;
    }

    .detail-popup .popup-row {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.06rem;
        font-size: 0.58rem;
        padding: 0.2rem 0.28rem;
        margin: 0;
        border-radius: 6px;
        border-bottom: none;
        background: rgba(255, 255, 255, 0.04);
        min-width: 0;
    }

    .detail-popup .popup-row span {
        font-size: 0.56rem;
        font-weight: 600;
        color: rgba(226, 232, 240, 0.65);
        letter-spacing: 0.01em;
    }

    .detail-popup .popup-row strong {
        font-size: 0.62rem;
        font-weight: 600;
        text-align: left;
        line-height: 1.2;
        word-break: break-word;
        max-width: 100%;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .detail-popup .popup-row:last-of-type {
        grid-column: 1 / -1;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        gap: 0.35rem;
    }

    .detail-popup .popup-row:last-of-type strong {
        display: block;
        -webkit-line-clamp: unset;
        text-align: right;
        flex: 1;
        min-width: 0;
    }

    .detail-popup .popup-vai {
        margin-top: 0.35rem;
        padding: 0.42rem 0.55rem;
        font-size: 0.72rem;
        border-radius: 10px;
    }

    .detail-popup .fmn-live-badge {
        font-size: 0.52rem !important;
        padding: 0.1rem 0.38rem !important;
        margin-left: 0.28rem !important;
    }
}

@media (max-width: 420px) {
    .hero h1 {
        font-size: 2.6rem;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
        justify-content: center;
    }

    .map-view {
        height: 380px;
    }

    .detail-popup {
        width: min(calc(100vw - 14px), 340px);
        max-width: min(calc(100vw - 14px), 340px);
        padding: 0.38rem 0.42rem 0.44rem;
        column-gap: 0.38rem;
    }

    .detail-popup .popup-name {
        font-size: 0.78rem;
    }

    .detail-popup .popup-row {
        padding: 0.16rem 0.22rem;
    }

    .detail-popup .popup-row strong {
        font-size: 0.58rem;
    }

    .detail-popup .popup-vai {
        font-size: 0.68rem;
        padding: 0.38rem 0.48rem;
    }
}

/* ─── COOKIE BANNER (essenziali) ─── */
.cookie-banner {
    position: fixed;
    left: max(16px, env(safe-area-inset-left, 0px));
    right: max(16px, env(safe-area-inset-right, 0px));
    bottom: max(16px, env(safe-area-inset-bottom, 0px));
    z-index: 2000;
    display: none;
    background: rgba(14, 12, 28, 0.88);
    border: 0.5px solid rgba(168, 85, 247, 0.28);
    box-shadow: 0 18px 60px rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(18px);
    border-radius: 16px;
    padding: 0.95rem 0.95rem;
}

.cookie-banner.visible {
    display: flex;
}

.cookie-banner .cookie-inner {
    display: flex;
    gap: 0.9rem;
    width: 100%;
    align-items: flex-start;
}

.cookie-banner .cookie-text {
    flex: 1;
    min-width: 0;
}

.cookie-banner .cookie-title {
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    font-size: 0.95rem;
    margin-bottom: 0.25rem;
}

.cookie-banner .cookie-desc {
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.86rem;
    line-height: 1.45;
}

.cookie-banner .cookie-desc a {
    color: #22d3ee;
    text-decoration: none;
}

.cookie-banner .cookie-desc a:hover {
    text-decoration: underline;
}

.cookie-banner .cookie-actions {
    display: flex;
    gap: 0.6rem;
    align-items: center;
    flex: 0 0 auto;
}

.cookie-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0.5px solid rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.06);
    color: var(--text);
    border-radius: 12px;
    padding: 0.65rem 0.9rem;
    cursor: pointer;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.9rem;
    white-space: nowrap;
}

.cookie-btn.primary {
    border: none;
    background: linear-gradient(135deg, #a855f7, #ec4899);
}

@media (max-width: 520px) {
    .cookie-banner .cookie-inner {
        flex-direction: column;
        align-items: stretch;
    }

    .cookie-banner .cookie-actions {
        justify-content: flex-end;
    }

    .cookie-btn {
        width: 100%;
        justify-content: center;
    }
}
