/* 098 しじま心療内科 ― 色はここだけ触れば差し替わる */
:root {
  --c-bg: #f5f5f3;
  --c-paper: #ecebe7;
  --c-ink: #1d1d1f;
  --c-gray: #8a8a86;
  --c-accent-text: #55554f;
  --c-text: #374151;
  --c-sub: #4b5563;
  --c-on-ink: #e8e8e4;
  --c-on-ink-sub: #a8a8a2;
  --c-line: #d6d5d0;
  --font: "Noto Sans JP", sans-serif;
  --font-ja: "Noto Serif JP", serif;
  --font-en: "Cormorant Garamond", serif;
  --photo: grayscale(.55) contrast(.96);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: var(--font); font-size: 16px; line-height: 2; letter-spacing: .04em; color: var(--c-text); background: var(--c-bg); }
img { max-width: 100%; height: auto; display: block; filter: var(--photo); }
a { color: inherit; }
h1, h2, h3, p, figure, dl, dd { margin: 0; font-weight: inherit; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, p, dd, li { word-break: auto-phrase; }

.num { font-family: var(--font-en); font-weight: 300; font-size: 40px; line-height: 1; color: var(--c-accent-text); display: flex; align-items: baseline; gap: 16px; }
.num span { font-style: italic; font-size: 18px; letter-spacing: .14em; }
.num::after { content: ""; flex: 1; max-width: 120px; height: 1px; background: var(--c-gray); align-self: center; }
.num--light { color: var(--c-on-ink-sub); }
.sec-title { font-family: var(--font-ja); font-weight: 300; font-size: clamp(28px, 3.2vw, 42px); line-height: 1.7; letter-spacing: .1em; color: var(--c-ink); margin: 20px 0 28px; }
p + p { margin-top: 1em; }

.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 26px; text-decoration: none; letter-spacing: .14em; white-space: nowrap; flex: none; transition: background-color .5s, color .5s; }
.btn--ink { background: var(--c-ink); color: var(--c-bg); }
.btn--ink:hover { background: #444; }
.btn--paper { background: var(--c-bg); color: var(--c-ink); }
.btn--line { border: 1px solid var(--c-on-ink-sub); color: var(--c-on-ink); }
.btn--lg { min-height: 60px; padding: 0 36px; font-size: 16px; }

/* ===== ヘッダー ===== */
.header { position: fixed; top: 0; left: 0; right: 0; z-index: 50; background: rgba(245, 245, 243, .9); backdrop-filter: blur(6px); }
.header__inner { display: flex; align-items: center; gap: 12px; height: 68px; padding: 0 12px 0 20px; max-width: 1600px; margin: 0 auto; }
.logo { display: flex; align-items: baseline; gap: 12px; min-height: 48px; align-items: center; text-decoration: none; color: var(--c-ink); white-space: nowrap; flex: none; }
.logo__ja { font-family: var(--font-ja); font-weight: 500; font-size: 19px; letter-spacing: .14em; }
.logo__en { font-family: var(--font-en); font-style: italic; font-size: 17px; color: var(--c-accent-text); }
@media (max-width: 420px) { .logo__en { display: none; } }
.header__btn { margin-left: auto; min-height: 44px; padding: 0 20px; font-size: 15px; }
@media (min-width: 1080px) { .header__inner { height: 84px; padding: 0 48px; } }
.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-ink); }
.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: 24px; 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-gray); padding: 8px 20px 24px; display: flex; flex-direction: column; }
.spmenu__nav a { display: flex; align-items: center; min-height: 52px; color: var(--c-ink); text-decoration: none; font-family: var(--font-ja); border-bottom: 1px solid var(--c-line); }
.hprog { display: none; }

/* ===== 縦並び（スマホ・JSなし・動きを減らす設定） ===== */
.panel { position: relative; padding: 96px 20px; }

/* 01 メインビジュアル */
.hero { min-height: 100vh; padding: 0; display: flex; align-items: flex-end; overflow: hidden; background: var(--c-paper); }
.hero__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 70% 50%; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(245, 245, 243, .96) 0%, rgba(245, 245, 243, .85) 42%, rgba(245, 245, 243, 0) 75%); }
.hero__copy { position: relative; z-index: 2; padding: 0 20px 64px; }
.hero__title { font-family: var(--font-ja); font-weight: 300; font-size: clamp(32px, 4.6vw, 64px); line-height: 1.6; letter-spacing: .08em; color: var(--c-ink); margin: 20px 0; }
.hero__lead { color: var(--c-text); margin-bottom: 28px; }
@media (min-width: 900px) {
  .hero { align-items: center; }
  .hero::after { background: linear-gradient(90deg, rgba(245, 245, 243, .95) 0%, rgba(245, 245, 243, .8) 40%, rgba(245, 245, 243, 0) 65%); }
  .hero__copy { padding: 0 0 0 7vw; max-width: 760px; }
}

