:root {
    --widthLsidebar: 280px;
    --widthSelector: 180px;
    /* --widthProblem: 160px; */
    --heightsidebar: 100vh;
}
body {
    margin: 0;
    padding: 0;
    height: 100%;
}
a {
    text-decoration: none;
}
/* ========SLIDER CHIUDI============= */
.switch {
    position: fixed; /* Posizionalo rispetto alla viewport */
    /* top: 20px; */
    left: 0;         /* Allinealo a sinistra (o dove preferisci) */
    width: var(--widthLsidebar); /* Larghezza iniziale quando la sidebar è aperta */
    height: 34px;
    background-color: rgb(92, 94, 236);
    cursor: pointer;
    z-index: 101; /* Deve stare sopra la sidebar se la sidebar ha uno z-index */
    /* display: flex; align-items: center; ecc. come prima per gli elementi interni */
    display: flex;
    align-items: center;
}
/* Stili per .closeTextMenu e .slider rimangono per lo più invariati,
   ma assicurati che siano posizionati correttamente all'interno del .switch */
.closeTextMenu {
    overflow: hidden;
    text-align: center;
    /* margin: 0 5px; */
    font-size: 20px;
    color: white;
    cursor: pointer;
    margin-left: auto; /* Spinge il .slider a destra */
    /* La larghezza è animata da JS */
}
.slider {
    cursor: pointer;
    text-align: center;
    height: 26px;
    width: 26px;
    background-color: white;
    margin-left: auto; 
    margin-right: 5px; 
    flex-shrink: 0; /* Non si restringe */
}
#IObar{
    display: none;
}
/* ========FINE SLIDER CHIUDI============= */
.sidebar {
    background: rgb(176, 222, 252);
    height: var(--heightsidebar); /* o 100vh */
    width: var(--widthLsidebar);
    /* float: left; <-- Rimuovi float, non necessario con flex o fixed */
    position: fixed; /* Mantiene la sidebar fissa durante lo scroll della pagina */
    top: 34px;
    left: 0;
    z-index: 100; /* Assicurati che sia sopra altro contenuto se necessario */
    display: flex;
    flex-direction: column; /* Impila i figli verticalmente */
    overflow: hidden; /* Previene che la sidebar stessa mostri scrollbars se un figlio è troppo grande e non gestito */
}
/* ======== SELETTORI ============= */
.sel-wrapper {
    /* Rimuovi position: fixed; top: 20px; */
    /* margin: 34px 0 0 0; <-- Rimuovi o adatta se la spaziatura è ancora necessaria */
    width: 100%; /* Precedentemente var(--widthLsidebar) */
    background-color: blueviolet;
    /* display: block; <-- Rimuovi se non necessario, div è block di default */
    flex-shrink: 0; /* Non si restringe */
    /* Gli stili per .sel-lab e .sel possono rimanere simili,
       ma position: fixed al loro interno andrà rimosso se erano relativi
       alla viewport. Dovranno essere posizionati rispetto a .sel-wrapper */
    padding: 13px 0; /* Esempio per ricreare il padding verticale */
    box-sizing: border-box;
}
.sel-lab {
    /* position: fixed; <-- Rimuovi */
    width: 80px;
    /* margin: 13px 5px 0 0px; <-- Rimuovi se padding è su .sel-wrapper */
    text-align: right;
    color: white;
    display: inline-block; /* Per allineamento con select */
    margin-right: 5px;
    vertical-align: middle;
}
.sel {
    /* size: 0; <-- Attributo HTML, non CSS. Se è per nascondere, usa display:none o visibility */
    width: var(--widthSelector);
    /* position: fixed; <-- Rimuovi */
    /* margin: 13px 0 0 85px; <-- Rimuovi se padding è su .sel-wrapper */
    vertical-align: middle;
    margin-bottom: 5px; /* Spazio tra i select se sono uno sotto l'altro */
}
/* Potresti aver bisogno di un wrapper per ogni coppia label+select per gestire meglio il layout */
.sel-wrapper > br { display: none; } /* Nascondi i <br> se riorganizzi il layout interno */
/* ========FINE SELETTORI============= */
/* ======== SCROLLBAR ============= */
.scrollbar {
    /* Rimuovi position: fixed; top: 175px; */
    /* width: var(--widthLsidebar); <-- width: 100% è meglio come flex item */
    width: 100%;
    flex-grow: 1; /* OCCUPA LO SPAZIO VERTICALE RIMANENTE */
    min-height: 0; /* Necessario per il corretto funzionamento di flex-grow con overflow */
    overflow-x: hidden;
    overflow-y: auto; /* Sempre scrollabile quando necessario */
    
    /* Nascondi la scrollbar ma mantieni la funzionalità di scroll */
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* Internet Explorer e Edge */
}

