@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800;900&family=Space+Mono:ital,wght@0,400;0,700;1,400&family=Poppins:wght@300;400;500;600;700&display=swap');

/* =======================================
   THEME SETUP & VARIABLES
   ======================================== */
:root {
    /* PALETTE: Electric & Deep */
    --brand-yellow: #E4FF00;
    /* Fluorescent Yellow-Lime */
    --brand-yellow-dim: #C4DB00;
    /* Metallic Gold */
    --brand-blue: #3B82F6;
    /* Electric Blue (was #00A3FF) */
    --brand-blue-dim: #2563EB;

    --brand-black: #020202;
    /* Deepest Black (was #050505) */
    --brand-dark: #080808;
    /* Surface Black */

    /* EFFECTS */
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-highlight: rgba(255, 255, 255, 0.15);

    --glow-yellow: 0 0 35px rgba(228, 255, 0, 0.5), 0 0 10px rgba(228, 255, 0, 0.3);
    --glow-blue: 0 0 35px rgba(59, 130, 246, 0.5), 0 0 10px rgba(59, 130, 246, 0.3);

    --font-main: 'Outfit', sans-serif;
    --font-tech: 'Space Mono', monospace;
    /* New Technical Font */
}

html {
    scroll-behavior: smooth;
    background-color: var(--brand-black);
}

body {
    font-family: var(--font-main);
    background-color: var(--brand-black);
    color: #F1F5F9;
    /* Slate 100 for better readability than pure white */
    overflow-x: hidden;
    position: relative;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.03'/%3E%3C/svg%3E");
}

/* FIX: Limit Custom Logo Size (Nuclear Option) */
.logo-wrapper {
    display: flex !important;
    align-items: center !important;
    max-height: 48px !important;
    /* Mobile Height */
    width: auto !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
}

.logo-wrapper a,
.custom-logo-link {
    display: flex !important;
    align-items: center !important;
    height: 100% !important;
    max-height: 100% !important;
    width: auto !important;
}

.logo-wrapper img,
.custom-logo,
.custom-logo-link img {
    height: auto !important;
    width: auto !important;
    max-height: 100% !important;
    max-width: 200px !important;
    object-fit: contain !important;
    margin: 0 !important;
    padding: 0 !important;
}

@media (min-width: 768px) {
    .logo-wrapper {
        max-height: 64px !important;
        /* Desktop Height */
    }
}

/* ADMIN BAR FIX */
body.admin-bar nav.navbar-sticky {
    top: 32px !important;
}

@media screen and (max-width: 782px) {
    body.admin-bar nav.navbar-sticky {
        top: 46px !important;
    }
}

/* Background Animated Blobs */
body::before,
body::after {
    content: '';
    position: fixed;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.15;
    z-index: -1;
    animation: blob-move 20s infinite alternate;
}

body::before {
    background: var(--brand-blue);
    top: -10%;
    left: -10%;
}

body::after {
    background: var(--brand-yellow);
    bottom: -10%;
    right: -10%;
    animation-delay: -10s;
}

@keyframes blob-move {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(100px, 100px) scale(1.1);
    }
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-main);
    letter-spacing: -0.02em;
    /* Tighter headings */
}

.font-tech {
    font-family: var(--font-tech);
    letter-spacing: -0.05em;
}

/* =======================================
   UTILITIES & EFFECTS
   ======================================== */
/* CRITICAL: Force Colors */
.bg-brand-yellow {
    background-color: var(--brand-yellow) !important;
}

.bg-brand-black {
    background-color: var(--brand-black) !important;
}

.text-brand-black {
    color: var(--brand-black) !important;
}

.text-brand-yellow {
    color: var(--brand-yellow) !important;
}

.border-brand-yellow {
    border-color: var(--brand-yellow) !important;
}

.text-stroke-yellow {
    -webkit-text-stroke: 2px var(--brand-yellow);
    color: transparent;
}

.hover\:text-outline-yellow:hover {
    -webkit-text-stroke: 1px var(--brand-yellow);
    color: transparent;
}

