/**
 * Home dashboard (hero/KPI/fascia) + finanza pubblica.
 * Caricato PER ULTIMO nel layout così vince su ruoli/ovr/notifications.
 * File piccolo: più facile da caricare in FTP rispetto a tutto app.css.
 */
/**
 * Home (hero/KPI/fascia manager) + finanze club — stile pannelli pubblici.
 * File servito come pub-site-panels.css (evita "dashboard" nel path: filtri/proxy).
 * Scope: body.page-home.pub-shell-layout, body.page-finance.pub-shell-layout
 */

/* Due regole separate: con la virgola, un selettore non supportato (:has) faceva scartare tutta la regola su browser vecchi. */
body.page-home.pub-shell-layout main.page-content.container {
  padding-top: 0.75rem;
}

@supports selector(:has(*)) {
  main.page-content.container:has(.pub-home-dash) {
    padding-top: 0.75rem;
  }
}

.pub-home-dash {
  margin-bottom: 1.15rem;
}

/* Base scura esplicita: con foto stadio + vetro leggero il vecchio rgba 0.52 sembrava “bianco”. */
body.page-home.pub-shell-layout .pub-dash-hero,
.pub-home-dash > .pub-dash-hero {
  position: relative;
  isolation: isolate;
  border-radius: 18px;
  border: 1px solid rgba(186, 198, 255, 0.14);
  background-color: rgb(10, 14, 28);
  background-image: linear-gradient(
    165deg,
    rgba(22, 30, 56, 0.98) 0%,
    rgba(14, 20, 42, 0.95) 45%,
    rgba(10, 14, 28, 0.98) 100%
  );
  -webkit-backdrop-filter: saturate(150%) blur(12px);
  backdrop-filter: saturate(150%) blur(12px);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.05) inset,
    0 18px 48px rgba(0, 0, 0, 0.28);
  overflow: hidden;
}

.pub-dash-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.4;
  background:
    radial-gradient(ellipse 85% 75% at 10% 0%, rgba(99, 102, 241, 0.3), transparent 58%),
    radial-gradient(ellipse 65% 55% at 100% 6%, rgba(236, 72, 153, 0.14), transparent 52%),
    radial-gradient(ellipse 100% 80% at 50% 100%, rgba(14, 165, 233, 0.12), transparent 58%);
}

