/* Mappa live · BrandMeister Italia 2222 (live.dmrbrescia.it) */
:root {
  --bg: #0b1017; --glass: rgba(14, 20, 29, .66); --glass-line: rgba(255, 255, 255, .09);
  --text: #e8edf3; --muted: #93a0b0; --accent: #4c8dff;
  --rpt: #ffb020; --hs: #22d3ee; --hsd: #34d399; --app: #a78bfa; --air: #ff4d4f;
  --name: #ffd166;   /* nome di chi trasmette (utente, 05/12/2026: "evidenzia meglio il nome") */
  --radius: 14px; --shadow: 0 10px 30px rgba(0, 0, 0, .35);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--text); overflow: hidden; }
#map { position: absolute; inset: 0; }
a { color: #7fb0ff; text-decoration: none; }
a:hover { text-decoration: underline; }
button { font: inherit; color: inherit; }

.glass {
  position: absolute; z-index: 2; background: var(--glass); border: 1px solid var(--glass-line);
  border-radius: var(--radius); box-shadow: var(--shadow);
  backdrop-filter: blur(14px) saturate(140%); -webkit-backdrop-filter: blur(14px) saturate(140%);
}

/* testata */
/* stessa larghezza della colonna di sinistra (utente, 03/12/2026: "troppo largo") */
/* finestre spostabili col mouse (utente, 03/12/2026) */
@media (min-width: 761px) {
  .glass.dragging { cursor: grabbing; user-select: none; box-shadow: 0 14px 40px rgba(0, 0, 0, .55); z-index: 6; opacity: .96; }
  /* in trascinamento (utente, 04/12/2026): il contorno diventa una riga sottile gialla con una luce che gli gira attorno,
     e sparisce al rilascio. Riga disegnata in ::after (gradiente conico ritagliato al solo bordo); --drag-st la tiene
     ferma sulle finestre che scorrono (map.js la mette a scrollTop all'inizio del trascinamento) */
  .glass.dragging { border-color: transparent; }
  .glass.dragging::after {
    content: ""; position: absolute; left: 0; right: 0; top: var(--drag-st, 0px); bottom: calc(0px - var(--drag-st, 0px));
    border-radius: inherit; padding: 2px; pointer-events: none; z-index: 10;
    background: conic-gradient(from var(--drag-ang), rgba(255, 209, 102, .35) 0deg, rgba(255, 209, 102, .35) 250deg,
      #ffd166 300deg, #fff3c4 335deg, #ffd166 350deg, rgba(255, 209, 102, .35) 360deg);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor; mask-composite: exclude;
    filter: drop-shadow(0 0 3px rgba(255, 209, 102, .7));
    animation: drag-spin 1.4s linear infinite;
  }
}
@property --drag-ang { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
/* gira anche con "movimento ridotto" del sistema: dura solo mentre si trascina ed è l'utente a farlo partire (04/12/2026) */
@keyframes drag-spin { to { --drag-ang: 360deg; } }
.brand { top: 14px; left: 14px; width: 300px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 9px 10px 7px 9px; }
.brand-text { min-width: 0; flex: 1; }
.brand-row { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-top: 4px; }
.brand .logo { width: 42px; height: 42px; border-radius: 22%; box-shadow: 0 2px 8px rgba(0,0,0,.45); }   /* logo di BM-Companion (05/12/2026) */
/* logo: tocco = ricarica forzata, con un giro mentre riscarica */
/* il logo è un vero pulsante: sui telefoni un'immagine non sempre riceve il tocco (utente, 03/12/2026: "nel mobile il logo non lancia il refresh") */
#logo-reload { flex: none; display: block; padding: 0; margin: 0; border: 0; background: none; border-radius: 50%; line-height: 0; font: inherit; color: inherit;
  cursor: pointer; transition: transform .2s, box-shadow .2s; -webkit-tap-highlight-color: transparent; touch-action: manipulation;
  -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; }
#logo-reload img { display: block; pointer-events: none; }
#logo-reload:hover { box-shadow: 0 0 0 3px rgba(76, 141, 255, .45); }
#logo-reload:active { transform: scale(.92); }
#logo-reload.spin { animation: logospin .8s linear infinite; }
@keyframes logospin { to { transform: rotate(360deg); } }
.brand h1 { margin: 0; font-size: 16px; letter-spacing: .1px; white-space: nowrap; }
.brand p { margin: 1px 0 0; font-size: 11px; color: var(--muted); }
.brand p b { color: var(--text); }
/* "Pagina in sviluppo" (utente, 03/12/2026) */
.dev-badge { display: inline-block; white-space: nowrap; padding: 1px 6px; border-radius: 5px; font-size: 9.5px; font-weight: 700;
  letter-spacing: .3px; text-transform: uppercase; color: #1a1300; background: #ffb020; }
/* firma nella testata (utente, 03/12/2026: "integrare elegantemente IZ2FTR in questo frame"):
   riga sottile a tutta larghezza, filetti ai lati e nominativo al centro */
/* scritto come si legge, "by IZ2FTR", non tutto maiuscolo (utente, 03/12/2026) */
.sign { flex-basis: 100%; display: flex; align-items: center; gap: 8px; margin-top: -3px; font-size: 10.5px; line-height: 1;
  letter-spacing: .4px; color: var(--muted); }
.sign::before, .sign::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .16)); }
.sign::after { background: linear-gradient(90deg, rgba(255, 255, 255, .16), transparent); }
.sign span { opacity: .8; margin-right: -4px; }
.sign b { color: var(--text); font-weight: 700; letter-spacing: .6px; }
.sign em { font-style: normal; opacity: .8; }
.sign em i { font-style: normal; margin: 0 7px; }
.credit-m { display: none; }
.conn { display: flex; align-items: center; gap: 6px; white-space: nowrap; min-width: 0; overflow: hidden; font-size: 11.5px; color: var(--muted);
  padding: 4px 9px; border-radius: 20px; background: rgba(255, 255, 255, .05); text-transform: uppercase; letter-spacing: .6px; }
