/* FABIO 28/11/2026 cornice tf delle pagine (testata, barra del menu, percorso, piè di pagina).
   Tutte le regole valgono solo con la classe "tf-shell" su <html>, impostata dal Site.Master:
   togliendo la classe (o il link a questo file) si torna alla cornice di prima.
   Il menu mostra solo le voci che il server manda: qui non si nasconde e non si aggiunge nessuna voce. */

html.tf-shell { background-color:#eef2f6; }
html.tf-shell body { border-top:0; background-color:#eef2f6; }
html.tf-shell #body { background-color:#eef2f6; padding-bottom:24px; }

/* ---------- testata ---------- */
html.tf-shell header { background:#fff; border-bottom:1px solid #dbe3ea; }
html.tf-shell header .content-wrapper { display:flex; align-items:center; gap:16px; padding:8px 24px !important; }
html.tf-shell header .float-left,
html.tf-shell header .float-right { float:none; }
html.tf-shell header .site-title { margin:0; line-height:0; }
html.tf-shell header .site-title input[type=image] { max-height:46px; width:auto; border:0; outline:0; }
html.tf-shell header ul#menu,
html.tf-shell header nav { display:none; }
html.tf-shell header .float-right { margin-left:auto; font-size:13px; color:#4a5866; }
/* blocco utente di prima: nascosto solo quando lo script ha costruito quello nuovo */
html.tf-shell header .tfs-vecchio { display:none !important; }

.tfs-utente { margin-left:auto; display:flex; align-items:center; gap:14px; font-family:Inter,"Segoe UI",Roboto,sans-serif; }
.tfs-ruoli { display:flex; flex-wrap:wrap; gap:5px; justify-content:flex-end; max-width:520px; }
.tfs-ruolo { font-size:11px; font-weight:600; color:#003366; background:#e8f0f8; border-radius:10px; padding:2px 8px; white-space:nowrap; }
.tfs-chi { display:flex; align-items:center; gap:10px; border-left:1px solid #dbe3ea; padding-left:14px; }
.tfs-avatar { width:32px; height:32px; border-radius:50%; background:#003366; color:#fff; display:inline-flex; align-items:center; justify-content:center; font-weight:700; font-size:13px; flex:0 0 32px; }
.tfs-nome { font-weight:600; font-size:13px; color:#1b2733; line-height:1.25; }
.tfs-azioni { font-size:12px; line-height:1.25; }
.tfs-azioni a { color:#003366; text-decoration:none; font-weight:500; }
.tfs-azioni a:hover { text-decoration:underline; }

/* ---------- barra del menu (sezione "featured" delle pagine) ---------- */
html.tf-shell .featured { background:#003366; }
html.tf-shell .featured .content-wrapper {
    background:#003366 !important; background-image:none !important; color:#fff;
    padding:0 24px !important; display:flex; flex-wrap:nowrap; align-items:stretch; gap:2px;
    overflow-x:auto; scrollbar-width:thin; }
html.tf-shell .featured hgroup.title { display:none; }
/* il pannello che contiene le voci (PanelGestione) non deve fare da scatola: le voci restano in fila */
html.tf-shell .featured .content-wrapper > div { display:contents; }
html.tf-shell .featured .content-wrapper a {
    color:#c9d6e3 !important; font-weight:600 !important; font-size:14px; text-decoration:none !important;
    padding:12px 12px 9px; border-bottom:3px solid transparent; white-space:nowrap; line-height:1.2; }
html.tf-shell .featured .content-wrapper a:hover { color:#fff !important; background:rgba(255,255,255,.06); }
html.tf-shell .featured .content-wrapper a.tfs-attiva { color:#fff !important; border-bottom-color:#5fb4e5; background:rgba(255,255,255,.08); }

/* ---------- percorso (al posto del titolo grande) ---------- */
.tfs-percorso { padding:12px 24px 0; font-size:12px; color:#6b7785; font-family:Inter,"Segoe UI",Roboto,sans-serif; }
.tfs-percorso b { color:#4a5866; font-weight:600; }

/* ---------- area contenuto ---------- */
html.tf-shell .main-content,
html.tf-shell .featured + .main-content { background:none; padding:10px 24px 0; }

/* ---------- piè di pagina ---------- */
html.tf-shell footer { height:auto; background:#fff; border-top:1px solid #dbe3ea; font-size:12px; color:#6b7785; }
html.tf-shell footer .content-wrapper { display:flex; align-items:center; gap:10px; padding:10px 24px; }
html.tf-shell footer .float-left { float:none; }
html.tf-shell footer p { margin:0; }
.tfs-footer-link { margin-left:auto; }
.tfs-footer-link a { color:#6b7785; text-decoration:none; }
.tfs-footer-link a:hover { color:#003366; text-decoration:underline; }
/* fine FABIO */

/* FABIO 28/11/2026 tavolozza comune: il blu notte resta solo su barra del menu e testate; pulsanti in blu medio, intestazioni di griglia chiare, viste attive in blu chiaro (vale per dashboard ed elenchi con stile proprio) */
html.tf-shell .tfd input[type=submit], html.tf-shell .tfd input[type=button], html.tf-shell .tfd .tfd-btn,
html.tf-shell .tfl input[type=submit], html.tf-shell .tfl input[type=button], html.tf-shell .tfl a.tfl-btn,
html.tf-shell .tfc .tfc-btn-pri, html.tf-shell .tfc input[type=submit][id$=btNuova], html.tf-shell .tfc input[id$=btFiltraCommesse], html.tf-shell .tfc input[type=submit][id$=btEseguiDuplica] { background:#1f5c99; border-color:#1f5c99; }
html.tf-shell .tfd input[type=submit]:hover, html.tf-shell .tfd input[type=button]:hover, html.tf-shell .tfd .tfd-btn:hover,
html.tf-shell .tfl input[type=submit]:hover, html.tf-shell .tfl input[type=button]:hover, html.tf-shell .tfl a.tfl-btn:hover,
html.tf-shell .tfc .tfc-btn-pri:hover { background:#174a7c; border-color:#174a7c; }
html.tf-shell .tfd-num, html.tf-shell .tfl-num, html.tf-shell .tfc-step, html.tf-shell .tfd-progress-bar { background:#2f6fb0; }
html.tf-shell .tfd-vista-tab.tfd-vista-on, html.tf-shell .tfl .tfl-vista-tab.tfl-vista-on { background:#2f6fb0; }
html.tf-shell .tfd a.tfd-chip.tfd-chip-on { background:#2f6fb0; border-color:#2f6fb0; }
html.tf-shell tr.tfd-pager span, html.tf-shell .tfd-tab table tr[style*="background-color:#284775"] span { background:#2f6fb0; border-color:#2f6fb0; }
html.tf-shell table.tfd-grid th, html.tf-shell .tfd-tab table th, html.tf-shell table.tfl-grid th { background:#eaf1f8 !important; color:#1f3a5f !important; border-bottom:2px solid #c9d8e8; }
html.tf-shell table.tfd-grid th a, html.tf-shell .tfd-tab table th a, html.tf-shell table.tfl-grid th a { color:#1f3a5f !important; }
html.tf-shell .tfd-c-azioni a, html.tf-shell .tfl-c-azioni a { background:#fff; color:#1f5c99 !important; border:1px solid #b9cde2; }
html.tf-shell .tfd-c-azioni a:hover, html.tf-shell .tfl-c-azioni a:hover { background:#eaf1f8; }
html.tf-shell .tfd-tabs > .ajax__tab_header .ajax__tab_tab { background:#eef3f8; border:1px solid #dbe3ea; border-bottom:0; color:#2b4a6b; }
html.tf-shell .tfd-tabs > .ajax__tab_header .ajax__tab_active .ajax__tab_tab { background:#fff; color:#003366; border-color:#cfdbe7; box-shadow:inset 0 3px 0 #2f6fb0; }
html.tf-shell .tfb { --tfb-pri:#1f5c99; }
html.tf-shell [id^="MainContent_"][style*="border-color:#003366"], html.tf-shell [id^="MainContent_"][style*="border-color:#336699"] { border-color:#dbe3ea !important; border-radius:8px; }
/* fine FABIO */

/* FABIO 28/11/2026 pagina larga quanto la finestra (Site.css mette body in display:table, che allargava la pagina oltre lo schermo quando il menu ha molte voci);
   voci del menu un po' piu' strette sugli schermi fino a 1600px, cosi' stanno tutte in fila senza scorrere */
html.tf-shell body { display:block; }
@media (max-width:1599px) {
    html.tf-shell .featured .content-wrapper { padding:0 16px !important; }
    html.tf-shell .featured .content-wrapper a { padding:12px 9px 9px; font-size:13.5px; }
}
/* fine FABIO */

/* FABIO 28/11/2026 testata sul telefono: senza i ruoli e con margini stretti, cosi' la pagina non diventa piu' larga dello schermo */
@media (max-width:760px) {
    html.tf-shell header .content-wrapper { padding:8px 12px !important; gap:10px; }
    html.tf-shell header .site-title input[type=image] { max-width:150px; height:auto; }
    .tfs-ruoli { display:none; }
    .tfs-chi { border-left:0; padding-left:0; }
    .tfs-nome { max-width:140px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
    html.tf-shell .featured .content-wrapper { padding:0 8px !important; }
    .tfs-percorso { padding:10px 12px 0; }
    html.tf-shell .main-content, html.tf-shell .featured + .main-content { padding:10px 12px 0; }
    html.tf-shell footer .content-wrapper { flex-wrap:wrap; padding:10px 12px; }
}
/* fine FABIO */