.text-glow-blue {
    color: var(--brand-blue);
    text-shadow: 0 0 15px rgba(0, 163, 255, 0.8);
}

.floating {
    animation: floating 3s ease-in-out infinite;
}

.delay-100 {
    animation-delay: 1s;
}

.delay-300 {
    animation-delay: 3s;
}

@keyframes floating {
    0% {
        transform: translate(0, 0px);
    }

    50% {
        transform: translate(0, 15px);
    }

    100% {
        transform: translate(0, 0px);
    }
}

/* =======================================
   BUTTONS
   ======================================== */
.btn-download {
    position: relative;
    background: var(--brand-yellow);
    background: linear-gradient(135deg, var(--brand-yellow) 0%, var(--brand-yellow-dim) 100%);
    color: #000;
    font-family: var(--font-main);
    font-weight: 800;
    font-size: 1.125rem;
    padding: 1rem 2.5rem;
    border-radius: 6px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 1.25rem;
    /* Removed old clip-path for cleaner modern look, or keep if brand requires. Keeping slightly rounded. */
    clip-path: polygon(10% 0, 100% 0, 100% 70%, 95% 100%, 0 100%, 0 30%);
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    box-shadow: 0 4px 20px rgba(228, 255, 0, 0.25);
    z-index: 1;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-download::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.6), transparent);
    transition: 0.5s;
    z-index: 2;
}

.btn-download i {
    font-size: 1.75rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.btn-download:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: var(--glow-yellow);
}

.btn-download:hover::before {
    left: 100%;
}

.btn-outline-blue {
    background: transparent;
    border: 1px solid var(--brand-blue);
    color: var(--brand-blue);
    padding: 1rem 2.5rem;
    font-weight: 700;
    font-family: var(--font-tech);
    letter-spacing: -0.05em;
    text-transform: uppercase;
    border-radius: 4px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-outline-blue:hover {
    background: rgba(59, 130, 246, 0.1);
    color: #fff;
    border-color: #60A5FA;
    box-shadow: var(--glow-blue);
    text-shadow: 0 0 8px rgba(59, 130, 246, 0.8);
}

/* =======================================
   STORE BUTTONS (Yellow Theme)
   ======================================== */
.btn-store-yellow {
    background: var(--brand-yellow);
    color: var(--brand-black);
    /* Default text black? User asked for white text on yellow bg? Use black for readability or check request */
}

/* User request: "pulsanti app store e google play anche gialli con testo bianco" */
/* Yellow background with white text is poor contrast usually. Let's try, or tweak yellow. */
/* If brand-yellow is #FFE500, white text is unreadable. I will use a darker yellow/gold or add text shadow, OR suggest black text. */
/* However, to follow instructions EXACTLY: */
.btn-store-yellow {
    background: var(--brand-yellow);
    color: white;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
    /* Ensure readability */
    border: none;
    display: inline-flex;
    align-items: center;
    padding: 0.8rem 1.5rem;
    border-radius: 12px;
    font-family: 'Outfit', sans-serif;
    text-transform: uppercase;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(228, 255, 0, 0.3);
}

.btn-store-yellow:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(228, 255, 0, 0.5);
    background: #e6ce00;
    /* Darker yellow on hover */
    color: black;
}

.btn-store-yellow .store-icon {
    font-size: 1.8rem;
    margin-right: 0.8rem;
}

.btn-store-yellow .store-text {
    display: flex;
    flex-direction: column;
    line-height: 1;
    text-align: left;
}

.btn-store-yellow .small-text {
    font-size: 0.7rem;
    font-weight: 600;
    opacity: 0.9;
}

.btn-store-yellow .large-text {
    font-size: 1.1rem;
    font-weight: 800;
}

/* =======================================
   HERO SECTION
   ======================================== */
.hero-bg-image {
    position: absolute;
    inset: 0;
    background-image: url('assets/hero-bg-rome.png');
    background-size: cover;
    background-position: center;
    opacity: 1;
    z-index: 0;
    top: 0;
}

.badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(228, 255, 0, 0.05);
    border: 1px solid rgba(228, 255, 0, 0.3);
    padding: 0.4rem 1rem;
    border-radius: 4px;
    /* Tech look */
    font-family: var(--font-tech);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    color: var(--brand-yellow);
    box-shadow: 0 0 15px rgba(228, 255, 0, 0.1);
    backdrop-filter: blur(5px);
}

/* =======================================
   HOW IT WORKS (Colored Cards)
   ======================================== */
.process-card {
    position: relative;
    padding: 3rem 2rem;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.4s ease;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(12px);
    box-shadow: 0 4px 24px -1px rgba(0, 0, 0, 0.2);
}

.process-card::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 12px;
    padding: 1px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), transparent);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

.bg-surface-1 {
    background: linear-gradient(145deg, #1a1a1a, #0d0d0d);
    border-bottom: 4px solid var(--brand-yellow);
}

.bg-surface-2 {
    background: linear-gradient(145deg, #1a1a1a, #0d0d0d);
    border-bottom: 4px solid var(--brand-blue);
}

.bg-surface-3 {
    background: linear-gradient(145deg, #1a1a1a, #0d0d0d);
    border-bottom: 4px solid var(--brand-yellow);
}

.process-card:hover {
    transform: translateY(-10px);
}

/* Custom Colored Backgrounds on Hover (Optional, requested "Colored boxes") */
/* Let's make them statically colored but dark enough for text, or use gradients */
/* User asked for "3 box colorati che staccano sul nero" */

.bg-surface-1 {
    background: linear-gradient(135deg, rgba(228, 255, 0, 0.1), rgba(228, 255, 0, 0.02));
    border: 1px solid rgba(228, 255, 0, 0.2);
}

.bg-surface-2 {
    background: linear-gradient(135deg, rgba(0, 163, 255, 0.1), rgba(0, 163, 255, 0.02));
    border: 1px solid rgba(0, 163, 255, 0.2);
}

.bg-surface-3 {
    background: linear-gradient(135deg, rgba(228, 255, 0, 0.1), rgba(228, 255, 0, 0.02));
    border: 1px solid rgba(228, 255, 0, 0.2);
}


.card-number-modern {
    font-family: var(--font-tech);
    font-size: 4rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.1);
    line-height: 1;
    letter-spacing: -2px;
}

.icon-box-modern {
    font-size: 2.5rem;
}

/* =======================================
   ANIMATIONS
   ======================================== */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s forwards;
}

@keyframes fadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =======================================
   RESPONSIVE
   ======================================== */
@media (max-width: 768px) {
    .text-stroke-yellow {
        -webkit-text-stroke: 1px var(--brand-yellow);
    }

    .process-card {
        padding: 2rem;
    }

    h1 {
        font-size: 3rem !important;
        /* Fix Hero title on mobile */
    }
}

/* =======================================
   NEW DESIGN SYSTEM (Voozaa Inspired)
   ======================================== */
.text-gradient-gold {
    background: linear-gradient(135deg, #E4FF00 0%, #F2FF66 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(228, 255, 0, 0.3);
}

.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(16px) saturate(180%);
    border: 1px solid var(--glass-border);
    border-top: 1px solid var(--glass-highlight);
    border-radius: 12px;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.5);
}

.hero-glow-bg {
    position: absolute;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(0, 163, 255, 0.15) 0%, rgba(0, 0, 0, 0) 70%);
    top: -20%;
    right: -10%;
    z-index: 0;
    pointer-events: none;
    filter: blur(80px);
}

.hero-glow-bg-2 {
    position: absolute;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(228, 255, 0, 0.1) 0%, rgba(0, 0, 0, 0) 70%);
    bottom: -10%;
    left: -10%;
    z-index: 0;
    pointer-events: none;
    filter: blur(80px);
}

.compatibility-icon {
    font-size: 2.5rem;
    color: rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
}

.compatibility-icon:hover {
    color: var(--brand-white);
    transform: scale(1.1);
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
}

