/* #region 1. SETUP, VARIABILI E TIPOGRAFIA */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;700;900&display=swap');

:root {
    --primary: #00a8ff;
    --primary-purple: #d633ff;
    --primary-green: #00ff41;
    --primary-gold: #ffd700;
    --bg: #0a0a0a;
    --card-bg: #161616;
    --text: #f5f5f5;
    --text-muted: #a0a0a0;
    --nav-border: #222;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    background-color: var(--bg) !important; /* CAMBIATO: Usa la variabile nera e forza con !important */
    transition: background-color 0.5s ease, color 0.5s ease;
}

body {
    font-family: 'Plus Jakarta Sans', sans-serif;
    background-color: var(--bg) !important; /* CAMBIATO: Forza il nero anche qui */
    color: var(--text);
    line-height: 1.6;
    margin: 0;
    padding: 0;
    width: 100%;
    overflow-x: hidden;
    position: relative;
}



.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ==========================================================================
   STRUTTURA CARD E LOGICA DEI TEMI
   ========================================================================== */

/* Regole Base per tutte le Card (Centratura e Adattabilità) */
.project-card {
    background: var(--card-bg);
    padding: 40px;
    border-radius: 20px;
    border: 1px solid var(--nav-border);
    transition: 0.4s;
    margin-bottom: 30px;
    display: flex;
    flex-direction: column; 
    align-items: center;    /* Centra gli elementi orizzontalmente */
    justify-content: center; /* Centra gli elementi verticalmente */
    text-align: center;     /* Centra tutte le righe di testo */
}

.card-content {
    display: flex;
    flex-direction: column; /* Ordine verticale */
    align-items: center;    /* Centratura orizzontale */
    width: 100%;
    max-width: 650px;       /* Testo leggibile su PC */
}

/* Forziamo l'ordine richiesto indipendentemente dalla posizione nell'HTML */
.card-content .tag { order: 1; margin-bottom: 15px; }
.card-content h2  { order: 2; margin-bottom: 15px; }
.card-content p   { order: 3; margin-bottom: 25px; }
.card-content a   { order: 4; }

/* --- INTEGRAZIONE TEMI COLORATI --- */

/* a. Tema Blu (Default / Solar) */
.project-card.featured {
    border: 2px solid rgba(0, 168, 255, 0.3);
}
.project-card.featured .tag {
    background: rgba(0, 168, 255, 0.1);
    color: var(--primary);
    border: 1px solid rgba(0, 168, 255, 0.3);
}

/* b. Tema Viola (YouTube / Neon) */
.project-card.neon-card {
    border: 2px solid rgba(214, 51, 255, 0.3) !important;
}
.project-card.neon-card .tag {
    background: rgba(214, 51, 255, 0.1);
    color: var(--primary-purple);
    border: 1px solid rgba(214, 51, 255, 0.3);
}
.project-card.neon-card .btn-contact {
    border-color: var(--primary-purple) !important;
    color: var(--primary-purple) !important;
}
.project-card.neon-card .btn-contact:hover {
    background-color: var(--primary-purple) !important;
    color: #fff !important;
    box-shadow: 0 0 20px rgba(214, 51, 255, 0.4);
}

/* c. Tema Giallo (Business) */
.project-card.business-card {
    border: 2px solid rgba(255, 215, 0, 0.3) !important;
}
.project-card.business-card .tag {
    background: rgba(255, 215, 0, 0.1);
    color: var(--primary-gold);
    border: 1px solid rgba(255, 215, 0, 0.3);
}

/* d. Tema Verde (Vibe Password) */
.project-card.vibe-card {
    border: 2px solid rgba(0, 255, 65, 0.3) !important;
}
.project-card.vibe-card .tag {
    background: rgba(0, 255, 65, 0.1);
    color: var(--primary-green);
    border: 1px solid rgba(0, 255, 65, 0.3);
}

/* Responsive Mobile */
@media (max-width: 768px) {
    .project-card { padding: 30px 20px; }
    .card-content { max-width: 100%; }
}

.project-card.cta-more-projects {
    margin-top: 80px;
    margin-bottom: 80px;
    background: rgba(255, 255, 255, 0.02);
    border: 2px dashed rgba(255, 255, 255, 0.2) !important; /* Il bordo tratteggiato ora è forzato */
    display: flex;
    justify-content: center;
    align-items: center;
}

.project-card.cta-more-projects .card-content {
    display: flex;
    flex-direction: column;
    align-items: center; /* Centra titolo, testo e bottone all'interno */
}

