/* =========================================================
   MomentumMarketing コーポレートHP 仮組 (リッチ版)
   配色・書体はブランド (ロゴ実測値) 由来:
     深緑 #0B2F21 / クリーム #FDFBE6 / オフホワイト #FAF9F4
   モーション方針:
     - ごちゃつかせず手数を見せる。同時に動くのは1グループまで
     - ヒーローは読み込み時のシーケンス演出 (一度きり)
     - スクロール登場は要素グループ単位のスタガー (一度きり)
     - ホバー0.22s / 登場0.6s / 線画1.2s に統一
     - prefers-reduced-motion で全停止
   ========================================================= */

:root {
  --green: #0B2F21;
  --green-hover: #123E2C;
  --green-soft: #47604F;
  --ink: #182A20;
  --cream: #FDFBE6;
  --paper: #FAF9F4;
  --tint: #F1F0E6;
  --line: #DCDFD2;
  --line-on-dark: #2C4A3B;
  --accent: #D9A441;
  --header-h: 86px; /* JSが実測で上書き */
  --t: 0.22s ease-out;
  --font-head: "Zen Kaku Gothic New", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  --font-body: "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Yu Gothic Medium", "Yu Gothic", Meiryo, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.85;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; }
a { color: inherit; text-decoration: none; }

.container { width: min(1120px, 100% - 48px); margin-inline: auto; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  clip-path: inset(50%); overflow: hidden; white-space: nowrap;
}

.skip-link {
  position: absolute; left: 8px; top: -48px;
  background: var(--green); color: var(--cream);
  padding: 8px 16px; z-index: 100; transition: top var(--t);
}
.skip-link:focus { top: 8px; }

:focus-visible { outline: 3px solid var(--green); outline-offset: 2px; }

/* ---------- 共通部品 ---------- */

.eyebrow {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.8125rem;
  letter-spacing: 0.3em;
  color: var(--green-soft);
  margin-bottom: 10px;
}
.eyebrow-on-dark { color: color-mix(in srgb, var(--cream) 65%, var(--green)); }

.section { padding: 104px 0; position: relative; }
.section-tint { background: var(--tint); }

.section-head { margin-bottom: 56px; }

.section-title {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: clamp(2rem, 3.6vw, 2.75rem);
  line-height: 1.3;
  color: var(--green);
  position: relative;
  padding-bottom: 18px;
  margin-bottom: 14px;
}
/* 見出し下: ロゴ矢印の引用 (右肩上がりの跳ね) */
.section-title::after {
  content: "";
  position: absolute; left: 0; bottom: 0;
  width: 56px; height: 14px;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 56 14'%3E%3Cpath d='M0 12.5H42L54 2' fill='none' stroke='%23000' stroke-width='3'/%3E%3C/svg%3E") no-repeat left center / contain;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 56 14'%3E%3Cpath d='M0 12.5H42L54 2' fill='none' stroke='%23000' stroke-width='3'/%3E%3C/svg%3E") no-repeat left center / contain;
}

.section-sub { color: var(--green-soft); font-size: 0.9688rem; }

/* ナイル流: 宣言+数値の統合ブロック用の宣言文 */
.section-statement {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(1.25rem, 2.2vw, 1.625rem);
  line-height: 1.6;
  margin: 10px 0 8px;
}

/* サイバー・バズ流: 背景の巨大英字タイポ (色を増やさず面積で密度を出す)。
   ::before はジグザグ縁取り (.section-dark) と衝突するため ::after を使う */
.section[data-wm] { position: relative; isolation: isolate; overflow: hidden; }
.section[data-wm]::after {
  content: attr(data-wm);
  position: absolute;
  top: 28px; right: 12px;
  z-index: -1;
  font-family: var(--font-head);
  font-weight: 900;
  font-size: clamp(72px, 11vw, 150px);
  line-height: 1;
  letter-spacing: 0.04em;
  color: var(--green);
  opacity: 0.05;
  pointer-events: none;
  white-space: nowrap;
}
.section-dark[data-wm]::after { color: var(--cream); opacity: 0.07; }

.note { font-size: 0.8125rem; color: var(--green-soft); margin-top: 28px; }