/* Nascondi la scrollbar in WebKit (Chrome, Safari, Edge Chromium) */
.scrollbar::-webkit-scrollbar {
    display: none;
}

.scrollbar:hover {
    /* width: var(--widthLsidebar); <-- Non necessario, è già 100% */
    overflow-y: auto;
    /* overflow-x: hidden; <-- Già impostato */
}

/* Mantieni gli stili originali per eventuali altri elementi che usano #style-1 */
#style-1::-webkit-scrollbar-track {
    border-radius: 2px;
}
#style-1::-webkit-scrollbar {
    width: 5px;
    background-color: #F7F7F7;
}
#style-1::-webkit-scrollbar-thumb {
    border-radius: 10px;
    background-color: #BFBFBF;
}
/* ======== FINE SCROLLBAR ============= */
/* ======== BOTTONI ============= */
.btn {
    position: sticky;
    width: var(--widthLsidebar);
    padding-right: 10px;
    border-style: outset;
    cursor: pointer;
    z-index: 17;
}

/* #btn0, #btn1, #btn2, #btn3, #btn4 {
position: sticky;
} */
#btn1, #btn2, #btn3, #btn4, #btn5 {
    margin: 10px 0 0 0;
}

#btn0 {
    top: 0;
    border-color: rgb(134, 239, 181);
    background: rgb(134, 239, 181);
}
#btn1 {
    top: 30;
    border-color: rgb(134, 190, 239);
    background-color: rgb(134, 190, 239);
}
#btn2 {
    top: 60;
    border-color: rgb(240, 221, 152);
    background-color: rgb(240, 221, 152);
}
#btn5 {
    top: 90;
    border-color: rgb(240, 221, 152);
    background-color: rgb(255, 176, 0);
}
#btn3 {
    top: 120;
    border-color: rgb(239, 134, 134);
    background-color: rgb(239, 134, 134);
}
#btn4 {
    top: 150;
    border-color: rgb(233, 87, 206);
    background-color: rgb(237, 105, 213);
    /* margin-bottom: 10px; */
}
.btn-es {
    border-style: outset;
    position: absolute;
    margin-left: auto;
    top: 12px;
    right: 0;
    height: 30px;
    background: #1919aa;
    border-color: #4343b4;
    color: white;
}
.btn-esAct {
    margin-left: auto;
    right: 0;
    width: 40 px;
}
.btn-esCopy {
    margin-left: auto;
    right: 70px;
}
/* .selwrapbtnAct{
} */
.btn-es:hover {
    background-color: #7b7bd8
}
.btn-esactive {
    border-style: inset;
}
#btn0:hover {
    background-color: rgb(162, 240, 197);
}
#btn1:hover {
    background-color: rgb(150, 195, 234);
}
#btn2:hover {
    background-color: rgb(240, 221, 152);
}
#btn3:hover {
    background-color: rgb(236, 161, 161);
}
#btn4:hover {
    background-color: rgb(243, 138, 224);
}
.btnactive {
    border-style: inset;
}
.tooltip {
    position: absolute;
    background-color: #333;
    color: #fff;
    /* padding: 3px; */
    text-align: center;
    margin: 0px;
    border-radius: 3px;
    display: none;
    z-index: 1000;
    width: 200px;
    /* Larghezza fissa */
    height: 45px;
    /* Altezza fissa */
    word-wrap: break-word;
}
#control-panel-tooltip {
    height: 58px;
    width: 222px;
    position: absolute;
    left: 33px;
    top: 224px;
    z-index: 1000;
    padding: 10px;
    display: none;
}
/* ========FINE BOTTONI============= */
/* ======== CONTENUTI BOTTONI ========== */
.sidepage{
    display: none;
}
#Mappe {
    padding: 9px 0;
    position: relative;
    top: 0;
    z-index: 16;
    background-color: rgb(185, 215, 185);
}
#DidLab {
    padding: 9px 0;
    position: relative;
    top: 0;
    z-index: 14;
    background-color: rgb(169, 169, 241);
}
#Eser {
    padding: 9px 0;
    position: relative;
    top: 0;
    z-index: 12;
    background-color: rgb(238, 233, 201);
}
#Verif {
    padding: 9px 0;
    position: relative;
    top: 0;
    z-index: 10;
    background-color: rgb(255, 203, 88);
}
#StrumBesAltro {
    padding: 9px 0;
    position: relative;
    top: 0;
    z-index: 8;
    background-color: rgb(237, 172, 168);
}
#RisDoc {
    padding: 9px 0;
    position: relative;
    top: 0;
    z-index: 6;
    background-color: rgb(243, 138, 224);
}
.hiding-panel {
    height: 32px;
    width: 280px;
    position: absolute;
    background-color: rgb(176, 222, 252);;
    z-index: 5;
}
#hiding-panel-0 {
    top: 159px;
    z-index: 15;
}
#hiding-panel-1 {
    top: 191px;
    z-index: 13;
}
#hiding-panel-2 {
    top: 222px;
    z-index: 11;
}
#hiding-panel-3 {
    top: 254px;
    z-index: 9;
}
#hiding-panel-4 {
    top: 286px;
    z-index: 7;
}
/* #hiding-panel-4 {
    top: 362px;
    z-index: 7;
} */
/* ======== FINE CONTENUTI BOTTONI ========== */
/* ======== IFRAME ============= */
.frame {
    /* overflow: hidden; */
    background-color: #000;
    height: 100%;
        align-content: center;
}
iframe {
    height: 100vh;
    background: #ccc;;
    min-width: 100%;
}
.frame div.warning-message#iframe-specific-warning {
    color: #FFFFFF; /* Testo bianco per contrasto con lo sfondo nero del .frame */
    font-weight: bold;
    text-align: center;
    font-size: 1.1em;
    padding: 15px;
    margin: 0; /* Rimuove margini del paragrafo per un miglior controllo del flex centering */
    background-color: brown;
}
.frame div.warning-message#iframe-specific-warning .icon {
    font-size: 10em; /* Dimensione dell'icona */
    margin-right: 10px;
    /* L'icona specifica (es. Unicode o FontAwesome) verrà aggiunta via JS */
}
.frame div.warning-message#iframe-specific-warning .icon.danger::before {
    content: "⚠️"; /* Icona di pericolo Unicode */
    color: #ffc107; /* Giallo ambra */
}
.frame div.warning-message#iframe-specific-warning .icon.info::before {
    content: "ℹ️"; /* Icona info Unicode */
    color: #17a2b8; /* Ciano */
}
/* ======== FINE IFRAME ============= */
#header {
    width: var(--widthLsidebar);
    height: 20px;
    padding: 0;
    position: absolute;
    overflow: hidden;
    top: 0;
    left: 0;
    border-bottom: 1px solid #000;
    background: #F1EFE2;
    justify-content: center;
    align-items: top;
    z-index: 10;
}
div.slide-right p {
    /* -moz-animation: 15s slide-right;
  -webkit-animation: 15s slide-right;
  -o-animation: 15s slide-right; */
    animation: 15s slide-right;
    animation-iteration-count: infinite;
    animation-timing-function: linear;
    /* margin:0; */
}
@keyframes slide-right {
    from {
        margin-left: 100%;
        width: 300%;
    }
    to {
        margin-left: -280%;
        width: 300%;
    }
}
/* Style the button that is used to open and close the collapsible content */
/* Barra esercizi */
.upbar {
    position: absolute;
    /* min-width: 100% - var(--widthLsidebar); */
    overflow: hidden;
    background: #5959a9;
    height: 54px;
    /* text-align: top; */
    float: top;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}