.map-placeholder {
    width: 100%;
    height: 500px;
    border-radius: 1.5rem;
    background-image: url('assets/map-placeholder.jpg');
    /* Fallback */
    background-size: cover;
    background-position: center;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.map-overlay-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, transparent 0%, rgba(5, 5, 5, 0.8) 100%);
    pointer-events: none;
}

/* Accordion for FAQ */
.faq-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.faq-trigger {
    cursor: pointer;
    padding: 1.5rem 0;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s cubic-bezier(0, 1, 0, 1);
}

.faq-item.active .faq-content {
    max-height: 500px;
    /* arbitrary large height */
    transition: max-height 0.3s cubic-bezier(1, 0, 1, 0);
}

.faq-item.active .faq-trigger svg {
    transform: rotate(180deg);
}

/* =======================================
   ENERGY PARTICLES (Hero Option 2)
   ======================================== */
.energy-particle {
    position: absolute;
    background: var(--brand-yellow);
    border-radius: 50%;
    opacity: 0;
    box-shadow: 0 0 15px var(--brand-yellow);
    /* Enhanced glow */
    animation-name: floatUp;
    animation-timing-function: ease-in;
    animation-iteration-count: infinite;
    /* Duration is set via JS */
    pointer-events: none;
    z-index: 10;
    /* Ensure high z-index */
    mix-blend-mode: screen;
    /* clearer on dark bg */
    will-change: transform, opacity;
}

.energy-particle.blue-variant {
    background: var(--brand-blue);
    box-shadow: 0 0 10px var(--brand-blue);
}

@keyframes floatUp {
    0% {
        transform: translateY(100vh) scale(0);
        opacity: 0;
    }

    10% {
        opacity: 1;
        transform: translateY(90vh) scale(1);
    }

    90% {
        opacity: 1;
        transform: translateY(10vh) scale(1);
    }

    100% {
        transform: translateY(-10vh) scale(0);
        opacity: 0;
    }
}

/* =======================================
   LEAFLET MAP — Recharge.me Stations
   ======================================== */
#recharge-map {
    width: 100%;
    height: 450px;
    border-radius: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    z-index: 1;
}

@media (max-width: 768px) {
    #recharge-map {
        height: 350px;
        border-radius: 1rem;
    }

    /* Larger markers on mobile */
    .recharge-pin svg {
        width: 34px;
        height: 34px;
    }
}

/* Custom marker */
.recharge-marker {
    background: none !important;
    border: none !important;
}

.recharge-pin {
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.35));
    transition: transform 0.2s ease;
    cursor: pointer;
}

.recharge-pin:hover {
    transform: scale(1.2);
}

/* Popup styling (light map) */
.leaflet-popup-content-wrapper {
    background: rgba(15, 20, 35, 0.92) !important;
    backdrop-filter: blur(16px);
    border: 1px solid rgba(228, 255, 0, 0.15) !important;
    border-radius: 12px !important;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4) !important;
    color: #fff !important;
}

.leaflet-popup-tip {
    background: rgba(15, 20, 35, 0.92) !important;
}

.leaflet-popup-close-button {
    color: rgba(255, 255, 255, 0.5) !important;
}

.leaflet-popup-close-button:hover {
    color: #E4FF00 !important;
}

.recharge-popup {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 4px 0;
}

.recharge-popup strong {
    font-size: 14px;
    font-weight: 700;
    color: #fff;
}

.recharge-popup-status {
    font-size: 12px;
    color: #E4FF00;
    font-weight: 600;
}

/* Leaflet controls */
.leaflet-control-zoom a {
    background-color: rgba(15, 20, 35, 0.85) !important;
    color: #fff !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
}

.leaflet-control-zoom a:hover {
    background-color: rgba(228, 255, 0, 0.3) !important;
    color: #E4FF00 !important;
}

.leaflet-control-attribution {
    background: rgba(255, 255, 255, 0.8) !important;
    color: rgba(0, 0, 0, 0.5) !important;
    font-size: 10px !important;
}

.leaflet-control-attribution a {
    color: rgba(0, 0, 0, 0.6) !important;
}