/* ================= Pré-imersão: tema escuro da página com os tokens do instalador =================
   A página é só escura (data-theme="dark", color-scheme dark). Estes tokens são os mesmos do
   tema escuro do instalador Hermes e valem em qualquer preferência do sistema. */
:root {
  --teal: #05645f;
  --coral: #b53a31;
  --ui-card: #17212b;
  --ui-field: #1f2b38;
  --ui-field-border: #5d7083;
  --ui-text: #fffaf0;
  --ui-text-2: #e1d9c9;
  --ui-muted: #bab4a8;
  --ui-heading: #f4e6c7;
  --ui-accent-text: #72d9cd;
  --ui-focus: #72d9cd;
  --ui-solid-navy: #183653;
  --ui-primary: #b53a31;
  --ui-primary-text: #fffaf0;
  --ui-success-bg: #05645f;
  --ui-surface-2: #253340;
  --ui-line: #3f5163;
  --info-bg: #11302e;
  --info-border: #2f8c83;
  --info-text: #d7f1ed;
  --info-icon: #72d9cd;
  --warn-bg: #2e2716;
  --warn-border: #8a6a1f;
  --warn-text: #f6e7c2;
  --err-bg: #3a1a18;
  --err-border: #c0544c;
  --err-text: #ffdcd7;
  --err-icon: #ff9a90;
  --err-link: #ffdcd7;
}

/* ---------- caixas de aviso: sem borda esquerda, fundo tonal escuro, borda fina completa ---------- */
.note, .note.alert, .note.locked-note, .note.guarantee {
  background: var(--warn-bg); color: var(--warn-text);
  border: 1.5px solid var(--warn-border); border-radius: 12px;
}
.note.guarantee { background: var(--info-bg); color: var(--info-text); border-color: var(--info-border); font-size: 16px; }
.note.alert { background: var(--err-bg); color: var(--err-text); border-color: var(--err-border); }
.note.locked-note { background: var(--ui-surface-2); color: var(--ui-text-2); border-color: var(--ui-line); }
.note strong { color: inherit; }

/* ---------- cartões alinhados: sem rotação, mesma largura dos vizinhos ---------- */
.step, .step:nth-of-type(odd), .step:nth-of-type(even), .hero, .video-card, .hero-grupo, .hero-alert, .footer-warn { transform: none; }

/* ---------- barra do player: superfície escura, ícones SVG de linha ---------- */
.video-controls { background: #0f1720; border-color: var(--ui-line); }
.vc-btn { display: inline-flex; align-items: center; gap: 6px; }
.vc-btn .vc-ic { width: 16px; height: 16px; flex: none; }
.vc-select { background: var(--ui-field); color: var(--ui-text); border-color: var(--ui-field-border); }

/* ---------- botões e selos com contraste AA ---------- */
.copy-btn, .hw-copy { color: #142d46; }
.n-mustard, .dl-badge[style*="mustard"] { color: #142d46; }
.vd-btn[disabled], .dl-btn.locked {
  background: var(--ui-surface-2); color: var(--ui-muted);
  border: 1.5px solid var(--ui-line); box-shadow: none;
}
.release-pill { color: #edc76a; }

/* ---------- avisos sem borda esquerda: fundo tonal, borda fina e ícone de linha ---------- */
.note, .note.alert, .note.locked-note, .note.guarantee {
  border: 1.5px solid var(--info-border);
  border-radius: 12px;
}
.note.alert { border-color: var(--err-border); }

.hw-note-privacy, .hw-alert {
  position: relative;
  margin-top: 16px;
  border: 1.5px solid var(--info-border);
  border-radius: 12px;
  background: var(--info-bg);
  color: var(--info-text);
  font-size: 15px;
  line-height: 1.45;
  padding: 12px 16px 12px 46px;
  box-shadow: none;
}
.hw-note-privacy::before, .hw-alert::before {
  content: "";
  position: absolute; left: 15px; top: 13px;
  width: 20px; height: 20px;
  background-color: var(--info-icon);
  -webkit-mask: var(--hw-ic) center / contain no-repeat;
  mask: var(--hw-ic) center / contain no-repeat;
}
.hw-note-privacy {
  --hw-ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4.5' y='10.5' width='15' height='10' rx='2'/%3E%3Cpath d='M8 10.5V7.5a4 4 0 0 1 8 0v3'/%3E%3C/svg%3E");
}
.hw-alert {
  --hw-ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 7.5v5.5'/%3E%3Cpath d='M12 16.5h.01'/%3E%3C/svg%3E");
  border-color: var(--err-border);
  background: var(--err-bg);
  color: var(--err-text);
  display: none;
}
.hw-alert::before { background-color: var(--err-icon); }
.hw-alert.hw-on { display: block; }
.hw-alert strong { color: inherit; }
.hw-alert .hw-planob-link { color: var(--err-link); }

/* ---------- formulário: mesmo alinhamento, espaçamento e estados nos dois temas ---------- */
.hw-root h2.hw-title, .hw-field > span.hw-lb { color: var(--ui-heading); }
.hw-root p.hw-lead { color: var(--ui-text-2); }
.hw-fields { gap: 16px; margin-top: 16px; }
.hw-input {
  background: var(--ui-field);
  color: var(--ui-text);
  border: 2px solid var(--ui-field-border);
  box-shadow: none;
}
.hw-input::placeholder { color: var(--ui-muted); opacity: 1; }
.hw-input:focus, .hw-input:focus-visible {
  border-color: var(--ui-focus);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--ui-focus) 35%, transparent);
  outline: none;
}
.hw-input.hw-invalid, .hw-input[aria-invalid="true"] {
  border-color: var(--err-border);
  background: var(--err-bg);
  color: var(--err-text);
}
.hw-input.hw-invalid:focus { box-shadow: 0 0 0 3px color-mix(in srgb, var(--err-border) 35%, transparent); }
.hw-eye { color: var(--ui-text-2); }
.hw-eye:focus-visible { outline: 3px solid var(--ui-focus); outline-offset: 1px; }
.hw-cta { margin-top: 16px; }
.hw-btn { box-shadow: none; border-width: 2px; }
.hw-btn:hover { box-shadow: none; }
.hw-btn:focus-visible { outline: 3px solid var(--ui-focus); outline-offset: 3px; }
.hw-btn-coral { background: var(--ui-primary); color: var(--ui-primary-text); border-color: var(--ui-primary); }
.hw-btn-teal { background: var(--ui-success-bg); color: #fffaf0; border-color: var(--ui-success-bg); }
.hw-btn-paper { background: var(--ui-field); color: var(--ui-heading); border-color: var(--ui-field-border); }
.hw-done-tag { background: var(--ui-success-bg); }
.hw-oauth { background: var(--ui-field); }
.hw-oauth p.hw-oauth-step, .hw-waiting { color: var(--ui-text); }
.hw-copy { color: #142d46; }
.hw-steps li { color: var(--ui-text-2); }
.hw-steps li[data-state="running"] { background: var(--ui-field); color: var(--ui-heading); }
.hw-steps li[data-state="done"] { color: var(--ui-text); }

/* ---------- player no celular: controles quebram linha em vez de cortar ---------- */
@media (max-width: 1023px) {
  .video-controls { flex-wrap: wrap; overflow-x: visible; }
  .video-controls .vc-seek { flex: 1 1 100%; min-width: 0; order: 9; }
}