.selwrap {
    padding: 5px;
    margin: 0px 30px 0px 0px;
    /* flex: 1; */
    /* text-align: center; */
}
.self {
    width: 100%;
    /* text-align: center; */
}
.presenceMessage {
    display: inline-block;
    margin-left: 10px;
    color: red;
    font-weight: bold;
}
.selwrapbtn-es {
    /* position: relative; */
    z-index: 17;
    margin: 10px 0px 10px 0px;
    top: 140px;
    /* display: flex; */
    align-items: center;
    padding: 5px;
    border: 3px red dotted;
    width: -webkit-fill-available;
}
.wrapbtn-es_sidebar {
    display: flex;
     align-items: center;
    gap: 10px;
}
.btn-es_sidebar {
    border-style: outset;
    height: 20px;
}
.btn-esAct_sidebar {
    width: 90px;
    background: #f2ff00;
    border-color: #a4a632;
    color: rgb(0, 0, 0);
}
#btnAct_sidebar{
    cursor: pointer;
    transition: background-color 0.3s, border-style 0.1s;
}
#btnAct_sidebar:active {
    border-style: inset;
}
.materia, .documenti{
    position: relative;
    display: flex
}
.linkref {
    display: flex;
    position: relative;
}
.numArg{
    margin-right: 2px;;
}
.argomento {
    margin-left: 2px;
}
.input-wrapper-num_Arg{
    display: flex;
    margin-bottom: 2px;
    margin-left: -35px;
}
.display-toggle{
    cursor: pointer;
    font-size: 21px;
    padding-right: 6px;
    user-select: none;
    margin-top: -6px;
}