/* 02 ごあいさつ */
.greet { display: grid; gap: 40px; }
.greet__photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.greet__sign { font-family: var(--font-ja); color: var(--c-ink); margin-top: 2em; }
@media (min-width: 768px) { .greet { grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); align-items: center; gap: 64px; } }

/* 03 こんなとき */
.symptom { background: var(--c-paper); }
.symptom__list { border-top: 1px solid var(--c-gray); }
.symptom__list li { padding: 18px 0 18px 32px; border-bottom: 1px solid var(--c-line); position: relative; font-family: var(--font-ja); font-size: 17px; color: var(--c-ink); }
.symptom__list li::before { content: ""; position: absolute; left: 4px; top: 50%; width: 12px; height: 1px; background: var(--c-ink); }
.symptom__note { margin-top: 24px; color: var(--c-sub); font-size: 15px; }
@media (min-width: 768px) { .symptom__list { display: grid; grid-template-columns: 1fr 1fr; column-gap: 40px; } }

/* 04 初診の流れ（動かない版：大きな写真の下に4段） */
.first { padding: 0; background: var(--c-bg); }
.first__stage { position: relative; }
.first__bg { width: 100%; height: 50vh; min-height: 300px; object-fit: cover; }
.first__head { padding: 56px 20px 0; }
.first__steps { padding: 0 20px 96px; display: grid; gap: 32px; }
.step { display: grid; grid-template-columns: 112px 1fr; gap: 20px; align-items: start; }
.step__win { overflow: hidden; border: 6px solid #fff; box-shadow: 0 10px 30px rgba(29, 29, 31, .08); }
.step__win img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.step__no { font-family: var(--font-en); font-size: 20px; color: var(--c-accent-text); }
.step h3 { font-family: var(--font-ja); font-weight: 500; font-size: 22px; color: var(--c-ink); letter-spacing: .1em; margin: 2px 0 6px; }
/* 動く版（PCは横、スマホは縦のスクロールで）：写真は全面に止め、小窓だけ入れ替える */
.is-b04 .first__stage { height: 100vh; overflow: hidden; }
.is-b04 .first__bg { position: absolute; inset: 0; height: 100%; }
.is-b04 .first__stage::after { content: ""; position: absolute; inset: 0; background: rgba(29, 29, 31, .08); }
.is-b04 .first__head { position: absolute; z-index: 2; top: 84px; left: 20px; right: 20px; padding: 0; }
.is-b04 .first__head .sec-title { margin: 12px 0 0; }
.is-b04 .first__steps { position: absolute; inset: 0; z-index: 2; padding: 0; display: block; }
.is-b04 .step { position: absolute; inset: 0; display: block; }
.is-b04 .step + .step { visibility: hidden; }
.is-b04 .step__win { position: absolute; left: 50%; top: 48%; width: min(60vw, 360px); transform: translate(-50%, -50%); border-width: 10px; box-shadow: 0 30px 60px rgba(29, 29, 31, .18); }
.is-b04 .step__win img { aspect-ratio: 4 / 3; }
.is-b04 .step__text { position: absolute; left: 20px; right: 20px; bottom: 28px; background: rgba(245, 245, 243, .96); padding: 18px 20px; }
@media (min-width: 1080px) {
  .is-b04 .first__head { left: 7vw; top: 140px; }
  .is-b04 .step__win { width: 30vw; max-width: 460px; left: 58%; }
  .is-b04 .step__text { left: 7vw; right: auto; bottom: 12vh; width: 360px; padding: 28px; }
}

/* 05 院内（C02） */
.inside { background: var(--c-paper); overflow: hidden; padding-left: 0; padding-right: 0; }
.inside__head { padding: 0 20px; }
.inside__swiper { padding: 24px 0 8px; }
.inside__swiper .swiper-wrapper { transform-style: preserve-3d; }
.inside__swiper.swiper-initialized { perspective: 1100px; }
.room { width: 72%; max-width: 520px; }
.room img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.room p { margin-top: 10px; font-family: var(--font-ja); color: var(--c-ink); text-align: center; letter-spacing: .14em; }
.inside__ctrl { display: none; align-items: center; gap: 8px; padding: 16px 20px 0; max-width: 720px; margin: 0 auto; }
.js .inside__ctrl { display: flex; }
.ctrl { min-width: 48px; height: 48px; padding: 0 12px; border: 1px solid var(--c-gray); background: transparent; color: var(--c-ink); font-family: var(--font); font-size: 17px; cursor: pointer; flex: none; }
.ctrl--text { font-size: 15px; }
.ctrl:hover, .ctrl:focus-visible { background: var(--c-ink); color: var(--c-bg); }
.inside .swiper-pagination { position: static; display: flex; justify-content: center; flex: 1; }
.inside .swiper-pagination-bullet { position: relative; width: 28px; height: 44px; margin: 0 !important; background: transparent; opacity: 1; border-radius: 0; }
.inside .swiper-pagination-bullet::before { content: ""; position: absolute; left: 50%; top: 50%; width: 6px; height: 6px; border-radius: 50%; transform: translate(-50%, -50%); border: 1px solid var(--c-ink); }
.inside .swiper-pagination-bullet-active::before { background: var(--c-ink); }
.swiper:not(.swiper-initialized) .swiper-wrapper { overflow-x: auto; scroll-snap-type: x mandatory; gap: 16px; padding: 0 20px; }
.swiper:not(.swiper-initialized) .swiper-slide { scroll-snap-align: center; }

/* 06 診療時間・料金 */
.hours__inner { max-width: 720px; }
.table { width: 100%; border-collapse: collapse; font-size: 15px; text-align: center; }
.table th, .table td { padding: 12px 4px; border-bottom: 1px solid var(--c-line); font-weight: 400; }
.table thead th { color: var(--c-accent-text); border-bottom-color: var(--c-gray); }
.table tbody th { text-align: left; white-space: nowrap; color: var(--c-ink); }
.table td { color: var(--c-ink); }
.hours__note { margin-top: 12px; font-size: 15px; color: var(--c-sub); }
.fee { margin-top: 32px; border-top: 1px solid var(--c-gray); }
.fee div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 16px; padding: 14px 0; border-bottom: 1px solid var(--c-line); }
.fee dt { color: var(--c-ink); }

