/* Estilos específicos de tela. Componentes genéricos ficam em ds.css. */

.topbar .chan-btn {
  max-width: 200px;
  padding: 0 10px 0 6px;
  gap: 8px;
  border-radius: var(--r-full);
  height: 46px;
  background: var(--card);
  box-shadow: var(--rim), var(--shadow);
}
.topbar .chan-btn svg {
  width: 14px;
  height: 14px;
  color: var(--muted);
}
.topbar .btn.icon,
.topbar .btn.primary {
  height: 46px;
  border-radius: 13px;
}
.topbar .btn.icon {
  width: 46px;
  background: var(--card);
  box-shadow: var(--rim), var(--shadow);
}
.tile.sm {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  font-size: 11px;
}
.avatar-btn {
  width: 46px;
  height: 46px;
  border: 0;
  cursor: pointer;
  font-size: var(--fs-md);
  box-shadow:
    0 0 0 2px var(--bg),
    0 0 0 3px var(--line-2);
}
@media (max-width: 760px) {
  .brand-name,
  .hide-sm {
    display: none;
  }
  .topbar {
    gap: 10px;
  }
  .topbar .chan-btn {
    max-width: 130px;
  }
}

/* miniaturas e player */
.thumb {
  width: 36px;
  aspect-ratio: 9 / 16;
  border-radius: 7px;
  overflow: hidden;
  background: var(--card-3);
  display: grid;
  place-items: center;
  flex: none;
  color: var(--faint);
}
.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.thumb svg {
  width: 16px;
  height: 16px;
}
.thumb.lg {
  width: 100%;
  border-radius: var(--r-md);
}
.player {
  display: grid;
  place-items: center;
  background: #000;
  border-radius: var(--r-md);
  overflow: hidden;
}
.player video {
  max-height: min(68vh, 760px);
  width: auto;
  max-width: 100%;
}

/* rosca e legenda */
.ring {
  position: relative;
  flex: none;
}
.ring-c {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  text-align: center;
}
.ring-c b {
  font-size: 34px;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1;
}
.ring-c small {
  color: var(--muted);
  font-size: var(--fs-md);
  margin-top: 4px;
}
.legend {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px 22px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
.legend span {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink-2);
}
.legend i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  flex: none;
}
.legend b {
  margin-left: auto;
  font-weight: 600;
}

/* contagem regressiva */
.countdown {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-top: 16px;
}
.countdown div {
  padding: 12px 6px;
  border-radius: var(--r-md);
  text-align: center;
  box-shadow: var(--rim);
  background: var(--card-2);
}
.countdown b {
  display: block;
  font-size: var(--fs-4xl);
  font-weight: 600;
  line-height: 1.1;
}
.countdown small {
  color: var(--muted);
  font-size: var(--fs-2xs);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
}
.countdown .hot b {
  color: var(--accent-text);
}

/* progresso de job */
.jobbox {
  padding: 16px;
  border-radius: var(--r-md);
  background: var(--card-2);
  box-shadow: var(--rim);
}

/* grade de shorts (biblioteca) */
.shorts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 16px;
  padding: 16px;
}
.short-card {
  position: relative;
  border-radius: var(--r-md);
  overflow: hidden;
  background: var(--card-2);
  box-shadow: var(--rim);
  display: flex;
  flex-direction: column;
}
.short-card .cover {
  position: relative;
  aspect-ratio: 9 / 16;
  background: #08090b;
  display: grid;
  place-items: center;
  cursor: pointer;
  border: 0;
  padding: 0;
  width: 100%;
  color: var(--faint);
}
.short-card .cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.short-card .cover svg {
  width: 30px;
  height: 30px;
}
/* Selos sobre a miniatura: o fundo "soft" do .pill é translúcido e some sobre
   imagem escura. Aqui ele vai por cima de uma base sólida da superfície (--card),
   então cor e contraste ficam iguais aos do selo num card comum, nos dois temas. */