/* Stile per opacizzare il wrapper quando l'elemento è nascosto */
.input-wrapper-linkref[data-hidden="true"] {
    opacity: 0.4;
    background-color: rgba(200, 200, 200, 0.3);
    border-radius: 5px;
    transition: opacity 0.3s ease, background-color 0.3s ease;
}

/* Stile normale per il wrapper */
.input-wrapper-linkref {
    transition: opacity 0.3s ease, background-color 0.3s ease;
}
.input-wrapper-href {
    width: -webkit-fill-available;
    display: flex;
    align-items: flex-end;
    margin-bottom: 6px;
    margin-left: -33px;
}
.input-wrapper-href-hide {
    width: -webkit-fill-available;
    display: none; /* Nascosto di default */
    align-items: flex-end;
    margin-bottom: 6px;
    margin-left: -33px;
}
.input-wrapper-href-hide.show {
    display: flex; /* Mostra quando ha la classe 'show' */
}
.input-numArg {
    width: 35px;
    text-align: center;
    height: 20px;
    resize: none;
    overflow: hidden;
}
.input-argomento {
    width: -webkit-fill-available;
    height: 20px;
    /* margin-bottom: 10px; */
    margin-left: 4px;
    margin-right: 4px;
    overflow: hidden;
    resize: none;
}
.h-link-opener {
    margin: 0px 2px 0px 0px;
    width: 50px;
    cursor: pointer;
    color: #0066cc;
    text-decoration: underline;
}
.input-href-hide,
.input-href {
    height: 20px;
    /* margin-bottom: 10px; */
    margin-left: 2px;
    margin-right: 5px;
    overflow: hidden;
    resize: none;
    width: -webkit-fill-available;
}
.input-href-hide{
    width: 217px;
}
.addArgBtn, .delArgBtn, .addArgBtn_from0, .DriveBtn {
    width: 23px;
    /* Larghezza del pulsante */
    height: 23px;
    /* Altezza del pulsante */
    background-color: #f0f0f0;
    /* Colore di sfondo bianco grigiolino */
    color: black;
    /* Colore del testo */
    border: 2px outset #ccc;
    /* Bordo outset */
    border-radius: 5px;
    /* Angoli arrotondati (opzionale) */
    font-size: 24px;
    /* Dimensione del simbolo */
    display: flex;
    /* Utilizza Flexbox */
    justify-content: center;
    /* Centra orizzontalmente */
    align-items: center;
    /* Centra verticalmente */
    cursor: pointer;
    /* Cambia il cursore al passaggio del mouse */
    transition: background-color 0.3s, border-style 0.1s;
    /* Transizione per lo sfondo e il bordo */
    position: sticky;
}
.DriveBtn {
    width: 30px;
    height: 23px;
    margin-left: 30px;
}
#from0{
    left: 235px;
    top: 13px;
}
.addArgBtn {
    left: 229px;
}
.delArgBtn {
    left: 253px;
    background-color: #f78080;
    font-size: medium;
}
.delArgBtn:active {
    border-style: inset;
    /* Bordo inset al clic */
    background-color: #e33e3e;
}
.addArgBtn:hover, .addArgBtn_from0:hover {
    background-color: #e0e0e0;
    /* Colore di sfondo al passaggio del mouse */
}
.addArgBtn:active, .addArgBtn_from0 {
    border-style: inset;
    /* Bordo inset al clic */
    background-color: #d0d0d0;
    /* Colore di sfondo al clic */
}
.bannerNotReg{
    margin-left: auto;
}
.tool_sidebar {
    display: flex;
    align-items: center;
    margin-bottom: 2px;
}
.checkbox-wrapper-accessFile,
.checkbox-wrapper-saveFile {
    padding-right: 5px;
    border-radius: 20em;
    height: 21px;
    display: flex;
    align-items: flex-end;
    /* align-items: center; */
}
.checkbox-wrapper-saveFile {
    background-color: orange;
    margin-right: 5px;
}
.checkbox-wrapper-accessFile {
    color: white;
    background-color: green;
}
.saveFile{
    background-color: white;
}
label[for="saveFile"] {
    margin-left: 2px;
}
.suggestions {
    position: absolute;
    border: 1px solid #ccc;
    background: #fff;
    z-index: 1000;
}
.suggestion-item {
    padding: 5px;
    cursor: pointer;
}
.suggestion-item:hover {
    background: #f0f0f0;
}
.highlight {
    background-color: yellow;
    font-weight: bold;
}
/* Barra inferiore */
#bottom-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #333;
    color: white;
    /* padding: 10px 0; */
    z-index: 1000; /* Assicura che sia sopra il contenuto */
    box-shadow: 0 -2px 5px rgba(0,0,0,0.2);
}
#bottom-bar .bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}
#bottom-bar a {
    color: white;
    text-decoration: none;
    padding: 5px 10px;
    transition: background-color 0.3s;
}
#bottom-bar a:hover {
    background-color: #555;
    border-radius: 3px;
}
/* Stile per i banner modali */
.resource-placeholder {
    border: 1px dashed #ccc;
    padding: 20px;
    margin-top: 10px;
    background-color: #f9f9f9;
    min-height: 50px;
}
.banner-modal {
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    padding: 25px;
    border: 1px solid #ccc;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    z-index: 1002;
    max-width: 90%;
    width: 650px; /* Aumentato leggermente per il contenuto dei cookie */
    border-radius: 8px;
    max-height: 90vh; /* Leggermente più alto per contenuto cookie */
    overflow-y: auto;
}
.banner-modal .banner-content h2 { /* Specificità per h2 dentro .banner-content */
    margin-top: 0;
    color: #333;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
    margin-bottom: 15px;
    font-size: 1.5em; /* Dimensione titolo modal */
}
.banner-modal span { /* Stile generico, potrebbe necessitare affinamento */
    /* margin-bottom: 15px; Questo potrebbe essere troppo generico */
    color: #555;
    font-size: 0.95em;
}
.banner-modal p {
    font-size: 0.95em;
    line-height: 1.5;
    color: #555;
    margin-bottom: 10px;
}
.banner-modal a {
    color: #007bff;
    text-decoration: none;
}
.banner-modal a:hover {
    text-decoration: underline;
}
.close-banner-btn {
    display: block;
    margin: 20px auto 0;
    padding: 10px 20px;
    background-color: #6c757d; /* Grigio per coerenza con rifiuta */
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1em;
    transition: background-color 0.3s;
}
.close-banner-btn:hover {
    background-color: #545b62;
}
/* Overlay per lo sfondo (dal tuo CSS) */
#modal-overlay { /* Rinominato da #overlay per chiarezza */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6); /* Leggermente più scuro */
    z-index: 1001;
}
/* Barra inferiore (dal tuo CSS) */
#bottom-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #333;
    color: white;
    z-index: 1000;
    box-shadow: 0 -2px 5px rgba(0,0,0,0.2);
}
#bottom-bar .bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    /* padding: 5px 20px; */
}
#bottom-bar a {
    color: white;
    text-decoration: none;
    /* padding: 8px 12px; */
    margin-left: 10px; /* Spazio tra i link */
    transition: background-color 0.3s;
}
#bottom-bar a:hover {
    background-color: #555;
    border-radius: 3px;
}
/* Stili specifici per il MODAL dei Cookie */
#cookie-consent-modal .cookie-category {
    border: 1px solid #e0e0e0;
    border-radius: 5px;
    margin-bottom: 15px;
    padding: 15px;
    background-color: #fdfdfd;
}
#cookie-consent-modal .cookie-category-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: bold;
    margin-bottom: 8px;
}
#cookie-consent-modal .cookie-category-title label {
    cursor: pointer;
}
#cookie-consent-modal .cookie-category-title .always-active {
    font-style: italic;
    color: #28a745; /* Verde per sempre attivi */
    font-size: 0.9em;
    font-weight:normal;
}
#cookie-consent-modal .cookie-category-description {
    font-size: 0.9em;
    color: #444;
    margin-bottom: 0;
    line-height: 1.4;
}
#cookie-consent-modal .cookie-modal-actions {
    display: flex;
    justify-content: space-around; /* Spazio tra i bottoni */
    gap: 10px;
    margin-top: 25px;
    margin-bottom:15px;
    padding-top: 15px;
    border-top: 1px solid #eee;
}
#cookie-consent-modal .cookie-modal-actions button {
    padding: 10px 15px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.95em;
    flex-grow: 1; /* Fa sì che i bottoni occupino spazio simile */
}
#cookie-consent-modal #accept-all-cookies-modal {
    background-color: #28a745; /* Verde */
    color: white;
}
#cookie-consent-modal #accept-all-cookies-modal:hover {
    background-color: #218838;
}
#cookie-consent-modal #confirm-choices-cookies-modal {
    background-color: #007bff; /* Blu */
    color: white;
}
#cookie-consent-modal #confirm-choices-cookies-modal:hover {
    background-color: #0056b3;
}
#cookie-consent-modal #reject-all-cookies-modal {
    background-color: #dc3545; /* Rosso */
    color: white;
}
#cookie-consent-modal #reject-all-cookies-modal:hover {
    background-color: #c82333;
}
/* Switch styles (invariati dalla versione precedente, ma assicurati siano presenti) */
.switch_cookies {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}
.switch_cookies input { opacity: 0; width: 0; height: 0; }
.slider_cookies {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: #ccc;
    transition: .4s;
}
.slider_cookies:before {
    position: absolute;
    content: "";
    height: 18px; width: 18px;
    left: 3px; bottom: 3px;
    background-color: white;
    transition: .4s;
}
input:checked + .slider_cookies { background-color: #007bff; } /* Blu per coerenza */
input:focus + .slider_cookies { box-shadow: 0 0 1px #007bff; }
input:checked + .slider_cookies:before { transform: translateX(26px); }
.slider_cookies.round { border-radius: 24px; }
.slider_cookies.round:before { border-radius: 50%; }
/* Responsive */
@media (max-width: 768px) {
    .banner-modal {
        width: 95%; /* Più largo su mobile */
        padding: 10px 15px;
        font-size: small;
    }
    /* #cookie-consent-modal .cookie-modal-actions { */
        /* flex-direction: column; Bottoni in colonna su mobile */
        /* flex-direction: column; */
    /* } */
    #license{
        text-align: center;
    }
    #cookie-consent-modal .cookie-modal-actions button {
        width: 100%; /* Bottoni a piena larghezza */
        margin-bottom: 10px;
    }
    /* #cookie-consent-modal .cookie-modal-actions button:last-child {
        margin-bottom: 0;
    } */
    #bottom-bar .bar-content {
        /* flex-direction: column;
                */
        display: inline-flex;
        justify-content: space-between;
        width: 94%;
        padding: 0px 20px;
    }
    
    #bottom-bar a {
        margin-left: 0;
        /* padding: 0; */
        /* display: block; Link a blocco intero su mobile */
        display: table-cell;
        text-align: center;
        vertical-align: middle;
    }
    .slider_cookies {
        width: 44px;
    }
    .slider_cookies:before {
        left: 0px;
    }
}