.project-card.cta-more-projects:hover {
    border-color: rgba(255, 255, 255, 0.4) !important;
    transform: translateY(-5px);
}
/* #endregion */
/* #region 2. NAVIGAZIONE E HEADER (HERO) */
nav {
    padding: 20px 0;
    border-bottom: 1px solid var(--nav-border);
    margin-bottom: 60px;
    transition: all 0.4s ease-in-out;
    display: flex; /* Forza il contenitore nav a usare flex */
    justify-content: space-between; /* Spinge i due gruppi UL ai lati opposti */
    align-items: center;
}

nav ul {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 0;
    align-items: center;
    /* Rimosso justify-content: space-between da qui per tenere i link uniti */
}

nav ul li {
    display: inline-block;
    margin-left: 30px; /* Distanza fissa tra i link del menu */
}

nav ul li:first-child {
    margin-left: 0; /* Il primo elemento di ogni gruppo non ha margine a sinistra */
}

nav a {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    transition: 0.3s;
    margin-left: 0 !important; 
}

/* MODIFICATO: Colore dinamico e bagliore al passaggio del mouse */
nav a:hover {
    color: var(--project-accent) !important;
    text-shadow: 0 0 12px var(--project-accent);
}

.logo {
    font-size: 2.2rem;
    font-weight: 900;
    color: var(--text) !important;
    text-decoration: none;
    letter-spacing: -2px;
    transition: 0.3s;
}

/* MODIFICATO: Anche il logo si illumina del colore del tema */
.logo:hover {
    color: var(--project-accent) !important;
    text-shadow: 0 0 15px var(--project-accent);
    transform: scale(1.05);
}

header {
    text-align: center;
    padding: 40px 0;
    margin-bottom: 60px;
}

header h1, 
header .hero-subtitle {
    position: relative;
    z-index: 99;
    color: #ffffff !important;
}

h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 10px;
    letter-spacing: -2px;
    color: var(--text);
}

.hero-subtitle {
    font-size: 1.4rem;
    line-height: 1.5;
    max-width: 500px;
    margin: 15px auto 30px auto;
    color: var(--text-muted);
    font-weight: 400;
    opacity: 0.9;
    text-shadow: 0 2px 15px rgba(0,0,0,0.8);
}
/* #endregion */
/* #region 3. BOTTONI E ELEMENTI UI PER TIPOLOGIA */

/* Struttura Base Bottoni */
.btn-contact, .btn-vibe-color, .btn-business-theme, .btn-back, .btn-app-gold {
    display: inline-block;
    padding: 12px 25px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.85rem;
    transition: all 0.3s ease;
    cursor: pointer;
}

/* Bottone Contatti (Blu) */
.btn-contact {
    background-color: rgba(0, 168, 255, 0.1);
    color: var(--primary) !important;
    border: 2px solid var(--primary);
}
.btn-contact:hover {
    background-color: var(--primary);
    color: #fff !important;
    box-shadow: 0 0 20px rgba(0, 168, 255, 0.4);
    transform: scale(1.05);
}

/* Bottone Indietro */
.btn-back {
    border: 1.5px solid var(--primary) !important; 
    color: var(--primary) !important;
    margin-top: 20px;
}
.btn-back:hover {
    background-color: var(--primary) !important;
    color: #ffffff !important;
    box-shadow: 0 0 15px rgba(0, 168, 255, 0.4);
    transform: translateX(-5px);
}

/* Bottone Vibe (Verde) */
.btn-vibe-color {
    background-color: transparent !important;
    color: var(--primary-green) !important;
    border: 2px solid var(--primary-green) !important;
}
.btn-vibe-color:hover {
    background-color: var(--primary-green) !important;
    color: #000 !important;
    box-shadow: 0 0 20px rgba(0, 255, 65, 0.6) !important;
}

/* Bottone Business (Oro) */
.btn-business-theme {
    border: 1px solid var(--primary-gold) !important;
    color: var(--primary-gold) !important;
}
.btn-business-theme:hover {
    background: var(--primary-gold) !important;
    color: #000 !important;
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.5) !important;
}

/* Bottone App Gold */
.btn-app-gold {
    background-color: var(--primary-gold);
    color: #000 !important;
    border-radius: 5px;
}
.btn-app-gold:hover {
    background-color: transparent;
    color: var(--primary-gold) !important;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.4);
}
/* Card e Bottoni Sezione Contatti */
.contact-section {
    text-align: center;
    padding: 60px 0;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-top: 50px;
}

