/* KI税理士法人 サイト共通スタイル
   空の色（--sky-*）と街の灯り（--lights）は main.js がスクロール量に応じて書き換える */

:root {
  --sky-top: #1f4f8f;
  --sky-mid: #4f86c6;
  --sky-low: #a9cdea;
  --lights: 0;
  --stars: 0;
  --hero: 0;

  --navy: #0b1d3a;
  --accent: #1f5fa8;
  --gold: #e8b55a;
  --ink: #1b2533;
  --ink-soft: #4a5566;
  --paper: rgba(255, 255, 255, .92);
  --line: rgba(11, 29, 58, .12);

  --font-sans: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic UI", "Yu Gothic", "Meiryo", "Noto Sans JP", sans-serif;
  --font-serif: "Hiragino Mincho ProN", "Yu Mincho", "YuMincho", "Noto Serif JP", serif;
  --radius: 18px;
  --gutter: 16px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink: #e8edf5;
    --ink-soft: #aab4c3;
    --paper: rgba(14, 26, 48, .88);
    --line: rgba(255, 255, 255, .12);
    --accent: #7fb3ea;
  }
}
:root[data-theme="dark"] {
  --accent: #7fb3ea;
  --ink: #e8edf5;
  --ink-soft: #aab4c3;
  --paper: rgba(14, 26, 48, .88);
  --line: rgba(255, 255, 255, .12);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 72px; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--navy);
  line-height: 1.9;
  letter-spacing: .02em;
  overflow-x: hidden;
}

a { color: inherit; }
img, svg { display: block; max-width: 100%; }

/* ---------- 空 ---------- */
.sky {
  position: fixed;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, var(--sky-top) 0%, var(--sky-mid) 62%, var(--sky-low) 100%);
}
.stars {
  position: absolute;
  inset: 0 0 35% 0;
  opacity: var(--stars);
  background-image:
    radial-gradient(1px 1px at 12% 18%, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 28% 8%, #fff 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 44% 22%, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 63% 12%, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 78% 28%, #fff 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 90% 6%, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 6% 40%, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 54% 44%, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 84% 50%, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 36% 56%, #fff 50%, transparent 51%);
}

/* ---------- ヘッダー ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px max(var(--gutter), calc((100vw - 1120px) / 2));
  color: #fff;
  background: rgba(8, 18, 38, .35);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.brand {
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: 1.25rem;
  text-decoration: none;
  letter-spacing: .08em;
  white-space: nowrap;
}
.brand span { font-size: .8em; margin-left: .3em; }

.nav { display: flex; align-items: center; gap: 22px; font-size: .9rem; }
.nav a { text-decoration: none; opacity: .88; transition: opacity .2s; white-space: nowrap; }
.nav a:hover { opacity: 1; }
.nav-cta {
  padding: 6px 16px;
  border-radius: 999px;
  background: var(--accent);
  opacity: 1 !important;
}

.nav-toggle { display: none; }

/* ---------- ヒーロー ---------- */
.hero {
  position: relative;
  height: 100vh;
  height: 100svh;
  min-height: 560px;
  display: grid;
  place-items: end center;
  color: #fff;
  overflow: hidden;
}
.hero-text {
  position: relative;
  z-index: 2;
  padding: 0 var(--gutter) max(72px, 11vh);
  text-align: center;
  transform: translateY(calc(var(--hero) * -60px)) scale(calc(1 - var(--hero) * .12));
  opacity: calc(1 - var(--hero) * 1.4);
  will-change: transform, opacity;
}
.hero-kicker { margin: 0 0 14px; font-size: clamp(.8rem, 1.6vw, .95rem); font-weight: 500; letter-spacing: .18em; opacity: .9; }
.hero-catch {
  margin: 0;
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: clamp(2rem, 5.2vw, 4.2rem);
  line-height: 1.35;
  letter-spacing: .06em;
  text-shadow: 0 2px 24px rgba(0, 0, 0, .25);
}
.hero-lead { margin: 20px 0 0; font-size: clamp(.95rem, 2.2vw, 1.1rem); opacity: .92; }
.sp { display: none; }

/* ヒーロー写真：スクロールでゆっくり寄り、下端は空のグラデーションに溶け込む */
.hero-photo {
  position: absolute;
  inset: 0;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(180deg, #000 78%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 78%, transparent 100%);
}
.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 60% 30%;
  transform: scale(calc(1.02 + var(--hero) * .12));
  transform-origin: 60% 60%;
  will-change: transform;
}
.hero-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(8, 22, 52, .45) 0%, rgba(8, 22, 52, 0) 30%, rgba(8, 22, 52, 0) 50%, rgba(8, 22, 52, .55) 80%),
    rgba(8, 22, 52, calc(var(--hero) * .5));
}