/* Stili specifici (opzionali) per il contenuto del modale licenza */
#license-info-modal .license-details {
    font-size: 0.95em;
    line-height: 1.6;
    color: #333; /* Colore testo standard */
}

#license-info-modal .license-details b {
    /* display: block; Fa andare "Copyright:" a capo */
    margin-bottom: 5px;
    color: #111; /* Un po' più scuro per il titolo */
}

#license-info-modal .license-details a {
    color: #007bff; /* Colore standard per i link */
    text-decoration: none;
}

#license-info-modal .license-details a:hover {
    text-decoration: underline;
}

#license-info-modal .license-details img {
    height: 1.2em; /* Altezza unificata per le icone CC */
    margin-left: .2em;
    vertical-align: -0.2em; /* Aggiustamento fine per l'allineamento verticale */
    border: none; /* Assicura che non ci siano bordi strani sulle immagini linkate */
}

.control-panel {
    max-width: 600px;
    margin: 4px 0px;
    padding: 2px 5px;
    font-family: Arial, sans-serif;
    background: #96b3df;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    display: none; /* Nascosto di default */
}

/* Header del pannello di controllo (cliccabile per espandere/comprimere) */
.control-panel-header {
    cursor: pointer;
    user-select: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 10px;
    border-radius: 6px;
    transition: background-color 0.3s ease;
}

