/* =========================================================
   Almoha コーポレートサイト — 改善提案版（スタンドアロンCSS）
   トンマナの核は維持: Labレッド #fc183d / Josefin Sans + Noto Sans JP /
   ピルボタン / オフセットシャドウ。バランス（余白リズム・階層・導線）を最適化
   ========================================================= */

:root {
  --brand: #fc183d;
  --brand-dark: #d90f30;
  --ink: #111111;
  --body: #333333;
  --muted: #777777;
  --gray: #eeeeee;
  --bg-alt: #faf7f6;
  --white: #ffffff;
  --font-en: 'Josefin Sans', 'Noto Sans JP', sans-serif;
  --font-jp: 'Noto Sans JP', sans-serif;
  --header-h: 64px;
  --page-gutter: 64px;
  --news-content-max-w: 1200px;
  --radius: 14px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }

body {
  font-family: var(--font-jp);
  color: var(--body);
  background: var(--white);
  line-height: 1.9;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

.container { max-width: 1120px; margin: 0 auto; padding: 0 32px; }
.container.narrow-c { max-width: 840px; }
.center { text-align: center; }
.pc-only { display: inline; }

/* ---------- Typography system ---------- */
.label {
  font-family: var(--font-en);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.2em;
  color: var(--brand);
  margin-bottom: 16px;
}
.label.light { color: rgba(255, 255, 255, 0.9); }
.label.center { text-align: center; }

.title-lg {
  font-size: 40px;
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1.4;
  color: var(--ink);
  margin-bottom: 32px;
}
.title-md {
  font-size: 30px;
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1.5;
  color: var(--ink);
  margin-bottom: 24px;
}
.title-lg.light, .title-md.light { color: var(--white); }
.title-lg.center { text-align: center; }

.body {
  font-size: 15px;
  letter-spacing: 0.06em;
  margin-bottom: 1.4em;
}
.body.small { font-size: 13.5px; line-height: 1.85; }
.body.light { color: rgba(255, 255, 255, 0.96); }
.body.narrow { max-width: 760px; }
.body.center.narrow { margin-left: auto; margin-right: auto; }
/* 赤帯内の長文: 改行なしで自然に流し、中央揃え（1行約55文字・2026-07-21唐澤さん確定） */
.body.band-copy {
  text-align: center;
  max-width: 880px;
  margin-left: auto;
  margin-right: auto;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  font-family: var(--font-en);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.12em;
  border-radius: 80px;
  padding: 15px 36px;
  line-height: 1.4;
  white-space: nowrap;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}
.btn-primary {
  background: var(--brand);
  color: var(--white);
  box-shadow: 0 4px 14px rgba(252, 24, 61, 0.35);
}
.btn-primary:hover { background: var(--brand-dark); transform: translateY(-2px); box-shadow: 0 8px 20px rgba(252, 24, 61, 0.4); }
.btn-white {
  background: var(--white);
  color: var(--brand);
  box-shadow: 0 4px 14px rgba(17, 17, 17, 0.25);
}
.btn-white:hover { transform: translateY(-2px); }
.btn-ghost {
  border: 2px solid rgba(255, 255, 255, 0.85);
  color: var(--white);
}
.btn-ghost:hover { background: rgba(255, 255, 255, 0.12); }
.btn-nav { font-size: 12px; padding: 10px 24px; margin-left: 12px; }
.btn-wide { min-width: 260px; margin-top: 12px; }

/* ---------- Header ---------- */
.header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--header-h);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}
.header-inner {
  width: calc(100% - (var(--page-gutter) * 2));
  max-width: var(--news-content-max-w);
  margin: 0 auto;
  height: 100%;
  padding: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.header-logo img { width: 112px; height: auto; }
.header-nav { display: flex; align-items: center; gap: 8px; }
.header-nav a:not(.btn) {
  font-family: var(--font-en);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--ink);
  padding: 8px 14px;
  border-radius: 8px;
  transition: color 0.2s ease, background 0.2s ease;
}
.header-nav a:not(.btn):hover { color: var(--brand); background: rgba(252, 24, 61, 0.06); }

.menu-toggle {
  display: none;
  width: 48px; height: 48px;
  background: none; border: none; cursor: pointer;
  flex-direction: column; justify-content: center; align-items: center; gap: 6px;
}
.menu-toggle span { display: block; width: 24px; height: 2px; background: var(--ink); transition: transform 0.25s ease, opacity 0.25s ease; }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