.tbd {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.6875rem;
  line-height: 1;
  color: var(--green-soft);
  border: 1px dashed var(--green-soft);
  border-radius: 3px;
  padding: 3px 6px;
  margin-left: 8px;
  vertical-align: 0.2em;
  white-space: nowrap;
}
.tbd-on-dark { color: var(--cream); border-color: var(--cream); opacity: 0.75; }

/* ---------- ボタン ---------- */

.btn {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.9375rem;
  padding: 14px 32px;
  border: 2px solid var(--green);
  cursor: pointer;
  transition: background-color var(--t), color var(--t), border-color var(--t), box-shadow var(--t);
}
.btn-primary { background: var(--green); color: var(--cream); }
.btn-primary:hover { background: var(--green-hover); border-color: var(--green-hover); box-shadow: 0 6px 18px rgba(11,47,33,0.25); }
.btn-ghost { background: transparent; color: var(--green); }
.btn-ghost:hover { background: var(--green); color: var(--cream); }

/* ---------- ヘッダー ---------- */

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  width: min(1240px, 100% - 32px);
  margin-inline: auto;
  display: flex; align-items: center; gap: 32px;
  padding: 10px 0;
}
.brand img { width: 132px; height: auto; }
.global-nav { margin-left: auto; }
.global-nav ul { display: flex; gap: 4px; }
.global-nav a {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 10px 12px;
  border-bottom: 2px solid transparent;
  transition: color var(--t), border-color var(--t);
}
.global-nav a:hover { color: var(--green); border-bottom-color: var(--green); }
.header-cta { padding: 10px 22px; font-size: 0.875rem; }

