/* 128 透 矯正歯科 — K05 ページ全体が横に進む。色と書体は共通の13変数だけ（色は :root と区切りの上書きにだけ書く） */
:root {
  --c-bg: #f7f7f5;
  --c-bg-alt: #ebebe8;
  --c-text: #374151;
  --c-sub: #4b5563;
  --c-line: #c2c2bd;
  --c-accent: #8a8a86;
  --c-accent-text: #1d1d1f;
  --c-on-accent: #111111;
  --c-2: #c8c8c4;
  --c-3: #1d1d1f;
  --font-ja: "Noto Sans JP", sans-serif;
  --font-head: "Shippori Mincho B1", "Noto Sans JP", serif;
  --font-en: "Josefin Sans", "Noto Sans JP", sans-serif;
  --header-h: 64px;
}
/* 地の色が変わる区切り：変数を全部上書きする */
.p-paper, [data-tone="p-paper"] {
  --c-bg: #f7f7f5; --c-bg-alt: #ebebe8; --c-text: #374151; --c-sub: #4b5563; --c-line: #c2c2bd;
  --c-accent: #8a8a86; --c-accent-text: #1d1d1f; --c-on-accent: #111111; --c-2: #c8c8c4; --c-3: #1d1d1f;
}
.p-grey, [data-tone="p-grey"] {
  --c-bg: #e6e6e2; --c-bg-alt: #f7f7f5; --c-text: #374151; --c-sub: #4b5563; --c-line: #b4b4af;
  --c-accent: #6f6f6b; --c-accent-text: #1d1d1f; --c-on-accent: #f7f7f5; --c-2: #b4b4af; --c-3: #1d1d1f;
}
.p-ink, [data-tone="p-ink"] {
  --c-bg: #1d1d1f; --c-bg-alt: #2a2a2c; --c-text: #e6e6e3; --c-sub: #bdbdb9; --c-line: #55555a;
  --c-accent: #bdbdb9; --c-accent-text: #f7f7f5; --c-on-accent: #1d1d1f; --c-2: #55555a; --c-3: #f7f7f5;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 8px); -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--c-bg); color: var(--c-text); font-family: var(--font-ja); font-size: 16px; line-height: 2; overflow-x: hidden; }
figure { margin: 0; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, p, dd, dt, li { word-break: auto-phrase; overflow-wrap: anywhere; }
h1, h2, h3, p, dl, dd, ol, ul { margin: 0; padding: 0; font-weight: inherit; }
ul, ol { list-style: none; }
.fz { font-family: var(--font-ja); }

.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 26px; background: var(--c-3); color: var(--c-bg); font-family: var(--font-ja); font-weight: 500; font-size: 16px; letter-spacing: .06em; text-decoration: none; white-space: nowrap; flex: none; border: 0; }
.btn--lg { min-height: 56px; padding: 0 34px; }

/* ===== ヘッダー（物差し入り） ===== */
.header { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 12px; height: var(--header-h); padding: 0 8px 0 20px; background: var(--c-bg); border-bottom: 1px solid var(--c-line); color: var(--c-text); }
.logo { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--c-3); white-space: nowrap; flex: none; min-height: 44px; }
.logo__ja { font-family: var(--font-head); font-weight: 500; font-size: 19px; letter-spacing: .1em; }
.logo__en { font-family: var(--font-en); font-weight: 300; font-size: 15px; letter-spacing: .24em; color: var(--c-sub); }
@media (max-width: 520px) { .logo__en { display: none; } }
.ruler { display: none; }
.header__btn { margin-left: auto; min-height: 44px; padding: 0 18px; }
.spmenu { flex: none; }
.spmenu summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: center; min-width: 48px; min-height: 48px; color: var(--c-3); }
.spmenu summary::-webkit-details-marker { display: none; }
.spmenu__label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.spmenu__bar, .spmenu__bar::before, .spmenu__bar::after { display: block; width: 22px; height: 1px; background: currentColor; position: relative; }
.spmenu__bar::before, .spmenu__bar::after { content: ""; position: absolute; left: 0; }
.spmenu__bar::before { top: -7px; } .spmenu__bar::after { top: 7px; }
.spmenu[open] .spmenu__bar { background: transparent; }
.spmenu[open] .spmenu__bar::before { top: 0; transform: rotate(45deg); }
.spmenu[open] .spmenu__bar::after { top: 0; transform: rotate(-45deg); }
.spmenu__nav { position: absolute; left: 0; right: 0; top: 100%; background: var(--c-bg); border-bottom: 1px solid var(--c-line); padding: 4px 20px 12px; display: flex; flex-direction: column; }
.spmenu__nav a { display: flex; align-items: center; min-height: 52px; text-decoration: none; color: var(--c-3); border-bottom: 1px solid var(--c-line); }
.spmenu__nav a:last-child { border-bottom: 0; }