.contact-card {
    background: var(--card-bg);
    border: 1px solid var(--nav-border);
    padding: 40px;
    border-radius: 20px;
    text-decoration: none !important; /* Toglie la sottolineatura di Pico */
    transition: 0.4s all ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--text) !important;
}

.contact-card i {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: var(--primary); /* Di default blu, come il tuo brand */
}

.contact-card h3 {
    margin-bottom: 10px;
    font-weight: 700;
}

.contact-card p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin: 0;
}

/* Effetto Hover "Grande Tasto" */
.contact-card:hover {
    transform: translateY(-10px);
    border-color: var(--primary);
    box-shadow: 0 15px 30px rgba(0, 168, 255, 0.2);
    background: rgba(255, 255, 255, 0.03);
}

/* Colori specifici per Icone (opzionale, se vuoi differenziarli) */
.contact-card:hover i.fa-linkedin { color: #0077b5; }
.contact-card:hover i.fa-github { color: #fafafa; }
.contact-card:hover i.fa-envelope { color: #ff4b2b; }

/* --- LOGICA RESPONSIVE PER MOBILE --- */
@media (max-width: 768px) {
    .contact-grid {
        /* Forza 2 colonne: LinkedIn e GitHub staranno affiancati */
        grid-template-columns: 1fr 1fr; 
    }

    /* La terza card (Email) si allarga su entrambe le colonne */
    .contact-card:nth-child(3) {
        grid-column: span 2;
    }
}

/* Se lo schermo è piccolissimo (es. iPhone vecchio), le mettiamo tutte in colonna */
@media (max-width: 480px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }
    .contact-card:nth-child(3) {
        grid-column: span 1;
    }
}

/* #endregion */
/* #region 4. CARD E PROGETTI - HOVER PULITO E GLOW TEMATICO */

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

/* Regola Base per tutte le Card - Assicuriamoci che non ci siano sottolineature */
.project-card {
    background: var(--card-bg);
    padding: 40px;
    border-radius: 20px;
    border: 1px solid var(--nav-border);
    transition: 0.4s;
    margin-bottom: 30px;
    display: flex;
    flex-direction: column; 
    align-items: center;    
    justify-content: center; 
    text-align: center;
    /* Rimuoviamo qualsiasi decorazione di testo ereditata */
    text-decoration: none !important;
}
.tag {
    display: inline-block;
    padding: 5px 15px;
    background: rgba(0, 168, 255, 0.1); /* Colore base blu */
    color: var(--primary);
    border: 1px solid rgba(0, 168, 255, 0.3);
    border-radius: 50px !important; /* <--- Questo li rende TONDI */
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 15px;
}

/* Pulizia Titoli - Rimuove la linea blu inferiore */
.project-card h2, 
.project-card h3 {
    margin-bottom: 10px;
    letter-spacing: -1px;
    color: var(--text);
    /* Forziamo la rimozione di bordi inferiori ereditati */
    border-bottom: none !important;
    padding-bottom: 0 !important;
    text-decoration: none !important;
}

/* Sottotitoli - Pulizia finale per sicurezza */
.title-solar, .title-youtube, .title-password, .title-business {
    border-bottom: none !important;
    padding-bottom: 0 !important;
    display: inline-block;
    margin: 0 auto 15px auto;
}

/* --- LOGICA HOVER PULITA CON GLOW TEMATICO --- */

/* a. Tema Blu (Default) */
.project-card.featured:hover {
    transform: translateY(-5px);
    border-color: var(--primary) !important;
    box-shadow: 0 10px 30px rgba(0, 168, 255, 0.4) !important;
}

/* b. Tema Viola (Neon) */
.project-card.neon-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-purple) !important;
    box-shadow: 0 10px 30px rgba(214, 51, 255, 0.4) !important;
}

/* c. Tema Giallo (Business) */
.project-card.business-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-gold) !important;
    box-shadow: 0 10px 30px rgba(255, 215, 0, 0.6) !important;
}

/* d. Tema Verde (Vibe Password) */
.project-card.vibe-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-green) !important;
    box-shadow: 0 10px 30px rgba(0, 255, 65, 0.4) !important;
}

/* Responsive Mobile */
@media (max-width: 768px) {
    .project-card { padding: 30px 20px; }
}