.nav-toggle {
  display: none;
  width: 44px; height: 44px;
  background: none; border: none; cursor: pointer;
  position: relative;
}
.nav-toggle-bar,
.nav-toggle-bar::before,
.nav-toggle-bar::after {
  content: "";
  position: absolute; left: 10px;
  width: 24px; height: 2px;
  background: var(--green);
  transition: transform var(--t), opacity var(--t);
}
.nav-toggle-bar { top: 21px; }
.nav-toggle-bar::before { left: 0; top: -7px; }
.nav-toggle-bar::after { left: 0; top: 7px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar { transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar::before { transform: rotate(-90deg) translateX(-7px); top: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar::after { opacity: 0; }

/* ---------- MV: 全画面の深緑ブロック + 写真パネル ---------- */

.hero {
  position: relative;
  min-height: calc(100svh - var(--header-h));
  background: var(--green);
  color: var(--cream);
  overflow: hidden;
  display: flex;
}
.hero-inner { flex: 1; display: flex; }
.hero-copy {
  position: relative; z-index: 2;
  /* 幅はコンテンツ基準 (左パディングを含めない)。広い画面でタイトルが折れないようにする */
  box-sizing: content-box;
  width: min(720px, calc(100vw - max(24px, (100vw - 1160px) / 2) - 24px));
  padding: clamp(48px, 8vh, 96px) 24px clamp(120px, 16vh, 160px) max(24px, calc((100vw - 1160px) / 2));
  display: flex; flex-direction: column; justify-content: center;
}
.hero .eyebrow { color: color-mix(in srgb, var(--cream) 70%, var(--green)); }

.hero-title {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: min(clamp(3.25rem, 7.2vw, 6.25rem), 11.5vh);
  line-height: 1.12;
  letter-spacing: 0.02em;
  color: var(--cream);
}
/* 行ごとのマスク出現 */
.hero-title-line { display: block; overflow: hidden; padding-bottom: 0.08em; white-space: nowrap; }
.line-in {
  display: inline-block;
  transform: translateY(110%);
  animation: line-up 0.8s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
  animation-delay: calc(var(--seq) * 0.12s);
}
@keyframes line-up { to { transform: none; } }
.outline { color: transparent; -webkit-text-stroke: 2px var(--cream); }

.hero-seq {
  opacity: 0;
  transform: translateY(18px);
  animation: seq-up 0.6s ease-out forwards;
  animation-delay: calc(var(--seq) * 0.12s + 0.2s);
}
@keyframes seq-up { to { opacity: 1; transform: none; } }

.hero-lead { margin-top: 28px; font-size: 1.0625rem; max-width: 36em; }

.hero-chips { margin-top: 22px; display: flex; flex-wrap: wrap; gap: 10px; }
.hero-chips a {
  display: inline-block;
  font-family: var(--font-head); font-weight: 700; font-size: 0.8125rem;
  color: var(--cream);
  border: 1.5px solid color-mix(in srgb, var(--cream) 55%, var(--green));
  border-radius: 999px;
  padding: 7px 16px;
  transition: background-color var(--t), color var(--t), border-color var(--t);
}
.hero-chips a:hover { background: var(--cream); color: var(--green); border-color: var(--cream); }

.hero-actions { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 14px; }
.hero .btn-primary { background: var(--cream); color: var(--green); border-color: var(--cream); }
.hero .btn-primary:hover { background: #fff; border-color: #fff; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25); }
.hero .btn-ghost { color: var(--cream); border-color: var(--cream); }
.hero .btn-ghost:hover { background: var(--cream); color: var(--green); }

/* 見せ場: ロゴ矢印が左下から右上へ描画され、そのまま画面を斜めに切る境界線になる */
.hero-line {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  color: var(--accent);
  overflow: visible;
  pointer-events: none;
  z-index: 3;
}
.hero-line .line-main {
  stroke-dasharray: 100; stroke-dashoffset: 100;
  animation: draw 1.2s cubic-bezier(0.2, 0.7, 0.2, 1) 0.6s forwards;
}
.hero-line .line-head {
  opacity: 0;
  animation: seq-up 0.3s ease-out 1.65s forwards;
}
@keyframes draw { to { stroke-dashoffset: 0; } }

/* 写真パネル: 全面に敷き、矢印に沿った多角形で切り抜く (座標はJS)。
   描画された線に沿って右へ開く。受領後は <img> を挿入 */
.hero .hero-photo {
  position: absolute; inset: 0;
  /* JSが座標を入れるまでは何も見せない (読み込み直後に写真全面が一瞬映るのを防ぐ) */
  clip-path: polygon(100% 0, 100% 0, 100% 0);
  border: none;
  background:
    repeating-linear-gradient(-45deg, transparent 0 14px, rgba(253, 251, 230, 0.05) 14px 28px),
    #10402C;
  transition: clip-path 0.9s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.hero .hero-photo .ph-label {
  position: absolute; right: 5%; top: 46%;
  max-width: 34%; padding: 0; text-align: right;
  color: color-mix(in srgb, var(--cream) 70%, var(--green));
}
.hero-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero .hero-photo.has-img .ph-label { display: none; }
/* 実写をブランドの深緑に馴染ませる薄い色被せ (写真の主張を少し抑えて文字と矢印を立てる) */
.hero .hero-photo.has-img::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(11, 47, 33, 0.55) 0%, rgba(11, 47, 33, 0.25) 60%, rgba(11, 47, 33, 0.45) 100%);
  pointer-events: none;
}
.hero .hero-photo .ph-tag { position: absolute; right: 16px; bottom: 30px; z-index: 1; margin: 0; }

/* スクロール誘導 (小さく) */
.hero-scroll {
  position: absolute;
  left: max(24px, calc((100vw - 1160px) / 2));
  bottom: 30px;
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-head); font-weight: 700; font-size: 0.6875rem; letter-spacing: 0.2em;
  color: color-mix(in srgb, var(--cream) 55%, var(--green));
  opacity: 0;
  animation: seq-up 0.6s ease-out 1.6s forwards;
  z-index: 3;
}
.hero-scroll i { display: block; width: 40px; height: 1px; background: currentColor; }

/* ---------- 登場アニメーション ---------- */

.reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.6s ease-out, transform 0.6s ease-out; }
.reveal.is-in { opacity: 1; transform: none; }

/* グループスタガー: 親に data-stagger、子に --i を JS が付与 */
[data-stagger] > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
  transition-delay: calc(var(--i, 0) * 0.09s);
}
[data-stagger].is-in > *, [data-stagger] > .is-in { opacity: 1; transform: var(--rest-transform, none); }


/* ---------- 事業内容: 全幅バンド + 深緑の斜めパネル (ヒーローと同じ文法) ---------- */

#services { padding-bottom: 0; }
#services .section-head { margin-bottom: 40px; }