/* ===== 面（スマホ・JSなし：縦に並ぶ） ===== */
.hz__ui { display: none; }
.panel { background: var(--c-bg); color: var(--c-text); padding: 64px 20px; border-top: 1px solid var(--c-line); }
.panel__in { max-width: 40em; margin: 0 auto; }
.eyebrow { font-family: var(--font-en); font-weight: 300; font-size: 16px; letter-spacing: .34em; color: var(--c-sub); margin-bottom: 14px; }
.h2 { font-family: var(--font-head); font-weight: 400; font-size: clamp(28px, 7vw, 46px); line-height: 1.5; color: var(--c-3); margin-bottom: 22px; letter-spacing: .06em; }
.lead { font-size: clamp(16px, 4.2vw, 18px); }

/* はじめ：縦3枚（スマホは縦に積む） */
.panel--hero { padding: 0; border-top: 0; display: flex; flex-direction: column; }
.strip { overflow: hidden; background: var(--c-bg-alt); height: 34svh; min-height: 200px; }
.strip img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.08); }
.strip--a { order: 1; } .hero__band { order: 0; } .strip--b { order: 2; } .strip--c { order: 3; } .hero__sp { order: 4; }
.hero__band { padding: 36px 20px 28px; text-align: center; }
.hero__v { writing-mode: vertical-rl; display: inline-block; font-family: var(--font-head); font-weight: 500; font-size: clamp(30px, 8.6vw, 44px); line-height: 1.5; letter-spacing: .14em; color: var(--c-3); height: 10.6em; }
.hero__v span { display: block; margin-left: .6em; }
.hero__v span:last-child { margin-top: 1.4em; }
.hero__en { font-family: var(--font-en); font-weight: 300; font-size: 15px; letter-spacing: .3em; color: var(--c-sub); margin-top: 16px; }
.hero__sp { padding: 28px 20px 56px; }
.hero__lead { margin-bottom: 22px; }

.policy { margin-top: 28px; border-top: 1px solid var(--c-line); }
.policy li { display: grid; grid-template-columns: 56px minmax(0, 1fr); column-gap: 8px; padding: 18px 0; border-bottom: 1px solid var(--c-line); }
.policy__no { grid-row: 1 / 3; font-family: var(--font-en); font-weight: 300; font-size: 34px; line-height: 1.2; color: var(--c-sub); }
.policy h3 { font-family: var(--font-head); font-weight: 500; font-size: 20px; color: var(--c-3); }
.policy p { font-size: 15px; color: var(--c-sub); line-height: 1.8; }

/* パノラマ（スマホは縦の年表） */
.pano__head { margin-bottom: 18px; }
.pano__head p:last-child { color: var(--c-sub); }
.pano__list { border-left: 1px solid var(--c-line); margin-left: 6px; }
.stop { position: relative; padding: 0 0 28px 28px; }
.stop::before { content: ""; position: absolute; left: -5px; top: 14px; width: 9px; height: 9px; background: var(--c-3); border-radius: 50%; }
.stop__m { display: block; font-family: var(--font-en); font-weight: 300; font-size: 17px; letter-spacing: .1em; color: var(--c-sub); }
.stop__m b { font-weight: 300; font-size: 44px; line-height: 1.1; color: var(--c-3); margin-right: 4px; }
.stop h3 { font-family: var(--font-head); font-weight: 500; font-size: 21px; color: var(--c-3); }
.stop p { font-size: 15px; color: var(--c-sub); line-height: 1.8; }