/* 07 予約・アクセス */
.reserve { background: var(--c-ink); color: var(--c-on-ink); }
.reserve__title { font-family: var(--font-ja); font-weight: 300; font-size: clamp(28px, 3.2vw, 42px); letter-spacing: .12em; color: #fff; margin: 20px 0 16px; }
.reserve__btns { display: flex; flex-direction: column; gap: 14px; margin: 32px 0; }
.access div { display: grid; gap: 2px; padding: 14px 0; border-bottom: 1px solid #3a3a3c; }
.access dt { color: var(--c-on-ink-sub); font-size: 15px; }
.reserve__fiction { margin-top: 24px; color: var(--c-on-ink-sub); font-size: 15px; display: none; }
@media (min-width: 768px) { .reserve__btns { flex-direction: row; } }

.footer { padding: 56px 20px 40px; text-align: center; font-size: 15px; color: var(--c-sub); border-top: 1px solid var(--c-line); }
.footer__logo { font-family: var(--font-ja); font-weight: 500; font-size: 22px; letter-spacing: .2em; color: var(--c-ink); margin-bottom: 8px; }
.footer__fiction { margin-top: 12px; }

@media (min-width: 768px) { .panel { padding: 120px 7vw; } .hero { padding: 0; } .first { padding: 0; } .inside { padding-left: 0; padding-right: 0; } .inside__head { padding: 0 7vw; } }

/* ===== PCだけ：ページ全体が横に動く ===== */
.is-motion-pc .hprog { display: flex; align-items: center; gap: 16px; position: absolute; left: 48px; right: 48px; bottom: -2px; transform: translateY(100%); padding-top: 12px; pointer-events: none; }
.is-motion-pc .hprog__num { font-family: var(--font-en); font-size: 18px; color: var(--c-accent-text); white-space: nowrap; }
.is-motion-pc .hprog__num b { font-weight: 300; font-size: 24px; color: var(--c-ink); }
.is-motion-pc .hprog__bar { position: relative; flex: 1; height: 1px; background: var(--c-line); }
.is-motion-pc .hprog__bar i { position: absolute; left: 0; top: 0; bottom: 0; width: 100%; background: var(--c-ink); transform-origin: 0 50%; transform: scaleX(0); }
.is-motion-pc .spmenu { display: none; }
.is-motion-pc .hpage { overflow: hidden; }
.is-motion-pc .htrack { display: flex; width: max-content; height: 100vh; }
.is-motion-pc .panel { flex: none; width: 100vw; height: 100vh; overflow: hidden; padding: 150px 7vw 64px; border-right: 1px solid var(--c-line); }
.is-motion-pc .hero { padding: 0; }
.is-motion-pc .greet { grid-template-columns: 34vw 1fr; }
.is-motion-pc .greet__photo img { height: calc(100vh - 230px); aspect-ratio: auto; }
.is-motion-pc .greet__text { max-width: 520px; }
.is-motion-pc .symptom { display: flex; align-items: center; }
.is-motion-pc .symptom__inner { width: 100%; max-width: 980px; }
.is-motion-pc .first { width: 300vw; padding: 0; }
.is-motion-pc .first__stage { width: 100vw; }
.is-motion-pc .inside { width: 130vw; padding: 150px 0 48px; }
.is-motion-pc .inside .room { width: 34vw; max-width: none; }
.is-motion-pc .hours { display: flex; align-items: center; }
.is-motion-pc .reserve { display: flex; align-items: center; }
.is-motion-pc .reserve__inner { max-width: 760px; }
.is-motion-pc .reserve__fiction { display: block; }

/* A04：名前だけの幕（JSが足す。1回だけ） */
.curtain { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; background: var(--c-bg); pointer-events: none; }
.curtain__name { font-family: var(--font-ja); font-weight: 500; font-size: clamp(28px, 4vw, 52px); letter-spacing: .3em; color: var(--c-ink); white-space: nowrap; }

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