/* frontend-design 版の共通 CSS。計画は plan.md */
:root {
  --paper: #FFFFFF; --surface: #F0F1F2; --fv-ground: #FBFBFD; --ink: #1E2328; --ink-2: #5B6570; --rule: #D5D9DD; --structure: #37434F; --accent: #315DC6; --on-accent: #FFFFFF; --on-dark: #F4F6F8; --on-dark-2: #B9C2CB; --rule-dark: #55626F;
  --f-head: "Kozuka Gothic Pr6N", "kozuka-gothic-pr6n", "IBM Plex Sans JP", sans-serif;
  --f-body: "Inter", "IBM Plex Sans JP", "Hiragino Sans", sans-serif;
  --w: 1200px;
  --t-xxl: clamp(40px, 6.4vw, 96px);
  --t-xl: clamp(28px, 3.2vw, 44px);
  --t-l: 22px;
  --t-m: 16px;
  --t-s: 13px;
}
*, *::before, *::after { box-sizing: border-box; }
html, body { overflow-x: clip; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--f-body); font-size: var(--t-m); line-height: 1.85; font-feature-settings: "palt"; }
body { word-break: auto-phrase; } /* 文節で改行し、語の途中で切らない（2026-11-26 画面確認で「狙／う」「見／込み客」等）。長い英数字は overflow-wrap で折る */
body { overflow-wrap: break-word; } /* はみ出すときだけ折る（anywhere は媒体名など短い語まで途中で折った。2026-11-26） */
a { color: inherit; text-underline-offset: 5px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.w { max-width: var(--w); margin: 0 auto; padding-inline: max(24px, env(safe-area-inset-left)); }
h1, h2, h3, h4 { font-family: var(--f-head); font-weight: 700; margin: 0; text-wrap: balance; }

.hdr .w { display: flex; align-items: center; gap: 28px; min-height: 68px; background: linear-gradient(var(--structure), var(--structure)) no-repeat center bottom / calc(100% - 2 * max(24px, env(safe-area-inset-left))) 2px; } /* 線を本文の左右の端にそろえる（2026-11-26） */
.mark { font-weight: 500; font-size: 18px; text-decoration: none; margin-right: auto; white-space: nowrap; }
.nav { display: flex; gap: 24px; font-size: 14px; }
.nav a { text-decoration: none; }
.nav a:hover, .nav a[aria-current] { text-decoration: underline; }
.btn { display: inline-flex; align-items: center; white-space: nowrap; min-height: 48px; padding: 0 24px; font-size: 15px; font-weight: 700; text-decoration: none; border: 1px solid var(--structure); color: var(--structure); background: var(--paper); }
.btn:hover { background: var(--surface); }
.btn:active { transform: translateY(1px); }
.more:active { opacity: .7; }
.btn--primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn--primary:hover { background: var(--structure); border-color: var(--structure); }
.btn--sm { min-height: 44px; padding: 0 16px; font-size: 14px; }
.more { font-size: 14px; font-weight: 700; }
.note { font-size: var(--t-s); color: var(--ink-2); }
.slot { border: 1px dashed var(--rule); display: grid; place-items: center; text-align: center; font-size: var(--t-s); color: var(--ink-2); padding: 24px; }

/* a section opens on a heavy rule; the head sits left in three columns, the content takes the other nine */
.part { padding: 0 0 120px; }
.part .w { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 40px; }
.part__head { grid-column: 1 / 4; border-top: 2px solid var(--structure); padding-top: 20px; }
.part__head h2 { font-size: 28px; line-height: 1.35; margin-bottom: 16px; }
.part__head p { font-size: 14px; color: var(--ink-2); margin: 0; }
.part__body { grid-column: 4 / 13; border-top: 1px solid var(--rule); padding-top: 20px; min-width: 0; }

@media (max-width: 900px) {
  .nav, .hdr .btn:not(.btn--primary) { display: none; }
  .part .w { display: block; }
  .part__body { border-top: 0; }
  .part { padding-bottom: 72px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* スマホ・タブレットのメニュー（1180px 以下。WACUL と同じ全画面の形。2026-11-24） */
.menu-btn { display: none; flex: none; width: 48px; height: 48px; margin-left: -12px; padding: 0; border: 0; background: none; color: var(--structure); cursor: pointer; flex-direction: column; justify-content: center; align-items: center; gap: 6px; }
.menu-btn span { display: block; width: 24px; height: 2px; background: currentColor; }
.spmenu { position: fixed; inset: 0; z-index: 100; background: var(--paper); overflow-y: auto; padding: 72px 24px 40px; }
.spmenu[hidden] { display: none; }
.spmenu__close { position: absolute; top: 10px; right: 12px; width: 48px; height: 48px; border: 0; background: none; cursor: pointer; color: var(--structure); }
.spmenu__close::before, .spmenu__close::after { content: ""; position: absolute; left: 12px; top: 23px; width: 24px; height: 2px; background: currentColor; transform: rotate(45deg); }
.spmenu__close::after { transform: rotate(-45deg); }
.spmenu__nav { display: flex; flex-direction: column; max-width: 640px; margin: 0 auto; border-top: 2px solid var(--structure); }
.spmenu__nav a { font-family: var(--f-head); font-weight: 700; font-size: 20px; line-height: 1.5; padding: 18px 0; border-bottom: 1px solid var(--rule); text-decoration: none; }
.spmenu__nav a:hover { color: var(--accent); }
.spmenu__acts { display: grid; gap: 12px; max-width: 640px; margin: 40px auto 0; }
.hdr .spmenu__acts .btn.btn { display: flex; justify-content: center; min-height: 56px; padding: 0 24px; font-size: 15px; }
html.menu-open { overflow: hidden; }
@media (max-width: 1180px) { .menu-btn { display: flex; } .hdr .w { gap: 16px; } }

/* ===== 共通ヘッダー・フッター（2026-11-29 原田さん「A」: TOP統合版の Codex案のヘッダー・フッターを全ページに。正本は top_integrated_20261129/migrate_header_footer.py） ===== */
:root { --ease: cubic-bezier(0.4, 0.4, 0, 1); }
.ib { display: inline-block; }
/* 矢印: Codex案と同じ Inter（全文字版）から矢印だけを切り出した書体。ホバーで右向きに回す */
@font-face { font-family: "WDArrow"; src: url(../img/fonts/wd-arrows.woff) format("woff"); font-weight: 100 900; font-display: block; unicode-range: U+2190-2199; }
.ar { font-family: "WDArrow", "Inter", sans-serif; font-style: normal; font-weight: 400; font-size: 18px; line-height: 1; display: inline-block; transition: transform .35s var(--ease); }
a:hover .ar, a:focus-visible .ar { transform: rotate(45deg); }
.mast { position: relative; z-index: 20; background: var(--paper); }
.mast__bar { display: flex; align-items: center; gap: 30px; min-height: 88px; border-bottom: 1px solid var(--ink); }
.mast .brand { display: inline-block; flex: none; margin-right: auto; padding-block: 10px; }
.mast .brand img { display: block; width: 175px; height: auto; }
.mast__nav { display: flex; gap: clamp(18px, 2vw, 34px); align-items: center; font-family: var(--f-head); font-weight: 700; font-size: 14px; }
.mast__nav a { text-decoration: none; white-space: nowrap; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .3s var(--ease); padding-bottom: 2px; }
.mast__nav a:hover, .mast__nav a[aria-current] { background-size: 100% 1px; }
.head-act { display: flex; gap: 10px; }
.head-act .btn { min-height: 44px; padding: 0 14px; font-size: 14px; min-width: 163px; justify-content: space-between; gap: 16px; }
.head-act .btn .ar { font-size: 16px; }
.menu-button { display: none; flex: none; width: 44px; height: 44px; padding: 10px; border: 0; background: transparent; cursor: pointer; align-content: center; gap: 6px; }
.menu-button span { display: block; height: 2px; width: 24px; background: var(--ink); transition: transform .3s var(--ease); }
.menu-button[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
.menu-button[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }
.mobile-nav, .mobile-nav[hidden] { display: none; }
.mobile-nav .ar { font-size: 15px; }
@media (max-width: 1180px) {
  .mast__bar { min-height: 68px; gap: 18px; }
  .mast__nav { display: none; }
  .menu-button { display: grid; }
  .mobile-nav:not([hidden]) { position: absolute; display: grid; right: max(24px, env(safe-area-inset-right)); top: 100%; width: min(360px, calc(100% - 48px)); padding: 10px 20px; background: var(--paper); border: 1px solid var(--ink); }
  .mobile-nav a { display: flex; justify-content: space-between; align-items: center; min-height: 48px; padding: 6px 0; border-bottom: 1px solid var(--rule); font-family: var(--f-head); font-weight: 700; font-size: 15px; text-decoration: none; }
  .mobile-nav a:last-child { border-bottom: 0; }
}
@media (max-width: 760px) {
  .mast__bar { min-height: 63px; gap: 8px; }
  .mast .brand img { width: 123px; }
  .head-act .btn:not(.btn--primary) { display: none; }
  .head-act .btn { min-width: 0; min-height: 40px; padding: 0 14px; font-size: 13px; gap: 10px; }
  .head-act .btn .ar { font-size: 13px; }
  .mobile-nav:not([hidden]) { left: 24px; right: 24px; width: auto; }
}
@media (max-width: 360px) { .head-act .btn .ar { display: none; } .head-act .btn { padding: 0 10px; } }
.site-foot { padding-top: 56px; } /* 下層の共通CSS（site.css）の .foot（別の部品）とぶつからない名前 */
.foot-grid { display: grid; grid-template-columns: 1.1fr 1fr .64fr .64fr; gap: 38px; }
.foot-grid .brand { display: inline-block; padding-block: 10px; }
.foot-grid .brand img { display: block; width: 154px; height: auto; }
.foot-grid p { margin: 14px 0 0; max-width: 22em; font-size: 12px; line-height: 1.8; color: var(--ink-2); }
.foot-grid nav { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; }
.foot-grid nav a { font-size: 12px; text-decoration: none; padding-block: 4px; }
.foot-grid nav a:hover { text-decoration: underline; }
.foot-grid nav .top { font-family: var(--f-head); font-weight: 700; font-size: 13px; margin-bottom: 4px; }
.foot-bottom { display: flex; align-items: center; gap: 28px; margin-top: 40px; padding: 18px 0; border-top: 1px solid var(--rule); font-size: 12px; color: var(--ink-2); }
.foot-bottom small { font-size: 12px; margin-right: auto; }
.foot-bottom a { text-decoration: none; padding-block: 6px; }
.foot-bottom a:hover { text-decoration: underline; }
@media (max-width: 900px) {
  .site-foot { padding-top: 36px; }
  .foot-grid { grid-template-columns: 1fr 1fr; gap: 24px 17px; }
  .foot-grid > div:first-child { grid-column: 1 / -1; }
  .foot-grid nav:nth-child(2) { grid-row: 2 / 4; }
  .foot-grid p { max-width: none; }
  .foot-bottom { flex-wrap: wrap; gap: 8px 18px; margin-top: 28px; }
  .foot-bottom small { flex: 1 0 100%; order: 3; }
}
/* ===== 共通ヘッダー・フッター ここまで ===== */