.short-card .cover .pill {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 1;
  background: linear-gradient(var(--_b), var(--_b)), var(--card);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
}
.short-card .cover .score {
  position: absolute;
  top: 10px;
  right: 10px;
}
.short-card .cover::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(transparent 55%, rgba(0, 0, 0, 0.7));
  opacity: 0;
  transition: opacity 0.2s;
}
.short-card .cover:hover::after {
  opacity: 1;
}
.short-card .meta {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}
.short-card .meta b {
  font-weight: 600;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.short-card .meta small {
  color: var(--muted);
  font-size: var(--fs-sm);
}
.short-card .acts {
  display: flex;
  gap: 6px;
  padding: 0 12px 12px;
}
.short-card .acts .btn {
  flex: 1;
}
.short-card .acts .btn.icon {
  flex: none;
}

/* revisão */
.review {
  display: grid;
  grid-template-columns: minmax(0, 420px) minmax(0, 1fr);
  gap: var(--gap);
  align-items: start;
}
.review .player video {
  max-height: 72vh;
}
.queue {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 4px 2px 10px;
}
.queue button {
  flex: none;
  width: 54px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  border-radius: 9px;
  opacity: 0.55;
  transition:
    opacity 0.15s,
    box-shadow 0.15s;
}
.queue button:hover {
  opacity: 1;
}
.queue button.on {
  opacity: 1;
  box-shadow:
    0 0 0 2px var(--bg),
    0 0 0 4px var(--accent);
}
.queue .thumb {
  width: 54px;
}
@media (max-width: 980px) {
  .review {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* criar: etapas */
.steps {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: var(--gap);
  align-items: start;
}
.step-n {
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--card-3);
  color: var(--ink-2);
  font-size: var(--fs-xs);
  font-weight: 700;
  flex: none;
}
.step-n.done {
  background: var(--ok-soft);
  color: var(--ok);
}
.step-n.on {
  background: linear-gradient(180deg, var(--accent-from), var(--accent-to));
  color: var(--accent-ink);
}
.src-preview {
  position: relative;
  display: grid;
  place-items: center;
  background: #000;
  border-radius: var(--r-md);
  overflow: hidden;
  min-height: 200px;
}
.src-preview video {
  max-height: 420px;
  max-width: 100%;
}
.choice-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 10px;
}
.choice {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px;
  border: 0;
  text-align: left;
  cursor: pointer;
  border-radius: var(--r-md);
  background: var(--card-2);
  box-shadow: inset 0 0 0 1px var(--line-2);
  color: var(--ink);
  transition:
    box-shadow 0.16s,
    background 0.16s;
}
.choice:hover {
  background: var(--card-3);
}
.choice.on {
  box-shadow: inset 0 0 0 2px var(--accent);
  background: var(--accent-soft);
}
.choice b {
  font-weight: 600;
}
.choice small {
  color: var(--muted);
  font-size: var(--fs-sm);
  line-height: 1.35;
}
.choice .row {
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 6px;
}
@media (max-width: 1180px) {
  .steps {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* celular de prévia */
.phone {
  position: relative;
  width: 100%;
  max-width: 300px;
  margin: 0 auto;
  aspect-ratio: 9 / 16;
  border-radius: 26px;
  overflow: hidden;
  background: #08090b;
  box-shadow:
    0 0 0 6px var(--card-3),
    var(--shadow-lg);
}
.phone > img,
.phone > video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.phone .ph-empty {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  gap: 8px;
  text-align: center;
  padding: 20px;
  color: var(--faint);
  font-size: var(--fs-md);
}
.phone .ph-empty svg {
  margin: 0 auto;
  width: 28px;
  height: 28px;
}
.phone-map {
  container-type: inline-size;
  touch-action: none;
  user-select: none;
}
.phone-map > * {
  position: absolute;
}
.phone-map [data-drag] {
  cursor: grab;
}
.phone-map [data-drag]:active {
  cursor: grabbing;
}
.phone-map [data-drag].sel,
.phone-map [data-drag]:hover {
  outline: 1.5px dashed var(--accent);
  outline-offset: 2px;
}
.phone-map .m-bg {
  pointer-events: none;
}
.phone-map .m-video {
  background: rgba(91, 140, 255, 0.28);
  box-shadow: inset 0 0 0 1.5px var(--accent);
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
}
.phone-map .m-logo {
  height: auto;
}
.phone-map .m-text {
  white-space: nowrap;
  font-weight: 700;
  line-height: 1.15;
  text-align: center;
}
.phone-map .m-cap {
  white-space: normal;
  width: max-content;
}
.phone-map .m-grip {
  position: absolute;
  right: -6px;
  bottom: -6px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 2px var(--accent);
  cursor: nwse-resize;
}
.phone-map .m-grip.side {
  top: calc(50% - 7px);
  bottom: auto;
  cursor: ew-resize;
  opacity: 0;
}
.phone-map .m-cap:hover .m-grip,
.phone-map .m-cap.sel .m-grip {
  opacity: 1;
}
.phone-map .m-guide {
  left: 50%;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--accent);
  pointer-events: none;
}
/* aproximação dos efeitos de texto do render */
.m-text[data-fx='outline'],
.m-text[data-fx='normal'] {
  -webkit-text-stroke: 0.09em #000;
  paint-order: stroke fill;
}
.m-text[data-fx='normal'] {
  -webkit-text-stroke-width: 0.05em;
}
.m-text[data-fx='shadow'] {
  text-shadow: 0.06em 0.06em 0.08em rgba(0, 0, 0, 0.75);
}
.m-text[data-fx='neon'] {
  text-shadow:
    0 0 0.15em currentColor,
    0 0 0.45em currentColor;
}
.m-text[data-fx='sticker'] {
  color: #fff !important;
  -webkit-text-stroke: 0.14em #d232ff;
  paint-order: stroke fill;
  text-shadow: 0 0 0.3em #5a3cff;
}
.m-text[data-fx='fire'] {
  color: #ffd23c !important;
  -webkit-text-stroke: 0.08em #c81e00;
  paint-order: stroke fill;
  text-shadow: 0 0 0.35em #ff5a00;
}
.m-text[data-fx='rainbow_fire'] {
  color: #fff !important;
  -webkit-text-stroke: 0.09em #140c28;
  paint-order: stroke fill;
  animation: fx-flame 2s linear infinite;
}
@keyframes fx-flame {
  0%,
  100% {
    text-shadow:
      0.07em 0.07em 0 #966eff,
      0 -0.22em 0.18em #ff3c3c,
      0.3em -0.3em 0.22em #3cff8c;
  }
  33% {
    text-shadow:
      0.07em 0.07em 0 #966eff,
      0 -0.3em 0.22em #3cc8ff,
      -0.3em -0.2em 0.18em #ffd23c;
  }
  66% {
    text-shadow:
      0.07em 0.07em 0 #966eff,
      0 -0.2em 0.18em #c83cff,
      0.2em -0.32em 0.22em #3cffd2;
  }
}
/* entrada do título (os tempos acompanham o render) */
.m-cap-text .tw {
  visibility: hidden;
}
.m-cap-text .tw.on {
  visibility: visible;
}
.m-cap-text.an-fade,
.m-cap-text.an-slide,
.m-cap-text.an-pop {
  display: inline-block;
  animation: cap-fade 0.5s 0.15s both cubic-bezier(0.22, 1, 0.36, 1);
}
.m-cap-text.an-slide {
  animation-name: cap-slide;
}
.m-cap-text.an-pop {
  animation-name: cap-pop;
  animation-duration: 0.45s;
}
@keyframes cap-fade {
  from {
    opacity: 0;
  }
}
@keyframes cap-slide {
  from {
    opacity: 0;
    transform: translateY(35%);
  }
}
@keyframes cap-pop {
  0% {
    opacity: 0;
    transform: scale(0.6);
  }
  60% {
    opacity: 1;
    transform: scale(1.07);
  }
}
@media (prefers-reduced-motion: reduce) {
  .m-cap-text[class*='an-'] {
    animation: none;
  }
}
.le-sec {
  border-radius: var(--r-md);
  box-shadow: inset 0 0 0 1px var(--line-2);
  padding: 0 16px;
}
.le-sec > summary {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding: 14px 0;
  color: var(--ink);
}
.le-sec > summary .muted {
  font-size: var(--fs-md);
}
.le-sec > .stack {
  padding-bottom: 16px;
}
.le-fine > summary {
  font-size: var(--fs-md);
  color: var(--muted);
}
.le-fine > .field-row {
  margin-top: 10px;
  grid-template-columns: repeat(auto-fit, minmax(84px, 1fr));
}
.fld output {
  color: var(--muted);
  font-weight: 600;
}
.fld input[type='range'] {
  width: 100%;
}
.anim-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
}
.anim-opt {
  display: grid;
  gap: 2px;
  text-align: left;
  padding: 10px 12px;
  border: 0;
  cursor: pointer;
  border-radius: var(--r-sm);
  background: transparent;
  color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--line-2);
}
.anim-opt small {
  color: var(--muted);
  font-size: var(--fs-sm, 12px);
  line-height: 1.3;
}
.anim-opt:hover {
  background: var(--card-3);
}
.anim-opt.on {
  box-shadow: inset 0 0 0 2px var(--accent);
}

