/* ============================================================
   totop corporate site — mock v1
   白 × ティール × 上質ゴシック（明朝はミッションのみ）。品と清潔感、控えめなモーション。
   ============================================================ */

:root {
  --teal: #2CB8B7;          /* ブランドティール（背景・アクセント用） */
  --teal-ink: #17817F;      /* テキスト用ティール（コントラスト確保） */
  --teal-light: #A6D9D8;
  --teal-pale: #ECF7F7;
  --ink: #363332;
  --ink-soft: #5C5856;
  --gray: #6E6A67;   /* 補足文字。グレージュ地でも読めるコントラスト */
  --line: #E9E9E9;
  --bg: #FFFFFF;
  --serif: "Noto Serif JP", "Hiragino Mincho ProN", serif;   /* ミッション等のアクセント専用 */
  --head: "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Yu Gothic", "Noto Sans JP", sans-serif;
  --en: "Inter", "Helvetica Neue", sans-serif;
  --logo: "Jost", "Futura", "Inter", sans-serif;   /* totopロゴ＝Futura系幾何学サンセリフに近似 */
  --sans: "Noto Sans JP", "Hiragino Kaku Gothic ProN", sans-serif;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --header-h: 72px;
}

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

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

body {
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.9;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  letter-spacing: 0.02em;
}

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

.container { max-width: 1080px; margin: 0 auto; padding: 0 24px; }

.sp-only { display: none; }
@media (max-width: 767px) {
  .sp-only { display: inline; }
  .pc-only { display: none; }
}

/* ---------- 見出し共通 ---------- */
.sec-label {
  font-family: var(--logo);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--teal-ink);
  margin-bottom: 10px;
}
.sec-label.light { color: var(--teal-ink); }
.sec-title {
  font-family: var(--head);
  font-weight: 700;
  font-size: clamp(26px, 3.4vw, 34px);
  line-height: 1.5;
  letter-spacing: 0.04em;
  font-feature-settings: "palt";
  margin-bottom: 44px;
}

/* ---------- ボタン ---------- */
.btn-primary {
  display: inline-block;
  background: var(--teal);
  color: #fff;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.08em;
  padding: 15px 40px;
  border-radius: 4px;
  transition: background-color 0.25s var(--ease), transform 0.25s var(--ease);
  cursor: pointer;
}
.btn-primary:hover { background: #249D9C; transform: translateY(-1px); }
.btn-primary.large { padding: 18px 56px; font-size: 16px; }

.btn-text {
  display: inline-block;
  position: relative;
  font-weight: 500;
  color: var(--teal-ink);
  padding: 4px 2px;
  cursor: pointer;
}
.btn-text::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.3s var(--ease);
}
.btn-text:hover::after { transform: scaleX(1); transform-origin: left; }

.arrow { display: inline-block; transition: transform 0.25s var(--ease); }

/* ============================================================
   オープニング
   ============================================================ */
#opening {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.45s ease;
}
#opening.closing { opacity: 0; pointer-events: none; }
#opening.hidden { display: none; }

.op-stage { position: relative; text-align: center; }

.op-line {
  font-family: var(--logo);
  font-weight: 600;
  font-size: clamp(28px, 5vw, 52px);
  letter-spacing: 0.04em;
  color: var(--ink);
  white-space: nowrap;
  transition: opacity 0.35s ease;
}
.op-line.fade { opacity: 0; }
.op-line .tk { display: inline-block; white-space: nowrap; }
.op-line .ch {
  display: inline-block;
  opacity: 0;
  transform: translateY(0.35em);
  animation: opChIn 0.38s var(--ease) forwards;
  animation-delay: var(--d, 0s);
}
@keyframes opChIn {
  to { opacity: 1; transform: translateY(0); }
}
.op-line .tk.drop { overflow: hidden; vertical-align: bottom; transition: opacity 0.4s ease; }
.op-line.merge .tk.drop { opacity: 0; }

.op-logo {
  position: absolute;
  top: 50%; left: 50%;
  width: clamp(160px, 24vw, 240px);
  transform: translate(-50%, -50%) scale(0.92);
  opacity: 0;
  transition: opacity 0.4s ease, transform 0.45s var(--ease);
}
#opening.logo .op-logo { opacity: 1; transform: translate(-50%, -50%) scale(1); }

.op-sub {
  position: absolute;
  bottom: 34px; left: 0; right: 0;
  text-align: center;
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--gray);
}
.op-skip {
  position: absolute;
  top: 24px; right: 28px;
  background: none;
  border: none;
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: 0.15em;
  color: var(--gray);
  cursor: pointer;
  padding: 8px 12px;
}
.op-skip:hover { color: var(--ink); }

@media (prefers-reduced-motion: reduce) {
  #opening { display: none; }
  html { scroll-behavior: auto; }
}

/* ============================================================
   ヘッダー
   ============================================================ */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s ease;
}
.site-header.scrolled { border-bottom-color: var(--line); }

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: var(--header-h);
  display: flex;
  align-items: center;
  gap: 32px;
}
.brand img { width: 142px; height: auto; }

.gnav { margin-left: auto; }
.gnav > ul { display: flex; gap: 4px; }
.gnav > ul > li { position: relative; }
.gnav > ul > li > a {
  display: inline-block;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 500;
  position: relative;
}
.gnav > ul > li > a::after {
  content: "";
  position: absolute;
  left: 14px; right: 14px; bottom: 4px;
  height: 2px;
  background: var(--teal);
  transform: scaleX(0);
  transition: transform 0.25s var(--ease);
}
.gnav > ul > li > a:hover::after { transform: scaleX(1); }

.drop {
  position: absolute;
  top: 100%; left: 0;
  min-width: 220px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px 0;
  box-shadow: 0 8px 24px rgba(54, 51, 50, 0.08);
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: opacity 0.25s ease, transform 0.25s var(--ease), visibility 0.25s;
}
.has-drop:hover .drop,
.has-drop:focus-within .drop { opacity: 1; visibility: visible; transform: translateY(0); }
.drop a {
  display: block;
  padding: 9px 20px;
  font-size: 13px;
  transition: background-color 0.2s ease, color 0.2s ease;
}
.drop a:hover { background: var(--teal-pale); color: var(--teal-ink); }