/* コンテナを突き抜けて全幅にする */
.service-list {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  display: grid;
  grid-template-columns: minmax(0, 1fr);   /* 子の最小幅で列が膨らまないようにする */
}
.svc {
  display: grid;
  grid-template-columns: 46% 54%;
  min-height: 600px;
  background: #fff;
}
.svc:nth-child(even) { background: var(--paper); }

/* ビジュアル: 深緑パネルは全段左固定。斜辺の頂点を段の境界で共有し、
   段1右下がり→段2左下がり→段3右下がり の連続ジグザグ (ロゴのM字) にする。
   列幅46%に対し 78%/96% = 画面幅の約36%/44% */
.svc-visual { position: relative; min-height: 360px; }
.svc-panel {
  position: absolute; inset: 0;
  background: var(--green);
  clip-path: polygon(0 0, 78% 0, 96% 100%, 0 100%);
  overflow: hidden;
}
.svc:nth-child(even) .svc-panel { clip-path: polygon(0 0, 96% 0, 78% 100%, 0 100%); }

/* 境界に黄土色のライン (ヒーローの矢印と同じ文法)。全段を貫く1本で、
   スクロールに合わせて伸びる (dashoffset はJSが更新)。太さは画面拡縮に依存しない */
.service-list { position: relative; }
.svc-zigzag {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  overflow: visible; pointer-events: none;
  z-index: 2;
  color: var(--accent);
}
.svc-zigzag path {
  fill: none;
  stroke: currentColor; stroke-width: 3;
  stroke-linejoin: miter;
  stroke-dasharray: 100;
  stroke-dashoffset: 100;
}
/* 画像は深緑単色背景付きで生成 → パネル全面に contain で敷けば余白も同色で継ぎ目が出ない。
   斜辺で右側が欠けるので、絵の重心をやや左に寄せる */
.svc-panel img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: contain;
  object-position: 34% 50%;
  transition: transform 0.6s ease-out;
}
.svc:hover .svc-panel img { transform: scale(1.03); }
/* 旧版 (白地用・透過イラスト) にフォールバックした場合はパネルを薄い色にし、中央に小さめ配置 */
.svc-panel.is-light { background: var(--tint); }
.svc-panel.is-light img { object-fit: contain; padding: 12%; }
/* (パネル内の巨大番号は見切れリスクのため廃止) */

/* テキスト側 */
.svc-body {
  padding: 64px max(24px, calc((100vw - 1160px) / 2)) 64px 56px;
  display: flex; flex-direction: column; justify-content: center;
}

.svc-brand {
  font-family: var(--font-head); font-weight: 700;
  font-size: 0.8125rem; letter-spacing: 0.22em;
  color: var(--accent);
}
.svc-name {
  font-family: var(--font-head); font-weight: 900;
  font-size: clamp(2.25rem, 3.6vw, 3.25rem);
  line-height: 1.2; color: var(--green);
  margin-top: 6px;
}
/* 長い事業名 (マーケティングパートナー等) は1行に収まるサイズに落とす */
.svc-name--long { font-size: clamp(1.75rem, 2.6vw, 2.4rem); white-space: nowrap; }

.svc-catch {
  margin-top: 12px;
  font-family: var(--font-head); font-weight: 700;
  font-size: 1.25rem; color: var(--ink);
}
.svc-desc { margin-top: 12px; font-size: 0.9688rem; max-width: 40em; }

.svc-cols {
  margin-top: 22px;
  display: grid; grid-template-columns: 1fr 1.2fr; gap: 20px 32px;
}
.svc-col h4 {
  font-family: var(--font-head); font-weight: 700; font-size: 0.75rem; letter-spacing: 0.14em;
  color: var(--green-soft);
  border-bottom: 2px solid var(--green);
  padding-bottom: 6px; margin-bottom: 8px;
}
.svc-col li {
  font-size: 0.875rem; line-height: 1.6;
  padding: 4px 0 4px 16px; position: relative;
}
.svc-col li::before {
  content: ""; position: absolute; left: 0; top: 12px;
  width: 8px; height: 8px; background: var(--accent);
}

