:root {
  --bg: #f5f7fa;
  --card: #ffffff;
  --line: #e3e8ef;
  --text: #1c2530;
  --muted: #6b7785;
  --accent: #2f6df6;
  --ok: #1f9d55;
  --warn: #c8861a;
  --danger: #e0483b;
  /* KIPzSwitch ブランド */
  --navy: #111a3a;
  --navy2: #1a2350;
  --kipz-blue: #3b82f6;
  --tally: #ef4444;
  /* 画面identity: 同じトンマナ(寒色)のまま、マイページ=青／SRT HUB=ティールで一目で見分ける */
  --sw-accent: #3b82f6;
  --hub-accent: #14b8a6;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Kaku Gothic ProN", "Noto Sans JP", Meiryo, sans-serif;
  background: var(--bg); color: var(--text); font-size: 15px; line-height: 1.6;
}
.view { min-height: 100vh; }
.view.center { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px; padding: 24px; background: linear-gradient(150deg, var(--navy) 0%, var(--navy2) 60%, #1e3a8a 100%); }

/* 認証系画面（ログイン/登録/決済）の上部ブランド */
.auth-brand { display: inline-flex; align-items: center; gap: 9px; text-decoration: none; }
.auth-brand:hover { opacity: .85; }
.auth-brand .logo-word { font-weight: 800; letter-spacing: -0.02em; font-size: 21px; color: #fff; }
.auth-brand .logo-word .z { color: var(--kipz-blue); }
.auth-brand .logo-word .ti { position: relative; display: inline-block; }
.auth-brand .logo-word .tally { position: absolute; left: 50%; transform: translateX(-50%); bottom: 0.84em; width: 0.26em; height: 0.26em; border-radius: 50%; background: var(--tally); box-shadow: 0 0 6px rgba(239,68,68,.75); }
[hidden] { display: none !important; }
img { max-width: 100%; height: auto; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 4px 20px rgba(20,40,80,.06); }
.view.center .card { border: none; box-shadow: 0 24px 60px rgba(0,0,0,.35); }
.login { width: 100%; max-width: 400px; padding: 32px 28px; }
.brand { font-size: 22px; font-weight: 800; margin: 0 0 4px; letter-spacing: .01em; }
.brand.sm { font-size: 17px; }
.sub { color: var(--muted); margin: 0 0 20px; }
.hint { color: var(--muted); font-size: 12px; text-align: center; margin: 14px 0 0; }

.fld { display: block; font-size: 12px; color: var(--muted); margin: 14px 0 0; }
.fld input {
  width: 100%; margin-top: 5px; padding: 11px 12px; font-size: 15px;
  background: #fff; color: var(--text); border: 1px solid var(--line); border-radius: 10px;
}
.fld input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(47,109,246,.12); }
.cfg { margin: 16px 0 4px; border-top: 1px solid var(--line); padding-top: 10px; }
.cfg summary { cursor: pointer; color: var(--muted); font-size: 12px; }

button { font-family: inherit; cursor: pointer; }
.primary { background: var(--accent); color: #fff; border: none; border-radius: 10px; padding: 11px 18px; font-size: 15px; font-weight: 700; }
.primary:hover { filter: brightness(1.06); }
.primary:disabled { opacity: .55; cursor: default; }
.primary.big { width: 100%; margin-top: 20px; padding: 14px; font-size: 16px; }
.ghost { background: transparent; color: var(--text); border: 1px solid var(--line); border-radius: 10px; padding: 9px 14px; font-size: 14px; }
.ghost:hover { border-color: var(--accent); }
.danger { background: #fff; color: var(--danger); border: 1px solid #f3c6c1; border-radius: 10px; padding: 11px 18px; font-size: 15px; font-weight: 700; }
.danger:hover { background: #fdf1f0; }
.err { color: var(--danger); font-size: 14px; margin: 14px 0 0; white-space: pre-wrap; }

.topbar { display: flex; align-items: center; gap: 12px; padding: 13px 20px; background: var(--navy); }
.topbar .logo.lockup { text-decoration: none; }
.topbar-label { color: #8fa4d9; font-size: 12.5px; font-weight: 700; border-left: 1px solid rgba(255,255,255,.2); padding-left: 12px; }
.topbar .ghost { color: #fff; border-color: rgba(255,255,255,.35); }
.topbar .ghost:hover { border-color: #fff; }
.spacer { flex: 1 1 auto; }
.who { color: #aab4d4; font-size: 13px; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ===== 常設トップナビ（マイページ ⇄ SRT HUB）＋画面identity ===== */
.topbar.tb-sw { border-bottom: 3px solid var(--sw-accent); }
.topbar.tb-hub { border-bottom: 3px solid var(--hub-accent); }
.topnav { display: flex; align-items: center; gap: 2px; margin-left: 6px; padding-left: 12px; border-left: 1px solid rgba(255,255,255,.2); }
.topnav-i { display: inline-flex; align-items: center; }
.topnav-t { display: inline-flex; align-items: center; gap: 7px; padding: 6px 11px; border-radius: 8px; color: #8fa4d9; font-size: 13px; font-weight: 700; text-decoration: none; white-space: nowrap; }
.topnav-t:hover { color: #fff; background: rgba(255,255,255,.08); }
.topnav-t .tn-dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; opacity: .55; flex: none; }
.topnav-t.on { color: #fff; background: rgba(255,255,255,.12); }
.topnav-t.on.t-sw { box-shadow: inset 0 -2px 0 var(--sw-accent); }
.topnav-t.on.t-hub { box-shadow: inset 0 -2px 0 var(--hub-accent); }
.topnav-t.on.t-sw .tn-dot { background: var(--sw-accent); opacity: 1; }
.topnav-t.on.t-hub .tn-dot { background: var(--hub-accent); opacity: 1; }
.tn-ext { color: #7d90c4; text-decoration: none; font-size: 12px; padding: 4px 5px; border-radius: 6px; line-height: 1; }
.tn-ext:hover { color: #fff; background: rgba(255,255,255,.1); }

/* 画面の見出し（どの画面を開いているかを本文側でも明示） */
.page-hero { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin: 4px 0 14px; padding-left: 12px; border-left: 4px solid var(--line); }
.page-hero-t { margin: 0; font-size: 19px; font-weight: 800; letter-spacing: -.01em; }
.page-hero-d { margin: 0; font-size: 12.5px; color: var(--muted); }
.ph-sw { border-left-color: var(--sw-accent); }
.ph-sw .page-hero-t { color: #1d4ed8; }
.ph-hub { border-left-color: var(--hub-accent); }
.ph-hub .page-hero-t { color: #0f766e; }

/* もう一方の画面の状況（HUBページに出す「スイッチャー」ステータス） */
.xstrip { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; background: var(--card); border: 1px solid var(--line); border-left: 4px solid var(--sw-accent); border-radius: 10px; padding: 9px 13px; margin-bottom: 12px; font-size: 13px; }
.xs-k { font-weight: 800; color: #1d4ed8; }
.xs-badge { font-size: 11.5px; font-weight: 700; padding: 2px 9px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); }
.xs-badge.ok { background: #e8f6ee; border-color: #b9e3ca; color: #1f7a45; }
.xs-badge.off { background: #f2f4f7; }
.xs-badge.warn { background: #fdf3e3; border-color: #f0d9ab; color: #8a5d10; }
.xs-badge.live { background: #fdeaea; border-color: #f4bcbc; color: #b3261e; }
.xs-badge.rec { background: #fdeaea; border-color: #f4bcbc; color: #b3261e; }
.xs-d { color: var(--muted); font-size: 12.5px; }
.xs-open { margin-left: auto; font-weight: 700; text-decoration: none; color: #fff; background: var(--sw-accent); padding: 6px 13px; border-radius: 8px; font-size: 12.5px; }
.xs-open:hover { background: #2563eb; }
.xs-go { font-size: 12.5px; font-weight: 700; color: var(--accent); text-decoration: none; }
.xs-go:hover { text-decoration: underline; }

/* マイページのHUB要約に出すライブ受信/送信 */
.hub-sum-live { font-size: 11.5px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: #f2f4f7; color: var(--muted); border: 1px solid var(--line); }
.hub-sum-live.ok { background: #e6f7f4; border-color: #a9e5da; color: #0f766e; }
.hub-sum-live.ng { background: #f2f4f7; color: var(--muted); }
.hub-newtab { display: inline-flex; align-items: center; text-decoration: none; }
/* 色でモノを示す: 青=スイッチャー(セッション) / ティール=SRT HUB。どの画面でも同じ意味で使う */
.card.session { border-left: 3px solid var(--sw-accent); }
.card.hub { border-left: 3px solid var(--hub-accent); }
/* 狭い画面(iPhone等)ではタブを独立行のセグメント風に。メール表示は省いて画面切替を優先する */
@media (max-width: 640px) {
  .topbar { flex-wrap: wrap; gap: 8px; padding: 10px 12px; }
  .topbar .who { display: none; }
  .topnav { order: 3; width: 100%; margin-left: 0; padding-left: 0; border-left: 0; gap: 6px; }
  .topnav-i { flex: 1; }
  .topnav-t { flex: 1; justify-content: center; }
  .xs-open { margin-left: 0; }
}

.wrap { max-width: 620px; margin: 0 auto; padding: 32px 18px; }
.session { padding: 32px 28px; text-align: center; border-top: 3px solid var(--kipz-blue); }
.session .state-h { font-size: 22px; font-weight: 800; margin: 6px 0 8px; }
.session .state-d { color: var(--muted); margin: 0 0 20px; }
.session .actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 8px; }
.session .meta { color: var(--muted); font-size: 12px; margin-top: 18px; }

.statedot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 6px; vertical-align: middle; }
.statedot.run { background: var(--ok); }
.statedot.boot { background: var(--warn); }
.statedot.pause { background: var(--muted); }
.statedot.end { background: var(--danger); }
.statedot.warn { background: var(--danger); box-shadow: 0 0 0 4px rgba(220,38,38,.18); }
/* 終了失敗の警告（確実に目に留める） */
.err-strong { color: var(--danger); font-weight: 700; background: #fdf1f0; border: 1px solid #f3c6c1; border-radius: 10px; padding: 12px 14px; }
.danger.big { width: 100%; margin-top: 6px; padding: 14px; font-size: 16px; background: var(--danger); color: #fff; border-color: var(--danger); }
.danger.big:hover { filter: brightness(1.05); background: var(--danger); }

.open-btn { display: inline-block; background: var(--ok); color: #fff; text-decoration: none; border-radius: 12px; padding: 16px 26px; font-size: 18px; font-weight: 800; }
.open-btn:hover { filter: brightness(1.05); }

.cred { margin: 18px auto 4px; max-width: 360px; background: #f7f9fc; border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; text-align: left; }
.cred .cl { font-size: 11px; color: var(--muted); }
.cred .cv { display: flex; gap: 8px; align-items: center; margin-top: 4px; }
.cred .cv code { flex: 1; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 15px; word-break: break-all; }
.cred .cv button { font-size: 12px; padding: 6px 10px; border: 1px solid var(--line); border-radius: 8px; background: #fff; white-space: nowrap; }
.cred .cnote { font-size: 11px; color: var(--muted); margin-top: 6px; }

/* 起動中カード: カメラ接続先＋受信状態 */
.connbox { margin: 18px auto 4px; max-width: 560px; background: #f7f9fc; border: 1px solid var(--line); border-radius: 10px; padding: 10px 14px 12px; text-align: left; }
.connbox summary { cursor: pointer; font-size: 13px; font-weight: 700; padding: 4px 0; }
.conn-hint { font-size: 11.5px; color: var(--muted); margin: 6px 0 10px; }
.conn-row { display: flex; align-items: center; gap: 8px; padding: 5px 0; border-top: 1px dashed var(--line); }
.conn-cam { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-weight: 700; font-size: 12.5px; width: 44px; flex: none; }
.conn-st { font-size: 11.5px; width: 110px; flex: none; color: var(--muted); font-variant-numeric: tabular-nums; }
.conn-st.ok { color: #1f9d55; font-weight: 700; }
.conn-st.ng { color: #a0a8b3; }
.conn-url { flex: 1; min-width: 0; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 11px; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.conn-copy { font-size: 11.5px; padding: 4px 9px; border: 1px solid var(--line); border-radius: 7px; background: #fff; flex: none; }
.conn-copy:hover { border-color: var(--kipz-blue); }
/* FB②: 接続先の項目分解表示（共通欄＋ポート/ストリームID別掲・クリックでコピー） */
.conn-common { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; margin: 0 0 8px; }
.conn-common-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 2px 0; }
.conn-k { font-size: 11.5px; color: var(--muted); flex: none; }
.conn-v { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; }
.conn-code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; background: #eef2f8; border: 1px solid var(--line); border-radius: 6px; padding: 2px 8px; cursor: pointer; transition: background .15s, border-color .15s; user-select: all; }
.conn-code:hover { border-color: var(--kipz-blue); }
.conn-code.copied { background: #d9f2e4; border-color: #1f9d55; }
.conn-f { width: 64px; flex: none; }
.conn-f.wide { width: 96px; }
.conn-head { border-top: none; }
.conn-head .conn-st, .conn-head .conn-f { font-size: 10.5px; color: var(--muted); }
.conn-sp { flex: 1; text-align: right; }
.conn-hub-note { font-size: 11.5px; color: #1f6feb; margin: 0 0 8px; }
.conn-hub-warn { font-size: 12px; color: #b54708; font-weight: 700; margin: 0 0 8px; }
/* PC（OBS）接続の推奨設定ヘルプ（connbox内の入れ子） */
.connbox-sub { max-width: 560px; margin: 8px auto 4px; background: #fbfcfe; }
.conn-obs-row { padding: 3px 0; }
.conn-obs-row .conn-k { min-width: 132px; }
.conn-obs-note { font-size: 11px; color: var(--muted); }
.conn-obs-row.key .conn-v { background: #fff5e6; border: 1px solid #f0c98a; border-radius: 6px; padding: 1px 7px; font-weight: 700; }
.conn-obs-row.key .conn-obs-note { color: #b25e00; font-weight: 600; }

/* ===== SRT HUB カード ===== */
.card.hub { margin-top: 14px; padding: 24px 26px; text-align: left; }
/* 複数HUB: マイページ要約リスト＋専用ページ */
.hub-sum { margin: 10px 0 4px; display: flex; flex-direction: column; gap: 8px; }
.hub-sum-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px 10px; background: #f7f9fc; border: 1px solid var(--line); border-radius: 8px; }
.hub-sum-name { font-weight: 800; font-size: 13.5px; min-width: 90px; }
.hub-sum-period { font-size: 12px; }
.hub-sum-ip { font-size: 12.5px; margin-left: auto; }
#hub-cards { margin-top: 4px; }
.hub-item { margin-top: 14px; }
.hub-name-l { display: block; font-size: 12.5px; color: var(--muted); margin: 4px 0 10px; }
.hub-name-in { display: block; width: 100%; max-width: 340px; margin-top: 5px; font-size: 14px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; }
.hub-page-lead { text-align: left; }
/* C案従量: 概算計算機＋ライブ料金メーター */
.hub-calc { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin: 12px 0 4px; padding: 10px 12px; background: #f2f5fb; border-radius: 10px; }
.hub-calc-l { font-size: 12.5px; color: var(--muted); }
.hub-calc-in { width: 64px; font-size: 13.5px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 7px; text-align: center; }
.hub-calc-out { font-size: 13.5px; color: var(--text); }
.hub-usage { font-size: 12.5px; color: #1f6feb; font-weight: 700; margin: 6px 0 2px; min-height: 1em; }

/* 仕様・諸元（マイページ下部・ログイン後のみ表示） */
.card.specs { margin-top: 16px; padding: 16px 20px; text-align: left; }
.specs-sum { cursor: pointer; font-size: 14px; font-weight: 800; padding: 4px 0; }
.spec-sec { margin: 14px 0 4px; }
.spec-h { margin: 0 0 6px; font-size: 13px; color: var(--kipz-blue); }
.spec-t { width: 100%; border-collapse: collapse; }
.spec-t tr { border-top: 1px dashed var(--line); }
.spec-k { width: 32%; min-width: 120px; padding: 6px 10px 6px 0; font-size: 12px; font-weight: 700; color: var(--muted); vertical-align: top; }
.spec-v { padding: 6px 0; font-size: 12.5px; line-height: 1.55; }
.spec-note { margin: 12px 0 0; font-size: 11px; color: var(--muted); }
.hub-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.hub-h { margin: 0; font-size: 16px; }
.hub-badge { font-size: 11px; font-weight: 800; padding: 2px 9px; border-radius: 999px; background: #eef1f6; color: #667; }
.hub-badge.ok { background: #d9f2e4; color: #156d3d; }
.hub-badge.warn { background: #fdf0d5; color: #9a6700; }
.hub-price { font-size: 11.5px; color: var(--muted); margin-left: auto; }
.hub-d { font-size: 12.5px; color: var(--muted); margin: 8px 0 0; }
.hub-hostrow { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 10px 0 4px; }
.hub-strow { margin: 8px 0 2px; }
.hub-st-h { font-size: 11px; color: var(--muted); font-weight: 700; margin: 8px 0 4px; }
.hub-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.hub-chip { font-size: 11px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; padding: 2px 8px; border-radius: 6px; background: #eef1f6; color: #99a; border: 1px solid var(--line); }
.hub-chip.ok { background: #d9f2e4; color: #156d3d; border-color: #9fd8b7; font-weight: 700; }
.hub-chip.ng { background: #f6f7f9; color: #a0a8b3; }
.hub-send-row { display: flex; align-items: center; gap: 8px; padding: 2px 0; }
.hub-send-host { font-size: 12px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.hub-st-note { font-size: 11.5px; color: var(--muted); margin: 6px 0 0; }
.hub-cfg { margin: 10px 0 0; background: #f7f9fc; border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; }
.hub-cfg summary { cursor: pointer; font-size: 12.5px; font-weight: 700; }
.hub-cfg-hint { font-size: 11.5px; color: var(--muted); margin: 6px 0 8px; }
.hub-cfg-row { display: flex; align-items: center; gap: 8px; padding: 4px 0; flex-wrap: wrap; }
.hub-cfg-en { display: flex; align-items: center; gap: 4px; font-size: 12px; width: 72px; flex: none; }
.hub-cfg-host { flex: 1; min-width: 180px; font-size: 12.5px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 7px; }
.hub-cfg-port, .hub-cfg-lat { width: 84px; font-size: 12.5px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 7px; }
/* カメラ中心: CAM1〜8 ブロック（各カメラ最大3口） */
.hub-cam-block { border: 1px solid var(--line); border-radius: 9px; padding: 4px 10px 8px; margin: 8px 0; background: rgba(0,0,0,.015); }
.hub-cam-title { font-size: 13px; font-weight: 800; cursor: pointer; padding: 6px 2px; list-style: none; }
.hub-cam-title::-webkit-details-marker { display: none; }
.hub-cam-title::before { content: "▸"; display: inline-block; width: 1em; color: var(--muted); font-weight: 400; }
details[open] > .hub-cam-title::before { content: "▾"; }
.hub-cam-count { font-size: 11.5px; font-weight: 500; color: var(--muted); }
.hub-slot { display: flex; align-items: center; gap: 8px; padding: 7px 0 7px 1.2em; flex-wrap: wrap; border-top: 1px dashed var(--line); }
.hub-slot:first-of-type { border-top: 0; }
.hub-slot-no { font-size: 11.5px; font-weight: 700; color: var(--muted); width: 54px; flex: none; }
.hub-slot-k { font-size: 12.5px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 7px; background: #fff; }
.hub-f { display: inline-flex; align-items: center; gap: 5px; }
.hub-f-l { font-size: 11px; color: var(--muted); white-space: nowrap; }
.hub-cfg-sid { width: 132px; font-size: 12.5px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 7px; }
.hub-cfg-pw { width: 118px; font-size: 12.5px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 7px; }
.hub-cfg-host:disabled { background: #f2f4f7; color: var(--muted); }
/* 口ごとの送出状況（FB①: 送れているか一目で分かるように） */
.hub-slot-st { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: #f2f4f7; color: var(--muted); border: 1px solid var(--line); white-space: nowrap; }
.hub-slot-st.ok { background: #e8f6ee; border-color: #b9e3ca; color: #1f7a45; }
.hub-slot-st.ng { background: #fdf3e3; border-color: #f0d9ab; color: #8a5d10; }
.hub-actions { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.hub-remove { color: #b42318; }
.hub-period { font-size: 11.5px; color: var(--muted); }
.rsv-day.rsv-now .d1 { color: #1f6feb; font-weight: 800; }
.rsv-day.rsv-now.on .d1 { color: #fff; }
.rsv-eip-wait { font-size: 11px; }
.rsv-item .conn-code { font-size: 12.5px; font-weight: 700; }

/* FB④: おすすめ（予約）カードを主導線に */
.choice.recommended { position: relative; border-color: var(--kipz-blue); box-shadow: 0 2px 12px rgba(31,111,235,.14); }
.choice-badge { position: absolute; top: -10px; left: 14px; background: var(--kipz-blue); color: #fff; font-size: 11px; font-weight: 800; padding: 2px 10px; border-radius: 999px; }

/* 共通の期間ピッカー（予約・HUB） */
.pp { text-align: left; }
.pp-when { margin-top: 4px; }
.pp-cal-row { display: flex; align-items: center; gap: 10px; margin-top: 10px; flex-wrap: wrap; }
.pp-cal { font-size: 13px; padding: 7px 9px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.pp-cal:disabled { opacity: .5; }
.rsv-hours.pp-durs { grid-template-columns: repeat(5, 1fr); }
.pp-dur { padding: 9px 4px; font-size: 12.5px; }
.pp-dur:disabled { opacity: .4; }
@media (max-width: 520px) { .rsv-hours.pp-durs { grid-template-columns: repeat(3, 1fr); } }

/* FB②: スイッチャーへ送るトグル */
.hub-cfg-sw { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 13px; font-weight: 700; margin: 4px 0 8px; }
.hub-cfg-sw input { width: 17px; height: 17px; }
.hub-cfg-swnote { font-size: 11.5px; font-weight: 400; color: var(--muted); }
.hub-cfg-host { flex: 1; min-width: 150px; }
.hub-cfg-port, .hub-cfg-lat { width: 72px; }
.hub-card .rsv-summary { margin-top: 14px; padding: 12px; }
.bill-kind { font-size: 10.5px; font-weight: 800; padding: 1px 7px; border-radius: 999px; background: #e8edff; color: #3451b2; flex: none; }

.spinner { width: 38px; height: 38px; border: 4px solid var(--line); border-top-color: var(--accent); border-radius: 50%; margin: 8px auto 16px; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ===== セッション状態の演出: 起動中=緑グラデ点滅 / 終了中=赤オレンジ点滅（ぱっと見で状態が分かる） ===== */
/* 起動中・再起動中: 流れる緑グラデ＋緑グロー点滅 */
.session.phase-start {
  border-top-color: #16c060;
  background: linear-gradient(125deg, #eafff2 0%, #b3f2cd 22%, #eafff2 45%, #c8f7dd 68%, #eafff2 100%);
  background-size: 300% 300%;
  animation: phaseSweep 2.4s ease-in-out infinite, phaseGlowGreen 1.1s ease-in-out infinite;
}
.session.phase-start .spinner { border-top-color: #16c060; }
.session.phase-start .state-h { color: #0e7a3c; }
/* 終了中: 流れる赤オレンジグラデ＋赤グロー点滅（起動よりやや速く＝止める動作感） */
.session.phase-end {
  border-top-color: #ff5a1f;
  background: linear-gradient(125deg, #fff2ea 0%, #ffccb0 22%, #fff2ea 45%, #ffd8c2 68%, #fff2ea 100%);
  background-size: 300% 300%;
  animation: phaseSweep 1.8s ease-in-out infinite, phaseGlowRed 0.85s ease-in-out infinite;
}
.session.phase-end .spinner { border-top-color: #ff5a1f; }
.session.phase-end .state-h { color: #c53a12; }
@keyframes phaseSweep { 0% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } 100% { background-position: 0% 50%; } }
@keyframes phaseGlowGreen { 0%, 100% { box-shadow: 0 4px 14px rgba(0,0,0,.06), 0 0 0 0 rgba(22,192,96,0); } 50% { box-shadow: 0 4px 14px rgba(0,0,0,.06), 0 0 30px 2px rgba(22,192,96,.45); } }
@keyframes phaseGlowRed { 0%, 100% { box-shadow: 0 4px 14px rgba(0,0,0,.06), 0 0 0 0 rgba(255,90,30,0); } 50% { box-shadow: 0 4px 14px rgba(0,0,0,.06), 0 0 32px 2px rgba(255,90,30,.5); } }
/* 動きを抑える設定の人には点滅を止めて、色と縁だけで状態を示す */
@media (prefers-reduced-motion: reduce) {
  .session.phase-start, .session.phase-end { animation: none; background-size: 100% 100%; }
}

.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: #1c2530; color: #fff; padding: 11px 18px; border-radius: 10px; font-size: 14px; z-index: 20; box-shadow: 0 8px 28px rgba(0,0,0,.25); max-width: 90vw; }
.toast.bad { background: var(--danger); }

/* ===== ロゴ（マーク + タリーi ワードマーク） ===== */
.logo.lockup { display: inline-flex; align-items: center; gap: 8px; }
.logo-mark { display: block; border-radius: 6px; }
.logo-word { font-weight: 800; letter-spacing: -0.02em; font-size: 19px; color: #fff; }
.logo-word .z { color: var(--kipz-blue); }
.logo-word .ti { position: relative; display: inline-block; }
.logo-word .tally {
  position: absolute; left: 50%; transform: translateX(-50%);
  bottom: 0.84em; width: 0.26em; height: 0.26em; border-radius: 50%;
  background: var(--tally); box-shadow: 0 0 6px rgba(239,68,68,.75);
}
.logo.lockup.dk .logo-word { color: var(--navy); font-size: 17px; }
.logo.lockup.dk .tally { box-shadow: none; }
.logo.lockup.ft .logo-word { font-size: 15px; }
/* 旧ロゴ表記の互換 */
.logo { font-weight: 800; letter-spacing: .01em; }
.logo .sw { color: var(--kipz-blue); }
.logo .by { font-size: 11px; color: var(--muted); font-weight: 600; margin-left: 6px; }

/* ===== 公開ナビ ===== */
.navbar { display: flex; align-items: center; gap: 16px; padding: 12px 22px; background: rgba(17,26,58,.96); color: #fff; position: sticky; top: 0; z-index: 6; backdrop-filter: blur(6px); }
.nav-links { display: flex; gap: 4px; margin-left: 10px; }
.nav-links a { color: #c9d3ee; text-decoration: none; font-size: 13.5px; font-weight: 600; padding: 7px 10px; border-radius: 8px; }
.nav-links a:hover { color: #fff; background: rgba(255,255,255,.08); }
.navbar .nav-spacer { flex: 1 1 auto; }
.navbar .nav-login { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,.35); border-radius: 9px; padding: 8px 14px; font-size: 14px; font-weight: 600; }
.navbar .nav-login:hover { border-color: #fff; }
.navbar .nav-signup { background: var(--kipz-blue); color: #fff; border: none; border-radius: 9px; padding: 9px 16px; font-size: 14px; font-weight: 700; }
.navbar .nav-signup:hover { filter: brightness(1.08); }
.navbar .nav-contact { background: var(--kipz-blue); color: #fff; text-decoration: none; border-radius: 9px; padding: 9px 16px; font-size: 14px; font-weight: 700; }
.navbar .nav-contact:hover { filter: brightness(1.08); }

/* ===== ヒーロー ===== */
.hero { background: linear-gradient(150deg, var(--navy) 0%, var(--navy2) 55%, #1e3a8a 100%); color: #fff; padding: 56px 22px 34px; }
.hero-inner { max-width: 1120px; margin: 0 auto; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 40px; align-items: center; }
.hero .tagline { display: inline-flex; align-items: center; gap: 8px; color: #a9b8e0; font-size: 13.5px; font-weight: 700; margin: 0 0 16px; }
.hero .tagline::before { content: ""; width: 26px; height: 2px; border-radius: 2px; background: var(--kipz-blue); }
.hero h1 { font-size: 40px; font-weight: 800; margin: 0 0 16px; line-height: 1.25; letter-spacing: .01em; }
.hero p.lead { color: #d6ddf2; font-size: 16px; margin: 0 0 26px; }
.hero p.lead b { color: #fff; }
.hero .cta { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.hero .cta .primary.big { width: auto; min-width: 200px; margin-top: 0; background: var(--kipz-blue); }
.ghost-light { display: inline-block; background: rgba(255,255,255,.08); color: #fff; border: 1px solid rgba(255,255,255,.3); border-radius: 10px; padding: 13px 20px; font-size: 15px; font-weight: 700; text-decoration: none; text-align: center; }
.ghost-light:hover { background: rgba(255,255,255,.15); }

.hero-shot { margin: 0; }
.hero-shot .laptop { background: #0b1329; border: 1px solid rgba(255,255,255,.16); border-radius: 14px; padding: 10px 10px 14px; box-shadow: 0 24px 60px rgba(0,0,0,.45); }
.hero-shot .laptop img { display: block; width: 100%; height: auto; border-radius: 7px; }
.hero-shot figcaption { text-align: center; color: #8fa4d9; font-size: 12px; margin-top: 10px; }

.badge-strip { max-width: 1120px; margin: 40px auto 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.badge-strip li { background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.14); border-radius: 12px; padding: 12px 16px; display: flex; flex-direction: column; gap: 2px; }
.badge-strip b { font-size: 15px; }
.badge-strip span { color: #a9b8e0; font-size: 12px; }

/* ===== 課題提起 ===== */
.problem { background: #0d142e; color: #fff; text-align: center; padding: 52px 22px; }
.problem-line { color: #a9b8e0; font-size: 17px; margin: 0 0 14px; line-height: 1.9; }
.problem-answer { font-size: 24px; font-weight: 800; margin: 0; }
.problem-answer b { color: var(--kipz-blue); }

/* ===== セクション共通 ===== */
.how, .steps3, .featzig, .scenes, .pricing, .flow, .security, .faq, .about { padding: 64px 22px; }
.how h2, .steps3 h2, .featzig h2, .stability h2, .scenes h2, .pricing h2, .flow h2, .security h2, .faq h2, .about h2, .contact h2 { text-align: center; font-size: 27px; font-weight: 800; margin: 0 0 14px; letter-spacing: .01em; }
.sec-lead { text-align: center; color: var(--muted); max-width: 640px; margin: 0 auto 36px; }
.sec-lead-w { text-align: center; color: #a9b8e0; max-width: 640px; margin: 0 auto 36px; }

/* ===== 構成図 ===== */
.how { background: #fff; }
.diagram { max-width: 1000px; margin: 0 auto; }
.diagram svg { width: 100%; height: auto; display: block; }
.dg-box { fill: #f7f9fd; stroke: var(--line); stroke-width: 1.5; }
.dg-cloud { fill: var(--navy); stroke: none; }
.dg-h { font-size: 17px; font-weight: 800; fill: var(--text); }
.dg-hw { fill: #fff; }
.dg-s { font-size: 12.5px; fill: var(--muted); }
.dg-sw { fill: #8fa4d9; }
.dg-phones rect { fill: var(--kipz-blue); opacity: .85; }
.dg-chip { fill: rgba(59,130,246,.18); }
.dg-chip2 { fill: rgba(239,68,68,.22); }
.dg-c { font-size: 12.5px; font-weight: 700; fill: #dbe6ff; }
.dg-cw { fill: #fff; }
.dg-lbl { font-size: 13px; font-weight: 800; fill: var(--kipz-blue); }
.dg-note { font-size: 11px; fill: var(--muted); }
.dg-arrow { stroke: var(--kipz-blue); stroke-width: 3; fill: none; }
.dg-live { fill: var(--tally); }
.dg-play { fill: #fff; }
.dg-op { fill: var(--navy2); }

/* ===== 3ステップ ===== */
.steps3 { background: var(--bg); }
.steps3-grid { max-width: 980px; margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.st3 { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 24px; position: relative; }
.st3-n { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 50%; background: var(--kipz-blue); color: #fff; font-weight: 800; font-size: 16px; margin-bottom: 12px; }
.st3 h3 { margin: 0 0 6px; font-size: 17px; }
.st3 p { margin: 0; color: var(--muted); font-size: 14px; }

/* ===== 機能ジグザグ ===== */
.featzig { background: #fff; }
.fz { max-width: 1060px; margin: 0 auto 56px; display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 40px; align-items: center; }
.fz:last-child { margin-bottom: 0; }
.fz.rev .fz-txt { order: 2; }
.fz.rev .fz-img { order: 1; }
.fz-txt h3 { font-size: 21px; font-weight: 800; margin: 0 0 10px; }
.fz-txt p { color: var(--muted); margin: 0; }
.fz-img { margin: 0; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; box-shadow: 0 10px 34px rgba(20,40,80,.14); background: #0d142e; }
.fz-img img { display: block; width: 100%; height: auto; }

/* ===== 堅牢性 ===== */
.stability { background: var(--navy); color: #fff; padding: 64px 22px; }
.stb-grid { max-width: 1060px; margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.stb { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12); border-radius: 14px; padding: 20px 22px; }
.stb h3 { margin: 0 0 8px; font-size: 16px; color: #fff; }
.stb h3::before { content: "●"; color: var(--tally); font-size: 10px; margin-right: 8px; vertical-align: 2px; }
.stb p { margin: 0; color: #c2cdec; font-size: 13.5px; }
.stb p b { color: #fff; }
.stb-proof { max-width: 1060px; margin: 26px auto 0; text-align: center; background: rgba(59,130,246,.14); border: 1px solid rgba(59,130,246,.4); color: #dbe6ff; border-radius: 12px; padding: 13px 18px; font-size: 14px; font-weight: 600; }

/* ===== 利用シーン ===== */
.scenes { background: var(--bg); }
.scene-grid { max-width: 1020px; margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.scene { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 24px; display: flex; flex-direction: column; }
.scene h3 { margin: 0 0 8px; font-size: 17px; }
.scene p { margin: 0 0 14px; color: var(--muted); font-size: 14px; flex: 1; }
.scene-meta { font-size: 12px; color: var(--kipz-blue); font-weight: 700; background: rgba(59,130,246,.1); border-radius: 8px; padding: 6px 10px; align-self: flex-start; }

/* ===== 料金 ===== */
.pricing { background: #fff; }
.price-wrap { max-width: 900px; margin: 0 auto; display: grid; grid-template-columns: 1fr 1fr; gap: 22px; align-items: start; }
.price-card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 28px; text-align: center; box-shadow: 0 6px 24px rgba(20,40,80,.08); }
.price-card .amt { font-size: 32px; font-weight: 800; }
.price-card .amt small { font-size: 15px; color: var(--muted); font-weight: 600; }
.price-card .row { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px dashed var(--line); font-size: 15px; }
.price-card .row:last-of-type { border-bottom: none; }
.price-card .note { color: var(--muted); font-size: 12px; margin-top: 14px; text-align: left; }
.price-sim { background: var(--navy); color: #fff; border-radius: 16px; padding: 28px; }
.price-sim h3 { margin: 0 0 14px; font-size: 17px; }
.price-sim label { display: block; font-size: 14px; color: #c2cdec; }
.price-sim label b { color: #fff; font-size: 16px; margin-left: 6px; }
.price-sim input[type="range"] { width: 100%; margin: 14px 0 6px; accent-color: var(--kipz-blue); }
.sim-total { font-size: 15px; margin: 12px 0 16px; color: #c2cdec; }
.sim-total b { font-size: 30px; font-weight: 800; color: #fff; margin: 0 6px; font-variant-numeric: tabular-nums; }
.sim-total span { display: block; font-size: 12px; color: #8fa4d9; margin-top: 4px; }
.sim-examples { display: flex; flex-direction: column; gap: 6px; border-top: 1px solid rgba(255,255,255,.14); padding-top: 14px; }
.sim-examples span { font-size: 13px; color: #c2cdec; }

/* ===== 導入の流れ ===== */
.flow { background: var(--bg); }
.flow-list { max-width: 760px; margin: 0 auto; padding: 0; list-style: none; counter-reset: flowc; }
.flow-list li { counter-increment: flowc; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 20px 22px 20px 66px; margin-bottom: 12px; position: relative; }
.flow-list li::before { content: counter(flowc); position: absolute; left: 20px; top: 20px; width: 30px; height: 30px; border-radius: 50%; background: var(--navy); color: #fff; font-weight: 800; display: flex; align-items: center; justify-content: center; font-size: 14px; }
.flow-list b { font-size: 16px; }
.flow-list p { margin: 4px 0 0; color: var(--muted); font-size: 14px; }

/* ===== セキュリティ ===== */
.security { background: #fff; }
.sec-list { max-width: 760px; margin: 0 auto; padding: 0; list-style: none; }
.sec-list li { padding: 14px 4px 14px 34px; border-bottom: 1px solid var(--line); font-size: 14.5px; color: var(--muted); position: relative; }
.sec-list li::before { content: "🔒"; position: absolute; left: 4px; }
.sec-list li b { color: var(--text); margin-right: 6px; }
.sec-list li:last-child { border-bottom: none; }

/* ===== FAQ ===== */
.faq { background: var(--bg); }
.faq details { max-width: 760px; margin: 0 auto 10px; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 0 18px; }
.faq summary { cursor: pointer; font-weight: 700; font-size: 15px; padding: 15px 4px; list-style: none; position: relative; padding-right: 30px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 6px; top: 50%; transform: translateY(-50%); color: var(--kipz-blue); font-size: 20px; font-weight: 700; }
.faq details[open] summary::after { content: "−"; }
.faq details p { margin: 0 0 16px; color: var(--muted); font-size: 14px; }

/* ===== 運営 ===== */
.about { background: #fff; }
.about-body { max-width: 640px; margin: 0 auto; text-align: center; color: var(--muted); }
.about-body a { color: var(--kipz-blue); font-weight: 700; }

/* ===== クロージングCTA ===== */
.contact { background: linear-gradient(150deg, var(--navy) 0%, var(--navy2) 60%, #1e3a8a 100%); color: #fff; text-align: center; padding: 68px 22px; }
.contact p { color: #c2cdec; max-width: 620px; margin: 0 auto 26px; }
.contact-cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.contact-cta .primary.big { width: auto; min-width: 220px; margin-top: 0; background: var(--kipz-blue); text-decoration: none; display: inline-block; }

/* ===== フッター ===== */
.site-footer { background: #0d142e; color: #8fa4d9; text-align: center; font-size: 12px; padding: 26px 22px; display: flex; flex-direction: column; gap: 10px; align-items: center; }
.ft-links { color: #6b7aa8; }

/* ===== 起動方法の選択（即利用 / 予約） ===== */
.choose { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 6px; }
@media (max-width: 480px) { .choose { grid-template-columns: 1fr; } }
.choice { text-align: left; border: 1px solid var(--line); border-radius: 12px; padding: 16px; background: #fff; }
.choice h4 { margin: 0 0 4px; font-size: 15px; }
.choice p { margin: 0 0 12px; font-size: 12px; color: var(--muted); min-height: 48px; }
.choice .warn { color: var(--warn); }
.choice button { width: 100%; }

/* 課金表示（マイページ） */
.bill { margin: 16px auto 4px; max-width: 360px; background: #f7f9fc; border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; text-align: left; }
.bill .br { display: flex; justify-content: space-between; padding: 4px 0; font-size: 14px; }
.bill .br .k { color: var(--muted); }
.bill .br .v { font-weight: 700; font-variant-numeric: tabular-nums; }
.bill .est { color: var(--muted); font-size: 11px; margin-top: 6px; }
.mgmtno { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }

/* 予約UI: 日付チップ＋時刻グリッド（PC/タブレットのタップ操作向け） */
.rsv-sec { text-align: left; font-size: 13px; font-weight: 700; color: var(--muted); margin: 18px 0 8px; }
.rsv-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.rsv-day { display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 8px 2px; border: 1px solid var(--line); border-radius: 10px; background: #fff; min-height: 52px; }
.rsv-day .d1 { font-size: 14px; font-weight: 700; }
.rsv-day .d2 { font-size: 11px; color: var(--muted); }
.rsv-day.sat .d2 { color: #2f6df6; }
.rsv-day.sun .d2 { color: #e0483b; }
.rsv-day:hover { border-color: var(--kipz-blue); }
.rsv-day.on { background: var(--kipz-blue); border-color: var(--kipz-blue); }
.rsv-day.on .d1, .rsv-day.on .d2 { color: #fff; }
.rsv-hours { display: grid; grid-template-columns: repeat(12, 1fr); gap: 6px; }
.rsv-hour { padding: 9px 0; border: 1px solid var(--line); border-radius: 9px; background: #fff; font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; }
.rsv-hour:hover { border-color: var(--kipz-blue); }
.rsv-hour.on { background: var(--kipz-blue); border-color: var(--kipz-blue); color: #fff; }
.rsv-free { display: flex; align-items: center; gap: 10px; margin-top: 10px; flex-wrap: wrap; }
.rsv-free-l { font-size: 12.5px; color: var(--muted); }
#rsv-date-free { padding: 8px 10px; border: 1px solid var(--line); border-radius: 9px; font: inherit; background: #fff; color: var(--text); }
#rsv-date-free:focus { outline: none; border-color: var(--kipz-blue); box-shadow: 0 0 0 3px rgba(59,130,246,.14); }
.rsv-minrow { display: flex; align-items: center; justify-content: center; gap: 16px; margin-top: 10px; flex-wrap: wrap; }
.rsv-minrow .rsv-mins { margin-top: 0; }
.rsv-min-free-w { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); }
#rsv-min-free { width: 66px; padding: 8px 6px; border: 1px solid var(--line); border-radius: 9px; font: inherit; text-align: center; background: #fff; }
#rsv-min-free:focus { outline: none; border-color: var(--kipz-blue); box-shadow: 0 0 0 3px rgba(59,130,246,.14); }
.rsv-mins { display: flex; gap: 8px; margin-top: 10px; justify-content: center; }
.rsv-min { padding: 8px 18px; border: 1px solid var(--line); border-radius: 999px; background: #fff; font-size: 13.5px; font-weight: 700; }
.rsv-min:hover { border-color: var(--kipz-blue); }
.rsv-min.on { background: var(--navy); border-color: var(--navy); color: #fff; }
.rsv-summary { display: flex; align-items: center; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 20px; padding: 14px; background: #f2f5fb; border-radius: 12px; }
.rsv-sum { font-size: 15px; color: var(--muted); }
.rsv-sum.ok { color: var(--text); font-weight: 800; font-size: 16px; }
.rsv-summary .primary:disabled { opacity: .45; }
.rsv-note { margin-top: 12px; text-align: left; }
.rsv-list-h { margin: 18px 0 8px; font-size: 14px; text-align: left; }
.rsv-pill { font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: #eef1f6; color: var(--muted); white-space: nowrap; }
.rsv-pill.st-cr_pending { background: #fff3d6; color: #8a6d1a; }
.rsv-pill.st-cr_secured { background: #e1f5e9; color: #1f9d55; }
.rsv-pill.st-launched { background: #e3edff; color: #2f6df6; }
@media (max-width: 640px) {
  .rsv-hours { grid-template-columns: repeat(8, 1fr); }
  .rsv-days { grid-template-columns: repeat(7, 1fr); }
}

/* 予約一覧（Package D） */
.rsv-list { max-width: 420px; margin-left: auto; margin-right: auto; text-align: left; }
.rsv-list h4 { font-size: 14px; }
.rsv-item { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; margin-bottom: 6px; background: #fff; }
.rsv-when { flex: 1; font-size: 14px; font-variant-numeric: tabular-nums; }
.rsv-st { font-size: 12px; color: var(--muted); }
.rsv-cancel { padding: 4px 10px !important; font-size: 12px; width: auto !important; }
.rsv-item { flex-wrap: wrap; }
.rsv-launch { padding: 5px 12px !important; font-size: 12px; width: auto !important; }
.rsv-launched { font-size: 12px; color: #16a34a; font-weight: 700; }
.rsv-badge { max-width: 520px; margin: 0 auto; padding: 9px 13px; border-radius: 8px; background: #eef4ff; border: 1px solid #cdddff; color: #1d3a8a; font-size: 13px; line-height: 1.5; }

/* マイページ トップの予約枠カード（起動できる予約を目立たせる） */
.none-rsv { display: flex; flex-direction: column; gap: 8px; margin: 4px auto 16px; max-width: 560px; text-align: left; }
.none-rsv:empty { display: none; }
.none-rsv-h { font-size: 12px; font-weight: 800; color: var(--muted); margin-top: 4px; }
.none-rsv-h.go { color: var(--ok); font-size: 13px; }
.none-rsv-card { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; background: #fff; display: flex; flex-direction: column; gap: 8px; }
.none-rsv-card.go { border-color: var(--ok); background: #f2fbf6; box-shadow: 0 2px 12px rgba(31,157,85,.14); }
.none-rsv-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.none-rsv-when { flex: 1; font-size: 14.5px; font-weight: 700; font-variant-numeric: tabular-nums; }
.none-rsv-ip { display: flex; align-items: center; gap: 8px; font-size: 12.5px; }
.none-rsv-ip-l { color: var(--muted); font-weight: 700; }
.none-rsv-ip .conn-code { font-size: 12.5px; font-weight: 700; }
.none-rsv-acts { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.none-rsv-go { width: auto !important; padding: 10px 20px !important; font-size: 15px !important; }
.none-rsv-card.go .none-rsv-go { background: var(--ok); }
.none-rsv-wait { flex: 1; font-size: 13px; color: var(--muted); }
.none-rsv-cancel { padding: 6px 12px !important; font-size: 12px; width: auto !important; margin-left: auto; }

/* 新規登録 / 決済登録のステップ */
.steps { display: flex; gap: 8px; justify-content: center; margin: 0 0 16px; }
.steps .stp { font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 5px; }
.steps .stp .n { width: 18px; height: 18px; border-radius: 50%; background: var(--line); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: 11px; }
.steps .stp.active .n { background: var(--kipz-blue); }
.steps .stp.active { color: var(--text); font-weight: 600; }
.card-input { border: 1px solid var(--line); border-radius: 10px; padding: 12px; background: #fff; color: var(--muted); font-size: 14px; }
.stripe-note { background: #fff7e0; color: #8a6d1a; border: 1px solid #f0e3b0; border-radius: 8px; padding: 10px 12px; font-size: 12px; margin-top: 12px; }
.link-btn { background: none; border: none; color: var(--kipz-blue); font-size: 13px; cursor: pointer; padding: 6px; }
.link-btn:hover { text-decoration: underline; }
.pm-row { display: flex; gap: 10px; }
.pm-row .pm-exp { flex: 1; }
.pm-row .pm-cvc { width: 110px; }

/* #5 起動時の配信先・エンコーダ設定フォーム */
.start-config { display: flex; flex-direction: column; gap: 12px; text-align: left; }
.sc-field { display: flex; flex-direction: column; gap: 4px; }
.sc-field .sc-label { font-size: 13px; font-weight: 600; }
.sc-field input, .sc-field select { padding: 9px 11px; border: 1px solid #d4d4d8; border-radius: 8px; font: inherit; background: #fff; width: 100%; box-sizing: border-box; }
.sc-group { display: flex; flex-direction: column; gap: 10px; }
.sc-enc { border: 1px solid #d4d4d8; border-radius: 8px; padding: 8px 12px; }
.sc-enc > summary { cursor: pointer; font-size: 13px; font-weight: 600; }
.sc-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-top: 8px; }
.sc-actions { display: flex; gap: 10px; margin-top: 6px; }

/* 招待制の案内（自由登録が未解禁の間。ヒーロー＝濃紺背景に合わせる） */
.invite-note { margin: 18px 0 0; max-width: 600px; padding: 11px 16px; border-radius: 10px; font-size: 13.5px; line-height: 1.6; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.22); color: #eef2ff; }

/* ===== レスポンシブ ===== */
@media (max-width: 960px) {
  .hero-inner { grid-template-columns: 1fr; gap: 30px; }
  .hero h1 { font-size: 32px; }
  .badge-strip { grid-template-columns: repeat(2, 1fr); }
  .fz, .fz.rev { grid-template-columns: 1fr; gap: 16px; }
  .fz.rev .fz-txt { order: 1; }
  .fz.rev .fz-img { order: 2; }
  .stb-grid { grid-template-columns: repeat(2, 1fr); }
  .scene-grid, .steps3-grid { grid-template-columns: 1fr; }
  .price-wrap { grid-template-columns: 1fr; }
  .nav-links { display: none; }
}
@media (max-width: 560px) {
  .hero h1 { font-size: 27px; }
  .badge-strip { grid-template-columns: 1fr 1fr; }
  .stb-grid { grid-template-columns: 1fr; }
  .navbar .nav-contact { display: none; }
  .problem-line .sp-br { display: none; }
}

/* ===== 放置警告（無操作60分超）・自動終了のお知らせ・利用履歴 ===== */
.idlewarn { background: #fef2f2; border: 2px solid #dc2626; border-radius: 12px; padding: 14px 16px; margin-bottom: 16px; animation: idlePulse 1.6s ease-in-out infinite; }
.idlewarn-t { margin: 0 0 6px; font-weight: 800; color: #b91c1c; font-size: 15px; }
.idlewarn-d { margin: 0 0 12px; color: #7f1d1d; font-size: 13px; line-height: 1.7; }
@keyframes idlePulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(220,38,38,.30); } 50% { box-shadow: 0 0 0 6px rgba(220,38,38,0); } }
@media (prefers-reduced-motion: reduce) { .idlewarn { animation: none; } }

.card.autoend { border: 1px solid #f59e0b; background: #fffbeb; padding: 16px 18px; margin-bottom: 16px; }
.autoend-t { margin: 0 0 6px; font-weight: 800; color: #92400e; font-size: 15px; }
.autoend-d { margin: 0 0 12px; color: #78350f; font-size: 13px; line-height: 1.7; }

.card.billhist { padding: 18px 20px; margin-top: 16px; }
.billhist-h { margin: 0 0 4px; font-size: 16px; }
.billhist-sum { margin: 0 0 12px; color: var(--muted); font-size: 13px; }
.billhist-sum b { color: var(--text); font-size: 16px; }
.bill-rows { display: flex; flex-direction: column; gap: 2px; }
.bill-row { display: flex; align-items: center; gap: 12px; padding: 7px 4px; border-top: 1px solid var(--line); font-size: 13px; flex-wrap: wrap; }
.bill-when { min-width: 82px; font-variant-numeric: tabular-nums; }
.bill-dur { color: var(--muted); min-width: 76px; }
.bill-amt { font-weight: 700; min-width: 72px; text-align: right; font-variant-numeric: tabular-nums; }
.bill-amt.waived { text-decoration: line-through; color: var(--muted); font-weight: 500; }
.bill-st { font-size: 11px; border-radius: 999px; padding: 2px 9px; border: 1px solid var(--line); color: var(--muted); }
.bill-st.st-billed { background: #eef4ff; border-color: #bfd3ff; color: #2f6df6; }
.bill-st.st-pending { background: #fff7ed; border-color: #fed7aa; color: #c8861a; }
.bill-st.st-waived { background: #f0fdf4; border-color: #bbf7d0; color: #1f9d55; }
.bill-auto { font-size: 11px; border-radius: 999px; padding: 2px 9px; background: #fef2f2; border: 1px solid #fecaca; color: #b91c1c; font-weight: 700; }
.billhist-more { margin: 8px 0 0; color: var(--muted); font-size: 12px; }
.billhist-note { margin: 10px 0 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.bill-st.st-refunded { background: #eef4ff; border-color: #bfd3ff; color: #2f6df6; }

/* 録画データのダウンロード */
.card.rechist { padding: 18px 20px; margin-top: 16px; }
.rechist-h { margin: 0 0 12px; font-size: 16px; }
.rec-rows { display: flex; flex-direction: column; gap: 2px; }
.rec-row { display: flex; align-items: center; gap: 12px; padding: 9px 4px; border-top: 1px solid var(--line); font-size: 13px; flex-wrap: wrap; }
.rec-when { min-width: 92px; font-variant-numeric: tabular-nums; }
.rec-mgmt { color: var(--muted); min-width: 64px; }
.rec-size { color: var(--muted); min-width: 64px; font-variant-numeric: tabular-nums; }
.rec-dl { margin-left: auto; text-decoration: none; background: var(--accent); color: #fff; border-radius: 8px; padding: 7px 14px; font-weight: 700; font-size: 13px; }
.rec-dl:hover { opacity: .9; }
.rec-del { background: none; border: 1px solid var(--line); color: var(--muted); border-radius: 8px; padding: 6px 12px; font-size: 12px; cursor: pointer; }
.rec-del:hover { border-color: #dc2626; color: #dc2626; }
.rechist-note { margin: 10px 0 0; color: var(--muted); font-size: 12px; line-height: 1.6; }

/* 保護策①: 録画中は終了ロック */
.danger.locked { background: #f3f4f6; color: #9aa4b2; border-color: #e3e8ef; cursor: not-allowed; box-shadow: none; }
.danger.locked:hover { background: #f3f4f6; }
.rec-lock-note { margin: 8px 0 0; font-size: 12.5px; color: #b91c1c; line-height: 1.6; }
.idlewarn.urgent { border-color: #b91c1c; background: #fee2e2; animation-duration: 1s; }
.idlewarn .primary { margin-top: 4px; }

/* ===== 領収書・請求書 ===== */
.bill-rcpt { margin-left: 6px; font-size: 12px; padding: 5px 11px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--accent); font-weight: 700; cursor: pointer; }
.bill-rcpt:hover { border-color: var(--accent); }
.rcpt-backdrop { position: fixed; inset: 0; background: rgba(15,25,45,.55); z-index: 200; display: flex; align-items: flex-start; justify-content: center; overflow: auto; padding: 24px 12px; }
.rcpt-modal { width: 640px; max-width: 100%; }
.rcpt-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.rcpt-name-field { display: flex; align-items: center; gap: 6px; color: #fff; font-size: 13px; flex: 1; min-width: 200px; }
.rcpt-name-in { flex: 1; background: #fff; color: var(--text); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; font-size: 14px; }
.rcpt-btns { display: flex; gap: 8px; }
.rcpt-btns .ghost { color: #fff; border-color: rgba(255,255,255,.4); }
/* 紙（白地・常にライト。印刷でもそのまま） */
.rcpt { background: #fff; color: #12181f; border-radius: 10px; padding: 34px 38px; box-shadow: 0 24px 60px rgba(0,0,0,.35); }
.rcpt-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; border-bottom: 2px solid #12181f; padding-bottom: 12px; }
.rcpt-title { margin: 0; font-size: 26px; letter-spacing: .18em; }
.rcpt-meta { font-size: 12px; color: #556; text-align: right; line-height: 1.7; }
.rcpt-to { margin: 24px 0 6px; font-size: 18px; }
.rcpt-uline { display: inline-block; min-width: 230px; border-bottom: 1px solid #12181f; padding: 0 6px 2px; font-weight: 700; }
.rcpt-sama { font-size: 15px; }
.rcpt-amount { margin: 12px 0 4px; border-bottom: 1px solid #ccd3dd; padding-bottom: 10px; }
.rcpt-amount-v { font-size: 30px; font-weight: 800; letter-spacing: .02em; }
.rcpt-amount-tax { font-size: 13px; color: #556; margin-left: 8px; }
.rcpt-for { margin: 14px 0 2px; font-size: 14px; }
.rcpt-got { margin: 2px 0 16px; font-size: 13px; color: #445; }
.rcpt-table { width: 100%; border-collapse: collapse; font-size: 13px; margin: 6px 0 4px; }
.rcpt-table td { padding: 7px 8px; border-bottom: 1px solid #e3e8ef; }
.rcpt-table .rcpt-r { text-align: right; font-variant-numeric: tabular-nums; }
.rcpt-table .rcpt-total td { border-top: 2px solid #12181f; border-bottom: none; font-weight: 800; font-size: 15px; }
.rcpt-pending { margin: 12px 0 0; font-size: 12px; color: #c8861a; line-height: 1.6; }
.rcpt-issuer { margin: 26px 0 0; text-align: right; font-size: 13px; line-height: 1.7; }
.rcpt-issuer-name { font-weight: 700; }
.rcpt-stamp { margin: 14px 0 0; font-size: 11px; color: #889; }
@media print {
  body > *:not(.rcpt-backdrop) { display: none !important; }
  .rcpt-backdrop { position: static !important; inset: auto !important; background: #fff !important; display: block !important; padding: 0 !important; overflow: visible !important; }
  .rcpt-modal { width: 100% !important; }
  .rcpt-actions { display: none !important; }
  .rcpt { box-shadow: none !important; border-radius: 0 !important; padding: 8mm 10mm !important; }
}

/* ===== 使い方ガイド / オンボーディング ===== */
.onb-backdrop { position: fixed; inset: 0; background: rgba(15,25,45,.6); z-index: 210; display: flex; align-items: center; justify-content: center; padding: 20px 14px; }
.onb-modal { background: var(--card); border-radius: 18px; width: 480px; max-width: 100%; padding: 22px 26px 20px; box-shadow: 0 24px 70px rgba(0,0,0,.4); text-align: center; }
.onb-head { display: flex; align-items: center; justify-content: space-between; }
.onb-head-t { font-size: 13px; font-weight: 700; color: var(--muted); }
.onb-x { background: none; border: none; font-size: 18px; color: var(--muted); cursor: pointer; line-height: 1; }
.onb-body { min-height: 234px; padding: 14px 4px 4px; }
.onb-icon { font-size: 40px; line-height: 1; margin-bottom: 8px; }
.onb-title { margin: 0 0 12px; font-size: 20px; }
.onb-p { margin: 0 0 10px; color: #445267; font-size: 14px; line-height: 1.7; text-align: left; }
.onb-dots { display: flex; gap: 7px; justify-content: center; margin: 6px 0 14px; }
.onb-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--line); }
.onb-dot.on { background: var(--accent); }
.onb-actions { display: flex; gap: 10px; justify-content: center; }
.onb-actions .primary, .onb-actions .ghost { min-width: 120px; }
.onb-actions .ghost:disabled { opacity: .4; cursor: default; }
.onb-skip { display: block; margin: 12px auto 0; background: none; border: none; color: var(--muted); font-size: 12px; text-decoration: underline; cursor: pointer; }
