/* ============================================================
   Master League Manager Pro — Design System "Notturna"
   Ispirato al design Barlow / dark notturno
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Barlow:wght@400;500;600;700&family=Barlow+Condensed:wght@600;700;800&display=swap');

:root {
  --c-bg:        #05080B;
  --c-surface:   #0B0F14;
  --c-surface2:  #131A22;
  --c-surface3:  #1C2632;
  --c-border:    #1A232E;
  --c-border2:   #1F2A36;
  --c-border3:   #2A3644;
  --c-primary:   #C6F432;
  --c-primary-d: #B0DC20;
  --c-primary-text: #0B0F14;
  --c-accent:    #C6F432;
  --c-success:   #C6F432;
  --c-warning:   #F2B84B;
  --c-danger:    #FF5C5C;
  --c-text:      #E8EEF4;
  --c-text2:     #A9B6C3;
  --c-muted:     #8A99A8;
  --c-muted2:    #6E7D8C;
  --c-gold:      #F2B84B;
  --radius:      16px;
  --radius-sm:   10px;
  --header-h:    64px;
  --nav-h:       72px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 15px; scroll-behavior: smooth; }

/* Nasconde scrollbar ma mantiene funzionalità */
* { scrollbar-width: thin; scrollbar-color: var(--c-border3) transparent; }
*::-webkit-scrollbar { width: 4px; height: 4px; }
*::-webkit-scrollbar-thumb { background: var(--c-border3); border-radius: 4px; }

