/* Teams: telefono statico e grafici, comparse condivise in ai-base.css. */
.teams-scena {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas: "telefono" "schede";
  gap: 16px;
  margin-top: 30px;
}
.teams-telefono {
  --teams-viola: #5B5FC7;
  grid-area: telefono;
  min-width: 0;
  width: 100%;
  max-width: 340px;
  margin-inline: auto;
  padding: 6px;
  border: 6px solid var(--basalto);
  border-radius: 38px;
  background: var(--notte);
  box-shadow: 0 18px 44px color-mix(in srgb, var(--notte) 22%, transparent);
  display: flex;
  flex-direction: column;
}
.teams-telefono .teams-schermo {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  border-radius: 26px;
  padding-block: 6px;
  background: var(--bianco);
  color: var(--notte);
  font-size: .90625rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.teams-telefono .teams-stato {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 5px 16px 4px;
  font-size: .8125rem;
  font-weight: 600;
}
.teams-telefono .teams-signal { display: inline-flex; gap: 3px; align-items: flex-end; }
.teams-telefono .teams-signal i { display: block; width: 3px; background: var(--notte); border-radius: 1px; }
.teams-telefono .teams-signal i:nth-child(1) { height: 4px; }
.teams-telefono .teams-signal i:nth-child(2) { height: 7px; }
.teams-telefono .teams-signal i:nth-child(3) { height: 10px; }
.teams-telefono .teams-signal i:nth-child(4) { height: 13px; }
.teams-telefono .teams-barra {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 8px 10px;
  border-bottom: 1px solid var(--riga);
}
.teams-telefono .teams-indietro { flex: none; width: 20px; height: 20px; }
.teams-telefono .teams-indietro path { fill: none; stroke: var(--notte); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.teams-telefono .teams-avatar {
  flex: none;
  width: 2.125rem;
  min-height: 2.125rem;
  border-radius: 50%;
  background: var(--teams-viola);
  color: var(--bianco);
  display: grid;
  place-items: center;
  font-size: .75rem;
  font-weight: 600;
}
.teams-telefono .teams-piccolo { align-self: start; width: 1.625rem; min-height: 1.625rem; font-size: .625rem; }
.teams-telefono .teams-nome { display: flex; flex-direction: column; min-width: 0; }
.teams-telefono .teams-nome strong { font-weight: 600; font-size: .96875rem; line-height: 1.2; }
.teams-telefono .teams-nome span { color: var(--servizio); font-size: .78125rem; }
.teams-telefono .teams-chat {
  list-style: none;
  margin: 0;
  padding: 14px 8px 8px;
  background: var(--carta);
  display: grid;
  gap: 12px;
  flex: 1;
  align-content: start;
}
.teams-telefono .teams-chat li { min-width: 0; font-size: .90625rem; line-height: 1.35; }
.teams-telefono .teams-utente {
  justify-self: end;
  max-width: 74%;
  background: var(--panna);
  border: 1px solid var(--riga);
  border-radius: 6px;
  padding: 8px 12px;
  box-shadow: var(--ombra-a-piccola);
}
.teams-telefono .teams-agente { display: grid; grid-template-columns: 1.625rem minmax(0, 1fr); gap: 8px; }
.teams-telefono .teams-corpo { min-width: 0; }
.teams-telefono .teams-chi { display: block; font-size: .75rem; color: var(--servizio); margin-bottom: 3px; }
.teams-telefono .teams-chi b { color: var(--notte); font-weight: 600; }
.teams-telefono .teams-bolla { background: var(--bianco); border: 1px solid var(--riga); border-radius: 6px; padding: 8px 12px; box-shadow: var(--ombra-a-piccola); }
.teams-telefono .teams-agente small { display: block; font-size: .78125rem; color: var(--servizio); margin-top: 4px; }
.teams-telefono .teams-agente .teams-ok { color: var(--notte); }
.teams-telefono .teams-ok::before { content: "\2713\00a0"; color: var(--teams-viola); font-weight: 600; }
.teams-telefono .teams-scrive { background: var(--carta); color: var(--servizio); font-size: .75rem; padding: 0 10px 10px; }
.teams-telefono .teams-compone { display: flex; align-items: center; gap: 10px; padding: 8px; border-top: 1px solid var(--riga); background: var(--bianco); }
.teams-telefono .teams-campo { min-width: 0; flex: 1; border: 1px solid var(--riga); border-radius: 6px; padding: 8px 12px; color: var(--servizio); font-size: .875rem; }
.teams-telefono .teams-invia { flex: none; width: 24px; height: 24px; }
.teams-telefono .teams-invia path { fill: none; stroke: var(--teams-viola); stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.teams-telefono .teams-menu {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 3px;
  padding: 6px 4px 10px;
  border-top: 1px solid var(--riga);
  background: var(--bianco);
  text-align: center;
  font-size: .65625rem;
  color: var(--servizio);
}
.teams-telefono .teams-menu span { min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 3px; }
.teams-telefono .teams-menu .teams-attiva { color: var(--teams-viola); font-weight: 600; }
.teams-telefono .teams-menu svg { flex: none; width: 20px; height: 20px; }
.teams-telefono .teams-menu svg * { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.teams-telefono .teams-menu .teams-attiva svg * { fill: currentColor; fill-opacity: .15; }
.teams-telefono .teams-home { align-self: center; width: 96px; height: 4px; border-radius: 2px; background: var(--notte); margin: 0 auto 1px; }
.teams-schede { grid-area: schede; min-width: 0; display: grid; gap: 16px; }
.teams-scheda {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-content: start;
  align-items: center;
  gap: 14px;
  background: var(--bianco);
  border: 1px solid var(--bordo-a);
  border-radius: var(--raggio-pannello);
  padding: 22px 20px;
  overflow-wrap: anywhere;
  box-shadow: var(--ombra-a);
}
.teams-scheda .teams-titolo { margin: 0; grid-column: 1 / -1; color: var(--notte); font-size: 1.375rem; font-weight: 600; line-height: 1.2; }
.teams-grafico { display: grid; place-items: center; width: 100%; max-width: 220px; justify-self: center; min-width: 0; }
.teams-grafico svg { display: block; width: 100%; max-width: 250px; height: auto; }
.teams-scheda ul { min-width: 0; list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: 1rem; color: var(--servizio); }
.teams-scheda li { min-width: 0; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 12px; }
.teams-importo { color: var(--notte); font-weight: 600; }
.teams-scheda li > span:first-child { min-width: 0; display: inline-flex; align-items: center; gap: 10px; }
.teams-campione { flex: none; width: 12px; height: 12px; border-radius: 4px; background: var(--azzurro); }
.teams-campione.teams-primo { background: var(--notte); }
.teams-campione.teams-terzo { background: var(--ruolo); }
.teams-barra-grafico { fill: var(--notte); }
.teams-barra-grafico.teams-seconda { fill: var(--ruolo); }
.teams-arco { fill: none; stroke-width: 15; stroke: var(--notte); }
.teams-arco.teams-arco-due { stroke: var(--azzurro); }
.teams-arco.teams-arco-tre { stroke: var(--ruolo); }
.teams-avviso { font-size: .90625rem; color: var(--servizio); margin-top: 22px; }
@media (min-width: 768px) {
  .teams-scena { grid-template-columns: 330px minmax(0, 1fr); grid-template-areas: "telefono schede"; gap: 24px; margin-top: 40px; }
  /* 17/11/2026 (Giada): le schede prendono l'altezza del loro contenuto (prima si stiravano fino a quella del telefono, con un vuoto sotto i grafici); il gruppo resta centrato accanto al telefono. */
  .teams-schede { grid-template-rows: auto; align-content: center; gap: 24px; }
  .teams-scheda { padding: 28px 24px; }
}
@media (min-width: 1200px) {
  .teams-scheda { grid-template-columns: minmax(0, 260px) minmax(0, 1fr); gap: 6px 40px; padding: 28px 36px; }
  .teams-grafico { max-width: 250px; }
}