.control-panel-header:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.control-panel-title {
    margin: 0;
    font-size: 10pt;
    font-weight: bold;
}

.control-panel-toggle {
    font-size: 16px;
    transition: transform 0.3s ease;
}

.control-panel-toggle.expanded {
    transform: rotate(180deg);
}

/* Contenuto espandibile del pannello */
.control-panel-content {
    overflow: hidden;
    transition: max-height 0.3s ease, opacity 0.3s ease;
    max-height: 0;
    opacity: 0;
}

.control-panel-content.expanded {
    max-height: 500px; /* Altezza massima sufficiente per il contenuto */
    opacity: 1;
}

/* Container dei pulsanti come griglia 3x3 */
.control-panel .btn-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 10px;
    margin: 10px 0;
    max-width: 450px;
    margin-left: auto;
    margin-right: auto;
    justify-items: center;
}
.control-panel-class {
    background-color: #8edf8e;
    border-bottom: outset;
    position: sticky;
    top: 0;
    z-index: 900;
    display: none; /* Nascosto di default */
}
.control-panel-class .btn-grid-panel {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 4px;
    padding: 4px 6px;
}
.control-panel-class .btn-grid-panel .btn-syncG-class {
    width: auto;
    min-width: 0;
    font-size: 12px;
    padding: 2px 4px;
}
.btn-stop-sync {
    background: #ff9800 !important;
    display: none !important;
}
.btn-stop-sync.visible {
    display: flex !important;
}
.btn-stop-sync:hover {
    background: #e68900 !important;
}
.btn-close-panel {
    background: #607d8b !important;
    display: none !important;
}
.btn-close-panel.visible {
    display: flex !important;
}
.btn-close-panel:hover {
    background: #455a64 !important;
}