/* modal de recorte */
.cropper {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 20px;
  height: 100%;
  min-height: 0;
}
.crop-stage {
  display: grid;
  place-items: center;
  background: #000;
  border-radius: var(--r-md);
  min-height: 0;
  overflow: hidden;
  position: relative;
}
.crop-wrap {
  position: relative;
}
.crop-wrap video {
  display: block;
}
.crop-wrap canvas {
  position: absolute;
  inset: 0;
  touch-action: none;
}
.trim-track {
  position: relative;
  height: 8px;
  border-radius: 99px;
  background: var(--card-3);
  margin: 10px 0 6px;
}
.trim-track i {
  position: absolute;
  top: 0;
  bottom: 0;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--accent-to), var(--accent-from));
}
@media (max-width: 900px) {
  .cropper {
    grid-template-columns: minmax(0, 1fr);
  }
  .crop-stage {
    min-height: 320px;
  }
}

/* candidatos da descoberta */
/* Descoberta: última rodada automática na área grande */
.auto-item {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 12px 18px;
  border-bottom: 1px solid var(--line);
}
.auto-thumb {
  width: 64px;
  aspect-ratio: 9 / 16;
  border-radius: var(--r-sm);
  overflow: hidden;
  background: var(--card-3);
  display: grid;
  place-items: center;
  color: var(--faint);
}
.auto-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.auto-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.auto-body b {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.auto-state {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
}
.auto-state .bar {
  flex: 1 1 120px;
  max-width: 200px;
}
.auto-acts {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.auto-foot {
  padding: 14px 18px;
}
.auto-foot:empty {
  display: none;
}
.auto-steps {
  list-style: none;
  counter-reset: step;
  margin: 0;
  padding: 8px 18px 0;
  display: grid;
  gap: 12px;
}
.auto-steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 28px 1fr;
  column-gap: 12px;
}
.auto-steps li::before {
  content: counter(step);
  grid-row: span 2;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 600;
  background: var(--accent-soft);
  color: var(--accent-text);
}
.auto-steps span {
  color: var(--muted);
}
#dc-auto-last .ic {
  display: inline-block;
  width: 14px;
  height: 14px;
  vertical-align: -2px;
}
button.link {
  border: 0;
  background: none;
  padding: 0;
  font: inherit;
  color: var(--accent-text);
  cursor: pointer;
  text-decoration: underline;
}
@media (max-width: 640px) {
  .auto-item {
    grid-template-columns: 48px minmax(0, 1fr);
  }
  .auto-thumb {
    width: 48px;
  }
  .auto-acts {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }
}
.cand {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 16px;
  padding: 16px;
  border-bottom: 1px solid var(--line);
}
.cand:last-child {
  border-bottom: 0;
}
.cand .cover {
  position: relative;
  aspect-ratio: 9 / 16;
  border-radius: var(--r-sm);
  overflow: hidden;
  background: var(--card-3);
}
.cand .cover img,
.cand .cover iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 0;
}
.cand .cover button {
  position: absolute;
  inset: auto 8px 8px 8px;
}
.opt {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 9px 10px;
  border-radius: var(--r-sm);
  cursor: pointer;
}
.opt:hover {
  background: var(--card-2);
}
.opt input {
  margin-top: 3px;
  accent-color: var(--accent);
}
@media (max-width: 640px) {
  .cand {
    grid-template-columns: minmax(0, 1fr);
  }
  .cand .cover {
    max-width: 200px;
  }
}