.svc-plans {
  margin-top: 24px;
  display: flex; flex-wrap: wrap; align-items: stretch; gap: 10px;
}
.svc-plan {
  position: relative;
  border: 1.5px solid var(--line);
  background: #fff;
  padding: 12px 16px 10px;
  min-width: 150px;
  display: flex; flex-direction: column;
}
.svc-plan.is-rec { border-color: var(--green); }
.svc-plan-rec {
  position: absolute; top: -10px; left: 12px;
  background: var(--green); color: var(--cream);
  font-family: var(--font-head); font-weight: 700; font-size: 0.6875rem;
  padding: 2px 8px;
}
.svc-plan-name { font-family: var(--font-head); font-weight: 700; font-size: 0.8125rem; color: var(--green-soft); }
.svc-plan-price { font-family: var(--font-head); font-weight: 900; font-size: 1.25rem; color: var(--green); line-height: 1.2; }
.svc-plan-note { font-size: 0.75rem; color: var(--green-soft); margin-top: 2px; }
.svc-plans > .tbd { align-self: center; margin: 0; }

.svc-link { margin-top: 26px; align-self: flex-start; }

/* 4段目: 写真バンド (事業内容の締め)。パネルの中身だけ実写にし、深緑の色被せでトーンを揃える */
.svc--photo .svc-panel img { object-fit: cover; object-position: 50% 50%; }
.svc--photo .svc-panel::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(11, 47, 33, 0.55) 0%, rgba(11, 47, 33, 0.25) 60%, rgba(11, 47, 33, 0.5) 100%);
  pointer-events: none;
}
.svc--photo .svc-panel .ph-tag { position: absolute; left: 16px; bottom: 16px; z-index: 1; margin: 0; }
.svc--photo .svc-brand { color: var(--green-soft); }
.svc-statement {
  font-family: var(--font-head); font-weight: 900;
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  line-height: 1.5; color: var(--green);
  margin-top: 8px;
}

/* ---------- 実績 (ダーク面) ---------- */

.section-dark {
  background: var(--green);
  color: var(--cream);
  overflow: hidden;
}

