:root {
  --bg: #0c1220;
  --card: #131c31;
  --card2: #18233c;
  --border: #283655;
  --gold: #d4af37;
  --gold-soft: rgba(212, 175, 55, 0.14);
  --red: #e55353;
  --green: #38b26f;
  --blue: #4da3ff;
  --text: #dce3f0;
  --bright: #ffffff;
  --muted: #8e9cb8;
  --font: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Segoe UI", Roboto, sans-serif;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  line-height: 1.65;
  font-size: 15.5px;
}
a { color: var(--gold); text-decoration: none; }
a:hover { text-decoration: underline; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 18px 16px 80px; }

/* Topbar */
.topbar {
  background: #090e1a;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 10px 16px;
}
.topbar-in {
  max-width: 1120px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  color: var(--bright);
  font-size: 15px;
}
.brand-badge {
  background: var(--gold);
  color: #000;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 11px;
  letter-spacing: 0.5px;
}
.quadro-fixo {
  background: var(--card2);
  border: 1px solid var(--border);
  border-left: 4px solid var(--gold);
  padding: 8px 14px;
  font-size: 13px;
  margin-bottom: 14px;
  border-radius: 6px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

/* Tabs */
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 12px 0 18px; }
.tab-btn {
  background: var(--card);
  color: var(--text);
  border: 1px solid var(--border);
  padding: 9px 15px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: 0.15s;
}
.tab-btn:hover { border-color: var(--gold); color: var(--bright); }
.tab-btn.active { background: var(--gold); color: #000; border-color: var(--gold); }
.tab-pane { display: none; }
.tab-pane.active { display: block; animation: fadeIn 0.25s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }

/* Dual language grid in opening */
.bilingue-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
@media (max-width: 820px) {
  .bilingue-grid { grid-template-columns: 1fr; }
}
.col-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 22px;
}
.col-card h2 {
  color: var(--bright);
  font-size: 19px;
  margin: 18px 0 8px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 6px;
}
.col-card h2:first-child { margin-top: 0; }