.pub-dash-hero__head {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
  padding: 0.45rem 0.85rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.pub-dash-hero__head-main {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
  flex: 1 1 12rem;
}

.pub-dash-hero__toggle {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  flex-shrink: 0;
  margin: 0;
  padding: 0.32rem 0.55rem;
  border-radius: 999px;
  border: 1px solid rgba(56, 189, 248, 0.35);
  background: rgba(14, 165, 233, 0.1);
  color: #7dd3fc;
  font: inherit;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.pub-dash-hero__toggle:hover {
  background: rgba(14, 165, 233, 0.2);
  border-color: rgba(56, 189, 248, 0.55);
  color: #bae6fd;
}

.pub-dash-hero__toggle-text {
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.pub-dash-hero__toggle-chevron {
  font-size: 0.62rem;
  transition: transform 0.22s ease;
}

.pub-dash-hero__toggle[aria-expanded="false"] .pub-dash-hero__toggle-chevron {
  transform: rotate(180deg);
}

@media (max-width: 767.98px) {
  .pub-dash-hero__toggle {
    display: inline-flex;
  }

  .pub-dash-hero.is-collapsed .pub-dash-hero__body {
    display: none;
  }

  .pub-dash-hero.is-collapsed .pub-dash-hero__head {
    border-bottom-color: transparent;
  }
}

@media (min-width: 768px) {
  .pub-dash-hero.is-collapsed .pub-dash-hero__body {
    display: block;
  }
}

.pub-dash-hero__body {
  position: relative;
  z-index: 1;
}

.pub-dash-hero__icon {
  flex-shrink: 0;
  width: 2.15rem;
  height: 2.15rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  color: #e0f2fe;
  border-radius: 12px;
  border: 1px solid rgba(129, 140, 248, 0.38);
  background: linear-gradient(160deg, rgba(96, 165, 250, 0.22) 0%, rgba(37, 99, 235, 0.12) 100%);
  box-shadow:
    0 2px 12px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 255, 255, 0.08) inset;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.45);
}

.pub-dash-hero__text {
  min-width: 0;
}

.pub-dash-hero .breadcrumbs {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: rgba(56, 189, 248, 0.95);
  margin: 0 0 0.25rem;
}

.pub-dash-hero .breadcrumbs a {
  color: inherit;
  text-decoration: none;
}

.pub-dash-hero .breadcrumbs a:hover {
  text-decoration: underline;
}

.pub-dash-hero__title {
  margin: 0;
  font-size: clamp(1.15rem, 3.2vw, 1.45rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: #f8fafc;
  /* Evita il serif del foglio di stile del browser sull’h1 */
  font-family: inherit;
}

.pub-dash-hero__lead {
  margin: 0.2rem 0 0;
  font-size: 0.84rem;
  line-height: 1.4;
  color: rgba(148, 163, 184, 0.98);
  max-width: 42rem;
  font-family: inherit;
}

/* —— ML Analyst home pulse (prima di Mercato/Strutture) —— */
.pub-dash-hero a.xa-home-pulse--compact {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
  padding: 0.45rem 0.75rem;
  border-bottom: 1px solid rgba(34, 211, 238, 0.22);
  background: linear-gradient(120deg, rgba(14, 165, 233, 0.14), rgba(2, 6, 23, 0.35) 55%, rgba(167, 139, 250, 0.08));
  text-decoration: none;
  color: inherit;
}
.pub-dash-hero a.xa-home-pulse--compact:hover {
  background: linear-gradient(120deg, rgba(14, 165, 233, 0.22), rgba(2, 6, 23, 0.4) 55%, rgba(167, 139, 250, 0.12));
}
.pub-dash-hero .xa-home-pulse--compact .xa-home-pulse__mark {
  width: 1.65rem;
  height: 1.65rem;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  color: #0b1220;
  background: linear-gradient(160deg, #7dd3fc, #38bdf8);
}
.pub-dash-hero .xa-home-pulse--compact .xa-home-pulse__lbl {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #bae6fd;
}
.pub-dash-hero .xa-home-pulse--compact .xa-home-pulse__n {
  margin-left: auto;
  min-width: 1.4rem;
  height: 1.4rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(248, 113, 113, 0.2);
  border: 1px solid rgba(248, 113, 113, 0.42);
  color: #fecaca;
  font-size: 0.78rem;
  font-weight: 900;
}
.pub-dash-hero .xa-home-pulse--compact .xa-home-pulse__chev {
  font-size: 0.65rem;
  color: #64748b;
}

.pub-dash-hero .xa-home-pulse {
  position: relative;
  z-index: 1;
  margin: 0;
  padding: 0.55rem 0.75rem 0.65rem;
  border-bottom: 1px solid rgba(34, 211, 238, 0.22);
  background:
    linear-gradient(120deg, rgba(14, 165, 233, 0.14), rgba(2, 6, 23, 0.35) 55%, rgba(167, 139, 250, 0.08));
}
.pub-dash-hero .xa-home-pulse[hidden],
.pub-dash-hero .xa-home-pulse__chip[hidden] {
  display: none !important;
}

.pub-dash-hero .xa-home-pulse__bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.75rem;
  margin-bottom: 0.45rem;
}

.pub-dash-hero .xa-home-pulse__brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
}

.pub-dash-hero .xa-home-pulse__mark {
  width: 1.85rem;
  height: 1.85rem;
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-size: 0.85rem;
  color: #042f2e;
  background: linear-gradient(160deg, #67e8f9, #22d3ee 45%, #0891b2);
  box-shadow: 0 0 16px rgba(34, 211, 238, 0.35);
  flex: 0 0 auto;
}

.pub-dash-hero .xa-home-pulse__titles {
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
  min-width: 0;
}

.pub-dash-hero .xa-home-pulse__eyebrow {
  font-size: 0.62rem;
  font-weight: 850;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #22d3ee;
}

.pub-dash-hero .xa-home-pulse__lead {
  font-size: 0.82rem;
  font-weight: 750;
  color: #e2e8f0;
  line-height: 1.2;
}

.pub-dash-hero .xa-home-pulse__counts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-left: auto;
}

.pub-dash-hero .xa-home-pulse__chip {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.18rem 0.45rem;
  border-radius: 999px;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border: 1px solid transparent;
}

.pub-dash-hero .xa-home-pulse__chip b {
  font-variant-numeric: tabular-nums;
  font-size: 0.78rem;
}

.pub-dash-hero .xa-home-pulse__chip--urgent {
  color: #fecaca;
  background: rgba(239, 68, 68, 0.16);
  border-color: rgba(248, 113, 113, 0.4);
}

.pub-dash-hero .xa-home-pulse__chip--watch {
  color: #fde68a;
  background: rgba(245, 158, 11, 0.14);
  border-color: rgba(251, 191, 36, 0.4);
}

.pub-dash-hero .xa-home-pulse__hub {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  border: 1px solid rgba(45, 212, 191, 0.45);
  background: linear-gradient(180deg, #5eead4, #14b8a6);
  color: #042f2e !important;
  font-size: 0.72rem;
  font-weight: 850;
  text-decoration: none !important;
  white-space: nowrap;
}

.pub-dash-hero .xa-home-pulse__hub:hover {
  filter: brightness(1.06);
}

.pub-dash-hero .xa-home-pulse__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.pub-dash-hero .xa-home-pulse__item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.5rem;
  padding: 0.4rem 0.5rem;
  border-radius: 10px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  background: rgba(2, 6, 23, 0.55);
  border-left-width: 3px;
}

.pub-dash-hero .xa-home-pulse__item--urgent {
  border-left-color: #fb7185;
}

.pub-dash-hero .xa-home-pulse__item--watch {
  border-left-color: #fbbf24;
}

.pub-dash-hero .xa-home-pulse__link {
  flex: 1 1 12rem;
  min-width: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.25rem 0.45rem;
  text-decoration: none !important;
  color: inherit;
}

.pub-dash-hero .xa-home-pulse__sev {
  font-size: 0.62rem;
  font-weight: 850;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #94a3b8;
}

.pub-dash-hero .xa-home-pulse__item--urgent .xa-home-pulse__sev { color: #fecaca; }
.pub-dash-hero .xa-home-pulse__item--watch .xa-home-pulse__sev { color: #fde68a; }

.pub-dash-hero .xa-home-pulse__front {
  font-size: 0.68rem;
  font-weight: 700;
  color: #94a3b8;
}

.pub-dash-hero .xa-home-pulse__front i { color: #22d3ee; margin-right: 0.15rem; }

.pub-dash-hero .xa-home-pulse__title {
  flex: 1 1 100%;
  font-size: 0.86rem;
  font-weight: 800;
  color: #f8fafc;
  line-height: 1.25;
}

.pub-dash-hero .xa-home-pulse__dismiss {
  appearance: none;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(255, 255, 255, 0.04);
  color: #cbd5e1;
  font: inherit;
  font-size: 0.7rem;
  font-weight: 750;
  padding: 0.3rem 0.55rem;
  border-radius: 8px;
  cursor: pointer;
  flex: 0 0 auto;
}

.pub-dash-hero .xa-home-pulse__dismiss:hover {
  border-color: rgba(125, 211, 252, 0.45);
  color: #f0f9ff;
}

@media (max-width: 640px) {
  .pub-dash-hero .xa-home-pulse__counts { margin-left: 0; width: 100%; }
  .pub-dash-hero .xa-home-pulse__hub { margin-left: auto; }
}

/* Griglia KPI (come adm-dash-kpi) */
.pub-dash-kpi {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  padding: 0.55rem 0.85rem 0.7rem;
}

@media (min-width: 900px) {
  .pub-dash-kpi {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.55rem;
    align-items: stretch;
  }

  .pub-dash-kpi.pub-dash-kpi--3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Hero: solo Eventi master (live + prossimi) */
.pub-dash-hero__kpi-row {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.5rem;
  padding: 0.55rem 0.85rem 0.7rem;
  align-items: stretch;
  min-width: 0;
}

.pub-dash-hero__kpi-row > * {
  min-width: 0;
}

.pub-dash-hero__kpi-row--events {
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .pub-dash-hero__kpi-row--events {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 900px) {
  .pub-dash-hero__kpi-row--events {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.5rem;
  }
}

.pub-dash-kpi__tile--master-soon {
  border-color: rgba(125, 211, 252, 0.22);
  background: linear-gradient(145deg, rgba(30, 58, 88, 0.75) 0%, rgba(15, 23, 42, 0.9) 100%);
}

.pub-dash-kpi__tile--master-soon .pub-dash-kpi__label {
  color: #7dd3fc;
}

@media (min-width: 720px) and (max-width: 899.98px) {
  .pub-dash-kpi {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.pub-dash-kpi__tile {
  position: relative;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 0.65rem 0.6rem 0.6rem;
  border-radius: 12px;
  text-decoration: none;
  color: #f1f5f9;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(145deg, rgba(30, 41, 59, 0.92) 0%, rgba(15, 23, 42, 0.88) 100%);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.35) inset,
    0 6px 18px rgba(0, 0, 0, 0.3);
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease, filter 0.16s ease;
  overflow: hidden;
  min-height: 3.35rem;
  box-sizing: border-box;
}

a.pub-dash-kpi__tile--stat {
  cursor: pointer;
}

a.pub-dash-kpi__tile--stat:visited {
  color: #f1f5f9;
}

a.pub-dash-kpi__tile--link {
  cursor: pointer;
}

a.pub-dash-kpi__tile--link:visited {
  color: #f1f5f9;
}

.pub-dash-kpi__tile::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  opacity: 0.22;
  background: radial-gradient(120% 80% at 20% 0%, var(--pub-dash-glow, #38bdf8) 0%, transparent 55%);
  pointer-events: none;
}

a.pub-dash-kpi__tile:hover {
  transform: translateY(-2px);
}

/* box-shadow hover solo dove non c’è animazione “live” (altrimenti copre il pulse) */
a.pub-dash-kpi__tile:hover:not(.pub-dash-kpi__tile--market-on):not(.pub-dash-kpi__tile--struct-on):not(.pub-dash-kpi__tile--master-live) {
  border-color: rgba(255, 255, 255, 0.14);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.35) inset,
    0 12px 32px rgba(0, 0, 0, 0.45),
    0 0 28px var(--pub-dash-ring, rgba(56, 189, 248, 0.2));
}

a.pub-dash-kpi__tile--market-on:hover,
a.pub-dash-kpi__tile--struct-on:hover {
  transform: translateY(-2px) scale(1.015);
}

a.pub-dash-kpi__tile--master-live:hover {
  transform: translateY(-2px);
  border-color: rgba(134, 239, 172, 0.5);
}

.pub-dash-kpi__ico {
  flex-shrink: 0;
  width: 2.15rem;
  height: 2.15rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  font-size: 1.1rem;
  color: #fff;
  background: linear-gradient(160deg, var(--pub-ico-top, #64748b) 0%, var(--pub-ico-bot, #334155) 100%);
  box-shadow:
    0 2px 8px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 255, 255, 0.12) inset;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.45);
  z-index: 1;
}

.pub-dash-kpi__body {
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  min-width: 0;
  z-index: 1;
}

.pub-dash-kpi__value {
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

.pub-dash-kpi__label {
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(226, 232, 240, 0.82);
  line-height: 1.3;
}

.pub-dash-kpi__hint {
  font-size: 0.62rem;
  color: rgba(148, 163, 184, 0.95);
  line-height: 1.25;
  margin-top: 0.08rem;
}

/* Stat (mercato / strutture): label piccolo, stato in evidenza */
.pub-dash-kpi__tile--stat {
  align-items: flex-start;
}

.pub-dash-kpi__tile--stat .pub-dash-kpi__label {
  color: rgba(148, 163, 184, 0.95);
}

.pub-dash-kpi__tile--stat .pub-dash-kpi__value {
  font-size: 1.12rem;
}

/* Link azioni: testo come “label” principale */
.pub-dash-kpi__tile--link .pub-dash-kpi__body {
  justify-content: center;
  gap: 0;
}

.pub-dash-kpi__tile--link .pub-dash-kpi__label {
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: none;
  letter-spacing: 0.02em;
  line-height: 1.25;
  color: #f1f5f9;
}

/* Mercato chiuso / aperto */
.pub-dash-kpi__tile--market-on {
  --pub-dash-glow: #4ade80;
  --pub-dash-ring: rgba(74, 222, 128, 0.35);
  --pub-dash-ring-strong: rgba(74, 222, 128, 0.55);
  --pub-ico-top: #86efac;
  --pub-ico-bot: #16a34a;
  --pub-led-a: #ecfdf5;
  --pub-led-b: #22c55e;
  --pub-led-c: #4ade80;
  --pub-led-d: #bbf7d0;
  border-color: rgba(52, 211, 153, 0.65);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.35) inset,
    0 8px 24px rgba(0, 0, 0, 0.35),
    0 0 20px rgba(74, 222, 128, 0.35);
}

.pub-dash-kpi__tile--market-on .pub-dash-kpi__value {
  color: #a7f3d0;
}

/* Pre-mercato attivo (Season Hub): violet, distinto da mercato chiuso */
.pub-dash-kpi__tile--premarket-on {
  --pub-dash-glow: #a78bfa;
  --pub-dash-ring: rgba(167, 139, 250, 0.38);
  --pub-dash-ring-strong: rgba(167, 139, 250, 0.55);
  --pub-ico-top: #ddd6fe;
  --pub-ico-bot: #7c3aed;
  --pub-led-a: #f5f3ff;
  --pub-led-b: #6d28d9;
  --pub-led-c: #a78bfa;
  --pub-led-d: #e9d5ff;
  border-color: rgba(167, 139, 250, 0.55);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.35) inset,
    0 8px 24px rgba(0, 0, 0, 0.35),
    0 0 20px rgba(167, 139, 250, 0.32);
}

.pub-dash-kpi__tile--premarket-on .pub-dash-kpi__value {
  color: #ddd6fe;
  font-size: 0.98rem;
  letter-spacing: -0.03em;
  white-space: nowrap;
}

@media (max-width: 959.98px) {
  .pub-dash-kpi__tile--premarket-on .pub-dash-kpi__value {
    font-size: 0.84rem;
  }
}

.pub-dash-kpi__tile--premarket-on .pub-dash-kpi__hint {
  color: #c4b5fd;
}

.pub-dash-kpi__tile--premarket-on::before,
.pub-dash-kpi__tile--premarket-on:hover {
  border-color: rgba(196, 181, 253, 0.65);
}

a.pub-dash-kpi__tile--premarket-on:hover {
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.35) inset,
    0 10px 28px rgba(0, 0, 0, 0.38),
    0 0 26px rgba(167, 139, 250, 0.42);
}

/* Strutture aperte: palette LED (cyan) */
.pub-dash-kpi__tile--struct-on {
  --pub-dash-glow: #22d3ee;
  --pub-dash-ring: rgba(34, 211, 238, 0.35);
  --pub-dash-ring-strong: rgba(34, 211, 238, 0.52);
  --pub-ico-top: #67e8f9;
  --pub-ico-bot: #0891b2;
  --pub-led-a: #ecfeff;
  --pub-led-b: #0e7490;
  --pub-led-c: #22d3ee;
  --pub-led-d: #a5f3fc;
  border-color: rgba(56, 189, 248, 0.7);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.35) inset,
    0 8px 24px rgba(0, 0, 0, 0.35),
    0 0 22px rgba(34, 211, 238, 0.38);
}

.pub-dash-kpi__tile--struct-on .pub-dash-kpi__value {
  color: #bae6fd;
}

/* Bordo “LED” 360°: conic-gradient che ruota (dentro la tile → non viene tagliato da overflow:hidden) */
.pub-dash-kpi__tile--market-on::before,
.pub-dash-kpi__tile--struct-on::before,
.pub-dash-kpi__tile--premarket-on::before,
.pub-dash-kpi__tile--master-live::before {
  opacity: 0.28;
}

.pub-dash-kpi__led {
  position: absolute;
  inset: 0;
  border-radius: 14px;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.pub-dash-kpi__tile--market-on,
.pub-dash-kpi__tile--struct-on,
.pub-dash-kpi__tile--premarket-on,
.pub-dash-kpi__tile--master-live {
  --pub-led-orbit-duration: 2.4s;
  container-type: inline-size;
}

.pub-dash-kpi__led-spin {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 220%;
  height: 220%;
  transform: translate(-50%, -50%) rotate(0deg);
  transform-origin: center center;
  will-change: transform;
  background: conic-gradient(
    from 0deg,
    var(--pub-led-a) 0deg,
    var(--pub-led-b) 70deg,
    var(--pub-led-c) 140deg,
    var(--pub-led-d) 210deg,
    var(--pub-led-b) 280deg,
    var(--pub-led-a) 360deg
  );
  animation: pub-dash-led-orbit var(--pub-led-orbit-duration, 2.4s) linear infinite;
}

/* Stessa velocità percepita sul bordo: tile più larghe → rotazione più lenta */
@supports (width: 1cqw) {
  .pub-dash-kpi__tile--market-on,
  .pub-dash-kpi__tile--struct-on,
  .pub-dash-kpi__tile--premarket-on,
  .pub-dash-kpi__tile--master-live {
    --pub-led-orbit-duration: calc(2.4s + (100cqw - 10rem) * 0.012);
  }
}

.pub-dash-kpi__led-cut {
  position: absolute;
  inset: 3px;
  border-radius: 11px;
  z-index: 1;
  background: linear-gradient(145deg, rgba(30, 41, 59, 0.98) 0%, rgba(15, 23, 42, 0.95) 100%);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.4);
}

@keyframes pub-dash-led-orbit {
  from {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  to {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

/*
 * Su molti PC Windows, “Riduci animazioni” / effetti visivi attiva prefers-reduced-motion:
 * prima bloccavamo del tutto la rotazione → bordo “fisso” solo glow. Qui usiamo una rotazione
 * molto lenta (stesso keyframe) così resta visibile ma meno invasiva.
 */
@media (prefers-reduced-motion: reduce) {
  .pub-dash-kpi__tile--market-on,
  .pub-dash-kpi__tile--struct-on,
  .pub-dash-kpi__tile--premarket-on,
  .pub-dash-kpi__tile--master-live {
    --pub-led-orbit-duration: 22s;
  }

  @supports (width: 1cqw) {
    .pub-dash-kpi__tile--market-on,
    .pub-dash-kpi__tile--struct-on,
    .pub-dash-kpi__tile--premarket-on,
    .pub-dash-kpi__tile--master-live {
      --pub-led-orbit-duration: calc(22s + (100cqw - 10rem) * 0.11);
    }
  }
}

.pub-dash-kpi__tile--market-off {
  --pub-dash-glow: #f87171;
  --pub-dash-ring: rgba(248, 113, 113, 0.4);
  --pub-ico-top: #fca5a5;
  --pub-ico-bot: #dc2626;
  border-color: rgba(248, 113, 113, 0.32);
}

.pub-dash-kpi__tile--market-off .pub-dash-kpi__value {
  color: #fecaca;
}

/* Countdown testo Mercato / Strutture */
.pub-dash-kpi__tile--has-cd {
  min-height: 4.1rem;
}

.pub-dash-kpi-cd__clock {
  display: block;
  margin-top: 0.12rem;
  font-size: 0.72rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
  line-height: 1.2;
  color: #fda4af;
}

.pub-dash-kpi__tile--market-on .pub-dash-kpi-cd__clock {
  color: #86efac;
}

.pub-dash-kpi__tile--struct-off .pub-dash-kpi-cd__clock {
  color: #94a3b8;
}

.pub-dash-kpi__tile--struct-on .pub-dash-kpi-cd__clock {
  color: #7dd3fc;
}

.pub-dash-kpi__tile--has-cd .pub-dash-kpi__hint {
  margin-top: 0.1rem;
}

.pub-dash-kpi__tile--struct-off {
  --pub-dash-glow: #64748b;
  --pub-dash-ring: rgba(100, 116, 139, 0.3);
  --pub-ico-top: #94a3b8;
  --pub-ico-bot: #475569;
  border-color: rgba(100, 116, 139, 0.35);
}

.pub-dash-kpi__tile--struct-off .pub-dash-kpi__value {
  color: #cbd5e1;
}

/* Azioni */
.pub-dash-kpi__tile--green {
  --pub-dash-glow: #4ade80;
  --pub-dash-ring: rgba(74, 222, 128, 0.35);
  --pub-ico-top: #86efac;
  --pub-ico-bot: #16a34a;
  border-color: rgba(16, 185, 129, 0.38);
}

.pub-dash-kpi__tile--blue {
  --pub-dash-glow: #60a5fa;
  --pub-dash-ring: rgba(96, 165, 250, 0.35);
  --pub-ico-top: #93c5fd;
  --pub-ico-bot: #2563eb;
  border-color: rgba(56, 189, 248, 0.38);
}

.pub-dash-kpi__tile--gold {
  --pub-dash-glow: #fbbf24;
  --pub-dash-ring: rgba(251, 191, 36, 0.35);
  --pub-ico-top: #fcd34d;
  --pub-ico-bot: #d97706;
  border-color: rgba(251, 191, 36, 0.38);
}

/* Viola / gaming (es. wizard mercato · “Le mie trattative”) */
.pub-dash-kpi__tile--violet {
  --pub-dash-glow: #a78bfa;
  --pub-dash-ring: rgba(167, 139, 250, 0.42);
  --pub-ico-top: #c4b5fd;
  --pub-ico-bot: #6d28d9;
  border-color: rgba(167, 139, 250, 0.42);
}

.pub-dash-kpi__ico svg {
  width: 1.15rem;
  height: 1.15rem;
  display: block;
}

.pub-dash-kpi__tile:focus-visible {
  outline: 2px solid rgba(56, 189, 248, 0.65);
  outline-offset: 2px;
}

.pub-dash-kpi__badge {
  position: absolute;
  top: 0.45rem;
  right: 0.45rem;
  min-width: 1.35rem;
  height: 1.35rem;
  padding: 0 0.35rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  font-weight: 900;
  line-height: 1;
  color: #fff;
  background: linear-gradient(180deg, #f87171, #dc2626);
  border-radius: 999px;
  border: 2px solid rgba(15, 23, 42, 0.95);
  box-shadow: 0 2px 10px rgba(220, 38, 38, 0.45);
  z-index: 2;
}

/* Nascosta su mobile se c’è la barra rapida in basso (stesso breakpoint) */
@media (max-width: 959.98px) {
  .pub-dash-kpi__tile--hide-mobile-bottom-dup {
    display: none !important;
  }
}

.pub-dash-kpi__tile--next-match .pub-dash-kpi__body {
  align-items: flex-start;
  text-align: left;
}

.pub-dash-kpi__next-logo-wrap {
  flex-shrink: 0;
  width: 2.65rem;
  height: 2.65rem;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(56, 189, 248, 0.35);
  background: rgba(15, 23, 42, 0.9);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
}

.pub-dash-kpi__next-logo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.pub-dash-kpi__next-meta {
  display: block;
  margin-top: 0.2rem;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.25;
  color: rgba(186, 230, 253, 0.95);
}

.pub-dash-kpi__next-vs {
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(56, 189, 248, 0.85);
  margin-right: 0.2rem;
}

.pub-dash-kpi__next-name {
  font-weight: 800;
  color: #f0f9ff;
}

/* -------------------------------------------------------------------------- */
/* Home manager strip: Rapporto avversario + Tagboard                          */
/* -------------------------------------------------------------------------- */

.pub-home-manager-strip {
  margin-top: 0.15rem;
  margin-bottom: 0.45rem;
}

.pub-home-manager-strip__grid {
  display: grid;
  gap: 0.65rem;
  width: 100%;
  align-items: stretch;
}

@media (min-width: 900px) {
  .pub-home-manager-strip__grid--2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.pub-home-manager-strip__grid > .pub-home-module--opp,
.pub-home-manager-strip__grid > .pub-home-module--clubstate,
.pub-home-manager-strip__grid > .pub-home-module--tagboard,
.pub-home-manager-strip__grid > .pub-home-module--wire {
  display: flex;
  flex-direction: column;
  min-width: 0;
  margin: 0;
  height: 100%;
  align-self: stretch;
}

.pub-home-module--opp .dash-opp-report--strip {
  margin: 0;
  height: auto;
  width: 100%;
  flex: 1 1 auto;
  box-sizing: border-box;
}

/* Tagboard pannello verticale */
.pub-home-tb {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 0.32rem;
  min-height: 0;
  height: 100%;
  padding: 0.5rem 0.7rem 0.45rem;
  border-radius: 14px;
  border: 1px solid rgba(56, 189, 248, 0.28);
  background: linear-gradient(165deg, rgba(14, 22, 40, 0.92), rgba(8, 12, 24, 0.96));
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.28);
  box-sizing: border-box;
}

.pub-home-tb__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.38rem;
  min-width: 0;
  flex: 1 1 auto;
  max-height: none;
  overflow: hidden;
}

.pub-home-tb__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
}

.pub-home-tb__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  flex: 1 1 auto;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent-1, #12d6c5);
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pub-home-tb__live-dot {
  flex: 0 0 auto;
  width: 0.42rem;
  height: 0.42rem;
  border-radius: 999px;
  background: #4ade80;
  box-shadow: 0 0 0 2px rgba(74, 222, 128, 0.22), 0 0 10px rgba(74, 222, 128, 0.55);
  animation: pub-home-tb-live-dot 1.6s ease-in-out infinite;
}

@keyframes pub-home-tb-live-dot {
  0%, 100% { opacity: 1; transform: scale(1); box-shadow: 0 0 0 2px rgba(74, 222, 128, 0.2), 0 0 8px rgba(74, 222, 128, 0.45); }
  50% { opacity: 0.72; transform: scale(0.86); box-shadow: 0 0 0 3px rgba(74, 222, 128, 0.12), 0 0 14px rgba(74, 222, 128, 0.65); }
}

.pub-home-tb__more {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.68rem;
  font-weight: 750;
  color: #7dd3fc;
  text-decoration: none;
  white-space: nowrap;
}

.pub-home-tb__more:hover {
  color: #e0f2fe;
}

.pub-home-tb__empty {
  margin: 0.2rem 0 0;
  font-size: 0.8rem;
  line-height: 1.4;
  color: #94a3b8;
}

.pub-home-tb__empty a {
  color: #7dd3fc;
  font-weight: 700;
}

.pub-home-tb__item {
  min-width: 0;
  border-top: none;
  padding: 0.32rem 0.42rem;
  border-radius: 8px;
  background: linear-gradient(165deg, rgba(15, 23, 42, 0.55), rgba(8, 12, 24, 0.35));
}

.pub-home-tb__item--alt {
  background: linear-gradient(165deg, rgba(30, 41, 59, 0.62), rgba(15, 23, 42, 0.42));
}

.pub-home-tb__item:first-child {
  border-top: none;
  padding-top: 0.32rem;
}

.pub-home-tb__link {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
  text-decoration: none;
  color: inherit;
}

.pub-home-tb__link:hover .pub-home-tb__body {
  color: #f8fafc;
}

.pub-home-tb__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem 0.4rem;
  min-width: 0;
  font-size: 0.72rem;
  line-height: 1.25;
}

.pub-home-tb__who {
  color: #e2e8f0;
  font-weight: 800;
}

.pub-home-tb__crest {
  width: 14px;
  height: 14px;
  border-radius: 3px;
  object-fit: contain;
  flex-shrink: 0;
}

.pub-home-tb__team {
  color: #94a3b8;
  font-weight: 650;
  max-width: 7rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pub-home-tb__when {
  margin-left: auto;
  color: #64748b;
  font-size: 0.66rem;
  font-weight: 650;
  white-space: nowrap;
}

.pub-home-tb__body {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: 0.76rem;
  line-height: 1.28;
  color: #cbd5e1;
  font-weight: 600;
}

@media (max-width: 959.98px) {
  .pub-home-manager-strip {
    margin-top: 0.35rem;
    margin-bottom: 0.4rem;
  }
}

/* -------------------------------------------------------------------------- */
/* Moduli griglia (News, Mercato, …) — stesso linguaggio del hero               */
/* -------------------------------------------------------------------------- */

.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel {
  position: relative;
  border-radius: 16px;
  border: 1px solid rgba(186, 198, 255, 0.12);
  background: rgba(12, 18, 40, 0.42);
  -webkit-backdrop-filter: saturate(150%) blur(12px);
  backdrop-filter: saturate(150%) blur(12px);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.04) inset,
    0 14px 40px rgba(0, 0, 0, 0.26);
  overflow: hidden;
}

.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 2px;
  opacity: 0.75;
  pointer-events: none;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(56, 189, 248, 0.45),
    rgba(52, 211, 153, 0.35),
    rgba(129, 140, 248, 0.35),
    transparent
  );
}

.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel > .hd {
  position: relative;
  z-index: 1;
  background: rgba(8, 12, 26, 0.35);
  border-bottom-color: rgba(148, 163, 184, 0.14);
  padding: 0.65rem 0.85rem;
}

.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel > .bd,
.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel > .dash-mod-body {
  position: relative;
  z-index: 1;
}

.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel .tabs {
  padding-left: 0.65rem;
  padding-right: 0.65rem;
}

.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel .tab-btn {
  border-color: rgba(129, 140, 248, 0.2);
  background: rgba(15, 23, 42, 0.45);
}

.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel .tab-btn[aria-selected="true"] {
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.15);
}

.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel .tab-panels {
  border-top-color: rgba(148, 163, 184, 0.12);
}

.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel .dash-mod-toggle {
  border-color: rgba(56, 189, 248, 0.32);
  background: linear-gradient(165deg, rgba(24, 32, 48, 0.88), rgba(12, 18, 30, 0.95));
}

/* Tab "Ultime di Mercato": testo sempre leggibile (evita pill scura su sfondo scuro) */
.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel .tabs--mercato .tab-btn {
  color: #e8f0ff !important;
  background: rgba(56, 189, 248, 0.12) !important;
  border: 1px solid rgba(56, 189, 248, 0.38) !important;
  opacity: 1 !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.55);
}

.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel .tabs--mercato .tab-btn:hover {
  background: rgba(56, 189, 248, 0.2) !important;
  border-color: rgba(125, 211, 252, 0.5) !important;
}

.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel .tabs--mercato .tab-btn[aria-selected="true"] {
  color: #0b1220 !important;
  background: linear-gradient(180deg, #5eead4, #22d3ee) !important;
  border-color: rgba(14, 165, 233, 0.65) !important;
  font-weight: 800;
  text-shadow: none;
  box-shadow: 0 0 22px rgba(34, 211, 238, 0.28);
}

/* Tab "Risultati recenti" (magenta): stesso problema contrasto dell'attivo */
.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel .tabs--magenta .tab-btn {
  color: #f5e8ff !important;
  background: rgba(232, 121, 249, 0.14) !important;
  border: 1px solid rgba(232, 121, 249, 0.42) !important;
  opacity: 1 !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.55);
}

.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel .tabs--magenta .tab-btn:hover {
  background: rgba(232, 121, 249, 0.22) !important;
  border-color: rgba(244, 114, 242, 0.55) !important;
}

.dashboard-grid.dashboard-grid--home > section.card.pub-home-panel .tabs--magenta .tab-btn[aria-selected="true"] {
  color: #1a0524 !important;
  background: linear-gradient(180deg, #f0abfc, #e879f9) !important;
  border-color: rgba(192, 38, 211, 0.65) !important;
  font-weight: 800;
  text-shadow: none;
  box-shadow: 0 0 22px rgba(232, 121, 249, 0.35);
}

/* -------------------------------------------------------------------------- */
/* Finanze club (/finance): larghezza come Home + card/bottoni come dashboard   */
/* -------------------------------------------------------------------------- */

body.page-finance.pub-shell-layout main.page-content.container {
  padding-top: 0.75rem;
}

body.page-finance.pub-shell-layout .mgr-finance-grid {
  max-width: min(100%, 1420px);
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-left: 0;
  padding-right: 0;
}

body.page-finance.pub-shell-layout .finance-admin.manager .card.mgr-dash-hero,
body.page-finance.pub-shell-layout .finance-admin.manager .card.mgr-finance-tx-card {
  position: relative;
  border-radius: 16px;
  border: 1px solid rgba(186, 198, 255, 0.12);
  background: rgba(12, 18, 40, 0.42);
  -webkit-backdrop-filter: saturate(150%) blur(12px);
  backdrop-filter: saturate(150%) blur(12px);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.04) inset,
    0 14px 40px rgba(0, 0, 0, 0.26);
  overflow: hidden;
}

body.page-finance.pub-shell-layout .finance-admin.manager .card.mgr-dash-hero::before,
body.page-finance.pub-shell-layout .finance-admin.manager .card.mgr-finance-tx-card::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  bottom: auto;
  height: 2px;
  opacity: 0.75;
  pointer-events: none;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(56, 189, 248, 0.45),
    rgba(52, 211, 153, 0.35),
    rgba(129, 140, 248, 0.35),
    transparent
  );
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-dash-hero > *,
body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-tx-card > * {
  position: relative;
  z-index: 1;
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-balance-block {
  background: rgba(8, 12, 26, 0.55);
  border-color: rgba(56, 189, 248, 0.28);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.04) inset;
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-filters {
  border-color: rgba(129, 140, 248, 0.22);
  background: rgba(15, 23, 42, 0.38);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-filters .input {
  border-color: rgba(56, 189, 248, 0.25);
  background: rgba(11, 18, 32, 0.72);
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-filters .btn {
  border-radius: 12px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-filters .btn:not(.outline) {
  color: #0b1220 !important;
  background: linear-gradient(180deg, #5eead4, #22d3ee) !important;
  border: 1px solid rgba(14, 165, 233, 0.65) !important;
  box-shadow: 0 0 22px rgba(34, 211, 238, 0.22);
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-filters .btn.outline {
  color: #e8f4fc !important;
  background: linear-gradient(165deg, rgba(24, 32, 48, 0.88), rgba(12, 18, 30, 0.95)) !important;
  border: 1px solid rgba(56, 189, 248, 0.32) !important;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.25);
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-filters .btn.outline:hover {
  border-color: rgba(125, 211, 252, 0.5) !important;
  color: #fff !important;
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-pill-link:not(.mgr-pill-link--soft) {
  color: #0b1220;
  background: linear-gradient(180deg, #5eead4, #22d3ee);
  border: 1px solid rgba(14, 165, 233, 0.65);
  box-shadow: 0 4px 18px rgba(34, 211, 238, 0.2);
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-pill-link:not(.mgr-pill-link--soft):hover {
  border-color: rgba(125, 211, 252, 0.75);
  box-shadow: 0 6px 24px rgba(34, 211, 238, 0.28);
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-pill-link--soft {
  background: rgba(15, 23, 42, 0.55);
  border-color: rgba(56, 189, 248, 0.28);
  color: rgba(226, 232, 240, 0.92);
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-pill-link--soft:hover {
  border-color: rgba(125, 211, 252, 0.45);
  color: #f8fafc;
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-kpi {
  background: rgba(15, 23, 42, 0.45);
  border-color: rgba(129, 140, 248, 0.16);
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-chip {
  border-color: rgba(56, 189, 248, 0.28);
  background: rgba(8, 12, 26, 0.5);
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-section-title {
  color: #f1f5f9;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-table-wrap {
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  overflow: hidden;
}

@media (max-width: 959.98px) {
  body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-table-wrap {
    overflow-x: auto;
    overflow-y: visible;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: rgba(51, 65, 85, 0.85) rgba(15, 23, 42, 0.35);
  }

  body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-table-wrap::-webkit-scrollbar {
    height: 5px;
  }

  body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-table-wrap::-webkit-scrollbar-track {
    background: rgba(15, 23, 42, 0.35);
    border-radius: 6px;
  }

  body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-table-wrap::-webkit-scrollbar-thumb {
    background: rgba(51, 65, 85, 0.95);
    border-radius: 6px;
  }

  body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-table-wrap::-webkit-scrollbar-thumb:hover {
    background: rgba(71, 85, 105, 0.95);
  }
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-table thead {
  background: rgba(8, 12, 26, 0.65);
}

/* Finanze: flare un filo più visibile su vetro pubblico + sparkline “mercati” */
body.page-finance.pub-shell-layout .finance-admin.manager .card.mgr-finance-hero::after {
  opacity: 0.62;
  mix-blend-mode: screen;
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-sparkline__line {
  filter: drop-shadow(0 0 5px rgba(34, 211, 238, 0.4)) drop-shadow(0 0 12px rgba(45, 212, 191, 0.15));
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-sparkline__baseline {
  stroke: rgba(100, 116, 139, 0.22);
}

body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-sparkline__cap {
  color: rgba(148, 163, 184, 0.7);
}

/* —— PROSSIMI EVENTI MASTER (Home hero) —— */
.pub-dash-hero .pub-master-events {
  position: relative;
  z-index: 1;
  margin: 0;
  padding: 0.5rem 0.75rem 0.55rem;
  border-top: 1px solid rgba(34, 211, 238, 0.14);
  background: linear-gradient(180deg, rgba(8, 16, 32, 0.55) 0%, rgba(6, 10, 22, 0.35) 100%);
}

/* Eventi master — tile KPI cliccabile (Home hero) */
.pub-dash-kpi__tile--master-events {
  padding-right: 2.35rem;
  cursor: pointer;
}

.pub-dash-kpi__tile--master-live {
  --pub-dash-glow: #22c55e;
  --pub-dash-ring: rgba(34, 197, 94, 0.38);
  --pub-dash-ring-strong: rgba(34, 197, 94, 0.55);
  --pub-ico-top: #86efac;
  --pub-ico-bot: #15803d;
  --pub-led-a: #f0fdf4;
  --pub-led-b: #166534;
  --pub-led-c: #22c55e;
  --pub-led-d: #bbf7d0;
  --pub-live-glow: rgba(74, 222, 128, 0.3);
  /* Bordo sottile + alone che respira (come mcal__live) */
  border-color: rgba(74, 222, 128, 0.38);
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.32),
    0 0 0 1px rgba(34, 197, 94, 0.18) inset,
    0 0 18px var(--pub-live-glow);
  animation: pub-master-live-glow 4.2s ease-in-out infinite;
}

.pub-dash-kpi__tile--master-live .pub-dash-kpi__led-cut {
  inset: 1.5px;
  border-radius: 10.5px;
}

.pub-dash-kpi__tile--master-live .pub-dash-kpi__value,
.pub-dash-kpi__tile--master-live .pub-dash-kpi__value--live-title {
  color: #dcfce7;
}

.pub-dash-kpi__tile--master-live .pub-dash-kpi__hint {
  color: #86efac;
}

.pub-dash-kpi__tile--master-events .pub-dash-kpi__body {
  padding-right: 0.15rem;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.05rem;
  min-width: 0;
}

.pub-dash-kpi__tile--master-events .pub-dash-kpi__value {
  font-size: 0.92rem;
  line-height: 1.15;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

@media (min-width: 900px) {
  .pub-dash-kpi__tile--master-events .pub-dash-kpi__value {
    font-size: 0.86rem;
    -webkit-line-clamp: 1;
    white-space: nowrap;
    display: block;
    text-overflow: ellipsis;
  }
}

.pub-master-kpi__live {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  gap: 0.22rem;
  margin: 0 0 0.2rem;
  padding: 0.14rem 0.48rem 0.14rem 0.36rem;
  border-radius: 999px;
  font-size: 0.52rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #f0fdf4;
  background: linear-gradient(180deg, #22c55e 0%, #15803d 100%);
  border: 1px solid rgba(187, 247, 208, 0.5);
  box-shadow:
    0 0 12px rgba(34, 197, 94, 0.5),
    0 0 0 1px rgba(0, 0, 0, 0.25) inset;
  line-height: 1;
  animation: pubMasterKpiLivePulse 2.2s ease-in-out infinite;
}

.pub-master-kpi__live::before {
  content: "";
  width: 0.38rem;
  height: 0.38rem;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 0 8px rgba(255, 255, 255, 0.85);
  animation: pubMasterKpiLiveDot 2.2s ease-in-out infinite;
}

@keyframes pubMasterKpiLivePulse {
  0%, 100% {
    box-shadow:
      0 0 12px rgba(34, 197, 94, 0.45),
      0 0 0 1px rgba(0, 0, 0, 0.25) inset;
  }
  50% {
    box-shadow:
      0 0 18px rgba(74, 222, 128, 0.7),
      0 0 0 1px rgba(0, 0, 0, 0.25) inset;
  }
}

@keyframes pubMasterKpiLiveDot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.65; transform: scale(0.82); }
}

@keyframes pub-master-live-glow {
  0%, 100% {
    box-shadow:
      0 8px 24px rgba(0, 0, 0, 0.32),
      0 0 0 1px rgba(34, 197, 94, 0.16) inset,
      0 0 16px var(--pub-live-glow, rgba(74, 222, 128, 0.22));
  }
  50% {
    box-shadow:
      0 8px 24px rgba(0, 0, 0, 0.32),
      0 0 0 1px rgba(187, 247, 208, 0.28) inset,
      0 0 30px var(--pub-live-glow, rgba(74, 222, 128, 0.4));
  }
}

/* Barra avanzamento fase live (riempie verso la scadenza) */
.pub-master-kpi__progress {
  display: block;
  width: 100%;
  height: 0.28rem;
  margin-top: 0.42rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(74, 222, 128, 0.28);
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.25) inset;
}

.pub-master-kpi__progress-fill {
  display: block;
  height: 100%;
  width: 0%;
  border-radius: inherit;
  background: linear-gradient(90deg, #16a34a 0%, #4ade80 55%, #bbf7d0 100%);
  box-shadow: 0 0 10px rgba(74, 222, 128, 0.55);
  position: relative;
  transition: width 0.8s ease;
  min-width: 0.35rem;
}

.pub-master-kpi__progress-fill::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.35) 45%,
    transparent 90%
  );
  background-size: 200% 100%;
  animation: pubMasterKpiProgressShine 2.4s linear infinite;
}

@keyframes pubMasterKpiProgressShine {
  0% { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

.pub-dash-kpi__tile--master-live .pub-master-kpi__arrow {
  background: linear-gradient(160deg, rgba(74, 222, 128, 0.55) 0%, rgba(21, 128, 61, 0.8) 100%);
  border-color: rgba(187, 247, 208, 0.65);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.35) inset,
    0 2px 10px rgba(0, 0, 0, 0.35),
    0 0 14px rgba(34, 197, 94, 0.35);
}

a.pub-dash-kpi__tile--master-live:hover .pub-master-kpi__arrow {
  background: linear-gradient(160deg, rgba(134, 239, 172, 0.7) 0%, rgba(22, 163, 74, 0.85) 100%);
  border-color: rgba(220, 252, 231, 0.75);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.35) inset,
    0 3px 12px rgba(0, 0, 0, 0.4),
    0 0 18px rgba(74, 222, 128, 0.5);
}

.pub-master-kpi__arrow {
  position: absolute;
  right: 0.5rem;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 999px;
  color: #f8fafc;
  background: linear-gradient(160deg, rgba(56, 189, 248, 0.55) 0%, rgba(14, 116, 144, 0.75) 100%);
  border: 1px solid rgba(125, 211, 252, 0.65);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.35) inset,
    0 2px 10px rgba(0, 0, 0, 0.35),
    0 0 14px rgba(56, 189, 248, 0.35);
  font-size: 0.72rem;
  z-index: 1;
  transition: transform 0.16s ease, background 0.16s ease, color 0.16s ease, box-shadow 0.16s ease;
}

a.pub-dash-kpi__tile--master-events:hover .pub-master-kpi__arrow {
  transform: translateY(-50%) translateX(3px);
  color: #fff;
  background: linear-gradient(160deg, rgba(96, 165, 250, 0.7) 0%, rgba(21, 128, 161, 0.85) 100%);
  border-color: rgba(186, 230, 253, 0.75);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.35) inset,
    0 3px 12px rgba(0, 0, 0, 0.4),
    0 0 18px rgba(56, 189, 248, 0.5);
}

.pub-master-events__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.25rem 0.65rem;
  margin-bottom: 0.35rem;
}

.pub-master-events__head-main {
  min-width: 0;
  flex: 1 1 auto;
}

.pub-master-events__title {
  margin: 0;
  font-size: clamp(0.62rem, 1.4vw, 0.72rem);
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #f1f5f9;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 767.98px) {
  .pub-master-events__title {
    white-space: normal;
    line-height: 1.3;
  }
}

.pub-master-events__calendar-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: #7dd3fc;
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
  padding-top: 0.05rem;
  transition: color 0.2s ease;
}

.pub-master-events__calendar-link:hover {
  color: #bae6fd;
  text-decoration: none;
}

.pub-master-events__body {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  min-height: 0;
}

@media (min-width: 768px) {
  .pub-master-events__body {
    flex-direction: row;
    align-items: stretch;
    gap: 0.6rem;
    min-height: 0;
    max-height: 9.25rem;
  }
}

/* —— Live (~35%) —— */
.pub-master-events__live {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.42rem 0.55rem;
  border-radius: 12px;
  border: 1px solid rgba(34, 211, 238, 0.35);
  background: linear-gradient(145deg, rgba(8, 47, 73, 0.45), rgba(15, 23, 42, 0.72));
  box-shadow:
    0 0 0 1px rgba(34, 211, 238, 0.08) inset,
    0 0 24px rgba(34, 211, 238, 0.12);
  box-sizing: border-box;
}

@media (min-width: 768px) {
  .pub-master-events__live {
    flex: 0 0 35%;
    max-width: 35%;
    min-width: 0;
  }
}

.pub-master-events__live-main {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
}

.pub-master-events__live-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  padding: 0.14rem 0.42rem 0.14rem 0.32rem;
  border-radius: 999px;
  font-size: 0.54rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #ecfdf5;
  background: linear-gradient(180deg, #7c3aed, #6d28d9);
  box-shadow: 0 0 10px rgba(124, 58, 237, 0.45);
  line-height: 1;
  flex-shrink: 0;
}

.pub-master-events__live-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.45rem;
  min-width: 0;
}

.pub-master-events__live-dot {
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 0 8px rgba(255, 255, 255, 0.75);
  animation: pubMeLiveDot 1.6s ease-in-out infinite;
  flex-shrink: 0;
}

@keyframes pubMeLiveDot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.55; transform: scale(0.85); }
}

.pub-master-events__live-icon {
  flex-shrink: 0;
  width: 1.85rem;
  height: 1.85rem;
  display: grid;
  place-items: center;
  clip-path: polygon(25% 6%, 75% 6%, 100% 50%, 75% 94%, 25% 94%, 0 50%);
  background: linear-gradient(180deg, rgba(52, 211, 153, 0.35), rgba(16, 185, 129, 0.15));
  border: 1px solid rgba(52, 211, 153, 0.45);
  color: #6ee7b7;
  font-size: 0.78rem;
}

.pub-master-events__live.is-tone-violet .pub-master-events__live-icon {
  background: linear-gradient(180deg, rgba(167, 139, 250, 0.35), rgba(124, 58, 237, 0.15));
  border-color: rgba(167, 139, 250, 0.45);
  color: #c4b5fd;
}

.pub-master-events__live.is-tone-amber .pub-master-events__live-icon,
.pub-master-events__live.is-tone-orange .pub-master-events__live-icon {
  background: linear-gradient(180deg, rgba(251, 191, 36, 0.35), rgba(245, 158, 11, 0.15));
  border-color: rgba(251, 191, 36, 0.45);
  color: #fcd34d;
}

.pub-master-events__live-copy {
  min-width: 0;
  flex: 1 1 auto;
}

.pub-master-events__live-title {
  margin: 0;
  font-size: clamp(0.78rem, 1.6vw, 0.86rem);
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1.2;
  color: #f8fafc;
  word-break: break-word;
}

.pub-master-events__live-dates {
  margin: 0.08rem 0 0;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #cbd5e1;
  line-height: 1.25;
}

.pub-master-events__live-countdown {
  margin: 0.12rem 0 0;
  font-size: clamp(0.74rem, 1.6vw, 0.82rem);
  font-weight: 800;
  letter-spacing: 0.02em;
  color: #38bdf8;
  line-height: 1.15;
  text-shadow: 0 0 16px rgba(56, 189, 248, 0.28);
}

.pub-master-events__live-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.32rem;
  margin-top: 0;
}

.pub-master-events__action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  flex: 1 1 calc(50% - 0.2rem);
  min-width: 0;
  padding: 0.3rem 0.45rem;
  border-radius: 8px;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-decoration: none;
  text-transform: uppercase;
  color: #e0f2fe;
  border: 1px solid rgba(56, 189, 248, 0.45);
  background: rgba(14, 165, 233, 0.14);
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.pub-master-events__action--long {
  text-transform: none;
  letter-spacing: 0.02em;
  font-size: 0.58rem;
  font-weight: 700;
}

.pub-master-events__action:hover {
  background: rgba(14, 165, 233, 0.26);
  border-color: rgba(56, 189, 248, 0.7);
  transform: translateY(-1px);
  text-decoration: none;
}

.pub-master-events__action i {
  font-size: 0.72rem;
  opacity: 0.9;
}

/* —— Prossimamente (~65%) —— */
.pub-master-events__upcoming {
  flex: 1 1 65%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.15rem 0 0;
}

@media (min-width: 768px) {
  .pub-master-events__upcoming {
    padding: 0.1rem 0 0;
  }
}

.pub-master-events__upcoming-label {
  margin: 0;
  font-size: 0.58rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(56, 189, 248, 0.85);
}

.pub-master-events__upcoming-wrap {
  display: flex;
  align-items: stretch;
  gap: 0.35rem;
  flex: 1 1 auto;
  min-height: 0;
}

.pub-master-events__chain-outer {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
}

.pub-master-events__chain {
  display: flex;
  align-items: flex-start;
  gap: 0;
  list-style: none;
  margin: 0;
  padding: 0.15rem 0 0.1rem;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.pub-master-events__chain::-webkit-scrollbar {
  display: none;
}

.pub-master-events__chain-item {
  display: flex;
  align-items: flex-start;
  flex: 0 0 auto;
  position: relative;
  padding-bottom: 0.15rem;
}

.pub-master-events__card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.22rem;
  width: 5.5rem;
  padding: 0.35rem 0.25rem 0.4rem;
  border: 1px solid rgba(100, 116, 139, 0.35);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.55);
  color: inherit;
  cursor: pointer;
  opacity: 0.74;
  scroll-snap-align: start;
  transition: opacity 0.2s ease, border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.pub-master-events__card:hover,
.pub-master-events__card[aria-expanded="true"] {
  opacity: 1;
  border-color: rgba(56, 189, 248, 0.45);
  background: rgba(14, 165, 233, 0.1);
  transform: translateY(-1px);
}

.pub-master-events__card-icon {
  width: 1.65rem;
  height: 1.65rem;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: rgba(30, 41, 59, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.25);
  color: #94a3b8;
  font-size: 0.72rem;
}

.pub-master-events__card.is-tone-amber .pub-master-events__card-icon,
.pub-master-events__card.is-tone-orange .pub-master-events__card-icon {
  color: #fbbf24;
  border-color: rgba(251, 191, 36, 0.35);
}

.pub-master-events__card.is-tone-violet .pub-master-events__card-icon {
  color: #a78bfa;
  border-color: rgba(167, 139, 250, 0.35);
}

.pub-master-events__card.is-tone-emerald .pub-master-events__card-icon,
.pub-master-events__card.is-tone-cyan .pub-master-events__card-icon {
  color: #34d399;
  border-color: rgba(52, 211, 153, 0.35);
}

.pub-master-events__card.is-tone-gold .pub-master-events__card-icon {
  color: #facc15;
  border-color: rgba(250, 204, 21, 0.35);
}

.pub-master-events__card-label {
  font-size: 0.8125rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  text-align: center;
  line-height: 1.2;
  color: #e2e8f0;
  max-width: 100%;
  word-break: break-word;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.pub-master-events__card-dates {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-align: center;
  line-height: 1.2;
  color: #94a3b8;
  max-width: 100%;
}

.pub-master-events__connector {
  align-self: center;
  width: 1.1rem;
  height: 2px;
  margin: 1.15rem 0.05rem 0;
  background: linear-gradient(90deg, rgba(100, 116, 139, 0.5), rgba(148, 163, 184, 0.35));
  flex-shrink: 0;
  position: relative;
}

.pub-master-events__connector::after {
  content: "";
  position: absolute;
  right: -2px;
  top: 50%;
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.55);
  transform: translateY(-50%);
}

.pub-master-events__detail {
  position: absolute;
  z-index: 5;
  top: calc(100% + 0.25rem);
  left: 50%;
  transform: translateX(-50%);
  width: max-content;
  max-width: 14rem;
  padding: 0.45rem 0.55rem;
  border-radius: 8px;
  border: 1px solid rgba(56, 189, 248, 0.35);
  background: rgba(15, 23, 42, 0.96);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.pub-master-events__detail-title {
  margin: 0;
  font-size: 0.75rem;
  font-weight: 800;
  color: #f1f5f9;
  line-height: 1.25;
}

.pub-master-events__detail-dates {
  margin: 0.15rem 0 0;
  font-size: 0.6875rem;
  font-weight: 700;
  color: #94a3b8;
}

.pub-master-events__detail-desc {
  margin: 0.25rem 0 0;
  font-size: 0.6875rem;
  line-height: 1.35;
  color: #cbd5e1;
}

.pub-master-events__detail-link {
  display: inline-block;
  margin-top: 0.35rem;
  font-size: 0.625rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #7dd3fc;
  text-decoration: none;
}

.pub-master-events__detail-link:hover {
  color: #bae6fd;
  text-decoration: none;
}

.pub-master-events__scroll-btn {
  flex: 0 0 1.65rem;
  align-self: center;
  width: 1.65rem;
  height: 1.65rem;
  display: grid;
  place-items: center;
  border-radius: 999px;
  border: 1px solid rgba(56, 189, 248, 0.4);
  background: rgba(14, 165, 233, 0.12);
  color: #7dd3fc;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, opacity 0.2s ease;
}

.pub-master-events__scroll-btn:hover:not(:disabled) {
  background: rgba(14, 165, 233, 0.24);
  border-color: rgba(56, 189, 248, 0.65);
}

.pub-master-events__scroll-btn:disabled {
  opacity: 0.35;
  cursor: default;
}

.pub-master-events__empty {
  margin: 0;
  padding: 0.75rem;
  font-size: 0.8125rem;
  color: #94a3b8;
  text-align: center;
}

@media (max-width: 767.98px) {
  .pub-master-events__live {
    width: 100%;
    max-width: none;
  }

  .pub-master-events__upcoming {
    width: 100%;
  }

  .pub-master-events__card {
    width: 5.15rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .pub-master-events__live-dot {
    animation: none !important;
  }
  .pub-master-kpi__live,
  .pub-master-kpi__live::before {
    animation: none !important;
  }
  .pub-dash-kpi__tile--master-live {
    animation: none !important;
  }
  .pub-master-kpi__progress-fill {
    transition: none !important;
  }
  .pub-master-kpi__progress-fill::after {
    animation: none !important;
  }
  .pub-master-events__card,
  .pub-master-events__action {
    transition: none !important;
  }
  .pub-home-tb__live-dot {
    animation: none !important;
  }
}

/* Benessere rosa — label bianche, solo valore % colorato */
.dash-clubstate__em-row {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0 6px;
  font-size: 0.82rem;
  line-height: 1.25;
}
.dash-clubstate__em-item {
  display: inline-flex;
  align-items: baseline;
  gap: 0.28rem;
}
.dash-clubstate__em-lbl {
  color: #f1f5f9 !important;
  font-weight: 800;
}
.dash-clubstate__em-sep {
  color: #64748b;
  font-weight: 700;
}
.dash-clubstate__em-val {
  font-weight: 1000;
  letter-spacing: -0.02em;
}
.dash-clubstate__em-val--ok {
  color: #86efac !important;
}
.dash-clubstate__em-val--bad {
  color: #fca5a5 !important;
}

/* Mobile: senza blur i pannelli semi-trasparenti devono restare opachi */
@media (max-width: 980px) {
  .dashboard-grid.dashboard-grid--home > section.card.pub-home-panel {
    background: rgba(12, 18, 40, 0.94);
  }
  body.page-finance.pub-shell-layout .finance-admin.manager .card.mgr-finance-tx-card {
    background: rgba(12, 18, 40, 0.94);
  }
  body.page-finance.pub-shell-layout .finance-admin.manager .mgr-finance-filters {
    background: rgba(15, 23, 42, 0.94);
  }
}