body {
  font-family: 'Barlow', system-ui, -apple-system, sans-serif;
  background: var(--c-bg);
  color: var(--c-text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  padding-bottom: var(--nav-h); /* spazio per bottom nav su mobile */
}

a { color: var(--c-primary); }
a:hover { color: var(--c-primary-d); }

/* ── Input focus ── */
input:focus, select:focus, textarea:focus {
  outline: 2px solid var(--c-primary);
  outline-offset: -2px;
}
input[type=number] { -moz-appearance: textfield; }
input::-webkit-outer-spin-button, input::-webkit-inner-spin-button { -webkit-appearance: none; }

/* ── Header (top bar) ── */
.site-header {
  position: sticky; top: 0; z-index: 200;
  background: var(--c-surface);
  border-bottom: 1px solid var(--c-border);
  height: var(--header-h);
}
.header-inner {
  max-width: 1400px; margin: 0 auto;
  display: flex; align-items: center; gap: 1rem;
  padding: 0 1.25rem; height: 100%;
}

/* Logo */
.logo { display: flex; align-items: center; gap: .6rem; text-decoration: none; color: var(--c-text); flex-shrink: 0; }
.logo-icon {
  width: 34px; height: 34px; border-radius: 10px;
  background: var(--c-primary); color: var(--c-primary-text);
  display: flex; align-items: center; justify-content: center;
  font: 800 16px 'Barlow Condensed'; letter-spacing: -.5px;
}
.logo-text { font: 700 15px 'Barlow'; line-height: 1.2; }
.logo-text em { display: block; color: var(--c-muted); font-style: normal; font-weight: 500; font-size: 11px; letter-spacing: .04em; }

/* Nav desktop (horizontal links) */
.main-nav { display: flex; gap: .1rem; align-items: center; margin-left: auto; flex-wrap: wrap; }
.main-nav a {
  color: var(--c-muted); text-decoration: none; padding: .4rem .65rem;
  border-radius: 8px; font-size: .82rem; font-weight: 600;
  transition: color .2s, background .2s; white-space: nowrap; position: relative;
}
.main-nav a:hover { color: var(--c-text); background: var(--c-surface2); }
.main-nav a.active { color: var(--c-primary); background: rgba(198,244,50,.1); }

.nav-toggle { display: none; background: none; border: 1px solid var(--c-border3); color: var(--c-text); padding: .3rem .6rem; border-radius: 8px; cursor: pointer; font-size: 1.1rem; }

/* Badge non letti */
.nav-badge {
  position: absolute; top: 0; right: 0;
  background: var(--c-danger); color: #fff; border-radius: 99px;
  font-size: .6rem; font-weight: 700; padding: .05rem .3rem; line-height: 1.5;
  min-width: 1rem; text-align: center;
}

/* User info header */
.user-info {
  display: flex; align-items: center; gap: .5rem;
  margin-left: .75rem; flex-shrink: 0;
  border-left: 1px solid var(--c-border); padding-left: .75rem;
}
.user-name { font-size: .8rem; color: var(--c-muted); white-space: nowrap; display: flex; align-items: center; gap: .4rem; }
.user-role-badge {
  font-size: .68rem; font-weight: 700; padding: .15rem .45rem;
  border-radius: 5px; text-transform: uppercase; letter-spacing: .08em;
}
.badge-admin   { background: var(--c-danger); color: #fff; }
.badge-visitor { background: var(--c-surface2); color: var(--c-muted); border: 1px solid var(--c-border3); }
.btn-logout {
  background: none; border: 1px solid var(--c-border3); color: var(--c-muted);
  padding: .25rem .5rem; border-radius: 8px; cursor: pointer;
  text-decoration: none; font-size: 1rem; transition: color .2s, border-color .2s; line-height: 1;
}
.btn-logout:hover { color: var(--c-danger); border-color: var(--c-danger); }

/* ── Main content ── */
.site-main { flex: 1; max-width: 1400px; margin: 0 auto; width: 100%; padding: 1.5rem 1.25rem 2rem; }

/* ── Footer ── */
.site-footer {
  background: var(--c-surface); border-top: 1px solid var(--c-border);
  padding: 1rem 1.25rem; text-align: center;
}
.footer-inner p { color: var(--c-muted2); font-size: .78rem; }

/* ── Page Header ── */
.page-header { margin-bottom: 1.5rem; }
.page-header h1 {
  font: 800 2.4rem/1 'Barlow Condensed';
  text-transform: uppercase; letter-spacing: -.01em;
}
.page-header p { color: var(--c-muted); margin-top: .35rem; font-size: .9rem; font-weight: 500; }

/* ── Cards ── */
.card {
  background: var(--c-surface2);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: 1.25rem;
}
.card-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1rem; gap: 1rem; }
.card-title { font: 700 1rem 'Barlow'; display: flex; align-items: center; gap: .5rem; }

/* ── Stats Grid ── */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: .75rem; margin-bottom: 1.5rem; }
.stat-card {
  background: var(--c-surface2);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-sm);
  padding: .9rem 1rem;
  display: flex; flex-direction: column; gap: 3px;
}
.stat-card.success { border-color: rgba(198,244,50,.25); background: rgba(198,244,50,.05); }
.stat-card.warning { border-color: rgba(242,184,75,.25); background: rgba(242,184,75,.05); }
.stat-card.danger  { border-color: rgba(255,92,92,.25);  background: rgba(255,92,92,.05); }
.stat-card.gold    { border-color: rgba(242,184,75,.35); background: rgba(242,184,75,.08); }
.stat-label { font: 600 .72rem 'Barlow'; color: var(--c-muted); text-transform: uppercase; letter-spacing: .08em; }
.stat-value { font: 800 1.7rem/1 'Barlow Condensed'; margin-top: .15rem; }
.stat-sub   { font: 500 .72rem 'Barlow'; color: var(--c-muted); }

/* ── Tables ── */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .85rem; }
thead th {
  background: var(--c-surface);
  color: var(--c-muted2); font: 600 .68rem 'Barlow';
  text-transform: uppercase; letter-spacing: .08em;
  padding: .55rem .8rem; text-align: left;
  border-bottom: 1px solid var(--c-border); white-space: nowrap;
}
tbody td { padding: .65rem .8rem; border-bottom: 1px solid var(--c-border2); vertical-align: middle; }
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover { background: rgba(255,255,255,.025); }

