/* Public team match sheet: shared by canonical and legacy results views. */
.team-acta-dialog {
  width: min(920px, calc(100vw - 2rem));
  border-radius: 16px;
  background: #fff;
  color: #23342d;
  box-shadow: 0 28px 90px rgb(16 40 28 / 26%);
}
.team-acta-dialog::backdrop { background: rgb(16 30 24 / 58%); }
.team-acta-dialog .team-acta-shell { padding: 0; gap: 0; }
.team-acta-dialog .team-acta-heading {
  align-items: center;
  padding: 18px 24px;
  border-bottom: 1px solid #dde8e1;
  background: #f3f8f5;
}
.team-acta-dialog .team-acta-heading h2 { color: #234d38; font-size: 1.12rem; }
.team-acta-dialog #teamActaCode { margin-top: 4px; color: #627569; font-size: .78rem; }
.team-acta-dialog .team-acta-close {
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  border: 1px solid #dce7df;
  border-radius: 50%;
  background: #fff;
  color: #335844;
}
.team-acta-dialog .team-acta-close:hover { background: #e4f0e8; }
.team-acta-dialog .team-acta-close:focus-visible { outline: 2px solid #2f7650; outline-offset: 3px; }
.team-acta-dialog #teamActaContent { padding: 24px; }
.team-acta-dialog .team-acta-summary {
  grid-template-columns: minmax(0, 1fr) 112px minmax(0, 1fr);
  gap: 12px 20px;
  margin-bottom: 24px;
  padding: 22px 18px;
  border: 1px solid #d9e7de;
  border-radius: 12px;
  background: linear-gradient(120deg, #edf6f0, #f8fbf9);
}
.team-acta-dialog .team-acta-summary .team-acta-team { display:flex; align-items:center; gap:10px; min-width:0; }
.team-acta-dialog .team-acta-summary .team-acta-team-left { justify-content:flex-end; }
.team-acta-dialog .team-acta-summary .team-acta-team-right { justify-content:flex-start; }
.team-acta-dialog .team-acta-summary .team-acta-team strong { min-width:0; line-height:1.4; overflow-wrap:anywhere; font-size:1rem; }
.team-acta-dialog .team-acta-summary .team-left { min-width:0; overflow-wrap:anywhere; text-align:right; }
.team-acta-dialog .team-acta-summary .team-right { min-width:0; overflow-wrap:anywhere; text-align:left; }
.team-acta-dialog .team-acta-crest { display:grid; place-items:center; width:2.5rem; height:2.5rem; flex:0 0 2.5rem; overflow:hidden; box-sizing:border-box; border:1px solid #d0dfd5; border-radius:50%; background:#fff; }
.team-acta-dialog .team-acta-crest img { display:block; width:100%; height:100%; border-radius:50%; object-fit:contain; }
.team-acta-dialog .team-acta-summary .winner-name { color: #21613d; }
.team-acta-dialog .team-acta-score { min-width: 0; }
.team-acta-dialog .team-acta-score-label {
  display: block;
  margin-bottom: 6px;
  color: #5a7062;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.team-acta-dialog .team-acta-score > strong {
  margin-bottom: 7px;
  padding: 5px 14px;
  border: 1px solid #d6e5db;
  border-radius: 10px;
  background: #fff;
  color: #204c34;
  font-size: 2.1rem;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}
.team-acta-dialog .team-acta-score small { color: #506658; font-size: .76rem; }
.team-acta-dialog .team-acta-score small { white-space: normal; }
.team-acta-dialog .team-acta-resolution {
  grid-column: 1 / -1;
  min-width: 0;
  padding-top: 10px;
  border-top: 1px solid #d9e7de;
  color: #506658;
  text-align: center;
  line-height: 1.5;
  white-space: normal;
  overflow-wrap: anywhere;
}
.team-acta-dialog .team-acta-resolution .team-result-tiebreak { margin: 0; font-size: .76rem; opacity: 1; }
.team-acta-dialog .team-acta-resolution strong { display: inline; font-size: inherit; }
.team-acta-dialog .team-acta-table-wrap { border: 1px solid #dce6df; border-radius: 10px; }
.team-acta-dialog .team-acta-table { min-width: 600px; table-layout: fixed; }
.team-acta-dialog .team-acta-table th,
.team-acta-dialog .team-acta-table td { padding: 12px 14px; border-bottom-color: #e0e8e3; overflow-wrap: anywhere; }
.team-acta-dialog .team-acta-table th { background: #eaf2ed; color: #355441; font-size: .78rem; font-weight: 700; }
.team-acta-dialog .team-acta-table th:first-child { width: 60px; }
.team-acta-dialog .team-acta-table th:nth-child(3) { width: 110px; }
.team-acta-dialog .team-acta-table th:nth-child(2),
.team-acta-dialog .team-acta-table td:nth-child(2) { text-align:right; }
.team-acta-dialog .team-acta-table td { background: #fff; font-size: .9rem; }
.team-acta-dialog .team-acta-table .board-even td { background: #f5f9f6; }
.team-acta-dialog .team-acta-board-number {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 1px solid #d9e5dd;
  border-radius: 8px;
  background: #eaf2ed;
  color: #3f6150;
  font-size: .82rem;
  font-weight: 700;
}
.team-acta-dialog .team-acta-board-score > strong {
  display: inline-block;
  min-width: 52px;
  padding: 4px 8px;
  border: 1px solid #dfe8e2;
  border-radius: 6px;
  background: #fff;
  color: #233d2e;
  font-size: 1rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.team-acta-dialog .team-acta-period { margin-bottom: 5px; color: #607668; font-size: .65rem; letter-spacing: .03em; }
.team-acta-dialog .team-acta-second-row td { border-top: 1px dashed #d9e5dd; }
/* One board, one row: the final player/score leads; substitutions stay secondary. */
.team-acta-dialog .team-acta-player-final { display:block; font-weight:700; line-height:1.4; }
.team-acta-dialog .team-acta-player-change,
.team-acta-dialog .team-acta-half-score { display:block; margin-top:4px; color:#6b7c71; font-size:.7rem; font-weight:400; line-height:1.4; }
.team-acta-dialog .team-acta-half-score { white-space:nowrap; font-variant-numeric:tabular-nums; }
.team-acta-dialog .team-acta-table tr:last-child td { border-bottom: 0; }
@media (max-width: 600px) {
  .team-acta-dialog { width: calc(100vw - 1rem); max-height: calc(100dvh - 1rem); border-radius: 12px; }
  .team-acta-dialog .team-acta-heading { padding: 12px 14px; }
  .team-acta-dialog .team-acta-heading h2 { font-size: 1rem; }
  .team-acta-dialog #teamActaContent { padding: 14px; }
  .team-acta-dialog .team-acta-summary { grid-template-columns: minmax(0, 1fr) 86px minmax(0, 1fr); gap: 10px; padding: 16px 10px; margin-bottom: 16px; }
  .team-acta-dialog .team-acta-summary .team-acta-team { flex-direction: column; gap:6px; text-align: center; }
  .team-acta-dialog .team-acta-summary .team-left,
  .team-acta-dialog .team-acta-summary .team-right { text-align: center; }
  .team-acta-dialog .team-acta-team-right .team-acta-crest { order: -1; }
  .team-acta-dialog .team-acta-summary .team-acta-team strong,
  .team-acta-dialog .team-acta-summary > .team-left,
  .team-acta-dialog .team-acta-summary > .team-right { font-size: .83rem; }
  .team-acta-dialog .team-acta-crest { width:2rem; height:2rem; flex-basis:2rem; }
  .team-acta-dialog .team-acta-score { min-width: 0; }
  .team-acta-dialog .team-acta-score > strong { font-size: 1.7rem; padding: 5px 8px; }
}

.team-acta-dialog .team-acta-shell { grid-template-columns: minmax(0, 1fr); min-width: 0; }
.team-acta-dialog #teamActaContent,
.team-acta-dialog .team-acta-heading > div { min-width: 0; }
.team-acta-dialog .team-acta-table th:first-child { width: 76px; white-space: nowrap; }
@media (max-width: 600px) {
  .team-acta-dialog .team-acta-table { min-width: 0; }
  .team-acta-dialog .team-acta-table th,
  .team-acta-dialog .team-acta-table td { padding: 10px 6px; font-size: .8rem; }
  .team-acta-dialog .team-acta-table th:first-child { width: 48px; }
  .team-acta-dialog .team-acta-table th:nth-child(3) { width: 62px; }
  .team-acta-dialog .team-acta-board-number { width: 24px; height: 24px; }
  .team-acta-dialog .team-acta-board-score > strong { min-width: 36px; padding: 4px; font-size: .88rem; }
  .team-acta-dialog .team-acta-period { font-size: .6rem; }
}
@media (max-width: 600px) {
  .team-acta-dialog .team-acta-table th:nth-child(3) { font-size: .7rem; white-space: nowrap; }
}

.team-acta-dialog .team-acta-title-line { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.team-acta-live-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 9px;
  border: 1px solid #c6dfce;
  border-radius: 999px;
  background: #edf7f0;
  color: #226b40;
  font-size: .72rem;
  font-weight: 800;
  line-height: 1.25;
  text-transform: uppercase;
}
.team-acta-live-status[hidden] { display: none; }
.team-acta-live-status::before {
  content: '';
  width: 6px;
  height: 6px;
  flex: 0 0 6px;
  border-radius: 50%;
  background: #2b8a50;
  animation: public-acta-status-pulse 2.4s ease-out infinite;
}
@keyframes public-acta-status-pulse {
  0% { box-shadow: 0 0 0 0 rgb(43 138 80 / 35%); opacity: 1; }
  65% { box-shadow: 0 0 0 5px rgb(43 138 80 / 0%); opacity: .75; }
  100% { box-shadow: 0 0 0 5px rgb(43 138 80 / 0%); opacity: 1; }
}
@media (prefers-reduced-motion: reduce) { .team-acta-live-status::before { animation: none; } }

.team-acta-dialog .team-acta-score-updated {
  animation: public-acta-score-update 1s ease-in-out 10;
  border-radius: 6px;
}
@keyframes public-acta-score-update {
  0%, 100% { background-color: transparent; box-shadow: 0 0 0 0 transparent; }
  50% { background-color: #d4efdc; box-shadow: 0 0 0 3px rgb(63 145 85 / 18%); }
}
@media (prefers-reduced-motion: reduce) {
  .team-acta-dialog .team-acta-score-updated { animation: public-acta-score-fade 10s linear 1; }
}
@keyframes public-acta-score-fade {
  0%, 80% { background-color: #d4efdc; }
  100% { background-color: transparent; }
}

.team-acta-dialog .team-acta-referee { margin-top: 16px; color: #71717a; font-size: .75rem; line-height: 1.4; overflow-wrap: anywhere; }

.team-acta-dialog .team-acta-table-wrap[hidden] { display: none; }
.team-acta-dialog .team-acta-withdrawal-notice { margin: 0; color: #627569; font-size: .8rem; line-height: 1.5; text-align: center; overflow-wrap: anywhere; }
/* The same acta content can also be opened from a team recap on statistics. */
.team-recap-acta{padding:0;min-width:0;max-height:calc(100dvh - 28px);overflow:auto}
.team-recap-acta .team-acta-heading{display:flex;justify-content:space-between;gap:16px;margin:0;box-shadow:none;border-radius:0}
.team-recap-acta .team-acta-heading h2{margin:0}.team-recap-acta .team-acta-close{padding:0;margin:0;font-size:26px;cursor:pointer;box-shadow:none}
.team-recap-acta .team-acta-content{padding:24px}.team-recap-acta .team-acta-summary{display:grid;align-items:center}.team-recap-acta .team-acta-score{display:flex;flex-direction:column;align-items:center;text-align:center}
.team-recap-acta .team-acta-table-wrap{overflow:auto}.team-recap-acta .team-acta-table{width:100%;border-collapse:collapse}.team-recap-acta .team-acta-table th,.team-recap-acta .team-acta-table td{border-bottom:1px solid #e0e8e3;text-align:center}
.team-recap-acta .winner-name{color:#166534;font-weight:800}.team-recap-acta .team-acta-board-score small,.team-recap-acta .team-acta-player-change{display:block;font-size:.68rem;color:#738378;margin-top:4px}.team-recap-acta .team-acta-referee{margin-top:10px;text-align:right;color:#89968e;font-size:.7rem}
@media(max-width:600px){.team-recap-acta{width:calc(100vw - 14px)}.team-recap-acta .team-acta-content{padding:14px}}
