/* Caesar 営業TODOアプリ — 追加スタイル */
.todo-app .main-body { max-width: 960px; }

.view-panel { display: none; }
.view-panel.on { display: block; }

/* 空き時間入力 */
.avail-box {
  background: linear-gradient(135deg, #eff6ff, #fff);
  border: 1px solid #bfdbfe;
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  margin-bottom: 20px;
}
.avail-box h3 { font-size: 14px; font-weight: 700; margin-bottom: 8px; }
.avail-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; align-items: center; }
.avail-input {
  flex: 1;
  min-width: 200px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 14px;
  font-family: inherit;
}
.avail-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.avail-chip {
  padding: 5px 12px;
  font-size: 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--main-bg);
  cursor: pointer;
  font-family: inherit;
}
.avail-chip:hover { background: var(--sidebar-bg); border-color: #a1a1aa; }
.avail-result {
  margin-top: 12px;
  font-size: 13px;
  color: #1d4ed8;
  font-weight: 600;
}

/* タスクリスト */
.task-list { display: grid; gap: 10px; }
.task-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: start;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--main-bg);
  transition: border-color 0.15s, background 0.15s;
}
.task-item.done { background: #f0fdf4; border-color: #86efac; opacity: 0.85; }
.task-item.done .task-title { text-decoration: line-through; color: var(--hint); }
.task-check { margin-top: 3px; width: 18px; height: 18px; cursor: pointer; }
.task-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.task-tag {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--sidebar-bg);
  color: var(--sub);
}
.task-tag.time { background: #dbeafe; color: #1d4ed8; }
.task-tag.platform { background: #f3e8ff; color: #7c3aed; }
.task-tag.short { background: #fef3c7; color: #92400e; }
.task-block-hd {
  font-size: 12px;
  font-weight: 800;
  color: var(--sub);
  letter-spacing: 0.06em;
  padding: 14px 4px 6px;
  border-bottom: 2px solid var(--line);
  margin-top: 8px;
}
.task-block-hd:first-child { margin-top: 0; }
.task-item.task-step { border-left: 3px solid #dbeafe; }
.task-summary {
  margin-top: 16px;
  padding: 12px 14px;
  background: var(--sidebar-bg);
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  color: var(--sub);
  text-align: center;
}
.task-action-btn {
  cursor: pointer;
  font-family: inherit;
  background: #eff6ff;
  border-color: #93c5fd;
  color: #1d4ed8;
}
.task-title { font-size: 15px; font-weight: 700; color: var(--ink); }
.task-desc { font-size: 13px; color: var(--sub); margin-top: 4px; line-height: 1.55; }
.task-actions { display: flex; flex-direction: column; gap: 4px; align-items: flex-end; }
.task-link {
  font-size: 11px;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  padding: 4px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.task-link:hover { background: var(--sidebar-bg); }
.count-btn {
  width: 28px; height: 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--main-bg);
  cursor: pointer;
  font-weight: 700;
  font-size: 14px;
}
.count-val { font-size: 13px; font-weight: 700; min-width: 24px; text-align: center; }

/* 週次プログレス */
.progress-grid { display: grid; gap: 12px; }
.progress-row {
  display: grid;
  grid-template-columns: 120px 1fr 48px;
  gap: 12px;
  align-items: center;
  font-size: 13px;
}
.progress-bar {
  height: 8px;
  background: var(--line-light);
  border-radius: 999px;
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #18181b, #52525b);
  border-radius: 999px;
  transition: width 0.3s;
}
.progress-fill.high { background: linear-gradient(90deg, #059669, #10b981); }

/* 満足度 */
.satisfaction-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
}
.sat-btn {
  width: 44px; height: 44px;
  border: 2px solid var(--line);
  border-radius: 12px;
  background: var(--main-bg);
  font-size: 22px;
  cursor: pointer;
  transition: transform 0.1s, border-color 0.15s;
}
.sat-btn:hover { transform: scale(1.08); }
.sat-btn.on { border-color: #18181b; background: #fef3c7; }

/* 参照アカウント */
.account-grid { display: grid; gap: 10px; }
.account-card {
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: start;
}
.account-card h4 { font-size: 14px; font-weight: 700; }
.account-card .handle { font-size: 12px; color: #2563eb; }
.account-card p { font-size: 13px; color: var(--sub); margin-top: 4px; }
.platform-badge {
  font-size: 10px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 6px;
  background: #18181b;
  color: #fff;
}

/* 投稿テンプレ */
.post-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 12px;
}
.post-head {
  padding: 12px 16px;
  background: var(--sidebar-bg);
  border-bottom: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
}
.post-head .slot { font-size: 12px; font-weight: 700; color: var(--ink); }
.post-body {
  padding: 16px;
  font-size: 13px;
  line-height: 1.85;
  white-space: pre-wrap;
  color: var(--sub);
}
.post-actions { padding: 0 16px 14px; }

/* ── パネル共通 ── */
.panel-block { margin-bottom: 28px; }
.panel-title {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 6px;
  color: var(--ink);
}
.panel-desc { font-size: 13px; color: var(--sub); margin: 0 0 14px; line-height: 1.5; }
.panel-empty { font-size: 13px; color: var(--hint); padding: 20px; text-align: center; background: #f8fafc; border-radius: 12px; margin: 0; }

/* ── 期限アラート（最上部） ── */
.alert-board {
  margin-bottom: 20px;
  border-radius: 14px;
  overflow: hidden;
}
.alert-board--clear { display: none; }
.alert-board--ok {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
}
.alert-ok-icon { font-size: 20px; font-weight: 700; }
.alert-board--danger { border: 1px solid #fecaca; background: #fff; }
.alert-board--warn { border: 1px solid #fde68a; background: #fff; }
.alert-board-inner { padding: 0; }
.alert-board-head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 18px;
  background: linear-gradient(135deg, #fef2f2 0%, #fff7ed 100%);
  border-bottom: 1px solid #fecaca;
}
.alert-board-head--danger { background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%); }
.alert-board-head--boss { background: #f5f3ff; border-bottom-color: #e9d5ff; }
.alert-board-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: #dc2626;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  flex-shrink: 0;
}
.alert-board-head--boss .alert-board-icon { background: #7c3aed; }
.alert-board-head h3 { margin: 0; font-size: 15px; font-weight: 700; }
.alert-board-head p { margin: 4px 0 0; font-size: 12px; color: var(--sub); }
.alert-board-list { padding: 8px 12px 12px; }
.alert-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  margin-bottom: 6px;
  background: #fff;
  border: 1px solid var(--line);
}
.alert-row--overdue { border-color: #fca5a5; background: #fef2f2; }
.alert-row--today { border-color: #fcd34d; background: #fffbeb; }
.alert-row--boss { border-color: #c4b5fd; }
.alert-row-main { flex: 1; min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.alert-row-main strong { font-size: 14px; width: 100%; }
.alert-row-main time { font-size: 12px; color: var(--sub); }
.alert-from, .alert-tag, .alert-person { font-size: 11px; color: var(--hint); font-weight: 600; }
.alert-person { color: #b45309; font-size: 12px; }
.alert-row-actions { display: flex; gap: 6px; flex-shrink: 0; }

.due-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  letter-spacing: 0.02em;
}
.due-overdue { background: #fee2e2; color: #b91c1c; }
.due-today { background: #fef3c7; color: #b45309; }
.due-soon { background: #e0e7ff; color: #4338ca; }
.due-ok { background: #f1f5f9; color: #475569; }
.due-none { background: #f8fafc; color: #94a3b8; }
.due-done { background: #dcfce7; color: #166534; }

/* ── 稼働時間 ── */
.work-card { padding: 18px; }
.work-time-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-bottom: 14px;
}
@media (min-width: 520px) {
  .work-time-grid { grid-template-columns: repeat(4, 1fr); }
}
.work-time-item strong { font-size: 17px; display: block; margin-top: 2px; }
.work-label { font-size: 11px; color: var(--hint); font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; }
.work-time-item--accent strong { color: #059669; }
.work-time-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.break-input { font-size: 13px; color: var(--sub); display: flex; align-items: center; gap: 8px; }
.break-input input {
  width: 64px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 14px;
}

/* ── TODO作成フォーム ── */
.todo-compose {
  display: grid;
  gap: 10px;
  margin-bottom: 16px;
  padding: 16px;
  background: #f8fafc;
  border-radius: 12px;
  border: 1px solid var(--line);
}
@media (min-width: 720px) {
  .todo-compose {
    grid-template-columns: 1fr 1fr;
    align-items: end;
  }
  .todo-compose .btn-pill { grid-column: span 1; justify-self: start; }
  .todo-compose--manager { grid-template-columns: 1fr 1fr; }
}
.todo-compose input,
.todo-compose select {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 14px;
  background: #fff;
}
.todo-due-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 12px;
  font-weight: 600;
  color: var(--sub);
}

/* ── TODOカード ── */
.personal-todo-list { display: grid; gap: 10px; }
.ptodo-section-title { font-size: 12px; font-weight: 700; color: var(--hint); margin: 0 0 8px; text-transform: uppercase; letter-spacing: 0.06em; }
.ptodo-done-fold { margin-top: 12px; font-size: 13px; color: var(--sub); }
.ptodo-done-fold summary { cursor: pointer; padding: 8px 0; font-weight: 600; }
.ptodo-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: start;
  padding: 14px 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.ptodo-card:hover { border-color: #cbd5e1; }
.ptodo-card.is-overdue { border-color: #f87171; background: #fffbfb; }
.ptodo-card.is-today { border-color: #fbbf24; background: #fffef7; }
.ptodo-card.is-done { opacity: 0.65; background: #f8fafc; }
.ptodo-body { min-width: 0; }
.ptodo-title-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.ptodo-title-row h4 { margin: 0; font-size: 14px; font-weight: 600; flex: 1; min-width: 0; }
.ptodo-note, .ptodo-meta { font-size: 12px; color: var(--sub); margin: 6px 0 0; line-height: 1.45; }
.ptodo-check input { width: 18px; height: 18px; accent-color: #059669; margin-top: 4px; }
.ptodo-del {
  border: none;
  background: #f1f5f9;
  color: var(--hint);
  width: 28px;
  height: 28px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
}
.ptodo-del:hover { background: #fee2e2; color: #b91c1c; }
.ptodo-actions { display: flex; gap: 6px; align-items: center; }
.tag { font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 4px; }
.tag-boss { background: #ede9fe; color: #5b21b6; }

/* ── 上司画面 ── */
.manager-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 8px;
}
.manager-heading { font-size: 20px; font-weight: 700; margin: 8px 0 4px; letter-spacing: -0.03em; }
.sync-line { font-size: 12px; color: var(--hint); margin: 0 0 16px; }
.team-grid { display: grid; gap: 14px; }
.team-card {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
}
.team-card--alert { border-color: #fca5a5; box-shadow: 0 0 0 1px rgba(248, 113, 113, 0.2); }
.team-card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
}
.team-card-head h4 { margin: 0; font-size: 16px; font-weight: 700; }
.team-card-sub { margin: 4px 0 0; font-size: 12px; color: var(--hint); }
.team-alert-pill {
  font-size: 11px;
  font-weight: 700;
  background: #fee2e2;
  color: #b91c1c;
  padding: 4px 10px;
  border-radius: 20px;
  white-space: nowrap;
}
.team-metrics {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 12px;
}
@media (min-width: 480px) {
  .team-metrics { grid-template-columns: repeat(4, 1fr); }
}
.team-metric {
  padding: 10px 12px;
  background: #f8fafc;
  border-radius: 10px;
}
.team-metric span { display: block; font-size: 10px; color: var(--hint); font-weight: 600; margin-bottom: 2px; }
.team-metric strong { font-size: 15px; }
.team-todo-preview {
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
  display: grid;
  gap: 6px;
}
.team-todo-li {
  font-size: 13px;
  padding: 8px 10px;
  background: #f8fafc;
  border-radius: 8px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}
.team-todo-li--overdue { background: #fef2f2; }

.user-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  padding: 10px 28px;
  background: var(--sidebar-bg);
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}
.user-bar input {
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 13px;
  font-family: inherit;
}
.role-toggle { display: flex; gap: 4px; }
.role-toggle button {
  padding: 5px 12px;
  font-size: 11px;
  font-weight: 700;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--main-bg);
  cursor: pointer;
  font-family: inherit;
}
.role-toggle button.on { background: var(--pill); color: #fff; border-color: var(--pill); }

.script-preview {
  font-size: 12px;
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 8px;
  padding: 10px 12px;
  margin-top: 8px;
  color: #78350f;
  line-height: 1.6;
}

.schedule-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  margin-top: 8px;
}
.schedule-table th, .schedule-table td {
  border: 1px solid var(--line);
  padding: 8px 10px;
  text-align: left;
}
.schedule-table th { background: var(--sidebar-bg); font-size: 10px; text-transform: uppercase; color: var(--hint); }

.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--hint);
  font-size: 14px;
}

@media (max-width: 560px) {
  .task-item { grid-template-columns: auto 1fr; }
  .task-actions { grid-column: 2; flex-direction: row; align-items: center; }
  .progress-row { grid-template-columns: 1fr; gap: 4px; }
}

/* ── 架電リスト ── */
.call-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 16px;
}
.call-toolbar input {
  flex: 1;
  min-width: 160px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 13px;
  font-family: inherit;
}
.call-list { display: grid; gap: 10px; }
.call-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
  background: var(--main-bg);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: start;
}
.call-card.done { background: #f0fdf4; border-color: #86efac; }
.call-card h4 { font-size: 15px; font-weight: 700; margin-bottom: 4px; }
.call-meta { font-size: 12px; color: var(--sub); line-height: 1.6; }
.call-meta strong { color: var(--ink); }
.call-status {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 6px;
  background: #fef3c7;
  color: #92400e;
  margin-left: 6px;
}
.call-status.done { background: #dcfce7; color: #166534; }
.call-actions { display: flex; flex-direction: column; gap: 6px; align-items: stretch; }
.btn-call {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 16px;
  border-radius: 10px;
  background: #059669;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  white-space: nowrap;
}
.btn-call:hover { opacity: 0.92; }
.btn-log {
  padding: 7px 12px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--main-bg);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
}
.btn-coach-open {
  padding: 10px 14px;
  border-radius: 10px;
  border: none;
  background: linear-gradient(135deg, #4f46e5, #7c3aed);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
}
.btn-coach-open:hover { opacity: 0.92; }

/* ライブ架電コーチ */
.call-coach-panel {
  display: none;
  margin-bottom: 20px;
  border: 2px solid #6366f1;
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, #f8fafc, #fff);
  box-shadow: 0 8px 32px rgba(99, 102, 241, 0.15);
  overflow: hidden;
}
.call-coach-panel.on { display: block; }
.call-coach-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  background: linear-gradient(135deg, #0f172a, #312e81);
  color: #e2e8f0;
}
.coach-kicker { font-size: 10px; font-weight: 800; letter-spacing: 0.1em; color: #a5b4fc; }
.call-coach-head h3 { font-size: 18px; font-weight: 800; margin-top: 4px; color: #fff; }
.btn-sm { padding: 6px 12px; font-size: 12px; }
.coach-ios-hint {
  margin: 0;
  padding: 10px 16px;
  font-size: 13px;
  background: #fef3c7;
  color: #92400e;
  border-bottom: 1px solid #fde68a;
}
.call-coach-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
}
@media (max-width: 800px) {
  .call-coach-grid { grid-template-columns: 1fr; }
  .call-coach-panel.on {
    position: sticky;
    top: 0;
    z-index: 100;
  }
}
.coach-brief, .coach-live {
  padding: 14px 16px;
  min-width: 0;
}
.coach-live {
  background: linear-gradient(135deg, #eef2ff, #fafafa);
  border-left: 1px solid #c7d2fe;
}
@media (max-width: 800px) {
  .coach-live { border-left: none; border-top: 1px solid #c7d2fe; }
}
.coach-brief h4, .coach-live h4 { font-size: 12px; font-weight: 800; color: var(--sub); margin-bottom: 10px; }
.coach-brief-body { font-size: 13px; line-height: 1.55; max-height: 220px; overflow-y: auto; }
.coach-company { font-weight: 800; font-size: 14px; margin-bottom: 8px; }
.coach-memo { font-size: 12px; color: #166534; background: #f0fdf4; padding: 8px; border-radius: 8px; margin-bottom: 10px; }
.coach-manual-tag { font-size: 11px; font-weight: 700; color: #4f46e5; margin-bottom: 10px; }
.coach-block { margin-bottom: 12px; }
.coach-block-label { display: block; font-size: 11px; font-weight: 800; color: #4f46e5; margin-bottom: 6px; }
.coach-lines { margin: 0; padding-left: 18px; }
.coach-lines li { margin-bottom: 6px; }
.coach-obj { font-size: 12px; margin-bottom: 8px; line-height: 1.5; }
.coach-brief-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.coach-listen-status { font-size: 12px; color: var(--sub); margin-top: 8px; }
.coach-interim { font-size: 12px; color: #64748b; font-style: italic; min-height: 18px; margin-top: 4px; }
.coach-stage-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 999px;
  background: #4f46e5;
  color: #fff;
  margin-bottom: 8px;
}
.coach-say-now {
  font-size: 17px;
  font-weight: 700;
  line-height: 1.75;
  white-space: pre-wrap;
  word-break: break-word;
  margin: 0 0 12px;
  padding: 14px;
  background: #fff;
  border: 1px solid #c7d2fe;
  border-radius: 12px;
  min-height: 120px;
  font-family: inherit;
}
@media (max-width: 800px) {
  .coach-say-now { font-size: 19px; line-height: 1.8; }
}
.coach-note { font-size: 12px; color: var(--sub); margin-bottom: 10px; }
.coach-alternatives { margin-bottom: 10px; }
.coach-alt-label { font-size: 11px; font-weight: 700; display: block; margin-bottom: 6px; }
.coach-alt-btn {
  display: block;
  width: 100%;
  text-align: left;
  margin-bottom: 6px;
  padding: 8px 10px;
  font-size: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  font-family: inherit;
}
.coach-transcript-details { margin-top: 12px; font-size: 12px; }
.coach-transcript-log {
  font-size: 11px;
  max-height: 80px;
  overflow: auto;
  white-space: pre-wrap;
  color: var(--sub);
  margin-top: 6px;
}
.coach-loading { color: var(--sub); }
.coach-toast {
  position: fixed;
  bottom: calc(24px + env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  background: #0f172a;
  color: #fff;
  padding: 12px 20px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  z-index: 600;
  box-shadow: 0 8px 24px rgba(0,0,0,.25);
}
#btnCoachListen.on { background: #dc2626; }

.sheet-link { font-size: 12px; color: #2563eb; }

/* 架電記録モーダル */
.modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  z-index: 500;
  align-items: flex-end;
  justify-content: center;
  padding: 16px;
}
.modal-backdrop.on { display: flex; }
.modal-sheet {
  background: var(--main-bg);
  border-radius: 16px 16px 0 0;
  width: min(100%, 480px);
  max-height: 90vh;
  overflow-y: auto;
  padding: 20px;
  box-shadow: 0 -8px 40px rgba(0,0,0,.15);
}
.modal-sheet h3 { font-size: 16px; font-weight: 700; margin-bottom: 4px; }
.modal-sub { font-size: 13px; color: var(--sub); margin-bottom: 16px; }
.outcome-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 14px;
}
.outcome-btn {
  padding: 12px 10px;
  border: 2px solid var(--line);
  border-radius: 10px;
  background: var(--main-bg);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  text-align: center;
}
.outcome-btn.on { border-color: #18181b; background: #fafafa; }
.modal-field { margin-bottom: 12px; }
.modal-field label { display: block; font-size: 12px; font-weight: 600; color: var(--sub); margin-bottom: 4px; }
.modal-field textarea,
.modal-field input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 14px;
  font-family: inherit;
  resize: vertical;
}
.modal-field textarea { min-height: 80px; }
.modal-actions { display: flex; gap: 8px; margin-top: 16px; }
.modal-actions .btn { flex: 1; }

/* ── SNS引用フィード ── */
.sns-filter-row { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.sns-filter {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--main-bg);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
}
.sns-filter.on { background: var(--pill); color: #fff; border-color: var(--pill); }
.sns-metrics { margin-left: auto; font-size: 11px; color: var(--hint); }
.sns-feed-body {
  padding: 16px;
  font-size: 14px;
  line-height: 1.85;
  white-space: pre-wrap;
  color: var(--ink);
}
.sns-feed-actions {
  padding: 0 16px 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.sns-feed-actions .btn { font-size: 12px; padding: 8px 12px; min-height: 36px; }
.sns-thumb-wrap { padding: 0 16px 8px; }
.sns-thumb { max-width: 100%; max-height: 220px; border-radius: 10px; object-fit: cover; }
.plat-x { background: #0f172a; color: #fff; }
.plat-ig { background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); color: #fff; }
.plat-tt { background: #010101; color: #fff; }
.sns-acc-links { margin-top: 8px; font-size: 12px; }
.sns-acc-links a, .ref-link { color: #2563eb; font-weight: 600; margin-right: 8px; text-decoration: none; }
.sns-status { font-size: 12px; color: var(--hint); margin-bottom: 12px; }

/* ── View Hero & API Status ── */
.view-hero {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 20px;
  border-radius: var(--radius-lg);
  margin-bottom: 16px;
  border: 1px solid var(--line);
}
.sns-hero {
  background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 55%, #312e81 100%);
  color: #e2e8f0;
  border-color: #3730a3;
}

/* 自動収集・今すぐ投稿 */
.sns-ready-section { margin-bottom: 20px; }
.sns-ready-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}
.sns-live-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 5px 10px;
  border-radius: 999px;
  background: #e2e8f0;
  color: #475569;
}
.sns-live-badge.on { background: #dcfce7; color: #166534; }
.sns-live-badge.loading { background: #fef3c7; color: #92400e; animation: sns-pulse 1.2s ease-in-out infinite; }
@keyframes sns-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.65; } }
.sns-ready-picks {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
}
.sns-pick-loading {
  grid-column: 1 / -1;
  font-size: 13px;
  color: var(--sub);
  padding: 16px;
  text-align: center;
  background: #f8fafc;
  border-radius: 12px;
  border: 1px dashed var(--line);
}
.sns-ready-pick {
  text-align: left;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s;
  font-family: inherit;
}
.sns-ready-pick:hover { border-color: #818cf8; box-shadow: 0 4px 14px rgba(99, 102, 241, 0.12); }
.sns-ready-pick.on {
  border-color: #6366f1;
  background: linear-gradient(135deg, #eef2ff, #fff);
  box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.2);
}
.sns-pick-type {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  margin-bottom: 6px;
}
.sns-pick-name {
  display: block;
  font-size: 14px;
  margin-bottom: 6px;
  color: var(--text);
}
.sns-pick-preview {
  font-size: 12px;
  line-height: 1.45;
  color: var(--sub);
  margin: 0 0 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.sns-pick-tag {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #64748b;
}
.sns-pick-tag.ok { background: #dcfce7; color: #166534; }

/* 投稿スタジオ */
.sns-paste-studio { margin-bottom: 20px; }
.sns-howto {
  display: grid;
  gap: 8px;
  margin: 10px 0 14px;
  padding: 12px 14px;
  background: linear-gradient(135deg, #f0fdf4, #ecfdf5);
  border: 1px solid #86efac;
  border-radius: 12px;
}
.sns-howto-step {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  line-height: 1.5;
}
.sns-howto-n {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: #166534;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}
.sns-angle-row--studio { margin-bottom: 12px; }
.sns-paste-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 12px;
}
@media (max-width: 800px) { .sns-paste-grid { grid-template-columns: 1fr; } }
.sns-field-label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  color: var(--sub);
  margin-bottom: 6px;
}
.sns-paste-input {
  width: 100%;
  min-height: 120px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 14px;
  font-family: inherit;
  line-height: 1.55;
  resize: vertical;
}
.sns-paste-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
  font-size: 13px;
}
.sns-paste-meta label { display: flex; flex-direction: column; gap: 4px; font-weight: 600; }
.sns-paste-meta input, .sns-paste-meta select {
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-family: inherit;
  min-width: 140px;
}
.sns-paste-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}
.btn-copy-primary {
  font-size: 15px;
  padding: 12px 20px;
  flex: 1 1 100%;
  max-width: 100%;
}
.sns-paste-hint {
  font-size: 12px;
  margin-top: 8px;
  min-height: 18px;
}
.sns-paste-hint.ok { color: #166534; }
.sns-paste-hint.warn { color: #92400e; }
.sns-paste-hint.err { color: #991b1b; }
.sns-paste-output-wrap { min-width: 0; }
.sns-paste-output {
  min-height: 180px;
  max-height: 320px;
  overflow: auto;
  padding: 14px;
  border: 1px solid #c7d2fe;
  border-radius: 12px;
  background: linear-gradient(135deg, #eef2ff, #fafafa);
  font-size: 13px;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
  font-family: inherit;
}

/* 伸びている人の型 */
.sns-growth-section { margin-bottom: 20px; }
.sns-growth-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 10px;
  margin-top: 10px;
}
.sns-growth-card {
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--main-bg);
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.sns-growth-card:hover {
  border-color: #818cf8;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.12);
}
.sns-growth-card strong { display: block; font-size: 13px; margin-bottom: 6px; }
.sns-growth-card p { font-size: 12px; color: var(--sub); line-height: 1.5; margin: 0; }
.sns-growth-tag {
  display: inline-block;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 6px;
  background: #ede9fe;
  color: #5b21b6;
  margin-bottom: 6px;
}
.fallback-tag {
  font-size: 10px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 6px;
  background: #fef3c7;
  color: #92400e;
  margin-left: 6px;
}
.sns-toast {
  position: fixed;
  bottom: 88px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  background: #1e1b4b;
  color: #e0e7ff;
  box-shadow: 0 8px 24px rgba(0,0,0,.2);
  animation: snsToastIn 0.25s ease;
}
@keyframes snsToastIn {
  from { opacity: 0; transform: translateX(-50%) translateY(8px); }
  to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

/* 今日の予定 — 時間タップ */
.today-label-btn {
  border: none;
  background: transparent;
  font: inherit;
  padding: 4px 8px;
  border-radius: 8px;
}
.today-label-btn:hover { background: var(--sidebar-bg); color: var(--ink); }
.plan-schedule-block { margin-bottom: 20px; }
.today-schedule-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 16px;
}
.schedule-slot {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 56px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--main-bg);
  cursor: pointer;
  font-family: inherit;
  transition: border-color 0.15s, background 0.15s;
}
.schedule-slot:hover { border-color: #6366f1; background: #eef2ff; }
.schedule-slot.has-plan { border-color: #4338ca; background: #eef2ff; }
.schedule-slot .slot-time { font-size: 12px; font-weight: 700; }
.schedule-slot .slot-count {
  font-size: 10px;
  font-weight: 800;
  color: #4338ca;
  margin-top: 2px;
}
.plan-compose {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 8px;
  align-items: end;
  margin-bottom: 10px;
}
.plan-compose label { font-size: 12px; font-weight: 600; display: flex; flex-direction: column; gap: 4px; }
.plan-compose input, .plan-compose select {
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-family: inherit;
}
.plan-toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.plan-list-title {
  font-size: 13px;
  font-weight: 800;
  color: var(--sub);
  margin: 8px 0 10px;
  letter-spacing: 0.04em;
}
.plan-panel--idle .plan-list-title { opacity: 0.7; }
.plan-empty { margin-top: 8px; }
.task-time-btn {
  border: none;
  cursor: pointer;
  font-family: inherit;
}
.task-time-btn:hover { filter: brightness(0.95); }
.avail-box--optional { opacity: 0.95; }

.ref-hero {
  background: linear-gradient(135deg, #fafafa, #f4f4f5);
}
.hero-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.12);
  margin-bottom: 8px;
}
.ref-hero .hero-badge { background: #e4e4e7; color: var(--ink); }
.hero-lead { font-size: 14px; line-height: 1.6; opacity: 0.92; max-width: 520px; }
.api-status-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}
.api-chip {
  font-size: 11px;
  font-weight: 700;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--sidebar-bg);
  color: var(--sub);
}
.api-chip.ok { background: #ecfdf5; border-color: #86efac; color: #166534; }
.api-chip.off { background: #fef2f2; border-color: #fecaca; color: #991b1b; }
.api-chip.warn { background: #fffbeb; border-color: #fde68a; color: #92400e; }

.sns-angle-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}
.sns-angle-label { font-size: 12px; font-weight: 700; color: var(--sub); }
.sns-angle {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--main-bg);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
}
.sns-angle.on { background: #1e1b4b; color: #c7d2fe; border-color: #4338ca; }

/* ── Reference tabs & cards ── */
.ref-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 20px;
  padding: 4px;
  background: var(--sidebar-bg);
  border-radius: 12px;
  border: 1px solid var(--line);
}
.ref-tab {
  flex: 1;
  min-width: 100px;
  padding: 10px 12px;
  border: none;
  border-radius: 8px;
  background: transparent;
  font-size: 12px;
  font-weight: 700;
  color: var(--sub);
  cursor: pointer;
  font-family: inherit;
}
.ref-tab.on { background: var(--main-bg); color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.ref-panel { display: none; }
.ref-panel.on { display: block; }
.sec-sub { font-size: 13px; color: var(--sub); margin: -8px 0 14px; }

.ref-acc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
}
.ref-acc-card {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  gap: 12px;
  align-items: start;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--main-bg);
  transition: box-shadow 0.15s, border-color 0.15s;
}
.ref-acc-card:hover { border-color: #a1a1aa; box-shadow: 0 4px 16px rgba(0,0,0,.06); }
.ref-acc-avatar {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
}
.ref-acc-avatar.plat-x { background: linear-gradient(135deg, #0f172a, #334155); }
.ref-acc-avatar.plat-ig { background: linear-gradient(45deg, #f09433, #dc2743); }
.ref-acc-avatar.plat-tt { background: #010101; }
.ref-acc-body h4 { font-size: 15px; font-weight: 800; margin: 4px 0 2px; }
.ref-acc-top { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.ref-acc-cat {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  color: #6366f1;
  background: #eef2ff;
  padding: 2px 8px;
  border-radius: 6px;
  margin: 4px 0;
}
.ref-acc-why, .ref-acc-body p { font-size: 13px; color: var(--sub); line-height: 1.55; }
.ref-acc-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: stretch;
}
.btn-sm { font-size: 11px !important; padding: 6px 12px !important; white-space: nowrap; }
.btn-go-sns { font-size: 11px !important; }

.expert-grid, .template-grid {
  display: grid;
  gap: 12px;
}
.expert-card, .template-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 16px 18px;
  background: var(--main-bg);
}
.expert-head, .template-head {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 10px;
}
.expert-source { font-size: 13px; font-weight: 800; }
.expert-usage { font-size: 12px; color: var(--hint); margin-bottom: 10px; }
.expert-body, .template-body {
  font-size: 13px;
  line-height: 1.75;
  white-space: pre-wrap;
  font-family: inherit;
  background: var(--sidebar-bg);
  padding: 12px 14px;
  border-radius: 10px;
  margin: 0 0 12px;
  border: none;
  overflow-x: auto;
}
.template-slot { font-size: 12px; font-weight: 700; color: #1d4ed8; }
.template-type { font-size: 11px; color: var(--hint); }
.template-toolbar { margin-bottom: 14px; }
.template-toolbar select {
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid var(--line);
  font-family: inherit;
}
.schedule-card { overflow-x: auto; }
.sched-time { font-weight: 800; color: #1d4ed8; white-space: nowrap; }
.plat-yt { background: #dc2626; }

.btn-gemini {
  background: linear-gradient(135deg, #4f46e5, #7c3aed) !important;
  color: #fff !important;
  border: none !important;
  font-weight: 700;
}
.btn-gemini:hover { opacity: 0.92; }
.btn, .sns-angle, .sns-filter, .qbox-set-tab, .ref-tab {
  touch-action: manipulation;
  -webkit-tap-highlight-color: rgba(0,0,0,.08);
  min-height: 44px;
}
.sns-angle, .sns-filter { min-height: 36px; }
.post-actions { display: flex; flex-wrap: wrap; gap: 8px; }

/* ── SNS Feed cards (enhanced) ── */
.sns-feed-list { display: grid; gap: 16px; }
.feed-type-tag {
  font-size: 10px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  margin-right: 6px;
}
.feed-type-news { background: #dbeafe; color: #1d4ed8; }
.feed-type-quote { background: #ede9fe; color: #5b21b6; }
.feed-type-post { background: #ecfdf5; color: #047857; }
.sns-load-more-wrap .btn { min-width: 200px; }
.sns-feed-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  background: var(--main-bg);
  box-shadow: 0 2px 8px rgba(0,0,0,.04);
}
.sns-feed-head {
  padding: 14px 16px;
  background: linear-gradient(to bottom, var(--sidebar-bg), var(--main-bg));
  border-bottom: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  font-size: 13px;
}
.sns-acc-name { font-size: 14px; }
.sns-feed-head .handle { color: #2563eb; font-size: 12px; font-weight: 600; }
.demo-tag {
  font-size: 9px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 4px;
  background: #fef3c7;
  color: #92400e;
}
.gemini-output {
  margin: 0 16px 12px;
  padding: 14px;
  background: linear-gradient(135deg, #eef2ff, #faf5ff);
  border: 1px solid #c7d2fe;
  border-radius: 12px;
}
.gemini-label { font-size: 11px; font-weight: 800; color: #4338ca; margin-bottom: 8px; }
.gemini-text {
  font-size: 13px;
  line-height: 1.75;
  white-space: pre-wrap;
  font-family: inherit;
  margin: 0;
  background: transparent;
  border: none;
}
.gemini-img {
  max-width: 100%;
  max-height: 280px;
  border-radius: 10px;
  margin-top: 10px;
  display: block;
}
.empty-state.rich { text-align: center; padding: 32px 20px; }
.empty-icon { font-size: 40px; margin-bottom: 12px; }
.loading-pulse { animation: pulse 1.2s ease-in-out infinite; color: var(--sub); }
@keyframes pulse { 0%,100%{opacity:.5} 50%{opacity:1} }

/* ── スマホ：下部タブ＋誤タップ防止 ── */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 300;
  background: var(--main-bg);
  border-top: 1px solid var(--line);
  padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  grid-template-columns: repeat(5, 1fr);
  gap: 2px;
  box-shadow: 0 -4px 20px rgba(0,0,0,.06);
}
.mbn-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 8px 4px;
  border: none;
  background: transparent;
  border-radius: 10px;
  cursor: pointer;
  font-family: inherit;
  min-height: 52px;
  -webkit-tap-highlight-color: transparent;
}
.mbn-item.on { background: var(--sidebar-bg); }
.mbn-ic, .mbn-item .mbn-b { font-size: 18px; line-height: 1; }
.mbn-lb { font-size: 10px; font-weight: 700; color: var(--sub); }
.mbn-item.on .mbn-lb { color: var(--ink); }

@media (max-width: 900px) {
  .mobile-bottom-nav { display: grid; }
  body.app.todo-app { padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
  .todo-app .sidebar {
    display: none;
  }
  .todo-app .main-col { width: 100%; }
  .todo-app .main-body {
    padding-bottom: calc(100px + env(safe-area-inset-bottom));
    max-width: 100%;
  }
  .todo-app .main-top { padding: 14px 16px 12px; }
  .todo-app .main-top h1 { font-size: 22px; }
  .todo-app .user-bar {
    padding: 8px 16px;
    flex-wrap: wrap;
    gap: 6px;
  }
  .todo-app .kpi-row { grid-template-columns: 1fr 1fr; }
  .todo-app .call-card {
    grid-template-columns: 1fr;
  }
  .todo-app .call-actions {
    flex-direction: row;
    flex-wrap: wrap;
  }
  .todo-app .btn-call {
    flex: 1;
    min-height: 48px;
    font-size: 16px;
  }
  .todo-app .btn-log { min-height: 44px; padding: 10px 16px; }
  .todo-app .avail-input { font-size: 16px; min-height: 44px; }
  .todo-app .task-check { width: 22px; height: 22px; }
  .todo-app .sat-btn { width: 52px; height: 52px; }
  .todo-app .outcome-btn { min-height: 48px; font-size: 14px; }
  .todo-app .modal-sheet {
    width: 100%;
    max-height: 92vh;
    border-radius: 16px 16px 0 0;
  }
  .todo-app .top-actions .btn-outline:last-child { display: none; }
  .todo-app .call-toolbar { flex-wrap: wrap; gap: 8px; }
  .todo-app .call-toolbar .avail-input,
  .todo-app .call-toolbar input[type="search"] { flex: 1 1 100%; min-height: 44px; font-size: 16px; }
  .todo-app .call-sheet-btn { min-height: 44px; flex: 1 1 auto; text-align: center; }
}

@media (max-width: 560px) {
  .todo-app .grid2 { grid-template-columns: 1fr; }
  .todo-app .sns-feed-actions { flex-direction: column; }
  .todo-app .sns-feed-actions .btn { width: 100%; min-height: 44px; }
  .qbox-layout { grid-template-columns: 1fr; }
}

/* ── 架電リスト セットアップ ── */
.call-setup-card {
  padding: 28px 24px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  background: linear-gradient(135deg, #fafafa, #f0fdf4);
  text-align: center;
  max-width: 520px;
  margin: 0 auto;
}
.call-setup-icon { font-size: 48px; margin-bottom: 12px; }
.call-setup-card h3 { font-size: 18px; margin-bottom: 8px; }
.call-setup-reason { color: #b45309; font-size: 14px; margin-bottom: 16px; }
.call-setup-steps { text-align: left; font-size: 13px; margin: 16px 0; }
.call-setup-steps ol { padding-left: 20px; line-height: 1.8; }
.call-setup-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 16px; }

/* ── 質問箱 ── */
.qbox-section { margin-top: 8px; }
.qbox-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: flex-end;
  margin-bottom: 16px;
}
.qbox-field label { display: block; font-size: 12px; font-weight: 700; color: var(--sub); margin-bottom: 6px; }
.qbox-field input, .qbox-field textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-family: inherit;
  font-size: 14px;
}
.qbox-aspect-btns { display: flex; gap: 8px; }
.qbox-aspect {
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--main-bg);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
}
.qbox-aspect.on { background: #1e1b4b; color: #c7d2fe; border-color: #4338ca; }
.qbox-set-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}
.qbox-set-tab {
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--sidebar-bg);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
}
.qbox-set-tab.on { background: #0f172a; color: #fff; border-color: #0f172a; }
.qbox-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 24px;
  align-items: start;
}
.qbox-q-list { display: flex; flex-direction: column; gap: 8px; }
.qbox-q-item {
  text-align: left;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--main-bg);
  cursor: pointer;
  font-family: inherit;
}
.qbox-q-item.on { border-color: #4338ca; background: #eef2ff; }
.qbox-q-item strong { display: block; font-size: 14px; margin-bottom: 4px; }
.qbox-q-item span { font-size: 12px; color: var(--hint); }
.qbox-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.qbox-hint-tip { font-size: 12px; color: var(--sub); margin-top: 12px; }
.qbox-preview-wrap { position: sticky; top: 16px; }
.qbox-screenshot {
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,.15);
  margin: 0 auto;
}
.qbox-aspect-story { width: 100%; max-width: 300px; aspect-ratio: 9/16; }
.qbox-aspect-square { width: 100%; max-width: 300px; aspect-ratio: 1/1; }
.qbox-screenshot-inner {
  height: 100%;
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.qbox-screenshot-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  font-size: 13px;
  font-weight: 700;
}
.qbox-screenshot-icon { font-size: 24px; }
.qbox-screenshot-badge {
  margin-left: auto;
  font-size: 10px;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(255,255,255,.25);
}
.qbox-screenshot-q, .qbox-screenshot-a { margin-bottom: 16px; }
.qbox-q-label, .qbox-a-label {
  display: inline-block;
  font-size: 11px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 6px;
  margin-bottom: 8px;
  background: rgba(255,255,255,.3);
}
.qbox-screenshot-q p, .qbox-screenshot-a p {
  font-size: 15px;
  line-height: 1.65;
  font-weight: 600;
}
.qbox-screenshot-foot {
  margin-top: auto;
  font-size: 10px;
  opacity: 0.7;
  text-align: center;
  padding-top: 12px;
}
.qbox-screenshot-tip { font-size: 11px; color: var(--hint); margin-top: 12px; text-align: center; }

.theme-warm .qbox-screenshot-inner { background: linear-gradient(160deg, #78350f, #92400e 40%, #b45309); color: #fff; }
.theme-orange .qbox-screenshot-inner { background: linear-gradient(160deg, #c2410c, #ea580c 50%, #f97316); color: #fff; }
.theme-green .qbox-screenshot-inner { background: linear-gradient(160deg, #14532d, #166534 50%, #22c55e); color: #fff; }
.theme-pink .qbox-screenshot-inner { background: linear-gradient(160deg, #9d174d, #db2777 50%, #f472b6); color: #fff; }
.theme-slate .qbox-screenshot-inner { background: linear-gradient(160deg, #1e293b, #334155 50%, #475569); color: #fff; }
.theme-purple .qbox-screenshot-inner { background: linear-gradient(160deg, #581c87, #7c3aed 50%, #a78bfa); color: #fff; }