/* ページ末尾の夜景イラスト */
.city { position: relative; height: clamp(180px, 22vw, 320px); overflow: hidden; margin-top: 40px; }
.skyline {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  width: 100%;
  height: 100%;
}
.skyline .far  { fill: #1c2b4d; opacity: .55; }
.skyline .near { fill: #0e1a33; }
.skyline .water { fill: #0b1830; }
.skyline .lit  { opacity: var(--lights); }
.skyline .wheel-lights { stroke: var(--gold); opacity: var(--lights); }

.scroll-hint {
  position: absolute;
  bottom: 22px; left: 50%;
  z-index: 3;
  width: 26px; height: 42px;
  margin-left: -13px;
  border: 2px solid rgba(255, 255, 255, .7);
  border-radius: 14px;
  opacity: calc(1 - var(--hero) * 3);
}
.scroll-hint span {
  position: absolute;
  top: 8px; left: 50%;
  width: 4px; height: 8px;
  margin-left: -2px;
  border-radius: 2px;
  background: #fff;
  animation: hint 1.8s infinite;
}
@keyframes hint { 0% { transform: translateY(0); opacity: 1; } 80% { transform: translateY(14px); opacity: 0; } 100% { opacity: 0; } }

/* ---------- セクション共通 ---------- */
.section { padding: 96px 0; }
.wrap { width: min(1120px, 100% - var(--gutter) * 2); margin: 0 auto; }

h2 {
  margin: 0 0 40px;
  color: #fff;
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  letter-spacing: .08em;
  text-shadow: 0 2px 16px rgba(0, 0, 0, .25);
}
h2 small {
  display: block;
  margin-bottom: 4px;
  font-family: var(--font-sans);
  font-size: .8rem;
  font-weight: 500;
  letter-spacing: .35em;
  color: var(--gold);
  text-transform: uppercase;
}
h3 { margin: 0 0 8px; font-size: 1.1rem; letter-spacing: .06em; }

.card {
  padding: clamp(22px, 4vw, 40px);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: 0 20px 50px rgba(5, 12, 28, .25);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
.card p { margin: 0 0 1em; }
.card p:last-child { margin-bottom: 0; }

/* スクロールで浮かび上がる演出 */
.reveal { opacity: 0; transform: translateY(36px); transition: opacity .9s ease, transform .9s cubic-bezier(.2, .7, .2, 1); }
.reveal.is-in { opacity: 1; transform: none; }

/* ---------- ご挨拶 ---------- */
.greeting-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.person { display: grid; grid-template-columns: 120px 1fr; gap: 24px; align-items: start; }
.person .photo {
  aspect-ratio: 3 / 4;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: .72rem;
  color: var(--ink-soft);
  background: linear-gradient(160deg, rgba(31, 95, 168, .18), rgba(11, 29, 58, .15));
}
.role { margin: 0 !important; font-size: .8rem; color: var(--accent); letter-spacing: .1em; }
.person h3 { font-family: var(--font-serif); font-size: 1.4rem; }
.person p:not(.role) { font-size: .95rem; color: var(--ink-soft); }

/* ---------- 数字 ---------- */
.numbers { padding: 24px 0 48px; }
.stats { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; color: #fff; text-align: center; }
.stats b { display: block; font-family: var(--font-serif); font-size: clamp(1.6rem, 5vw, 3rem); font-weight: 600; line-height: 1.3; }
.stats b small { font-size: .45em; margin-left: .15em; }
.stats span { font-size: .85rem; opacity: .85; letter-spacing: .1em; }

.career { margin: -4px 0 12px !important; font-size: .82rem !important; color: var(--accent) !important; }

/* ---------- 沿革（写真背景の帯） ---------- */
.history { position: relative; isolation: isolate; padding: 140px 0; overflow: hidden; color: #fff; }
.history-bg { position: absolute; inset: 0; }
.history-bg img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 60%; opacity: .75; }
.history::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, var(--sky-mid) 0%, rgba(6, 18, 44, .6) 30%, rgba(6, 18, 44, .6) 70%, var(--sky-mid) 100%);
}
.history-bg { z-index: -2; }
.timeline { list-style: none; margin: 0; padding: 0 0 0 28px; border-left: 2px solid rgba(255, 255, 255, .35); max-width: 720px; }
.timeline li { position: relative; padding: 0 0 32px; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before {
  content: "";
  position: absolute;
  left: -36px; top: 10px;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 4px rgba(232, 181, 90, .25);
}
.timeline time { font-family: var(--font-serif); font-size: 1.3rem; font-weight: 600; letter-spacing: .06em; }
.timeline p { margin: 2px 0 0; text-shadow: 0 1px 8px rgba(0, 0, 0, .5); }
.timeline small { opacity: .8; }

/* ---------- 業務内容 ---------- */
.service-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; align-items: start; }
.service-grid .card { border-top: 4px solid var(--accent); }
.service-grid .card:nth-child(2) { transition-delay: .08s; }
.service-grid .card:nth-child(3) { transition-delay: .16s; }
.service-list { list-style: none; margin: 12px 0 0; padding: 0; font-size: .92rem; }
.service-list li { position: relative; padding: 8px 0 8px 18px; border-bottom: 1px solid var(--line); line-height: 1.6; }
.service-list li:last-child { border-bottom: 0; }
.service-list li::before { content: ""; position: absolute; left: 2px; top: 16px; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }

/* ---------- 報酬の目安 ---------- */
.note { font-size: .82rem; color: var(--ink-soft); }

.draft-badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: .78rem;
  color: var(--accent);
  border: 1px dashed var(--accent);
}

/* ---------- 私たちの職場 ---------- */

/* ---------- 事務所概要 ---------- */
.office { display: grid; grid-template-columns: 8em 1fr; margin: 0 0 24px; }
.office dt, .office dd { margin: 0; padding: 14px 0; border-bottom: 1px solid var(--line); }
.office dt { font-size: .85rem; color: var(--ink-soft); }

.btn {
  display: inline-block;
  padding: 10px 22px;
  border-radius: 999px;
  text-decoration: none;
  font-size: .9rem;
}
.btn.ghost { border: 1px solid var(--accent); color: var(--accent); }
.btn.ghost:hover { background: var(--accent); color: #fff; }

/* ---------- お問い合わせ ---------- */
.form-embed { margin: 16px 0; }
.form-embed iframe { display: block; width: 100%; height: 1300px; border: 0; border-radius: 12px; background: #fff; }
@media (max-width: 720px) { .form-embed iframe { height: 1650px; } }

/* ---------- フッター ---------- */
.site-footer {
  padding: 48px var(--gutter) 40px;
  text-align: center;
  color: rgba(255, 255, 255, .75);
  font-size: .82rem;
  background: rgba(3, 8, 20, .6);
}
.site-footer p { margin: 4px 0; }
.site-footer .brand { color: #fff; font-size: 1.1rem; margin-bottom: 12px; }
.site-footer .copy { margin-top: 16px; opacity: .6; }

/* ---------- 業務内容の詳細リンク ---------- */
.more { display: block; margin-top: 16px; font-size: .88rem; color: var(--accent); text-decoration: none; font-weight: 600; }
.more::after { content: " →"; }
.more:hover { text-decoration: underline; }
.more + .more { margin-top: 6px; }

/* ---------- よくある質問 ---------- */
.faq { padding-top: 8px; padding-bottom: 8px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq details:last-child { border-bottom: 0; }
.faq summary {
  position: relative;
  padding: 18px 36px 18px 0;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before { content: "Q."; margin-right: .5em; color: var(--accent); font-family: var(--font-serif); }
.faq summary::after {
  content: "";
  position: absolute;
  right: 6px; top: 50%;
  width: 9px; height: 9px;
  margin-top: -7px;
  border-right: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(45deg);
  transition: transform .2s;
}
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.faq details p { margin: 0 0 18px; padding-left: 1.6em; font-size: .95rem; color: var(--ink-soft); }
.faq details a, .article a { color: var(--accent); }

/* ---------- 下層ページ（プライバシーポリシー等） ---------- */
.page { padding: 120px 0 80px; }
.page .card h2 { color: var(--ink); text-shadow: none; font-size: 1.6rem; }
.page .card h3 { margin-top: 2em; }
.breadcrumb { margin: 0 0 16px; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 6px; font-size: .8rem; color: rgba(255, 255, 255, .8); }
.breadcrumb li + li::before { content: "›"; margin-right: 6px; }
.breadcrumb a { color: inherit; }
.article h1 { margin: 0 0 8px; font-family: var(--font-serif); font-size: clamp(1.5rem, 4vw, 2.1rem); font-weight: 600; letter-spacing: .06em; line-height: 1.5; }
.article .lead { font-size: 1.02rem; color: var(--ink-soft); }
.article h2 { margin: 2.2em 0 .6em; color: var(--ink); text-shadow: none; font-size: 1.3rem; padding-left: 12px; border-left: 4px solid var(--accent); }
.article h2 small { display: none; }
.article ul, .article ol { padding-left: 1.4em; }
.article li { margin: .3em 0; }
.article table { width: 100%; border-collapse: collapse; margin: 1em 0; font-size: .92rem; }
.article th, .article td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.article th { width: 34%; color: var(--ink-soft); font-weight: 600; }
.article .cta { margin-top: 2.4em; padding: 20px; border-radius: 12px; background: rgba(31, 95, 168, .08); }
.article .cta .btn { margin-top: 8px; background: var(--accent); color: #fff; }
.updated { font-size: .78rem; color: var(--ink-soft); }

/* ---------- スマートフォン ---------- */
@media (max-width: 900px) {
  .service-grid { grid-template-columns: 1fr 1fr; }
  .greeting-grid { grid-template-columns: 1fr; }
}

/* メニュー項目が収まらない幅ではハンバーガーメニューに切り替える */
@media (max-width: 1120px) {
  .nav-toggle {
    display: block;
    position: relative;
    width: 40px; height: 40px;
    margin-right: -8px;
    border: 0;
    background: none;
    cursor: pointer;
  }
  .nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
    position: absolute;
    left: 10px;
    width: 20px; height: 2px;
    background: #fff;
    border-radius: 1px;
    transition: transform .25s, top .25s, opacity .25s;
  }
  .nav-toggle span { top: 19px; }
  .nav-toggle span::before, .nav-toggle span::after { content: ""; left: 0; }
  .nav-toggle span::before { top: -6px; }
  .nav-toggle span::after { top: 6px; }
  .nav-toggle[aria-expanded="true"] span { background: transparent; }
  .nav-toggle[aria-expanded="true"] span::before { top: 0; transform: rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span::after { top: 0; transform: rotate(-45deg); }

  .nav {
    position: fixed;
    top: 64px; left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px var(--gutter) 20px;
    background: rgba(8, 18, 38, .96);
    transform: translateY(-8px);
    opacity: 0;
    visibility: hidden;
    transition: opacity .2s, transform .2s, visibility .2s;
  }
  .nav.is-open { opacity: 1; transform: none; visibility: visible; }
  .nav a { padding: 14px 4px; border-bottom: 1px solid rgba(255, 255, 255, .08); font-size: 1rem; }
  .nav-cta { margin-top: 12px; text-align: center; border-bottom: 0 !important; }
}

@media (max-width: 720px) {
  .sp { display: inline; }
  .kicker-sep { display: none; }
  .kicker-name { display: block; margin-top: 2px; }
  .section { padding: 64px 0; }
  h2 { margin-bottom: 28px; }
  .service-grid { grid-template-columns: 1fr; gap: 14px; }
  .service-grid .card { transition-delay: 0s !important; }
  .person { grid-template-columns: 88px 1fr; gap: 16px; }
  .stats { gap: 8px; }
  .stats span { font-size: .72rem; letter-spacing: 0; }
  .office { grid-template-columns: 1fr; }
  .office dt { padding-bottom: 0; border-bottom: 0; }
  .office dd { padding-top: 2px; }
  /* 縦長画面ではランドマークタワー〜観覧車の範囲が見えるように横位置をずらす */
  .skyline { right: auto; width: auto; max-width: none; aspect-ratio: 1600 / 420; translate: -17% 0; }
  .hero-text { padding-bottom: 96px; }
  .hero-photo img { object-position: 62% 50%; }

}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .scroll-hint span { animation: none; }
}

/* 職場紹介の小見出し */
.card h3.sub { margin: 28px 0 8px; font-size: 1.05rem; padding-left: 10px; border-left: 3px solid var(--accent); }
.card .office { margin-bottom: 8px; }

/* 代表者写真・事務所の写真 */
.person img.photo { width: 100%; height: auto; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 12px; }
.office-photos { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 0 0 24px; }
.office-photos figure { margin: 0; }
.office-photos .wide { grid-column: 1 / -1; }
.office-photos img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 12px; }
.office-photos .wide img { aspect-ratio: auto; }
.office-photos figcaption { margin-top: 6px; font-size: .78rem; color: var(--ink-soft); }
@media (max-width: 720px) { .office-photos { grid-template-columns: 1fr; } }

/* 事務所のまわり（写真ギャラリー：縦横混在をそのまま段組みで並べる） */
.section-lead { margin: -20px 0 28px; color: #fff; opacity: .9; text-shadow: 0 1px 8px rgba(0, 0, 0, .3); }
.gallery { columns: 3 240px; column-gap: 16px; }
.gallery figure { margin: 0 0 16px; break-inside: avoid; }
.gallery img { width: 100%; height: auto; border-radius: 12px; box-shadow: 0 12px 30px rgba(5, 12, 28, .25); }
.gallery figcaption { margin-top: 6px; font-size: .8rem; color: rgba(255, 255, 255, .85); }
@media (max-width: 720px) { .gallery { columns: 2; column-gap: 10px; } .gallery figure { margin-bottom: 10px; } }

/* スクロールで切り替わる背景写真（空のグラデーションを半透明に重ねて色味をそろえる） */
.bg-photos { position: fixed; inset: 0; z-index: -2; overflow: hidden; background: var(--navy); }
.bg-layer {
  position: absolute;
  inset: -3%;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: scale(1.08);
  filter: blur(1.5px) saturate(1.1);
  transition: opacity 1.6s ease, transform 10s ease-out;
}
.bg-layer.on { opacity: 1; transform: scale(1); }
.sky { transition: opacity 1.2s ease; }
:root.has-bg .sky { opacity: .78; }
@media (prefers-reduced-motion: reduce) {
  .bg-layer { transform: none; transition: opacity .6s ease; }
}

/* 職場紹介：スタッフ写真と見出しを横並び（スマホは縦積み） */
.team-intro { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(20px, 4vw, 40px); align-items: center; margin-bottom: 24px; }
.team-intro img { width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 14px; box-shadow: 0 14px 34px rgba(5, 12, 28, .22); }
.team-label { margin: 0 0 6px !important; font-size: .75rem; letter-spacing: .3em; color: var(--accent); font-weight: 600; }
.team-lead { margin: 0 !important; font-family: var(--font-serif); font-size: clamp(1.2rem, 2.6vw, 1.7rem); font-weight: 600; line-height: 1.7; letter-spacing: .04em; }
.pc { display: inline; }
@media (max-width: 720px) {
  .team-intro { grid-template-columns: 1fr; gap: 16px; }
  .pc { display: none; }
}

/* 代表者の経歴（ご挨拶カードの下段、写真と本文の幅いっぱいに表示） */
.career-block { grid-column: 1 / -1; padding-top: 18px; border-top: 1px solid var(--line); }
.career-block h4 { margin: 0 0 8px; font-size: .85rem; letter-spacing: .15em; color: var(--accent); }
.career-block p { margin: 0; font-size: .9rem; color: var(--ink-soft); line-height: 1.8; }
.career-list { display: grid; grid-template-columns: 5.5em 1fr; gap: 6px 12px; margin: 0; font-size: .88rem; line-height: 1.7; }
.career-list dt { color: var(--accent); font-weight: 600; font-variant-numeric: tabular-nums; }
.career-list dd { margin: 0; color: var(--ink-soft); }
.person { align-content: start; }

/* 沿革：二人の歩み（2本の線）が事務所の開設で1本に合流する */
.merge-timeline { max-width: 720px; }
.lanes { display: grid; grid-template-columns: 1fr 1fr; }
.timeline.lane { padding-right: 16px; padding-bottom: 8px; }
.timeline.lane li { padding-bottom: 0; }
.lane-name { display: block; font-size: .78rem; letter-spacing: .15em; color: var(--gold); }
.merge { display: block; width: 100%; height: 64px; overflow: visible; }
.merge path { fill: none; stroke: rgba(255, 255, 255, .35); stroke-width: 2; }
.timeline.trunk { padding-top: 8px; }
@media (max-width: 720px) {
  .timeline.lane { padding-left: 20px; padding-right: 10px; }
  .timeline.lane li::before { left: -28px; }
  .timeline.lane time { font-size: 1.1rem; }
  .timeline.lane p { font-size: .88rem; }
}

.price-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
.price-grid h3 { padding-bottom: 10px; border-bottom: 2px solid var(--accent); }
.price-list { display: grid; grid-template-columns: minmax(8em, 1fr) minmax(0, 1.3fr); margin: 0; font-size: .92rem; }
.price-list dt, .price-list dd { padding: 10px 0; border-bottom: 1px solid var(--line); }
.price-list dt { padding-right: 12px; color: var(--ink-soft); }
.price-list dd { margin: 0; text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
.price-list dd small { display: block; font-weight: 400; font-size: .76rem; color: var(--ink-soft); line-height: 1.6; }
.price-list dt:last-of-type, .price-list dd:last-of-type { border-bottom: 0; }
@media (max-width: 900px) { .price-grid { grid-template-columns: 1fr; } }
@media (max-width: 720px) {
  .price-list { grid-template-columns: 1fr; }
  .price-list dt { padding-bottom: 0; border-bottom: 0; }
  .price-list dd { padding-top: 2px; text-align: left; }
}
.price-alert { margin: -16px 0 28px; padding: 14px 18px; border-left: 4px solid var(--gold); border-radius: 8px; background: rgba(8, 22, 52, .55); color: #fff; font-size: .9rem; line-height: 1.8; }
.price-grid .note { margin-top: 12px; font-size: .8rem; }

/* ご挨拶から沿革へつながる線（main.js が描画。JSが動かない場合は従来の静的な線を表示） */
main { position: relative; }
.story-lines { position: absolute; left: 0; top: 0; z-index: 1; pointer-events: none; overflow: visible; }
.story-lines path { fill: none; stroke: rgba(232, 181, 90, .85); stroke-width: 2; stroke-linecap: round; }
.story-lines-on .timeline.lane,
.story-lines-on .timeline.trunk { border-left-color: transparent; }
.story-lines-on .merge path { stroke: transparent; }

/* 代表者カード右上の頭文字（小池＝K、一戸＝I で「KI」） */
.person { position: relative; overflow: hidden; }
.person::after {
  content: attr(data-initial);
  position: absolute;
  top: 12px;
  right: 22px;
  font-family: var(--font-serif);
  font-size: clamp(5.5rem, 10vw, 8rem);
  font-weight: 700;
  line-height: 1;
  color: var(--accent);
  opacity: .14;
  pointer-events: none;
}
.person > * { position: relative; z-index: 1; }

/* ロゴ */
.brand { display: inline-flex; align-items: center; gap: 8px; }
.brand-mark { width: 40px; height: auto; }
.site-footer .brand { flex-direction: column; gap: 6px; }
.footer-logo { width: 140px; height: auto; margin: 0 auto; }
.footer-name { font-size: .95rem; margin: 0 !important; }

/* リンク集 */
.link-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0 28px; }
.link-list li { border-bottom: 1px solid var(--line); }
.link-list a { display: block; padding: 14px 0; text-decoration: none; }
.link-list strong { display: block; color: var(--accent); font-size: .98rem; }
.link-list strong::after { content: " ↗"; font-size: .8em; }
.link-list span { font-size: .82rem; color: var(--ink-soft); }
.link-list a:hover strong { text-decoration: underline; }
@media (max-width: 720px) { .link-list { grid-template-columns: 1fr; } }

/* 事務所概要の地図 */
.map-embed { margin: 0 0 16px; }
.map-embed iframe { width: 100%; height: 440px; border: 0; border-radius: 12px; box-shadow: 0 14px 34px rgba(5, 12, 28, .22); }
@media (max-width: 720px) { .map-embed iframe { height: 320px; } }

/* =========================================================
   選ばれる3つの理由（左の見出しを固定、右の項目が順に浮かぶ）
   ========================================================= */
.reasons { padding-top: 120px; }
.reasons-layout { display: grid; grid-template-columns: .8fr 1.2fr; gap: 48px; align-items: start; }
.reasons-head { position: sticky; top: 120px; }
.reasons-head h2 { font-size: clamp(2rem, 4.2vw, 3.2rem); line-height: 1.35; margin-bottom: 28px; }
.reasons-progress { display: flex; gap: 8px; list-style: none; margin: 0; padding: 0; }
.reasons-progress li { width: 28px; height: 3px; border-radius: 2px; background: rgba(255, 255, 255, .25); transition: background .4s, width .4s; }
.reasons-progress li.is-active { width: 56px; background: var(--gold); }
.reason-item { min-height: 58vh; display: flex; flex-direction: column; justify-content: center; color: #fff; opacity: .28; transform: translateY(24px); transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .2, 1); }
.reason-item.is-active { opacity: 1; transform: none; }
.reason-no { font-family: var(--font-serif); font-size: 1rem; letter-spacing: .3em; color: var(--gold); margin-bottom: 12px; }
.reason-item h3 { margin: 0 0 18px; font-family: var(--font-serif); font-size: clamp(1.7rem, 3.4vw, 2.7rem); font-weight: 600; line-height: 1.45; letter-spacing: .04em; text-shadow: 0 2px 18px rgba(0, 0, 0, .25); }
.reason-item p { margin: 0; max-width: 32em; font-size: clamp(.98rem, 1.4vw, 1.1rem); line-height: 2; opacity: .9; }

/* =========================================================
   数字で見る当事務所
   ========================================================= */
.numbers { padding: 40px 0 80px; }
.stats { grid-template-columns: repeat(4, 1fr); }
.stats b .pre { font-size: .45em; margin-right: .1em; }
.stats .count { font-variant-numeric: tabular-nums; }
.stats-facts { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 14px; list-style: none; margin: 28px 0 0; padding: 0; }
.stats-facts li { padding: 8px 18px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .28); background: rgba(8, 22, 52, .35); color: #fff; font-size: .85rem; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }

/* =========================================================
   主な対応業種
   ========================================================= */
.card.industry { margin-top: 24px; }
.industry-list { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; margin: 8px 0 12px; padding: 0; }
.industry-list li { padding: 8px 18px; border-radius: 999px; border: 1px solid var(--accent); color: var(--accent); font-size: .92rem; font-weight: 600; }
.industry-list small { font-weight: 400; margin-left: .2em; }

/* =========================================================
   ご相談事例（横スクロールのカルーセル）
   ========================================================= */
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.section-head h2 { margin-bottom: 0; }
.cases .section-lead { margin: 16px 0 28px; }
.scroller-nav { display: flex; gap: 10px; }
.snav { width: 44px; height: 44px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .5); background: rgba(8, 22, 52, .35); color: #fff; font-size: 1.5rem; line-height: 1; cursor: pointer; transition: background .2s, transform .2s; }
.snav:hover { background: rgba(255, 255, 255, .2); transform: scale(1.06); }
.case-scroller {
  --edge: max(var(--gutter), calc((100vw - 1120px) / 2));
  display: flex; gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: var(--edge);
  padding: 8px var(--edge) 28px; scrollbar-width: none;
}
.case-scroller::-webkit-scrollbar { display: none; }
.case-card {
  flex: 0 0 min(360px, 82vw); scroll-snap-align: start; padding: 32px 30px; border-radius: 22px;
  background: var(--paper); box-shadow: 0 20px 50px rgba(5, 12, 28, .25);
  transition: transform .35s cubic-bezier(.2, .7, .2, 1), box-shadow .35s;
}
.case-card:hover { transform: translateY(-6px); box-shadow: 0 28px 60px rgba(5, 12, 28, .32); }
.case-tag { display: inline-block; margin-bottom: 14px; padding: 4px 12px; border-radius: 999px; background: rgba(31, 95, 168, .1); color: var(--accent); font-size: .78rem; font-weight: 600; }
.case-card h3 { font-family: var(--font-serif); font-size: 1.25rem; line-height: 1.5; margin-bottom: 12px; }
.case-card p { margin: 0; font-size: .92rem; color: var(--ink-soft); line-height: 1.9; }
.cases-note { color: rgba(255, 255, 255, .8); }

/* =========================================================
   税務調査への考え方（ステートメント）
   ========================================================= */
.statement {
  padding: clamp(36px, 6vw, 72px); border-radius: 28px; color: #fff;
  background: linear-gradient(140deg, rgba(8, 22, 52, .78), rgba(18, 48, 92, .62));
  border: 1px solid rgba(255, 255, 255, .12); box-shadow: 0 30px 70px rgba(3, 8, 20, .35);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
}
.statement-kicker { margin: 0 0 14px; font-size: .82rem; letter-spacing: .3em; color: var(--gold); }
.statement-title { margin: 0 0 28px; font-family: var(--font-serif); font-size: clamp(1.9rem, 4.4vw, 3.3rem); font-weight: 600; line-height: 1.4; letter-spacing: .04em; text-shadow: none; }
.statement-body { display: grid; grid-template-columns: 1fr 1.4fr; gap: 32px; }
.statement-body p { margin: 0; font-size: .98rem; line-height: 2.05; opacity: .92; }
.card.partner { margin-top: 24px; display: grid; grid-template-columns: 14em 1fr; gap: 24px; align-items: center; }
.card.partner h3 { margin: 0; font-family: var(--font-serif); font-size: 1.25rem; }
.card.partner p { margin: 0; color: var(--ink-soft); font-size: .95rem; }

/* スクロールで少し拡大しながら現れる（ステートメント用） */
.statement.reveal { transform: translateY(36px) scale(.97); }
.statement.reveal.is-in { transform: none; }

@media (max-width: 900px) {
  .reasons-layout { grid-template-columns: 1fr; gap: 8px; }
  .reasons-head { position: static; }
  .reasons-progress { display: none; }
  .reason-item { min-height: auto; padding: 28px 0; opacity: 1; transform: none; border-top: 1px solid rgba(255, 255, 255, .15); }
  .stats { grid-template-columns: 1fr 1fr; row-gap: 28px; }
  .statement-body { grid-template-columns: 1fr; gap: 16px; }
  .card.partner { grid-template-columns: 1fr; gap: 10px; }
}
@media (max-width: 720px) {
  .reasons { padding-top: 72px; }
  .scroller-nav { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .reason-item { opacity: 1; transform: none; transition: none; }
  .case-card, .case-card:hover { transform: none; }
}
/* 数字の帯：ラベル用の span 指定が数字に効かないようにする */
.stats b span.count { font-size: inherit; opacity: 1; letter-spacing: inherit; }

/* お問い合わせのボタン */
.contact-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 20px 0 12px; }
.btn.primary { background: var(--accent); color: #fff; font-weight: 600; padding: 14px 28px; font-size: 1rem; box-shadow: 0 10px 24px rgba(31, 95, 168, .3); transition: transform .2s, box-shadow .2s; }
.btn.primary:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(31, 95, 168, .38); }
.contact-actions .btn.ghost { padding: 14px 24px; font-size: 1rem; }
@media (max-width: 720px) { .contact-actions .btn { width: 100%; text-align: center; } }
