/* Morpha ホームページの共通の見た目。
   暗く落ち着いた下地に、Morpha の白い画面（.app-shot）が浮かぶように作る。
   色はロゴのブランド色（#7C3AED・#A855F7・#EC4899）を、線と小さな面にだけ使う。
   色は下の変数だけで決める。:root がダーク、:root[data-theme="light"] がライト（アプリの色）。
   明暗で変わる色をページ・規則に直接書かない。 */

:root {
  --bg: #08080a;
  --bg-elev: #111115;
  --bg-elev-2: #17171c;
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.16);
  --text: #f1f0f4;
  --muted: #a5a3af;
  --faint: #6f6d79;
  --violet: #7c3aed;
  --purple: #a855f7;
  --pink: #ec4899;
  --rose: #be4b6c;
  --ok: #4ade80;
  --warn: #fbbf24;
  --err: #f87171;
  --grad: linear-gradient(115deg, #a855f7 0%, #ec4899 100%);
  /* 書体はアプリと同じ Noto Sans JP に統一する（MainApp/Themes/Typography.xaml） */
  --sans: "Noto Sans JP", "Yu Gothic UI", "Yu Gothic", Meiryo, system-ui, sans-serif;
  --radius: 14px;
  --max: 1160px;
  /* 明暗で変わる色。ダークの値は、変数にする前の値と同じ */
  --text-soft: #d9d7e0;
  --accent-fg: #e9d5ff;
  --accent-subtle: rgba(168, 85, 247, 0.1);
  --addon: #f0abfc;
  --addon-rgb: 240, 171, 252;
  --ok-rgb: 74, 222, 128;
  --warn-rgb: 251, 191, 36;
  --err-rgb: 248, 113, 113;
  --glow-a: rgba(124, 58, 237, 0.18);
  --glow-b: rgba(236, 72, 153, 0.12);
  --notice-bg: rgba(255, 255, 255, 0.02);
  --header-bg: rgba(8, 8, 10, 0.72);
  --hover: rgba(255, 255, 255, 0.05);
  --hover-soft: rgba(255, 255, 255, 0.04);
  --shadow-pop: 0 18px 40px rgba(0, 0, 0, 0.55);
  --card-shadow: none;
  --shot-shadow: 0 1px 0 rgba(255, 255, 255, 0.5) inset, 0 30px 90px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.12);
  --shot-glow: 1;
  --shot-sel: #f6eef2;
  --feature-bg: var(--bg);
  --skel-a: rgba(255, 255, 255, 0.04);
  --skel-b: rgba(255, 255, 255, 0.09);
  --contract-bg: rgba(255, 255, 255, 0.015);
  --btn-main-bg: #fff;
  --btn-main-fg: #111;
  --btn-main-hover: #ece9f3;
  --ghost-hover-line: rgba(255, 255, 255, 0.4);
  --chart-bar: #a855f7;     /* 管理者用のダッシュボードの棒（下地との対比 3:1 以上を確認済み） */
  color-scheme: dark;
}

/* ライトモード。アプリの白基調の配色（01_Product/Morpha/MainApp/Themes/LightTheme.xaml）に合わせる。
   右のコメントはアプリの色のキー。「アプリに無い」は、Web で読めるように決めた色 */