.conn .dot { width: 8px; height: 8px; border-radius: 50%; background: #6b7785; }
.conn.ok .dot { background: #3ddc84; box-shadow: 0 0 0 0 rgba(61, 220, 132, .7); animation: beat 2s infinite; }
.conn.ok { color: #9fe8bf; }
.conn.bad .dot { background: #ff6b6b; }
@keyframes beat { 0% { box-shadow: 0 0 0 0 rgba(61, 220, 132, .6); } 70% { box-shadow: 0 0 0 8px rgba(61, 220, 132, 0); } 100% { box-shadow: 0 0 0 0 rgba(61, 220, 132, 0); } }

/* contatori */
.stats { top: 86px; left: 14px; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; width: 300px; padding: 8px 6px; cursor: help; }
/* statistiche degli accessi: stessa misura dei contatori, quattro numeri (utente, 03/12/2026) */
.visits { top: 160px; }
.visits .stat b { color: #e8edf3; }
body.m .visits { display: none; }   /* sul telefono stanno nella scheda Mappa */
.stat { display: flex; flex-direction: column; align-items: center; gap: 1px; }
.stat b { font-size: 22px; font-variant-numeric: tabular-nums; line-height: 1.1; }
.stat > span { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .6px; }
/* chi ha la mappa aperta adesso (utente, 03/12/2026) */
.stat.users b { color: #7fb2ff; }
.stat.all b { color: #e8edf3; } .stat.air b { color: var(--air); } .stat.at b { color: #7fb2ff; }
/* «AirTime + FF» col bottone Fast Forward dei TG impegnati acceso (06/12/2026): il viola delle FF */
.stat.at.ff b { color: #c9c3ff; }

/* layer */
.layers { top: 160px; left: 14px; width: 300px; padding: 6px; display: grid; grid-template-columns: 1fr; gap: 1px; }
/* icone centrate sullo stesso asse verticale, qualunque sia la loro larghezza (utente, 03/12/2026: "non sono allineate") */
.layer .sw { grid-row: 1 / 3; align-self: center; justify-self: center; background: var(--k); }
.layer .nm { font-weight: 600; }
.layer .cn { color: var(--k); font-size: 15px; font-variant-numeric: tabular-nums; text-align: right; }
.layer .om { grid-column: 2 / 4; color: var(--muted); font-size: 10.5px; line-height: 1.1; }
.layer { display: grid; grid-template-columns: 16px 1fr auto; column-gap: 8px; align-items: center; padding: 4px 8px; border-radius: 9px; cursor: pointer; font-size: 13px; user-select: none; }
.layer[hidden] { display: none; }
.layer:hover { background: rgba(255, 255, 255, .06); }
.layer input { display: none; }
.layer .sw { width: 12px; height: 12px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .85); }
/* ripetitore: la stessa tessera col traliccio della mappa */
.layer .sw.rpt, .tg-table .sw.rpt { width: 16px; height: 16px; border: 0; border-radius: 0; transform: none; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-13 -13 26 26'%3E%3Cdefs%3E%3ClinearGradient id='a' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%23ffd166'/%3E%3Cstop offset='1' stop-color='%23f59e0b'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect x='-12.5' y='-12.5' width='25' height='25' rx='7' fill='url(%23a)' stroke='%230b1017' stroke-width='1'/%3E%3Cg transform='translate(0 1)' fill='none' stroke='%231a1205' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M0-4.6L-4.4 8.2M0-4.6L4.4 8.2' stroke-width='2.1'/%3E%3Cpath d='M-2.7 3.2H2.7M-3.6 5.8H3.6M-2.7 3.2L3.6 5.8M2.7 3.2L-3.6 5.8M-1.6 .2H1.6' stroke-width='1.5'/%3E%3Ccircle cx='0' cy='-5.6' r='1.8' fill='%231a1205' stroke='none'/%3E%3Cpath d='M3.6-7.6A4.2 4.2 0 0 1 3.6-3.6M-3.6-7.6A4.2 4.2 0 0 0-3.6-3.6M6.3-9.4A7.4 7.4 0 0 1 6.3-1.8M-6.3-9.4A7.4 7.4 0 0 0-6.3-1.8' stroke-width='1.6'/%3E%3C/g%3E%3C/svg%3E") center / contain no-repeat; }
.tg-table .sw.rpt { width: 11px; height: 11px; }
.layer .sw.hs, .layer .sw.hsd { width: 16px; height: 16px; border-width: 1.5px; display: flex; align-items: center; justify-content: center;
  font: normal 900 10px/1 system-ui, sans-serif; color: #06121a; }
.layer .sw.hs::after { content: "H"; }
.layer .sw.hsd::after { content: "H"; }
.layer .sw.hsd::before { content: "D"; order: 2; font-size: 5.5px; margin: 4px 0 0 .3px; }
.layer:has(input:not(:checked)) { opacity: .45; }
.layer:has(input:not(:checked)) .sw { filter: grayscale(1); }

/* strumenti */
.tools { top: 14px; right: 14px; width: 300px; padding: 8px; display: flex; flex-direction: column; gap: 8px; }
.search { position: relative; }
.search input { width: 100%; padding: 9px 12px; border-radius: 10px; border: 1px solid var(--glass-line); background: rgba(0, 0, 0, .25);
  color: var(--text); font-size: 14px; outline: none; }
.search input:focus { border-color: var(--accent); }
.q-res { position: absolute; top: 100%; left: 0; right: 0; margin: 4px 0 0; padding: 4px; list-style: none; background: #121a25;
  border: 1px solid var(--glass-line); border-radius: 10px; max-height: 260px; overflow: auto; z-index: 5; }
.q-res li { padding: 7px 9px; border-radius: 7px; cursor: pointer; display: flex; gap: 8px; align-items: center; font-size: 13px; }
.q-res li:hover, .q-res li.sel { background: rgba(76, 141, 255, .18); }
.q-res li small { color: var(--muted); margin-left: auto; }
.bases { display: grid; grid-template-columns: repeat(5, 1fr); gap: 5px; }
.base { display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 0; border: 0; background: none; cursor: pointer; }
.base .thumb { width: 100%; aspect-ratio: 1; border-radius: 9px; background-size: cover; background-position: center;
  border: 2px solid transparent; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .12); }
.base span { font-size: 10.5px; color: var(--muted); white-space: nowrap; }
.base[aria-checked="true"] .thumb { border-color: var(--accent); }
.base[aria-checked="true"] span { color: var(--text); }
/* colonne uguali per i bottoni che si vedono (il «?» della guida può essere nascosto) */
.row-btns { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 5px; }
.row-btns [hidden], #m-more [hidden] { display: none; }
.btn { padding: 7px 0; border-radius: 9px; border: 1px solid var(--glass-line); background: rgba(255, 255, 255, .05); cursor: pointer; font-size: 15px; }
.btn:hover { background: rgba(255, 255, 255, .1); }
.btn.lang, #btn-italy { font-size: 12.5px; font-weight: 700; letter-spacing: .5px; }
/* guida: un link con l'aspetto dei bottoni */
.btn.help { display: block; text-align: center; color: var(--text); text-decoration: none; font-weight: 800; }
.btn.help:hover { text-decoration: none; }

/* in onda */
.live { top: 232px; left: 14px; width: 300px; padding: 10px 10px 8px; max-height: calc(100vh - 250px); overflow: auto; }
.live h2, .log h2, #live-h { margin: 0 0 6px; font-size: 12px; text-transform: uppercase; letter-spacing: .8px; color: var(--muted); display: flex; align-items: center; gap: 8px; }
/* numero dei TG impegnati accanto al titolo (utente, 03/12/2026) */
.h-cnt { min-width: 20px; padding: 0 6px; border-radius: 9px; background: rgba(255, 255, 255, .1); color: var(--text); font-size: 11.5px;
  line-height: 18px; text-align: center; letter-spacing: 0; font-variant-numeric: tabular-nums; }
.h-cnt:empty { display: none; }
.m-pane .live h2, .m-pane #live-h { margin: 4px 2px 8px; }
.rec { width: 9px; height: 9px; border-radius: 50%; background: #55606d; }
.live.on .rec { background: var(--air); animation: rec 1.2s infinite; }
@keyframes rec { 50% { opacity: .25; } }
.live-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.live-item { display: grid; grid-template-columns: 4px 1fr auto; gap: 0 10px; padding: 7px 9px 7px 0; border-radius: 10px;
  background: rgba(255, 255, 255, .045); cursor: pointer; align-items: center; animation: slidein .35s ease-out; }
.live-item:hover { background: rgba(255, 255, 255, .09); }
.live-item .bar { grid-row: 1 / span 2; align-self: stretch; border-radius: 4px; }
.live-item .who { font-weight: 700; font-size: 14px; }
.live-item .who small { font-weight: 600; color: var(--name); margin-left: 4px; }
.live-item .tg { grid-column: 2; font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.live-item .time { grid-row: 1 / span 2; grid-column: 3; font-variant-numeric: tabular-nums; font-weight: 700; font-size: 17px; color: #ffd7d7; }
.live-item.ended { opacity: .45; transition: opacity .6s; }
.empty { margin: 2px 0 2px; font-size: 12.5px; color: var(--muted); }
@keyframes slidein { from { transform: translateX(-12px); opacity: 0; } to { transform: none; opacity: 1; } }

/* pannello a destra: storico e TG */
.side { right: 14px; bottom: 30px; width: 400px; padding: 6px 8px 8px 10px; max-height: 52vh; display: flex; flex-direction: column; }
.tabs { display: flex; gap: 4px; margin-bottom: 6px; }
.tabs > button { all: unset; cursor: pointer; padding: 5px 10px; border-radius: 8px; font-size: 12px; text-transform: uppercase; letter-spacing: .7px; color: var(--muted); }
.tabs > button[aria-selected="true"] { background: rgba(255, 255, 255, .08); color: var(--text); }
.tabs .min { margin-left: auto; transition: transform .2s; }
.side.closed .min { transform: rotate(180deg); }
.side.closed .log-list, .side.closed .tg-pane { display: none; }
/* ridotto: solo le linguette, piccolo nell'angolo in basso a destra (utente, 03/12/2026) */
.side.closed { width: auto; }
.side.closed .tabs { margin-bottom: 0; gap: 2px; }
.side.closed .tabs .min { margin-left: 6px; }
.side.tab-log .tg-pane, .side.tab-tg .log-list { display: none; }
/* Pausa e Fast Forward dello storico: nella riga delle linguette, solo con lo storico aperto (utente, 05/12/2026) */
.log-btns { display: flex; align-items: center; justify-content: flex-end; gap: 6px; margin: -2px 2px 6px; }
.log-btns .ff-btn { margin-left: 0; white-space: nowrap; }
.side.closed .log-btns, .side.tab-tg .log-btns { display: none; }
.pause-btn b { margin-left: 4px; font-weight: 800; color: #fff; }
.pause-btn b:empty { display: none; }
.m-pane h3 .log-btns { order: 1; margin: 0; text-transform: none; letter-spacing: normal; }
.m-pane h3 .ff-btn { text-transform: uppercase; letter-spacing: .5px; }
.log-list { list-style: none; margin: 0; padding: 0 4px 0 0; overflow: auto; }
.log-list li { display: grid; grid-template-columns: 54px 1fr auto; gap: 0 8px; padding: 6px 4px; border-top: 1px solid rgba(255, 255, 255, .05);
  font-size: 12.5px; cursor: pointer; border-radius: 6px; }
.log-list li:hover { background: rgba(255, 255, 255, .05); }
.log-list li.new { animation: flash 1.6s ease-out; }
@keyframes flash { from { background: rgba(255, 77, 79, .25); } to { background: transparent; } }
.log-list .t { color: var(--muted); font-variant-numeric: tabular-nums; }
.log-list .w b { font-size: 13px; }
.log-list .w small { color: var(--name); font-weight: 600; }
.log-list .d { color: var(--muted); font-variant-numeric: tabular-nums; text-align: right; }
.log-list .tgline { grid-column: 2 / span 2; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chip { display: inline-block; padding: 0 6px; border-radius: 6px; font-weight: 700; font-size: 11.5px; color: #0b1017; margin-right: 5px; }
/* chip che col tasto destro apre la Hoseline (utente, 04/12/2026): contorno chiaro al passaggio del mouse */
.chip.hose:hover { outline: 1.5px solid rgba(255, 255, 255, .85); outline-offset: 1px; }

.tg-pane { display: flex; flex-direction: column; min-height: 0; }
.tg-tools { display: grid; grid-template-columns: 1fr auto; gap: 6px; }
.tg-tools input { padding: 7px 10px; border-radius: 9px; border: 1px solid var(--glass-line); background: rgba(0, 0, 0, .25); color: var(--text); font-size: 13.5px; outline: none; min-width: 0; }
.tg-tools input:focus { border-color: var(--accent); }
.seg { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--glass-line); border-radius: 9px; overflow: hidden; }
.seg button { all: unset; cursor: pointer; padding: 6px 10px; font-size: 12px; text-align: center; color: var(--muted); }
.seg button.on { background: var(--accent); color: #fff; }
.legend { display: flex; gap: 14px; font-size: 12px; color: var(--muted); margin: 7px 2px 4px; }
.legend > span { display: flex; align-items: center; gap: 6px; }
.legend .lg-n { color: var(--text); font-weight: 700; font-variant-numeric: tabular-nums; }
.legend .lg-n:empty { display: none; }
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; border: 2.5px solid; }
.dot.st, h3.st .dot { border-color: #3ddc84; } .dot.dy, h3.dy .dot { border-color: #ff4fd8; }
.tg-body { overflow: auto; padding-right: 4px; }
.tg-title { display: flex; align-items: center; gap: 6px; margin: 4px 0 6px; font-size: 14px; }
.tg-title .chip { font-size: 13px; }
.tg-title .x { all: unset; cursor: pointer; margin-left: auto; color: var(--muted); font-size: 18px; padding: 0 4px; }
.tg-air { font-size: 12.5px; padding: 6px 8px; border-radius: 8px; background: rgba(255, 77, 79, .12); margin-bottom: 4px; }
.tg-air b { color: #ffd7d7; }
.tg-body h3 { font-size: 11.5px; text-transform: uppercase; letter-spacing: .7px; margin: 10px 0 4px; display: flex; align-items: center; gap: 6px; }
.tg-body h3.st { color: #8ff0b8; } .tg-body h3.dy { color: #ffa6ef; }
.tg-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.tg-table td { padding: 4px 4px; border-top: 1px solid rgba(255, 255, 255, .05); white-space: nowrap; }
.tg-table tr { cursor: pointer; } .tg-table tr:hover td { background: rgba(255, 255, 255, .05); }
.tg-table tr.nopos { opacity: .55; cursor: default; }
.tg-table td.c { display: flex; align-items: center; gap: 6px; }
.tg-table td.p { color: var(--muted); max-width: 120px; overflow: hidden; text-overflow: ellipsis; }
.tg-table .sw { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.sw.rpt { background: #ffb020; } .sw.hs { background: #22d3ee; } .sw.hsd { background: #34d399; } .sw.app { background: #a78bfa; } .sw.net { background: #60a5fa; } .sw.chk { background: #94a3b8; } .sw.na { background: #555; }


/* TG impegnati (a sinistra) */
.tg-group { border-radius: 10px; background: rgba(255, 255, 255, .04); padding: 4px 0 2px; }
.tg-group.new { animation: slidein .35s ease-out; }
.tg-group.sel { box-shadow: inset 0 0 0 1.5px var(--accent); }
.tg-head { display: flex; align-items: center; gap: 6px; padding: 3px 9px 4px; cursor: pointer; border-left: 4px solid var(--c); border-radius: 4px; margin-left: 0; }
.tg-head .tg-name { font-size: 12.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tg-cnt { margin-left: auto; display: flex; gap: 4px; }
.tg-cnt b { font-size: 11px; padding: 0 6px; border-radius: 8px; border: 1.5px solid; }
.tg-cnt b.st { border-color: #3ddc84; color: #8ff0b8; } .tg-cnt b.dy { border-color: #ff4fd8; color: #ffa6ef; }
.tg-group .live-item { background: none; animation: none; margin-left: 4px; grid-template-columns: 1fr auto; padding: 3px 9px; }
.tg-group .live-item .tg { grid-column: 1; }
.tg-group .live-item .time { grid-row: 1 / span 2; grid-column: 2; font-size: 15px; }
/* traffico entrato da un altro master in FastForward (utente, 05/12/2026): fondo blu-viola tenue e contrassegno «FF · master» */
.tg-group.ff, .live-item.ff, .tg-group .live-item.ff, .log-list li.ff, .tg-air.ff { background: rgba(120, 110, 255, .20); box-shadow: inset 0 0 0 1px rgba(150, 140, 255, .30); }
.tg-group.ff .live-item.ff { background: none; box-shadow: none; }
/* chiamate private: un riquadro per chiamata, fondo rosa (utente, 05/12/2026: «differenzia meglio il fondo per distinguere le private») */
.tg-group.priv { background: rgba(255, 110, 140, .17); box-shadow: inset 0 0 0 1px rgba(255, 143, 163, .32); }
.tg-group.ff.sel { box-shadow: inset 0 0 0 1.5px var(--accent); }
.tg-group .live-item.ff { border-radius: 8px; margin-right: 4px; }
.ff-out { font-size: 12px; color: var(--text); }
.ff-btn { margin-left: auto; font: inherit; font-size: 9.5px; font-weight: 700; letter-spacing: .5px; text-transform: uppercase; color: #c9c3ff;
  background: rgba(120, 110, 255, .08); border: 1px solid rgba(150, 140, 255, .45); border-radius: 7px; padding: 1px 8px; cursor: pointer; line-height: 1.6;
  box-shadow: 0 1px 0 rgba(0, 0, 0, .25); }   /* contorno leggero: si capisce che è un bottone (utente, 05/12/2026) */
.ff-btn:hover { color: #fff; background: rgba(120, 110, 255, .16); border-color: rgba(170, 160, 255, .75); }
.ff-btn.on { color: #e4e0ff; background: rgba(120, 110, 255, .28); border-color: rgba(150, 140, 255, .7); }
.ff-tag { display: inline-block; font-size: 10.5px; font-weight: 700; letter-spacing: .3px; color: #c9c3ff; padding: 0 6px; border-radius: 6px;
  border: 1px solid rgba(150, 140, 255, .45); line-height: 1.5; cursor: help; }

/* TG scelto: pillola sulla mappa con l'interruttore Solo TG / Tutti (utente, 03/12/2026) */
.tg-focus { top: 14px; left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 8px; padding: 5px 6px 5px 8px;
  border-radius: 12px; font-size: 12.5px; white-space: nowrap; max-width: calc(100vw - 680px); }
.tg-focus[hidden] { display: none; }
.tg-focus .chip { margin: 0; font-size: 12px; cursor: pointer; }
.tg-focus .nm { font-weight: 600; overflow: hidden; text-overflow: ellipsis; min-width: 0; cursor: pointer; }
.tg-focus .n { color: var(--muted); font-size: 11px; font-variant-numeric: tabular-nums; }
.tg-focus .n::after { content: " dev"; }
.tg-focus .x { all: unset; cursor: pointer; color: var(--muted); font-size: 18px; line-height: 1; padding: 0 4px; }
.seg.only { grid-template-columns: auto auto; flex: none; }
.seg.only button { padding: 4px 9px; font-size: 11px; font-weight: 600; }
.tg-title .seg.only { margin-left: auto; }
.tg-title .seg.only + .x { margin-left: 2px; }
body.m .tg-focus { top: calc(max(6px, env(safe-area-inset-top)) + 54px); max-width: calc(100vw - 16px); font-size: 11.5px; padding: 3px 4px 3px 6px; gap: 6px; border-radius: 10px;
  background: var(--m-bg); }
body.m .tg-focus .chip { font-size: 10.5px; }
body.m .tg-focus .seg.only button { padding: 3px 8px; font-size: 10.5px; }

/* popup: TG del device */
.pp-tgs { margin-top: 8px; display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.pp-tgs .lbl { font-size: 11px; text-transform: uppercase; letter-spacing: .6px; color: var(--muted); margin-right: 4px; width: 100%; }
.tgchip { all: unset; cursor: pointer; font-size: 11.5px; font-weight: 700; padding: 1px 7px; border-radius: 8px; border: 1.5px solid; font-variant-numeric: tabular-nums; }
.tgchip.st { border-color: #3ddc84; color: #8ff0b8; } .tgchip.dy { border-color: #ff4fd8; color: #ffa6ef; }
.tgchip:hover { background: rgba(255, 255, 255, .08); }
/* slot del TG: TS1 azzurro, TS2 arancio (utente, 03/12/2026) */
.tgchip { display: inline-flex; align-items: center; gap: 5px; }
.tgchip .ts, .tg-table .ts { font-style: normal; font-size: 9.5px; font-weight: 800; letter-spacing: .3px; line-height: 13px; padding: 0 4px; border-radius: 4px; color: #06121a; }
.tgchip .ts1, .tg-table .ts1 { background: #38bdf8; }
.tgchip .ts2, .tg-table .ts2 { background: #fb923c; }

/* etichetta "in onda" sulla mappa */
.air-marker { position: relative; width: 0; height: 0; pointer-events: none; }
.air-marker .ring { position: absolute; left: -14px; top: -14px; width: 28px; height: 28px; border-radius: 50%;
  border: 3px solid var(--c); animation: ring 1.6s ease-out infinite; }
.air-marker .ring.r2 { animation-delay: .53s; } .air-marker .ring.r3 { animation-delay: 1.06s; }
.air-marker .core { position: absolute; left: -7px; top: -7px; width: 14px; height: 14px; border-radius: 50%; background: var(--c);
  box-shadow: 0 0 18px 6px var(--c); border: 2px solid #fff; }
@keyframes ring { from { transform: scale(.4); opacity: 1; } to { transform: scale(3.2); opacity: 0; } }
.air-card { position: absolute; left: 0; bottom: 22px; transform: translateX(-50%); pointer-events: auto; cursor: pointer;
  min-width: 150px; padding: 7px 10px 7px 12px; border-radius: 11px; background: rgba(12, 17, 25, .92); border: 1px solid rgba(255, 255, 255, .12);
  border-left: 4px solid var(--c); box-shadow: 0 8px 22px rgba(0, 0, 0, .45); white-space: nowrap; animation: pop .35s cubic-bezier(.2, 1.4, .4, 1); }
.air-card::after { content: ""; position: absolute; left: 50%; bottom: -7px; margin-left: -6px; border: 6px solid transparent;
  border-top-color: rgba(12, 17, 25, .92); border-bottom: 0; }
/* fumetti spostati a raggiera (map.js doLayout): niente punta, una riga sottile al device */
.air-card { transition: translate .18s ease-out; }
.air-card.moved::after { display: none; }
/* niente freccina: il fumetto è sempre unito all'icona da una riga (map.js doLayout) */
.air-card::after { display: none; }
/* gruppi aperti a raggiera (come la Live Map di DRN-Manager): righine sottili e semitrasparenti dal punto vero all'icona */
.esp-lines { position: absolute; left: 0; top: 0; width: 100%; height: 100%; pointer-events: none; overflow: visible; }
.esp-lines line { stroke-width: 1; stroke-opacity: .6; stroke-linecap: round; }
.esp-lines circle { fill-opacity: .8; stroke: none; }
.esp-ico { width: 14px; height: 14px; cursor: pointer; z-index: 3; }
.esp-ico i { position: absolute; inset: 0; border-radius: 50%; background: var(--k); border: 2px solid #0b1017; box-shadow: 0 0 0 3px color-mix(in srgb, var(--k) 30%, transparent); }
.esp-ico.off i { opacity: .6; }
/* device con il TG scelto: anello statico/dinamico (--ring) */
.esp-ico[style*="--ring"] i { box-shadow: 0 0 0 2px #0b1017, 0 0 0 4.5px var(--ring); }
.esp-ico.let { width: 26px; height: 26px; }
.esp-ico.let i { display: flex; align-items: center; justify-content: center; border-width: 2px; font: normal 900 15px/1 system-ui, sans-serif; color: #06121a; }
.esp-ico.let i sub { font-size: 8.5px; margin: 7px 0 0 .5px; vertical-align: baseline; }
.esp-ico .esp-lb { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); white-space: nowrap; padding: 1px 6px;
  border-radius: 6px; font: 700 11.5px/16px system-ui, sans-serif; letter-spacing: .3px; color: #e8edf3; background: rgba(11, 16, 23, .86);
  border: 1px solid color-mix(in srgb, var(--k) 55%, transparent); }
.esp-ico:hover i { box-shadow: 0 0 0 5px color-mix(in srgb, var(--k) 45%, transparent); }
.esp-ico:hover .esp-lb { background: color-mix(in srgb, var(--k) 30%, #0b1017); }
.maplibregl-marker.esp-anim { transition: transform .15s ease-out; }
.maplibregl-marker.esp-anim .esp-lb { transition: translate .15s ease-out; }
.esp-aperta .maplibregl-popup { z-index: 5; }
.air-lines { position: absolute; left: 0; top: 0; width: 100%; height: 100%; pointer-events: none; overflow: visible; }
/* riga più larga per vederla bene (utente, 03/12/2026), con un bordo scuro che la stacca da qualunque carta */
.air-lines line { stroke-width: 2.6; stroke-opacity: .95; stroke-linecap: round; }
.air-lines line.halo { stroke: rgba(0, 0, 0, .6); stroke-width: 5.5; }
.air-lines g.ended { opacity: 0; transition: opacity .8s ease-in 1.6s; }
.air-card .l1 { display: flex; align-items: baseline; gap: 8px; }
.air-card .call { font-weight: 800; font-size: 14px; letter-spacing: .3px; }
.air-card .name { color: var(--name); font-size: 12.5px; font-weight: 600; }
.air-card .timer { margin-left: auto; padding-left: 10px; font-variant-numeric: tabular-nums; font-weight: 800; color: #ffd7d7; font-size: 14px; }
.air-card .l2 { font-size: 12px; margin-top: 2px; }
.air-card .l3 { font-size: 11px; color: var(--muted); margin-top: 1px; }
.air-marker.ended .ring { animation: none; opacity: 0; }
.air-marker.ended .air-card { opacity: 0; transform: translateX(-50%) translateY(-8px); transition: all .8s ease-in 1.6s; }
.air-marker.ended .core { opacity: 0; transition: opacity .8s ease-in 1.6s; }
@keyframes pop { from { transform: translateX(-50%) scale(.6); opacity: 0; } to { transform: translateX(-50%) scale(1); opacity: 1; } }

/* popup */
.maplibregl-popup-content { background: rgba(12, 17, 25, .96); color: var(--text); border-radius: 14px; padding: 0; box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, .1); min-width: 260px; max-width: 340px; }
/* device senza posizione: scheda al centro, senza punta */
.pp-free .maplibregl-popup-tip { display: none; }
.maplibregl-popup-anchor-bottom .maplibregl-popup-tip, .maplibregl-popup-anchor-bottom-left .maplibregl-popup-tip,
.maplibregl-popup-anchor-bottom-right .maplibregl-popup-tip { border-top-color: rgba(12, 17, 25, .96); }
.maplibregl-popup-anchor-top .maplibregl-popup-tip, .maplibregl-popup-anchor-top-left .maplibregl-popup-tip,
.maplibregl-popup-anchor-top-right .maplibregl-popup-tip { border-bottom-color: rgba(12, 17, 25, .96); }
.maplibregl-popup-anchor-left .maplibregl-popup-tip { border-right-color: rgba(12, 17, 25, .96); }
.maplibregl-popup-anchor-right .maplibregl-popup-tip { border-left-color: rgba(12, 17, 25, .96); }
.maplibregl-popup-close-button { color: var(--muted); font-size: 20px; right: 6px; top: 4px; }
.pp-head { padding: 12px 34px 10px 14px; border-bottom: 1px solid rgba(255, 255, 255, .08); border-radius: 14px 14px 0 0;
  background: linear-gradient(135deg, color-mix(in srgb, var(--k) 28%, transparent), transparent 70%); }
.pp-head .call { font-size: 19px; font-weight: 800; letter-spacing: .3px; }
.pp-head .kind { display: inline-block; margin-left: 8px; padding: 1px 8px; border-radius: 10px; font-size: 11px; font-weight: 700;
  background: var(--k); color: #0b1017; vertical-align: 3px; letter-spacing: .3px; }
/* il tipo si scrive come in tutto il progetto ("MMDVM-Rpt", non "MMDVM-RPT"; utente 05/12/2026) */
.pp-head .sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.pp-air { margin: 10px 14px 0; padding: 8px 10px; border-radius: 10px; background: rgba(255, 77, 79, .12); border: 1px solid rgba(255, 77, 79, .35); font-size: 13px; }
.pp-air b { color: #ffd7d7; }
.pp-body { padding: 8px 14px 12px; }
.pp-body dl { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; margin: 0; font-size: 13px; }
.pp-body dt { color: var(--muted); }
.pp-body dd { margin: 0; overflow-wrap: anywhere; }
.pp-desc { margin: 8px 0 0; font-size: 12.5px; color: #c4ccd6; line-height: 1.35; max-height: 90px; overflow: auto; white-space: pre-line; }
.pp-last { margin-top: 8px; font-size: 12px; color: var(--muted); }
.mono { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 12.5px; }

.maplibregl-ctrl-attrib { background: rgba(12, 17, 25, .7) !important; color: var(--muted); font-size: 11px; }
.maplibregl-ctrl-attrib a { color: #9fb7d8; }
.maplibregl-ctrl-group { background: var(--glass); border: 1px solid var(--glass-line); }
.maplibregl-ctrl-group button + button { border-top-color: var(--glass-line); }
.maplibregl-ctrl button .maplibregl-ctrl-icon { filter: invert(1); }

/* ---------- telefono (utente, 03/12/2026: "va completamente ripensata"; poi "elegantissima, caratteri piccoli, densità
   di informazione elevata, ci deve essere tutto") ----------
   Classe "m" sul body (map.js: schermo stretto, o basso come un telefono in orizzontale). Mappa a tutto schermo; in alto
   una barra sottile con titolo, diretta, contatori e ricerca; in basso un pannello che sale col dito (ridotto, metà,
   tutto): una riga con chi è in onda adesso, le schede In onda, Ultime, TG, Mappa e il dettaglio del device. */
.m-fabs, .m-sheet, .m-ico { display: none; }
body.m { --sheet-h: 84px; --hair: rgba(255, 255, 255, .07); --m-bg: rgba(11, 16, 23, .9); -webkit-text-size-adjust: 100%; }
body.m .live, body.m .side, body.m .tools { display: none; }
body.m .maplibregl-ctrl-group { display: none; }   /* niente + e -: si zooma con le dita */
body.m .maplibregl-ctrl-bottom-left, body.m .maplibregl-ctrl-bottom-right { bottom: calc(var(--sheet-h) + 2px); transition: bottom .28s cubic-bezier(.2, .8, .2, 1); }
body.m.sheet-full .maplibregl-ctrl-bottom-left, body.m.sheet-full .maplibregl-ctrl-bottom-right { display: none; }
body.m .maplibregl-ctrl-scale { margin: 0 0 4px 8px; font-size: 9px; padding: 0 4px; background: rgba(11, 16, 23, .55); color: #c4ccd6; border-color: rgba(255, 255, 255, .5); }
body.m .maplibregl-ctrl-attrib { font-size: 9px; }
body.m .maplibregl-ctrl-attrib.maplibregl-compact { min-height: 20px; }

/* barra in alto */
body.m .brand { top: max(6px, env(safe-area-inset-top)); left: 6px; right: 6px; width: auto; flex-wrap: nowrap; gap: 8px; padding: 5px 5px 5px 6px;
  border-radius: 14px; background: var(--m-bg); }
body.m .brand .logo { width: 30px; height: 30px; flex: none; }
body.m .brand-text { display: flex; flex-direction: column; min-width: 0; }
body.m .brand h1 { order: 1; display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; letter-spacing: .1px; overflow: hidden; }
body.m .brand h1 > span { color: #9fc0ff; }
body.m .brand-text > p, body.m .brand .sign { display: none; }
body.m .brand-row { order: 2; margin-top: 2px; justify-content: flex-start; }
body.m .conn { padding: 0; background: none; overflow: visible; }
body.m .conn .dot { width: 7px; height: 7px; }
body.m .conn #conn-text { display: none; }
body.m .brand .stats { position: static; width: auto; padding: 0; border: 0; background: none; box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none;
  display: flex; gap: 10px; cursor: default; }
body.m .brand .stat { flex-direction: row; align-items: baseline; gap: 3px; white-space: nowrap; }
/* quattro voci (05/12/2026): sul telefono vanno a capo intere, mai a metà */
body.m .brand .stats { flex-wrap: wrap; row-gap: 1px; column-gap: 9px; }
body.m .brand .stat b { font-size: 11.5px; font-weight: 700; }
body.m .brand .stat > span { font-size: 8.5px; letter-spacing: .5px; font-weight: 600; }
body.m .m-ico { display: flex; flex: none; align-items: center; justify-content: center; width: 34px; height: 34px; margin-left: auto; border-radius: 10px;
  border: 1px solid var(--hair); background: rgba(255, 255, 255, .05) center / 17px no-repeat; color: var(--text); font-size: 19px; cursor: pointer; padding: 0; }
body.m .m-ico.find { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23e8edf3' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='10.5' cy='10.5' r='6.5'/%3E%3Cpath d='M15.5 15.5 21 21'/%3E%3C/svg%3E"); }
body.m .m-ico.close { display: none; }
/* ricerca: la barra diventa il campo di ricerca */
body.m .brand .search { display: none; flex: 1; min-width: 0; }
body.m .brand.searching { z-index: 6; }
body.m .brand.searching .search { display: block; order: 1; }
body.m .brand.searching .brand-text, body.m .brand.searching #logo-reload, body.m .brand.searching .m-ico.find { display: none; }
body.m .brand.searching .m-ico.close { display: flex; order: 2; }
body.m .search input { font-size: 14px; padding: 7px 10px; border-radius: 9px; }
body.m .q-res { left: -1px; right: -42px; top: calc(100% + 11px); margin: 0; padding: 3px; max-height: 58vh; background: rgba(13, 19, 28, .97); box-shadow: var(--shadow); border-radius: 12px; }
body.m .q-res li { padding: 8px 8px; font-size: 12.5px; border-radius: 8px; }
body.m .q-res li + li { border-top: 1px solid var(--hair); border-radius: 0; }
body.m .q-res li small { font-size: 10.5px; max-width: 55%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* bottoni rotondi a destra, sopra il pannello */
body.m .m-fabs { display: flex; flex-direction: column; gap: 8px; position: absolute; z-index: 2; right: 8px; bottom: calc(var(--sheet-h) + 30px);
  transition: bottom .28s cubic-bezier(.2, .8, .2, 1), opacity .2s; }
body.m.sheet-full .m-fabs { opacity: 0; pointer-events: none; }
body.m .m-fabs .btn { width: 38px; height: 38px; padding: 0; border-radius: 12px; font-size: 0; background: var(--m-bg) center / 18px no-repeat; box-shadow: 0 4px 14px rgba(0, 0, 0, .4);
  border-color: var(--hair); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
body.m #btn-italy, body.m #btn-locate { font-size: 0; }
body.m #btn-locate { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23e8edf3' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='6.5'/%3E%3Ccircle cx='12' cy='12' r='2' fill='%23e8edf3'/%3E%3Cpath d='M12 2v3M12 19v3M2 12h3M19 12h3'/%3E%3C/svg%3E"); }
body.m #btn-italy { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23e8edf3' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 9V4h5M20 9V4h-5M4 15v5h5M20 15v5h-5'/%3E%3C/svg%3E"); }

/* pannello che sale dal basso */
body.m .m-sheet { display: flex; flex-direction: column; position: absolute; z-index: 4; left: 0; right: 0; bottom: 0; height: var(--sheet-h);
  padding-bottom: env(safe-area-inset-bottom); background: var(--m-bg); border-top: 1px solid rgba(255, 255, 255, .1); border-radius: 16px 16px 0 0;
  box-shadow: 0 -10px 34px rgba(0, 0, 0, .5); backdrop-filter: blur(18px) saturate(150%); -webkit-backdrop-filter: blur(18px) saturate(150%);
  transition: height .28s cubic-bezier(.2, .8, .2, 1); touch-action: none; font-size: 12px; }
body.m .m-sheet.drag { transition: none; }
.m-grip { flex: none; height: 13px; display: flex; justify-content: center; align-items: center; cursor: grab; }
.m-grip i { width: 34px; height: 4px; border-radius: 3px; background: rgba(255, 255, 255, .22); }
/* riga della diretta: chi è in onda adesso (o l'ultima trasmissione), sempre visibile anche col pannello ridotto */
.m-tick { flex: none; display: flex; align-items: center; gap: 7px; height: 26px; margin: 0 8px 5px; padding: 0 8px; border-radius: 8px;
  background: rgba(255, 255, 255, .035); font-size: 11.5px; white-space: nowrap; overflow: hidden; cursor: pointer; }
.m-tick.air { background: linear-gradient(90deg, rgba(255, 77, 79, .16), rgba(255, 77, 79, .04)); }
.m-tick .rec { flex: none; width: 7px; height: 7px; }
.m-tick.air .rec { background: var(--air); animation: rec 1.2s infinite; }
.m-tick b { font-weight: 800; letter-spacing: .2px; }
.m-tick .nm { color: var(--muted); overflow: hidden; text-overflow: ellipsis; min-width: 0; flex-shrink: 1; }
.m-tick .chip { flex: none; margin: 0; font-size: 10px; padding: 0 5px; line-height: 15px; }
.m-tick .lbl { color: var(--muted); font-size: 9.5px; text-transform: uppercase; letter-spacing: .6px; flex: none; }
.m-tick .tm { margin-left: auto; flex: none; font-weight: 800; font-variant-numeric: tabular-nums; color: #ffd7d7; }
.m-tick .ago { margin-left: auto; flex: none; color: var(--muted); font-size: 10.5px; }
.m-tick .more { flex: none; font-size: 9.5px; font-weight: 800; padding: 0 5px; border-radius: 7px; background: rgba(255, 255, 255, .1); line-height: 15px; }
.m-tabs { flex: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; margin: 0 8px 6px; padding: 2px; border-radius: 10px; background: rgba(255, 255, 255, .04); }
.m-tabs button { all: unset; display: flex; align-items: center; justify-content: center; gap: 5px; height: 28px; border-radius: 8px; font-size: 11.5px; font-weight: 650;
  letter-spacing: .2px; color: var(--muted); cursor: pointer; -webkit-tap-highlight-color: transparent; transition: background .15s, color .15s; }
.m-tabs button[aria-selected="true"] { background: rgba(255, 255, 255, .11); color: var(--text); box-shadow: 0 1px 4px rgba(0, 0, 0, .3); }
.m-tabs .rec { width: 6px; height: 6px; }
.m-sheet.on-air .rec { background: var(--air); animation: rec 1.2s infinite; }
.m-cnt { font-size: 9.5px; font-weight: 800; min-width: 15px; padding: 0 4px; border-radius: 8px; background: var(--air); color: #fff; text-align: center; line-height: 15px; font-variant-numeric: tabular-nums; }
.m-cnt.tg { background: var(--accent); }
.m-cnt:empty { display: none; }
.m-body { flex: 1; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: 0 10px 12px; touch-action: pan-y; border-top: 1px solid var(--hair); }
.m-sheet.peek .m-body { visibility: hidden; }
.m-pane { display: none; }
.m-pane.on { display: block; }
/* titoletti: maiuscoletto piccolo con un filo che corre fino al bordo */
.m-pane h3, .m-pane #live-h { display: flex; align-items: center; gap: 7px; margin: 10px 0 5px; font-size: 9.5px; font-weight: 750; text-transform: uppercase;
  letter-spacing: 1px; color: var(--muted); }
.m-pane h3::after, .m-pane #live-h::after { content: ""; flex: 1; height: 1px; background: var(--hair); }
.m-pane #live-h .rec { width: 6px; height: 6px; }
.m-pane .h-cnt { font-size: 9.5px; line-height: 15px; min-width: 16px; padding: 0 4px; }
/* contenuti spostati dalle finestre del computer: senza vetro né posizione propria */
.m-pane .glass { position: static; width: auto; background: none; border: 0; box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; padding: 0; max-height: none; }
.m-pane .empty { font-size: 11.5px; padding: 6px 2px; }

/* In onda: gruppi per TG, righe fitte */
.m-pane .live-list { gap: 0; }
.m-pane .tg-group { background: none; border-radius: 0; padding: 5px 0 4px; border-bottom: 1px solid var(--hair); }
.m-pane .tg-group.sel { box-shadow: none; background: rgba(76, 141, 255, .08); }
.m-pane .tg-group.ff { background: rgba(120, 110, 255, .20); box-shadow: none; }
.m-pane .tg-group.ff.sel { background: rgba(120, 110, 255, .28); }
.m-pane .tg-group.priv { background: rgba(255, 110, 140, .17); box-shadow: none; }
.m-pane .tg-head { padding: 1px 4px 2px 7px; border-left-width: 3px; gap: 6px; }
.m-pane .tg-head .chip { font-size: 10.5px; padding: 0 5px; line-height: 16px; margin: 0; }
.m-pane .tg-head .tg-name { font-size: 11.5px; font-weight: 600; }
.m-pane .tg-cnt b { font-size: 9.5px; padding: 0 5px; line-height: 13px; }
.m-pane .tg-group .live-item { padding: 2px 4px 2px 10px; margin: 0; gap: 0 8px; }
.m-pane .live-item .who { font-size: 12.5px; font-weight: 750; }
.m-pane .live-item .who small { font-size: 10.5px; }
.m-pane .live-item .tg { font-size: 10.5px; }
.m-pane .tg-group .live-item .time { font-size: 12.5px; }
/* una riga per trasmissione: nominativo e nome, "via" il device, tempo */
.m-pane .tg-group .live-item { grid-template-columns: auto minmax(0, 1fr) auto; align-items: baseline; }
.m-pane .tg-group .live-item .who { grid-column: 1; grid-row: 1; white-space: nowrap; }
.m-pane .tg-group .live-item .tg { grid-column: 2; grid-row: 1; }
.m-pane .tg-group .live-item .time { grid-column: 3; grid-row: 1; }

/* Ultime: tre colonne, due righe per trasmissione */
.m-pane .log-list { overflow: visible; padding: 0; }
.m-pane .log-list li { grid-template-columns: 50px 1fr auto; gap: 0 8px; padding: 5px 2px; font-size: 11.5px; border-top: 0; border-bottom: 1px solid var(--hair); border-radius: 0; }
.m-pane .log-list .t { font-size: 10.5px; padding-top: 1px; }
.m-pane .log-list .w b { font-size: 12.5px; }
.m-pane .log-list .w b a { color: var(--text); }
.m-pane .log-list .w small { font-size: 10.5px; }
.m-pane .log-list .d { font-size: 11px; }
.m-pane .log-list .tgline { font-size: 10.5px; }
.m-pane .log-list .chip { font-size: 9.5px; padding: 0 4px; line-height: 14px; }

/* TG */
.m-pane .tg-pane { padding-top: 8px; }
.m-pane .tg-tools { gap: 5px; }
.m-pane .tg-tools input { font-size: 13px; padding: 6px 9px; border-radius: 8px; }
.m-pane .seg { border-radius: 8px; }
.m-pane .seg button { padding: 6px 9px; font-size: 11px; }
.m-pane .legend { font-size: 10.5px; margin: 7px 1px 2px; gap: 12px; }
.m-pane .dot { width: 8px; height: 8px; border-width: 2px; }
.m-pane .tg-body { overflow: visible; padding: 0; }
.m-pane .tg-title { font-size: 12.5px; margin: 6px 0 4px; }
.m-pane .tg-title .chip { font-size: 11px; }
.m-pane .tg-air { font-size: 11px; padding: 4px 7px; margin-bottom: 3px; }
.m-pane .tg-sort { font-size: 10px; margin: 6px 0 0; }
.m-pane .tg-sort button { padding: 1px 7px; font-size: 10px; }
.m-pane .tg-body h3 { margin: 9px 0 3px; font-size: 9.5px; }
.m-pane .tg-table { font-size: 11px; }
.m-pane .tg-table td { padding: 4px 3px; border-top: 0; border-bottom: 1px solid var(--hair); }
.m-pane .tg-table td.p { max-width: 104px; font-size: 10.5px; }
.m-pane .tg-table .mono { font-size: 10.5px; }
.m-pane .tg-table .ts { font-size: 8.5px; line-height: 12px; padding: 0 3px; }

.m-quick { margin-top: 2px; gap: 5px; }
.m-quick .tgchip { font-size: 11.5px; padding: 2px 8px; }
.m-quick .tgchip .nm { font-style: normal; font-weight: 500; color: var(--text); opacity: .8; }
/* Mappa: layer in due colonne, carte, chi guarda, informazioni */
.m-pane .layers { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; }
.m-pane .layer { padding: 6px 8px; border-radius: 9px; background: rgba(255, 255, 255, .04); border: 1px solid var(--hair); font-size: 11.5px; column-gap: 7px; }
.m-pane .layer .cn { font-size: 12.5px; font-weight: 700; }
.m-pane .layer .om { font-size: 9.5px; }
.m-pane .layer .sw { width: 11px; height: 11px; }
.m-pane .layer .sw.hs, .m-pane .layer .sw.hsd { width: 15px; height: 15px; font-size: 9px; }
.m-pane .bases { gap: 6px; }
.m-pane .base .thumb { border-radius: 8px; }
.m-pane .base span { font-size: 9.5px; }
.m-hint { margin: 6px 2px 0; font-size: 10.5px; color: var(--muted); line-height: 1.35; }
.m-kpi { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--hair); border-radius: 10px; overflow: hidden; }
.m-kpi > div { display: flex; flex-direction: column; align-items: center; padding: 6px 2px 5px; gap: 1px; }
.m-kpi > div + div { border-left: 1px solid var(--hair); }
.m-kpi b { font-size: 15px; font-weight: 750; font-variant-numeric: tabular-nums; color: #7fb2ff; line-height: 1.15; }
.m-kpi span { font-size: 8.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; text-align: center; }
.m-kpi small { font-size: 9px; color: var(--muted); font-variant-numeric: tabular-nums; }
.m-colo { display: flex; align-items: center; gap: 9px; font-size: 11px; color: var(--muted); }
.m-colo .logo { width: 30px; height: 30px; border-radius: 22%; flex: none; }
.m-colo > div { display: flex; flex-direction: column; gap: 1px; }
.m-colo b { color: var(--text); }
#m-more { display: flex; align-items: center; gap: 10px; margin-top: 9px; }
#m-more .dev-badge { flex: none; font-size: 8.5px; }
#m-more .sign { display: flex; flex: 1; margin: 0; font-size: 10px; }
#m-more .btn { flex: none; width: 44px; padding: 4px 0; font-size: 11px; border-radius: 8px; }

/* dettaglio del device: il contenuto del popup, nel pannello */
.m-back { all: unset; cursor: pointer; display: inline-flex; align-items: center; gap: 3px; padding: 7px 8px 5px 1px; font-size: 12px; font-weight: 600; color: #9fc0ff; }
#m-dev .pp-head { border-radius: 10px; border: 1px solid var(--hair); padding: 8px 10px; }
#m-dev .pp-head .call { font-size: 17px; }
#m-dev .pp-head .kind { font-size: 9px; padding: 1px 6px; vertical-align: 2px; margin-left: 6px; }
#m-dev .pp-head .sub { font-size: 11px; }
#m-dev .pp-air { margin: 6px 0 0; padding: 5px 8px; font-size: 11.5px; border-radius: 8px; }
#m-dev .pp-body { padding: 6px 1px 4px; }
#m-dev .pp-body dl { font-size: 11.5px; gap: 0; grid-template-columns: auto 1fr; }
#m-dev .pp-body dt, #m-dev .pp-body dd { padding: 3px 0; border-bottom: 1px solid var(--hair); }
#m-dev .pp-body dt { padding-right: 12px; font-size: 10.5px; }
#m-dev .pp-desc { max-height: none; font-size: 11px; margin-top: 6px; }
#m-dev .pp-tgs { gap: 4px; margin-top: 7px; }
#m-dev .pp-tgs .lbl { font-size: 9.5px; letter-spacing: .8px; }
#m-dev .tgchip { font-size: 11px; padding: 1px 6px; }
#m-dev .tgchip .ts { font-size: 8.5px; line-height: 12px; }
#m-dev .pp-last { font-size: 10.5px; }
.m-acts { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: 5px; margin-top: 8px; }
.m-acts a, .m-acts button { all: unset; cursor: pointer; text-align: center; padding: 6px 0; border-radius: 8px; border: 1px solid var(--hair); background: rgba(255, 255, 255, .05);
  font-size: 11px; font-weight: 650; color: #c9d6ea; }

/* fumetti "in onda" più piccoli sulla mappa */
body.m .air-card { min-width: 0; padding: 4px 7px 4px 8px; border-radius: 8px; border-left-width: 3px; }
body.m .air-card .call { font-size: 11.5px; }
body.m .air-card .name, body.m .air-card .l3 { display: none; }
body.m .air-card .timer { font-size: 11.5px; padding-left: 6px; }
body.m .air-card .l2 { font-size: 10px; max-width: 140px; overflow: hidden; text-overflow: ellipsis; }
body.m .air-card .chip { font-size: 9.5px; padding: 0 4px; }

/* ordinamento delle tabelle dei TG */
.tg-sort { display: flex; align-items: center; gap: 6px; margin: 8px 0 2px; font-size: 11.5px; color: var(--muted); }
.tg-sort button { font: inherit; color: #c4ccd6; background: rgba(255, 255, 255, .06); border: 1px solid var(--glass-line); border-radius: 7px; padding: 2px 9px; cursor: pointer; }
.tg-sort button:hover { background: rgba(255, 255, 255, .12); }
.tg-sort button.on { background: #3b82f6; border-color: #3b82f6; color: #fff; }

/* ® dei TG di ripetitore: rossa e in grassetto, più visibile dell'emoji (utente, 04/12/2026) */
.rpt-r { color: #ff3b3b; font-weight: 800; font-size: 1.1em; line-height: 1; font-variant-emoji: text; }

/* destinatario delle chiamate private (04/12/2026) */
.to { white-space: nowrap; }
.to a, .to b { color: #ffb3c1; font-weight: 700; }
.to small { font-weight: 400; color: var(--muted); }
.live-item .who .to small { margin-left: 0; }

/* aiuto in fondo alla tabella dei tipi: si accendono e spengono (04/12/2026) */
.layers-hint { margin: 4px 8px 2px; font-size: 11px; color: var(--muted); line-height: 1.35; }
.m-pane .layers-hint { grid-column: 1 / -1; margin: 2px 2px 0; font-size: 10.5px; }

/* Famiglie / Dettaglio (utente, 05/12/2026): due bottoni a matrice, colonne uguali su tutta la larghezza */
.mode-seg { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; margin: 0 0 4px; }
.mode-seg button { font: inherit; font-size: 12px; font-weight: 600; padding: 5px 6px; border-radius: 8px; cursor: pointer;
  color: var(--muted); background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .1); }
.mode-seg button[aria-pressed="true"] { color: #e8edf3; background: rgba(127, 178, 255, .2); border-color: rgba(127, 178, 255, .55); }
/* caselline dei tipi: l'icona vera (ripetitori e HotSpot, disegnata dalla mappa) o il pallino del colore del tipo */
.sw.ico, .layer .sw.ico { width: 16px; height: 16px; border: 0; border-radius: 0; background-color: transparent;
  background-position: center; background-size: contain; background-repeat: no-repeat; }
.sw.dot { background: var(--k); }
.sw.sm { width: 11px; height: 11px; display: inline-block; }
.sw.dot.sm { border-radius: 50%; }
.opname { color: var(--name); font-weight: 600; }

/* elenco dei device di un tipo (utente, 05/12/2026): tasto destro sulla riga della legenda; stesso vetro delle altre finestre */
.devlist { top: 90px; left: max(340px, calc(50% - 500px)); width: min(1000px, calc(100vw - 360px)); max-height: calc(100vh - 130px);
  padding: 10px 10px 8px 12px; display: flex; flex-direction: column; z-index: 4; }
.devlist[hidden] { display: none; }
.devlist { min-width: 420px; min-height: 220px; max-width: calc(100vw - 20px); }
.dl-grip { position: absolute; right: 0; bottom: 0; width: 22px; height: 22px; cursor: nwse-resize; touch-action: none; z-index: 2; border-bottom-right-radius: var(--radius); }
.dl-grip::after { content: ""; position: absolute; right: 5px; bottom: 5px; width: 10px; height: 10px;
  border-right: 2px solid rgba(255,255,255,.45); border-bottom: 2px solid rgba(255,255,255,.45); border-bottom-right-radius: 3px; }
.dl-grip:hover::after, .devlist.resizing .dl-grip::after { border-color: var(--accent); }
.devlist.resizing { outline: 1px solid var(--accent); user-select: none; }
.dl { display: flex; flex-direction: column; min-height: 0; flex: 1; }
.dl-head { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.dl-head h2 { margin: 0; font-size: 13px; text-transform: uppercase; letter-spacing: .8px; color: var(--text); }
.dl-head .sw { flex: none; }
.dl-x { all: unset; cursor: pointer; margin-left: auto; width: 26px; height: 26px; border-radius: 8px; text-align: center; line-height: 25px; font-size: 18px; color: var(--muted); }
.dl-x:hover { background: rgba(255, 255, 255, .08); color: var(--text); }
.dl-tools { display: grid; grid-template-columns: 1fr auto; gap: 8px; margin-bottom: 8px; }
.dl-q { padding: 7px 10px; border-radius: 9px; border: 1px solid var(--glass-line); background: rgba(0, 0, 0, .25); color: var(--text); font-size: 13.5px; outline: none; min-width: 0; }
.dl-tools .seg button[aria-pressed="true"] { background: rgba(255, 255, 255, .1); color: var(--text); }
.dl-scroll { overflow: auto; min-height: 0; flex: 1; border-top: 1px solid var(--glass-line); }
.dl-grid { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.dl-grid th { position: sticky; top: 0; z-index: 1; background: rgba(14, 20, 29, .96); text-align: left; padding: 6px 8px; font-size: 10.5px; font-weight: 650;
  text-transform: uppercase; letter-spacing: .6px; color: var(--muted); cursor: pointer; white-space: nowrap; user-select: none; }
.dl-grid th:hover { color: var(--text); }
.dl-ar { font-style: normal; font-size: 9px; margin-left: 4px; color: var(--accent); }
.dl-grid td { padding: 5px 8px; border-top: 1px solid rgba(255, 255, 255, .05); white-space: nowrap; max-width: 170px; overflow: hidden; text-overflow: ellipsis; }
.dl-grid tbody tr { cursor: pointer; }
.dl-grid tbody tr:hover { background: rgba(255, 255, 255, .06); }
.dl-grid .call { font-weight: 700; }
.dl-grid .nocall { color: var(--muted); }
.dl-grid .mono { font-variant-numeric: tabular-nums; color: var(--muted); }
.dl-grid .c-type, .dl-grid .c-hw, .dl-grid .c-city { color: var(--muted); }
.dl-grid .m-city { display: none; }
.dl-grid .c-state { color: var(--muted); }
.dl-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 6px; vertical-align: 1px; background: #3ddc84; box-shadow: 0 0 6px #3ddc84; }
.dl-grid tr.away .dl-dot { background: #ffb020; box-shadow: none; }
.dl-grid tr.off .dl-dot { background: #5b6675; box-shadow: none; }
.dl-grid tr.off .call { color: var(--muted); }
.dl .empty { padding: 10px 8px; }
.dl-help { margin: 6px 2px 0; font-size: 11px; color: var(--muted); }
/* telefono: pannello a tutta altezza, solo nominativo (con la località sotto), tipo e stato */
body.m .dl-head h2 { font-size: 12px; }
body.m .dl-tools { grid-template-columns: 1fr; }
body.m .dl-grid .c-id, body.m .dl-grid .c-city, body.m .dl-grid .c-master, body.m .dl-grid .c-tx, body.m .dl-grid .c-rx, body.m .dl-grid .c-shift, body.m .dl-grid .c-hw { display: none; }
body.m .dl-grid .m-city { display: block; font-size: 10.5px; color: var(--muted); font-weight: 400; }
body.m .dl-grid td { max-width: 150px; padding: 6px 6px; }
body.m .dl-scroll { overflow: visible; }
body.m .dl-help { display: none; }
.layer { -webkit-touch-callout: none; }
