/* ===== cards.css — Cards de animal/buff, slots de time, grade de posicao, bestiario, placares =====
   Gerado por tools/split-css-modules.mjs (Fase B-CSS). Nao editar a divisao manualmente sem
   reconferir a cascata. Ver VaultBrain/Brain/Padroes/Padroes CSS.md ===== */
.pick-grid .animal-card:nth-child(-n + 3) {
  top: -37px;
}
.pick-grid .animal-card:nth-child(n + 4):nth-child(-n + 6) {
  top: -28px;
}
.pick-grid .animal-card:nth-child(n + 7):nth-child(-n + 9) {
  top: -19px;
}
.pick-grid .animal-card:nth-child(n + 10):nth-child(-n + 12) {
  top: -10px;
}
.animal-card {
  background: none;
  border: none;
  border-radius: var(--radius-lg);
  padding: 0;
  text-align: center;
  cursor: pointer;
  transition: all 0.15s;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: none;
  aspect-ratio: 1/1;
  width: 100%;
  height: auto;
}
.animal-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('../img/slots.webp') center/100% 100% no-repeat;
  opacity: 1;
  border-radius: var(--radius-lg);
  pointer-events: none;
  z-index: var(--z-base);
}
.animal-card.cant-buy::before {
  filter: grayscale(35%) brightness(0.85);
  opacity: 0.9;
}
.animal-card:active {
  transform: scale(0.95);
}
.animal-card.selected {
  border-color: var(--accent);
  background: rgba(var(--accent-rgb), 0.12);
}
.animal-card.deck-in-team {
  border: 3px solid #ffd700;
  outline: 2px solid #111;
  outline-offset: -1px;
  background: rgba(60, 90, 40, 0.85);
  box-shadow:
    0 0 10px rgba(var(--gold-rgb), 0.6),
    0 0 20px rgba(var(--gold-rgb), 0.25),
    inset 0 0 6px rgba(var(--gold-rgb), 0.15);
  animation: deck-team-glow 1.8s ease-in-out infinite alternate;
}
.animal-card.disabled {
  opacity: 0.7;
  pointer-events: none;
}
.animal-emoji {
  font-size: clamp(21px, 8.99vw, 39px);
  line-height: 1;
}
.animal-name {
  font-size: clamp(8px, 2.37vw, 11px);
  font-weight: 700;
  color: #2a3a20;
  position: absolute;
  bottom: 5px;
  left: 0;
  right: 0;
  text-align: center;
  line-height: 1;
  pointer-events: none;
  text-shadow: 0 0 3px rgba(var(--white-rgb), 0.6);
}
.animal-cost {
  position: absolute;
  top: 3px;
  right: 8px;
  width: auto;
  height: auto;
  border-radius: 0;
  background: none;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  box-shadow: none;
  border: none;
  font-size: clamp(8px, 2.37vw, 11px);
  font-weight: 900;
  color: #e6b800;
  text-shadow:
    0 1px 3px rgba(var(--black-rgb), 0.9),
    -1px -1px 0 rgba(var(--black-rgb), 0.6),
    1px -1px 0 rgba(var(--black-rgb), 0.6);
}
.animal-star {
  position: absolute;
  top: 2px;
  right: 4px;
  font-size: 10px;
}
.team-bar {
  background: transparent;
  padding: 4px clamp(8px, 3vw, 12px);
  flex-shrink: 0;
}
.team-title {
  font-size: 10px;
  color: var(--text2);
  font-weight: 700;
  margin-bottom: 5px;
  display: flex;
  justify-content: space-between;
}
.team-slots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 0 clamp(6px, 2vw, 12px);
}
.team-slot {
  width: 100%;
  aspect-ratio: 1/1;
  border-radius: var(--radius-sm);
  background: radial-gradient(
    circle at 50% 45%,
    rgba(240, 255, 240, 0.15) 0%,
    rgba(160, 200, 160, 0.08) 80%,
    rgba(130, 175, 130, 0.05) 100%
  );
  border: 2px dashed rgba(138, 175, 106, 0.25);
  overflow: visible;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: clamp(14px, 4.5vw, 22px);
  cursor: pointer;
  position: relative;
}
.team-slot.filled {
  border-color: var(--accent2);
  border-style: solid;
  width: 100%;
  aspect-ratio: 1/1;
}
.tournament-bracket {
  padding: 6px 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  overflow-y: auto;
}
.bracket-round {
  background: var(--surface);
  border-radius: var(--radius-xl);
  padding: 8px 10px;
  border: 1px solid var(--surface2);
}
.bracket-round-title {
  font-family: 'Righteous', cursive;
  font-size: 11px;
  color: var(--text2);
  letter-spacing: 2px;
  margin-bottom: 6px;
}
.bracket-matchup {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 0;
}
.bracket-player {
  flex: 1;
  background: var(--surface2);
  border-radius: var(--radius-md);
  padding: 5px 8px;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 5px;
}
.bracket-player.is-you {
  border: 1.5px solid var(--accent);
  background: rgba(var(--accent-rgb), 0.1);
}
.bracket-player.winner {
  border: 1.5px solid var(--green);
  background: rgba(var(--green-rgb), 0.08);
}
.bracket-player.loser {
  opacity: 0.45;
}
.bracket-vs {
  font-size: 10px;
  color: var(--text2);
  font-weight: 800;
}
.bracket-result {
  font-size: 10px;
  font-weight: 800;
  min-width: 30px;
  text-align: center;
}
.standings-table {
  background: linear-gradient(135deg, rgba(var(--surface-rgb), 0.95), rgba(20, 32, 52, 0.95));
  border-radius: var(--radius-xl);
  margin: 0 10px;
  overflow: hidden;
  border: 1.5px solid rgba(var(--white-rgb), 0.08);
  box-shadow: 0 2px 10px rgba(var(--black-rgb), 0.25);
}
.standings-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border-bottom: 1px solid var(--surface2);
  font-size: 12px;
}
.standings-row:last-child {
  border-bottom: none;
}
.standings-row.you {
  background: rgba(var(--accent-rgb), 0.08);
}
.standings-rank {
  font-family: 'Righteous', cursive;
  font-size: 14px;
  color: var(--text2);
  width: 18px;
}
.standings-emoji {
  font-size: 18px;
}
.standings-name {
  flex: 1;
  font-weight: 700;
}
.standings-score {
  font-family: 'Righteous', cursive;
  font-size: 14px;
  color: var(--green);
}
.standings-wl {
  font-size: 10px;
  color: var(--text2);
}
.next-match-banner {
  margin: 8px 10px;
  background: linear-gradient(135deg, rgba(var(--accent-rgb), 0.15), rgba(232, 93, 117, 0.15));
  border: 1.5px solid var(--accent);
  border-radius: var(--radius-xl);
  padding: 8px 12px;
  text-align: center;
}
.next-match-label {
  font-size: 10px;
  color: var(--text2);
  letter-spacing: 2px;
  margin-bottom: 4px;
}
.next-match-vs {
  font-family: 'Righteous', cursive;
  font-size: 16px;
  color: var(--text);
}
.next-match-vs span {
  color: var(--accent);
}
.round-indicator {
  display: flex;
  gap: 4px;
  justify-content: center;
  padding: 4px 0 6px;
}
.round-dot {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-circle);
  background: var(--surface2);
  transition: all 0.3s;
}
.round-dot.done {
  background: var(--green);
}
.round-dot.current {
  background: var(--accent);
  box-shadow: 0 0 6px var(--accent);
}
.buff-grid {
  display: none;
}
.buff-card {
  background: transparent;
  border: 1.5px solid transparent;
  border-radius: var(--radius-lg);
  padding: 6px 8px;
  cursor: pointer;
  transition:
    border 0.15s,
    box-shadow 0.15s;
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
  position: absolute;
  width: fit-content;
  max-width: 220px;
}
.buff-card:active {
  transform: scale(0.97);
}
.buff-card.selected {
  border-color: var(--accent);
  background: transparent;
  box-shadow: 0 0 14px rgba(var(--accent-rgb), 0.5);
}
.buff-animals {
  display: flex;
  gap: 0;
  flex-wrap: nowrap;
  width: 100%;
  justify-content: center;
  overflow: hidden;
}
.buff-animal-chip {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border-radius: var(--radius-sm);
  font-size: 30px;
  padding: 4px 0;
  min-width: 0;
}
.buff-bonus {
  font-size: 11px;
  font-weight: 700;
  color: var(--text);
  background: transparent;
  padding: 4px 6px;
  border-radius: var(--radius-md);
  text-align: center;
  border: none;
}
.buff-log {
  margin: 2px 6px;
  background: linear-gradient(135deg, rgba(18, 40, 18, 0.95), rgba(12, 30, 12, 0.95));
  border: 1px solid rgba(100, 140, 80, 0.2);
  border-radius: var(--radius-lg);
  padding: 4px 6px;
  font-size: 10px;
  flex-shrink: 0;
  max-height: 150px;
  overflow-y: auto;
  box-shadow:
    inset 0 1px 1px rgba(var(--white-rgb), 0.04),
    0 2px 6px rgba(var(--black-rgb), 0.2);
}
.buff-log-title {
  font-weight: 800;
  color: var(--text2);
  margin-bottom: 3px;
}
.buff-log-row {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 1px 0;
  border-bottom: 1px solid var(--surface2);
}
.buff-log-row:last-child {
  border-bottom: none;
}
.pos-info {
  text-align: center;
  font-size: 11px;
  color: var(--text2);
  padding: 3px 0;
  flex-shrink: 0;
}
.pos-area {
  display: flex;
  flex-direction: column;
  padding: 4px;
  flex-shrink: 0;
}
.pos-grid-wrap {
  position: relative;
  clip-path: inset(-999px);
}
.pos-row {
  display: contents;
}
.pos-row-label {
  display: none;
}
.pos-grid-wrap {
  position: relative;
}
.pos-stake {
  position: absolute;
  width: 18px;
  height: 18px;
  z-index: var(--z-behind);
  pointer-events: none;
  transform: translate(-50%, -50%);
  background: url('../img/estaca.webp') center/contain no-repeat;
  opacity: 0.9;
}
.pos-cell {
  background: transparent;
  border: none;
  border-radius: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  cursor: pointer;
  transition: all 0.15s;
  position: absolute;
  overflow: visible;
  clip-path: inset(-999px);
}
.pos-cell.filled {
  background: transparent;
}
.pos-cell.pos-cell-solo {
  background: radial-gradient(
    ellipse at center,
    rgba(255, 210, 90, 0.32) 0%,
    rgba(255, 195, 70, 0.16) 70%,
    transparent 100%
  );
  outline: 2px solid rgba(255, 205, 80, 0.9);
  outline-offset: -2px;
  border-radius: 5px;
  box-shadow:
    inset 0 0 12px rgba(255, 200, 70, 0.45),
    0 0 8px rgba(255, 200, 70, 0.4);
}
.pos-cell.selected {
  background: rgba(40, 140, 230, 0.32);
  box-shadow: 0 0 10px rgba(80, 170, 255, 0.7);
  outline: 2px solid rgba(80, 170, 255, 0.95);
  outline-offset: -2px;
  border-radius: 4px;
}
.pos-cell.target {
  animation: pulse-cell 0.7s infinite alternate;
  outline: 1.5px solid rgba(180, 140, 15, 0.85);
  outline-offset: -1px;
  border-radius: 3px;
  box-shadow: inset 0 0 8px rgba(180, 140, 15, 0.2);
}
.pos-cell.alfa-target {
  background: rgba(var(--gold-rgb), 0.08);
}
.pos-cell .cell-name {
  font-size: min(9px, 2.2vw);
  color: var(--text2);
  font-weight: 700;
  line-height: 1;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 0 2px;
}
.pos-cell .cell-star {
  position: absolute;
  top: 1px;
  right: 3px;
  font-size: 8px;
}
.animal-card {
  border-radius: var(--radius-xl);
  padding: clamp(3px, 1.5vw, 6px) clamp(2px, 1vw, 3px) clamp(2px, 1vw, 4px);
  gap: 2px;
  overflow: hidden;
  aspect-ratio: 1;
}
.animal-card[data-cost='1'] {
  border-color: #9aaa96 #6e8268 #5a7052 #8a9e86;
}
.animal-card[data-cost='2'] {
  border-color: #5ea86e #3a7a48 #2d6638 #4e9660;
}
.animal-card[data-cost='3'] {
  border-color: #5a8abf #3a6090 #2c4e7a #4a78aa;
}
.animal-card[data-cost='4'] {
  border-color: #9a6ad0 #7040a0 #5c3088 #8858c0;
}
.animal-card[data-cost='5'] {
  border-color: #c8982a #9a7018 #7a5810 #b08822;
}
.animal-card[data-cost='1'].selected {
  box-shadow:
    0 0 12px rgba(170, 184, 200, 0.4),
    inset 0 1px 2px rgba(var(--white-rgb), 0.5);
}
.animal-card[data-cost='2'].selected {
  box-shadow:
    0 0 14px rgba(var(--green-rgb), 0.4),
    inset 0 1px 2px rgba(var(--white-rgb), 0.5);
}
.animal-card[data-cost='3'].selected {
  box-shadow:
    0 0 14px rgba(74, 168, 245, 0.4),
    inset 0 1px 2px rgba(var(--white-rgb), 0.5);
}
.animal-card[data-cost='4'].selected {
  box-shadow:
    0 0 14px rgba(var(--purple-rgb), 0.4),
    inset 0 1px 2px rgba(var(--white-rgb), 0.5);
}
.animal-card[data-cost='5'].selected {
  box-shadow:
    0 0 16px rgba(var(--accent-rgb), 0.5),
    inset 0 1px 2px rgba(var(--white-rgb), 0.5);
}
.animal-card.selected::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    115deg,
    transparent 20%,
    rgba(var(--white-rgb), 0.12) 50%,
    transparent 80%
  );
  background-size: 200% 200%;
  animation: card-shimmer 2.5s ease-in-out infinite;
}
.animal-name {
  font-size: clamp(8px, 2.37vw, 11px);
  letter-spacing: 0.3px;
  color: #2a3a20;
  text-shadow: 0 0 3px rgba(var(--white-rgb), 0.6);
}
.animal-cost {
  font-size: clamp(11px, 3.67vw, 14px);
  font-weight: 900;
  letter-spacing: 0.5px;
}
.team-slot.filled {
  border: none;
  background: none;
  box-shadow: none;
  width: 100%;
  aspect-ratio: 1/1;
}
.team-bar {
  border-top: none;
  background: transparent;
  padding: 4px clamp(8px, 3vw, 12px);
  margin-top: -50px;
}
#btn-buff-confirm:disabled {
  opacity: 0.4;
  pointer-events: none;
}
#btn-buff-confirm:not(:disabled) {
  opacity: 1;
  pointer-events: auto;
}
.animal-card.cant-buy {
  opacity: 0.88;
}
.buff-card {
  background: transparent;
  border: 1.5px solid transparent;
  border-radius: var(--radius-lg);
  padding: 6px 8px;
  cursor: pointer;
  transition:
    border 0.15s,
    box-shadow 0.15s;
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
  position: absolute;
  width: fit-content;
  max-width: 220px;
}
.buff-card.selected {
  border-color: transparent;
  box-shadow: none;
}
.buff-animal-chip {
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border-radius: var(--radius-sm);
  font-size: 44px;
  padding: 4px 2px;
  min-width: 0;
}
.buff-bonus {
  font-size: 10px;
  font-weight: 700;
  color: #2a1505;
  padding: 2px 6px;
  text-align: center;
  background: transparent;
  border: none;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.25;
}
.bracket-round {
  box-shadow: 0 2px 10px rgba(var(--black-rgb), 0.25);
  border: 1px solid rgba(var(--white-rgb), 0.06);
}
.bracket-player.is-you {
  box-shadow: 0 0 14px rgba(var(--accent-rgb), 0.18);
}
.bracket-player.winner {
  box-shadow: 0 0 10px rgba(var(--green-rgb), 0.12);
}
.next-match-banner {
  background: linear-gradient(135deg, rgba(var(--accent-rgb), 0.12), rgba(232, 93, 117, 0.12));
  box-shadow: 0 0 18px rgba(var(--accent-rgb), 0.15);
  border: 1.5px solid rgba(var(--accent-rgb), 0.2);
}
.pos-cell {
  transition: all 0.18s;
}
.pos-cell-locked {
  opacity: 0.22;
  cursor: not-allowed !important;
  pointer-events: none;
  background: repeating-linear-gradient(
    45deg,
    rgba(255, 0, 0, 0.07) 0px,
    rgba(255, 0, 0, 0.07) 4px,
    transparent 4px,
    transparent 8px
  ) !important;
  border: 1px dashed rgba(255, 60, 60, 0.25) !important;
}
.pos-grid-wrap.show-slots .pos-cell {
  border: none !important;
  background: transparent !important;
  box-shadow: none !important;
}
#buff-screen {
  background: transparent;
  position: relative;
  overflow: visible;
}
