/* Layout Generale e Filtri */
.controls-area { background: var(--card); border: 1px solid var(--border); padding: 20px; border-radius: 15px; margin-bottom: 20px; }

.filter-row { 
    display: flex; 
    flex-wrap: wrap; 
    gap: 30px; 
    align-items: center; 
    justify-content: center; 
    width: 100%; 
}

.filter-group { 
    display: flex; 
    flex-direction: row; 
    align-items: center; 
    gap: 10px; 
}

.filter-group label { 
    font-size: 0.75rem; 
    text-transform: uppercase; 
    color: var(--text-dim); 
    font-weight: 800;
    white-space: nowrap; 
}

select, input { 
    background: var(--bg); border: 1px solid var(--border); color: var(--text-main); 
    padding: 8px 12px; border-radius: 8px; font-family: inherit; font-size: 0.9rem;
}

.btn-ai { 
    background: var(--accent); color: white; border: none; padding: 10px 18px; 
    border-radius: 8px; cursor: pointer; font-weight: 700; transition: 0.2s;
}
.btn-ai:hover { opacity: 0.8; }

/* NUOVO: Badge Periodo IW0RQH (Integrato nello stile) */
.period-wrapper { width: 100%; text-align: center; margin: 0px 0; display: block; }
.weather-badge {
    display: inline-flex; align-items: center; background: #1e293b; 
    padding: 8px 20px; border-radius: 50px; border: 1px solid #334155; gap: 10px;
}
.weather-badge i { color: #10b981; }
.weather-badge span { color: #94a3b8; font-size: 0.85rem; font-weight: 600; }
.weather-badge strong { color: #fff; margin-left: 5px; }

/* Grafico */
#chart-container, 
#secondary-chart-container { 
    background: var(--card); 
    border: 1px solid var(--border); 
    border-radius: 20px; 
    padding: 20px; 
    height: 500px; /* Altezza professionale fissa */
    margin-bottom: 25px; 
    position: relative;
    transition: background 0.3s ease, border-color 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05); /* Ombra leggera per profondità */
}

#chart-container canvas, 
#secondary-chart-container canvas {
    width: 100% !important;
    height: 100% !important;
}

/* Box Record e Titoli */
.summary-title { 
    text-align: center; font-size: 0.9rem; font-weight: bold; color: var(--text-dim); 
    text-transform: uppercase; margin: 30px 0 15px; border-bottom: 2px solid var(--border); 
    padding-bottom: 10px; width: 100%; 
}

.summary-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); 
    gap: 15px; margin-bottom: 30px; 
}

.box-info { 
    text-align: center; border-top: 4px solid var(--border); padding: 18px; 
    background: var(--card); border-radius: 12px; box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1); 
}

.box-info span { display: block; font-size: 0.75rem; color: var(--text-dim); font-weight: 700; text-transform: uppercase; }
.box-info strong { display: block; font-size: 1.8rem; margin: 8px 0; color: var(--text-main); font-weight: 800; }
.date-sub { font-size: 0.85rem; color: var(--text-dim); }