:root[data-theme="light"] {
  --bg: #f5f5f8;            /* MorphaBackgroundBrush */
  --bg-elev: #ffffff;       /* MorphaCardBrush */
  --bg-elev-2: #fcfcfd;     /* MorphaSidePanelBackground */
  --line: #e2dfea;          /* MorphaBorderBrush */
  --line-strong: #cfcad9;   /* MorphaInputBorderHoverBrush */
  --text: #1e1b26;          /* MorphaTextBrush */
  --text-soft: #1e1b26;     /* MorphaTextBrush */
  --muted: #6e6a7c;         /* MorphaTextSecondaryBrush */
  --faint: #7f7b8c;         /* アプリに無い（3段目の文字） */
  --rose: #9333ea;          /* MorphaAccentForegroundBrush（作り物の画面のアイコン） */
  --ok: #107c41;            /* MorphaSuccessBrush */
  --warn: #9a5b00;          /* MorphaWarningBrush */
  --err: #c42b1c;           /* MorphaErrorTextBrush */
  --ok-rgb: 16, 124, 65;
  --warn-rgb: 154, 91, 0;
  --err-rgb: 196, 43, 28;
  --accent-fg: #9333ea;     /* MorphaAccentForegroundBrush */
  --accent-subtle: #f1e7fe; /* MorphaAccentSubtleBrush */
  --addon: #a21caf;         /* アプリに無い（MorphaHighlightBrush は白の上の小さい文字には薄い） */
  --addon-rgb: 162, 28, 175;
  --grad: linear-gradient(115deg, #8558d0 0%, #d05c9f 100%); /* MorphaSelectedGradient */
  --glow-a: rgba(124, 58, 237, 0.07);
  --glow-b: rgba(236, 72, 153, 0.05);
  --notice-bg: rgba(30, 27, 38, 0.03);
  --header-bg: rgba(245, 245, 248, 0.82);
  --hover: #efedf4;         /* MorphaHoverBrush */
  --hover-soft: #efedf4;    /* MorphaHoverBrush */
  --shadow-pop: 0 14px 36px rgba(42, 33, 64, 0.16);
  --card-shadow: 0 2px 14px rgba(42, 33, 64, 0.08); /* MorphaCardShadowEffect */
  --shot-shadow: 0 24px 64px rgba(42, 33, 64, 0.18), 0 0 0 1px #e2dfea;
  --shot-glow: 0.45;
  --shot-sel: #f1e7fe;      /* MorphaAccentSubtleBrush */
  --feature-bg: #ffffff;    /* MorphaCardBrush */
  --skel-a: rgba(30, 27, 38, 0.05);
  --skel-b: rgba(30, 27, 38, 0.1);
  --contract-bg: #fcfcfd;   /* MorphaSidePanelBackground */
  --btn-main-bg: #7e22ce;   /* MorphaDeepBrush（アプリの主のボタン） */
  --btn-main-fg: #f7f7f5;   /* MorphaOffWhite */
  --btn-main-hover: #6b1cb0;
  --ghost-hover-line: #a9a6b4; /* MorphaAvatarEmptyBrush */
  --chart-bar: #9333ea;     /* MorphaAccentForegroundBrush（管理者用のダッシュボードの棒） */
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background:
    radial-gradient(1200px 600px at 12% -10%, var(--glow-a), transparent 60%),
    radial-gradient(900px 500px at 92% 0%, var(--glow-b), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  color: var(--text);
  font-family: var(--sans);
  font-weight: 400;
  line-height: 1.8;
  letter-spacing: 0.02em;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
img, svg { max-width: 100%; display: block; }
[hidden] { display: none !important; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 24px; }
@media (max-width: 600px) { .wrap { padding: 0 16px; } }

/* ---------- 準備中の帯 ---------- */
.notice-bar {
  text-align: center; font-size: 0.78rem; color: var(--muted);
  padding: 7px 16px; border-bottom: 1px solid var(--line); background: var(--notice-bg);
  letter-spacing: 0.06em;
}
.notice-bar a { color: inherit; text-decoration: underline; text-underline-offset: 2px; margin-left: 0.5em; white-space: nowrap; }

/* ---------- ヘッダー ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--header-bg);
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; gap: 28px; height: 66px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img { width: 26px; height: 26px; }
.brand span { font-size: 1.3rem; font-weight: 700; letter-spacing: 0.02em; }
.nav { display: flex; align-items: center; gap: 4px; margin-right: auto; }
.account-area { display: flex; align-items: center; gap: 12px; min-height: 34px; }

/* ---------- ヘッダーのメニュー（機能・サポート・言語。<details> で開く。中身は tools-layout.mjs が書く） ---------- */
.dd { position: relative; }
.dd > summary {
  list-style: none; display: inline-flex; align-items: center; gap: 6px; cursor: pointer; user-select: none;
  height: 34px; padding: 0 12px; border-radius: 999px; border: 1px solid transparent;
  color: var(--muted); font-size: 0.9rem; white-space: nowrap; transition: color 0.2s, border-color 0.2s, background 0.2s;
}
.dd > summary::-webkit-details-marker { display: none; }
.dd > summary:hover, .dd[open] > summary { color: var(--text); background: var(--hover); }
.dd > summary.is-current { color: var(--text); }
.dd > summary:focus-visible, .dd-panel a:focus-visible { outline: 2px solid var(--purple); outline-offset: 2px; }
.dd svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.dd .chev { width: 12px; height: 12px; transition: transform 0.2s; }
.dd[open] .chev { transform: rotate(180deg); }
.dd-panel {
  position: absolute; left: 0; top: calc(100% + 10px); z-index: 60; min-width: 168px;
  padding: 6px; display: grid; gap: 2px;
  background: var(--bg-elev-2); border: 1px solid var(--line-strong); border-radius: 14px;
  box-shadow: var(--shadow-pop);
}
.dd-panel a {
  display: flex; align-items: center; gap: 12px;
  padding: 8px 12px; border-radius: 10px; color: var(--muted); text-decoration: none; font-size: 0.88rem;
}
.dd-panel a:hover { background: var(--hover); color: var(--text); }
.dd-panel a[aria-current="page"] { background: var(--accent-subtle); }
/* 機能・サポート：アイコン・名前・説明 */
.dd-panel.rich { width: 340px; padding: 8px; }
.dd-panel.rich a { align-items: flex-start; padding: 10px 12px; }
.dd-ico {
  flex: none; width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center;
  background: var(--accent-subtle); border: 1px solid rgba(168, 85, 247, 0.25);
}
.dd-ico svg { width: 18px; height: 18px; stroke: var(--accent-fg); }
.dd-text { display: grid; gap: 1px; }
.dd-title { color: var(--text); font-weight: 500; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.dd-desc { color: var(--muted); font-size: 0.8rem; line-height: 1.5; }
.dd-tag { font-size: 0.66rem; letter-spacing: 0.08em; padding: 0 8px; border-radius: 999px; border: 1px solid var(--line-strong); color: var(--muted); font-weight: 400; }
.dd-tag.free { color: var(--ok); border-color: rgba(var(--ok-rgb), 0.35); }
.dd-tag.addon { color: var(--addon); border-color: rgba(var(--addon-rgb), 0.35); }
/* メニューを開かない項目（ニュース）。見た目は .dd > summary にそろえる */
.nav-link {
  display: inline-flex; align-items: center; height: 34px; padding: 0 12px; border-radius: 999px; border: 1px solid transparent;
  color: var(--muted); font-size: 0.9rem; white-space: nowrap; text-decoration: none; transition: color 0.2s, background 0.2s;
}
.nav-link:hover { color: var(--text); background: var(--hover); }
.nav-link:focus-visible { outline: 2px solid var(--purple); outline-offset: 2px; }
/* 言語：右寄せ。今の言語に点 */
.lang > summary { font-size: 0.85rem; }
.lang > summary:hover, .lang[open] > summary { background: none; border-color: var(--line-strong); }
.lang .dd-panel { left: auto; right: 0; }
.lang .dd-panel a { justify-content: space-between; }
.lang .dd-panel a[aria-current="true"] { color: var(--text); }
.lang .dd-panel a[aria-current="true"]::after { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--grad); }

/* スマホの幅：1行目はロゴとログインのボタン（ログイン中でも1行に収める）。
   2行目に機能・サポートと、右端に言語（地球のアイコンだけ）。機能・サポートの中身は画面の幅いっぱいに開く */
@media (max-width: 760px) {
  .site-header .wrap { flex-wrap: wrap; height: auto; padding-top: 12px; column-gap: 16px; row-gap: 6px; }
  .brand { margin-right: auto; }
  .account-area { display: contents; }
  #hdr-user:empty { display: none; }   /* ログイン前の空の入れ物が、すき間だけ取らないように */
  .nav { order: 3; flex: 1 1 calc(100% - 104px); margin: 0 0 8px -12px; }
  .nav .dd { position: static; }
  .nav .dd-panel { left: 16px; right: 16px; top: calc(100% + 4px); width: auto; }
  .theme-toggle { order: 4; margin-bottom: 8px; }
  .lang { order: 5; margin-bottom: 8px; }
  .lang > summary { padding: 0 10px; }
  .lang .lang-name, .lang .chev { display: none; }
}
/* さらに狭い幅：製品・サポート・Beta 版・ニュース・切り替え・言語を1行に収めるため、余白を詰め、メニューの▼を隠す
   （Beta 版のリンクを足した 2026-11-15 に、390px で言語が2行目に落ちたため） */
@media (max-width: 430px) {
  .site-header .wrap { column-gap: 8px; }
  .nav { gap: 0; margin-left: -8px; }
  .nav .dd > summary, .nav-link { padding: 0 8px; }
  .nav .dd > summary { gap: 0; }
  .nav .dd > summary .chev { display: none; }
}
@media (max-width: 380px) {
  .site-header .wrap { column-gap: 4px; }
  .nav .dd > summary { gap: 0; padding: 0 5px; }
  .nav .dd > summary .chev { display: none; }
  .nav-link { padding: 0 5px; }
  .nav { margin-left: -5px; }
  .lang > summary { padding: 0 6px; }
}

/* ---------- ボタン ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-size: 0.92rem; font-weight: 500; letter-spacing: 0.06em;
  padding: 12px 26px; border-radius: 999px; cursor: pointer; text-decoration: none;
  border: 1px solid transparent; transition: transform 0.15s, background 0.2s, border-color 0.2s, opacity 0.2s;
}
.btn:active { transform: translateY(1px); }
.btn-light { background: var(--btn-main-bg); color: var(--btn-main-fg); }
.btn-light:hover { background: var(--btn-main-hover); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--line-strong); }
.btn-ghost:hover { border-color: var(--ghost-hover-line); background: var(--hover-soft); }
.btn-grad { background: var(--grad); color: #fff; }
.btn-grad:hover { opacity: 0.92; }
.btn-small { padding: 7px 16px; font-size: 0.82rem; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.45; cursor: not-allowed; }

/* ---------- 見出し・文字 ---------- */
.eyebrow {
  display: inline-block; font-size: 0.72rem; letter-spacing: 0.32em; text-transform: uppercase;
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
  font-weight: 500;
}
h1, h2, h3 { font-weight: 700; letter-spacing: 0.02em; line-height: 1.4; margin: 0; }
h3 { font-weight: 500; }
h1 { font-size: clamp(2.2rem, 5.6vw, 4.2rem); }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.4rem); }
h3 { font-size: 1.15rem; }
.lead { color: var(--muted); font-size: clamp(1rem, 1.6vw, 1.12rem); max-width: 40em; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.rule { height: 1px; background: linear-gradient(90deg, transparent, var(--line-strong), transparent); border: 0; margin: 0; }

/* ---------- セクション ---------- */
.section { padding: 110px 0; }
.section-tight { padding: 72px 0; }
.section-head { display: grid; gap: 14px; margin-bottom: 48px; }
@media (max-width: 600px) { .section { padding: 72px 0; } }

/* ---------- ヒーロー ---------- */
.hero { padding: 96px 0 40px; text-align: center; }
.hero .lead { margin: 22px auto 0; }
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-top: 36px; }
.hero-note { margin-top: 14px; font-size: 0.8rem; color: var(--faint); }

/* ---------- Morpha の白い画面（作り物の画面。実際の画面に似せた図） ---------- */
.shot-stage { position: relative; margin: 64px auto 0; max-width: 1080px; }
.shot-stage::before {
  content: ""; position: absolute; inset: 10% 6% -8%; z-index: 0;
  background: radial-gradient(closest-side, rgba(168, 85, 247, 0.38), rgba(236, 72, 153, 0.18) 55%, transparent);
  filter: blur(40px); opacity: var(--shot-glow);
}
.app-shot {
  position: relative; z-index: 1;
  background: #fff; color: #1f2030; border-radius: 12px; overflow: hidden;
  box-shadow: var(--shot-shadow);
  font-family: var(--sans); font-size: 12px; letter-spacing: 0; line-height: 1.5;
  text-align: left;
}
.app-titlebar { display: flex; align-items: center; gap: 10px; height: 34px; padding: 0 12px; border-bottom: 1px solid #eeeef3; }
.app-titlebar img { width: 16px; height: 16px; }
.app-titlebar .t-name { font-weight: 600; }
.app-titlebar .t-file { margin: 0 auto; color: #8a8b99; }
.app-titlebar .t-win { display: flex; gap: 14px; color: #9b9cab; font-size: 11px; }
.app-tabs { display: flex; gap: 18px; padding: 0 14px; height: 30px; align-items: center; color: #6c6d7c; border-bottom: 1px solid #f0f0f4; }
.app-tabs .on { color: #1f2030; font-weight: 600; border-bottom: 2px solid var(--rose); padding: 5px 0 4px; }
.app-ribbon { display: flex; gap: 2px; padding: 8px 10px; border-bottom: 1px solid #eeeef3; background: #fcfcfe; overflow: hidden; }
.app-ribbon .grp { display: flex; gap: 2px; padding-right: 8px; margin-right: 8px; border-right: 1px solid #ececf2; }
.app-ribbon .grp:last-child { border-right: 0; }
.rb { display: grid; justify-items: center; gap: 3px; min-width: 58px; padding: 6px 6px; border-radius: 6px; color: #4b4c5b; font-size: 10.5px; white-space: nowrap; }
.rb svg { width: 22px; height: 22px; stroke: var(--rose); fill: none; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.rb.on { background: var(--shot-sel); }
.app-body { display: grid; grid-template-columns: 200px 1fr 210px; gap: 10px; padding: 10px; background: #f3f3f7; min-height: 420px; }
.panel { background: #fff; border-radius: 10px; box-shadow: 0 1px 3px rgba(20, 20, 40, 0.06); padding: 12px; }
.panel h4 { margin: 0 0 8px; font-size: 11px; color: #8a8b99; font-weight: 600; letter-spacing: 0.04em; }
.tree { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.tree li { display: flex; align-items: center; gap: 7px; padding: 4px 6px; border-radius: 5px; color: #3a3b4a; white-space: nowrap; }
.tree li svg { width: 14px; height: 14px; stroke: var(--rose); fill: none; stroke-width: 1.5; flex: none; }
.tree li.sel { background: var(--shot-sel); color: #1f2030; font-weight: 600; }
.viewport { position: relative; border-radius: 10px; background: linear-gradient(180deg, #fbfbfd, #e9e9f0); overflow: hidden; display: grid; place-items: center; }
.viewport img { width: 74%; }
.viewport .crumb { position: absolute; top: 10px; left: 12px; color: #7a7b8a; font-size: 11px; }
.viewport .triad { position: absolute; right: 14px; bottom: 12px; width: 46px; height: 46px; }
.props dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 6px 10px; font-size: 11px; }
.props dt { color: #8a8b99; }
.props dd { margin: 0; padding: 2px 6px; border: 1px solid #ececf2; border-radius: 4px; color: #2a2b39; }
.app-status { display: flex; gap: 18px; padding: 6px 14px; border-top: 1px solid #eeeef3; color: #8a8b99; font-size: 11px; }
.app-status .ok::before { content: "●"; color: #22c55e; margin-right: 6px; }
@media (max-width: 860px) {
  .app-body { grid-template-columns: 1fr; min-height: 0; }
  .app-body .panel { display: none; }
  .viewport { min-height: 280px; }
  .app-ribbon .grp:nth-child(n+3) { display: none; }
  .app-tabs span:nth-child(n+5) { display: none; }
}

/* ---------- 製品のカード ---------- */
.products { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 900px) { .products { grid-template-columns: 1fr; } }
.products.products-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 700px) { .products.products-4 { grid-template-columns: 1fr; } }

/* トップページの AI の節（頼む言葉と、AI がすること） */
.pill { justify-self: start; font-size: 0.72rem; letter-spacing: 0.08em; padding: 3px 10px; border-radius: 999px; border: 1px solid var(--line-strong); color: var(--muted); }
.pill.ok { color: var(--ok); border-color: rgba(var(--ok-rgb), 0.35); }
.ai-cases { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
@media (max-width: 900px) { .ai-cases { grid-template-columns: 1fr; } }
.ai-case { border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-elev); padding: 24px; display: grid; gap: 12px; align-content: start; }
.ai-case h3, .ai-way h3 { font-size: 1.08rem; }
.ai-say { margin: 0; padding: 12px 14px; border: 1px solid var(--line-strong); border-radius: 14px 14px 14px 4px; background: var(--bg-elev-2); font-size: 0.92rem; }
.ai-say::before { content: "「"; } .ai-say::after { content: "」"; }
:lang(en) .ai-say::before { content: "“"; } :lang(en) .ai-say::after { content: "”"; }
.ai-do { margin: 0; padding-left: 22px; position: relative; color: var(--muted); font-size: 0.9rem; }
.ai-do::before { content: "→"; position: absolute; left: 0; color: var(--faint); }
.ai-ways { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: 20px; }
@media (max-width: 760px) { .ai-ways { grid-template-columns: 1fr; } }
.ai-way { border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; display: grid; gap: 10px; align-content: start; }
.ai-way p { margin: 0; font-size: 0.92rem; }
.product {
  position: relative; display: grid; grid-template-rows: auto 1fr; text-decoration: none;
  background: linear-gradient(180deg, var(--bg-elev), var(--bg));
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  transition: border-color 0.25s, transform 0.25s;
}
.product:hover { border-color: rgba(168, 85, 247, 0.45); transform: translateY(-3px); }
.product .art { position: relative; aspect-ratio: 16 / 10; overflow: hidden; border-bottom: 1px solid var(--line);
  background: radial-gradient(70% 70% at 50% 60%, rgba(168, 85, 247, 0.08), transparent); }
.product .art img { position: absolute; inset: 24px; width: calc(100% - 48px); height: calc(100% - 48px); object-fit: contain; }
.product .body { padding: 24px; display: grid; gap: 10px; align-content: start; }
.product .tag { justify-self: start; font-size: 0.72rem; letter-spacing: 0.12em; padding: 3px 10px; border-radius: 999px; border: 1px solid var(--line-strong); color: var(--muted); }
.product .tag.free { color: var(--ok); border-color: rgba(var(--ok-rgb), 0.35); }
.product .tag.addon { color: var(--addon); border-color: rgba(var(--addon-rgb), 0.35); }
.product .more { margin-top: 6px; font-size: 0.86rem; color: var(--text); }
.product .more::after { content: " →"; }

/* ---------- 特長の格子 ---------- */
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
@media (max-width: 900px) { .features { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .features { grid-template-columns: 1fr; } }
.feature { background: var(--feature-bg); padding: 30px 28px; display: grid; gap: 10px; align-content: start; }
.feature .num { font-size: 0.85rem; font-weight: 500; letter-spacing: 0.08em; color: var(--faint); font-variant-numeric: tabular-nums; }
.feature p { margin: 0; color: var(--muted); font-size: 0.93rem; }

/* ---------- 2列（文章と図） ---------- */
.split { display: grid; grid-template-columns: 1.1fr 1fr; gap: 64px; align-items: center; }
.split > * { min-width: 0; }   /* 折り返さないコードの枠が、列を画面の外へ押し広げないように */
@media (max-width: 900px) { .split { grid-template-columns: 1fr; gap: 36px; } }
.check { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 10px; }
.check li { padding-left: 26px; position: relative; color: var(--muted); }
.check li::before { content: ""; position: absolute; left: 0; top: calc(0.9em - 0.5px); top: calc(0.5lh - 0.5px); width: 12px; height: 1px; background: var(--grad); }
.frame { border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-elev); padding: 28px; overflow-x: auto; }

/* ---------- 価格 ---------- */
.price-card { border: 1px solid var(--line-strong); border-radius: var(--radius); padding: 36px; background: linear-gradient(180deg, var(--bg-elev-2), var(--bg-elev)); display: grid; gap: 16px; max-width: 520px; }
.price { font-size: 2.6rem; line-height: 1; font-weight: 700; letter-spacing: 0; font-variant-numeric: tabular-nums; }
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.plans .price-card { max-width: none; padding: 28px; display: flex; flex-direction: column; }
/* ボタンの並び（Pro は注記も）をカードの下端にそろえる。横に並んだカードの高さは同じなので、ボタンの位置がそろう */
.plan-actions { margin-top: auto; display: grid; gap: 12px; }
@media (max-width: 1000px) { .plans { grid-template-columns: 1fr; } }
/* トップページの最初の画面に置くプラン（小さめにして、画面の中に収める） */
.hero-plans { padding-top: 32px; }
.hero-plans h1 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); }
.hero-plans .lead { margin-top: 12px; max-width: 56em; }
.plans-hero { max-width: 1080px; margin: 26px auto 0; text-align: left; }
.plans-hero .price-card { padding: 20px 24px; gap: 10px; }
.plan-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.plans-hero .price { font-size: 1.6rem; }
.plans-hero .plan-for { margin: 0; color: var(--muted); font-size: 0.86rem; }
/* 試用のボタンの下の注記（Pro は購入の前に試用だけできる） */
/* ボタンの文を、区切り（span）の所で折る：入りきらなければ「（60日間）」を次の行へ送る（.btn は flex なので、区切りごとに折り返す） */
.btn:has(.nb) { flex-wrap: wrap; column-gap: 0; row-gap: 0; }
.btn .nb { max-width: 100%; }
@media (min-width: 701px) and (max-width: 1000px) { .price-card .btn:has(.nb) { padding-left: 14px; padding-right: 14px; } }
.price-card .plan-note { margin: 0; color: var(--faint, var(--muted)); font-size: 0.8rem; line-height: 1.6; }
.plans-hero .check { margin: 0; gap: 6px; font-size: 0.9rem; }
.plans-hero .plan-actions { gap: 10px; padding-top: 4px; }
@media (min-width: 701px) and (max-width: 1000px) { .plans-hero { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; } .plans-hero .price-card { padding: 18px; } }
.hero-buy { display: flex; gap: 12px; align-items: center; justify-content: center; flex-wrap: wrap; margin-top: 20px; font-size: 0.88rem; color: var(--muted); }
.price small { font-family: var(--sans); font-size: 0.9rem; color: var(--muted); font-weight: 400; margin-left: 6px; }

/* ---------- メッセージ ---------- */
.msg { border-radius: 10px; padding: 14px 18px; font-size: 0.92rem; border: 1px solid var(--line-strong); background: var(--bg-elev); }
.msg.ok { border-color: rgba(var(--ok-rgb), 0.4); }
.msg.warn { border-color: rgba(var(--warn-rgb), 0.45); }
.msg.err { border-color: rgba(var(--err-rgb), 0.5); }

/* ---------- ユーザーページ ---------- */
.account-grid { display: grid; grid-template-columns: 1fr 340px; gap: 28px; align-items: start; }
@media (max-width: 960px) { .account-grid { grid-template-columns: 1fr; } }
/* ユーザーページの左のタブ（狭い画面では上の横並び） */
.acct-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 28px; align-items: start; }
.acct-nav { position: sticky; top: 88px; display: grid; gap: 4px; }
.acct-nav a { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 10px; border: 1px solid transparent; color: var(--muted); text-decoration: none; font-size: 0.92rem; transition: color 0.2s, background 0.2s; }
.acct-nav a:hover { color: var(--text); background: var(--hover-soft); }
.acct-nav a[aria-current="page"] { color: var(--text); background: var(--accent-subtle); border-color: rgba(168, 85, 247, 0.3); }
.acct-nav a:focus-visible { outline: 2px solid var(--purple); outline-offset: 2px; }
.acct-nav svg { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.acct-nav .acct-nav-help { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); border-radius: 0; font-size: 0.85rem; }
.acct-main { min-width: 0; }
@media (max-width: 860px) {
  .acct-layout { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .acct-nav { position: static; display: flex; gap: 6px; overflow-x: auto; padding-bottom: 4px; }
  .acct-nav a { flex: none; white-space: nowrap; padding: 8px 12px; }
  .acct-nav .acct-nav-help { margin: 0; padding: 8px 12px; border-top: 0; border-radius: 10px; }
}
.card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-elev); padding: 26px; }
.card + .card { margin-top: 20px; }
.card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.license { display: grid; grid-template-columns: 44px 1fr auto; gap: 16px; align-items: center; padding: 16px 0; border-top: 1px solid var(--line); }
.license:first-of-type { border-top: 0; padding-top: 0; }
.license .ico { width: 44px; height: 44px; border-radius: 10px; display: grid; place-items: center; background: var(--accent-subtle); border: 1px solid rgba(168, 85, 247, 0.25); }
.license .ico svg { width: 22px; height: 22px; stroke: var(--accent-fg); fill: none; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.license .name { font-weight: 500; }
.license .meta { color: var(--muted); font-size: 0.85rem; }
@media (max-width: 600px) { .license { grid-template-columns: 44px 1fr; } .license .badge { grid-column: 2; justify-self: start; } }
.badge { font-size: 0.74rem; letter-spacing: 0.08em; padding: 4px 12px; border-radius: 999px; border: 1px solid var(--line-strong); white-space: nowrap; }
.badge.ok { color: var(--ok); border-color: rgba(var(--ok-rgb), 0.4); }
.badge.warn { color: var(--warn); border-color: rgba(var(--warn-rgb), 0.45); }
.badge.err { color: var(--err); border-color: rgba(var(--err-rgb), 0.5); }
.badge.off { color: var(--faint); }
/* 見積書のフォーム（/quote/） */
.quote-form { display: grid; gap: 18px; }
.field { display: grid; gap: 6px; }
.field label, .items legend { font-size: 0.9rem; font-weight: 500; }
.req { font-size: 0.72rem; color: var(--warn); margin-left: 6px; font-weight: 400; }
.quote-form input { width: 100%; min-width: 0; padding: 10px 12px; border-radius: 8px; border: 1px solid var(--line-strong); background: var(--bg-elev-2); color: var(--text); font: inherit; }
.quote-form input:focus-visible { outline: 2px solid #a855f7; outline-offset: 1px; }
.quote-form input[aria-invalid="true"] { border-color: rgba(var(--err-rgb), 0.7); }
.items { border: 1px solid var(--line); border-radius: 10px; padding: 6px 16px 10px; margin: 0; display: grid; }
.items legend { padding: 0 6px; }
.item-row { display: grid; grid-template-columns: minmax(0, 1fr) 6.5em; gap: 14px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); }
.item-row:first-of-type { border-top: 0; }
.item-row label { font-size: 0.92rem; }
.item-row label small { display: block; color: var(--muted); font-size: 0.8rem; font-variant-numeric: tabular-nums; }
.item-row input { text-align: right; font-variant-numeric: tabular-nums; }
.quote-total { display: flex; justify-content: space-between; align-items: baseline; padding-top: 4px; }
.quote-total strong { font-size: 1.5rem; font-variant-numeric: tabular-nums; }
.quote-form .btn { justify-self: start; }
/* ライセンス数の変更のページ（/account/quantity/） */
.quote-form input.qty-input { width: 8em; text-align: right; font-variant-numeric: tabular-nums; }
.agree { display: flex; gap: 10px; align-items: flex-start; font-size: 0.92rem; cursor: pointer; }
.quote-form .agree input { width: auto; margin: 0.3em 0 0; accent-color: #a855f7; flex: none; }
.form-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.kv dd.change { color: var(--text); font-weight: 500; }

/* 購入：支払いの周期と席の数を選ぶ欄 */
.buy-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.buy-row select, .buy-row input { padding: 9px 10px; border-radius: 8px; border: 1px solid var(--line-strong); background: var(--bg-elev-2); color: var(--text); font: inherit; font-size: 0.88rem; }
.buy-row select:focus-visible, .buy-row input:focus-visible { outline: 2px solid #a855f7; outline-offset: 1px; }
.buy-row .qty { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); font-size: 0.86rem; }
.buy-row .qty input { width: 4.2em; text-align: right; font-variant-numeric: tabular-nums; }

/* 注文の手続き（/order/）の明細の表 */
.table-wrap { overflow-x: auto; margin-top: 18px; }
.order-lines { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.order-lines th, .order-lines td { padding: 10px 8px; border-top: 1px solid var(--line); text-align: left; vertical-align: top; }
.order-lines th { color: var(--muted); font-weight: 500; font-size: 0.82rem; border-top: 0; }
.order-lines .num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.order-lines tr.total td { font-weight: 700; border-top: 1px solid var(--line-strong); }

/* ユーザーページ：席の割り当て（管理者向け。「席の管理」のタブに契約ごとに並べる） */
.seat-help { margin: 0 0 22px; font-size: 0.82rem; }
.seat-block { display: grid; gap: 4px; }
.seat-qty-link { margin: 2px 0 8px; }
.qty-links { display: flex; flex-wrap: wrap; gap: 8px; }
.qty-steps { display: flex; flex-wrap: wrap; gap: 8px 22px; list-style: none; padding: 0; margin: 22px 0 0; font-size: 0.88rem; color: var(--faint); }
.qty-steps li { display: flex; align-items: center; gap: 8px; }
.qty-steps li span { display: inline-grid; place-items: center; width: 1.7em; height: 1.7em; border-radius: 50%; border: 1px solid var(--line-strong); font-size: 0.8rem; line-height: 1; }
.qty-steps li[aria-current] { color: var(--text); font-weight: 600; }
.qty-steps li[aria-current] span { border-color: transparent; background: var(--grad); color: #fff; }
#h-confirm:focus { outline: none; }
.seat-row .who small.ending { color: var(--warn); }
.qty-ending { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
.qty-pick { display: grid; gap: 8px; }
.qty-pick .pick-title { margin: 0; font-weight: 600; }
.qty-pick .pick-count { margin: 0; font-size: 0.85rem; }
.qty-pick .pick-count.off { color: var(--warn); }
.sub-qty-link { margin-top: 10px; }
.seat-block + .seat-block { margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--line); }
.seat-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 8px; }
.seat-head .name { font-weight: 500; }
.seat-head .meta { color: var(--muted); font-size: 0.85rem; font-variant-numeric: tabular-nums; }
.seat-row { display: grid; grid-template-columns: 4.5em minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 0; border-top: 1px solid var(--line); font-size: 0.92rem; }
.seat-row .slot { color: var(--faint); font-variant-numeric: tabular-nums; }
.seat-row .who { min-width: 0; overflow-wrap: anywhere; }
.seat-row .who small { display: block; color: var(--muted); font-size: 0.8rem; }
.seat-form { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.seat-form input { min-width: 0; width: 15em; max-width: 100%; padding: 7px 12px; border-radius: 8px; border: 1px solid var(--line-strong); background: var(--bg-elev-2); color: var(--text); font: inherit; font-size: 0.86rem; }
.seat-form input:focus-visible { outline: 2px solid #a855f7; outline-offset: 1px; }
@media (max-width: 600px) { .seat-row { grid-template-columns: 1fr; gap: 8px; } .seat-form { justify-content: flex-start; } .seat-form input { width: 100%; } }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; font-size: 0.9rem; }
.kv dt { color: var(--faint); }
.kv dd { margin: 0; }
/* 狭い画面では、見出しの下に値を置く（長い見出しで値の欄が細くならないように） */
@media (max-width: 520px) { .kv { grid-template-columns: 1fr; gap: 2px; } .kv dd + dt { margin-top: 10px; } }
.skeleton { height: 14px; border-radius: 6px; background: linear-gradient(90deg, var(--skel-a), var(--skel-b), var(--skel-a)); background-size: 200% 100%; animation: sk 1.4s infinite; }
@keyframes sk { to { background-position: -200% 0; } }
.signin-box { display: grid; place-items: center; padding: 20px 0; }
details.past summary { cursor: pointer; color: var(--muted); font-size: 0.88rem; }

/* ---------- サポートのページ（動作環境・よくある質問・お問い合わせ） ---------- */
.wrap.narrow { max-width: 880px; }
.card a:not(.btn), .faq a { color: var(--accent-fg); text-underline-offset: 3px; }
.contact-card { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.contact-mail { font-size: clamp(1.2rem, 3vw, 1.5rem); font-weight: 500; letter-spacing: 0.01em; word-break: break-all; }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
@media (max-width: 600px) { .two-col { grid-template-columns: 1fr; gap: 8px; } }
h3.mini { font-size: 0.95rem; font-weight: 500; margin: 0; }
.spec { width: 100%; border-collapse: collapse; font-size: 0.93rem; }
.spec th, .spec td { text-align: left; vertical-align: top; padding: 14px 4px; border-top: 1px solid var(--line); }
.spec tr:first-child th, .spec tr:first-child td { border-top: 0; }
.spec th { width: 32%; padding-right: 20px; color: var(--muted); font-weight: 500; }
.spec td small { display: block; color: var(--faint); font-size: 0.82rem; margin-top: 4px; }
@media (max-width: 600px) {
  .spec th, .spec td { display: block; width: auto; padding: 0; border: 0; }
  .spec th { padding-top: 14px; border-top: 1px solid var(--line); }
  .spec td { padding: 4px 0 14px; }
  .spec tr:first-child th { border-top: 0; padding-top: 0; }
}
.faq-group + .faq-group { margin-top: 44px; }
.faq-group > h2 { font-size: 1.2rem; margin-bottom: 14px; }
.faq { display: grid; gap: 10px; }
.faq details { border: 1px solid var(--line); border-radius: 12px; background: var(--bg-elev); transition: border-color 0.2s; }
.faq details[open] { border-color: var(--line-strong); }
.faq summary { cursor: pointer; list-style: none; padding: 16px 20px; font-weight: 500; display: flex; justify-content: space-between; align-items: baseline; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--muted); font-weight: 400; font-size: 1.2rem; line-height: 1; }
.faq details[open] summary::after { content: "−"; }
.faq summary:focus-visible { outline: 2px solid var(--purple); outline-offset: 2px; border-radius: 12px; }
.faq .a { padding: 0 20px 18px; color: var(--muted); font-size: 0.93rem; }
.faq .a p { margin: 0; }
.faq .a p + p { margin-top: 8px; }

/* ---------- ニュース（tools-news.mjs が news-src/news.json から作る） ---------- */
.news-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.news-list li { border-bottom: 1px solid var(--line); }
.news-list a { display: grid; grid-template-columns: 15em minmax(0, 1fr); gap: 4px 20px; align-items: baseline; padding: 18px 12px; text-decoration: none; transition: background 0.2s; }
.news-list a:hover { background: var(--hover-soft); }
.news-list a:focus-visible { outline: 2px solid var(--purple); outline-offset: -2px; }
.news-title { font-weight: 500; }
.news-meta { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 0.85rem; font-variant-numeric: tabular-nums; }
.news-tag { font-size: 0.72rem; letter-spacing: 0.08em; padding: 0 10px; border-radius: 999px; border: 1px solid var(--line-strong); white-space: nowrap; }
.news-article .news-meta { margin: 0 0 14px; }
.news-article h1 { font-size: clamp(1.5rem, 3.4vw, 2.1rem); }
.news-body { margin-top: 28px; }
.news-body p { margin: 0; }
.news-body p + p { margin-top: 1em; }
.news-body a, .news-back a { color: var(--accent-fg); text-underline-offset: 3px; }
.news-back { margin: 44px 0 0; padding-top: 20px; border-top: 1px solid var(--line); font-size: 0.92rem; }
@media (max-width: 600px) { .news-list a { grid-template-columns: minmax(0, 1fr); padding: 16px 4px; } }

/* ---------- フッター ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 48px 0 56px; color: var(--faint); font-size: 0.84rem; }
.site-footer .wrap { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: start; }
.footer-cols { display: flex; gap: 56px; flex-wrap: wrap; }
.footer-cols nav { display: grid; gap: 8px; align-content: start; }
.footer-cols h4 { margin: 0 0 4px; font-size: 0.76rem; font-weight: 500; letter-spacing: 0.1em; color: var(--faint); }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--text); }
@media (max-width: 700px) { .site-footer .wrap { grid-template-columns: 1fr; } }

/* ---------- 動きを控えたい人向け ---------- */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

/* ---------- Pro のページ：Standard に足す機能の格子と、プランの比較の表 ---------- */
.features .feature .pill { margin-bottom: 2px; }
.feature .check { margin: 2px 0 0; gap: 6px; font-size: 0.9rem; }
.feature .more { font-size: 0.86rem; color: var(--text); }
.feature .more::after { content: " →"; }
.compare { width: 100%; border-collapse: collapse; font-size: 0.93rem; }
.compare th, .compare td { padding: 13px 12px; border-top: 1px solid var(--line); text-align: center; vertical-align: middle; }
.compare thead th { border-top: 0; color: var(--text); font-weight: 500; }
.compare tbody th, .compare thead th:first-child { text-align: left; color: var(--muted); font-weight: 400; }
.compare td small { display: block; color: var(--faint); font-size: 0.78rem; }
.compare .col-pro { background: rgba(168, 85, 247, 0.07); }
.compare thead .col-pro { border-radius: 10px 10px 0 0; }
.compare .yes { color: var(--ok); }
.compare .no { color: var(--faint); }
@media (max-width: 600px) { .compare { font-size: 0.8rem; } .compare th, .compare td { padding: 11px 5px; } .compare td { white-space: nowrap; } .compare td small { font-size: 0.7rem; } }

/* 契約と請求：契約ごとに品目をまとめる（2026-10-28） */
.contract { border: 1px solid var(--line); border-radius: 12px; padding: 18px 20px 4px; background: var(--contract-bg); }
.contract + .contract { margin-top: 14px; }
.contract-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.contract-head .title { font-weight: 600; }
.contract-head .meta { color: var(--muted); font-size: 0.85rem; margin-top: 4px; }
.contract-items .license { grid-template-columns: 36px 1fr auto; align-items: start; padding: 14px 0; }
.contract-items .license:first-of-type { padding-top: 14px; }
.contract-items .license .ico { width: 36px; height: 36px; border-radius: 9px; }
.contract-items .license .ico svg { width: 18px; height: 18px; }
@media (max-width: 600px) { .contract { padding: 14px 14px 2px; } .contract-items .license { grid-template-columns: 1fr; gap: 8px; } .contract-items .license .ico { display: none; } .contract-items .license .badge { grid-column: 1; } }
/* ライセンスと契約：枠の中の品目ごとの割り当てと、契約の解約（2026-10-28） */
.contract-item + .contract-item { border-top: 1px solid var(--line); }
.contract-item > .license { border-top: 0; padding-bottom: 8px; }
.contract-seat-rows { margin: 0 0 12px 52px; }
.contract-seat-rows .msg { margin: 6px 0; }
.contract-foot { display: flex; justify-content: flex-end; padding: 12px 0 14px; border-top: 1px solid var(--line); }
@media (max-width: 600px) { .contract-seat-rows { margin-left: 0; } .contract-foot { justify-content: flex-start; } }
/* トップページの「法人のお客様へ」の帯（2026-10-28） */
.hero-corp { margin-top: 12px; }
.hero-corp strong { color: var(--text); margin-right: 10px; }
/* 購入の手続き（/buy/。2026-10-28） */
.buy-choices { border: 0; margin: 0; padding: 0; min-width: 0; }
.buy-choices legend { padding: 0; margin-bottom: 6px; }
.field-label { font-size: 0.9rem; font-weight: 500; color: var(--muted); }
.choice-list { display: grid; gap: 8px; }
.choice { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--line-strong); border-radius: 10px; cursor: pointer; background: var(--bg-elev-2); }
.choice:has(input:checked) { border-color: #a855f7; background: rgba(168, 85, 247, 0.08); }
.quote-form .choice input { width: auto; margin: 0; accent-color: #a855f7; flex: none; }
.choice .choice-name { font-weight: 500; }
.choice .choice-price { margin-left: auto; color: var(--muted); font-variant-numeric: tabular-nums; }
.buy-qty { display: flex; align-items: center; gap: 8px; color: var(--muted); }
.quote-form .btn.btn-wide { justify-self: stretch; }
#buy-total { font-size: 1.15rem; font-weight: 600; font-variant-numeric: tabular-nums; }

/* ---------- ダーク・ライトの切り替え（assets/theme.js）。2026-11-04 ---------- */
.theme-toggle {
  display: inline-grid; place-items: center; flex: none; width: 34px; height: 34px; padding: 0;
  border-radius: 50%; border: 1px solid transparent; background: none; color: var(--muted); cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}
.theme-toggle:hover { color: var(--text); border-color: var(--line-strong); }
.theme-toggle:focus-visible { outline: 2px solid var(--purple); outline-offset: 2px; }
.theme-toggle svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.theme-toggle .when-light { display: none; }
:root[data-theme="light"] .theme-toggle .when-dark { display: none; }
:root[data-theme="light"] .theme-toggle .when-light { display: block; }
/* 明暗で違う絵（暗い下地用の絵は、白い下地では黒い塊に見えるため、-light.svg を別に持つ） */
.for-light { display: none !important; }
:root[data-theme="light"] .for-light { display: block !important; }
:root[data-theme="light"] .for-dark { display: none !important; }
/* 白いカードを淡い影で浮かせる（アプリと同じ）。ダークでは影なし */
.card, .price-card, .product, .ai-case, .frame, .faq details { box-shadow: var(--card-shadow); }

/* ---------- 管理者用のダッシュボード（admin/。assets/admin.js。スマホの幅を先に考える） ---------- */
.adm-head { position: sticky; top: 0; z-index: 10; background: var(--header-bg); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.adm-head .wrap { display: flex; align-items: center; gap: 12px; height: 58px; }
.adm-head .brand span { font-size: 1.1rem; }
.adm-head h1 { font-size: 0.95rem; font-weight: 500; color: var(--muted); letter-spacing: 0.04em; white-space: nowrap; }
@media (max-width: 420px) { .adm-head .brand span { display: none; } .adm-head .wrap { gap: 10px; } }
.adm-head .spacer { flex: 1; }
.adm-main { padding: 20px 0 64px; }
.adm-main .msg { margin: 0 0 16px; }
.adm-main .msg code { font-size: 0.85rem; word-break: break-all; }
.adm-signin { display: flex; justify-content: center; padding: 24px 0; }
.adm-signin:empty { display: none; }
.adm-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin: 0 0 18px; }
.adm-range { display: inline-flex; border: 1px solid var(--line-strong); border-radius: 999px; padding: 3px; }
.adm-range button { border: 0; background: transparent; color: var(--muted); font: inherit; font-size: 0.85rem; padding: 6px 14px; border-radius: 999px; cursor: pointer; }
.adm-range button[aria-pressed="true"] { background: var(--accent-subtle); color: var(--text); font-weight: 500; }
.adm-range button:focus-visible, .adm-icon-btn:focus-visible { outline: 2px solid var(--purple); outline-offset: 2px; }
.adm-icon-btn { border: 1px solid var(--line-strong); background: transparent; color: var(--muted); font: inherit; font-size: 0.82rem; padding: 6px 14px; border-radius: 999px; cursor: pointer; white-space: nowrap; }
.adm-icon-btn:hover { color: var(--text); background: var(--hover-soft); }
.adm-icon-btn[disabled] { opacity: 0.5; cursor: progress; }
.adm-updated { color: var(--faint); font-size: 0.78rem; font-variant-numeric: tabular-nums; }
.adm-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 0 0 14px; }
.adm-tile, .adm-card { background: var(--bg-elev); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--card-shadow); }
.adm-tile { padding: 14px 16px; min-width: 0; }
.adm-tile .label { color: var(--muted); font-size: 0.8rem; }
.adm-tile .value { font-size: 1.75rem; font-weight: 500; line-height: 1.3; margin-top: 2px; font-variant-numeric: tabular-nums; }
.adm-tile .delta { color: var(--muted); font-size: 0.76rem; font-variant-numeric: tabular-nums; min-height: 1.2em; }
.adm-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.adm-grid .wide { grid-column: 1 / -1; }
@media (max-width: 760px) { .adm-grid { grid-template-columns: minmax(0, 1fr); } }
.adm-card { padding: 16px 18px; min-width: 0; }
.adm-card h2 { font-size: 0.95rem; font-weight: 500; margin: 0 0 2px; }
.adm-card .sub { color: var(--faint); font-size: 0.76rem; margin: 0 0 10px; }
.adm-chart { position: relative; }
.adm-chart svg { display: block; width: 100%; height: 170px; overflow: visible; }
.adm-chart .grid { stroke: var(--line); stroke-width: 1; }
.adm-chart .tick { fill: var(--faint); font-size: 10px; font-variant-numeric: tabular-nums; }
.adm-chart .bar { fill: var(--chart-bar); }
.adm-chart .bar.dim { opacity: 0.35; }
.adm-chart .hit { fill: transparent; cursor: default; }
.adm-tip { position: absolute; pointer-events: none; transform: translate(-50%, -100%); background: var(--bg-elev-2); border: 1px solid var(--line-strong); border-radius: 8px; padding: 6px 10px; font-size: 0.78rem; white-space: nowrap; box-shadow: var(--shadow-pop); font-variant-numeric: tabular-nums; }
.adm-tip b { font-weight: 500; }
.adm-card details { margin-top: 8px; font-size: 0.8rem; color: var(--muted); }
.adm-card details summary { cursor: pointer; }
.adm-table { width: 100%; border-collapse: collapse; font-size: 0.84rem; }
.adm-table th, .adm-table td { padding: 7px 4px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.adm-table th { color: var(--muted); font-weight: 400; font-size: 0.76rem; }
.adm-table td.num, .adm-table th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; padding-left: 12px; }
.adm-table td.key { word-break: break-all; }
.adm-table tr:last-child td { border-bottom: 0; }
.adm-empty { color: var(--faint); font-size: 0.84rem; padding: 6px 0; }
.adm-note { color: var(--faint); font-size: 0.76rem; margin: 18px 0 0; line-height: 1.7; }
.adm-skel { height: 1.75rem; border-radius: 6px; background: var(--skel-a); }

/* ---------- トップページ（AI が 3D モデルを作る。2026-11-08）---------- */
/* 最初の画面の動く図（会話と Morpha の画面）は assets/home.js が段階ごとに .on を付けて動かす。
   AI ができることのカードには、いずれ実際の動作の動画を .pill の前に .ai-video で入れる（音なし・繰り返し・playsinline） */
.mcp-hero { padding: 64px 0 24px; text-align: center; }
.mcp-hero h1 { margin-top: 14px; font-size: clamp(2rem, 4.4vw, 3.1rem); line-height: 1.3; }
.mcp-hero .lead { margin: 18px auto 0; max-width: 40em; }
.mcp-hero .hero-actions { margin-top: 28px; }

/* 会話（AI アプリ）と Morpha の画面を並べた図 */
.mcp-stage { margin-top: 48px; display: grid; grid-template-columns: minmax(0, 340px) minmax(0, 1fr); gap: 16px; text-align: left; }
.mcp-stage > * { position: relative; z-index: 1; min-width: 0; }
@media (max-width: 900px) { .mcp-stage { grid-template-columns: minmax(0, 1fr); } }
.mcp-caption { margin: 14px 0 0; font-size: 0.78rem; color: var(--faint); text-align: center; }

.mcp-chat { display: flex; flex-direction: column; border: 1px solid var(--line-strong); border-radius: 12px; background: var(--bg-elev); overflow: hidden; font-size: 0.86rem; line-height: 1.65; letter-spacing: 0.01em; }
.mcp-chat-head { display: flex; align-items: center; gap: 8px; height: 34px; padding: 0 14px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 0.76rem; }
.mcp-chat-head::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--purple); }
.mcp-chat-head span { margin-left: auto; color: var(--faint); }
.mcp-chat-body { flex: 1; display: flex; flex-direction: column; gap: 10px; padding: 14px; }
.mcp-user { align-self: flex-end; max-width: 92%; margin: 0; padding: 10px 12px; border-radius: 12px 12px 4px 12px; background: var(--accent-subtle); color: var(--text); }
.mcp-ai { margin: 0; color: var(--text-soft); }
.mcp-tool { display: grid; grid-template-columns: auto 1fr; column-gap: 8px; align-items: baseline; padding: 6px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg-elev-2); font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 0.74rem; line-height: 1.5; }
.mcp-tool::before { content: "✓"; color: var(--ok); font-family: var(--sans); }
.mcp-tool b { font-weight: 500; color: var(--text); overflow-wrap: anywhere; }
.mcp-tool i { grid-column: 2; font-style: normal; color: var(--muted); overflow-wrap: anywhere; }
.mcp-thumb { grid-column: 2; margin-top: 6px; width: 96px; border-radius: 6px; background: linear-gradient(180deg, #fbfbfd, #e9e9f0); border: 1px solid var(--line); }
.mcp-chat-input { margin: 0 14px 14px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 10px; color: var(--faint); font-size: 0.8rem; }

.mcp-stage .app-shot { display: flex; flex-direction: column; }
.mcp-stage .app-body { flex: 1; grid-template-columns: 170px 1fr 180px; min-height: 380px; }
.mcp-view svg { width: 82%; max-width: 560px; }
/* スマホでは、形ができていく Morpha の画面を先に見せ、会話をその下に置く */
@media (max-width: 900px) { .mcp-stage .app-shot { order: -1; } .mcp-chat-input { display: none; } }
.mcp-props { display: grid; }
.mcp-props > dl { grid-area: 1 / 1; align-self: start; }
@media (max-width: 860px) { .mcp-stage .app-body { grid-template-columns: 1fr; } .mcp-stage .viewport { min-height: 240px; } }

/* 動き：JS が .anim を付けたときだけ、まだの段階の物を隠す（JS が無い・動きを減らす設定なら、できあがりを見せる） */
.mcp-stage [data-at] { transition: opacity 0.35s ease, transform 0.35s ease; }
.mcp-stage.anim [data-at]:not(.on) { opacity: 0; transform: translateY(6px); }
.mcp-stage.anim svg [data-at]:not(.on) { transform: none; }
.mcp-stage:not(.anim) [data-until] { display: none; }
.mcp-stage.anim .tree li[data-at]:not(.on) { display: none; }

/* できることのカード（6枚） */
.mcp-cases { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 900px) { .mcp-cases { grid-template-columns: minmax(0, 1fr); } }
.ai-case .ai-video { width: 100%; aspect-ratio: 16 / 9; border-radius: 10px; border: 1px solid var(--line); background: var(--bg-elev-2); object-fit: cover; }
.mcp-cases .ai-do code, .mcp-steps code { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 0.85em; color: var(--text-soft); overflow-wrap: anywhere; }

/* データの流れの図 */
.mcp-flow { display: grid; grid-template-columns: minmax(0, 1.5fr) auto minmax(0, 1fr); gap: 14px; align-items: center; }
@media (max-width: 760px) { .mcp-flow { grid-template-columns: minmax(0, 1fr); } }
.mcp-pc { border: 1px dashed var(--line-strong); border-radius: var(--radius); padding: 18px; display: grid; gap: 10px; }
.mcp-pc > .cap, .mcp-cloud > .cap { font-size: 0.76rem; letter-spacing: 0.06em; color: var(--faint); }
.mcp-node { border: 1px solid var(--line-strong); border-radius: 10px; background: var(--bg-elev); padding: 12px 14px; display: grid; gap: 2px; }
.mcp-node strong { font-weight: 500; }
.mcp-node small { color: var(--muted); font-size: 0.8rem; line-height: 1.6; }
.mcp-link { text-align: center; color: var(--muted); font-size: 0.8rem; }
.mcp-out { color: var(--muted); font-size: 0.8rem; text-align: center; max-width: 12em; justify-self: center; line-height: 1.6; }
.mcp-out::before { content: "→"; display: block; font-size: 1.3rem; color: var(--faint); }
@media (max-width: 760px) { .mcp-out::before { content: "↓"; } .mcp-out { max-width: none; } }
.mcp-cloud { border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; display: grid; gap: 10px; }
/* 外へ出る矢印は、PC の枠の真ん中ではなく AI アプリの高さから出す（送るのは AI アプリなので） */
@media (min-width: 761px) { .mcp-out, .mcp-cloud { align-self: end; } .mcp-out { margin-bottom: 34px; } }
.mcp-notes { margin-top: 28px; }

/* つなぎ方 */
.mcp-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; counter-reset: step; }
@media (max-width: 900px) { .mcp-steps { grid-template-columns: minmax(0, 1fr); } }
.mcp-steps li { border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-elev); padding: 22px 24px; display: grid; gap: 8px; align-content: start; counter-increment: step; box-shadow: var(--card-shadow); }
.mcp-steps li::before { content: counter(step); font-size: 0.85rem; font-weight: 500; color: var(--faint); font-variant-numeric: tabular-nums; }
.mcp-steps h3 { font-size: 1.02rem; }
.mcp-steps p { margin: 0; color: var(--muted); font-size: 0.92rem; }
.mcp-code { margin: 20px 0 0; padding: 16px 18px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg-elev-2); overflow-x: auto; font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 0.8rem; line-height: 1.7; color: var(--text-soft); letter-spacing: 0; }
.mcp-small { margin: 14px 0 0; color: var(--muted); font-size: 0.88rem; }
/* つなぎ方の2つの方法（かんたんな方法と、場所を登録する方法） */
.mcp-ways { margin-top: 20px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
@media (max-width: 900px) { .mcp-ways { grid-template-columns: minmax(0, 1fr); } }
.mcp-way { min-width: 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-elev); padding: 22px 24px; display: grid; gap: 10px; align-content: start; justify-items: start; box-shadow: var(--card-shadow); }
.mcp-way h3 { font-size: 1.02rem; }
.mcp-way p { margin: 0; color: var(--muted); font-size: 0.92rem; }
.mcp-way p code { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 0.85em; color: var(--text-soft); overflow-wrap: anywhere; }
.mcp-way .mcp-code { margin: 2px 0; justify-self: stretch; }
.mcp-code code { font-family: inherit; }
.mcp-small a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.plans-section .plans-hero { margin-top: 0; }

/* 文の折り返し（2026-11-08）：トップページと Morpha Agent のページの文は、語の途中ではなく文節の切れ目で折り返す（word-break: auto-phrase。
   Chrome・Edge が対応。ほかのブラウザでは今までどおり）。最後の行に1〜2文字だけ残らないよう text-wrap: pretty、見出しは balance。
   節の説明文（.lead）は、PC で1文が1行に収まる幅にする */
:is(body[data-page="home"], body[data-page="agent"], body[data-page="cad"], body[data-page="beta"]) main { word-break: auto-phrase; overflow-wrap: break-word; }
:is(body[data-page="home"], body[data-page="agent"], body[data-page="cad"], body[data-page="beta"]) main p, :is(body[data-page="home"], body[data-page="agent"], body[data-page="cad"], body[data-page="beta"]) main li { text-wrap: pretty; }
:is(body[data-page="home"], body[data-page="agent"], body[data-page="cad"], body[data-page="beta"]) main h1, :is(body[data-page="home"], body[data-page="agent"], body[data-page="cad"], body[data-page="beta"]) main h2, :is(body[data-page="home"], body[data-page="agent"], body[data-page="cad"], body[data-page="beta"]) main h3 { text-wrap: balance; }
:is(body[data-page="home"], body[data-page="agent"], body[data-page="cad"], body[data-page="beta"]) .section-head .lead { max-width: 58em; }
/* 英字の語と、後ろの助詞の間で切れないようにする所（.nw）。1文ずつ折り返したい説明文は、文を .sent で包む（PC の幅だけ。1文が1行に入らなければ、その中で折り返す） */
:is(body[data-page="home"], body[data-page="agent"], body[data-page="cad"], body[data-page="beta"]) .nw { white-space: nowrap; }
@media (min-width: 901px) { :is(body[data-page="home"], body[data-page="agent"], body[data-page="cad"], body[data-page="beta"]) .sent { display: inline-block; } }

/* 押せるプランのカード（トップページ。2026-11-08）：カードのどこを押しても、プランの名前のリンク（.card-link）の行き先へ。
   中のボタン（試用・購入・ダウンロード）は、カードのリンクより上に置いて、それぞれの働きのまま押せるようにする */
.price-card.is-link { position: relative; transition: border-color 0.2s ease, transform 0.2s ease; }
.price-card.is-link:hover { border-color: rgba(168, 85, 247, 0.45); transform: translateY(-3px); }
.price-card .card-link { text-decoration: none; }
.price-card .card-link::after { content: ""; position: absolute; inset: 0; border-radius: inherit; z-index: 1; }
.price-card .card-link:focus-visible { outline: none; }
.price-card.is-link:has(.card-link:focus-visible) { outline: 2px solid var(--purple); outline-offset: 2px; }
.price-card.is-link .plan-actions { position: relative; z-index: 2; pointer-events: none; }
.price-card.is-link .plan-actions > .btn, .price-card.is-link .plan-actions > .msg { pointer-events: auto; }

/* ---------- お知らせのメールの登録（Beta 版のページの [data-newsletter]。2026-11-15） ---------- */
.notify-card { display: grid; gap: 14px; }
.notify-consent { display: flex; gap: 10px; align-items: flex-start; font-size: 0.92rem; cursor: pointer; }
.notify-consent input { flex: none; width: 17px; height: 17px; margin: 0.25em 0 0; accent-color: var(--purple); }
.notify-state { margin: 0; font-size: 0.9rem; overflow-wrap: anywhere; }
.notify-note { margin: 0; font-size: 0.8rem; }