/* Elenco grid */
.elenco-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 12px;
  margin: 12px 0;
}
.elenco-item {
  background: var(--card2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px;
  display: flex;
  gap: 10px;
  align-items: center;
}
.elenco-item.vitima { border-color: var(--red); background: rgba(229, 83, 83, 0.1); }
.elenco-item img {
  width: 58px;
  height: 58px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
}
.elenco-nome { font-weight: 700; color: var(--bright); font-size: 14px; }
.elenco-papel { font-size: 12px; color: var(--muted); line-height: 1.35; }

/* Intro lado & Documents */
.intro-lado {
  background: var(--card2);
  border: 1px solid var(--gold);
  border-radius: 10px;
  padding: 14px 16px;
  display: flex;
  gap: 14px;
  align-items: center;
  margin-bottom: 18px;
}
.avatar { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; border: 2px solid var(--gold); flex-shrink: 0; }
.cap-h { color: var(--gold); border-bottom: 2px solid var(--border); padding-bottom: 6px; margin-top: 28px; }
.doc {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px;
  margin-bottom: 16px;
}
.doc-h {
  font-weight: 800;
  color: var(--bright);
  font-size: 16px;
  margin-bottom: 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
}
.meta { font-size: 12.5px; color: var(--muted); margin-top: -4px; margin-bottom: 10px; }
.nota {
  background: rgba(77, 163, 255, 0.1);
  border-left: 3px solid var(--blue);
  padding: 10px 12px;
  font-size: 13.5px;
  border-radius: 4px;
}
.destaque {
  background: var(--gold-soft);
  border-left: 4px solid var(--gold);
  padding: 12px 14px;
  border-radius: 6px;
  margin: 12px 0;
}
.destaque.vermelho {
  background: rgba(229, 83, 83, 0.12);
  border-left-color: var(--red);
}
.recado {
  background: var(--card2);
  border-radius: 8px;
  padding: 12px 14px;
  border: 1px solid var(--border);
}
.relogio {
  font-size: 30px;
  font-weight: 800;
  color: var(--gold);
  text-align: center;
  padding: 14px;
  background: #080d18;
  border: 1px solid var(--border);
  border-radius: 8px;
  margin: 10px 0;
}
.relogio small { display: block; font-size: 12px; color: var(--muted); font-weight: 500; margin-top: 4px; }
.gravacao {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  background: #fff8dc;
  color: #222;
  padding: 10px 14px;
  border-radius: 6px;
  font-weight: 700;
  text-align: center;
  border: 1px dashed #b8860b;
  margin: 10px 0;
}
blockquote {
  margin: 10px 0;
  padding: 10px 14px;
  background: var(--card2);
  border-left: 3px solid var(--gold);
  border-radius: 4px;
}

/* WhatsApp */
.wa { background: #0b141a; border: 1px solid var(--border); border-radius: 10px; padding: 14px; margin: 10px 0; }
.wa-b { padding: 9px 12px; border-radius: 8px; margin-bottom: 8px; max-width: 86%; font-size: 14px; position: relative; }
.wa-in { background: #202c33; color: #e9edef; margin-right: auto; }
.wa-out { background: #005c4b; color: #e9edef; margin-left: auto; }
.wa-t { font-size: 11px; color: #99b0bb; float: right; margin-left: 10px; }

/* Tables */
.tabela-wrap { overflow-x: auto; }
.tabela { width: 100%; border-collapse: collapse; font-size: 13.5px; margin: 8px 0; }
.tabela th, .tabela td { border: 1px solid var(--border); padding: 8px 10px; text-align: left; vertical-align: top; }
.tabela th { background: var(--card2); color: var(--bright); font-weight: 700; }
.tabela.centro th, .tabela.centro td { text-align: center; }
.pos { color: var(--green); font-weight: 700; }
.neg { color: var(--red); }

/* Trava box */
.trava-box {
  background: linear-gradient(145deg, #16223d, #10192e);
  border: 2px solid var(--gold);
  border-radius: 10px;
  padding: 18px;
  margin: 18px 0 24px;
}
.trava-box.aberta { border-color: var(--green); }
.trava-head { font-weight: 800; color: var(--gold); font-size: 16px; margin-bottom: 6px; }
.trava-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 10px; }
.inp {
  background: #080d18;
  color: var(--bright);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px 12px;
  font-size: 15px;
  min-width: 140px;
}
.btn {
  background: var(--gold);
  color: #000;
  border: none;
  padding: 10px 16px;
  border-radius: 6px;
  font-weight: 800;
  font-size: 14px;
  cursor: pointer;
}
.btn-sec {
  background: var(--card2);
  color: var(--text);
  border: 1px solid var(--border);
  padding: 8px 12px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
}
.btn-sec:hover { border-color: var(--gold); color: var(--bright); }
.dica-item {
  background: var(--card);
  border-left: 3px solid var(--gold);
  padding: 8px 12px;
  margin-top: 8px;
  border-radius: 4px;
  font-size: 13.5px;
  display: none;
}
.msg-status { font-weight: 700; font-size: 14px; margin-top: 8px; }
.cap-bloco.locked { display: none; }

/* Banner Kakutei */
.k-banner {
  background: linear-gradient(135deg, #182848 0%, #101b33 100%);
  border: 1px solid var(--gold);
  border-radius: 10px;
  padding: 16px 20px;
  margin: 26px 0 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.k-banner-tag {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--gold);
  font-weight: 800;
}
.k-banner-title { font-size: 16px; font-weight: 800; color: var(--bright); margin: 2px 0; }
.k-banner-sub { font-size: 13.5px; color: var(--muted); }

/* Solution & Epilogue */
.sol-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 18px; }
@media (max-width: 820px) { .sol-grid { grid-template-columns: 1fr; } }
.sol-col { background: var(--card); border: 1px solid var(--green); border-radius: 10px; padding: 20px; }
.sol-lead { font-size: 17px; color: var(--bright); }
.epilogo {
  background: #101525;
  border: 2px solid var(--gold);
  border-radius: 12px;
  padding: 20px;
  margin-top: 20px;
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 18px;
  align-items: center;
}
@media (max-width: 700px) { .epilogo { grid-template-columns: 1fr; } }
.epi-img { width: 100%; border-radius: 8px; }
.carta { background: var(--card2); padding: 12px; border-radius: 6px; border-left: 3px solid var(--gold); }
.peca {
  background: var(--gold-soft);
  border: 2px dashed var(--gold);
  border-radius: 10px;
  padding: 16px;
  margin-top: 18px;
  display: flex;
  gap: 14px;
  align-items: center;
}
.peca-ic { font-size: 40px; }
.peca-palavra {
  font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 24px;
  font-weight: 900;
  letter-spacing: 4px;
  color: var(--gold);
  margin: 4px 0;
}

/* Certificado */
.cert-panel {
  background: var(--card);
  border: 2px solid var(--gold);
  border-radius: 12px;
  padding: 22px;
  margin-top: 22px;
}
.cert-canvas-wrap { text-align: center; margin: 14px 0; }
.cert-canvas-wrap canvas { max-width: 100%; height: auto; border-radius: 8px; border: 1px solid var(--border); }

/* Print opening sheet A4 */
@media print {
  body { background: #fff; color: #000; font-size: 10.5pt; }
  .topbar, .tabs, .no-print, .k-banner, #pane-br, #pane-jp, #pane-quadro, #pane-final { display: none !important; }
  #pane-abertura { display: block !important; }
  .col-card, .recado, .elenco-item { background: #fff; border: 1px solid #ccc; color: #000; }
  .col-card h2, .elenco-nome { color: #000; }
}

/* 1. Cena do Crime Interativa (Hotspots + Lupa) */
.cena-interativa-wrap {
  margin-bottom: 18px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--gold);
  background: #080d18;
  box-shadow: 0 8px 28px rgba(0,0,0,0.45);
}
.cena-interativa-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 16px;
  background: linear-gradient(90deg, #131f3a, #0e172c);
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}
.cena-stage {
  position: relative;
  width: 100%;
  max-height: 440px;
  overflow: hidden;
}
.cena-stage img {
  width: 100%;
  max-height: 440px;
  object-fit: cover;
  display: block;
}
.hotspot-pin {
  position: absolute;
  transform: translate(-50%, -50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid #fff;
  background: rgba(212, 175, 55, 0.92);
  color: #000;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 0 0 0 rgba(212, 175, 55, 0.7), 0 4px 12px rgba(0,0,0,0.6);
  animation: hsPulse 2s infinite;
  transition: transform 0.18s ease, background 0.18s ease;
  z-index: 4;
}
.hotspot-pin:hover, .hotspot-pin.active {
  transform: translate(-50%, -50%) scale(1.18);
  background: #fff;
  border-color: var(--gold);
}
.hotspot-pin.visto {
  background: rgba(56, 178, 111, 0.92);
  border-color: #d1fae5;
  animation: none;
}
.hotspot-pin.visto::after {
  content: "✓";
  position: absolute;
  bottom: -4px;
  right: -4px;
  background: #065f46;
  color: #fff;
  font-size: 10px;
  font-weight: 900;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #fff;
}
@keyframes hsPulse {
  0% { box-shadow: 0 0 0 0 rgba(212, 175, 55, 0.75); }
  70% { box-shadow: 0 0 0 14px rgba(212, 175, 55, 0); }
  100% { box-shadow: 0 0 0 0 rgba(212, 175, 55, 0); }
}
.cena-lupa-painel {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 16px;
  align-items: center;
  padding: 14px 18px;
  background: #10192e;
  border-top: 1px solid var(--border);
}
@media (max-width: 600px) {
  .cena-lupa-painel { grid-template-columns: 1fr; }
}
.lupa-zoom-thumb {
  width: 108px;
  height: 108px;
  border-radius: 50%;
  border: 3px solid var(--gold);
  background-repeat: no-repeat;
  background-size: 360% 360%;
  box-shadow: inset 0 0 18px rgba(0,0,0,0.65), 0 4px 12px rgba(0,0,0,0.4);
  margin: 0 auto;
}

/* 2. Documentos Realistas + Player de Áudio */
.doc { position: relative; }
.doc-pf {
  border-left: 4px solid #d4af37;
  background: linear-gradient(180deg, #131e36 0%, #10182b 100%);
}
.doc-keishicho {
  border-left: 4px solid #e55353;
  background: linear-gradient(180deg, #1a1829 0%, #121728 100%);
}
.doc-stamp {
  float: right;
  font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 11px;
  font-weight: 800;
  color: var(--gold);
  border: 1.5px solid var(--gold);
  padding: 2px 8px;
  border-radius: 4px;
  letter-spacing: 0.8px;
  transform: rotate(-3deg);
}
.doc-stamp-jp {
  float: right;
  font-size: 11.5px;
  font-weight: 900;
  color: #f87171;
  border: 2px solid #ef4444;
  padding: 2px 8px;
  border-radius: 4px;
  letter-spacing: 1px;
  transform: rotate(-4deg);
}
.cctv-frame {
  background: #060b12;
  border: 2px solid #2b3b55;
  border-radius: 8px;
  padding: 12px;
  margin: 10px 0;
  position: relative;
  box-shadow: inset 0 0 24px rgba(0, 255, 136, 0.05);
}
.cctv-hud {
  display: flex;
  justify-content: space-between;
  font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 12px;
  color: #4ade80;
  margin-bottom: 8px;
  padding-bottom: 6px;
  border-bottom: 1px dashed rgba(74, 222, 128, 0.3);
}
.boarding-pass {
  background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
  border: 1px solid var(--gold);
  border-left: 6px solid #ef4444;
  border-radius: 10px;
  padding: 12px 16px;
  margin: 12px 0;
}
.bp-top {
  display: flex;
  justify-content: space-between;
  font-size: 11.5px;
  font-weight: 800;
  color: var(--gold);
  border-bottom: 1px dashed var(--border);
  padding-bottom: 6px;
  margin-bottom: 10px;
}
.bp-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 10px;
}
.bp-grid small { display: block; font-size: 10px; color: var(--muted); }
.bp-grid b { font-size: 13px; color: #fff; font-family: ui-monospace, monospace; }

.wa-phone {
  border: 2px solid #233138;
  border-radius: 14px;
  overflow: hidden;
  background: #0b141a;
  margin: 10px 0;
}
.wa-topbar {
  background: #202c33;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid #2a3942;
}
.wa-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #00a884;
  color: #000;
  font-weight: 900;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.wa-phone .wa { border: none; margin: 0; border-radius: 0; }
.wa-audio-player {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(0,0,0,0.28);
  padding: 8px 12px;
  border-radius: 999px;
  margin-top: 6px;
  border: 1px solid rgba(255,255,255,0.1);
}
.wa-play-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: none;
  background: #00a884;
  color: #fff;
  font-size: 15px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.wa-wave {
  display: flex;
  align-items: center;
  gap: 3px;
  height: 22px;
  flex: 1;
}
.wa-wave span {
  display: inline-block;
  width: 3px;
  height: 8px;
  background: #8696a0;
  border-radius: 2px;
  transition: height 0.15s ease, background 0.15s ease;
}
.wa-wave span:nth-child(odd) { height: 15px; }
.wa-wave span:nth-child(3n) { height: 20px; }
.wa-audio-player.playing .wa-wave span {
  background: #00a884;
  animation: waveAnim 0.55s infinite ease-in-out alternate;
}
.wa-audio-player.playing .wa-wave span:nth-child(2n) { animation-delay: 0.18s; }
.wa-audio-player.playing .wa-wave span:nth-child(3n) { animation-delay: 0.33s; }
@keyframes waveAnim {
  0% { height: 5px; }
  100% { height: 22px; }
}
.wa-dur { font-family: ui-monospace, monospace; font-size: 12px; color: #d1d7db; }

.voice-bar {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.btn-voice {
  background: rgba(212, 175, 55, 0.14);
  color: var(--gold);
  border: 1px solid rgba(212, 175, 55, 0.45);
  border-radius: 999px;
  padding: 5px 12px;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
}
.btn-voice:hover { background: var(--gold); color: #000; }

/* 3. Quadro de Detetive com Fios Vermelhos */
.quadro-board {
  position: relative;
  background: radial-gradient(circle at center, #1a243d 0%, #0d1322 100%);
  border: 2px solid #3b2f2f;
  border-radius: 12px;
  padding: 22px;
  overflow: hidden;
}
.quadro-svg-fios {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}
.quadro-centro {
  position: relative;
  z-index: 2;
  max-width: 440px;
  margin: 0 auto 26px;
  background: #141e33;
  border: 2px solid var(--gold);
  border-radius: 10px;
  padding: 12px 16px;
  text-align: center;
  box-shadow: 0 6px 20px rgba(0,0,0,0.5);
}
.quadro-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(235px, 1fr));
  gap: 16px;
}
.suspeito-pin-card {
  background: #131c31;
  border: 2px solid var(--border);
  border-radius: 10px;
  padding: 12px;
  position: relative;
  transition: all 0.2s ease;
  box-shadow: 0 6px 16px rgba(0,0,0,0.35);
}
.suspeito-pin-card::before {
  content: "📌";
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 18px;
}
.suspeito-pin-card[data-st="suspeito"] {
  border-color: #ef4444;
  background: rgba(239, 68, 68, 0.12);
  box-shadow: 0 0 20px rgba(239, 68, 68, 0.25);
}
.suspeito-pin-card[data-st="inocente"] {
  border-color: #38b26f;
  opacity: 0.68;
}
.suspeito-st-btns {
  display: flex;
  gap: 4px;
  margin-top: 8px;
}
.suspeito-st-btns button {
  flex: 1;
  font-size: 11px;
  padding: 5px 4px;
  border-radius: 5px;
  border: 1px solid var(--border);
  background: var(--card2);
  color: var(--muted);
  cursor: pointer;
  font-weight: 700;
}
.suspeito-st-btns button.on {
  background: var(--gold);
  color: #000;
  border-color: var(--gold);
}
.suspeito-nota {
  width: 100%;
  margin-top: 8px;
  background: #090e1a;
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 5px;
  padding: 6px 8px;
  font-size: 12px;
}

/* 4. Barra de Sala em Família (Sync 2 celulares) */
.sala-bar {
  background: linear-gradient(90deg, rgba(16, 185, 129, 0.14), rgba(212, 175, 55, 0.12));
  border: 1px solid rgba(16, 185, 129, 0.4);
  border-radius: 10px;
  padding: 10px 14px;
  margin-bottom: 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 13px;
}
.sala-code-pill {
  font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 16px;
  font-weight: 900;
  letter-spacing: 2px;
  background: #065f46;
  color: #ecfdf5;
  padding: 4px 10px;
  border-radius: 6px;
  border: 1px solid #34d399;
}
.toast-sync {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: #065f46;
  color: #fff;
  border: 2px solid #34d399;
  border-radius: 10px;
  padding: 12px 18px;
  font-weight: 800;
  font-size: 14px;
  box-shadow: 0 10px 28px rgba(0,0,0,0.6);
  z-index: 9999;
  display: none;
}

/* Sora epilogo in new cases */
.sora-epilogo {
  background: #101525;
  border: 2px solid var(--gold);
  border-radius: 12px;
  padding: 18px;
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 18px;
  align-items: center;
}
@media (max-width: 700px) { .sora-epilogo { grid-template-columns: 1fr; } }
.sora-epilogo img { width: 100%; border-radius: 8px; }

/* 5. Forensic Video Player (警視庁・映像解析プレイヤー) */
.video-forense-card {
  background: linear-gradient(180deg, #0b1324 0%, #070c17 100%);
  border: 2px solid #2b4266;
  border-radius: 12px;
  padding: 16px;
  margin: 16px 0 22px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55);
}
.vf-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px dashed rgba(74, 222, 128, 0.35);
}
.vf-title {
  font-weight: 900;
  color: var(--gold);
  font-size: 15.5px;
}
.vf-timecode {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  background: #040811;
  color: #4ade80;
  border: 1px solid #22c55e;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 13.5px;
  font-weight: 800;
  letter-spacing: 0.8px;
}
.vf-timecode .rec-dot {
  color: #ef4444;
  animation: recBlink 1s infinite;
}
@keyframes recBlink {
  0%, 65% { opacity: 1; }
  66%, 100% { opacity: 0.2; }
}
.vf-screen-wrap {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid #1e293b;
  background: #000;
}
.vf-video {
  width: 100%;
  max-height: 430px;
  display: block;
  object-fit: contain;
  background: #000;
  transition: filter 0.2s ease;
}
.vf-video.ir-mode {
  filter: contrast(1.42) brightness(1.12) hue-rotate(85deg) saturate(1.55);
}
.vf-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
  padding: 10px 12px;
  background: #10192e;
  border: 1px solid var(--border);
  border-radius: 8px;
}
.vf-btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}
.vf-btn {
  background: #192746;
  color: var(--bright);
  border: 1px solid #354a75;
  padding: 7px 11px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 12.5px;
  cursor: pointer;
  transition: 0.15s;
}
.vf-btn:hover, .vf-btn.active {
  background: var(--gold);
  color: #000;
  border-color: var(--gold);
}
.vf-btn-evidencia {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #000;
  border: none;
  padding: 8px 14px;
  border-radius: 6px;
  font-weight: 900;
  font-size: 13px;
  cursor: pointer;
}
.vf-btn-evidencia.ok {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #fff;
}
.vf-descoberta {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: 8px;
  background: rgba(16, 185, 129, 0.14);
  border: 1.5px solid #10b981;
  color: #ecfdf5;
  font-size: 13.5px;
  display: none;
}
.vf-descoberta.visivel {
  display: block;
  animation: fadeIn 0.25s ease;
}

/* 6. Interactive 4x4 Logic Deduction Grid (論理パズル・マトリックス) */
.grade-logica-card {
  background: var(--card);
  border: 2px solid var(--gold);
  border-radius: 12px;
  padding: 18px;
  margin: 16px 0 22px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}
.grade-regras-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin: 12px 0 16px;
}
@media (max-width: 780px) {
  .grade-regras-split { grid-template-columns: 1fr; }
}
.grade-regras-box {
  background: var(--card2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 13.5px;
}
.grade-regras-box.jp { border-left: 4px solid var(--red); }
.grade-regras-box.br { border-left: 4px solid var(--green); }
.grade-regras-box ul { margin: 6px 0 0; padding-left: 18px; }
.grade-regras-box li { margin-bottom: 6px; }
.grade-table {
  width: 100%;
  border-collapse: collapse;
  margin: 10px 0;
  font-size: 13.5px;
}
.grade-table th, .grade-table td {
  border: 1px solid var(--border);
  padding: 10px 8px;
  text-align: center;
}
.grade-table th {
  background: #0f172a;
  color: var(--gold);
  font-weight: 800;
}
.grade-table td.row-lbl {
  text-align: left;
  background: var(--card2);
  font-weight: 700;
  color: var(--bright);
  padding-left: 12px;
}
.grade-cell {
  cursor: pointer;
  user-select: none;
  font-size: 20px;
  font-weight: 900;
  min-width: 68px;
  height: 50px;
  background: #0a101e;
  transition: background 0.12s ease, transform 0.1s ease;
}
.grade-cell:hover {
  background: #17233f;
}
.grade-cell[data-val="✅"] {
  background: rgba(56, 178, 111, 0.24);
  border-color: #38b26f;
}
.grade-cell[data-val="❌"] {
  background: rgba(229, 83, 83, 0.13);
  opacity: 0.78;
}
.grade-cell[data-val="❓"] {
  background: rgba(212, 175, 55, 0.18);
}

/* 7. 3-Role Family RoomSelector (👨 Pai · 👩 Mãe · 👧 Filha JP) */
.role-selector-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 6px;
}
.role-btn {
  background: #0f182b;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: 0.15s;
}
.role-btn:hover { border-color: var(--gold); color: #fff; }
.role-btn.active {
  background: var(--gold);
  color: #000;
  border-color: var(--gold);
  font-weight: 900;
}