.btn-syncG {
    background: #4CAF50;
    color: white;
    padding: 0px 15px;
    width: 60px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    text-align: center;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.btn-syncG-class {
    background: #4CAF50;
    color: white;
    padding: 0px 0px;
    width: 119px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 15px;
    font-weight: bold;
    text-align: center;
    min-height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}
.btn-syncG-class:hover {
    background: #45a049; 
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}
.btn-syncG:hover { 
    background: #45a049; 
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}
.btn-syncG.btn-danger { 
    background: #f44336; 
}
.btn-syncG.btn-danger:hover { 
    background: #d32f2f; 
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(244, 67, 54, 0.3);
}
.btn-syncG.btn-info { 
    background: #2196F3; 
}
.btn-syncG.btn-info:hover { 
    background: #1976D2; 
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(33, 150, 243, 0.3);
}
.btn-syncG.btn-warning { 
    background: #ff9800; 
}
.btn-syncG.btn-warning:hover { 
    background: #f57c00; 
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(255, 152, 0, 0.3);
}
.btn-syncG.btn-secondary { 
    background: #6c757d; 
}
.btn-syncG.btn-secondary:hover { 
    background: #5a6268; 
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(108, 117, 125, 0.3);
}
.result {
    margin: 20px 0;
    padding: 15px;
    border-radius: 5px;
    display: none;
}
.success { background: #d4edda; color: #155724; }
.error { background: #f8d7da; color: #721c24; }