/* #endregion */
/* #region 5. COMPONENTI MULTIMEDIALI (CAROUSEL, IMAGES, FRAMES) */
.profile-pic {
    width: 220px;
    height: 220px;
    object-fit: cover;
    border-radius: 50%;
    border: 4px solid var(--primary);
    margin: 30px auto;
    display: block;
    animation: fadeInScale 1.2s ease-out forwards, pulseGlow 3s ease-in-out infinite;
}

.cover-container img {
    /* Glow Statico: Sempre visibile grazie a var(--project-accent) */
    box-shadow: 0 0 40px var(--project-accent) !important; 
    border: 2px solid var(--project-accent);
    transition: all 0.5s ease-in-out !important;
    width: 100%;
    border-radius: 15px;
    opacity: 1; /* Massima visibilità dell'immagine */
}

.cover-container img:hover {
    /* Al passaggio del mouse, il viola si intensifica invece di cambiare colore */
    box-shadow: 0 0 70px var(--project-accent) !important;
    transform: scale(1.01);
}

/* Vibe Carousel - FIX LARGHEZZA BLOCCATA */
.vibe-carousel {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 35px; 
    padding: 20px 10px 40px 10px;
    -webkit-overflow-scrolling: touch;
    width: 100%;
}

.vibe-carousel::-webkit-scrollbar { height: 6px; }
.vibe-carousel::-webkit-scrollbar-thumb { background: rgba(0, 255, 65, 0.3); border-radius: 10px; }

/* --- STILE BASE PER TUTTI --- */

.vibe-carousel-container {
    width: 100%;
    /* Riduciamo la larghezza massima per tenerli più vicini al centro */
    max-width: 1550px !important; 
    margin: 0 auto !important; 
    padding: 0 20px;
    overflow: visible !important;
}

.vibe-carousel {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr); 
    /* Riduciamo il gap da 60px a 30px per avvicinarli */
    gap: 30px; 
    width: 100%;
    /* Allineamento verticale: fondamentale per i titoli sotto */
    align-items: start; 
}

.carousel-item {
    background: transparent !important;
    border: none !important;
    width: 100% !important;
    display: flex;
    flex-direction: column;
    /* Centra tutto il blocco rispetto alla colonna */
    align-items: center; 
}

.carousel-item .img-container {
    width: 100%;
    /* Forziamo un'altezza minima contenuta per pareggiare la base delle immagini */
    min-height: 200px;
    display: flex;
    align-items: flex-end; /* Spinge le immagini verso il basso per allinearle alla base */
    justify-content: center;
    margin-bottom: 25px; /* Spazio costante tra immagine e titolo */
}

.carousel-item img {
    width: 100% !important;
    height: auto !important;
    display: block;
    object-fit: contain; 
    border-radius: 20px;
    filter: drop-shadow(0 15px 35px rgba(0,0,0,0.8));
}

/* --- ALLINEAMENTO TITOLI E TESTI --- */
.carousel-item .caption {
    width: 100%;
    text-align: center;
    /* Rimuoviamo margini extra che potrebbero sballare l'allineamento */
    margin: 0; 
}

.carousel-item .caption strong {
    display: block;
    font-size: 1.25rem !important;
    /* Forziamo un'altezza minima per il titolo per evitare che titoli su 1 o 2 righe 
       spostino il paragrafo sottostante */
    min-height: 1.5em; 
    line-height: 1.2;
    margin-bottom: 10px;
}

.carousel-item .caption p {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin: 0;
    line-height: 1.4;
}

/* --- MOBILE --- */
@media (max-width: 991px) {
    .vibe-carousel {
        display: flex !important;
        gap: 15px;
    }
    .carousel-item {
        flex: 0 0 300px !important;
    }
}

.circular-frame-solar {
    width: 250px;
    height: 250px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid rgba(0, 162, 255, 0.3);
    box-shadow: 0 0 20px rgba(0, 162, 255, 0.1);
    transition: all 0.4s ease;
}

.carousel-item .caption {
    padding: 15px;
    text-align: center;
}

.carousel-item .caption strong {
    display: block;
    font-size: 1rem;
    margin-bottom: 5px;
}

/* Gestione Indicatore Swipe */
.swipe-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 20px auto 40px auto;
    gap: 10px;
}

.swipe-text {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--text-muted);
}

.swipe-hand svg {
    width: 30px;
    height: 30px;
    animation: swipeAnim 2s infinite ease-in-out;
}