.header-cta {
  background: var(--teal);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  padding: 10px 22px;
  border-radius: 4px;
  transition: background-color 0.25s ease;
  white-space: nowrap;
}
.header-cta:hover { background: #249D9C; }

.menu-btn { display: none; }
.sp-menu { display: none; }

@media (max-width: 900px) {
  .gnav, .header-cta { display: none; }
  .menu-btn {
    display: block;
    margin-left: auto;
    width: 44px; height: 44px;
    background: none;
    border: none;
    position: relative;
    cursor: pointer;
  }
  .menu-btn span {
    position: absolute;
    left: 10px; right: 10px;
    height: 2px;
    background: var(--ink);
    transition: transform 0.3s var(--ease), top 0.3s var(--ease);
  }
  .menu-btn span:nth-child(1) { top: 17px; }
  .menu-btn span:nth-child(2) { top: 26px; }
  .menu-btn.open span:nth-child(1) { top: 21px; transform: rotate(30deg); }
  .menu-btn.open span:nth-child(2) { top: 21px; transform: rotate(-30deg); }

  .sp-menu {
    display: block;
    position: fixed;
    top: var(--header-h); left: 0; right: 0; bottom: 0;
    background: #fff;
    padding: 16px 28px 40px;
    overflow-y: auto;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.3s ease, transform 0.3s var(--ease), visibility 0.3s;
  }
  .sp-menu.open { opacity: 1; visibility: visible; transform: translateY(0); }
  .sp-menu a { display: block; padding: 13px 4px; font-size: 15px; font-weight: 500; border-bottom: 1px solid var(--line); }
  .sp-label { font-size: 12px; font-weight: 700; letter-spacing: 0.18em; color: var(--teal-ink); padding: 18px 0 6px; }
  .sp-divider { height: 18px; }
  .sp-contact a { border: none; margin-top: 20px; background: var(--teal); color: #fff; text-align: center; border-radius: 4px; padding: 15px; }
}

/* ============================================================
   ファーストビュー（動画背景＋オーバーレイ）
   ============================================================ */
.hero {
  position: relative;
  min-height: min(88vh, 780px);
  display: flex;
  align-items: center;
  padding: calc(var(--header-h) + 48px) 0 96px;
  overflow: hidden;
  color: #fff;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  /* 動画が入るまでのプレースホルダー：深いティールグレーに光がゆっくり動く */
  background:
    radial-gradient(ellipse 900px 600px at 78% 30%, rgba(44, 184, 183, 0.28), transparent 60%),
    radial-gradient(ellipse 700px 500px at 15% 85%, rgba(44, 184, 183, 0.14), transparent 60%),
    linear-gradient(160deg, #202B2B 0%, #17211F 55%, #1C2827 100%);
}
.hero-bg::before {
  content: "";
  position: absolute;
  inset: -20%;
  background: radial-gradient(ellipse 600px 420px at 50% 50%, rgba(166, 217, 216, 0.12), transparent 65%);
  animation: heroGlow 14s ease-in-out infinite alternate;
}
@keyframes heroGlow {
  from { transform: translate(-6%, -4%); }
  to   { transform: translate(8%, 6%); }
}

.hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* 右下のAIウォーターマークを画面外に追い出すクロップ（本番はffmpegで焼き直し推奨） */
  transform: scale(1.22);
  transform-origin: 10% 15%;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(24, 30, 30, 0.58) 0%, rgba(24, 30, 30, 0.42) 55%, rgba(24, 30, 30, 0.62) 100%);
}

.hero-content { position: relative; }
.hero-en {
  font-family: var(--logo);
  font-weight: 500;
  font-size: 14px;
  letter-spacing: 0.1em;
  text-transform: none;
  color: var(--teal-light);
  margin-bottom: 24px;
}
.hero h1 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(34px, 5.4vw, 56px);
  line-height: 1.6;
  letter-spacing: 0.08em;
  font-feature-settings: "palt";
  margin-bottom: 28px;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.25);
}
.hero-lead {
  max-width: 600px;
  font-size: 15.5px;
  color: rgba(255, 255, 255, 0.88);
  margin-bottom: 40px;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.25);
}
.hero-actions { display: flex; align-items: center; gap: 32px; flex-wrap: wrap; }
.btn-text.white { color: #fff; }

.hero-scroll {
  position: absolute;
  bottom: 0;
  left: 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.hero-scroll span {
  font-size: 10px;
  letter-spacing: 0.3em;
  color: rgba(255, 255, 255, 0.7);
  writing-mode: vertical-rl;
}
.hero-scroll i {
  display: block;
  width: 1px;
  height: 56px;
  background: rgba(255, 255, 255, 0.35);
  position: relative;
  overflow: hidden;
}
.hero-scroll i::after {
  content: "";
  position: absolute;
  top: -100%;
  left: 0;
  width: 100%;
  height: 100%;
  background: #fff;
  animation: scrollLine 2.2s var(--ease) infinite;
}
@keyframes scrollLine {
  0% { top: -100%; }
  55% { top: 0; }
  100% { top: 100%; }
}

@media (max-width: 767px) {
  .hero { min-height: 82vh; padding: calc(var(--header-h) + 40px) 0 80px; }
  .hero-scroll { left: 22px; }
  .hero-scroll i { height: 40px; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-bg::before, .hero-scroll i::after { animation: none; }
  .hero-video { display: none; }
}

/* ============================================================
   課題起点の入口
   ============================================================ */
.issues { padding: 96px 0; background: #FAFCFC; }
.issue-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
.issue-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 30px 32px 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s var(--ease);
}
.issue-card:hover {
  border-color: var(--teal-light);
  box-shadow: 0 10px 28px rgba(44, 184, 183, 0.10);
  transform: translateY(-2px);
}
.issue-card:hover .arrow { transform: translateX(4px); }
.issue-q {
  font-family: var(--head);
  font-weight: 700;
  font-size: 17.5px;
  line-height: 1.7;
  letter-spacing: 0.03em;
}
.issue-q::before {
  content: "";
  display: block;
  width: 22px; height: 3px;
  background: var(--teal);
  margin-bottom: 14px;
  border-radius: 2px;
}
.issue-to { margin-top: auto; font-size: 13.5px; font-weight: 700; color: var(--teal-ink); letter-spacing: 0.04em; }
@media (max-width: 767px) {
  .issues { padding: 68px 0; }
  .issue-grid { grid-template-columns: 1fr; }
  .issue-q br { display: none; }
}

/* ============================================================
   ミッション
   ============================================================ */
.mission {
  background: var(--teal-pale);
  padding: 96px 0;
  text-align: center;
}
.mission-copy {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(24px, 3.4vw, 34px);
  line-height: 1.8;
  letter-spacing: 0.08em;
  font-feature-settings: "palt";
  margin-bottom: 26px;
}
.mission-text { font-size: 15px; color: var(--ink-soft); }
@media (max-width: 767px) { .mission { padding: 68px 0; } }

/* ============================================================
   数字
   ============================================================ */
.numbers { padding: 96px 0 40px; }
.num-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  text-align: center;
}
.num-item { padding: 12px 8px 20px; border-top: 2px solid var(--teal); }
.num-label { font-size: 14px; font-weight: 700; letter-spacing: 0.1em; margin: 18px 0 4px; }
.num-value {
  font-family: var(--en);
  font-weight: 600;
  font-feature-settings: "tnum";
  font-size: clamp(44px, 6vw, 64px);
  line-height: 1.2;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

/* スロット式カウンター（桁が回転して止まる） */
.count { display: inline-flex; align-items: flex-start; overflow: hidden; height: 1.18em; vertical-align: bottom; }
.odo-static { display: inline-block; height: 1.18em; line-height: 1.18; }
.odo-digit { display: inline-block; height: 1.18em; overflow: hidden; }
.odo-reel { display: flex; flex-direction: column; will-change: transform; }
.odo-reel span { display: block; height: 1.18em; line-height: 1.18; text-align: center; }
.num-unit { font-size: 0.42em; margin-left: 4px; color: var(--teal-ink); font-weight: 700; }
.num-note { font-size: 11.5px; color: var(--gray); margin-top: 6px; }
@media (max-width: 767px) {
  .numbers { padding: 68px 0 24px; }
  .num-grid { grid-template-columns: 1fr; gap: 8px; }
  .num-item { display: grid; grid-template-columns: 1fr; padding-bottom: 26px; }
}

/* ============================================================
   事業紹介
   ============================================================ */
.services { padding: 96px 0; }
.service-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
.service-card {
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 36px 36px 30px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: #fff;
  transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s var(--ease);
}
.service-card:hover {
  border-color: var(--teal-light);
  box-shadow: 0 10px 28px rgba(44, 184, 183, 0.10);
  transform: translateY(-2px);
}
.service-card:hover .arrow { transform: translateX(4px); }
.service-num {
  font-family: var(--en);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.2em;
  color: var(--teal-ink);
}
.service-card h3 {
  font-family: var(--head);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: 0.03em;
  line-height: 1.5;
}
.service-card p { font-size: 14.5px; color: var(--ink-soft); }
.service-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.service-tags span {
  font-size: 12px;
  font-weight: 500;
  color: var(--teal-ink);
  background: var(--teal-pale);
  border-radius: 999px;
  padding: 3px 14px;
}
.card-link { margin-top: auto; font-size: 13.5px; font-weight: 700; color: var(--teal-ink); }
@media (max-width: 767px) {
  .services { padding: 68px 0; }
  .service-grid { grid-template-columns: 1fr; }
  .service-card { padding: 28px 24px 24px; }
}

/* ============================================================
   支援事例
   ============================================================ */
.cases { padding: 96px 0; background: #FAFCFC; }
.case-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.case-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 30px 28px 28px;
}
.case-tag {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 13px;
  font-weight: 700;
  color: var(--teal-ink);
  border-bottom: 1px solid var(--line);
  padding-bottom: 14px;
  margin-bottom: 18px;
}
.case-tag span { font-size: 11.5px; font-weight: 400; color: var(--gray); }
.case-card h3 {
  font-family: var(--head);
  font-weight: 700;
  font-size: 16.5px;
  line-height: 1.7;
  letter-spacing: 0.03em;
  margin-bottom: 12px;
}
.case-card p { font-size: 13.5px; color: var(--ink-soft); }
.case-note {
  margin-top: 32px;
  font-size: 12.5px;
  color: var(--gray);
  text-align: center;
}
@media (max-width: 900px) { .case-grid { grid-template-columns: 1fr; } }
@media (max-width: 767px) { .cases { padding: 68px 0; } }

/* ============================================================
   特徴
   ============================================================ */
.strengths { padding: 96px 0; }
.strength-list { display: flex; flex-direction: column; }
.strength-item {
  display: flex;
  gap: 36px;
  padding: 34px 8px;
  border-bottom: 1px solid var(--line);
}
.strength-item:first-child { border-top: 1px solid var(--line); }
.strength-num {
  font-family: var(--en);
  font-weight: 500;
  font-size: 15px;
  letter-spacing: 0.15em;
  color: var(--teal-ink);
  padding-top: 6px;
}
.strength-item h3 {
  font-family: var(--head);
  font-weight: 700;
  font-size: 19px;
  letter-spacing: 0.04em;
  line-height: 1.6;
  margin-bottom: 8px;
}
.strength-item p { font-size: 14.5px; color: var(--ink-soft); max-width: 720px; }
@media (max-width: 767px) {
  .strengths { padding: 68px 0; }
  .strength-item { flex-direction: column; gap: 8px; padding: 26px 4px; }
}

/* ============================================================
   コラム
   ============================================================ */
.column { padding: 96px 0; background: #FAFCFC; }
.column-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.column-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 26px 26px 24px;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}
.column-card:hover { border-color: var(--teal-light); box-shadow: 0 8px 20px rgba(44, 184, 183, 0.08); }
.column-date { font-size: 12px; color: var(--gray); letter-spacing: 0.08em; margin-bottom: 10px; }
.column-card h3 { font-size: 14.5px; font-weight: 500; line-height: 1.75; }
@media (max-width: 900px) { .column-grid { grid-template-columns: 1fr; } }
@media (max-width: 767px) { .column { padding: 68px 0; } }

/* ============================================================
   会社概要
   ============================================================ */
.company { padding: 96px 0; }
.company-table { max-width: 760px; }
.company-table > div {
  display: grid;
  grid-template-columns: 160px 1fr;
  padding: 20px 8px;
  border-bottom: 1px solid var(--line);
  font-size: 14.5px;
}
.company-table > div:first-child { border-top: 1px solid var(--line); }
.company-table dt { font-weight: 700; color: var(--ink-soft); }
.company-more { margin-top: 28px; }
@media (max-width: 767px) {
  .company { padding: 68px 0; }
  .company-table > div { grid-template-columns: 1fr; gap: 2px; padding: 14px 4px; }
}

/* ============================================================
   CTA
   ============================================================ */
.cta {
  background: linear-gradient(135deg, #249D9C 0%, var(--teal) 100%);
  padding: 88px 0;
  text-align: center;
  color: #fff;
}
.cta-copy {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(24px, 3.2vw, 32px);
  letter-spacing: 0.08em;
  font-feature-settings: "palt";
  margin-bottom: 16px;
}
.cta-text { font-size: 14.5px; opacity: 0.92; margin-bottom: 36px; }
.cta .btn-primary { background: #fff; color: var(--teal-ink); }
.cta .btn-primary:hover { background: var(--teal-pale); }
@media (max-width: 767px) { .cta { padding: 64px 0; } }

/* ============================================================
   フッター
   ============================================================ */
.site-footer { padding: 72px 0 0; border-top: 1px solid var(--line); }
.footer-inner {
  display: flex;
  gap: 64px;
  flex-wrap: wrap;
  padding-bottom: 48px;
}
.footer-brand p { font-size: 12.5px; color: var(--gray); margin-top: 16px; line-height: 1.8; }
.footer-nav { display: flex; gap: 48px; flex-wrap: wrap; margin-left: auto; }
.footer-nav a { font-size: 13px; color: var(--ink-soft); display: inline-block; padding: 5px 0; transition: color 0.2s ease; }
.footer-nav a:hover { color: var(--teal-ink); }
.copyright {
  text-align: center;
  font-size: 11.5px;
  letter-spacing: 0.12em;
  color: var(--gray);
  padding: 20px 0 26px;
  border-top: 1px solid var(--line);
}
@media (max-width: 767px) {
  .footer-inner { flex-direction: column; gap: 32px; }
  .footer-nav { margin-left: 0; gap: 28px; }
}

/* ============================================================
   スクロールリビール
   ============================================================ */
html.js .reveal,
html.js .reveal-group > * {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
html.js .reveal.visible,
html.js .reveal-group.visible > * { opacity: 1; transform: translateY(0); }
.reveal-group.visible > *:nth-child(2) { transition-delay: 0.08s; }
.reveal-group.visible > *:nth-child(3) { transition-delay: 0.16s; }
.reveal-group.visible > *:nth-child(4) { transition-delay: 0.24s; }

@media (prefers-reduced-motion: reduce) {
  html.js .reveal, html.js .reveal-group > * { opacity: 1; transform: none; transition: none; }
  .btn-primary, .issue-card, .service-card { transition: none; }
}

/* ---------- フォーカス可視化 ---------- */
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--teal-ink);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ============================================================
   追加v2：タイルモチーフ／マスクリビール／devフォントパネル
   ============================================================ */

/* ---------- ロゴのタイルモチーフ ---------- */
/* セクションラベル横の小マーク */
.sec-label::before {
  content: "";
  display: inline-block;
  width: 15px;
  height: 15px;
  margin-right: 9px;
  vertical-align: -2px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 22'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='1' y2='1'%3E%3Cstop offset='0' stop-color='%232CB8B7'/%3E%3Cstop offset='1' stop-color='%236FD4D3'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect x='0' y='0' width='9.5' height='9.5' rx='2.6' fill='url(%23g)'/%3E%3Crect x='0' y='12' width='9.5' height='9.5' rx='2.6' fill='url(%23g)'/%3E%3Crect x='12' y='12' width='9.5' height='9.5' rx='2.6' fill='url(%23g)'/%3E%3Crect x='12.9' y='0.9' width='7.8' height='7.8' rx='2' fill='%23A6D9D8' transform='rotate(45 16.8 4.8)'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
}

/* ミッション・CTAの背景に大きく薄く敷く */
.mission { position: relative; overflow: hidden; }
.mission::after {
  content: "";
  position: absolute;
  right: -46px;
  bottom: -46px;
  width: 230px;
  height: 230px;
  opacity: 0.4;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 22'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='1' y2='1'%3E%3Cstop offset='0' stop-color='%232CB8B7' stop-opacity='0.35'/%3E%3Cstop offset='1' stop-color='%236FD4D3' stop-opacity='0.2'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect x='0' y='0' width='9.5' height='9.5' rx='2.6' fill='url(%23g)'/%3E%3Crect x='0' y='12' width='9.5' height='9.5' rx='2.6' fill='url(%23g)'/%3E%3Crect x='12' y='12' width='9.5' height='9.5' rx='2.6' fill='url(%23g)'/%3E%3Crect x='12.9' y='0.9' width='7.8' height='7.8' rx='2' fill='%23A6D9D8' fill-opacity='0.5' transform='rotate(45 16.8 4.8)'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
}

.cta { position: relative; overflow: hidden; }
.cta::after {
  content: "";
  position: absolute;
  left: -40px;
  top: -40px;
  width: 200px;
  height: 200px;
  opacity: 0.14;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 22'%3E%3Crect x='0' y='0' width='9.5' height='9.5' rx='2.6' fill='white'/%3E%3Crect x='0' y='12' width='9.5' height='9.5' rx='2.6' fill='white'/%3E%3Crect x='12' y='12' width='9.5' height='9.5' rx='2.6' fill='white'/%3E%3Crect x='12.9' y='0.9' width='7.8' height='7.8' rx='2' fill='white' fill-opacity='0.6' transform='rotate(45 16.8 4.8)'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
}

/* ---------- 見出しマスクリビール ---------- */
/* .sec-title は全体フェードでなく、行ブロックが下からすっと現れる */
.sec-title.reveal { opacity: 1; transform: none; overflow: hidden; }
.sec-title.reveal .mr {
  display: block;
  transform: translateY(110%);
  transition: transform 0.85s var(--ease);
}
.sec-title.reveal.visible .mr { transform: translateY(0); }

/* ヒーロー見出し：オープニングが閉じたタイミングで立ち上がる */
.hero h1 { overflow: hidden; }
.hero h1 .mr {
  display: block;
  transform: translateY(108%);
  transition: transform 0.9s var(--ease) 0.1s;
}
body.opened .hero h1 .mr { transform: translateY(0); }
html.js .hero-en, html.js .hero-lead, html.js .hero-actions {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.7s ease 0.35s, transform 0.7s var(--ease) 0.35s;
}
body.opened .hero-en, body.opened .hero-lead, body.opened .hero-actions {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .sec-title.reveal .mr, .hero h1 .mr { transform: none; transition: none; }
  .hero-en, .hero-lead, .hero-actions { opacity: 1; transform: none; transition: none; }
}

/* ---------- devフォント切替パネル（本番では削除） ---------- */
.dev-font {
  position: fixed;
  right: 14px;
  bottom: 14px;
  z-index: 500;
  background: rgba(30, 34, 34, 0.92);
  color: #fff;
  border-radius: 6px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
}
.dev-font p { letter-spacing: 0.06em; margin-right: 4px; opacity: 0.7; }
.dev-font button {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 4px;
  font-size: 11px;
  padding: 5px 10px;
  cursor: pointer;
}
.dev-font button.active { background: var(--teal); border-color: var(--teal); }

/* devパネル：区切りと動画切替 */
.dev-sep { width: 1px; height: 18px; background: rgba(255,255,255,0.25); margin: 0 4px; }

/* ============================================================
   追加v3：オープニング作り替え（クロスフェード式・確実に動く）
   タイムライン: s1 全文表示 → s2 中間ワード消灯 → s3 totopへ凝縮 → s4 ロゴ
   ============================================================ */
.op-a {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.65s ease, transform 0.75s cubic-bezier(0.22, 0.61, 0.36, 1);
}
#opening.s1 .op-a { opacity: 1; transform: translateY(0); }
.op-a .d { transition: opacity 0.45s ease; }
#opening.s2 .op-a .d { opacity: 0; }
#opening.s3 .op-a { opacity: 0; transition: opacity 0.3s ease; }

.op-b {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  letter-spacing: 0.3em;
  transition: opacity 0.5s ease, letter-spacing 0.65s cubic-bezier(0.22, 0.61, 0.36, 1);
}
#opening.s3 .op-b { opacity: 1; letter-spacing: 0.04em; }
#opening.s4 .op-b { opacity: 0; }
#opening.s4 .op-logo { opacity: 1; transform: translate(-50%, -50%) scale(1); }

/* ============================================================
   追加v3：スタイルエッジ型ヘッダー
   FV上＝透明背景・白ロゴ・白リンク → スクロールで白背景・黒文字に反転
   ============================================================ */
.site-header {
  background: transparent;
  backdrop-filter: none;
  transition: background-color 0.35s ease, border-color 0.35s ease;
}
.site-header .brand img {
  filter: brightness(0) invert(1);   /* 白ロゴ化 */
  transition: filter 0.35s ease;
}
.site-header .gnav > ul > li > a { color: #fff; transition: color 0.35s ease; }
.site-header .menu-btn span { background: #fff; }

.site-header.scrolled,
.site-header.menu-open {
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(8px);
  border-bottom-color: var(--line);
}
.site-header.scrolled .brand img,
.site-header.menu-open .brand img { filter: none; }
.site-header.scrolled .gnav > ul > li > a,
.site-header.menu-open .gnav > ul > li > a { color: var(--ink); }
.site-header.scrolled .menu-btn span,
.site-header.menu-open .menu-btn span { background: var(--ink); }

/* FVを全画面に */
.hero {
  min-height: 100vh;
  min-height: 100dvh;
}
@media (max-width: 767px) {
  .hero { min-height: 100vh; min-height: 100dvh; }
}

/* ============================================================
   追加v4：事業セクションをカード→エディトリアルリストに
   （均質な角丸カードグリッド＝AIっぽさの正体、を解体）
   ============================================================ */
.service-list { border-top: 1px solid var(--ink); }
.service-row {
  display: grid;
  grid-template-columns: 90px 300px 1fr 48px;
  align-items: center;
  gap: 32px;
  padding: 44px 8px;
  border-bottom: 1px solid var(--line);
  position: relative;
  transition: padding-left 0.35s var(--ease);
}
.service-row::before {
  content: "";
  position: absolute;
  left: 0; top: -1px; bottom: -1px;
  width: 0;
  background: var(--teal-pale);
  transition: width 0.4s var(--ease);
  z-index: -1;
}
.service-row:hover::before { width: 100%; }
.service-row:hover { padding-left: 20px; }
.service-row:hover .sr-arrow { transform: translateX(6px); color: var(--teal-ink); }

.sr-num {
  font-family: var(--logo);
  font-weight: 500;
  font-size: clamp(28px, 3.2vw, 40px);
  color: var(--teal);
  line-height: 1;
}
.sr-en {
  display: block;
  font-family: var(--logo);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray);
  margin-bottom: 6px;
}
.sr-head h3 {
  font-family: var(--head);
  font-weight: 700;
  font-size: clamp(20px, 2.4vw, 26px);
  letter-spacing: 0.03em;
  line-height: 1.4;
}
.sr-desc { font-size: 14px; color: var(--ink-soft); line-height: 1.9; }
.sr-tags { display: inline-flex; flex-wrap: wrap; gap: 6px; margin-left: 10px; vertical-align: middle; }
.sr-tags span {
  font-size: 11px;
  font-weight: 500;
  color: var(--teal-ink);
  background: #fff;
  border: 1px solid var(--teal-light);
  border-radius: 999px;
  padding: 1px 12px;
}
.sr-arrow {
  font-size: 22px;
  color: var(--gray);
  justify-self: end;
  transition: transform 0.3s var(--ease), color 0.3s ease;
}

@media (max-width: 900px) {
  .service-row {
    grid-template-columns: 56px 1fr 32px;
    grid-template-areas:
      "num head arrow"
      "num desc arrow";
    gap: 8px 18px;
    padding: 30px 4px;
    align-items: start;
  }
  .sr-num { grid-area: num; font-size: 24px; padding-top: 4px; }
  .sr-head { grid-area: head; }
  .sr-desc { grid-area: desc; }
  .sr-arrow { grid-area: arrow; align-self: center; }
  .service-row:hover { padding-left: 4px; }
}

/* ============================================================
   追加v5：均質さの追加解体＋ホバーのガタつき修正
   ============================================================ */

/* 事業リスト：ホバー時のレイアウト移動を廃止（テキスト再改行のガタつき対策）。
   動くのは背景・矢印・色だけにする */
.service-row { transition: none; }
.service-row:hover { padding-left: 0; }
.service-row:hover .sr-head h3 { color: var(--teal-ink); }
.sr-head h3 { transition: color 0.3s ease; }
@media (max-width: 900px) {
  .service-row:hover { padding-left: 0; }
}

/* 見出しのジャンプ率を上げる */
.sec-title { font-size: clamp(30px, 4.2vw, 44px); }

/* ---------- 課題：左見出し固定＋右リスト（非対称2カラム） ---------- */
.issues-grid {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 72px;
  align-items: start;
}
.issues-intro { position: sticky; top: 120px; }
.issues-intro .sec-title { margin-bottom: 24px; }
.issues-lead { font-size: 14px; color: var(--ink-soft); }

.issues-list { border-top: 1px solid var(--ink); }
.issue-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding: 30px 6px;
  border-bottom: 1px solid var(--line);
}
.issue-q {
  font-family: var(--head);
  font-weight: 600;
  font-size: 16.5px;
  line-height: 1.8;
  letter-spacing: 0.02em;
  transition: color 0.3s ease;
}
.issue-q::before { content: none; }  /* 旧カード用の飾り線を無効化 */
.issue-row:hover .issue-q { color: var(--teal-ink); }
.issue-row:hover .arrow { transform: translateX(5px); }
.issue-to {
  font-family: var(--sans);
  font-size: 12.5px;
  font-weight: 700;
  color: var(--teal-ink);
  letter-spacing: 0.04em;
  white-space: nowrap;
}
@media (max-width: 900px) {
  .issues-grid { grid-template-columns: 1fr; gap: 36px; }
  .issues-intro { position: static; }
  .issue-row { flex-direction: column; align-items: flex-start; gap: 10px; padding: 22px 2px; }
}

/* ---------- 事例：カード箱を外してエディトリアルなカラムに ---------- */
.cases { background: #fff; }
.case-card {
  background: transparent;
  border: none;
  border-top: 2px solid var(--ink);
  border-radius: 0;
  padding: 24px 4px 0;
}
.case-tag { border-bottom: none; padding-bottom: 0; margin-bottom: 14px; }

/* ============================================================
   追加v6：配色テーマ検討用（devパネルで切替・確定後に1本化）
   ============================================================ */
body.theme-warm { background: #F7F5F1; }
body.theme-warm .issues, body.theme-warm .cases, body.theme-warm .column, body.theme-warm .numbers, body.theme-warm .services, body.theme-warm .strengths, body.theme-warm .company { background: transparent; }
body.theme-warm .issue-row, body.theme-warm .service-row { border-bottom-color: #E3DfD7; }
body.theme-warm .column-card, body.theme-warm .site-footer { background: #fff; }
body.theme-warm .site-header.scrolled, body.theme-warm .site-header.menu-open { background: rgba(247, 245, 241, 0.94); }

body.theme-mist { background: #F3F8F8; }
body.theme-mist .issues, body.theme-mist .cases, body.theme-mist .column, body.theme-mist .numbers, body.theme-mist .services, body.theme-mist .strengths, body.theme-mist .company { background: transparent; }
body.theme-mist .column-card, body.theme-mist .site-footer { background: #fff; }
body.theme-mist .mission { background: #fff; }
body.theme-mist .site-header.scrolled, body.theme-mist .site-header.menu-open { background: rgba(243, 248, 248, 0.94); }

/* devパネルを2段対応に */
.dev-font { flex-wrap: wrap; max-width: 460px; justify-content: flex-end; }

/* 事業リスト内のサービスロゴ（実物感） */
.sr-logo { height: 24px; width: auto; margin-top: 12px; }
@media (max-width: 900px) { .sr-logo { height: 20px; } }

/* ============================================================
   追加v7：スマホの改行制御＋devパネル折りたたみ
   ============================================================ */

/* 見出しは文節単位でしか折り返さない（inline-blockのかたまり） */
.hero h1 .u { display: block; }   /* FVコピーは常に意図した2行で固定 */

/* 対応ブラウザでは文節改行を自動化（非対応は無視される） */
.hero h1, .sec-title, .mission-copy, .cta-copy, .issue-q, .sr-head h3 {
  word-break: auto-phrase;
}

/* SE級の狭い画面向けにFV見出しを一段小さく */
.hero h1 { font-size: clamp(28px, 5.4vw, 56px); }
@media (max-width: 380px) {
  .hero h1 { font-size: 27px; letter-spacing: 0.05em; }
  .hero-lead { font-size: 14px; }
}

/* devパネル：スマホでは「dev」ボタンだけにたたむ */
.dev-handle {
  display: none;
  background: var(--teal);
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 6px 12px;
  cursor: pointer;
}
.dev-body { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; justify-content: flex-end; }
@media (max-width: 767px) {
  .dev-font { background: none; padding: 0; max-width: none; }
  .dev-handle { display: block; margin-left: auto; }
  .dev-font:not(.open) .dev-body { display: none; }
  .dev-font.open .dev-body {
    background: rgba(30, 34, 34, 0.94);
    border-radius: 6px;
    padding: 10px 12px;
    margin-top: 8px;
  }
}

/* ============================================================
   追加v8：案D＝ホバーで実物スクショが浮かぶ（相談室の行）
   ============================================================ */
.sr-thumb {
  position: absolute;
  right: 96px;
  top: 50%;
  width: 260px;
  transform: translateY(-46%) rotate(-2deg) scale(0.96);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.45s var(--ease);
  z-index: 2;
}
.sr-thumb img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 5px;
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: 0 20px 44px rgba(28, 40, 40, 0.20);
}
.service-row:hover .sr-thumb {
  opacity: 1;
  transform: translateY(-50%) rotate(-2deg) scale(1);
}
@media (max-width: 900px) {
  /* SPはホバーが無いので小さく常時表示 */
  .sr-thumb {
    position: static;
    width: 190px;
    opacity: 1;
    transform: none;
    margin-top: 12px;
  }
}

/* 追加v9：案A＝相談室の見出しをロゴ画像に置き換え */
.sr-logo-head { line-height: 1; padding: 4px 0 6px; }
.sr-logo-head img { height: 36px; width: auto; display: block; }
@media (max-width: 900px) { .sr-logo-head img { height: 28px; } }

/* ============================================================
   追加v10：SPの事業リストを組み直し（左右バランス改善）
   番号＋ラベルを上段に、説明文は全幅。矢印はSPでは非表示
   ============================================================ */
@media (max-width: 900px) {
  .service-row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 0 14px;
    padding: 30px 2px;
  }
  .sr-num { font-size: 19px; padding-top: 3px; }
  .sr-head { flex: 1; min-width: 0; }
  .sr-desc { flex-basis: 100%; margin-top: 12px; }
  .sr-arrow { display: none; }
  .sr-tags { display: flex; margin-left: 0; margin-top: 8px; }
}

/* ============================================================
   追加v11：重厚感＝明暗のリズム
   FV(暗) → 明 → ミッション(深緑黒) → 明 → CTA・フッター(暗)
   ============================================================ */

/* ---- ミッション：淡ティール → 深いティールチャコール ---- */
.mission {
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 240 240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.05 0'/%3E%3C/filter%3E%3Crect width='240' height='240' filter='url(%23n)'/%3E%3C/svg%3E"),
    linear-gradient(155deg, #2C4A46 0%, #223D39 60%, #28453F 100%);
  padding: 116px 0;
}
.mission .sec-label { color: var(--teal-light); }
.mission-copy { color: #fff; }
.mission-text { color: rgba(255, 255, 255, 0.72); }
.mission::after { opacity: 0.5; }

/* ---- CTA：ティールグラデ → 深緑黒＋質感 ---- */
.cta {
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 240 240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.04 0'/%3E%3C/filter%3E%3Crect width='240' height='240' filter='url(%23n)'/%3E%3C/svg%3E"),
    linear-gradient(160deg, #27433E 0%, #1D3531 100%);
  padding: 104px 0;
}
.cta .btn-primary { background: var(--teal); color: #fff; }
.cta .btn-primary:hover { background: #35C6C5; }
.cta-text { opacity: 0.78; }

/* ---- フッター：暗色で締める ---- */
.site-footer {
  background: #18221F;   /* CTA(深緑)より一段暗く、階調で沈ませる */
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  border-top: none;
  padding-top: 76px;
}
.site-footer .footer-brand img { filter: brightness(0) invert(1); opacity: 0.92; }
.footer-brand p { color: rgba(255, 255, 255, 0.55); }
.footer-nav a { color: rgba(255, 255, 255, 0.72); }
.footer-nav a:hover { color: var(--teal-light); }
.copyright { color: rgba(255, 255, 255, 0.4); border-top: 1px solid rgba(255, 255, 255, 0.10); }
body.theme-warm .site-footer, body.theme-mist .site-footer { background: #18221F; }

/* ダーク帯の上では数字スロットやテキスト選択色が沈まないように */
.mission ::selection, .cta ::selection { background: rgba(44, 184, 183, 0.5); color: #fff; }

/* ============================================================
   追加v12：レビュー3rd反映（FVの可読性・高さ・ヘッダーscrim）
   ============================================================ */

/* 重大3: 動画の明暗に依存せず白ナビが読めるよう、上部に薄い暗色scrim */
.hero::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 180px;
  background: linear-gradient(180deg, rgba(8, 14, 14, 0.42), transparent);
  z-index: 0;
  pointer-events: none;
}

/* 重大2: テキストが乗る左下に局所的な暗がりを足してリード文を沈める */
.hero-overlay {
  background:
    radial-gradient(ellipse 680px 520px at 24% 66%, rgba(10, 16, 16, 0.5), transparent 70%),
    linear-gradient(180deg, rgba(24, 30, 30, 0.5) 0%, rgba(24, 30, 30, 0.4) 55%, rgba(24, 30, 30, 0.6) 100%);
}

/* FVは縦100%のフルスクリーン表示（内田確定） */
.hero { min-height: 100vh; min-height: 100svh; }
@media (max-width: 767px) {
  .hero { min-height: 100svh; }
}

/* ============================================================
   追加v13：ダーク帯の色パターン検討用（devパネルで切替）
   ============================================================ */
/* B: チャコール（無彩色寄りの重厚） */
body.dark-b .mission { background: linear-gradient(155deg, #2E3336 0%, #24292C 60%, #2A2F32 100%); }
body.dark-b .cta { background: linear-gradient(160deg, #282D30 0%, #1F2427 100%); }
body.dark-b .site-footer, body.theme-warm.dark-b .site-footer, body.theme-mist.dark-b .site-footer { background: #212629; }

/* C: ネイビー（青系の格調） */
body.dark-c .mission { background: linear-gradient(155deg, #2A3648 0%, #202B3B 60%, #263143 100%); }
body.dark-c .cta { background: linear-gradient(160deg, #253044 0%, #1B2536 100%); }
body.dark-c .site-footer, body.theme-warm.dark-c .site-footer, body.theme-mist.dark-c .site-footer { background: #212B3B; }

/* D: ダーク弱め（ミッションは淡ティールに戻し、CTAはティール、フッターだけ暗） */
body.dark-d .mission { background: var(--teal-pale); }
body.dark-d .mission .sec-label { color: var(--teal-ink); }
body.dark-d .mission-copy { color: var(--ink); }
body.dark-d .mission-text { color: var(--ink-soft); }
body.dark-d .cta { background: linear-gradient(135deg, #249D9C 0%, var(--teal) 100%); }

/* dark-d（CTAがティール背景）の時はボタンを白に戻す */
body.dark-d .cta .btn-primary { background: #fff; color: var(--teal-ink); }
body.dark-d .cta .btn-primary:hover { background: var(--teal-pale); }

/* 撮影検証用（?flat=1）：FVのビューポート高さ依存を解除 */
body.flat .hero { min-height: 0; padding-bottom: 80px; }

/* ============================================================
   追加v14：エディトリアル刷新（gnmd / trail / sense-trust踏襲）
   英字巨大ディスプレイ×日本語小見出しの逆転階層＋非対称＋反復
   ============================================================ */

/* 見出しの階層を逆転：英字が主役、日本語は添え */
.sec-label {
  font-family: var(--logo);
  font-size: clamp(46px, 6.5vw, 86px);
  font-weight: 500;
  letter-spacing: 0.01em;
  color: var(--ink);
  line-height: 1.05;
  margin-bottom: 4px;
}
.sec-label::before { content: none; }
.sec-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--teal-ink);
  letter-spacing: 0.14em;
  line-height: 1.6;
  margin-bottom: 52px;
}
.sec-title::before { content: "— "; color: var(--teal); }

/* ミッションだけは従来の小ラベル＋明朝コピー主役を維持 */
.mission .sec-label {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.24em;
  color: var(--teal-light);
  margin-bottom: 18px;
}

/* セクションごとに寄せを変えて非対称に */
.services .sec-label, .services .sec-title { text-align: right; }
.strengths .sec-label, .strengths .sec-title { text-align: right; }
.company .sec-label, .company .sec-title { text-align: right; }



@media (max-width: 767px) {
  .sec-label { font-size: clamp(40px, 12vw, 56px); }
  .sec-title { margin-bottom: 36px; }
  .issues-intro .sec-title { margin-bottom: 20px; }
}

/* ============================================================
   追加v15：図解・実物ビジュアル・浮きブロック・触感
   ============================================================ */

/* ① ミッションの両輪ダイアグラム */
.mission-diagram { max-width: 720px; margin: 40px auto 0; }
.mission-diagram svg { width: 100%; height: auto; display: block; }

/* ③ 深緑帯を「敷く」から「置く」へ（浮きブロック化） */
.mission {
  max-width: min(1240px, calc(100% - 40px));
  margin: 0 auto;
  border-radius: 20px;
  box-shadow: 0 30px 70px rgba(24, 40, 38, 0.16);
}
@media (max-width: 767px) {
  .mission { max-width: calc(100% - 24px); border-radius: 14px; }
}

/* ② 特徴セクションの実物ビジュアル列 */
.strengths-grid {
  display: grid;
  grid-template-columns: 1fr 350px;
  gap: 64px;
  align-items: start;
}
.strength-visual {
  position: sticky;
  top: 110px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.strength-visual figure { margin: 0; }
.strength-visual img {
  width: 100%;
  height: auto;
  display: block;
  border: 1px solid var(--line);
  border-radius: 6px;
  box-shadow: 0 16px 38px rgba(30, 40, 40, 0.12);
  background: #fff;
}
.strength-visual figcaption {
  font-size: 11.5px;
  color: var(--gray);
  margin-top: 8px;
  letter-spacing: 0.04em;
}
@media (max-width: 900px) {
  .strengths-grid { grid-template-columns: 1fr; gap: 40px; }
  .strength-visual { position: static; flex-direction: row; }
  .strength-visual figure { flex: 1; min-width: 0; }
}
@media (max-width: 600px) {
  .strength-visual { flex-direction: column; }
}

/* ④ 触感：事業リストの矢印を円ボタン化 */
.sr-arrow {
  width: 46px;
  height: 46px;
  border: 1px solid #D8D4CD;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  color: var(--gray);
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, transform 0.35s var(--ease);
}
.service-row:hover .sr-arrow {
  background: var(--teal);
  border-color: var(--teal);
  color: #fff;
  transform: translateX(4px);
}

/* ④ 触感：数字の上罫線が左から伸びる */
.num-item { border-top: none; position: relative; }
.num-item::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  height: 2px;
  width: 0;
  background: var(--teal);
  transition: width 0.9s var(--ease);
}
.num-grid.visible .num-item:nth-child(1)::before { width: 100%; transition-delay: 0.1s; }
.num-grid.visible .num-item:nth-child(2)::before { width: 100%; transition-delay: 0.25s; }
.num-grid.visible .num-item:nth-child(3)::before { width: 100%; transition-delay: 0.4s; }

/* ============================================================
   追加v16：深緑帯がスクロールで全幅に開く（peak-clinic FV風）
   clip-path方式＝中身のテキストは動かないのでガタつかない
   ============================================================ */
.mission {
  max-width: none;
  width: 100%;
  margin: 0;
  border-radius: 0;
  box-shadow: none;
  --mx: 0;
  clip-path: inset(0 calc((1 - var(--mx)) * 11%) round calc(28px * (1 - var(--mx))));
}
@media (prefers-reduced-motion: reduce) {
  .mission { clip-path: none; }
}

/* 追加v17：タイルモチーフをえぐりに追従させ、閉じても削れないように */
.mission::after {
  right: calc((1 - var(--mx, 1)) * 11% + 28px);
  bottom: 28px;
  width: 190px;
  height: 190px;
  opacity: 0.45;
}

/* 追加v18：SPのベン図は縦型に切替＋タイルの主張を抑える */
.dia-sp { display: none; }
@media (max-width: 767px) {
  .dia-pc { display: none; }
  .dia-sp { display: block; max-width: 330px; margin: 0 auto; }
  .mission-diagram { margin-top: 28px; }
  .mission::after {
    width: 96px;
    height: 96px;
    opacity: 0.28;
    right: calc((1 - var(--mx, 1)) * 11% + 18px);
    bottom: 18px;
  }
}

/* 追加v19：SPは横型ベン図をほぼ全幅で大きく表示＋文字サイズ引き上げ */
@media (max-width: 767px) {
  .mission-diagram {
    width: calc(100% + 56px);
    margin-left: -28px;
  }
  .dia-pc { display: block; }
  .dia-pc text { font-size: 15px; }
  .dia-pc text[font-weight="700"] { font-size: 20px; }
  .dia-pc text[fill="#A6D9D8"] { font-size: 15.5px; }
}

/* 追加v20：SPベン図の作り直し（v19の文字拡大は撤回し、SP専用ジオメトリで表示） */
.mission-diagram .dia-sp { display: none; }
@media (max-width: 767px) {
  .mission-diagram .dia-pc { display: none; }
  .mission-diagram .dia-sp { display: block; width: 100%; }
  /* v19の文字サイズ上書きを無効化（dia-pc非表示のため実質不要だが念のため） */
  .dia-pc text, .dia-pc text[font-weight="700"], .dia-pc text[fill="#A6D9D8"] { font-size: revert; }
}

/* ============================================================
   追加v21：内田FB反映（2026-07-05）
   ①ヒーロー英文コピーを一回り大きく ②ミッションコピーを大きく・字間は締める
   ③ミッション右下のタイルモチーフを撤去 ④事業リスト英字ラベルの全大文字化を解除（Media表記に統一）
   ============================================================ */
.hero-en { font-size: 17px; letter-spacing: 0.16em; }
.mission-copy { font-size: clamp(28px, 4.2vw, 44px); letter-spacing: 0.05em; }
.mission::after { content: none; }
.sr-en { text-transform: none; }

/* ============================================================
   追加v22：タイルモチーフの再設計（内田FB 2026-07-05）
   ルール＝3スケールのみ。①判子：見出し頭の「—」をタイル化
   ②ダーク帯の質感：白タイルを特大・角で切って超薄く（ステッカー感の逆）
   ============================================================ */
/* ①判子：セクション見出し頭 */
.sec-title::before {
  content: "";
  display: inline-block;
  width: 13px;
  height: 13px;
  margin-right: 10px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 22'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='1' y2='1'%3E%3Cstop offset='0' stop-color='%232CB8B7'/%3E%3Cstop offset='1' stop-color='%236FD4D3'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect x='0' y='0' width='9.5' height='9.5' rx='2.6' fill='url(%23g)'/%3E%3Crect x='0' y='12' width='9.5' height='9.5' rx='2.6' fill='url(%23g)'/%3E%3Crect x='12' y='12' width='9.5' height='9.5' rx='2.6' fill='url(%23g)'/%3E%3Crect x='12.9' y='0.9' width='7.8' height='7.8' rx='2' fill='%23A6D9D8' transform='rotate(45 16.8 4.8)'/%3E%3C/svg%3E") no-repeat center / contain;
}

/* ②ミッション帯：白タイルを特大・右下角で切る */
.mission::after {
  content: "";
  position: absolute;
  right: -110px;
  bottom: -110px;
  width: 430px;
  height: 430px;
  opacity: 0.07;
  pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 22'%3E%3Crect x='0' y='0' width='9.5' height='9.5' rx='2.6' fill='white'/%3E%3Crect x='0' y='12' width='9.5' height='9.5' rx='2.6' fill='white'/%3E%3Crect x='12' y='12' width='9.5' height='9.5' rx='2.6' fill='white'/%3E%3Crect x='12.9' y='0.9' width='7.8' height='7.8' rx='2' fill='white' fill-opacity='0.6' transform='rotate(45 16.8 4.8)'/%3E%3C/svg%3E") no-repeat center / contain;
}

/* ②CTA帯：既存の左上タイルを特大・角切りに更新 */
.cta::after {
  left: -130px;
  top: -130px;
  width: 400px;
  height: 400px;
  opacity: 0.08;
}

@media (max-width: 767px) {
  .sec-title::before { width: 11px; height: 11px; margin-right: 8px; }
  .mission::after { width: 260px; height: 260px; right: -80px; bottom: -80px; }
  .cta::after { width: 240px; height: 240px; left: -90px; top: -90px; }
}

/* ============================================================
   追加v23：タイルに「意味」を持たせる（内田FB 2026-07-05）
   判子はCSS背景→JS注入のインラインSVGに変更。4つ目のタイル(.t4)が
   表示時に45°回転してロゴの形に収まる＝ブランドの動きの署名。
   数字の罫線の端にも回転タイル（ダイヤ）を打つ。
   ============================================================ */
/* v22のCSS判子は廃止（JS注入のtile-markに一本化） */
.sec-title::before { content: none; }

.tile-mark {
  display: inline-block;
  width: 14px;
  height: 14px;
  margin-right: 10px;
  vertical-align: -1px;
}
.tile-mark svg { display: block; width: 100%; height: 100%; overflow: visible; }
.tile-mark .t4 {
  transform-box: fill-box;
  transform-origin: center;
  transform: rotate(0deg);
  /* 見出しが立ち上がった後、行き過ぎて戻るオーバーシュートで「くるん」と収まる */
  transition: transform 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) 0.7s;
}
/* セクションが画面に入ったら回転して収まる */
.sec-title.visible .tile-mark .t4 { transform: rotate(45deg); }
/* reveal対象でないsec-titleは最初から収まった状態 */
html.js .sec-title:not(.reveal) .tile-mark .t4 { transform: rotate(45deg); transition: none; }
/* 下層H1はページ表示直後に自動再生 */
.page-hero h1 .tile-mark .t4 { animation: tileTurn 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) 0.6s forwards; }
@keyframes tileTurn { to { transform: rotate(45deg); } }

/* 数字：罫線が伸び切った先端にダイヤが打たれる */
.num-item::after {
  content: "";
  position: absolute;
  top: -4.5px;
  right: 0;
  width: 9px;
  height: 9px;
  border-radius: 2px;
  background: var(--teal);
  transform: rotate(45deg) scale(0);
  transition: transform 0.45s var(--ease);
}
.num-grid.visible .num-item:nth-child(1)::after { transform: rotate(45deg) scale(1); transition-delay: 1.0s; }
.num-grid.visible .num-item:nth-child(2)::after { transform: rotate(45deg) scale(1); transition-delay: 1.15s; }
.num-grid.visible .num-item:nth-child(3)::after { transform: rotate(45deg) scale(1); transition-delay: 1.3s; }

@media (prefers-reduced-motion: reduce) {
  .tile-mark .t4 { transform: rotate(45deg) !important; transition: none !important; animation: none !important; }
  .num-item::after { transform: rotate(45deg) scale(1); transition: none; }
}
@media (max-width: 767px) {
  .tile-mark { width: 12px; height: 12px; margin-right: 8px; }
}

/* ============================================================
   追加v24：判子の置き場所を巨大英字見出しへ（内田FB「小さくて見つけられない」）
   サイズは見出しに比例（0.34em）。画面に入ると.turnが付き4つ目が回転
   ============================================================ */
.tile-mark {
  width: 0.34em;
  height: 0.34em;
  margin-right: 0.22em;
  vertical-align: 0.03em;
}
.tile-mark.turn .t4 { transform: rotate(45deg); }

/* ============================================================
   追加v25：SPのベン図×質感タイルの被り解消＋判子の拡大（内田FB）
   ============================================================ */
/* 判子を一回り大きく（ビュレット化しない0.5em前後を上限とする） */
.tile-mark {
  width: 0.46em;
  height: 0.46em;
  margin-right: 0.24em;
  vertical-align: 0.02em;
}
@media (max-width: 767px) {
  .tile-mark {
    width: 0.56em;
    height: 0.56em;
    margin-right: 0.26em;
  }
}

/* SP〜タブレットではミッション帯の質感タイルを消す
   （帯の主役がベン図＝意味のあるモチーフなので、質感タイルと同居させない） */
@media (max-width: 900px) {
  .mission::after { content: none; }
}

/* ============================================================
   追加v25：SP修正（内田FB 2026-07-06）
   ①ハンバーガー：backdrop-filterが固定配置の基準を狂わせsp-menuが潰れる
     → SPではすりガラスを切り、メニュー展開中は不透明背景に
   ②事業リストSP：番号＋ラベル行の右端に矢印、説明は全幅
   ③タグのピルを廃止（PC/SP共通）→ スラッシュ区切りテキストに
   ============================================================ */
@media (max-width: 900px) {
  .site-header,
  .site-header.scrolled,
  .site-header.menu-open,
  body.subpage .site-header {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
  .site-header.scrolled,
  .site-header.menu-open,
  body.subpage .site-header {
    background: #F7F5F1;
  }
  .sp-menu { height: calc(100dvh - var(--header-h)); bottom: auto; }
}

/* ③タグ：ピル→スラッシュ区切り（全幅共通） */
.sr-tags { display: inline-flex; flex-wrap: wrap; gap: 0; margin-left: 10px; }
.sr-tags span {
  background: none;
  border: none;
  border-radius: 0;
  padding: 0;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--teal-ink);
}
.sr-tags span + span::before { content: "／"; color: var(--teal-light); font-weight: 400; margin: 0 7px; }

/* ②事業リストのSPレイアウト組み直し */
@media (max-width: 900px) {
  .service-row {
    display: grid;
    grid-template-columns: auto 1fr 40px;
    grid-template-areas:
      "num head arrow"
      "desc desc desc";
    gap: 6px 14px;
    align-items: start;
    padding: 28px 2px;
  }
  .sr-num { grid-area: num; font-size: 19px; padding-top: 5px; }
  .sr-head { grid-area: head; }
  .sr-desc { grid-area: desc; margin-top: 6px; }
  .sr-arrow {
    grid-area: arrow;
    display: flex;
    width: 38px;
    height: 38px;
    font-size: 15px;
    justify-self: end;
    margin-top: 0;
  }
  .sr-tags { display: flex; margin-left: 0; margin-top: 10px; }
  .sr-thumb { position: static; width: 190px; opacity: 1; transform: none; margin-top: 12px; }
}

/* ============================================================
   追加v26：ホバーで改行が動くバグ修正（内田FB 2026-07-06）
   v5の「ズレ演出廃止」がpadding-left:0と書かれ、基本値8pxとの差分で
   ホバー時に行内容が8px広がり改行が変わっていた。基本値に一致させる
   ============================================================ */
.service-row:hover { padding-left: 8px; }
@media (max-width: 900px) {
  .service-row:hover { padding-left: 2px; }
}

/* ============================================================
   追加v27：ホバーのスライド演出を復活（改行を動かさない方式）
   paddingでなくtransformで中身だけ滑らせる＝レイアウト計算に影響しないため
   改行は固定のまま。矢印は既存の+4pxが別途効く
   ============================================================ */
.sr-num, .sr-head, .sr-desc {
  transition: transform 0.35s var(--ease);
}
.service-row:hover .sr-num,
.service-row:hover .sr-head,
.service-row:hover .sr-desc {
  transform: translateX(12px);
}
@media (max-width: 900px) {
  /* タッチ端末はホバー概念がないためスライドさせない（タップ後の張り付き防止） */
  .service-row:hover .sr-num,
  .service-row:hover .sr-head,
  .service-row:hover .sr-desc { transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .sr-num, .sr-head, .sr-desc { transition: none; }
  .service-row:hover .sr-num,
  .service-row:hover .sr-head,
  .service-row:hover .sr-desc { transform: none; }
}

/* ============================================================
   追加v29：FV候補（?fv=2）＝巨大タイル構図
   現行の全面動画FVをそのまま、画面の7〜8割を占める巨大な角丸タイル窓に
   載せ替える。構成・文字は現行と同一、形だけがととっぷ固有になる
   ============================================================ */
body.fv2 .hero { background: #F7F5F1; --fx: 0; }
body.fv2 .hero::before { display: none; }
/* --fx=0でタイル、1で全幅（スクロールで開く。JSがrAFで更新） */
body.fv2 .hero-bg {
  top: calc((var(--header-h) + 12px) * (1 - var(--fx)));
  left: calc(clamp(16px, 2vw, 28px) * (1 - var(--fx)));
  right: calc(clamp(16px, 2vw, 28px) * (1 - var(--fx)));
  bottom: calc(84px * (1 - var(--fx)));
  z-index: 0;
  border-radius: calc(clamp(32px, 5vw, 72px) * (1 - var(--fx)));
  overflow: hidden;
}
/* 開いた動画がヘッダー下に潜っても読めるよう、fv2はヘッダーを常時ソリッドに */
body.fv2 .site-header { background: rgba(247, 245, 241, 0.94); }
body.fv2 .hero-content { z-index: 1; }
/* ヘッダーはグレージュ上なのでソリッド文字 */
body.fv2 .site-header .brand img { filter: none; }
body.fv2 .site-header .gnav > ul > li > a { color: var(--ink); }
body.fv2 .site-header .menu-btn span { background: var(--ink); }
/* スクロールインジケータは地の上（ダーク色） */
body.fv2 .hero-scroll span { color: var(--gray); }
body.fv2 .hero-scroll i { background: rgba(54, 51, 50, 0.25); }
body.fv2 .hero-scroll i::after { background: var(--ink); }

@media (max-width: 900px) {
  body.fv2 .hero-bg {
    top: calc((var(--header-h) + 6px) * (1 - var(--fx)));
    left: calc(8px * (1 - var(--fx)));
    right: calc(8px * (1 - var(--fx)));
    bottom: calc(64px * (1 - var(--fx)));
    border-radius: calc(22px * (1 - var(--fx)));
  }
}