.dark-watermark {
  position: absolute;
  right: -60px; bottom: -40px;
  width: 620px;
  pointer-events: none;
  overflow: visible;
}
.dark-watermark .wm-base { stroke: var(--cream); opacity: 0.06; }
/* 塗りレイヤー: 画面に入ったら根本から矢じりへ黄土色が伸びる */
.dark-watermark .wm-paint {
  stroke: var(--accent);
  opacity: 0.85;
  stroke-dasharray: 100;
  stroke-dashoffset: 100;
  transition: stroke-dashoffset 1.4s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.dark-watermark .wm-paint-head { transition-duration: 0.4s; transition-delay: 1.3s; }
.dark-watermark.is-in .wm-paint { stroke-dashoffset: 0; }

.section-dark .section-title { color: var(--cream); }
.section-dark .section-sub { color: color-mix(in srgb, var(--cream) 75%, var(--green)); }
.note-on-dark { color: color-mix(in srgb, var(--cream) 70%, var(--green)); }

.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  position: relative;
}
.stat {
  border-left: 3px solid var(--cream);
  padding: 6px 0 6px 24px;
}
.stat dt { font-size: 0.875rem; letter-spacing: 0.08em; }
.stat dd {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: clamp(2.75rem, 5.5vw, 4rem);
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
.stat-unit { font-size: 0.42em; font-weight: 700; margin-left: 4px; }

.case-grid {
  margin-top: 44px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  position: relative;
}
.case-card {
  border: 1px solid var(--line-on-dark);
  background: color-mix(in srgb, var(--cream) 4%, var(--green));
  padding: 28px 26px;
  transition: opacity 0.6s ease-out, transform 0.6s ease-out, border-color var(--t);
  transition-delay: calc(var(--i, 0) * 0.09s), calc(var(--i, 0) * 0.09s), 0s;
}
.case-card:hover { border-color: var(--cream); }
.case-meta {
  display: flex; flex-wrap: wrap; gap: 8px;
  font-family: var(--font-head); font-weight: 700; font-size: 0.75rem;
}
.case-meta span { border: 1px solid var(--line-on-dark); padding: 3px 10px; }
.case-support {
  margin-top: 16px;
  font-family: var(--font-head); font-weight: 700;
  font-size: 1.0625rem;
}
.case-body { margin-top: 10px; font-size: 0.9063rem; color: color-mix(in srgb, var(--cream) 85%, var(--green)); }

/* ---------- ご依頼の流れ: 成長曲線 (黄土の線+ノード+同寸カード) ---------- */

.section-flow { overflow: hidden; }

.flow-chart { position: relative; --chart-h: 250px; padding-top: var(--chart-h); }   /* margin だと相殺で座標がずれるので padding */
.flow-svg {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  overflow: visible; pointer-events: none;
}
.fl-area { fill: var(--green); opacity: 0.05; }
.fl-ticks line { stroke: var(--green-soft); stroke-width: 1.5; stroke-dasharray: 3 5; opacity: 0.6; }
/* 線は深緑の静かな細線。ここは黄土色の演出を使わず目を休める */
.fl-base { stroke: var(--green); stroke-width: 3; opacity: 0.45; }
.fl-paint { display: none; }

/* ノード: 小さな正方形マーカー (番号はカード側へ) */
.flow-nodes { position: absolute; inset: 0; pointer-events: none; }
.flow-node {
  position: absolute;
  width: 14px; height: 14px; margin: -7px 0 0 -7px;
  background: var(--green);
  outline: 4px solid var(--paper);
}
.flow-node:last-child { width: 18px; height: 18px; margin: -9px 0 0 -9px; }   /* 最終ステップだけ少し大きく */

/* カード: 6枚同寸・下端揃え。グラフの分だけ上に余白 */
.flow-list {
  position: relative; z-index: 1;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 18px;
}
.flow-step {
  background: #fff;
  border: 1px solid var(--line);
  border-top: 4px solid var(--green);
  padding: 22px 18px 20px;
  transition: opacity 0.6s ease-out, transform 0.6s ease-out, box-shadow var(--t);
  transition-delay: calc(var(--i, 0) * 0.09s), calc(var(--i, 0) * 0.09s), 0s;
}
.flow-step:hover { box-shadow: 0 10px 24px rgba(11, 47, 33, 0.12); }
.flow-num {
  display: block;
  font-family: var(--font-head); font-weight: 700;
  font-size: 0.75rem; letter-spacing: 0.16em;
  color: var(--green-soft);
  margin-bottom: 8px;
}
.flow-step h3 {
  font-family: var(--font-head); font-weight: 700;
  font-size: 0.9375rem; line-height: 1.4; letter-spacing: 0;
  color: var(--green);
}
.flow-step p { font-size: 0.8125rem; line-height: 1.7; margin-top: 8px; }

.flow-cta {
  margin-top: 48px;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 24px;
  background: var(--tint);
  border: 1px dashed var(--green-soft);
  padding: 28px 32px;
}
.flow-cta p { font-family: var(--font-head); font-weight: 700; color: var(--green); }

/* ---------- チーム ---------- */

.team-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  align-items: stretch;
}
.team-card {
  background: #fff;
  border: 1px solid var(--line);
  border-top: 4px solid var(--green);
  padding: 16px 16px 20px;
  text-align: left;
  position: relative;
  transition: opacity 0.6s ease-out, transform 0.6s ease-out, box-shadow var(--t);
  transition-delay: calc(var(--i, 0) * 0.09s), calc(var(--i, 0) * 0.09s), 0s;
}
.team-card:hover { box-shadow: 0 12px 28px rgba(11, 47, 33, 0.14); }

/* 実写前提の縦型フレーム (4:5)。受領後は同比率トリミングの <img> に差し替え */
.member-photo {
  aspect-ratio: 4 / 5;
  width: 100%;
  margin-bottom: 14px;
}
.mp-initial {
  font-family: var(--font-head); font-weight: 900;
  font-size: 2rem;
  color: var(--green);
  opacity: 0.35;
}
.member-photo .ph-label { position: absolute; bottom: 8px; left: 0; right: 0; }

.team-name { font-family: var(--font-head); font-weight: 700; font-size: 1.0625rem; color: var(--green); }
.team-role {
  font-family: var(--font-head); font-weight: 700;
  font-size: 0.75rem; letter-spacing: 0.12em;
  color: var(--green-soft); margin-top: 2px;
}
.team-x { display: inline-block; margin-top: 10px; font-size: 0.75rem; font-weight: 600; color: var(--green-soft); }

