/* ============================================================
   AID CRAFT — プロダクトデモ共通シェル（アプリ画面風）
   本体サイトとは独立。全デモ共通の部品をここに集約。
   ============================================================ */
:root {
  --ink: #15181e; --ink-2: #2a2e37; --text: #15181e; --gray: #4d5970; --gray-2: #6b7789;
  --line: #e4e7ec; --hair: #edeff2; --bg: #f4f5f3; --white: #fff;
  --ok: #15803d; --ok-bg: #e8f5ec; --warn: #b45309; --warn-bg: #fdf1e1; --ng: #b91c1c; --ng-bg: #fdecec; --info: #1d4ed8; --info-bg: #eaf0fe;
  --accent: #e2571c;
  --p: #1d4ed8; --p-deep: #1e3a8a; --p-bg: #eef3fe; --p-weak: rgba(29,78,216,.14); --p-text: #1e3a8a;
  --ff: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  --ff-num: "Inter", "Noto Sans JP", sans-serif;
  --r: 14px; --r-s: 9px;
  --sh: 0 1px 2px rgba(16,19,25,.04), 0 12px 28px -22px rgba(16,19,25,.22);
  --ease: cubic-bezier(.16,1,.3,1);
  --side-w: 236px; --top-h: 60px;
}
body.dm--deaeru   { --p:#1d4ed8; --p-deep:#1e3a8a; --p-bg:#eef3fe; --p-weak:rgba(29,78,216,.14); --p-text:#1e3a8a; }
body.dm--hakadoru { --p:#0f766e; --p-deep:#134e4a; --p-bg:#e9f5f2; --p-weak:rgba(15,118,110,.14); --p-text:#134e4a; }
body.dm--kotaeru  { --p:#4338ca; --p-deep:#312e81; --p-bg:#eeeffc; --p-weak:rgba(67,56,202,.14); --p-text:#312e81; }
body.dm--mitsukaru{ --p:#c2410c; --p-deep:#9a3412; --p-bg:#fdf0e9; --p-weak:rgba(194,65,12,.14); --p-text:#9a3412; }
body.dm--todokeru { --p:#9d174d; --p-deep:#831843; --p-bg:#fceef4; --p-weak:rgba(157,23,77,.14); --p-text:#831843; }
body.dm--atsumaru { --p:#15803d; --p-deep:#14532d; --p-bg:#edf7ef; --p-weak:rgba(21,128,61,.14); --p-text:#14532d; }

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body { font-family: var(--ff); background: var(--bg); color: var(--text); font-size: 14.5px; line-height: 1.75; letter-spacing: .02em; font-feature-settings: "palt"; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; font-size: inherit; }
input, select, textarea { font-family: inherit; font-size: 16px; color: var(--text); }
:focus-visible { outline: 2px solid var(--p); outline-offset: 2px; border-radius: 4px; }
b, strong { font-weight: 900; }
.num { font-family: var(--ff-num); font-feature-settings: "tnum"; }

/* ---------- レイアウト ---------- */
.dm-app { display: grid; grid-template-columns: var(--side-w) 1fr; min-height: 100vh; }
.dm-side { background: var(--ink); color: #fff; position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; padding: 18px 14px 20px; }
.dm-side__brand { display: flex; align-items: center; gap: 10px; padding: 4px 8px 18px; border-bottom: 1px solid rgba(255,255,255,.14); margin-bottom: 14px; }
.dm-side__brand img { width: 30px; height: 30px; border-radius: 7px; }
.dm-side__brand b { font-size: 17px; letter-spacing: .04em; line-height: 1.2; display: block; color: #fff; }
.dm-side__brand small { display: block; font-size: 11.5px; color: #d5d9e2; font-weight: 700; line-height: 1.3; }
.dm-side__sec { font-size: 11.5px; font-weight: 900; color: #c9ced9; padding: 12px 10px 6px; letter-spacing: .06em; }
.dm-nav a, .dm-nav button { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 10px 12px; border-radius: 9px; font-size: 13.5px; font-weight: 700; color: #e7eaf0; transition: background .2s; }
.dm-nav a:hover, .dm-nav button:hover { background: rgba(255,255,255,.08); }
.dm-nav .is-on { background: var(--p); color: #fff; }
.dm-nav .ico { width: 20px; height: 20px; flex-shrink: 0; display: grid; place-items: center; }
.dm-nav .ico svg { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.dm-nav .cnt { margin-left: auto; font-family: var(--ff-num); font-size: 11.5px; font-weight: 700; background: rgba(255,255,255,.16); padding: 1px 8px; border-radius: 999px; }
.dm-side__foot { margin-top: auto; padding: 14px 8px 0; border-top: 1px solid rgba(255,255,255,.14); font-size: 12px; color: #d5d9e2; line-height: 1.6; }
.dm-side__foot b { color: #fff; display: block; font-size: 12.5px; margin-bottom: 4px; }
.dm-side__foot a { color: #fff; text-decoration: underline; text-underline-offset: 3px; }

.dm-body { min-width: 0; display: flex; flex-direction: column; }
.dm-top { height: var(--top-h); background: #fff; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 12px; padding: 0 22px; position: sticky; top: 0; z-index: 20; }
.dm-top__title { font-size: 16px; font-weight: 900; letter-spacing: .02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dm-top__title small { font-size: 12.5px; color: var(--gray); font-weight: 700; margin-left: 10px; }
.dm-top__right { margin-left: auto; display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.dm-demo-tag { display: inline-flex; align-items: center; gap: 6px; background: var(--p-bg); color: var(--p-text); border: 1px solid var(--p-weak); font-size: 12px; font-weight: 900; padding: 4px 10px; border-radius: 999px; white-space: nowrap; }
.dm-demo-tag::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--p); animation: dm-blink 1.6s infinite; }
@keyframes dm-blink { 0%,100% { opacity: 1 } 50% { opacity: .35 } }

.dm-main { padding: 22px 22px 120px; display: grid; gap: 18px; align-content: start; }
.dm-view { display: grid; gap: 18px; }
.dm-view[hidden] { display: none; }

/* ---------- 見出し・案内 ---------- */
.dm-h { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.dm-h h1 { font-size: 22px; font-weight: 900; line-height: 1.4; letter-spacing: .01em; }
.dm-h p { color: var(--gray); font-size: 13.5px; }
.dm-guide { background: var(--ink); color: #fff; border-radius: var(--r); padding: 14px 18px; display: flex; gap: 12px; align-items: flex-start; font-size: 14px; font-weight: 700; line-height: 1.6; }
.dm-guide .step { flex-shrink: 0; width: 26px; height: 26px; border-radius: 50%; background: var(--p); color: #fff; display: grid; place-items: center; font-family: var(--ff-num); font-weight: 700; font-size: 13px; }
.dm-guide span { color: #fff; }
.dm-guide em { font-style: normal; color: #ffd9c7; }
.dm-note { font-size: 12.5px; color: var(--gray); font-weight: 700; }
.dm-note--box { background: #fff; border: 1px dashed var(--line); border-radius: var(--r-s); padding: 10px 14px; }

/* ---------- グリッド・カード ---------- */
.dm-grid { display: grid; gap: 18px; }
.dm-grid--2 { grid-template-columns: repeat(2, minmax(0,1fr)); }
.dm-grid--3 { grid-template-columns: repeat(3, minmax(0,1fr)); }
.dm-grid--4 { grid-template-columns: repeat(4, minmax(0,1fr)); }
.dm-grid--side { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); }
.dm-grid--wide { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); }
.dm-card { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 20px 22px; box-shadow: var(--sh); min-width: 0; }
.dm-card--p { border-top: 4px solid var(--p); }
.dm-card--ink { background: var(--ink); color: #fff; border-color: var(--ink); }
.dm-card__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.dm-card__title { font-size: 15px; font-weight: 900; display: flex; align-items: center; gap: 8px; line-height: 1.4; }
.dm-card__title::before { content: ""; width: 4px; height: 16px; background: var(--p); border-radius: 2px; }
.dm-card--ink .dm-card__title::before { background: #fff; }
.dm-card__sub { font-size: 12.5px; color: var(--gray); font-weight: 700; }
.dm-card--ink .dm-card__sub { color: #d5d9e2; }

/* ---------- KPI ---------- */
.dm-kpi { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 16px 18px; box-shadow: var(--sh); min-width: 0; }
.dm-kpi__label { font-size: 12.5px; font-weight: 900; color: var(--gray); margin-bottom: 4px; }
.dm-kpi__val { font-family: var(--ff-num); font-size: 30px; font-weight: 700; line-height: 1.1; color: var(--ink); letter-spacing: -.01em; }
.dm-kpi__val small { font-family: var(--ff); font-size: 13px; font-weight: 900; color: var(--gray); margin-left: 3px; letter-spacing: 0; }
.dm-kpi__delta { font-size: 12px; font-weight: 900; margin-top: 6px; display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px; }
.dm-kpi__delta.up { background: var(--ok-bg); color: var(--ok); }
.dm-kpi__delta.down { background: var(--ng-bg); color: var(--ng); }
.dm-kpi__delta.flat { background: var(--hair); color: var(--gray); }

/* ---------- フォーム ---------- */
.dm-field { display: grid; gap: 6px; margin-bottom: 14px; }
.dm-field label { font-size: 13px; font-weight: 900; color: var(--ink); }
.dm-field label small { color: var(--gray); font-weight: 700; margin-left: 6px; font-size: 11.5px; }
.dm-input, .dm-select, .dm-textarea { width: 100%; border: 1.5px solid var(--line); border-radius: var(--r-s); padding: 10px 13px; background: #fff; transition: border-color .2s, box-shadow .2s; line-height: 1.5; }
.dm-input:focus, .dm-select:focus, .dm-textarea:focus { outline: none; border-color: var(--p); box-shadow: 0 0 0 3px var(--p-weak); }
.dm-textarea { min-height: 120px; resize: vertical; line-height: 1.7; }
.dm-select { appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%2315181e' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'><path d='M6 9l6 6 6-6'/></svg>"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 36px; }
.dm-row { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 12px; }
.dm-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.dm-chip { border: 1.5px solid var(--line); border-radius: 999px; padding: 6px 13px; font-size: 13px; font-weight: 700; background: #fff; transition: all .2s; }
.dm-chip:hover { border-color: var(--p); }
.dm-chip.is-on { background: var(--p); border-color: var(--p); color: #fff; }

/* ---------- ボタン ---------- */
.dm-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 20px; border-radius: 999px; font-size: 14px; font-weight: 900; background: var(--p); color: #fff; transition: transform .2s var(--ease), filter .2s, box-shadow .2s; white-space: nowrap; line-height: 1.3; }
.dm-btn:hover { filter: brightness(.94); transform: translateY(-1px); box-shadow: 0 10px 20px -14px var(--p); }
.dm-btn:disabled { opacity: .55; cursor: wait; transform: none; box-shadow: none; }
.dm-btn--ghost { background: #fff; color: var(--ink); border: 1.5px solid var(--line); }
.dm-btn--ghost:hover { border-color: var(--ink); box-shadow: none; }
.dm-btn--ink { background: var(--ink); }
.dm-btn--accent { background: var(--accent); }
.dm-btn--sm { padding: 7px 14px; font-size: 12.5px; }
.dm-btn--block { width: 100%; }
.dm-btn svg { width: 16px; height: 16px; stroke: currentColor; fill: none; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.dm-btn.is-busy::after { content: ""; width: 14px; height: 14px; border: 2px solid rgba(255,255,255,.45); border-top-color: #fff; border-radius: 50%; animation: dm-spin .7s linear infinite; }
@keyframes dm-spin { to { transform: rotate(360deg) } }

/* ---------- ピル・タグ ---------- */
.dm-pill { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 900; padding: 3px 10px; border-radius: 999px; white-space: nowrap; line-height: 1.5; }
.dm-pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.dm-pill--ok { background: var(--ok-bg); color: var(--ok); }
.dm-pill--warn { background: var(--warn-bg); color: var(--warn); }
.dm-pill--ng { background: var(--ng-bg); color: var(--ng); }
.dm-pill--info { background: var(--info-bg); color: var(--info); }
.dm-pill--p { background: var(--p-bg); color: var(--p-text); }
.dm-pill--off { background: var(--hair); color: var(--gray); }
.dm-tag { display: inline-block; font-size: 12px; font-weight: 900; padding: 2px 9px; border-radius: 6px; background: var(--p-bg); color: var(--p-text); }

/* ---------- テーブル ---------- */
.dm-tbl-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: var(--r-s); }
.dm-tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; min-width: 560px; }
.dm-tbl th { text-align: left; font-size: 12px; font-weight: 900; color: var(--gray); background: var(--bg); padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.dm-tbl td { padding: 11px 12px; border-bottom: 1px solid var(--hair); vertical-align: middle; }
.dm-tbl tr:last-child td { border-bottom: none; }
.dm-tbl tbody tr { transition: background .15s; }
.dm-tbl tbody tr:hover { background: #fafaf8; }
.dm-tbl tr.is-new td { animation: dm-rowin .6s var(--ease); background: var(--p-bg); }
@keyframes dm-rowin { from { opacity: 0; transform: translateY(-6px) } to { opacity: 1; transform: none } }
.dm-tbl .r { text-align: right; font-family: var(--ff-num); }

/* ---------- リスト ---------- */
.dm-list { display: grid; gap: 8px; }
.dm-list__item { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--r-s); background: #fff; }
.dm-list__item.is-on { border-color: var(--p); box-shadow: 0 0 0 3px var(--p-weak); }
.dm-list__item .t { font-weight: 900; font-size: 13.5px; line-height: 1.5; }
.dm-list__item .s { font-size: 12.5px; color: var(--gray); }
.dm-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--p); flex-shrink: 0; margin-top: 7px; }

/* ---------- 出力（生成テキスト） ---------- */
.dm-out { background: var(--bg); border: 1px solid var(--line); border-radius: var(--r-s); padding: 16px 18px; min-height: 160px; white-space: pre-wrap; line-height: 1.9; font-size: 14px; position: relative; }
.dm-out--paper { background: #fff; }
.dm-out.is-typing::after { content: ""; display: inline-block; width: 2px; height: 1.1em; background: var(--p); vertical-align: text-bottom; margin-left: 2px; animation: dm-blink .8s infinite; }
.dm-out .ph { color: var(--gray); font-weight: 700; }
.dm-out mark { background: linear-gradient(transparent 55%, var(--p-weak) 55%, var(--p-weak) 90%, transparent 90%); color: inherit; padding: 0 1px; }
.dm-out__tools { display: flex; gap: 8px; justify-content: flex-end; margin-top: 10px; flex-wrap: wrap; }

/* ---------- 処理ステップ表示 ---------- */
.dm-steps { display: grid; gap: 6px; }
.dm-step { display: flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 700; color: var(--gray); padding: 6px 10px; border-radius: 8px; }
.dm-step i { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--line); flex-shrink: 0; display: grid; place-items: center; font-style: normal; }
.dm-step.is-run { color: var(--ink); background: var(--p-bg); }
.dm-step.is-run i { border-color: var(--p); border-top-color: transparent; animation: dm-spin .8s linear infinite; }
.dm-step.is-done { color: var(--ink); }
.dm-step.is-done i { background: var(--ok); border-color: var(--ok); }
.dm-step.is-done i::after { content: ""; width: 5px; height: 8px; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); margin-top: -2px; }

/* ---------- チャット ---------- */
.dm-chat { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; background: #fff; min-height: 460px; }
.dm-chat__head { padding: 12px 16px; background: var(--p); color: #fff; font-weight: 900; font-size: 14px; display: flex; align-items: center; gap: 10px; }
.dm-chat__head small { font-weight: 700; font-size: 12px; color: #fff; margin-left: auto; }
.dm-chat__log { flex: 1; padding: 16px; display: flex; flex-direction: column; gap: 10px; overflow-y: auto; background: var(--bg); max-height: 440px; }
.dm-msg { max-width: 86%; padding: 10px 14px; border-radius: 14px; font-size: 14px; line-height: 1.75; white-space: pre-wrap; animation: dm-rowin .35s var(--ease); }
.dm-msg--bot { background: #fff; border: 1px solid var(--line); border-bottom-left-radius: 4px; align-self: flex-start; }
.dm-msg--user { background: var(--p); color: #fff; border-bottom-right-radius: 4px; align-self: flex-end; }
.dm-msg--sys { align-self: center; font-size: 12px; color: var(--gray); font-weight: 700; background: none; }
.dm-msg .src { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; font-size: 12px; font-weight: 900; color: var(--p-text); background: var(--p-bg); padding: 3px 9px; border-radius: 6px; }
.dm-msg .lnk { display: inline-block; margin-top: 8px; font-size: 13px; font-weight: 900; color: var(--p); text-decoration: underline; text-underline-offset: 3px; }
.dm-typing { display: inline-flex; gap: 4px; padding: 12px 14px; }
.dm-typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--gray-2); animation: dm-bounce 1s infinite; }
.dm-typing i:nth-child(2) { animation-delay: .15s } .dm-typing i:nth-child(3) { animation-delay: .3s }
@keyframes dm-bounce { 0%,80%,100% { transform: translateY(0) } 40% { transform: translateY(-5px) } }
.dm-chat__form { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--line); background: #fff; }
.dm-chat__form input { flex: 1; }
.dm-chat__quick { display: flex; gap: 6px; flex-wrap: wrap; padding: 10px 12px 0; background: #fff; }

/* ---------- 棒グラフ（CSSのみ） ---------- */
.dm-bars { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 8px; align-items: end; height: 150px; padding-top: 22px; }
.dm-bar { position: relative; background: var(--p); border-radius: 5px 5px 0 0; height: calc(var(--v) * 1%); min-height: 3px; transition: height .8s var(--ease); }
.dm-bar.is-sub { background: var(--p-weak); }
.dm-bar.is-hi { background: var(--accent); }
.dm-bar::after { content: attr(data-v); position: absolute; top: -20px; left: 50%; transform: translateX(-50%); font-family: var(--ff-num); font-size: 11px; font-weight: 700; color: var(--ink); white-space: nowrap; }
.dm-bars-x { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 8px; margin-top: 6px; }
.dm-bars-x span { text-align: center; font-size: 11px; font-weight: 700; color: var(--gray); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dm-legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; font-weight: 700; color: var(--gray); margin-top: 8px; }
.dm-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; background: var(--p); vertical-align: -1px; margin-right: 5px; }
.dm-legend i.sub { background: var(--p-weak); } .dm-legend i.hi { background: var(--accent); }

/* ---------- 進捗バー ---------- */
.dm-prog { height: 8px; background: var(--hair); border-radius: 999px; overflow: hidden; }
.dm-prog i { display: block; height: 100%; width: calc(var(--v) * 1%); background: var(--p); border-radius: 999px; transition: width .8s var(--ease); }

/* ---------- タブ ---------- */
.dm-tabs { display: flex; gap: 4px; background: var(--hair); padding: 4px; border-radius: 999px; width: max-content; max-width: 100%; overflow-x: auto; }
.dm-tabs button { padding: 7px 16px; border-radius: 999px; font-size: 13px; font-weight: 900; color: var(--gray); white-space: nowrap; }
.dm-tabs button.is-on { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgba(16,19,25,.12); }

/* ---------- デバイス枠（プレビュー） ---------- */
.dm-device { border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: #fff; box-shadow: var(--sh); }
.dm-device__bar { height: 34px; background: #eceef1; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 6px; padding: 0 12px; }
.dm-device__bar i { width: 10px; height: 10px; border-radius: 50%; background: #c9ced9; }
.dm-device__bar span { margin-left: 8px; background: #fff; border-radius: 6px; padding: 2px 10px; font-size: 11.5px; color: var(--gray); font-weight: 700; flex: 1; max-width: 360px; font-family: var(--ff-num); }
.dm-device__body { position: relative; }
.dm-device--phone { width: 320px; max-width: 100%; margin: 0 auto; border-radius: 30px; border: 8px solid var(--ink); }
.dm-device--phone .dm-device__bar { display: none; }

/* ---------- トースト ---------- */
.dm-toast { position: fixed; left: 50%; bottom: 96px; transform: translate(-50%, 20px); background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 999px; font-size: 13.5px; font-weight: 900; opacity: 0; transition: all .35s var(--ease); z-index: 60; pointer-events: none; white-space: nowrap; max-width: 92vw; box-shadow: 0 12px 30px -12px rgba(0,0,0,.4); }
.dm-toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* ---------- 下部CTAバー ---------- */
.dm-cta { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; background: #fff; border-top: 1px solid var(--line); box-shadow: 0 -10px 30px -22px rgba(16,19,25,.3); }
.dm-cta__in { display: flex; align-items: center; gap: 14px; padding: 12px 22px; }
.dm-cta__txt { font-size: 13.5px; font-weight: 900; line-height: 1.5; }
.dm-cta__txt small { display: block; font-size: 12px; color: var(--gray); font-weight: 700; }
.dm-cta__btns { margin-left: auto; display: flex; gap: 8px; flex-shrink: 0; }
@media (min-width: 961px) { .dm-cta { left: var(--side-w); } }

/* ---------- 補助 ---------- */
.dm-sep { height: 1px; background: var(--hair); margin: 14px 0; }
.dm-muted { color: var(--gray); font-size: 12.5px; font-weight: 700; }
.dm-em { color: var(--p-text); font-weight: 900; }
.dm-flex { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.dm-right { margin-left: auto; }
.dm-mt { margin-top: 14px; } .dm-mb { margin-bottom: 14px; }
.dm-hide { display: none !important; }
.dm-mono { font-family: var(--ff-num); }
.dm-ico { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.dm-avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--p-bg); color: var(--p-text); font-weight: 900; font-size: 13px; display: grid; place-items: center; flex-shrink: 0; }
.dm-timeline { display: grid; gap: 0; }
.dm-tl { display: grid; grid-template-columns: 22px 1fr; gap: 10px; }
.dm-tl__line { position: relative; }
.dm-tl__line::before { content: ""; position: absolute; left: 10px; top: 0; bottom: 0; width: 2px; background: var(--hair); }
.dm-tl__line i { position: absolute; left: 5px; top: 8px; width: 12px; height: 12px; border-radius: 50%; background: var(--p); border: 2px solid #fff; box-shadow: 0 0 0 2px var(--p-weak); }
.dm-tl__body { padding: 4px 0 18px; }
.dm-tl__time { font-family: var(--ff-num); font-size: 11.5px; font-weight: 700; color: var(--gray); }
.dm-tl__t { font-weight: 900; font-size: 13.5px; }
.dm-tl__s { font-size: 13px; color: var(--gray); }

/* ---------- レスポンシブ ---------- */
@media (max-width: 1200px) {
  .dm-grid--4 { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .dm-grid--3 { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 960px) {
  :root { --side-w: 0px; }
  .dm-app { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); }
  .dm-side { position: static; height: auto; padding: 12px 14px 0; min-width: 0; }
  .dm-nav { min-width: 0; }
  .dm-body, .dm-main { min-width: 0; max-width: 100vw; }
  .dm-side__brand { border: none; padding: 2px 4px 10px; margin: 0; }
  .dm-side__sec, .dm-side__foot { display: none; }
  .dm-nav { display: flex; gap: 6px; overflow-x: auto; -webkit-overflow-scrolling: touch; padding-bottom: 12px; scrollbar-width: none; }
  .dm-nav::-webkit-scrollbar { display: none; }
  .dm-nav a, .dm-nav button { width: auto; white-space: nowrap; padding: 8px 14px; font-size: 13px; background: rgba(255,255,255,.08); }
  .dm-nav .cnt { display: none; }
  .dm-top { padding: 0 14px; height: 54px; }
  .dm-top__title small { display: none; }
  .dm-main { padding: 14px 14px 140px; gap: 14px; }
  .dm-grid--2, .dm-grid--3, .dm-grid--4, .dm-grid--side, .dm-grid--wide { grid-template-columns: 1fr; }
  .dm-card { padding: 16px; }
  .dm-row { grid-template-columns: 1fr; }
  .dm-h h1 { font-size: 19px; }
  .dm-kpi__val { font-size: 26px; }
  .dm-chat__log { max-height: 380px; }
  .dm-cta__in { flex-direction: column; align-items: stretch; gap: 8px; padding: 10px 14px; }
  .dm-cta__txt { font-size: 13px; }
  .dm-cta__txt small { display: none; }
  .dm-cta__btns { margin-left: 0; }
  .dm-cta__btns .dm-btn { flex: 1; }
  .dm-toast { bottom: 130px; }
}
@media (max-width: 600px) {
  .dm-top { gap: 8px; }
  .dm-top__right .dm-btn--ghost { display: none; }
  .dm-top__right .dm-btn--sm { padding: 6px 11px; font-size: 12px; }
  .dm-demo-tag { font-size: 11px; padding: 3px 8px; }
  .dm-guide { font-size: 13px; }
  .dm-cta__btns .dm-btn--ghost { display: none; }
}
