:root {
  --ink: #1c1917;
  --paper: #f4efe6;
  --panel: #fffdf8;
  --line: #e4d8c4;
  --indigo: #1e3a5f;
  --indigo-soft: #e8eef5;
  --vermilion: #9a3412;
  --warn: #b45309;
  --ok: #1f6b4a;
  --muted: #6b6258;
  --font: "IBM Plex Sans JP", "Noto Sans SC", "Noto Sans KR", sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--paper);
}
button, input, select { font: inherit; }
.top {
  background: var(--indigo);
  color: #fff;
  padding: 14px 18px;
}
.top h1 { margin: 4px 0 0; font-size: 1.25rem; font-weight: 650; }
.kicker { margin: 0; letter-spacing: 0.08em; font-size: 0.72rem; font-weight: 700; opacity: 0.8; }
.visitor-sub { margin: 6px 0 0; font-size: 0.88rem; opacity: 0.88; font-weight: 500; }
.visitor-wrap { max-width: 720px; }
.visitor-step { transition: opacity 0.25s ease; }
.visitor-step.is-on { opacity: 1; }
.wrap { max-width: 1100px; margin: 0 auto; padding: 16px; }
.note {
  background: #fff7ed;
  border: 1px solid #f3ddc0;
  color: var(--warn);
  border-radius: 14px;
  padding: 10px 12px;
  font-size: 0.86rem;
  margin: 12px 0;
}
.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 16px;
}
.langs { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0; }
.langs button, .btn {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 8px 14px;
  cursor: pointer;
  font-weight: 700;
}
.langs button.is-on, .btn.primary { background: var(--indigo); color: #fff; border-color: var(--indigo); }
.btn.warn { background: #9a3412; color: #fff; border-color: #9a3412; }
.btn.ghost { background: #fff; color: var(--indigo); }
.btn:disabled { opacity: 0.4; cursor: not-allowed; }
.stage { min-height: 88px; margin-top: 12px; white-space: pre-wrap; line-height: 1.65; }
.label { font-size: 0.75rem; font-weight: 800; color: var(--muted); letter-spacing: 0.04em; }
.big { font-size: 1.2rem; }
.staff-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 12px; }
.metric { display: flex; gap: 10px; flex-wrap: wrap; }
.metric b { display: block; font-size: 1.1rem; }
.pill { display: inline-block; border-radius: 999px; padding: 4px 10px; font-size: 0.75rem; font-weight: 800; }
.pill.ok { background: #dcefe6; color: var(--ok); }
.pill.warn { background: #fde7d4; color: var(--warn); }
.pill.live { background: #fee2e2; color: #991b1b; }
.alert {
  border-radius: 14px;
  padding: 12px;
  font-weight: 700;
}
.alert.red { background: #fee2e2; color: #991b1b; }
.alert.yellow { background: #fef3c7; color: #92400e; }
.qbtns { display: grid; gap: 8px; }
.qbtns button { text-align: left; border-radius: 14px; padding: 10px 12px; }
.history { font-size: 0.82rem; }
.history div { border-bottom: 1px solid var(--line); padding: 6px 0; }
.admin-login { max-width: 360px; margin: 40px auto; }
input[type="password"], input[type="text"] {
  width: 100%;
  padding: 10px;
  border-radius: 12px;
  border: 1px solid var(--line);
}
.row { display: flex; gap: 8px; flex-wrap: wrap; margin: 8px 0; }
.muted { color: var(--muted); font-size: 0.84rem; }
.lang-main { font-weight: 650; }
.lang-ja {
  margin: 10px 0 0;
  padding-top: 8px;
  border-top: 1px dashed var(--line);
  font-size: 0.92rem;
  font-weight: 500;
  color: #4b433a;
  line-height: 1.65;
}
.lang-ja::before {
  content: "日本語：";
  font-weight: 800;
  color: var(--indigo);
  margin-right: 4px;
}
.step { opacity: 0.32; transition: opacity 0.25s ease; }
.step.is-on { opacity: 1; }
.ok-bar {
  background: #9a3412;
  color: #fff;
  border-radius: 16px;
  padding: 14px 16px;
  margin: 12px 0;
}
.ok-bar p { margin: 0 0 10px; font-weight: 700; }
.ok-bar .btn {
  background: #fff;
  color: #9a3412;
  border-color: #fff;
}
.ok-bar .btn:disabled { opacity: 0.5; }
.thinking {
  color: var(--muted);
  font-weight: 600;
  font-style: italic;
}
.nowplay {
  display: inline-block;
  margin-top: 8px;
  font-size: 0.86rem;
  font-weight: 800;
  color: var(--indigo);
}
.sound-gate {
  position: fixed;
  inset: 0;
  z-index: 40;
  background: rgba(28, 25, 23, 0.72);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.sound-gate[hidden] { display: none; }
.sound-gate .panel { max-width: 420px; text-align: center; }
.sound-gate h2 { margin: 0 0 8px; font-size: 1.15rem; }
.demo-panel { margin-top: 18px; border: 1px solid #c7d6ea; background: linear-gradient(180deg, #f8fbff, #fffdf8); }
.demo-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.demo-head h2 { margin: 0 0 6px; font-size: 1.05rem; }
.demo-login { max-width: 520px; }
.demo-advanced { margin-top: 14px; padding-top: 10px; border-top: 1px dashed var(--line); }
.demo-advanced summary { cursor: pointer; font-weight: 800; color: var(--indigo); }
.scenario-btn {
  width: 100%;
  text-align: left;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 14px;
  padding: 10px 12px;
  cursor: pointer;
  font-weight: 700;
}
.scenario-btn:hover { border-color: var(--indigo); background: var(--indigo-soft); }
.flash {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  background: #e8eef5;
  color: var(--indigo);
  font-size: 0.86rem;
  font-weight: 700;
}
.flash[hidden] { display: none; }
@media (max-width: 860px) {
  .staff-grid { grid-template-columns: 1fr; }
}