/* planos */
.plans {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--gap);
}
.plan {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 22px;
  border-radius: var(--r-lg);
  background: var(--card);
  box-shadow: var(--rim), var(--shadow);
}
.plan.on {
  box-shadow:
    inset 0 0 0 2px var(--accent),
    var(--shadow);
}
.plan .price b {
  font-size: 34px;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.plan .price small {
  color: var(--muted);
}
.plan ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 9px;
  flex: 1;
}
.plan li {
  display: flex;
  gap: 9px;
  align-items: flex-start;
  color: var(--ink-2);
}
.plan li svg {
  width: 16px;
  height: 16px;
  flex: none;
  margin-top: 2px;
  color: var(--ok);
}
.plan li.off {
  color: var(--faint);
}
.plan li.off svg {
  color: var(--faint);
}

/* horários da agenda */
.slots {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.slot {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 4px 4px 10px;
  border-radius: var(--r-sm);
  background: var(--card-2);
  box-shadow: inset 0 0 0 1px var(--line-2);
}
.slot input {
  border: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-variant-numeric: tabular-nums;
  width: 74px;
}
.slot input:focus {
  outline: 0;
}
.slot button {
  width: 26px;
  height: 26px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  display: grid;
  place-items: center;
}
.slot button:hover {
  background: var(--bad-soft);
  color: var(--bad);
}
.slot svg {
  width: 14px;
  height: 14px;
}

/* chat de títulos */
.chat {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 220px;
  overflow-y: auto;
  padding: 4px 2px;
}
.chat p {
  padding: 8px 12px;
  border-radius: 12px;
  max-width: 88%;
  background: var(--card-3);
}
.chat p.me {
  align-self: flex-end;
  background: var(--accent-soft);
  color: var(--accent-text);
}

/* páginas públicas (login, cadastro…) */
.auth {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
}
.auth-side {
  position: relative;
  padding: 44px 52px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  background: radial-gradient(900px 600px at 0% 0%, var(--accent-soft), transparent 60%),
    radial-gradient(700px 500px at 100% 100%, rgba(108, 199, 232, 0.07), transparent 60%), var(--card);
  box-shadow: var(--rim);
}
.auth-side h1 {
  font-size: 46px;
  max-width: 520px;
}
.auth-side ul {
  list-style: none;
  padding: 0;
  margin: 28px 0 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  color: var(--ink-2);
  font-size: var(--fs-lg);
  max-width: 460px;
}
.auth-side li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.auth-side li svg {
  width: 20px;
  height: 20px;
  flex: none;
  margin-top: 2px;
  color: var(--accent-text);
}
/* mascote do Studio no canto livre do painel: decorativo, não recebe cliques
   e sai antes de encostar nos textos (alturas pequenas) */
.auth-mascot {
  position: absolute;
  right: 34px;
  bottom: 66px;
  pointer-events: none;
}
.auth-mascot img {
  width: 178px;
  height: 178px;
  object-fit: contain;
}
@media (max-width: 1100px) {
  .auth-mascot {
    right: 24px;
    bottom: 74px;
  }
  .auth-mascot img {
    width: 120px;
    height: 120px;
  }
}
@media (max-height: 740px) {
  .auth-mascot {
    display: none;
  }
}
.auth-main {
  display: grid;
  place-items: center;
  padding: 32px 24px;
}
.auth-box {
  width: min(420px, 100%);
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.auth-box h2 {
  font-size: var(--fs-4xl);
}
.auth-box form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.auth-foot {
  color: var(--muted);
  text-align: center;
}
.code-in {
  letter-spacing: 0.4em;
  text-align: center;
  font: 600 22px var(--mono);
  height: 52px;
}
@media (max-width: 900px) {
  .auth {
    grid-template-columns: minmax(0, 1fr);
  }
  .auth-side {
    display: none;
  }
}

/* 2FA */
.totp-qr {
  display: block;
  margin: 0 auto;
  width: 220px;
  height: 220px;
  background: #fff;
  border-radius: var(--r-md, 12px);
  image-rendering: pixelated;
}
.audit-detail dl {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 12px;
  margin: 8px 0 0;
  font-size: var(--fs-sm, 12px);
}
.audit-detail dt {
  color: var(--muted);
}
.audit-detail dd {
  margin: 0;
  max-width: 360px;
}
#audit-filter {
  align-items: end; /* botão na linha dos campos, não dos rótulos */
}
.qr-secret {
  font: 600 var(--fs-lg) var(--mono);
  letter-spacing: 0.12em;
  word-break: break-all;
}
.codes {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  font: 600 var(--fs-base) var(--mono);
}
.codes span {
  padding: 9px;
  text-align: center;
  border-radius: var(--r-xs);
  background: var(--card-2);
  box-shadow: inset 0 0 0 1px var(--line-2);
}

/* Novas áreas de produção e conta usam os mesmos tokens do shell. */
.section-title {
  margin: 8px 0 18px;
}
.section-title p {
  margin-top: 5px;
}
.editor-options {
  margin-top: 16px;
}
.drop {
  padding: 20px;
  border: 1px dashed var(--line-2);
  border-radius: var(--r-md);
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
  background: var(--card-2);
}
.drop input {
  max-width: 100%;
}
#source-url {
  align-items: end;
}
#source-url .fld {
  flex: 1;
}
.transcript-text {
  max-height: 260px;
  overflow: auto;
  line-height: 1.8;
  margin-top: 12px;
}
.layout-swatch {
  height: 150px;
  border-radius: var(--r-md);
  background: var(--card-2);
  display: grid;
  place-items: center;
  overflow: hidden;
  color: var(--muted);
  font-size: 36px;
}
.layout-swatch img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.layout-preview {
  display: block;
  max-height: 68vh;
  max-width: 100%;
  margin: auto;
  border-radius: var(--r-md);
}
.profile-editor-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 24px;
}
.profile-editor-grid aside {
  position: sticky;
  top: 0;
  align-self: start;
}
.profile-editor-grid aside .hint {
  margin-top: 16px;
}
.settings-layout {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 24px;
}
.settings-nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-self: start;
}
.settings-nav a {
  padding: 12px 16px;
  border-radius: var(--r-md);
  color: var(--muted);
}
.settings-nav a:hover {
  background: var(--card-2);
  color: var(--ink);
}
.settings-nav a.on {
  background: var(--accent-soft);
  color: var(--accent-text);
}
.secret-value {
  display: block;
  padding: 18px;
  white-space: pre-wrap;
  word-break: break-all;
  background: var(--card-2);
  border-radius: var(--r-md);
  user-select: all;
}
.break {
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}
.row.end {
  justify-content: flex-end;
}
summary {
  cursor: pointer;
  color: var(--ink-2);
}
[hidden] {
  display: none !important;
}
.skip-link {
  position: fixed;
  left: 16px;
  top: -70px;
  z-index: 200;
  padding: 12px;
  background: var(--card);
  color: var(--ink);
}
.skip-link:focus {
  top: 12px;
}
@media (max-width: 900px) {
  .settings-layout,
  .profile-editor-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .settings-nav {
    flex-direction: row;
    overflow-x: auto;
  }
  .settings-nav a {
    white-space: nowrap;
  }
  .profile-editor-grid aside {
    order: -1;
    position: static;
  }
  .profile-editor-grid .phone {
    max-width: 240px;
  }
  .settings-layout .plans {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 540px) {
  #source-url {
    flex-direction: column;
    align-items: stretch;
  }
  .row.wrap {
    gap: 8px;
  }
  .modal {
    width: 100%;
  }
  .tbl {
    min-width: 560px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* biblioteca: tentar agendar de novo */
.retry-bar {
  margin: 0 16px 16px;
  align-items: center;
  flex-wrap: wrap;
}
.retry-bar .grow {
  flex: 1 1 260px;
  min-width: 0;
}
.lib-pick {
  padding: 0 12px 8px;
  font-size: var(--fs-md);
}

/* ── esqueletos de carregamento (js/skeletons.js) ─────────────────────────── */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.sk-page {
  pointer-events: none;
}
.sk-page .skel {
  min-height: 0;
}
.sk-title {
  display: block;
  height: calc(var(--fs-display) * 1.1);
  width: min(320px, 70%);
}
.sk-sub {
  display: block;
  height: var(--fs-lg);
  width: min(440px, 90%);
  margin-top: 12px;
}
.sk-btn {
  display: block;
  width: 120px;
  height: var(--h-ctl);
  border-radius: var(--r-md);
}
.sk-chip {
  display: block;
  width: 88px;
  height: 34px;
}
.sk-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
  gap: 16px;
  margin-top: 16px;
}
.sk-rows {
  padding: 8px 20px 16px;
}
.sk-row {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) repeat(auto-fit, 64px);
  grid-auto-flow: column;
  align-items: center;
  gap: 16px;
  padding: 10px 0;
}
.sk-thumb {
  display: block;
  width: 36px;
  aspect-ratio: 9 / 16;
  border-radius: 7px;
}
.sk-short {
  border-radius: var(--r-md);
  overflow: hidden;
}
.sk-short .skel {
  display: block;
  aspect-ratio: 9 / 16;
  border-radius: 0;
}
.sk-qthumb {
  display: block;
  flex: none;
  width: 54px;
  aspect-ratio: 9 / 16;
  border-radius: 9px;
}
.card.sk-pad {
  padding: 12px;
}
.sk-player {
  display: block;
  aspect-ratio: 9 / 16;
  max-height: 72vh;
  margin: 0 auto;
  border-radius: var(--r-md);
}
@media (prefers-reduced-motion: reduce) {
  .skel {
    animation: none;
  }
}
