/* salt AIエンジニアリング
   デザインは案B（design/canvas/project/MainB.dc.html・MobileB.dc.html）に合わせている。
   色は :root のトークンだけ差し替えれば全体に効く */

:root {
  --bg: #fafaf8;
  --surface: #ffffff;
  --tint: #f2f0ed;
  --ink: #231815;
  --muted: #5f5b58;
  --line: #e2dfdb;
  --accent: #231815;
  --accent-fg: #ffffff;
  --q: #b00000;          /* 赤：問いかけ・強調・工程番号など、赤はすべてこれ1色 */
  --img-filter: none;    /* 線画の画像。ダークでは白黒を反転する */

  --f-body: "Noto Sans JP", "Hiragino Sans", "Yu Gothic UI", "Meiryo", sans-serif;
  --f-label: "Jost", "Noto Sans JP", sans-serif;
  --container: 1200px;
  --gutter: 40px;
  --header-h: 76px;
}
@media (max-width: 860px) {
  :root { --gutter: 20px; --header-h: 60px; }
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #141312;
    --surface: #1c1b1a;
    --tint: #191817;
    --ink: #ecebe9;
    --muted: #a19d99;
    --line: #2f2d2b;
    --accent: #ecebe9;
    --accent-fg: #141312;
    --q: #ff8f87;
    --img-filter: invert(1);
  }
}
:root[data-theme="dark"] {
  --bg: #141312;
  --surface: #1c1b1a;
  --tint: #191817;
  --ink: #ecebe9;
  --muted: #a19d99;
  --line: #2f2d2b;
  --accent: #ecebe9;
  --accent-fg: #141312;
  --q: #ff8f87;
  --img-filter: invert(1);
}