.team-card-recruit {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 8px;
  background: var(--green);
  border: 1px solid var(--green);
  border-top: 4px solid var(--green);
  color: var(--cream);
  text-align: center;
  padding: 30px 18px 24px;
  font-family: var(--font-head); font-weight: 700;
  transition: opacity 0.6s ease-out, transform 0.6s ease-out, background-color var(--t);
  transition-delay: calc(var(--i, 0) * 0.09s), calc(var(--i, 0) * 0.09s), 0s;
}
.team-card-recruit:hover { background: var(--green-hover); }
.team-card-recruit h3 { font-size: 1.0625rem; font-weight: 900; }
.team-card-recruit p { font-size: 0.8125rem; line-height: 1.7; font-weight: 500; }

/* ---------- お知らせ ---------- */

.news-list { border-top: 1px solid var(--line); }
.news-list li { border-bottom: 1px solid var(--line); }
.news-list .news-row {
  display: grid;
  grid-template-columns: 110px 90px 1fr;
  gap: 18px;
  align-items: baseline;
  padding: 18px 8px;
  transition: background-color var(--t);
}
.news-list .news-row:hover { background: var(--tint); }
.news-date { font-family: var(--font-head); font-weight: 500; font-size: 0.875rem; color: var(--green-soft); }
.news-tag {
  font-family: var(--font-head); font-weight: 700; font-size: 0.6875rem;
  color: var(--green); border: 1px solid var(--green);
  text-align: center; padding: 2px 0;
}
.news-title { font-size: 0.9375rem; }

/* ---------- 会社概要 ---------- */

.company-table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border: 1px solid var(--line);
}
.company-table th, .company-table td {
  text-align: left;
  padding: 18px 24px;
  border-bottom: 1px solid var(--line);
  font-size: 0.9375rem;
  vertical-align: top;
}
.company-table tr:last-child th, .company-table tr:last-child td { border-bottom: none; }
.company-table th {
  width: 180px;
  font-family: var(--font-head); font-weight: 700;
  color: var(--green);
  background: var(--tint);
}

/* ---------- お問い合わせ ---------- */

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 40px;
  align-items: start;
}
.contact-choices { display: grid; gap: 20px; }
.contact-card {
  display: block;
  background: #fff;
  border: 2px solid var(--green);
  padding: 26px 28px;
  transition: background-color var(--t);
}
.contact-card:hover { background: var(--cream); }
.contact-card h3 {
  font-family: var(--font-head); font-weight: 900;
  font-size: 1.25rem; color: var(--green);
}
.contact-card h3::after { content: " →"; font-weight: 700; }
.contact-card p { font-size: 0.875rem; margin-top: 6px; }

.contact-form {
  background: #fff;
  border: 1px solid var(--line);
  padding: 32px;
}
.form-row { margin-bottom: 18px; }
.form-row label {
  display: block;
  font-family: var(--font-head); font-weight: 700;
  font-size: 0.8125rem; color: var(--green);
  margin-bottom: 6px;
}
.form-row input, .form-row textarea {
  width: 100%;
  font: inherit;
  padding: 12px 14px;
  border: 1px solid var(--line);
  background: var(--paper);
  transition: border-color var(--t);
}
.form-row input:focus, .form-row textarea:focus {
  outline: none;
  border-color: var(--green);
}
#form-note { margin-top: 12px; }

/* ---------- 仮組バナー・フッター ---------- */

.mock-banner {
  background: var(--ink);
  color: var(--cream);
  text-align: center;
  font-size: 0.8125rem;
  padding: 12px 24px;
}

.site-footer {
  background: var(--green);
  color: var(--cream);
  padding: 72px 0 28px;
  position: relative;
}
.footer-grid {
  display: flex; flex-wrap: wrap; gap: 48px;
  justify-content: space-between;
  align-items: flex-start;
}
.footer-brand img { width: 180px; }
.footer-nav { display: flex; gap: 64px; flex-wrap: wrap; }
.footer-nav a, .dead-link {
  display: block;
  font-size: 0.875rem;
  padding: 6px 0;
  transition: opacity var(--t);
}
.footer-nav a:hover { opacity: 0.7; }
.dead-link { opacity: 0.75; }
.copyright {
  text-align: center;
  font-size: 0.75rem;
  margin-top: 48px;
  opacity: 0.6;
}

