/* ============================================================================
   ESPLORA ONIRIKA - STILI PER SISTEMA DI NAVIGAZIONE
   ============================================================================ */

/* Reset e Base */
.esplora-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
    min-height: calc(100vh - 200px);
}

/* ============================================================================
   HEADER ESPLORAZIONE
   ============================================================================ */

.esplora-header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem 0;
    border-bottom: 1px solid var(--border-color, rgba(255, 255, 255, 0.1));
}

.esplora-header h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}


/* ============================================================================
   VISTA INDEX - GRIGLIA DOMINI
   ============================================================================ */

.domini-overview {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 2rem;
    align-items: start;
}

.domini-content {
    /* Contenitore per intro-text e domini-grid */
}

.domini-overview .intro-text {
    text-align: center;
    margin-bottom: 2rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.domini-overview .intro-text p {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 1rem;
    opacity: 0.9;
}

.domini-overview .warning {
    padding: 1rem;
    background: rgba(255, 193, 7, 0.1);
    border: 1px solid rgba(255, 193, 7, 0.3);
    border-radius: 6px;
    color: #ffc107;
    font-style: italic;
}

.domini-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-top: 2rem;
}

.dominio-card {
    background: linear-gradient(135deg,
            rgba(0, 0, 0, 0.6) 0%,
            rgba(0, 0, 0, 0.8) 100%);
    border: 1px solid var(--primary-color, rgba(255, 255, 255, 0.1));
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3),
        0 0 0 1px var(--primary-color, transparent);
}

.dominio-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg,
            var(--primary-color, #667eea) 0%,
            var(--secondary-color, #764ba2) 50%,
            var(--primary-color, #667eea) 100%);
}

.dominio-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4),
        0 0 20px var(--primary-color, rgba(255, 255, 255, 0.1));
    border-color: var(--secondary-color, rgba(255, 255, 255, 0.3));
}

.dominio-header h3 {
    margin: 0 0 1rem 0;
}