.mobile-menu {
  position: fixed;
  inset: var(--header-h) 0 auto 0;
  z-index: 99;
  background: var(--white);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.12);
}
.mobile-menu nav { display: flex; flex-direction: column; align-items: center; gap: 24px; padding: 36px 24px 44px; }
.mobile-menu a:not(.btn) { font-family: var(--font-en); font-size: 15px; font-weight: 600; letter-spacing: 0.12em; color: var(--ink); }

/* ---------- Hero ---------- */
.hero {
  margin-top: var(--header-h);
  /* 元サイト（faithful/ の .billboard）はファーストビューが height:100vh の赤一面。
     78vh だと画面が大きいほど下に白が残る（1280x860で125px余っていた）ため、
     ヘッダー（固定・白）の下から画面下端までを赤で埋める＝実質「全面赤」に戻す。
     2026-07-16 唐澤さん指摘で修正 */
  min-height: calc(100vh - var(--header-h));
  min-height: calc(100svh - var(--header-h)); /* モバイルのURLバー分を考慮（対応ブラウザのみ） */
  background: linear-gradient(160deg, var(--brand) 0%, #e91437 100%);
  display: flex;
  align-items: center;
  padding: 72px 32px;
}
/* 2026-07-16 唐澤さん指摘で調整:
   元サイト（faithful/）のファーストビューは「OUR MISSION」＋巨大なコピーの2要素だけで、
   コピーが主役だった（画像幅は最大1164px＝ビューポートの約77%）。
   本体はコピーを780pxに縮小したうえリード文とボタンを足したため、主役が埋もれていた。
   → コピーを元サイトと同じ大きさに戻し、他の要素は「脇役」として一段落とす */
.hero-inner {
  width: 100%;
  max-width: 1164px; /* 元サイトの .billboard-inner と同値 */
  margin: 0 auto;
  text-align: center;
}
.hero-label {
  font-family: var(--font-en);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.28em;
  color: rgba(255, 255, 255, 0.72); /* コピーより弱く */
  margin-bottom: 32px;
}
/* 主役。元サイト同様、横幅いっぱいまで使う */
.hero-title img { width: 100%; max-width: 1164px; margin: 0 auto; }

/* 以下 .hero-lead / .hero-ctas は現在ヒーローでは未使用（2026-07-16にコピー一本化）。
   リード文とCTAを復活させたくなったとき用に残してある */
.hero-lead {
  margin: 56px auto 0; /* コピーとの間を広げて主従を分ける */
  max-width: 680px;
  font-size: 14px;
  line-height: 2.1;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.82); /* コピーより弱く */
}
.hero-ctas {
  margin-top: 36px;
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}
/* ヒーロー内のボタンは本文中のボタンより一回り小さく（主役を食わないように） */
.hero-ctas .btn { font-size: 13.5px; padding: 12px 30px; }

/* ---------- Sections ---------- */
.section { padding: 112px 0; }
.section.alt { background: var(--bg-alt); }
.band { background: var(--brand); }
.section.band { padding: 96px 0; }

/* ---------- About ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 72px;
  align-items: center;
}
.about-visual { opacity: 0.85; padding: 24px; }

/* ---------- Service cards ---------- */
.service-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 64px;
}
.service-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 36px 30px 30px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  box-shadow: 0 10px 30px rgba(120, 0, 16, 0.18);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}
.service-card:hover { transform: translateY(-6px); box-shadow: 0 18px 40px rgba(120, 0, 16, 0.26); }
.service-card-label {
  font-family: var(--font-en);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.18em;
  color: var(--brand);
}
.service-card h3 {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.05em;
  line-height: 1.55;
  color: var(--ink);
}
.service-card p { font-size: 13px; line-height: 1.85; letter-spacing: 0.04em; }
.service-card-more {
  margin-top: auto;
  padding-top: 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--brand);
}

/* ---------- Work sections ---------- */
.work-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 88px;
  align-items: center;
}
.work-grid.reverse .work-visual { order: 2; }
.work-grid.reverse .work-text { order: 1; }
.work-visual img { width: 100%; }
.shadow-br { box-shadow: 14px 14px 0 var(--brand); }
.shadow-bl { box-shadow: -14px 14px 0 var(--brand); }
.work-text .btn { margin-top: 16px; }