/* 背の低いビューポート: ヒーローを1画面に収めるため余白を詰める */
@media (max-height: 820px) and (min-width: 961px) {
  .hero-copy { padding-top: 28px; padding-bottom: 128px; }
  .hero .eyebrow { margin-bottom: 6px; }
  .hero-lead { margin-top: 14px; font-size: 1rem; }
  .hero-chips { margin-top: 12px; }
  .hero-actions { margin-top: 20px; }
  .hero-copy { padding-bottom: 100px; }
  .hero-scroll { bottom: 12px; }
}

/* ---------- reduced-motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-seq, .hero-scroll { animation: none; opacity: 1; transform: none; }
  .line-in { animation: none; transform: none; }
  .hero-line .line-main { animation: none; stroke-dashoffset: 0; }
  .hero-line .line-head { animation: none; opacity: 1; }
  .hero .hero-photo { transition: none; }
  .reveal, [data-stagger] > * { opacity: 1; transform: var(--rest-transform, none); transition: none; }
  .flow-chart .reveal { opacity: 1; transform: none; }
  .dark-watermark .wm-paint { stroke-dashoffset: 0; transition: none; }
  * { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

/* ---------- レスポンシブ ---------- */

@media (max-width: 1080px) {
  .flow-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 960px) {
  .section { padding: 72px 0; }
  .hero { min-height: 0; display: block; }
  .hero-copy { width: auto; padding: 56px 24px 64px; }
  .hero .hero-photo {
    position: static; height: 42vh;
    clip-path: polygon(0 16%, 100% 0, 100% 100%, 0 100%);
    transition: none;
  }
  .hero .hero-photo .ph-label { position: static; max-width: none; text-align: center; }
  .hero-line, .hero-scroll { display: none; }

  .svc, .svc:nth-child(even) { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .svc-name--long { white-space: normal; font-size: clamp(1.25rem, 6vw, 2rem); }
  .svc-statement br { display: none; }   /* 幅が狭いときは自然改行に任せる */
  .svc-visual { min-height: 260px; }
  .svc-panel, .svc:nth-child(even) .svc-panel { clip-path: polygon(0 0, 100% 0, 100% 84%, 0 100%); }
  .svc-panel img { object-position: 50% 50%; }
  .svc-zigzag { display: none; }
  .svc-body { padding: 36px 24px 44px; }
  .svc-cols { grid-template-columns: 1fr; }

  .case-grid, .stats, .team-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .contact-grid, .company-grid { grid-template-columns: 1fr; }

  .global-nav {
    display: none;
    position: absolute; top: 100%; left: 0; right: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    padding: 12px 24px 20px;
  }
  .global-nav.is-open { display: block; }
  .global-nav ul { flex-direction: column; gap: 0; }
  .global-nav a { padding: 12px 4px; border-bottom: 1px solid var(--line); }
  .nav-toggle { display: block; margin-left: auto; }
  .header-cta { display: none; }
}

@media (max-width: 640px) {
  body { font-size: 15px; }
  .stats, .case-grid { grid-template-columns: 1fr; }

  /* 流れ: 縦タイムライン (線は左、カードは右) */
  .flow-chart { --chart-h: 0px; }
  .flow-list { grid-template-columns: 1fr; gap: 14px; padding-left: 56px; }
  .flow-step { border-top: 1px solid var(--line); border-left: 4px solid var(--green); }
  .flow-step h3 br { display: none; }

  .news-list .news-row { grid-template-columns: 96px 1fr; }
  .news-title { grid-column: 1 / -1; }
  /* 会社概要: 見出しセルが1文字ずつ縦に折れないよう、ラベルを上に積む */
  .company-table th, .company-table td { display: block; width: auto; }
  .company-table th { padding: 12px 16px 2px; border-bottom: none; font-size: 0.75rem; letter-spacing: 0.1em; }
  .company-table td { padding: 2px 16px 12px; }
  .footer-nav { gap: 32px; }
  .team-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .photo-band-copy { position: static; max-width: none; padding: 20px 24px; }
  .photo-band .ph-band { height: 220px; }
}