/* スライド（CSSだけの scroll-snap） */
.snap-ctrl { display: flex; gap: 10px; margin: 6px 0 18px; }
.snap-ctrl__btn { width: 52px; height: 52px; border: 1px solid var(--c-3); background: transparent; color: var(--c-3); font-size: 22px; line-height: 1; cursor: pointer; font-family: var(--font-ja); }
.snap-ctrl__btn:hover, .snap-ctrl__btn:focus-visible { background: var(--c-3); color: var(--c-bg); }
.snap { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: 20px; margin: 0 -20px; padding: 2px 20px 18px; }
.snap:focus-visible { outline: 2px solid var(--c-3); outline-offset: -2px; }
.card { flex: 0 0 min(76vw, 280px); min-width: 0; scroll-snap-align: start; padding: 22px 20px; border: 1px solid var(--c-line); background: var(--c-bg-alt); display: flex; flex-direction: column; min-height: 280px; }
.card__no { font-family: var(--font-en); font-weight: 300; font-size: 44px; line-height: 1; color: var(--c-sub); margin-bottom: auto; padding-bottom: 28px; }
.card h3 { font-family: var(--font-head); font-weight: 500; font-size: 21px; color: var(--c-3); margin-bottom: 6px; }
.card p { font-size: 15px; line-height: 1.8; color: var(--c-sub); }
.card .card__tag { margin-top: 12px; font-family: var(--font-en); font-weight: 400; letter-spacing: .1em; color: var(--c-3); }

/* F05：数字の穴に二色刷りの写真（白地・黒の数字を screen で重ねる） */
.why { display: grid; gap: 28px; margin-top: 8px; }
.why__num { position: relative; height: 170px; margin-bottom: 10px; background: var(--c-bg-alt); overflow: hidden; }
.why__num img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.3) brightness(.55); }
.why__num b { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-family: var(--font-en); font-weight: 400; font-size: 190px; line-height: 1; background: var(--c-bg); color: var(--c-3); mix-blend-mode: screen; }
.why h3 { font-family: var(--font-head); font-weight: 500; font-size: 22px; color: var(--c-3); }
.why p { font-size: 15px; color: var(--c-sub); line-height: 1.8; }

.fee { border-top: 1px solid var(--c-line); }
.fee > div { display: flex; justify-content: space-between; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--c-line); }
.fee dt { color: var(--c-3); }
.fee dd { flex: none; font-family: var(--font-en); font-weight: 400; color: var(--c-3); }
.note { margin-top: 16px; font-size: 15px; color: var(--c-sub); line-height: 1.8; }
.info { margin-top: 32px; border-top: 1px solid var(--c-line); }
.info > div { display: grid; grid-template-columns: 5em minmax(0, 1fr); gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--c-line); }
.info dt { font-weight: 700; color: var(--c-accent-text); }
.fiction { margin-top: 28px; font-size: 15px; color: var(--c-sub); }

/* ===== 動き：1枚目の写真がゆっくり拡大（JS が is-motion を付けたときだけ） ===== */
.is-motion .strip img { animation: slowzoom 6s ease-out both; }
.is-motion .strip--b img { animation-delay: .5s; }
.is-motion .strip--c img { animation-delay: 1s; }
@keyframes slowzoom { from { transform: scale(1); } to { transform: scale(1.08); } }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .is-motion .strip img { animation: none; } }