.stat {
  font-size: 15px;
  letter-spacing: 0.06em;
  margin-bottom: 1.4em;
}
.stat strong {
  font-family: var(--font-en);
  font-size: 44px;
  font-weight: 700;
  color: var(--brand);
  line-height: 1;
  margin-right: 4px;
}
.stat strong span { font-size: 18px; font-family: var(--font-jp); font-weight: 700; }

.consulting { max-width: 760px; }
.consulting .btn { margin-top: 8px; }

/* ---------- Members ---------- */
.members { padding-top: 96px; }
.members-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}
.member-card .member-photo {
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--gray);
  margin-bottom: 28px;
}
.member-card .member-photo img { width: 100%; height: 100%; object-fit: cover; }
/* 正方形の元写真用: 中央基準だと頭が切れるため上端基準で切り抜く */
.member-card .member-photo img.crop-top { object-position: center top; }
.member-role {
  font-family: var(--font-en);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.2em;
  color: var(--brand);
  margin-bottom: 6px;
}
.member-name {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--ink);
  margin-bottom: 18px;
}

/* ---------- Company ---------- */
.company-table { margin-top: 40px; }
.company-table > div {
  display: flex;
  padding: 22px 8px;
  border-bottom: 1px solid #e3ddda;
}
.company-table > div:first-child { border-top: 1px solid #e3ddda; }
.company-table dt { flex: 0 0 170px; font-size: 14px; font-weight: 700; letter-spacing: 0.08em; color: var(--ink); }
.company-table dd { font-size: 14px; letter-spacing: 0.05em; }

/* ---------- Contact band ---------- */
.contact .title-lg { margin-bottom: 24px; }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--gray); padding: 56px 32px; }
.footer-inner {
  max-width: 1120px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.footer-logo { font-family: var(--font-en); font-size: 18px; font-weight: 600; letter-spacing: 0.1em; color: var(--ink); }
.footer-nav { display: flex; gap: 28px; flex-wrap: wrap; }
.footer-nav a { font-family: var(--font-en); font-size: 12px; font-weight: 500; letter-spacing: 0.12em; color: var(--ink); }
.footer-nav a:hover { color: var(--brand); }
.footer-copy { font-family: var(--font-en); font-size: 11px; letter-spacing: 0.1em; color: var(--muted); }

/* ---------- News ---------- */
.news-section { padding: 64px 0; background: var(--bg-alt); }
.news-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  margin-bottom: 28px;
}
.news-heading { margin-bottom: 0; }
.news-all {
  font-family: var(--font-en);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--brand);
  white-space: nowrap;
  padding-bottom: 4px;
}
.news-all:hover { text-decoration: underline; }
.news-list { list-style: none; }
.news-list li { border-bottom: 1px solid #e3ddda; }
.news-list li:first-child { border-top: 1px solid #e3ddda; }
.news-list a {
  display: flex;
  align-items: baseline;
  gap: 20px;
  padding: 20px 8px;
  transition: background 0.2s ease;
}
.news-list a:hover { background: rgba(252, 24, 61, 0.04); }
.news-list a:hover .news-title-text { color: var(--brand); }
.news-date {
  font-family: var(--font-en);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--muted);
  flex: 0 0 auto;
}
.news-cat {
  flex: 0 0 auto;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--brand);
  border: 1px solid currentColor;
  border-radius: 20px;
  padding: 2px 12px;
  line-height: 1.7;
  white-space: nowrap;
}
.news-title-text {
  font-size: 14px;
  letter-spacing: 0.05em;
  line-height: 1.7;
  color: var(--ink);
  transition: color 0.2s ease;
}
.news-empty { padding: 20px 8px; font-size: 14px; color: var(--muted); }
.news-back { margin-top: 40px; }
.news-back a { font-size: 14px; font-weight: 700; color: var(--brand); }
.news-back a:hover { text-decoration: underline; }