.dominio-header h3 a {
    color: var(--primary-color, #fff);
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: 600;
    transition: color 0.3s ease;
}

.dominio-header h3 a:hover {
    color: var(--secondary-color, #ccc);
}

.dominio-description {
    margin-bottom: 1.5rem;
    line-height: 1.6;
    opacity: 0.9;
    font-size: 0.95rem;
}

.dominio-actions {
    text-align: center;
}

.btn-explore {
    display: inline-block;
    padding: 0.8rem 1.5rem;
    background: linear-gradient(135deg,
            var(--primary-color, #667eea) 0%,
            var(--secondary-color, #764ba2) 100%);
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.btn-explore:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px var(--primary-color, rgba(0, 0, 0, 0.3));
    background: linear-gradient(135deg,
            var(--secondary-color, #764ba2) 0%,
            var(--primary-color, #667eea) 100%);
}

.btn-explore.secondary {
    background: transparent;
    border: 1px solid var(--primary-color, rgba(255, 255, 255, 0.3));
}

/* ============================================================================
   VISTA DOMINIO - DETTAGLIO + ZONE
   ============================================================================ */

.dominio-detail-header {
    text-align: center;
    margin-bottom: 2rem;
    padding: 2rem 0;
    border-bottom: 3px solid var(--primary-color, rgba(255, 255, 255, 0.1));
    position: relative;
    background: linear-gradient(135deg,
            rgba(0, 0, 0, 0.4) 0%,
            rgba(0, 0, 0, 0.6) 100%);
    border-radius: 12px;
    box-shadow: 0 0 30px var(--primary-color, transparent);
}

.dominio-detail-header h2 {
    font-size: 2.5rem;
    color: var(--primary-color, #fff);
    margin-bottom: 1rem;
    text-shadow: 0 0 20px var(--primary-color, transparent);
}

.navigation-controls {
    margin-bottom: 1rem;
}

.nav-back,
.nav-home,
.nav-dominio {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 0.9rem;
}

.nav-back:hover,
.nav-home:hover,
.nav-dominio:hover {
    color: var(--primary-color, #fff);
    text-shadow: 0 0 10px var(--primary-color, transparent);
}

.nav-separator {
    margin: 0 0.5rem;
    opacity: 0.5;
}

.dominio-content {
    display: grid;
    gap: 2rem;
}

.dominio-narrative {
    background: rgba(0, 0, 0, 0.4);
    padding: 2rem;
    border-radius: 8px;
    line-height: 1.7;
    font-size: 1.05rem;
    border-left: 4px solid var(--primary-color, #667eea);
}

.zone-exploration h3 {
    margin-bottom: 1.5rem;
    color: var(--primary-color, #fff);
    font-size: 1.8rem;
}

.zone-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.zona-narrative {
    background: linear-gradient(135deg,
            rgba(0, 0, 0, 0.6) 0%,
            rgba(0, 0, 0, 0.8) 100%);
    padding: 2rem;
    border-radius: 12px;
    border-left: 4px solid var(--primary-color, #667eea);
    box-shadow: -5px 0 15px var(--primary-color, transparent);
}

.zona-card {
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.zona-card:hover {
    border-color: var(--primary-color, rgba(255, 255, 255, 0.3));
    transform: translateY(-3px);
    box-shadow: 0 5px 20px var(--primary-color, rgba(0, 0, 0, 0.2));
}

.zona-card h4 {
    margin: 0 0 1rem 0;
}

.zona-card h4 a {
    color: #fff;
    text-decoration: none;
    font-size: 1.2rem;
    transition: color 0.3s ease;
}

.zona-card h4 a:hover {
    color: var(--primary-color, #ccc);
}

.zona-preview {
    margin-bottom: 1rem;
    opacity: 0.8;
    font-size: 0.9rem;
    line-height: 1.5;
}

.zona-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.zona-type {
    background: rgba(255, 255, 255, 0.1);
    padding: 0.3rem 0.8rem;
    border-radius: 12px;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.no-zones {
    text-align: center;
    padding: 3rem;
    opacity: 0.7;
    font-style: italic;
}

/* ============================================================================
   VISTA ZONA - ESPERIENZA COMPLETA
   ============================================================================ */

.zona-detail-header {
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.zona-detail-header h2 {
    font-size: 2.2rem;
    margin: 1rem 0;
    color: #fff;
}

.zona-detail-header .zona-meta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    opacity: 0.8;
}

.dominio-parent {
    font-style: italic;
    opacity: 0.7;
}

.zona-experience {
    display: grid;
    gap: 2rem;
}

.zona-narrative {
    background: linear-gradient(135deg,
            rgba(0, 0, 0, 0.6) 0%,
            rgba(0, 0, 0, 0.8) 100%);
    padding: 2rem;
    border-radius: 12px;
    border-left: 4px solid #667eea;
}

.zona-narrative h3 {
    color: #667eea;
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

.narrative-text {
    line-height: 1.7;
    font-size: 1.05rem;
}

.zona-mechanics {
    display: grid;
    gap: 1.5rem;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.zona-rischi,
.zona-comportamento,
.zona-temporali {
    background: rgba(0, 0, 0, 0.4);
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.zona-rischi {
    border-left-color: #dc3545;
}

.zona-comportamento {
    border-left-color: #17a2b8;
}

.zona-temporali {
    border-left-color: #ffc107;
}

.zona-rischi h4 {
    color: #dc3545;
    margin-bottom: 1rem;
}

.zona-comportamento h4 {
    color: #17a2b8;
    margin-bottom: 1rem;
}

.zona-temporali h4 {
    color: #ffc107;
    margin-bottom: 1rem;
}

.zona-navigation {
    background: rgba(0, 0, 0, 0.3);
    padding: 2rem;
    border-radius: 8px;
    margin-top: 2rem;
}

.zona-navigation h4 {
    margin-bottom: 1.5rem;
    color: #fff;
    font-size: 1.3rem;
}

.movement-options {
    display: grid;
    gap: 2rem;
}

.local-zones h5 {
    margin-bottom: 1rem;
    color: rgba(255, 255, 255, 0.8);
}

.zone-links {
    list-style: none;
    padding: 0;
    display: grid;
    gap: 0.5rem;
}

.zone-links li a {
    display: block;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    padding: 0.5rem 0;
    transition: color 0.3s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.zone-links li a:hover {
    color: var(--primary-color, #667eea);
    padding-left: 1rem;
    border-left: 3px solid var(--primary-color, #667eea);
}

.general-options {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* ============================================================================
   SIDEBAR ATMOSFERICA
   ============================================================================ */

.atmospheric-info {
    position: static;
    transform: none;
    background: rgba(0, 0, 0, 0.6);
    padding: 1.5rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    max-width: none;
    backdrop-filter: blur(10px);
    height: fit-content;
    top: 0;
}

.atmospheric-info h4 {
    margin-bottom: 1rem;
    color: #667eea;
    font-size: 1.1rem;
    text-align: center;
}

/* Aggiungi un link alla pagina meteo */
.meteo-link {
    display: block;
    text-align: center;
    margin-top: 1rem;
    padding: 0.8rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.meteo-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

.esplora-intro {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

.hero-exploration {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.hero-content h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.2rem;
    line-height: 1.6;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.warning-box {
    background: rgba(255, 193, 7, 0.1);
    border: 1px solid rgba(255, 193, 7, 0.3);
    border-radius: 8px;
    padding: 1.5rem;
    margin: 2rem 0;
    color: #ffc107;
}

.warning-box h3 {
    margin-bottom: 1rem;
    color: #ffc107;
}

.btn-enter-system {
    display: inline-block;
    padding: 1.2rem 2rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    margin: 2rem 0;
}

.btn-enter-system:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
}

.quick-access h4 {
    margin: 2rem 0 1rem 0;
    color: #667eea;
}

.quick-domini {
    display: grid;
    gap: 1rem;
    margin-top: 1rem;
}

.quick-dominio {
    display: block;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

.quick-dominio:hover {
    border-color: #667eea;
    transform: translateX(5px);
}

.quick-dominio strong {
    display: block;
    color: #667eea;
    margin-bottom: 0.5rem;
}

.quick-dominio span {
    font-size: 0.9rem;
    opacity: 0.8;
    line-height: 1.4;
}

.hero-sidebar {
    display: grid;
    gap: 1.5rem;
}

.info-box {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 1.5rem;
}

.info-box h4 {
    margin-bottom: 1rem;
    color: #667eea;
}

.info-box ul {
    list-style: none;
    padding: 0;
}

.info-box li {
    margin-bottom: 0.8rem;
    padding-left: 0rem;
    position: relative;
}

.info-box li::before {
    content: "→";
    position: absolute;
    left: 0;
    color: #667eea;
}

.info-box a {
    color: #667eea;
    text-decoration: none;
}

.info-box a:hover {
    text-decoration: underline;
}

@media (max-width: 768px) {
    .hero-exploration {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

    .hero-description {
        font-size: 1rem;
    }
}

/* ============================================================================
   ZONA NON TROVATA
   ============================================================================ */

.zona-not-found {
    text-align: center;
    padding: 4rem 2rem;
    opacity: 0.8;
}

.zona-not-found h2 {
    margin-bottom: 1rem;
    color: rgba(255, 255, 255, 0.7);
}

/* ============================================================================
   RESPONSIVE
   ============================================================================ */

@media (max-width: 768px) {
    .esplora-container {
        padding: 1rem 0.5rem;
    }

    .esplora-header h1 {
        font-size: 2rem;
    }

    .domini-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

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

    .zona-mechanics {
        grid-template-columns: 1fr;
    }

    .domini-overview {
        grid-template-columns: 1fr;
    }

    .atmospheric-info {
        order: -1;
        margin-bottom: 2rem;
    }

    .general-options {
        flex-direction: column;
    }

    .breadcrumb-step {
        display: block;
        margin: 0.25rem 0;
    }

    .breadcrumb-separator {
        display: none;
    }
}

@media (max-width: 480px) {
    .dominio-detail-header h2 {
        font-size: 1.8rem;
    }

    .zona-detail-header h2 {
        font-size: 1.6rem;
    }

    .zona-detail-header .zona-meta {
        flex-direction: column;
        gap: 0.5rem;
    }
}

/* ============================================================================
   AGGIUNTE CSS MIRATE PER TEMPLATE POTENZIATO - DA AGGIUNGERE A esplora.css
   ============================================================================ */

/* === PALETTE COLORI DINAMICHE === */
.dominio-palette {
    display: flex;
    gap: 0.4rem;
    margin: 0.8rem 0;
    align-items: center;
}

/* Palette centrata sotto il titolo */
.dominio-palette.centered {
    justify-content: center;
    margin: 1rem 0 0.5rem 0;
    gap: 0.6rem;
}

.palette-color {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.4);
    transition: all 0.2s ease;
    cursor: help;
    position: relative;
}

.palette-color:hover {
    transform: scale(1.6);
    border-color: rgba(255, 255, 255, 0.8);
    z-index: 10;
}

/* Tooltip per colori palette */
.palette-color::after {
    content: attr(title);
    position: absolute;
    bottom: -1.8rem;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.9);
    color: white;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.7rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    z-index: 20;
}

.palette-color:hover::after {
    opacity: 1;
}

/* === ZONE COUNT INDICATOR === */
.zone-count-indicator {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: linear-gradient(135deg,
            var(--primary-color, #667eea),
            var(--secondary-color, #764ba2));
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 16px;
    font-size: 0.8rem;
    font-weight: 600;
    z-index: 3;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* === META ITEMS PER DOMINI === */
.dominio-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    margin-top: 1.2rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
    background: rgba(255, 255, 255, 0.05);
    padding: 0.4rem 0.8rem;
    border-radius: 16px;
    transition: all 0.2s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.meta-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.9);
    transform: translateY(-1px);
    border-color: var(--primary-color, rgba(255, 255, 255, 0.2));
}

.meta-icon {
    opacity: 0.8;
    font-size: 0.9rem;
}

/* === ZONE PREVIEW PER DOMINI === */
.zone-preview {
    margin-top: 1.2rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.zone-preview h5 {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0.6rem;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    opacity: 0.7;
}

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

.zone-tag {
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.7);
    padding: 0.25rem 0.6rem;
    border-radius: 10px;
    font-size: 0.7rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.2s ease;
}

.zone-tag:hover {
    background: rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.9);
    border-color: var(--primary-color, rgba(255, 255, 255, 0.2));
}

.zone-tag.more {
    background: linear-gradient(135deg,
            var(--primary-color, #667eea),
            var(--secondary-color, #764ba2));
    color: white;
    font-weight: 600;
    border-color: transparent;
}

/* === STATISTICHE DOMINI === */
.domains-stats {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    margin: 1.2rem 0;
    padding: 1rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-item {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    text-align: center;
}

.stat-item strong {
    color: var(--primary-color, #667eea);
    font-weight: 700;
    font-size: 1.2em;
    display: block;
    margin-bottom: 0.2rem;
}

/* === VISTA DOMINIO: MIGLIORAMENTI SPECIFICI === */

/* Atmosfera header dominio con integration meteo */
.dominio-detail-header.with-weather {
    background: linear-gradient(135deg,
            rgba(var(--domain-primary-rgb, 102, 126, 234), 0.1) 0%,
            rgba(0, 0, 0, 0.6) 50%,
            rgba(var(--domain-secondary-rgb, 118, 75, 162), 0.1) 100%);
    position: relative;
    overflow: hidden;
}

/* Particle overlay per atmosfere meteo */
.dominio-detail-header.with-weather::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        radial-gradient(2px 2px at 20px 30px, rgba(var(--domain-primary-rgb, 102, 126, 234), 0.3), transparent),
        radial-gradient(2px 2px at 40px 70px, rgba(var(--domain-secondary-rgb, 118, 75, 162), 0.2), transparent);
    background-size: 100px 100px;
    animation: weatherDrift 15s infinite linear;
    pointer-events: none;
    opacity: 0.3;
}

@keyframes weatherDrift {
    0% {
        transform: translate(0, 0);
    }

    100% {
        transform: translate(-100px, -100px);
    }
}

/* Zone exploration con meteo awareness */
.zone-exploration.weather-affected {
    position: relative;
}

/* Zona card con atmosfera */
.zona-card.atmospheric {
    border-left: 3px solid var(--primary-color, #667eea);
    transition: all 0.3s ease, border-left-color 0.3s ease;
}

.zona-card.atmospheric:hover {
    border-left-color: var(--secondary-color, #764ba2);
    box-shadow:
        0 5px 20px rgba(var(--primary-color-rgb, 102, 126, 234), 0.2),
        -3px 0 15px var(--primary-color, transparent);
}

/* Risk indicators per zone */
.zona-risk {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    background: rgba(220, 53, 69, 0.15);
    color: #dc3545;
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
    font-size: 0.75rem;
    border: 1px solid rgba(220, 53, 69, 0.3);
    cursor: help;
}

/* === RESPONSIVE ADJUSTMENTS === */
@media (max-width: 768px) {
    .domains-stats {
        flex-direction: column;
        gap: 0.8rem;
        text-align: center;
    }

    .zone-count-indicator {
        top: 0.8rem;
        right: 0.8rem;
        padding: 0.2rem 0.6rem;
        font-size: 0.7rem;
    }

    .dominio-meta {
        gap: 0.5rem;
    }

    .meta-item {
        font-size: 0.8rem;
        padding: 0.3rem 0.6rem;
    }

    .zone-tags {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .dominio-palette {
        justify-content: center;
        margin: 1rem 0;
    }

    .palette-color {
        width: 14px;
        height: 14px;
    }

    .palette-color:hover {
        transform: scale(1.4);
    }

    .zone-preview {
        text-align: center;
    }

    .dominio-meta {
        justify-content: center;
        flex-direction: column;
        align-items: center;
    }

    .meta-item {
        justify-content: center;
        min-width: 120px;
    }
}

/* === INTEGRATION CON SISTEMA METEO === */

/* Classe per domini che ricevono dati meteo */
.dominio-card[data-weather-active="true"] {
    position: relative;
}

.dominio-card[data-weather-active="true"]::after {
    content: '🌡️';
    position: absolute;
    top: 0.8rem;
    left: 1rem;
    font-size: 0.8rem;
    opacity: 0.6;
    z-index: 2;
}

/* Indicatori atmosfera dinamica */
.atmospheric-indicator {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.8rem;
    opacity: 0.7;
    margin-left: 0.5rem;
}

.atmospheric-indicator.active {
    opacity: 1;
    color: var(--primary-color, #667eea);
}

/* Pulses per elementi dinamici */
@keyframes atmosphericPulse {

    0%,
    100% {
        opacity: 0.6;
    }

    50% {
        opacity: 1;
    }
}

.weather-dynamic {
    animation: atmosphericPulse 3s infinite;
}

/* === LAYOUT VISTA DOMINIO COMPLETO === */
.dominio-content-grid {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 2.5rem;
    align-items: start;
}

.dominio-main-content {
    min-width: 0;
    /* Previene overflow */
}

.dominio-sidebar {
    position: sticky;
    top: 0;
}

/* Sezione narrativa migliorata */
.dominio-narrative.atmospheric {
    background: linear-gradient(135deg,
            rgba(var(--domain-primary-rgb, 102, 126, 234), 0.08) 0%,
            rgba(0, 0, 0, 0.6) 50%,
            rgba(var(--domain-secondary-rgb, 118, 75, 162), 0.05) 100%);
    position: relative;
}

/* Zone exploration intro */
.zone-exploration-intro {
    margin-bottom: 1.5rem;
    color: rgba(255, 255, 255, 0.8);
    font-style: italic;
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Header zona card migliorato */
.zona-card-header {
    margin-bottom: 1rem;
    padding-bottom: 0.8rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.zona-card-header h4 {
    margin: 0;
    font-size: 1.1rem;
}

.zona-card-header h4 a {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    transition: color 0.3s ease;
}

.zona-card-header h4 a:hover {
    color: var(--primary-color, #667eea);
}

/* Footer zona card */
.zona-card .zona-meta {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.zona-type-section {
    flex-shrink: 0;
}

.zona-indicators {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    align-items: center;
}

/* Indicatori zona specifici */
.zona-temporal {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    background: rgba(255, 193, 7, 0.15);
    color: #ffc107;
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
    font-size: 0.75rem;
    border: 1px solid rgba(255, 193, 7, 0.3);
    cursor: help;
}

/* Palette atmosferica sidebar */
.palette-atmospheric {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.color-atmosphere-item {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
}

.color-atmosphere-item .palette-color {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

/* === RESPONSIVE LAYOUT === */
@media (max-width: 1024px) {
    .dominio-content-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .dominio-sidebar {
        position: static;
        order: -1;
    }
}

@media (max-width: 768px) {
    .dominio-content-grid {
        gap: 1.5rem;
    }

    .zona-card .zona-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.8rem;
    }

    .zona-indicators {
        width: 100%;
        justify-content: flex-start;
    }

    .domains-stats {
        flex-direction: column;
        gap: 0.8rem;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .zone-exploration-intro {
        text-align: center;
        font-size: 0.9rem;
    }

    .zona-card-header h4 a {
        font-size: 1rem;
        justify-content: center;
    }

    .zona-indicators {
        justify-content: center;
    }

    .atmospheric-indicator {
        font-size: 0.75rem;
    }
}

/* ============================================================================
   CSS AGGIUNTIVO - SIDEBAR CENTRALIZZATA (Step 1)
   DA AGGIUNGERE A esplora.css
   ============================================================================ */

/* === STATISTICHE VERTICALI SIDEBAR === */
.domains-stats.vertical {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    padding: 0;
    border: none;
    margin: 0;
}

.domains-stats.vertical .stat-item {
    text-align: left;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.domains-stats.vertical .stat-item:last-child {
    border-bottom: none;
}

.domains-stats.vertical .stat-item strong {
    display: inline;
    margin-right: 0.5rem;
    font-size: 1em;
    color: var(--primary-color, #667eea);
}

/* === MAPPA RAPIDA ZONE === */
.zone-quick-nav {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.zone-quick-link {
    display: block;
    padding: 0.4rem 0.8rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 0.85rem;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

.zone-quick-link:hover {
    background: rgba(var(--primary-color-rgb, 102, 126, 234), 0.1);
    border-color: var(--primary-color, #667eea);
    border-left-color: var(--primary-color, #667eea);
    color: white;
    transform: translateX(4px);
}

/* === TIPI DI TERRITORIO TAGS === */
.zone-types-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.zone-type-tag {
    display: inline-block;
    padding: 0.3rem 0.7rem;
    background: linear-gradient(135deg,
            rgba(var(--primary-color-rgb, 102, 126, 234), 0.2),
            rgba(var(--secondary-color-rgb, 118, 75, 162), 0.1));
    border: 1px solid rgba(var(--primary-color-rgb, 102, 126, 234), 0.3);
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* === PALETTE INFO SECTION === */
.palette-info {
    margin-top: 1rem;
    padding: 0.8rem;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 6px;
    border-left: 3px solid var(--primary-color, #667eea);
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
}

.palette-info strong {
    color: var(--primary-color, #667eea);
}

/* === MIGLIORAMENTI INFO-BLOCK === */
.info-block h5 {
    color: var(--primary-color, #667eea);
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.8rem;
    padding-bottom: 0.3rem;
    border-bottom: 1px solid rgba(var(--primary-color-rgb, 102, 126, 234), 0.3);
}

/* === RESPONSIVE ADJUSTMENTS === */
@media (max-width: 1024px) {
    .dominio-sidebar {
        order: -1;
        margin-bottom: 2rem;
    }

    .zone-quick-nav {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .zone-quick-link {
        flex: 1 1 auto;
        min-width: 120px;
        text-align: center;
    }

    .domains-stats.vertical {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }

    .domains-stats.vertical .stat-item {
        flex: 1 1 auto;
        text-align: center;
        min-width: 120px;
        border-bottom: none;
        border-right: 1px solid rgba(255, 255, 255, 0.1);
    }

    .domains-stats.vertical .stat-item:last-child {
        border-right: none;
    }
}

@media (max-width: 768px) {
    .zone-types-list {
        justify-content: center;
    }

    .palette-atmospheric {
        align-items: center;
        text-align: center;
    }

    .color-atmosphere-item {
        justify-content: center;
        flex-direction: column;
        gap: 0.4rem;
        text-align: center;
    }

    .zone-quick-link {
        font-size: 0.8rem;
        padding: 0.3rem 0.6rem;
    }
}

/* === ANIMAZIONI PROGRESSIVE === */
.weather-dynamic {
    animation: atmosphericPulse 3s infinite;
}

@keyframes atmosphericPulse {

    0%,
    100% {
        opacity: 0.6;
    }

    50% {
        opacity: 1;
    }
}

.zone-quick-link,
.zone-type-tag,
.stat-item {
    animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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

/* === LAYOUT IMPROVEMENTS === */
.atmospheric-info {
    background: linear-gradient(135deg,
            rgba(0, 0, 0, 0.4) 0%,
            rgba(0, 0, 0, 0.6) 100%);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.atmospheric-info h4 {
    background: linear-gradient(135deg,
            var(--primary-color, #667eea) 0%,
            var(--secondary-color, #764ba2) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    font-weight: 600;
}

/* ============================================================================
   CSS SIDEBAR METEO AJAX - DA AGGIUNGERE A esplora.css
   ============================================================================ */

/* === STATI LOADING METEO === */
.meteo-loading-state {
    text-align: center;
    padding: 2rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    margin-bottom: 1rem;
}

.loading-spinner {
    font-size: 2rem;
    animation: spin-meteo 2s linear infinite;
    display: block;
    margin-bottom: 1rem;
}

@keyframes spin-meteo {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.meteo-loading-state p {
    color: rgba(255, 255, 255, 0.7);
    font-style: italic;
    margin: 0;
}

/* === CONTAINER DATI METEO === */
.meteo-data-container {
    animation: fadeInMeteo 0.6s ease-out;
}

@keyframes fadeInMeteo {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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

/* === ATMOSFERA CORRENTE === */
.atmosfera-attuale {
    background: linear-gradient(135deg,
            rgba(var(--primary-color-rgb, 102, 126, 234), 0.1) 0%,
            rgba(0, 0, 0, 0.3) 100%);
    padding: 1rem;
    border-radius: 8px;
    border-left: 4px solid var(--primary-color, #667eea);
    transition: all 0.3s ease;
}

.atmosfera-nome {
    font-size: 1.1rem;
    margin-bottom: 0.6rem;
    color: var(--primary-color, #667eea);
    min-height: 1.3rem;
}

.atmosfera-descrizione {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 0.5rem;
    font-style: italic;
    min-height: 2rem;
}

.atmosfera-categoria {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.atmosfera-categoria span {
    color: var(--secondary-color, #764ba2);
    font-weight: 600;
}

/* === DISTORSIONE SPAZIO-TEMPORALE === */
.distorsione-attuale {
    background: rgba(255, 107, 107, 0.1);
    padding: 1rem;
    border-radius: 8px;
    border-left: 4px solid #ff6b6b;
    transition: all 0.3s ease;
}

.distorsione-nome {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    color: #ff6b6b;
    min-height: 1.2rem;
}

.distorsione-descrizione {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.85rem;
    line-height: 1.4;
    min-height: 1.7rem;
}

/* === COLORI ATMOSFERICI DINAMICI === */
.colori-atmosferici {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    min-height: 120px;
}

.colore-atmosferico-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.6rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 6px;
    transition: all 0.3s ease;
    animation: fadeInUp 0.5s ease-out;
}

.colore-atmosferico-item:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(4px);
}

.palette-color-dynamic {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 3px solid rgba(255, 255, 255, 0.3);
    flex-shrink: 0;
    transition: all 0.3s ease;
    cursor: help;
}

.palette-color-dynamic:hover {
    transform: scale(1.2);
    border-color: rgba(255, 255, 255, 0.6);
}

.colore-info {
    flex: 1;
    font-size: 0.9rem;
}

.colore-info strong {
    color: rgba(255, 255, 255, 0.9);
}

.colore-info small {
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* === INTENSITÀ ATMOSFERICA === */
.intensita-container {
    background: rgba(0, 0, 0, 0.3);
    padding: 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.intensita-value {
    text-align: center;
    margin-bottom: 0.8rem;
}

.intensita-value strong {
    font-size: 1.5rem;
    color: var(--primary-color, #667eea);
    transition: all 0.3s ease;
}

.intensita-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.6rem;
}

.intensita-fill {
    height: 100%;
    background: linear-gradient(90deg,
            var(--primary-color, #667eea) 0%,
            var(--secondary-color, #764ba2) 100%);
    border-radius: 4px;
    transition: width 0.8s ease;
    animation: intensityPulse 3s infinite ease-in-out;
}

@keyframes intensityPulse {

    0%,
    100% {
        opacity: 0.8;
    }

    50% {
        opacity: 1;
    }
}

.modificatori-info {
    text-align: center;
    color: #ffc107;
    font-size: 0.8rem;
    margin-top: 0.5rem;
    animation: fadeInUp 0.5s ease-out;
}

/* === SINCRONIZZAZIONE TEMPORALE === */
.sincronizzazione-temporale {
    background: rgba(255, 152, 0, 0.1);
    padding: 1rem;
    border-radius: 8px;
    border-left: 4px solid #ff9800;
    text-align: center;
    transition: all 0.3s ease;
}

.prossimo-cambio {
    margin-bottom: 0.5rem;
    color: rgba(255, 255, 255, 0.9);
}

.prossimo-cambio strong {
    color: #ff9800;
}

.cambio-automatico small {
    color: rgba(255, 255, 255, 0.6);
    font-style: italic;
}

/* === STATO ERRORE === */
.meteo-offline {
    background: rgba(255, 193, 7, 0.1);
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid rgba(255, 193, 7, 0.3);
    text-align: center;
}

.meteo-offline p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0.8rem;
    font-size: 0.9rem;
}

.meteo-offline p:first-child {
    color: #ffc107;
    font-weight: 600;
}

.retry-btn {
    background: linear-gradient(135deg, #ff9800, #f57c00);
    color: white;
    border: none;
    padding: 0.6rem 1.2rem;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    margin-top: 0.5rem;
}

.retry-btn:hover {
    background: linear-gradient(135deg, #f57c00, #e65100);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 152, 0, 0.3);
}

/* === NAVIGAZIONE VELOCE === */
.quick-nav-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.quick-nav-link {
    display: block;
    padding: 0.6rem 1rem;
    background: linear-gradient(135deg,
            rgba(var(--primary-color-rgb, 102, 126, 234), 0.2),
            rgba(var(--secondary-color-rgb, 118, 75, 162), 0.1));
    border: 1px solid rgba(var(--primary-color-rgb, 102, 126, 234), 0.3);
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    text-align: center;
}

.quick-nav-link:hover {
    background: linear-gradient(135deg,
            rgba(var(--primary-color-rgb, 102, 126, 234), 0.3),
            rgba(var(--secondary-color-rgb, 118, 75, 162), 0.2));
    border-color: var(--primary-color, #667eea);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(var(--primary-color-rgb, 102, 126, 234), 0.3);
}

/* === LAYOUT GENERALE === */
.atmospheric-info {
    background: linear-gradient(135deg,
            rgba(0, 0, 0, 0.4) 0%,
            rgba(0, 0, 0, 0.6) 100%);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    padding: 1.5rem;
}

.atmospheric-info h4 {
    background: linear-gradient(135deg,
            var(--primary-color, #667eea) 0%,
            var(--secondary-color, #764ba2) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 2rem;
    font-size: 1.2rem;
    font-weight: 700;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.info-block h5 {
    color: var(--primary-color, #667eea);
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 1rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid rgba(var(--primary-color-rgb, 102, 126, 234), 0.3);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.info-block {
    margin-bottom: 2rem;
}

.info-block:last-child {
    margin-bottom: 0;
}

/* === ANIMAZIONI GENERICHE === */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(15px);
    }

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

/* === RESPONSIVE === */
@media (max-width: 1024px) {
    .dominio-sidebar {
        order: -1;
        margin-bottom: 2rem;
    }

    .colori-atmosferici {
        min-height: auto;
    }

    .colore-atmosferico-item {
        justify-content: center;
        text-align: center;
    }

    .quick-nav-links {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .quick-nav-link {
        flex: 1 1 auto;
        min-width: 120px;
    }
}

@media (max-width: 768px) {
    .atmospheric-info {
        padding: 1rem;
    }

    .atmospheric-info h4 {
        font-size: 1rem;
    }

    .colore-atmosferico-item {
        flex-direction: column;
        gap: 0.5rem;
    }

    .palette-color-dynamic {
        width: 20px;
        height: 20px;
    }

    .intensita-value strong {
        font-size: 1.2rem;
    }

    .meteo-loading-state {
        padding: 1rem;
    }

    .loading-spinner {
        font-size: 1.5rem;
    }
}

/* ============================================================================
   ESPLORA ONIRIKA - FIX ALLINEAMENTO VERTICALE SIDEBAR
   CSS addizionale per correggere l'allineamento senza centratura verticale
   ============================================================================ */

/* PROBLEMA PRINCIPALE: Eliminare centratura verticale e forzare allineamento top */

/* 1. CORRETTI GRID CONTAINERS - Forza allineamento top esplicito */
.domini-overview,
.dominio-content-grid {
    align-items: start !important;
    /* Forza allineamento in alto */
    align-content: start !important;
    /* Anche per il contenuto */
}

/* 2. CORRETTO SIDEBAR POSITIONING */
.dominio-sidebar {
    position: sticky;
    top: 0 !important;
    /* Rimuove offset */
    align-self: start !important;
    /* Forza allineamento in alto */
    justify-self: start !important;
    /* Forza allineamento orizzontale */
}

/* 3. CORRETTO ATMOSPHERIC-INFO - Rimuove centratura */
.atmospheric-info {
    align-items: flex-start !important;
    /* Se è flexbox, allinea in alto */
    justify-content: flex-start !important;
    /* Rimuove centratura orizzontale */
    text-align: left !important;
    /* Forza allineamento testo a sinistra */
    margin-top: 0 !important;
    /* Reset margin top */
    padding-top: 1.5rem;
    /* Mantiene padding interno */
}

/* 4. CORRETTO TITOLO SIDEBAR - Non più centrato */
.atmospheric-info h4 {
    text-align: left !important;
    /* Allineamento sinistra invece di center */
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* 5. CORREZIONE CONTENUTO PRINCIPALE - Allineamento esplicito */
.dominio-main-content {
    align-self: start !important;
    justify-self: start !important;
    margin-top: 0 !important;
}

/* 6. CORREZIONE SEZIONI SPECIFICHE che potrebbero avere centratura */
.dominio-narrative.atmospheric,
.zone-exploration,
.info-block {
    align-self: start !important;
    text-align: left !important;
    /* Override eventuali text-align: center */
}

/* 7. CORREZIONE FLEXBOX INTERNI - Rimuove align-items: center */
.info-block,
.meteo-data-container,
.color-atmosphere-item {
    align-items: flex-start !important;
}

/* 8. CORREZIONE DOMINI OVERVIEW INDEX - Stesso problema */
.domini-content {
    align-self: start !important;
    justify-self: start !important;
}

.atmospheric-info h4,
.info-block h5 {
    text-align: left !important;
    /* Titoli sidebar allineati a sinistra */
}

/* 9. CORREZIONE SPECIFICA PER ELEMENTI CHE POTREBBERO ESSERE CENTRATI */
.domains-stats {
    justify-content: flex-start !important;
    /* Rimuove centratura statistiche */
    text-align: left !important;
}

.intro-text {
    text-align: center;
    /* Questa può rimanere centrata perché è introduzione */
}

/* 10. ASSICURA CHE I FLEX CONTAINER NON CENTRINO */
.dominio-meta,
.zona-meta,
.quick-nav-links {
    align-items: flex-start !important;
    justify-content: flex-start !important;
}

/* 11. RESPONSIVE - Mantiene correzioni anche su mobile */
@media (max-width: 1024px) {
    .dominio-content-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
        align-items: start !important;
    }

    .dominio-sidebar {
        position: static !important;
        order: -1;
        margin-bottom: 2rem;
        top: auto !important;
        align-self: start !important;
    }

    .atmospheric-info {
        text-align: left !important;
    }

    .atmospheric-info h4 {
        text-align: left !important;
    }
}

/* 12. DEBUG VISIVO - Decommentare per vedere il problema (OPZIONALE) */
/*
.dominio-main-content {
    border: 2px solid red;
    background: rgba(255, 0, 0, 0.1);
}

.dominio-sidebar {
    border: 2px solid blue;
    background: rgba(0, 0, 255, 0.1);
}

.atmospheric-info {
    border: 2px solid green;
    background: rgba(0, 255, 0, 0.1);
}
*/

/* NOTA: Questo CSS usa !important per override forzato delle centrature esistenti */

/**
 * ============================================================================
 * ONIRIKA - FASE 2: CSS SISTEMA IMMAGINI
 * ============================================================================
 * Integrazione responsiva per domini e zone con immagini
 * Compatible con esplora.css esistente + tema dark + sistema palette
 */

/* =============================================================================
   DOMINI HEADER CON IMMAGINI DI SFONDO
   ============================================================================= */

.dominio-header {
    /* Migliora transizioni e blend per immagini background */
    position: relative;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: var(--radius-large, 12px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Header con immagine di sfondo */
.dominio-header.has-background-image {
    background-attachment: local;
    /* Migliore performance su mobile */
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    min-height: 250px;
}

/* Overlay per leggibilità testo su immagini */
.dominio-header.has-background-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg,
            rgba(0, 0, 0, 0.3) 0%,
            rgba(0, 0, 0, 0.1) 50%,
            rgba(0, 0, 0, 0.4) 100%);
    z-index: 1;
}

/* Contenuto header sopra overlay */
.dominio-header-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 2rem;
    width: 100%;
}

/* Titoli potenziati per backgrounds */
.dominio-header.has-background-image .dominio-title {
    text-shadow:
        2px 2px 4px rgba(0, 0, 0, 0.8),
        0 0 8px rgba(0, 0, 0, 0.6);
    color: #ffffff;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.dominio-header.has-background-image .dominio-description {
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    border-radius: var(--radius-medium, 8px);
    padding: 1rem;
    margin-top: 1rem;
    color: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* =============================================================================
   ZONE GRID CON THUMBNAILS
   ============================================================================= */

.zone-grid-item {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

/* Thumbnail zone */
.zone-thumbnail-container {
    position: relative;
    width: 100%;
    height: 160px;
    border-radius: var(--radius-medium, 8px);
    overflow: hidden;
    margin-bottom: 0.75rem;
    background: var(--surface-color, #1a1a1a);
    border: 1px solid var(--border-color, #333);
}

.zone-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    filter: brightness(0.8) saturate(1.1);
}

.zone-thumbnail-container:hover .zone-thumbnail {
    transform: scale(1.05);
    filter: brightness(0.9) saturate(1.2);
}

/* Overlay info su thumbnail */
.zone-thumbnail-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    color: white;
    padding: 0.75rem;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.zone-thumbnail-container:hover .zone-thumbnail-overlay {
    transform: translateY(0);
}

/* Fallback per zone senza immagine */
.zone-no-image {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg,
            var(--accent-color, #444) 0%,
            var(--secondary-color, #333) 100%);
    color: var(--text-muted, #999);
    font-size: 0.9rem;
    text-align: center;
}

.zone-no-image::before {
    content: '🌫️';
    display: block;
    font-size: 2rem;
    margin-bottom: 0.5rem;
    opacity: 0.7;
}

/* =============================================================================
   GALLERY IMMAGINI PER ZONE DETTAGLIO
   ============================================================================= */

.zone-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 0.75rem;
    margin: 1rem 0;
}

.gallery-item {
    position: relative;
    aspect-ratio: 4/3;
    border-radius: var(--radius-small, 6px);
    overflow: hidden;
    background: var(--surface-dark, #0f0f0f);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease, filter 0.3s ease;
    cursor: pointer;
}

.gallery-item:hover img {
    transform: scale(1.03);
    filter: brightness(1.1);
}

/* Caption su immagini gallery */
.image-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.9));
    color: white;
    font-size: 0.8rem;
    padding: 0.5rem;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    line-height: 1.3;
}

.gallery-item:hover .image-caption {
    transform: translateY(0);
}

/* Indicatore immagini aggiuntive */
.gallery-more {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border: 2px dashed rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-small, 6px);
    color: var(--text-muted, #999);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.gallery-more:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.4);
    color: var(--text-primary, #fff);
}

/* =============================================================================
   RESPONSIVE DESIGN
   ============================================================================= */

/* Tablet */
@media (max-width: 768px) {
    .dominio-header {
        min-height: 180px;
    }

    .dominio-header.has-background-image {
        min-height: 220px;
        background-attachment: scroll;
        /* Performance mobile */
    }

    .dominio-header-content {
        padding: 1.5rem;
    }

    .zone-thumbnail-container {
        height: 140px;
    }

    .zone-gallery {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 0.5rem;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .dominio-header {
        min-height: 160px;
    }

    .dominio-header.has-background-image {
        min-height: 200px;
    }

    .dominio-header-content {
        padding: 1rem;
    }

    .dominio-header.has-background-image .dominio-title {
        font-size: 1.8rem;
    }

    .zone-thumbnail-container {
        height: 120px;
    }

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

    /* Semplifica overlays su mobile per performance */
    .zone-thumbnail-overlay,
    .image-caption {
        position: static;
        transform: none;
        background: rgba(0, 0, 0, 0.8);
        margin-top: 0.25rem;
        padding: 0.5rem;
        font-size: 0.75rem;
    }
}

/* =============================================================================
   PERFORMANCE E ACCESSIBILITY
   ============================================================================= */

/* Lazy loading placeholder */
.image-loading {
    background: linear-gradient(90deg,
            transparent 0%,
            rgba(255, 255, 255, 0.1) 50%,
            transparent 100%);
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }

    100% {
        background-position: 200% 0;
    }
}

/* Focus states per accessibility */
.gallery-item:focus,
.zone-thumbnail-container:focus {
    outline: 2px solid var(--accent-color, #007acc);
    outline-offset: 2px;
}

/* Riduzione motion per utenti sensibili */
@media (prefers-reduced-motion: reduce) {

    .zone-thumbnail,
    .gallery-item img,
    .zone-thumbnail-overlay,
    .image-caption {
        transition: none;
    }

    .image-loading {
        animation: none;
    }
}

/* =============================================================================
   INTEGRAZIONE CON SISTEMA PALETTE
   ============================================================================= */

/* Le classi .dominio-{palette} vengono generate dinamicamente */
/* Esempio per palette specifica */
.dominio-paura .zone-thumbnail-container {
    box-shadow: 0 4px 8px rgba(139, 0, 0, 0.3);
}

.dominio-paura .gallery-item:hover {
    box-shadow: 0 8px 16px rgba(139, 0, 0, 0.4);
}

.dominio-memoria .zone-thumbnail-container {
    box-shadow: 0 4px 8px rgba(75, 0, 130, 0.3);
}

.dominio-memoria .gallery-item:hover {
    box-shadow: 0 8px 16px rgba(75, 0, 130, 0.4);
}

/* Pattern fallback per domini senza immagine */
.dominio-pattern-fallback {
    background-size: 120px 120px;
    background-repeat: repeat;
    position: relative;
}

.dominio-pattern-fallback::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.2);
    mix-blend-mode: multiply;
}



/* ============================================================================
   ONIRIKA - FASE 3: VISUALIZZAZIONE IMMAGINI DOMINI
   ============================================================================
   Integrazione responsive per domini e zone con immagini header
   Compatible con esplora.css esistente + tema dark + sistema palette
   ============================================================================ */

/* === DOMINI CARDS CON IMMAGINI HEADER (Vista griglia) === */

.dominio-card.has-header-image {
    min-height: 280px;
    position: relative;
    overflow: hidden;
    background-image: var(--domain-bg-image);
    opacity: 0.9;
    background-size: cover;
    background-position: center;
    background-attachment: local;
}

/* Header immagine per card griglia */
.dominio-image-header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 140px;
    background-size: cover;
    background-position: center;
    z-index: 1;
}

/* Overlay per leggibilità testo su immagini */
.dominio-card.has-header-image .image-overlay,
.dominio-image-header .image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;
}

/* Contenuto card sopra l'immagine */
.dominio-card.has-header-image .dominio-card-header {
    position: relative;
    z-index: 3;
    padding-top: 160px;
}

/* Titolo con shadow per leggibilità */
.dominio-card.has-header-image .dominio-title-section h3 a {
    color: white;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
    font-weight: 600;
}

/* Badge visivo per domini con immagini */
.dominio-card.has-header-image::after {
    display: none;
}

/* === DOMINI HEADER COMPLETO (Vista singola) === */

.dominio-detail-header.has-background-image {
    /* Altezza dinamica basata su presenza immagine */
    min-height: var(--header-min-height, 250px);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: var(--radius-large, 12px);
    margin-bottom: 2rem;

    /* Background con immagine o pattern fallback */
    background: var(--header-fallback-bg, #1a1a1a);
    background-image: var(--header-bg-image, none);
    background-size: cover;
    background-position: center;
    background-attachment: local;
}

/* Overlay per header vista singola */
.dominio-detail-header.has-background-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--domain-overlay, linear-gradient(135deg, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0.2) 50%, rgba(0, 0, 0, 0.6) 100%));
    z-index: 1;
}

/* Contenuto header sopra overlay */
.dominio-detail-header.has-background-image .dominio-title-section {
    position: relative;
    z-index: 2;
    text-align: center;
}

/* Titolo header con text shadow */
.dominio-detail-header.has-background-image .dominio-title-section h2 {
    color: white;
    text-shadow: var(--header-text-shadow, 2px 2px 4px rgba(0, 0, 0, 0.8));
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

/* Palette colori con maggior contrasto su immagini */
.dominio-detail-header.has-background-image .dominio-palette.centered .palette-color {
    border: 3px solid rgba(255, 255, 255, 0.8);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

/* === FALLBACK PER DOMINI SENZA IMMAGINI === */

.dominio-card:not(.has-header-image) {
    /* Mantiene lo stile esistente per domini senza immagini */
    background: var(--domain-fallback-bg, linear-gradient(135deg, rgba(0, 0, 0, 0.6) 0%, rgba(0, 0, 0, 0.8) 100%));
    position: relative;
}

/* Pattern geometrico per domini senza header image */
.dominio-card:not(.has-header-image)::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--domain-fallback-bg);
    opacity: 0.1;
    z-index: 0;
}

/* Header vista singola senza immagine */
.dominio-detail-header:not(.has-background-image) {
    background: var(--header-fallback-bg, linear-gradient(135deg, var(--domain-primary, #333) 0%, var(--domain-secondary, #666) 50%, var(--domain-accent, #999) 100%));
    min-height: var(--header-min-height, 200px);
    position: relative;
}

/* Pattern geometrico per header senza immagine */
.dominio-detail-header:not(.has-background-image)::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        radial-gradient(circle at 25% 25%, var(--domain-accent, #999)33 0%, transparent 50%),
        radial-gradient(circle at 75% 75%, var(--domain-primary, #333)33 0%, transparent 50%);
    background-size: 100px 100px;
    opacity: 0.3;
}

/* === ZONE CON THUMBNAILS (Bonus: per vista domini) === */

.zona-card.has-zone-image {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 1rem;
}

.zona-image-thumbnail {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    border-radius: 8px;
    overflow: hidden;
    background: var(--surface-color, #1a1a1a);
    border: 2px solid var(--domain-primary, rgba(255, 255, 255, 0.1));
}

.zona-image-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.zona-card.has-zone-image:hover .zona-image-thumbnail img {
    transform: scale(1.05);
}

/* === RESPONSIVE DESIGN === */

@media (max-width: 768px) {

    /* Domini cards responsive */
    .dominio-card.has-header-image {
        min-height: 240px;
    }

    .dominio-image-header {
        height: 120px;
    }

    .dominio-card.has-header-image .dominio-card-header {
        padding-top: 140px;
    }

    /* Header vista singola responsive */
    .dominio-detail-header.has-background-image {
        min-height: 200px;
    }

    .dominio-detail-header.has-background-image .dominio-title-section h2 {
        font-size: 2rem;
    }

    /* Zone thumbnails responsive */
    .zona-card.has-zone-image {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .zona-image-thumbnail {
        width: 60px;
        height: 60px;
    }
}

@media (max-width: 480px) {
    .dominio-card.has-header-image {
        min-height: 200px;
    }

    .dominio-image-header {
        height: 100px;
    }

    .dominio-card.has-header-image .dominio-card-header {
        padding-top: 120px;
    }

    .dominio-detail-header.has-background-image .dominio-title-section h2 {
        font-size: 1.8rem;
    }
}

/* === PERFORMANCE OPTIMIZATION === */

/* Lazy loading hint per immagini header */
.dominio-card.has-header-image .dominio-image-header,
.dominio-detail-header.has-background-image {
    will-change: transform;
}

/* Smooth scroll per domini con molte immagini */
.domini-grid {
    scroll-behavior: smooth;
}

/* === ACCESSIBILITÀ === */

/* Focus states per elementi clickabili */
.dominio-card.has-header-image:focus-within {
    outline: 2px solid var(--domain-accent, #667eea);
    outline-offset: 4px;
}

/* Reduced motion per utenti che preferiscono animazioni ridotte */
@media (prefers-reduced-motion: reduce) {

    .dominio-card.has-header-image,
    .zona-image-thumbnail img {
        transition: none;
    }
}

/* === INTEGRAZIONE CON SISTEMA METEO === */

/* Domini con meteo attivo + immagini */
.dominio-card.has-header-image[data-weather-active="true"]::after {
    content: '🌡️📸';
    font-size: 1rem;
}

/* Indicatori atmosferici su immagini */
.dominio-card.has-header-image .atmospheric-indicator {
    background: rgba(0, 0, 0, 0.7);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    backdrop-filter: blur(2px);
}