@keyframes swipeAnim {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(20px); }
}
/* Fix per evitare le barre azzurre/glitch su Vibe Solar Mobile */
@media (max-width: 768px) {
    .vibe-carousel-container {
        overflow: hidden !important; /* Impedisce al browser di creare scroll extra */
        -webkit-overflow-scrolling: touch;
    }

    .carousel-item img {
        height: auto !important;
        max-height: 250px; /* Evita che l'immagine occupi troppo spazio verticale */
        object-fit: contain !important;
    }

    /* Rimuove eventuali ombre eccessive che causano lag su Safari mobile */
    .cover-container img {
        box-shadow: 0 0 20px var(--project-accent) !important;
    }
}
/* #endregion *//* #endregion */
/* #region 6. TEMI DI PAGINA */

/* REGOLA GENERALE: Forza il nero su tutte le pagine a tema */
.project-blue, 
.project-green, 
.project-purple, 
.project-gold {
    background-color: var(--bg) !important;
}

/* --- TEMA VERDE (Vibe Password) --- */
.project-green h3 {
    color: #00ff41; 
    font-size: 1.5rem; 
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 40px;
    margin-bottom: 20px;
    text-align: center;
}

/* Carosello Verde */
.project-green .carousel-item .caption strong { color: #00ff41; }
.project-green .carousel-item { border-color: rgba(0, 255, 65, 0.15); }
.project-green .vibe-carousel::-webkit-scrollbar-thumb { background: rgba(0, 255, 65, 0.5); }
.project-green .swipe-hand svg { stroke: #00ff41 !important; }

/* --- TEMA BLU (Vibe Solar) --- */
.project-blue h3 {
    color: #00a2ff;
    font-size: 1.5rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 40px;
    margin-bottom: 20px;
    text-align: center;
}

/* Carosello Blu */
.project-blue .carousel-item .caption strong { color: #00a2ff; }
.project-blue .carousel-item { border-color: rgba(0, 162, 255, 0.15); }
.project-blue .vibe-carousel::-webkit-scrollbar-thumb { background: rgba(0, 162, 255, 0.5); }
.project-blue .swipe-hand svg { stroke: #00a2ff !important; }


/* --- GESTIONE MANINA SWIPE (Visibile solo su Mobile) --- */
.swipe-indicator {
    display: none; /* Nasconde su PC */
}

@media (max-width: 768px) {
    .swipe-indicator {
        display: flex;
        flex-direction: column;
        align-items: center;
        margin-bottom: 30px;
    }
}

@keyframes swipeAnim {
    0%, 100% { transform: translateX(-10px); }
    50% { transform: translateX(10px); }
}

/* --- HOVER NAVIGAZIONE --- */
/* Effetto Glow SOLO sulla linea inferiore in Vibe Solar */
.project-blue nav:hover {
    border-bottom: 1px solid #00a8ff !important;
    /* L'ombra ha 0 offset orizzontale e si espande solo verso il basso */
    box-shadow: 0 8px 15px -50px rgba(0, 168, 255, 0.4);
}

/* Opzionale: Applica la stessa logica agli altri temi */
.project-yellow nav:hover {
    border-bottom: 1px solid #ffd700 !important;
    box-shadow: 0 8px 15px -50px rgba(255, 215, 0, 0.4);
}

.project-purple nav:hover {
    border-bottom: 1px solid #bc66ff !important;
    box-shadow: 0 8px 15px -50px rgba(188, 102, 255, 0.4);
}

.project-green nav:hover {
    border-bottom: 1px solid #00ff41 !important;
    box-shadow: 0 8px 15px -50px rgba(0, 255, 65, 0.4);
}
/* #endregion */
/* #region 7. ANIMAZIONI (@KEYFRAMES) */

@keyframes fadeInScale {
    from { opacity: 0; transform: scale(0.8) translateY(20px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

@keyframes pulseGlow {
    0%, 100% { box-shadow: 0 0 30px hsla(200, 100%, 50%, 0.3); transform: scale(1); }
    50% { box-shadow: 0 0 60px rgba(0, 168, 255, 0.6); transform: scale(1.02); }
}

@keyframes swipe-hand-x {
    0%, 100% { transform: translateX(15px); opacity: 0.4; }
    50% { transform: translateX(-15px); opacity: 1; }
}
/* #endregion */
/* #region 8. MEDIA QUERIES (RESPONSIVE COMPLETO)*/

/* MOBILE (Sotto i 768px) */
@media (max-width: 768px) {
    nav.container { padding: 15px 10px !important; }
    nav ul { gap: 5px; }
    nav a { margin-left: 10px !important; font-size: 0.85rem; white-space: nowrap; }
    .logo { font-size: 1.5rem !important; }
    nav ul {
        gap: 0 !important;
    }

    nav ul li {
        margin-left: 10px !important; /* Riduce lo spazio tra Home, Progetti, Contatti */
    }

    nav a {
        font-size: 0.8rem !important;
    }
}

    .project-card {
        align-items: center !important;
        text-align: center !important;
        padding: 30px 20px !important;
    }

    .tag { margin: 0 auto 15px auto !important; }
    
    .project-card .btn-contact, 
    .project-card .btn-vibe-color,
    .project-card .btn-business-theme {
        display: table !important;
        margin: 25px auto 0 auto !important;
    }

    .circular-frame-solar { width: 180px; height: 180px; margin: 0 auto 20px auto; }
}

/* DESKTOP (Sopra i 992px) */
@media (min-width: 992px) {
    .container { max-width: 1000px !important; }
    
    .project-card.featured {
        grid-column: 1 / -1;
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 40px;
        padding: 50px;
    }

    .vibe-carousel {
        display: grid !important;
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 30px !important;
        overflow: visible;
    }

    .carousel-item { flex: none !important; width: 100% !important; }
    
    .swipe-indicator-container { display: none !important; }
    
    .hero-subtitle { font-size: 2rem !important; max-width: 1000px; }
}
@media (max-width: 768px) {
    /* Trova il contenitore che tiene le due colonne (es. un div o section) */
    .grid-problema-soluzione { 
        display: flex !important;
        flex-direction: column !important; /* Forza la disposizione verticale */
        gap: 40px !important; /* Distanzia le due sezioni tra loro */
        text-align: center !important;
    }

    .grid-problema-soluzione div {
        width: 100% !important;
        max-width: 100% !important;
    }

    /* Riduciamo leggermente i titoli per farli stare su una riga */
    .grid-problema-soluzione h3 {
        font-size: 1.5rem !important;
        margin-bottom: 15px !important;
    }
}
/* FIX SPECIFICO PER VIBE SOLAR MOBILE */
@media (max-width: 768px) {
    /* Forza le colonne a mettersi una sopra l'altra */
    .section-problema-soluzione {
        grid-template-columns: 1fr !important;
        display: flex !important;
        flex-direction: column !important;
        gap: 20px !important;
    }

    /* Evita che Fancybox o il Carousel creino scroll orizzontale */
    .vibe-carousel-container {
        padding: 0 !important;
        overflow: hidden !important;
    }

    /* Ridimensiona i titoli che 'spingono' fuori il layout */
    h1 {
        font-size: 2.2rem !important;
    }
    
    .hero-subtitle {
        font-size: 1.1rem !important;
    }
}
/* #endregion */
/* #region 9. FOOTER UNIVERSALE DINAMICO */

/* CONFIGURAZIONE COLORI */
.project-green  { --project-accent: #00ff41; }   /* Vibe Password */
.project-blue   { --project-accent: #00a8ff; }   /* IL TUO BLU ORIGINALE */
.project-purple { --project-accent: #bc66ff; }   /* VIOLA PER SLOWED & REVERBED */
.project-yellow { --project-accent: #ffd700; }   /* GIALLO PER BEP */

/* Default (Blu) */
body { --project-accent: #00a8ff; }

/* Stile Footer */
footer {
    padding: 80px 0 40px 0 !important;
    text-align: center;
}

/* Il pulsante rotondo userà ora il viola in questa pagina */
.link-back-vibe {
    color: var(--project-accent) !important;
    border: 1px solid var(--project-accent);
    padding: 12px 30px;
    border-radius: 50px; /* <--- Rotondo come richiesto */
    text-decoration: none;
    font-weight: 600;
    text-transform: uppercase;
    display: inline-block;
    margin-bottom: 50px;
    transition: all 0.3s ease;
}

.link-back-vibe:hover {
    background-color: var(--project-accent);
    color: #000 !important;
    box-shadow: 0 0 20px var(--project-accent);
}

footer hr { 
    border: none;
    border-top: 1px solid var(--project-accent);
    opacity: 0.2;
    margin: 0 auto 40px auto;
    width: 100%;
}

.footer-social {
    display: flex;
    justify-content: center;
    gap: 70px; /* Distanza tra i link */
    margin-bottom: 20px;
}

.footer-social a {
    color: var(--project-accent) !important;
    text-decoration: none;
}

footer .signature {
    color: var(--project-accent) !important;
    opacity: 0.5;
}
/* #endregion */
