/* ---------------------------------------------------------- escolha do canal */
.pick {
  min-height: 100%;
  display: flex;
  flex-direction: column;
  padding: max(26px, env(safe-area-inset-top)) 0 max(18px, env(safe-area-inset-bottom));
  max-width: 600px;
  margin: 0 auto;
}
.pick-head { padding: 0 20px 22px; }
.event-name { margin: 0 0 14px; padding-bottom: 12px; border-bottom: var(--line); color: var(--signal-text); font-size: var(--t-sm); font-weight: 700; }
.event-name:empty { display: none; }
.pick h1 { margin: 0; font-size: var(--t-3xl); }
.pick h1 span { display: block; color: var(--dim); }

/* cada canal é uma placa: número à esquerda, nome grande, cor chapada */
.channel {
  flex: 1;
  min-height: 170px;
  display: flex;
  align-items: stretch;
  gap: 0;
  padding: 0;
  border: 0;
  text-align: left;
  color: #fff;
}
.channel + .channel { border-top: 4px solid var(--bg); }
.channel[data-lang="pt"] { background: var(--pt); }
.channel[data-lang="es"] { background: var(--es); }
.channel .ch-num { width: auto; height: auto; aspect-ratio: auto; padding: 0 18px; font-size: var(--t-4xl); background: rgb(14 26 51 / .28); color: #fff; place-items: start center; padding-top: 18px; }
.channel-text { display: flex; flex-direction: column; justify-content: flex-end; gap: 8px; padding: 18px 20px 22px; }
.channel-name { font-size: clamp(3rem, 15vw, 4.5rem); }
.channel-desc { font-size: var(--t-md); max-width: 22em; }
.channel:active { filter: brightness(.92); }
.pick-foot { margin: 0; padding: 16px 20px 0; color: var(--dim); font-size: var(--t-sm); }
.pick-foot span { display: block; }

/* ---------------------------------------------------------- ouvindo */
.room { height: 100%; display: flex; flex-direction: column; --chan: var(--pt); }
.room.es { --chan: var(--es); }

.room-bar {
  background: var(--surface);
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  border-bottom: var(--line);
  padding-top: env(safe-area-inset-top);
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 0 18px 0 0;
  height: 58px;
  border: 0;
  background: var(--chan);
  color: #fff;
}
.chip .ch-num { height: 100%; width: 54px; font-size: var(--t-xl); background: rgb(14 26 51 / .28); color: #fff; }
.chip .sign { font-size: var(--t-2xl); }
.chip .eq { color: #fff; }
.state { display: flex; align-items: center; gap: 9px; padding: 0 16px; font-size: var(--t-sm); color: var(--dim); white-space: nowrap; }

/* aviso = placa amarela de sinalização */
.notice { margin: 0; padding: 12px 16px; background: var(--signal); color: var(--navy); font-size: var(--t-sm); line-height: 1.4; }
.notice b { font-weight: 800; }

.room .captions { flex: 1; padding: 24px 16px 32px; }
.src-quote { font-size: var(--t-sm); color: var(--dim); padding: 4px 0 4px 18px; max-width: 34em; border-top: 1px solid var(--rule); }
.src-quote:empty { display: none; }

/* controles: uma régua de botões quadrados */
.room-controls {
  display: flex;
  align-items: stretch;
  border-top: var(--line);
  padding-bottom: env(safe-area-inset-bottom);
  background: var(--surface);
}
.ctl {
  min-width: 58px;
  height: 58px;
  padding: 0 14px;
  border: 0;
  background: transparent;
  color: var(--text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
#muteBtn { border-right: var(--line); }
#sizeBtn, #srcBtn, #themeBtn { border-left: var(--line); }
.ctl.text { font-size: var(--t-sm); font-weight: 700; }
.ctl[aria-pressed="true"] { background: var(--text); color: var(--bg); }
#muteBtn[aria-pressed="true"] { background: var(--alert); color: var(--navy); }
.ctl .aa { font-family: var(--display); font-stretch: 80%; font-weight: 800; font-size: 20px; }
.ctl .aa small { font-size: 13px; }
.room-controls input[type=range] { flex: 1; min-width: 60px; margin: 0 14px; accent-color: var(--chan); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* toque para reativar o som */
.tap { position: fixed; inset: 0; z-index: 10; display: grid; place-items: center; padding: 30px; background: color-mix(in srgb, var(--bg) 94%, transparent); }
.tap button { padding: 22px 30px; border: 0; background: var(--signal); color: var(--navy); font-size: var(--t-lg); font-weight: 800; }

/* ---------------------------------------------------------- telão (/tela) */
body.tela .room-bar, body.tela .room-controls, body.tela .notice { display: none; }
body.tela .room .captions { --cap-size: clamp(2rem, 4.6vw, 4.6rem); justify-content: flex-end; padding: 5vh 6vw; overflow: hidden; }
body.tela .captions .line { max-width: none; color: color-mix(in srgb, var(--text) 40%, transparent); border-left-width: 8px; padding-left: .5em; }
body.tela .captions .line.latest, body.tela .captions .line.partial { color: var(--text); }

@media (min-width: 720px) {
  .pick { justify-content: center; }
  .channel { flex: none; min-height: 200px; }
  .room .captions { padding: 32px max(24px, calc((100% - 880px) / 2)); }
}