/* ---------- News pages (一覧・記事) ---------- */
.page-hero {
  margin-top: var(--header-h);
  background: linear-gradient(160deg, var(--brand) 0%, #e91437 100%);
  padding: 72px 0 64px;
}
.page-hero-title { margin-bottom: 0; }
.news-page { padding: 80px 0 112px; }
.news-content { width: calc(100% - (var(--page-gutter) * 2)); max-width: var(--news-content-max-w); margin-left: auto; margin-right: auto; padding-left: 0; padding-right: 0; }
.news-subheader { border-bottom: 1px solid #e3ddda; background: #fff; }
.news-subheader .container { display: flex; justify-content: flex-end; padding-top: 14px; padding-bottom: 14px; }
.news-subheader a { color: var(--text); font-family: var(--font-en); font-size: 12px; font-weight: 600; letter-spacing: 0.1em; text-decoration: none; }
.news-subheader a:hover { color: var(--brand); }
.article { padding-top: 0; padding-bottom: 0; }
.article-meta {
  display: flex;
  align-items: baseline;
  gap: 16px;
  margin-bottom: 20px;
}
.article-title { margin-bottom: 40px; }
.article-body p { font-size: 15px; letter-spacing: 0.06em; margin-bottom: 1.6em; }
.article-body img { border-radius: var(--radius); margin: 8px 0 32px; }
.article-h2 {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--ink);
  margin: 48px 0 16px;
}

/* =========================================================
   Responsive
   ========================================================= */
@media (max-width: 960px) {
  .section { padding: 80px 0; }
  .section.band { padding: 72px 0; }
  .title-lg { font-size: 32px; }
  .title-md { font-size: 25px; }

  .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .about-visual { max-width: 420px; margin: 0 auto; }

  .service-cards { grid-template-columns: 1fr; max-width: 520px; margin-left: auto; margin-right: auto; }

  .work-grid, .work-grid.reverse { grid-template-columns: 1fr; gap: 56px; }
  .work-grid.reverse .work-visual { order: 0; }
  .work-visual { max-width: 560px; }

  .members-grid { grid-template-columns: 1fr; gap: 56px; }
}

@media (max-width: 768px) {
  :root { --page-gutter: 24px; }
  .header-nav { display: none; }
  .menu-toggle { display: flex; }
  .pc-only { display: none; }

  .news-list a { flex-wrap: wrap; gap: 8px 14px; }
  .news-title-text { flex-basis: 100%; }
  .page-hero { padding: 48px 0 40px; }

  /* モバイルも元サイト同様ファーストビューを赤で埋める（元: .billboard は 70vh/最低420px）。
     内容が増えたときは伸びるよう min-height で指定 */
  .hero { min-height: calc(100vh - var(--header-h)); min-height: calc(100svh - var(--header-h)); padding: 64px 24px; }
  .hero-lead { font-size: 13.5px; }
  .hero-ctas .btn { width: 100%; max-width: 320px; }

  .container { padding: 0 24px; }
  .company-table > div { display: block; padding: 20px 8px; }
  .company-table dt, .company-table dd { display: block; margin: 0; padding: 0; }
  .company-table dd { margin: 8px 0 0; }
  .footer-inner { flex-direction: column; text-align: center; }
}

/* --------------------------------------------------------------------------
   日本語の改行制御（3サイト共通。2026-07-16 WEALL LPから横展開）
   日本語は単語の途中でも改行できるため、「比較し／て、」のように意味の切れ目でない
   ところで行が変わって読みづらくなる。対策は2段構え:
   1) .ph = 文節のかたまり。inline-block なので、その行に入りきらないときだけ
      かたまりごと次の行へ送られる（かたまりの途中では改行されない）
      → 見出し・リード文・注記・表のセル・箇条書きなど「短い表示テキスト」に付ける
      → 本文の長い段落には付けない（行末の余白がバラつき逆に読みにくくなる）。
        最後の一文だけ .ph で包み、「ます。」だけが残るのを防ぐ
   2) text-wrap の balance / pretty（対応ブラウザのみ効く保険。未対応でも1)で崩れない）
   ※ display:flex の要素の直下に .ph を置くと各文節がflexアイテムになって崩れる。
      テキストを span でひと包みしてから中で .ph に分けること
   ※ 監査ツール: projects/website-migration/tools/line-break-audit.js
   -------------------------------------------------------------------------- */
.ph { display: inline-block; }
h1, h2, h3 { text-wrap: balance; }
p, li, summary, td, th { text-wrap: pretty; }
table th { word-break: keep-all; }

/* データから差し込むテキスト（.ph を手で入れられない箇所）は、
   対応ブラウザの自動文節改行に任せる。未対応ブラウザは従来どおり（実害なし） */
@supports (word-break: auto-phrase) {
  /* 対応ブラウザ（Chrome/Edge）では、文節を判定して自動で改行位置を選んでくれる。
     .ph を手で入れられないデータ差し込みのテキスト（人名・イベント名・お知らせ等）にも効くよう、
     ページ全体に適用する。未対応ブラウザは従来どおりで、.ph 側の制御は変わらない */
  body { word-break: auto-phrase; }
}