/* ── Badges ── */
.badge {
  display: inline-flex; align-items: center; gap: .25rem;
  padding: .2rem .55rem; border-radius: 6px; font: 700 .72rem 'Barlow';
}
.badge-blue   { background: rgba(99,179,237,.15);  color: #63b3ed; border: 1px solid rgba(99,179,237,.2); }
.badge-green  { background: rgba(198,244,50,.15);  color: #C6F432; border: 1px solid rgba(198,244,50,.2); }
.badge-yellow { background: rgba(242,184,75,.15);  color: #F2B84B; border: 1px solid rgba(242,184,75,.2); }
.badge-red    { background: rgba(255,92,92,.15);   color: #FF5C5C; border: 1px solid rgba(255,92,92,.2); }
.badge-gray   { background: rgba(138,153,168,.1);  color: var(--c-muted); border: 1px solid var(--c-border3); }
.badge-gold   { background: rgba(242,184,75,.15);  color: #F2B84B; border: 1px solid rgba(242,184,75,.2); }
.badge-orange { background: rgba(251,146,60,.15);  color: #fb923c; border: 1px solid rgba(251,146,60,.2); }

/* Ruoli */
.ruolo-P { background: rgba(99,179,237,.12); color: #63b3ed; border: 1px solid rgba(99,179,237,.2); }
.ruolo-D { background: rgba(198,244,50,.12); color: #C6F432; border: 1px solid rgba(198,244,50,.2); }
.ruolo-C { background: rgba(242,184,75,.12); color: #F2B84B; border: 1px solid rgba(242,184,75,.2); }
.ruolo-A { background: rgba(255,92,92,.12);  color: #FF5C5C; border: 1px solid rgba(255,92,92,.2); }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .5rem 1.1rem; border-radius: var(--radius-sm); font: 700 .88rem 'Barlow';
  border: none; cursor: pointer; transition: all .15s; text-decoration: none;
  white-space: nowrap; line-height: 1.4;
}
.btn-primary {
  background: var(--c-primary); color: var(--c-primary-text);
}
.btn-primary:hover { background: var(--c-primary-d); color: var(--c-primary-text); filter: brightness(1.05); }
.btn-success { background: var(--c-primary); color: var(--c-primary-text); }
.btn-success:hover { filter: brightness(1.08); }
.btn-warning { background: var(--c-warning); color: #0B0F14; }
.btn-warning:hover { filter: brightness(1.08); }
.btn-danger  { background: var(--c-danger); color: #fff; }
.btn-danger:hover  { filter: brightness(1.1); }
.btn-ghost {
  background: transparent;
  border: 1px solid var(--c-border3);
  color: var(--c-text2);
}
.btn-ghost:hover { background: var(--c-surface2); color: var(--c-text); border-color: var(--c-border3); }
.btn-outline-primary {
  background: transparent; border: 1px solid var(--c-primary); color: var(--c-primary);
}
.btn-outline-primary:hover { background: rgba(198,244,50,.1); }
.btn-sm  { padding: .3rem .7rem; font-size: .78rem; border-radius: 8px; }
.btn-xs  { padding: .18rem .45rem; font-size: .7rem; border-radius: 6px; }

/* ── Forms ── */
.form-grid   { display: grid; gap: 1rem; }
.form-grid-2 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.form-grid-3 { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.form-group  { display: flex; flex-direction: column; gap: .35rem; }
.form-group label { font: 600 .78rem 'Barlow'; color: var(--c-muted); text-transform: uppercase; letter-spacing: .06em; }
.form-group input,
.form-group select,
.form-group textarea {
  background: var(--c-surface); border: 1px solid var(--c-border3);
  color: var(--c-text); border-radius: 10px; padding: .6rem .9rem;
  font: 500 .9rem 'Barlow'; transition: border-color .2s; font-family: inherit;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  border-color: var(--c-primary);
}
.form-group select option { background: var(--c-surface2); }

/* ── Modal ── */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.75);
  display: none; align-items: center; justify-content: center;
  z-index: 999; padding: 1rem;
}
.modal-overlay.open { display: flex; }
.modal {
  background: var(--c-surface2); border: 1px solid var(--c-border);
  border-radius: var(--radius); padding: 1.5rem; width: 100%;
  max-width: 600px; max-height: 90vh; overflow-y: auto;
  box-shadow: 0 24px 64px rgba(0,0,0,.7);
}
.modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.25rem; }
.modal-header h2, .modal-header h3 { font: 700 1.1rem 'Barlow'; }
.modal-close { background: none; border: none; color: var(--c-muted); cursor: pointer; font-size: 1.3rem; transition: color .2s; }
.modal-close:hover { color: var(--c-text); }
.modal-footer { display: flex; gap: .75rem; justify-content: flex-end; margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid var(--c-border); }
.modal-body { display: flex; flex-direction: column; gap: 1rem; }

/* ── Tabs ── */
.tabs-container { }
.tabs {
  display: flex; gap: 4px; margin-bottom: 1.25rem;
  background: var(--c-surface); border-radius: 12px; padding: 4px;
  overflow-x: auto; flex-wrap: nowrap;
}
.tab-btn {
  padding: .55rem 1rem; font: 700 .82rem 'Barlow'; white-space: nowrap;
  color: var(--c-muted); background: transparent; border: none; cursor: pointer;
  border-radius: 9px; transition: all .2s; flex-shrink: 0;
}
.tab-btn.active { color: var(--c-primary-text); background: var(--c-primary); }
.tab-btn:hover:not(.active) { color: var(--c-text); background: var(--c-surface2); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ── Alerts ── */
.alert { padding: .75rem 1rem; border-radius: 10px; font: 500 .85rem 'Barlow'; margin-bottom: 1rem; }
.alert-success { background: rgba(198,244,50,.1); border: 1px solid rgba(198,244,50,.25); color: #C6F432; }
.alert-warning { background: rgba(242,184,75,.1); border: 1px solid rgba(242,184,75,.25); color: #F2B84B; }
.alert-danger  { background: rgba(255,92,92,.1);  border: 1px solid rgba(255,92,92,.25);  color: #FF5C5C; }
.alert-info    { background: rgba(99,179,237,.1); border: 1px solid rgba(99,179,237,.25); color: #63b3ed; }
.alert-flash   { position: fixed; top: calc(var(--header-h) + .75rem); right: 1rem; z-index: 9999; min-width: 260px; max-width: 400px; box-shadow: 0 8px 24px rgba(0,0,0,.4); }

/* ── Progress ── */
.progress-bar  { background: var(--c-surface); border-radius: 999px; height: 6px; overflow: hidden; }
.progress-fill { height: 100%; border-radius: 999px; background: var(--c-primary); transition: width .4s; }
.progress-fill.success { background: var(--c-success); }
.progress-fill.warning { background: var(--c-warning); }
.progress-fill.danger  { background: var(--c-danger); }

/* ── Team dot ── */
.team-dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex-shrink: 0; }

/* Team logo piccolo */
.team-logo-sm {
  width: 28px; height: 28px; border-radius: 50%;
  object-fit: cover; background: var(--c-surface3);
  border: 1px solid var(--c-border3); flex-shrink: 0;
}

/* ── Classifica pos badge ── */
.pos-badge {
  width: 26px; height: 26px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font: 800 .8rem 'Barlow Condensed'; background: var(--c-surface);
  color: var(--c-muted);
}
.pos-1 { background: #F2B84B; color: #0B0F14; }
.pos-2 { background: #94a3b8; color: #0B0F14; }
.pos-3 { background: #b45309; color: #fff; }

/* Form badges risultato (V/P/S) */
.form-badge {
  width: 18px; height: 18px; border-radius: 4px;
  display: inline-flex; align-items: center; justify-content: center;
  font: 700 .65rem 'Barlow'; color: #0B0F14;
}
.form-v { background: var(--c-primary); }
.form-p { background: var(--c-muted); }
.form-s { background: var(--c-danger); }

/* ── Dashboard grid ── */
.dashboard-grid { display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; }
.dashboard-grid .dash-full { grid-column: 1 / -1; }

/* ── Sponsor card ── */
.sponsor-card { border-radius: var(--radius); padding: 1rem; border: 2px solid; }
.sponsor-top    { border-color: var(--c-gold); }
.sponsor-medio  { border-color: var(--c-primary); }
.sponsor-piccolo{ border-color: var(--c-border3); }

/* ── Stadium ── */
.stadium-levels { display: flex; gap: 1rem; flex-wrap: wrap; }
.level-box { flex: 1; min-width: 140px; border-radius: var(--radius); padding: 1rem; border: 2px solid var(--c-border3); text-align: center; }
.level-box.reached { border-color: var(--c-success); background: rgba(198,244,50,.06); }
.level-box.current { border-color: var(--c-warning); background: rgba(242,184,75,.06); }

/* ── Section title (stile Barlow Condensed uppercase) ── */
.section-title {
  font: 800 1.3rem 'Barlow Condensed'; text-transform: uppercase; letter-spacing: .02em; margin-bottom: .75rem;
}

/* ── Chip / pill filtri ── */
.chip {
  display: inline-flex; align-items: center; height: 36px; padding: 0 14px;
  border-radius: 18px; font: 700 .82rem 'Barlow'; cursor: pointer;
  border: 1px solid var(--c-border3); color: var(--c-muted); background: transparent;
  transition: all .15s; white-space: nowrap;
}
.chip.active, .chip:hover { background: var(--c-primary); color: var(--c-primary-text); border-color: var(--c-primary); }

/* ── Utils ── */
.text-primary  { color: var(--c-primary); }
.text-success  { color: var(--c-success); }
.text-danger   { color: var(--c-danger); }
.text-warning  { color: var(--c-warning); }
.text-muted    { color: var(--c-muted); }
.text-muted2   { color: var(--c-muted2); }
.text-gold     { color: var(--c-gold); }
.text-right    { text-align: right; }
.text-center   { text-align: center; }
.flex          { display: flex; }
.flex-wrap     { flex-wrap: wrap; }
.items-center  { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-1  { gap: .5rem; }
.gap-2  { gap: 1rem; }
.mt-1   { margin-top: .5rem; }
.mt-2   { margin-top: 1rem; }
.mt-3   { margin-top: 1.5rem; }
.mb-1   { margin-bottom: .5rem; }
.mb-2   { margin-bottom: 1rem; }
.mb-3   { margin-bottom: 1.5rem; }
.fw-bold { font-weight: 700; }
.fw-800  { font: 800 inherit 'Barlow Condensed'; }
.fs-sm   { font-size: .8rem; }
.fs-xs   { font-size: .72rem; }
.w-100   { width: 100%; }
.d-none  { display: none; }
.opacity-50 { opacity: .5; }

/* Numeri grandi stile Barlow Condensed */
.num-big { font: 800 2rem/1 'Barlow Condensed'; }
.num-lg  { font: 800 1.5rem/1 'Barlow Condensed'; }
.num-md  { font: 800 1.2rem/1 'Barlow Condensed'; }

/* ── Search ── */
.search-bar { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; margin-bottom: 1rem; }
.search-bar input {
  flex: 1; min-width: 200px; background: var(--c-surface2);
  border: 1px solid var(--c-border3); color: var(--c-text);
  border-radius: 10px; padding: .55rem .9rem; font: 500 .9rem 'Barlow';
}

/* ── Responsive: bottom nav mobile ── */
@media (max-width: 900px) {
  .main-nav {
    display: none; flex-direction: column; gap: .25rem;
    position: absolute; top: var(--header-h); left: 0; right: 0;
    background: var(--c-surface); border-bottom: 1px solid var(--c-border);
    padding: .75rem 1rem; z-index: 190;
  }
  .main-nav.open { display: flex; }
  .nav-toggle { display: block; margin-left: auto; }
  .header-inner { position: relative; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-grid { grid-template-columns: 1fr; }
  .dashboard-grid .dash-full { grid-column: 1; }
}
@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .stat-value { font-size: 1.4rem; }
  html { font-size: 14px; }
  .site-main { padding: 1rem .85rem 2rem; }
  .page-header h1 { font-size: 2rem; }
}

/* ── Tabs scrollabili (stile pill) ── */
.tabs { -webkit-overflow-scrolling: touch; }

/* ── Hover row highlight ── */
tbody tr { transition: background .1s; }

/* ── Card variante dark inner ── */
.card-inner {
  background: var(--c-surface); border-radius: 12px; padding: 1rem 1.1rem;
}

/* ── Divider ── */
.divider { border: none; border-top: 1px solid var(--c-border2); margin: 1rem 0; }

/* ── Colori testo per posizioni classifica ── */
.text-pos-1 { color: #F2B84B; }
.text-pos-2 { color: #94a3b8; }
.text-pos-3 { color: #b45309; }

/* ── Stats 3 colonne ── */
.stats-grid-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 480px) { .stats-grid-3 { grid-template-columns: repeat(3, 1fr); } }

/* ── Card Giornata (lime) ── */
.card-giornata {
  background: var(--c-primary); border-radius: var(--radius);
  padding: 1.1rem 1.25rem; color: var(--c-primary-text);
}
.card-giornata-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: .3rem;
}
.card-giornata-label { font: 700 .68rem 'Barlow'; text-transform: uppercase; letter-spacing: .1em; opacity: .7; }
.card-giornata-link  { font: 700 .82rem 'Barlow'; color: var(--c-primary-text); text-decoration: none; opacity: .8; }
.card-giornata-link:hover { opacity: 1; }
.card-giornata-title { font: 800 1.8rem/1 'Barlow Condensed'; text-transform: uppercase; margin-bottom: .85rem; }
.card-giornata-fixtures { display: flex; flex-direction: column; gap: .35rem; }

.fixture-row {
  display: flex; align-items: center; gap: .5rem;
  background: rgba(0,0,0,.12); border-radius: 10px;
  padding: .5rem .75rem;
}
.fixture-team { display: flex; align-items: center; gap: .4rem; flex: 1; }
.fixture-team-home { justify-content: flex-start; }
.fixture-team-away { justify-content: flex-end; flex-direction: row-reverse; }
.fixture-logo {
  width: 24px; height: 24px; object-fit: contain; border-radius: 50%;
  background: rgba(255,255,255,.2); flex-shrink: 0;
}
.fixture-dot { width: 20px; height: 20px; border-radius: 50%; flex-shrink: 0; }
.fixture-name { font: 600 .82rem 'Barlow'; line-height: 1.2; }
.fixture-score {
  display: flex; align-items: center; gap: .3rem; flex-shrink: 0;
  font: 800 .9rem 'Barlow Condensed'; min-width: 60px; justify-content: center;
}
.fixture-vs { font: 500 .7rem 'Barlow'; opacity: .6; }

/* ── Bottom Navigation Mobile ── */
.bottom-nav {
  display: none;
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 200;
  background: var(--c-surface); border-top: 1px solid var(--c-border);
  padding: 0 .5rem env(safe-area-inset-bottom,.5rem);
  justify-content: space-around; align-items: stretch;
}
.bottom-nav-item {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 1px; padding: .35rem .1rem; text-decoration: none;
  color: var(--c-muted2); font: 600 .52rem 'Barlow';
  flex: 1; min-width: 0; transition: color .15s; border-top: 2px solid transparent;
}
.bottom-nav-item span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.bottom-nav-item svg { width: 18px; height: 18px; flex-shrink: 0; }
.bottom-nav-item.active { color: var(--c-primary); border-top-color: var(--c-primary); }

@media (max-width: 900px) {
  .bottom-nav { display: flex; }
  body { padding-bottom: calc(var(--nav-h) + env(safe-area-inset-bottom, 0px)); }
}
/* Pagine a uso prevalentemente mobile: bottom nav sempre visibile */
body.always-bottom-nav .bottom-nav { display: flex; }
body.always-bottom-nav { padding-bottom: calc(var(--nav-h) + env(safe-area-inset-bottom, 0px)); }