/* ===== PC：JS が is-hz を付けたときだけ、横に進む ===== */
@media (min-width: 1080px) {
  .is-hz .header { position: fixed; left: 0; right: 0; top: 0; padding: 0 56px; }
  .is-hz .spmenu { display: none; }
  .is-hz .ruler { display: flex; align-items: center; gap: 16px; flex: 1 1 auto; margin: 0 24px; }
  .ruler__label { font-family: var(--font-en); font-weight: 300; font-size: 15px; letter-spacing: .2em; color: var(--c-sub); white-space: nowrap; flex: none; }
  .ruler__label b { font-weight: 400; color: var(--c-3); }
  .ruler__line { position: relative; flex: 1 1 auto; height: 14px; background: repeating-linear-gradient(90deg, var(--c-accent) 0 1px, transparent 1px 12px) bottom / 100% 6px no-repeat; border-bottom: 1px solid var(--c-accent); }
  .ruler__line i { position: absolute; left: 0; bottom: -1px; width: 2px; height: 14px; background: var(--c-3); }
  .is-hz .header__btn { margin-left: 0; }

  .is-hz .hz { height: 100svh; overflow: hidden; position: relative; }
  .is-hz .hz__track { display: flex; width: max-content; height: 100%; will-change: transform; }
  .is-hz .panel { flex: 0 0 100vw; width: 100vw; height: 100svh; padding: calc(var(--header-h) + 24px) 7vw 48px; border-top: 0; display: flex; align-items: center; overflow: hidden; position: relative; }
  .is-hz .panel__in { margin: 0; max-width: 46em; }
  .is-hz .panel__in--wide { max-width: none; width: 100%; }
  .is-hz .h2 { font-size: clamp(32px, 3.4vw, 52px); }

  /* 1枚目：写真A｜縦書きの帯｜写真B｜写真C */
  .is-hz .panel--hero { padding: var(--header-h) 0 0; display: grid; grid-template-columns: 1fr 0.9fr 1fr 1fr; }
  .is-hz .strip { height: 100%; min-height: 0; }
  .is-hz .strip--a, .is-hz .hero__band, .is-hz .strip--b, .is-hz .strip--c { order: 0; }
  .is-hz .hero__band { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 0; }
  .is-hz .hero__v { font-size: clamp(30px, 3.3vw, 52px); height: 10.6em; }
  .is-hz .hero__sp { position: absolute; left: 3vw; bottom: 5svh; width: 22vw; padding: 20px; background: var(--c-bg); z-index: 2; }
  .is-hz .hero__lead { font-size: 15px; line-height: 1.8; margin-bottom: 16px; }
  .is-hz .hero__sp .btn { width: 100%; }

  /* パノラマ：横に長い面。物差しの月数が進む */
  .is-hz .panel--pano { flex-basis: 280vw; width: 280vw; padding-right: 0; }
  .is-hz .pano { display: flex; align-items: center; gap: 6vw; width: 100%; }
  .is-hz .pano__head { flex: none; width: 26vw; margin-bottom: 0; }
  .is-hz .pano__list { display: flex; flex: 1 1 auto; border-left: 0; margin: 0; border-top: 1px solid var(--c-3); gap: 0; align-self: center; padding-right: 7vw; }
  .is-hz .stop { flex: 1 1 0; min-width: 22vw; padding: 36px 3vw 0 0; }
  .is-hz .stop::before { left: 0; top: -5px; }
  .is-hz .stop:nth-child(even) { padding-top: 0; padding-bottom: 36px; transform: none; align-self: flex-end; }
  .is-hz .stop__m b { font-size: 84px; }

  .is-hz .snap { margin: 0; padding: 2px 0 14px; overflow-x: auto; }
  .is-hz .card { flex: 0 0 calc((100% - 42px) / 4); min-height: 340px; }
  .is-hz .why { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 3vw; }
  .is-hz .why__num { height: 30svh; }
  .is-hz .why__num b { font-size: 32svh; }
  .is-hz .fee { max-width: 36em; }

  .is-hz .hz__ui { display: block; position: fixed; right: 56px; bottom: 28px; z-index: 35; font-family: var(--font-en); font-weight: 300; font-size: 17px; letter-spacing: .2em; color: var(--c-sub); background: var(--c-bg); padding: 6px 14px; border: 1px solid var(--c-line); }
}