*, *::before, *::after { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  /* アンカーで移動したとき、見出しが固定ヘッダーの下に隠れないようにする */
  scroll-padding-top: calc(var(--header-h) + 48px);
  -webkit-text-size-adjust: 100%;
}
/* 案C：PCではページ全体を90%の大きさで表示する（スマホは端末に合わせてそのまま） */
@media (min-width: 861px) {
  html { zoom: .9; }
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.9;
  letter-spacing: .02em;
  overflow-wrap: anywhere;
  line-break: strict;
}
h1, h2, h3, h4, p, dl, dd, ol, figure { margin: 0; }
ol { padding: 0; list-style: none; }
img { max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
a:hover { opacity: .75; }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 2px solid var(--q); outline-offset: 3px; }
strong { font-weight: 700; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.line-img { filter: var(--img-filter); }

/* 改行：PCだけ／スマホだけ */
@media (max-width: 860px) { .br-pc { display: none; } }
@media (min-width: 861px) { .br-sp { display: none; } }

.container {
  /* 中身の幅を --container にする（左右の余白はその外側） */
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin-inline: auto;
  padding-left: max(var(--gutter), env(safe-area-inset-left, 0px));
  padding-right: max(var(--gutter), env(safe-area-inset-right, 0px));
}

/* ラベル（ABOUT ― 〜） */
.label { font-family: var(--f-label); font-size: 13px; letter-spacing: .2em; color: var(--muted); }
@media (max-width: 860px) { .label { font-size: 12px; } }

/* ヘッダー */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.site-header__inner { height: var(--header-h); display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.logo { display: flex; align-items: center; }
.logo img { display: block; height: 26px; width: auto; filter: var(--img-filter); }
@media (max-width: 860px) { .logo img { height: 22px; } }
.site-nav { display: flex; align-items: center; gap: 32px; font-size: 14px; white-space: nowrap; }

.nav-toggle { display: none; }
@media (max-width: 1000px) {
  .nav-toggle {
    display: grid; place-items: center;
    width: 44px; height: 44px; margin-right: -10px;
    background: none; border: 0; color: var(--ink); cursor: pointer;
  }
  .nav-toggle__bar, .nav-toggle__bar::before, .nav-toggle__bar::after {
    display: block; width: 22px; height: 1.5px; background: currentColor; position: relative; content: "";
    transition: transform .2s;
  }
  .nav-toggle__bar::before { position: absolute; left: 0; top: -7px; }
  .nav-toggle__bar::after { position: absolute; left: 0; top: 7px; }
  .nav-toggle[aria-expanded="true"] .nav-toggle__bar { background: transparent; }
  .nav-toggle[aria-expanded="true"] .nav-toggle__bar::before { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] .nav-toggle__bar::after { transform: translateY(-7px) rotate(-45deg); }

  .site-nav {
    display: none;
    position: absolute; top: var(--header-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    padding: 8px var(--gutter) 20px;
    background: var(--bg); border-bottom: 1px solid var(--line);
    font-size: 16px; white-space: normal;
  }
  .site-nav.is-open { display: flex; }
  .site-nav a:not(.btn) { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .site-nav .btn { margin-top: 16px; }
}

/* ボタン */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  height: 60px; padding: 0 40px;
  background: var(--accent); color: var(--accent-fg);
  font-size: 17px; font-weight: 500; letter-spacing: .06em; text-align: center;
  transition: opacity .15s;
}
.btn:hover { opacity: .85; }
.btn--sm { height: 42px; padding: 0 20px; font-size: 14px; }

/* ── トップ ── */
.hero__split {
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  align-items: center; gap: 64px; padding: 32px 32px 0;
}
.hero__copy { position: relative; z-index: 1; top: -88px; }
.hero__brand { display: inline-flex; align-items: center; gap: 16px; margin-bottom: 32px; }
.hero__brand img { width: 48px; height: 48px; display: block; filter: var(--img-filter); }
.hero__brand p { font-size: 16px; font-weight: 500; letter-spacing: .12em; }
.hero__title { font-size: 64px; font-weight: 500; line-height: 1.45; letter-spacing: .06em; font-feature-settings: "palt"; }
.hero__img {
  position: relative; top: -32px; z-index: 0;
  width: 125%; max-width: none; aspect-ratio: 1 / 1; margin: -48px 0 0 -15%;
  object-fit: contain; display: block; opacity: .27; pointer-events: none;
  filter: var(--img-filter);
}
/* 問いかけ：トップからABOUTへ誘導する */
.hero__q {
  position: relative; z-index: 1; margin-top: -190px; padding: 0 32px;
  display: flex; flex-direction: column; align-items: flex-start; gap: 28px;
}
.hero__q::before { content: ""; display: block; width: 40px; height: 2px; background: var(--q); margin-bottom: -12px; }
.hero__q p { font-size: 27px; font-weight: 400; line-height: 1.9; letter-spacing: .04em; font-feature-settings: "palt"; color: var(--q); }
.hero__q::after { content: ""; display: block; width: 1px; height: 72px; margin-top: 4px; background: var(--ink); }
@media (max-width: 860px) {
  .hero { padding-top: 28px; }
  .hero__split { grid-template-columns: minmax(0, 1fr); gap: 0; padding: 0; }
  .hero__copy { top: 0; }
  .hero__brand { gap: 12px; margin-bottom: 16px; }
  .hero__brand img { width: 36px; height: 36px; }
  .hero__brand p { font-size: 14px; }
  .hero__title { font-size: 34px; line-height: 1.5; }
  .hero__img { top: 0; width: 100%; margin: -8px 0 0; }
  .hero__q { margin-top: -120px; padding: 0; gap: 20px; }
  .hero__q::before { width: 32px; margin-bottom: -6px; }
  .hero__q p { font-size: 19px; }
  .hero__q::after { height: 56px; margin-top: 0; }
}

/* ── ABOUT ── */
.about { padding-bottom: 120px; }
.rail { margin-left: 32px; }
.rail__line {
  border-left: 1px solid var(--ink); padding: 40px 0 120px 56px;
  display: flex; flex-direction: column; gap: 24px;
}
.rail__block { position: relative; display: flex; flex-direction: column; gap: 16px; }
.rail__dot { position: absolute; left: -61px; top: 9px; width: 9px; height: 9px; border-radius: 50%; background: var(--q); }
.rail__dot--b { top: 24px; }
.about__head { display: flex; flex-direction: column; gap: 12px; }
.about__label { font-family: var(--f-label); font-size: 14px; font-weight: 500; letter-spacing: .2em; }
.about__title { font-size: 46px; font-weight: 500; line-height: 1.6; letter-spacing: .04em; font-feature-settings: "palt"; }
.about-row { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 72px; align-items: center; }
.about-row--rev { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: 64px; }
.about__body { display: flex; flex-direction: column; gap: 16px; max-width: 26em; }
.about__body p { font-size: 18px; line-height: 2.1; }
.about__fig1 { width: 93%; aspect-ratio: 1100 / 1026; object-fit: contain; display: block; filter: var(--img-filter); }
.about__point { font-size: 32px; font-weight: 500; line-height: 1.8; letter-spacing: .04em; font-feature-settings: "palt"; }

.answer { display: grid; grid-template-columns: 48px minmax(0, 1fr); column-gap: 32px; align-items: start; margin-left: 8px; }
.answer__mark { width: 48px; height: 48px; display: block; margin-top: 8px; filter: var(--img-filter); }
.answer__body { display: flex; flex-direction: column; gap: 32px; min-width: 0; }
.answer__text { max-width: 28em; font-size: 38px; font-weight: 500; line-height: 1.75; letter-spacing: .03em; font-feature-settings: "palt"; }
.answer__text .em { color: var(--q); }
.answer__text .ul { text-decoration: underline; text-decoration-color: var(--q); text-decoration-thickness: 2px; text-underline-offset: 12px; }
.answer__fig2 { width: 100%; aspect-ratio: 1400 / 933; object-fit: contain; display: block; filter: var(--img-filter); }
.answer__close { max-width: 22em; font-size: 22px; font-weight: 500; line-height: 2; }

@media (max-width: 860px) {
  .about { padding-bottom: 80px; }
  .rail { margin-left: 0; }
  .rail__line { padding: 32px 0 72px 24px; gap: 56px; }
  .rail__block { gap: 32px; }
  .rail__dot { left: -29px; top: 7px; }
  .rail__dot--b { top: 13px; }
  .about__head { gap: 20px; }
  .about__label { font-size: 12px; letter-spacing: .16em; }
  .about__title { font-size: 26px; }
  .about-row, .about-row--rev { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .about__body { gap: 24px; max-width: none; }
  .about__body p { font-size: 16px; line-height: 2; }
  .about__fig1 { width: 100%; }
  .about__point { font-size: 20px; }
  .answer { grid-template-columns: minmax(0, 1fr); row-gap: 32px; margin-left: 0; padding-top: 40px; }
  .answer__mark { width: 36px; height: 36px; margin-top: 0; }
  .answer__body { gap: 32px; }
  .answer__text { font-size: 23px; line-height: 1.8; }
  .answer__text .ul { text-underline-offset: 8px; }
  .answer__close { font-size: 18px; max-width: none; }
}

/* ── 節の共通 ── */
.sec__inner { padding-block: 140px; display: flex; flex-direction: column; gap: 24px; }
/* PCの節ごとの余白（案Bのキャンバスで詰めた値） */
@media (min-width: 861px) {
  .about { padding-bottom: 100px; }
  .hero__brand { position: relative; top: -12px; }
  /* 図解2を少し大きく見せる（左端を基準に拡大し、右の文の下にもぐらせる） */
  .answer__fig2 { transform: scale(1.2); transform-origin: left center; position: relative; z-index: 0; }
  .answer__close { position: relative; z-index: 1; }
  .service .sec__inner { padding-top: 80px; }
  .workflow .sec__inner { padding-block: 64px; }
  .contact .sec__inner { padding-top: 80px; }
}
.sec__title { font-size: 36px; font-weight: 500; line-height: 1.6; letter-spacing: .04em; }
.sec__lead { color: var(--muted); }
@media (max-width: 860px) {
  .sec__inner { padding-block: 80px; gap: 16px; }
  .sec__title { font-size: 26px; }
  .sec__lead { font-size: 15px; }
}

/* ── サービス ── */
.service { background: var(--tint); }
.service .sec__inner { padding-bottom: 16px; }
.service .sec__lead { max-width: 36em; margin-bottom: 32px; }
.axes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; }
/* 左右の列で、見出し・各メニューの高さを段ごとに揃える */
.axes__col { display: grid; grid-template-rows: subgrid; grid-row: span 4; row-gap: 12px; min-width: 0; }
.axis-head { padding: 32px; background: var(--accent); color: var(--accent-fg); display: flex; flex-direction: column; gap: 8px; }
.axis-head__en { font-family: var(--f-label); font-size: 12px; letter-spacing: .2em; opacity: .8; }
.axis-head__name { font-size: 28px; font-weight: 700; letter-spacing: .06em; }
.axis-head__lead { font-size: 16px; font-weight: 500; }
.axis-head__text { font-size: 14px; line-height: 1.8; opacity: .85; }
.plan { padding: 24px 32px; background: var(--surface); border: 1px solid var(--line); display: flex; flex-direction: column; gap: 4px; }
.plan--cont { padding-block: 18px; background: transparent; border: 1px dashed var(--muted); }
.plan__top { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; }
.plan__name { font-size: 22px; font-weight: 700; }
.plan__name--q { color: var(--q); }
.plan__price { font-size: 15px; }
.plan__price b { font-family: var(--f-label); font-size: 22px; font-weight: 500; }
.plan__price .plan__term { margin-left: 10px; font-size: 13px; color: var(--muted); }
.plan__price--est { font-size: 17px; font-weight: 500; }
.plan__when { font-size: 14px; font-weight: 700; color: var(--muted); }
.plan__text { font-size: 14px; line-height: 1.8; color: var(--muted); }
@media (max-width: 860px) {
  .service .sec__lead { margin-bottom: 16px; }
  .axes { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .axes__col { row-gap: 10px; }
  .axis-head { padding: 24px 20px; gap: 6px; }
  .axis-head__en { font-size: 11px; }
  .axis-head__name { font-size: 24px; }
  .axis-head__lead { font-size: 15px; }
  .axis-head__text { font-size: 13px; }
  .plan { padding: 22px 20px; }
  .plan--cont { padding-block: 18px; }
  .plan__top { flex-direction: column; align-items: flex-start; }
  .plan__name { font-size: 19px; }
  .plan__price b { font-size: 20px; }
  .plan__price { font-size: 14px; }
  .plan__when { margin-top: 4px; font-size: 13px; }
  .plan__text { font-size: 13px; }
}

/* ── 無料相談の案内が付いてくる範囲（サービスの最後のメニューの下〜お問い合わせ） ── */
.cta-run { background: var(--tint); padding-bottom: 140px; }
.cta-run__start { height: 48px; }
@media (max-width: 860px) {
  .cta-run { padding-bottom: 80px; }
  .cta-run__start { height: 64px; }
}

/* ── ワークフロー ── */
.workflow { background: var(--bg); }
.workflow .sec__lead { margin-bottom: 32px; }
.flow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); column-gap: 40px; row-gap: 48px; }
/* 横並びでは、見出し・説明・期間の段を列どうしで揃える */
.flow__step { border-top: 1px solid var(--ink); padding-top: 20px; display: grid; grid-template-rows: subgrid; grid-row: span 3; row-gap: 14px; min-width: 0; }
.flow__head { display: flex; align-items: baseline; gap: 14px; }
.flow__no { font-family: var(--f-label); font-size: 28px; font-weight: 300; line-height: 1.2; color: var(--q); }
.flow__name { font-size: 18px; font-weight: 700; }
.flow__text { font-size: 14px; line-height: 1.8; color: var(--muted); }
.flow__term { padding-top: 14px; border-top: 1px solid var(--line); font-size: 15px; font-weight: 500; line-height: 1.7; }
.flow-note { margin-top: 8px; font-size: 13px; color: var(--muted); display: flex; flex-direction: column; gap: 2px; }
@media (max-width: 860px) {
  .workflow .sec__lead { margin-bottom: 24px; }
  .flow { grid-template-columns: minmax(0, 1fr); row-gap: 40px; }
  .flow__step { padding-top: 18px; row-gap: 12px; }
  .flow__head { gap: 12px; }
  .flow__no { font-size: 26px; }
  .flow__term { padding-top: 12px; }
  .flow-note { font-size: 12px; }
}

/* ── お問い合わせ ── */
.contact { background: var(--tint); border-top: 1px solid var(--line); }
.contact .sec__inner { padding-bottom: 0; }
.contact .sec__title { color: var(--q); }
.contact .sec__lead { margin-bottom: 32px; }
@media (min-width: 861px) { .contact .sec__lead { white-space: nowrap; } }
@media (max-width: 860px) { .contact .sec__lead { margin-bottom: 24px; } }

/* 無料相談の枠：PCはこの枠ごと画面の下に付いてきて、お問い合わせで定位置に収まる */
.cta-card {
  position: sticky; bottom: 16px; z-index: 4;
  width: calc(100% - 2 * var(--gutter)); max-width: calc(var(--container) - 80px); margin: 0 auto;
  padding: 32px 56px;
  background: var(--surface); border: 1px solid var(--q);
  box-shadow: 0 12px 32px rgb(35 24 21 / .12);
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 32px 56px;
}
.cta-card__copy { display: flex; flex-direction: column; gap: 10px; flex: 1 1 520px; min-width: 0; }
.cta-card__title { font-size: 24px; font-weight: 500; line-height: 1.6; letter-spacing: .04em; font-feature-settings: "palt"; text-wrap: pretty; }
.cta-card__lead { font-size: 16px; line-height: 1.8; color: var(--muted); text-wrap: pretty; }
.cta-card__close { margin-top: 2px; font-size: 18px; font-weight: 500; line-height: 1.6; letter-spacing: .04em; }
.cta-card__action { display: flex; flex-direction: column; align-items: center; gap: 12px; flex: 0 0 auto; }
.cta-card__meta { font-size: 14px; color: var(--muted); }

/* スマホ：スクロール中は「1行とボタン」の小さな帯。お問い合わせまで来ると、上の枠が帯に重なって置き換わる */
.cta-band { display: none; }
@media (max-width: 767px) {
  .cta-band {
    position: sticky; bottom: 12px; z-index: 4;
    width: calc(100% - 24px); height: 64px; margin: 0 auto; padding: 0 10px 0 16px;
    background: var(--surface); border: 1px solid var(--q);
    box-shadow: 0 8px 24px rgb(35 24 21 / .16);
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
  }
  .cta-band p { font-size: 14px; font-weight: 500; line-height: 1.5; }
  .cta-band .btn { height: 44px; padding: 0 16px; font-size: 14px; letter-spacing: .04em; flex: 0 0 auto; }
  .cta-card {
    position: relative; bottom: auto; z-index: 5;
    width: calc(100% - 24px); margin: -64px auto 0; padding: 20px;
    box-shadow: 0 10px 28px rgb(35 24 21 / .14);
    flex-direction: column; align-items: stretch; gap: 16px;
  }
  .cta-card__copy { flex: none; gap: 6px; }
  .cta-card__title { font-size: 17px; letter-spacing: .02em; }
  .cta-card__lead { font-size: 13px; line-height: 1.7; }
  .cta-card__close { margin-top: 0; font-size: 15px; }
  .cta-card__action { align-items: stretch; gap: 8px; }
  .cta-card .btn { height: 52px; font-size: 16px; }
  .cta-card__meta { font-size: 12px; text-align: center; }
}

/* ── フッター ── */
.site-footer { border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.site-footer__inner { padding-block: 56px calc(48px + env(safe-area-inset-bottom, 0px)); display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 40px 64px; }
.site-footer__co { display: flex; flex-direction: column; gap: 16px; flex: 1 1 520px; }
.site-footer__co img { height: 22px; width: auto; align-self: flex-start; filter: var(--img-filter); }
.site-footer__co a { text-decoration: underline; text-underline-offset: 3px; }
.site-footer__nav { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.site-footer__bottom { width: 100%; border-top: 1px solid var(--line); padding-top: 24px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 32px; }
@media (max-width: 860px) {
  .site-footer__inner { padding-block: 48px calc(40px + env(safe-area-inset-bottom, 0px)); flex-direction: column; gap: 32px; }
  .site-footer__co { flex: none; gap: 14px; }
  .site-footer__nav { gap: 0; }
  .site-footer__nav a { padding: 10px 0; }
  .site-footer__bottom { padding-top: 20px; }
}

/* 下層ページ（プライバシーポリシーなど）の本文の枠 */
.page { padding-block: clamp(80px, 12vw, 140px); }
.page a { text-decoration: underline; text-underline-offset: 3px; }

/* 仮リンクの案内 */
.toast {
  position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom, 0px)); z-index: 20;
  transform: translateX(-50%);
  width: max-content; max-width: calc(100vw - 32px);
  padding: 12px 18px;
  background: var(--ink); color: var(--bg);
  font-size: 14px; line-height: 1.6;
  box-shadow: 0 6px 24px rgb(0 0 0 / .18);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
