/* 社長AI インタビュー — スマホ優先（iPhone Safari）。大きい文字・大きいマイク */
:root {
  --bg: #f6f5f0;
  --card: #ffffff;
  --ink: #1d2318;
  --muted: #667061;
  --line: #dfe3d6;
  --green: #2f5d1e;
  --green-2: #4f8a2b;
  --accent: #b8860b;
  --pri: #c0392b;
  --danger: #a3271b;
  --radius: 16px;
  font-size: 17px;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic", sans-serif;
  line-height: 1.6;
  -webkit-text-size-adjust: 100%;
  padding-bottom: env(safe-area-inset-bottom);
}
[hidden] { display: none !important; }
.wrap { max-width: 640px; margin: 0 auto; padding: 0 16px 32px; padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right)); }
.boot { text-align: center; color: var(--muted); padding-top: 30vh; }
h1 { font-size: 1.05rem; margin: 0; text-align: center; flex: 1; }
h2 { font-size: 1.05rem; margin: 22px 0 10px; }
.muted { color: var(--muted); }
.small { font-size: .82rem; }
.center { text-align: center; }
.err { color: var(--danger); min-height: 1.4em; }
.note { background: #fff7e0; border: 1px solid #f0d58a; padding: 10px 12px; border-radius: 12px; font-size: .92rem; }

.bar { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 8px; padding: 10px 0; padding-top: max(10px, env(safe-area-inset-top)); background: var(--bg); border-bottom: 1px solid var(--line); margin-bottom: 12px; }
.bar .brand { font-weight: 700; color: var(--green); min-width: 64px; }
.bar-r { min-width: 64px; text-align: right; font-variant-numeric: tabular-nums; font-size: .9rem; color: var(--muted); }
.link { background: none; border: 0; color: var(--green); font-size: 1rem; padding: 8px 4px; min-width: 64px; text-align: left; cursor: pointer; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin: 12px 0; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 48px; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--line); background: #fff; color: var(--ink); font-size: 1rem; font-weight: 600; text-decoration: none; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.btn:disabled { opacity: .45; }
.btn.primary { background: var(--green); border-color: var(--green); color: #fff; }
.btn.accent { background: #fff8e6; border-color: var(--accent); color: #6b4e00; }
.btn.danger { color: var(--danger); border-color: #e6b8b2; }
.btn.big { width: 100%; min-height: 60px; font-size: 1.1rem; margin: 6px 0; }
.btn.small { min-height: 40px; padding: 6px 12px; font-size: .9rem; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 10px 0; }
.row3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px; margin: 10px 0; }
.row-inline { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 8px; }
input[type=text], input[type=password], textarea, select { width: 100%; font: inherit; font-size: 1rem; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: #fff; color: var(--ink); }
.row-inline select { width: auto; flex: 1; min-width: 120px; }
textarea { resize: vertical; line-height: 1.7; }

.login { margin-top: 18vh; display: grid; gap: 12px; }
.login h2 { margin: 0; }

.summary { display: grid; grid-template-columns: repeat(3, 1fr); text-align: center; }
.stat b { display: block; font-size: 1.7rem; color: var(--green); line-height: 1.2; }
.stat span { font-size: .8rem; color: var(--muted); }
.themes { display: grid; gap: 10px; }
.theme { display: grid; gap: 4px; text-align: left; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; font: inherit; color: inherit; cursor: pointer; }
.theme-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.meter { display: block; height: 8px; background: #edf0e6; border-radius: 99px; overflow: hidden; }
.meter > span { display: block; height: 100%; background: var(--green-2); }
.links { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 20px; }
.links .btn { font-size: .88rem; padding: 8px 6px; }

.badges { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-bottom: 6px; }
.badge { font-size: .75rem; font-weight: 700; padding: 2px 8px; border-radius: 99px; background: #e8f0e0; color: var(--green); }
.badge.pri { background: #fde8e6; color: var(--pri); }
.badge.deep { background: #fff3d6; color: #7a5600; }
.badge.ghost { background: #f0f0ec; color: var(--muted); font-weight: 500; }

.qcard .qtext { font-size: 1.32rem; line-height: 1.65; font-weight: 600; margin: 6px 0 8px; }
.qcard details summary { color: var(--muted); font-size: .85rem; cursor: pointer; }
.source { white-space: pre-wrap; }
.status { min-height: 1.5em; color: var(--green); font-weight: 600; text-align: center; margin: 6px 0; }
.micwrap { display: flex; justify-content: center; margin: 6px 0 4px; }
.mic { width: 116px; height: 116px; border-radius: 50%; border: 0; background: var(--green); color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; font-size: 1rem; font-weight: 700; box-shadow: 0 6px 18px rgba(47, 93, 30, .3); cursor: pointer; -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.mic:disabled { background: #b9c2b1; box-shadow: none; }
.mic.on { background: var(--pri); animation: pulse 1.4s ease-in-out infinite; }
.mic-ico { width: 20px; height: 28px; border: 4px solid #fff; border-radius: 11px; position: relative; margin-bottom: 10px; }
.mic-ico::after { content: ""; position: absolute; left: 50%; bottom: -11px; width: 4px; height: 7px; margin-left: -2px; background: #fff; }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(192, 57, 43, .45); } 50% { box-shadow: 0 0 0 16px rgba(192, 57, 43, 0); } }
@media (prefers-reduced-motion: reduce) { .mic.on { animation: none; } }
.interim { min-height: 1.4em; color: var(--muted); font-style: italic; margin: 4px 2px; }
.timer { font-weight: 700; color: var(--ink); }

.done .big-num { font-size: 3rem; font-weight: 800; color: var(--green); margin: 0; }
.filter { display: flex; gap: 10px; align-items: center; }
.filter select { flex: 1; }
.alist { list-style: none; padding: 0; margin: 0; }
.aitem textarea, .aitem input { margin-top: 8px; }
.aq { font-weight: 600; margin: 4px 0; }
.mdpreview { white-space: pre-wrap; word-break: break-word; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px; font-size: .82rem; max-height: 60vh; overflow: auto; }
.chk { display: flex; gap: 10px; align-items: flex-start; margin: 10px 0; }
.chk input { width: 22px; height: 22px; margin-top: 3px; flex: none; }
.settings input[type=range] { width: 100%; }

#toast { position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); transform: translateX(-50%); background: rgba(29, 35, 24, .92); color: #fff; padding: 10px 18px; border-radius: 99px; font-size: .92rem; z-index: 20; max-width: 90vw; }

/* 取材中の主ボタンは画面下に固定（iPhone で話しながら押せるように） */
.interview .actions { position: sticky; bottom: 0; z-index: 4; background: var(--bg); padding: 10px 0 calc(10px + env(safe-area-inset-bottom)); margin-bottom: 0; border-top: 1px solid var(--line); }
