/* =========================================================
   高畑中央歯科 — デザインシステム
   名古屋市中川区・高畑駅の歯医者
   ========================================================= */

:root {
  /* Brand colors — 淡いスカイブルー × 温かみのあるゴールド/ベージュ（清潔感・上品・親しみ） */
  --teal: #4a8fb5;          /* primary soft blue */
  --teal-dark: #3a7596;
  --teal-darker: #2c5a74;
  --teal-light: #eaf3f8;    /* very light blue tint */
  --mint: #aed4e7;          /* light blue accent */
  --accent: #b3995f;        /* warm gold CTA */
  --accent-dark: #9c7f4e;
  --gold-grad-a: #d3c777;
  --gold-grad-b: #c8b114;

  /* Neutrals */
  --ink: #2e3340;           /* dark navy-charcoal text */
  --muted: #6b7280;
  --line: #e8e0d3;
  --sand: #f5eee2;          /* warm cream bg（原宿式の温かみ） */
  --sand-light: #faf6ef;    /* さらに淡いクリーム */
  --paper: #ffffff;

  /* Layout */
  --maxw: 1120px;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 18px 50px rgba(44, 90, 116, 0.10);
  --shadow-sm: 0 6px 20px rgba(46, 51, 64, 0.06);

  --header-h: 78px;

  --font-sans: "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Yu Gothic", "YuGothic", "Meiryo", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-serif: "Hiragino Mincho ProN", "Yu Mincho", "YuMincho", "Noto Serif JP", serif;
  --font-en: "Cormorant Garamond", "Times New Roman", serif;
}

/* ----------------------- reset / base ----------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; overflow-x: clip; }
body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.85;
  font-size: 16px;
  letter-spacing: .01em;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--teal-dark); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { line-height: 1.4; margin: 0 0 .6em; font-weight: 700; }
p { margin: 0 0 1.2em; }
ul { margin: 0 0 1.2em; padding-left: 1.2em; }

.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--teal); color: #fff; padding: 10px 16px; z-index: 1000;
}
.skip-link:focus { left: 8px; top: 8px; }

/* ----------------------- layout ----------------------- */
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }
.section { padding: 72px 0; }
.section--sand { background: var(--sand); }
.section--teal { background: var(--teal-dark); color: #fff; }
.narrow { max-width: 760px; margin-left: auto; margin-right: auto; }

.section-head { text-align: center; margin-bottom: 56px; }
.section-head .en {
  display: block; font-family: var(--font-en); font-weight: 600; font-style: normal;
  text-transform: uppercase; letter-spacing: .12em; line-height: 1;
  font-size: clamp(2.4rem, 6vw, 3.9rem); color: #e7dcc9;
}
.section-head h2 {
  font-size: clamp(1.4rem, 4vw, 1.95rem);
  font-family: var(--font-serif); font-weight: 600; letter-spacing: .08em;
  margin-top: 2px;
}
.section--sand .section-head .en { color: #e4d7c0; }
.section--teal .section-head .en { color: rgba(255,255,255,.16); }
.section--teal .section-head h2 { color: #fff; }

/* ----------------------- buttons ----------------------- */
.btn {
  display: inline-flex; align-items: center; gap: .5em; justify-content: center;
  padding: 14px 28px; border-radius: 999px; font-weight: 700; font-size: .98rem;
  border: 2px solid transparent; cursor: pointer; transition: .2s ease;
  text-decoration: none; line-height: 1.2;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn-primary { background: var(--teal); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--teal-dark); color:#fff; }
.btn-accent { background: var(--accent); color: #fff; box-shadow: var(--shadow-sm); }
.btn-accent:hover { background: var(--accent-dark); color:#fff; }
.btn-outline { background: transparent; color: var(--teal-dark); border-color: var(--teal); }
.btn-outline:hover { background: var(--teal); color: #fff; }
.btn-outline-light { background: rgba(255,255,255,.12); color: #fff; border-color: rgba(255,255,255,.85); }
.btn-outline-light:hover { background: #fff; color: var(--teal-darker); }
.btn-lg { padding: 17px 36px; font-size: 1.05rem; }

/* ----------------------- header ----------------------- */
.site-header {
  position: sticky; top: 0; z-index: 100; background: rgba(255,255,255,.96);
  backdrop-filter: blur(8px); border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--header-h); gap: 20px;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand .logo-mark {
  display: none; /* 一旦非表示。ロゴが決まったら display: grid に戻す */
  width: 40px; height: 40px; border-radius: 11px; background: var(--teal);
  place-items: center; color: #fff; font-weight: 700; flex: none;
}
.brand .logo-text { display: flex; flex-direction: column; line-height: 1.25; }
.brand { flex-shrink: 0; }
.brand .logo-text strong { font-size: 1.12rem; color: var(--ink); white-space: nowrap; }
.brand .logo-text small { font-size: .68rem; color: var(--muted); letter-spacing: .06em; white-space: nowrap; }
.brand:hover { text-decoration: none; }

.main-nav ul { display: flex; gap: 18px; list-style: none; margin: 0; padding: 0; }
.main-nav a { color: var(--ink); font-weight: 500; font-size: .93rem; white-space: nowrap; }
.main-nav a:hover { color: var(--teal); text-decoration: none; }

/* dropdown: 診療案内 */
.main-nav .has-sub { position: relative; }
.main-nav .sub-toggle {
  background: none; border: 0; padding: 0; cursor: pointer;
  color: var(--ink);
  font: inherit; font-weight: 500; font-size: .93rem; white-space: nowrap;
  display: inline-flex; align-items: center; gap: 5px;
  -webkit-appearance: none; appearance: none; -webkit-tap-highlight-color: transparent;
}
.main-nav .sub-toggle:hover,
.main-nav .sub-toggle:focus { color: var(--teal); outline: none; }
/* homepage 透過ヘッダー時は白文字、スクロール後は濃色に戻す */
body.home .site-header .main-nav .sub-toggle { color: #fff; }
body.home .site-header.scrolled .main-nav .sub-toggle { color: var(--ink); }
.main-nav .caret {
  width: 8px; height: 8px; border-right: 1.6px solid currentColor;
  border-bottom: 1.6px solid currentColor; transform: rotate(45deg) translate(-2px,-2px);
  transition: transform .2s;
}
.main-nav .has-sub.open .caret,
.main-nav .has-sub:hover .caret { transform: rotate(-135deg) translate(-2px,-2px); }

.main-nav .submenu {
  display: block;
  position: absolute; top: calc(100% + 10px); left: 50%;
  transform: translateX(-50%) translateY(-6px);
  width: 560px; max-width: calc(100vw - 40px);
  background: rgba(255,255,255,.86); backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 3px solid var(--teal);
  border-radius: 4px; box-shadow: 0 18px 44px rgba(16,30,40,.18);
  padding: 18px 8px; list-style: none; margin: 0;
  columns: 2; column-gap: 4px; gap: 0;
  opacity: 0; visibility: hidden;
  transition: opacity .2s ease, transform .2s ease, visibility .2s;
  z-index: 200;
}
.main-nav .has-sub:hover .submenu,
.main-nav .has-sub.open .submenu,
.main-nav .has-sub:focus-within .submenu {
  opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0);
}
.main-nav .submenu::before {
  content: ""; position: absolute; top: -9px; left: 50%; transform: translateX(-50%);
  border: 6px solid transparent; border-bottom-color: var(--teal); border-top: 0;
}
.main-nav .submenu li {
  display: block; break-inside: avoid;
}
.main-nav .submenu a {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 18px; font-size: .92rem; color: var(--ink) !important;
  font-family: var(--font-serif); letter-spacing: .02em;
  border-radius: 0; position: relative;
  transition: background .15s, color .15s, padding-left .15s;
}
.main-nav .submenu a::before {
  content: ""; width: 6px; height: 6px; flex: none;
  border-right: 1.6px solid var(--teal);
  border-bottom: 1.6px solid var(--teal);
  transform: rotate(-45deg);
  transition: transform .15s, border-color .15s;
}
.main-nav .submenu a:hover {
  background: var(--sand); color: var(--teal-dark) !important;
  padding-left: 22px;
}
.main-nav .submenu a:hover::before { border-color: var(--teal-dark); transform: rotate(-45deg) translate(2px,-2px); }

.header-cta { display: flex; align-items: center; gap: 12px; }
.header-tel { text-align: right; line-height: 1.2; }
.header-tel small { display: block; font-size: .68rem; color: var(--muted); }
.header-tel strong { font-size: 1.2rem; color: var(--teal-dark); font-family: var(--font-serif); white-space: nowrap; }

.nav-toggle {
  display: none; width: 46px; height: 46px; border: 1px solid var(--line);
  background: #fff; border-radius: 10px; cursor: pointer; padding: 0;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  content: ""; display: block; width: 22px; height: 2px; background: var(--ink);
  margin: 0 auto; position: relative; transition: .25s;
}
.nav-toggle span::before { position: absolute; top: -7px; }
.nav-toggle span::after  { position: absolute; top: 7px; }
.nav-open .nav-toggle span { background: transparent; }
.nav-open .nav-toggle span::before { top: 0; transform: rotate(45deg); }
.nav-open .nav-toggle span::after  { top: 0; transform: rotate(-45deg); }

/* ----------------------- homepage: 透過ヘッダー（写真にオーバーレイ） ----------------------- */
body.home .site-header { background: linear-gradient(to bottom, rgba(16,30,40,.34), rgba(16,30,40,0)); border-bottom-color: transparent; box-shadow: none; backdrop-filter: none; }
body.home .site-header .logo-text strong { color: #fff; }
body.home .site-header .logo-text small { color: rgba(255,255,255,.82); }
body.home .site-header .main-nav a { color: #fff; }
body.home .site-header .header-tel small { color: rgba(255,255,255,.82); }
body.home .site-header .header-tel strong { color: #fff; }
body.home .site-header .nav-toggle { background: rgba(255,255,255,.14); border-color: rgba(255,255,255,.55); }
body.home .site-header .nav-toggle span,
body.home .site-header .nav-toggle span::before,
body.home .site-header .nav-toggle span::after { background: #fff; }
/* スクロール後は通常の白ヘッダーに戻す */
body.home .site-header.scrolled { background: rgba(255,255,255,.97); border-bottom-color: var(--line); box-shadow: var(--shadow-sm); }
body.home .site-header.scrolled .logo-text strong { color: var(--ink); }
body.home .site-header.scrolled .logo-text small { color: var(--muted); }
body.home .site-header.scrolled .main-nav a { color: var(--ink); }
body.home .site-header.scrolled .header-tel small { color: var(--muted); }
body.home .site-header.scrolled .header-tel strong { color: var(--teal-dark); }
body.home .site-header.scrolled .nav-toggle { background: #fff; border-color: var(--line); }
body.home .site-header.scrolled .nav-toggle span,
body.home .site-header.scrolled .nav-toggle span::before,
body.home .site-header.scrolled .nav-toggle span::after { background: var(--ink); }

/* ----------------------- hero (full-bleed photo) ----------------------- */
.hero {
  position: relative; overflow: hidden; min-height: 620px; display: flex; align-items: center;
  background: linear-gradient(120deg, #6ea7c7 0%, #aed4e7 55%, #eaf3f8 100%);
}
/* スライドショー背景（3枚を24秒でクロスフェード） */
.hero-slides { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.hero-slide {
  position: absolute; inset: 0;
  background-size: cover; background-position: right center;
  background-repeat: no-repeat;
  opacity: 0;
  animation: heroFade 24s infinite;
}
.hero-slide:nth-child(1) { animation-delay: 0s; opacity: 1; }
.hero-slide:nth-child(2) { animation-delay: 8s; }
.hero-slide:nth-child(3) { animation-delay: 16s; }
@keyframes heroFade {
  0%   { opacity: 0; }
  4%   { opacity: 1; }
  33%  { opacity: 1; }
  38%  { opacity: 0; }
  100% { opacity: 0; }
}
/* 暗いオーバーレイ（左側テキスト読ませる用） */
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(95deg, rgba(22,44,58,.86) 0%, rgba(28,54,70,.66) 34%, rgba(40,70,90,.22) 56%, rgba(40,70,90,0) 74%);
}
.hero::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 90px; z-index: 2;
  background: linear-gradient(to top, var(--paper), rgba(255,255,255,0));
}
@media (prefers-reduced-motion: reduce) {
  .hero-slide { animation: none; }
  .hero-slide:nth-child(1) { opacity: 1; }
  .hero-slide:nth-child(2), .hero-slide:nth-child(3) { opacity: 0; }
}
.hero-inner { padding: 90px 0 110px; position: relative; z-index: 2; max-width: 540px; }
.hero .hero-en {
  display: block; font-family: var(--font-en); font-style: italic; color: #fff;
  font-size: clamp(1.5rem, 4vw, 2.3rem); font-weight: 500; letter-spacing: .04em;
  margin-bottom: 14px; opacity: .95; text-shadow: 0 2px 18px rgba(0,0,0,.25);
}
.hero h1 {
  font-family: var(--font-serif); font-weight: 600; color: #fff;
  font-size: clamp(1.8rem, 5vw, 2.9rem); line-height: 1.5; margin-bottom: 22px;
  text-shadow: 0 2px 20px rgba(0,0,0,.28);
}
.hero h1 .hl { color: #fff; }
.hero .lead { font-size: 1.05rem; color: #fff; margin-bottom: 32px; max-width: 540px;
  text-shadow: 0 1px 12px rgba(0,0,0,.3); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero-badges { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 30px; }
.hero-badges span {
  background: rgba(255,255,255,.92); color: var(--teal-darker);
  font-size: .82rem; font-weight: 700; padding: 9px 16px; border-radius: 999px;
  backdrop-filter: blur(4px);
}
.hero-photo-note {
  position: absolute; right: 16px; bottom: 16px; z-index: 2; color: rgba(255,255,255,.7);
  font-size: .72rem; background: rgba(0,0,0,.25); padding: 5px 12px; border-radius: 999px;
}

/* homepage hero: 写真の下にヘッダーを潜らせて没入感を出す */
body.home .hero { margin-top: calc(-1 * var(--header-h)); min-height: 92vh; }
body.home .hero .hero-inner { padding-top: calc(var(--header-h) + 48px); }
body.home .hero h1 { color: var(--ink); text-shadow: none; }
body.home .hero h1 .ln {
  display: inline; background: rgba(255,255,255,.85); box-decoration-break: clone;
  -webkit-box-decoration-break: clone; padding: .07em .36em; line-height: 1.95; border-radius: 3px;
}
body.home .hero h1 .ln .hl { color: var(--teal); border-bottom: none; padding: 0; background: none; }

/* ----------------------- feature strip ----------------------- */
.strip {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 0;
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  background: #fff; box-shadow: var(--shadow-sm); margin-top: -38px; position: relative; z-index: 5;
}
.strip > div { padding: 28px 24px; text-align: center; }
.strip > div + div { border-left: 1px solid var(--line); }
.strip .ico { color: var(--teal); margin-bottom: 10px; display: flex; justify-content: center; }
.strip .ico svg { width: 34px; height: 34px; }
.strip strong { display: block; font-size: 1.05rem; }
.strip small { color: var(--muted); }

/* ----------------------- cards (services) ----------------------- */
.grid { display: grid; gap: 22px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 26px; transition: .2s; display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--mint); }
.card .ico {
  width: 64px; height: 64px; border-radius: 50%; background: var(--teal-light);
  display: grid; place-items: center; color: var(--teal-dark); margin-bottom: 18px;
}
.card .ico svg { width: 32px; height: 32px; }
.card h3 { font-size: 1.18rem; margin-bottom: 8px; }
.card p { color: var(--muted); font-size: .94rem; margin-bottom: 16px; }
.card .more { margin-top: auto; font-weight: 700; color: var(--teal); font-size: .9rem; }
.card.is-feature { border-color: var(--teal); box-shadow: var(--shadow); }
.card .tag {
  align-self: flex-start; background: var(--accent); color: #fff; font-size: .72rem;
  font-weight: 700; padding: 4px 10px; border-radius: 999px; margin-bottom: 14px;
}

/* ----------------------- menu grid (診療案内：原宿式 写真カード) ----------------------- */
.menu-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.mcard {
  position: relative; min-height: 196px; border-radius: 10px; overflow: hidden;
  display: flex; align-items: center; justify-content: center; text-align: center; color: #fff;
  background: radial-gradient(120% 100% at 30% 0%, #356a86 0%, #1d3d4f 72%);
  transition: transform .25s ease, box-shadow .25s ease;
}
.mcard img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.mcard::after { content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, rgba(20,34,46,.32) 0%, rgba(18,30,42,.62) 100%); }
.mcard:hover { transform: translateY(-4px); box-shadow: var(--shadow); text-decoration: none; }
.mcard:hover img { transform: scale(1.06); }
.mcard img { transition: transform .45s ease; }
.mcard .mc-label { position: relative; z-index: 2; padding: 14px 12px; }
.mcard .ja { font-family: var(--font-serif); font-weight: 600; font-size: 1.18rem; line-height: 1.45; text-shadow: 0 1px 10px rgba(0,0,0,.35); }
.mcard .en { display: block; margin-top: 7px; font-size: .68rem; letter-spacing: .2em; text-transform: uppercase; opacity: .78; }

/* ----------------------- reason（番号付き理念カード：院長挨拶ページ用） ----------------------- */
.reason {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px 26px; display: flex; gap: 16px; align-items: flex-start;
  box-shadow: 0 3px 14px rgba(31,42,55,.04);
}
.reason .num {
  font-family: var(--font-en); font-style: italic; color: var(--accent);
  font-size: 2.4rem; font-weight: 600; line-height: 1; flex: none; opacity: .85;
}
.reason h3 {
  font-family: var(--font-serif); font-size: 1.16rem; margin: 0 0 8px;
  color: var(--teal-darker); letter-spacing: .04em;
}
.reason p { color: var(--ink); font-size: .93rem; line-height: 1.8; margin: 0; }

/* ----------------------- reasons: 写真付きカードグリッド ----------------------- */
.reasons-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px;
}
.rcard {
  background: #fff; border-radius: 14px; overflow: hidden;
  box-shadow: 0 6px 22px rgba(31,42,55,.06);
  border: 1px solid rgba(179,153,95,.14);
  display: flex; flex-direction: column;
  transition: transform .28s ease, box-shadow .28s ease;
}
.rcard:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 34px rgba(31,42,55,.11);
}
.rcard .rcard-photo {
  aspect-ratio: 4/3; border: 0; border-radius: 0; margin: 0;
}
.rcard-body {
  padding: 26px 26px 28px; flex: 1;
  display: flex; flex-direction: column; gap: 10px;
  position: relative;
}
.rcard-num {
  position: absolute; top: 18px; right: 24px;
  font-family: var(--font-en); font-style: italic; font-size: 2rem; font-weight: 600;
  color: var(--teal); opacity: .38; line-height: 1;
}
.rcard-body h3 {
  font-family: var(--font-serif); font-size: 1.22rem; letter-spacing: .04em;
  color: var(--teal-darker); margin: 0; padding-right: 60px; line-height: 1.4;
}
.rcard-body p {
  color: var(--ink); font-size: .93rem; line-height: 1.85; margin: 0;
}

@media (max-width: 900px) {
  .reasons-grid { grid-template-columns: 1fr 1fr; gap: 18px; }
  .rcard-body { padding: 22px 22px 24px; }
  .rcard-body h3 { font-size: 1.12rem; }
}
@media (max-width: 560px) {
  .reasons-grid { grid-template-columns: 1fr; }
}


/* ----------------------- greeting (院長挨拶) ----------------------- */
.greeting { display: grid; grid-template-columns: .85fr 1.15fr; gap: 44px; align-items: center; }
.greeting-photo {
  border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
  position: relative; aspect-ratio: 3/4;
  background: linear-gradient(150deg, #aed4e7 0%, #d8e9f2 55%, #f3ece0 100%);
  display: grid; place-items: center; text-align: center;
}
.greeting-photo img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: center 30%;
}
.greeting-photo .ph-slot { color: var(--teal-darker); opacity: .8; font-size: .88rem; padding: 0 24px; }
.greeting-lead { font-family: var(--font-serif); font-size: clamp(1.3rem, 3.2vw, 1.7rem); color: var(--teal-darker); line-height: 1.7; margin-bottom: 20px; }
.greeting-body p { color: var(--ink); }
.greeting-body .sign { text-align: right; font-family: var(--font-serif); font-size: 1.05rem; color: var(--ink); margin-top: 8px; }
.greeting-body .sign small { display: block; color: var(--muted); font-family: var(--font-sans); font-size: .8rem; }

/* ----------------------- implant banner ----------------------- */
.implant-banner {
  display: grid; grid-template-columns: 1fr 1fr; border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow); min-height: 330px;
}
.ib-text {
  background: linear-gradient(135deg, #232f4d 0%, #2c324c 100%); color: #fff;
  padding: 48px 44px; display: flex; flex-direction: column; justify-content: center;
}
.ib-badge {
  align-self: flex-start; background: linear-gradient(90deg, #d3c777, #c8b114);
  color: #3a2f12; font-weight: 700; font-size: .82rem; padding: 8px 18px;
  border-radius: 6px; margin-bottom: 18px;
}
.ib-text .lead-jp {
  font-family: var(--font-serif); font-weight: 600; line-height: 1.5;
  font-size: clamp(1.35rem, 2.8vw, 1.95rem); margin: 0 0 14px;
}
.ib-en {
  font-family: var(--font-en); letter-spacing: .08em; line-height: 1;
  font-size: clamp(2.2rem, 5vw, 3.2rem); color: rgba(255,255,255,.9); margin-bottom: 24px;
}
.ib-text .btn { align-self: flex-start; }
.ib-img { position: relative; background: #fff; min-height: 240px; }
.ib-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* ----------------------- feature photo cards ----------------------- */
.feature-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 22px; }
.fcard {
  position: relative; min-height: 310px; border-radius: var(--radius); overflow: hidden;
  display: flex; align-items: center; justify-content: center; text-align: center; color: #fff;
}
.fcard img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .45s ease; }
.fcard::before { content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, rgba(18,28,42,.32) 0%, rgba(18,28,42,.55) 100%); }
.fcard .fc-frame { position: absolute; inset: 16px; border: 1px solid rgba(255,255,255,.55); z-index: 2; pointer-events: none; }
.fcard:hover img { transform: scale(1.06); }
.fcard:hover { text-decoration: none; }
.fc-inner { position: relative; z-index: 2; padding: 24px; }
.fc-inner .ja { font-family: var(--font-serif); font-size: 1.5rem; font-weight: 600; text-shadow: 0 2px 14px rgba(0,0,0,.4); }
.fc-inner .en { display: block; font-family: var(--font-en); font-style: italic; letter-spacing: .12em; font-size: .95rem; opacity: .9; margin-top: 6px; }
.fc-arrow { display: inline-block; margin-top: 18px; width: 46px; height: 1px; background: rgba(255,255,255,.85); position: relative; }
.fc-arrow::after { content: "›"; position: absolute; right: -3px; top: -12px; font-size: 1.1rem; }

/* ----------------------- access / hours ----------------------- */
/* ----------------------- ACCESS section (refined) ----------------------- */
.access-section {
  background:
    linear-gradient(180deg, var(--sand) 0%, #f6efe1 100%);
  padding: 100px 0 110px;
  position: relative;
}
.access-section::before, .access-section::after {
  content: ""; position: absolute; left: 0; right: 0; height: 1px;
  background: linear-gradient(to right, transparent, rgba(179,153,95,.3), transparent);
}
.access-section::before { top: 0; }
.access-section::after  { bottom: 0; }

.access-layout {
  display: grid; grid-template-columns: 1fr 1.05fr; gap: 32px;
  align-items: start;
}
.ac-card {
  background: #fff; border-radius: 14px;
  padding: 34px 36px;
  box-shadow: 0 10px 40px rgba(31,42,55,.06);
  border: 1px solid rgba(179,153,95,.14);
  position: relative;
}
.ac-card-en {
  font-family: var(--font-en); font-style: italic; font-size: 1.05rem;
  color: var(--teal); letter-spacing: .08em;
  margin-bottom: 22px; opacity: .8;
  padding-bottom: 14px; border-bottom: 1px solid var(--line);
}

/* 医院情報 */
.ac-info { margin: 0 0 26px; }
.ac-info-row { display: grid; grid-template-columns: 84px 1fr; gap: 16px; padding: 14px 0; }
.ac-info-row + .ac-info-row { border-top: 1px dashed rgba(179,153,95,.28); }
.ac-info dt {
  font-size: .78rem; font-weight: 700; color: var(--teal-dark);
  letter-spacing: .1em; padding-top: 4px;
}
.ac-info dd {
  margin: 0; font-size: .95rem; line-height: 1.75; color: var(--ink);
  font-family: var(--font-serif);
}

/* 電話番号ブロック */
.ac-tel {
  display: flex; flex-direction: column; align-items: center;
  padding: 24px 20px; margin-bottom: 20px;
  background: linear-gradient(135deg, var(--sand-light, #faf6ef) 0%, #fbf4e4 100%);
  border-radius: 10px;
  border: 1px solid rgba(179,153,95,.22);
}
.ac-tel-label {
  font-size: .78rem; color: var(--muted); letter-spacing: .12em;
  margin-bottom: 6px;
}
.ac-tel-num {
  font-family: var(--font-serif); font-size: 2.2rem; font-weight: 600;
  color: var(--teal-darker); letter-spacing: .04em; line-height: 1.1;
  text-decoration: none;
}
.ac-tel-num:hover { color: var(--teal); text-decoration: none; }
.ac-tel-note {
  font-size: .78rem; color: var(--muted); margin-top: 6px;
}

/* WEB予約ボタン */
.ac-web-btn {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 26px; border-radius: 10px;
  background: var(--teal-darker); color: #fff;
  text-decoration: none;
  transition: background .2s, transform .2s;
  box-shadow: 0 6px 20px rgba(31,66,84,.24);
}
.ac-web-btn:hover {
  background: var(--teal); color: #fff; text-decoration: none;
  transform: translateY(-2px);
}
.ac-web-btn-txt { display: flex; flex-direction: column; }
.ac-web-btn-lbl { font-family: var(--font-serif); font-size: 1.06rem; font-weight: 600; letter-spacing: .04em; }
.ac-web-btn-sub { font-size: .74rem; opacity: .75; letter-spacing: .1em; margin-top: 2px; }
.ac-web-btn-arr { width: 22px; height: 22px; flex: none; }

/* 診療時間カード */
.ac-side { display: flex; flex-direction: column; gap: 26px; }
.ac-card--hours { padding: 30px 32px; }
.hours-table {
  width: 100%; border-collapse: collapse; background: transparent;
  border-radius: 0; box-shadow: none;
}
.hours-table th, .hours-table td {
  padding: 12px 4px; text-align: center; font-size: .93rem;
  border: 0;
}
.hours-table thead th {
  background: none; color: var(--teal-darker); font-weight: 700;
  font-family: var(--font-serif); font-size: .95rem;
  border-bottom: 2px solid var(--teal); padding: 10px 4px;
}
.hours-table thead th.th-off { color: var(--muted); }
.hours-table tbody th {
  background: none; text-align: left; padding-left: 6px; white-space: nowrap;
  font-family: var(--font-en); font-style: italic; font-weight: 600;
  color: var(--teal-dark); font-size: .95rem;
}
.hours-table tbody tr { border-bottom: 1px dashed rgba(179,153,95,.22); }
.hours-table tbody tr:last-child { border-bottom: 0; }
.hours-table tbody td {
  color: var(--teal-dark); font-weight: 600; font-size: 1.05rem;
}
.hours-table .off {
  color: rgba(179,153,95,.4); font-weight: 400;
}
.ac-hours-notes {
  list-style: none; padding: 0; margin: 22px 0 0;
  display: flex; flex-direction: column; gap: 8px;
  font-size: .85rem;
}
.ac-hours-notes li {
  display: grid; grid-template-columns: 110px 1fr; gap: 10px;
  padding: 8px 0; border-top: 1px dashed rgba(179,153,95,.22);
  color: var(--ink);
}
.ac-hours-notes strong {
  color: var(--teal-darker); font-family: var(--font-serif); font-weight: 600;
  letter-spacing: .04em;
}

/* 地図 埋め込み */
.ac-map-wrap {
  position: relative; border-radius: 12px; overflow: hidden;
  box-shadow: 0 10px 30px rgba(31,42,55,.14);
  background: #fff;
}
.ac-map-embed {
  display: block; width: 100%; height: 340px; border: 0;
  filter: saturate(.9);
}
.ac-map-link {
  position: absolute; right: 14px; bottom: 14px;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 16px; border-radius: 999px;
  background: rgba(255,255,255,.96); backdrop-filter: blur(6px);
  color: var(--teal-darker); text-decoration: none;
  font-family: var(--font-serif); font-size: .88rem; letter-spacing: .04em;
  box-shadow: 0 4px 14px rgba(31,42,55,.14);
  transition: background .2s, transform .2s;
}
.ac-map-link:hover {
  background: #fff; color: var(--teal); text-decoration: none;
  transform: translateY(-1px);
}
.ac-map-link svg { width: 16px; height: 16px; color: var(--accent); }


/* ----------------------- news ----------------------- */
.news-list { list-style: none; padding: 0; margin: 0; }
.news-empty { padding: 24px 0; color: var(--muted); text-align: center; font-size: .92rem; }
.news-item {
  display: grid; grid-template-columns: 170px 1fr;
  gap: 22px 26px; padding: 22px 0;
  border-bottom: 1px solid var(--line);
  align-items: start;
}
.news-item.has-img .news-photo { grid-column: 2; margin-top: 6px; }
.news-item:first-child { padding-top: 0; }
.news-item:last-child { border-bottom: 0; }
.news-meta { display: flex; align-items: center; gap: 10px; padding-top: 4px; flex-wrap: wrap; }
.news-meta time {
  font-family: var(--font-en); font-size: 1rem; color: var(--muted);
  font-style: italic; letter-spacing: .02em;
}
.news-meta .cat {
  font-size: .74rem; font-weight: 700; padding: 3px 12px; border-radius: 999px;
  letter-spacing: .04em; flex: none;
}
.news-meta .cat--info { background: var(--teal-light); color: var(--teal-dark); }
.news-meta .cat--close { background: #fbe9d7; color: #a15a1f; }
.news-meta .cat--care { background: #e6efe1; color: #4d7a3e; }
.news-meta .cat--blog { background: #ece3d1; color: #7a5a2a; }
.news-body h3 {
  font-family: var(--font-serif); font-size: 1.08rem; color: var(--ink);
  margin: 0 0 6px; font-weight: 600; line-height: 1.55;
}
.news-body p { color: var(--muted); font-size: .92rem; line-height: 1.8; margin: 0; }
.news-photo { margin: 0; max-width: 420px; }
.news-photo img {
  width: 100%; height: auto; display: block;
  border-radius: 8px; box-shadow: 0 4px 16px rgba(31,42,55,.08);
}

/* ----------------------- CTA band ----------------------- */
/* ----------------------- CTA section (refined) ----------------------- */
.cta-section {
  padding: 90px 0 100px;
  background:
    radial-gradient(circle at 20% 20%, rgba(179,153,95,.14), transparent 45%),
    radial-gradient(circle at 80% 80%, rgba(31,66,84,.9), transparent 55%),
    linear-gradient(135deg, var(--teal-darker) 0%, #1c3a4e 100%);
  color: #fff; position: relative; overflow: hidden;
}
.cta-section::before {
  content: ""; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 60px; height: 2px; background: var(--accent);
}
.cta-card {
  max-width: 820px; margin: 0 auto; text-align: center; position: relative;
}
.cta-en {
  display: block; font-family: var(--font-en); font-style: italic;
  color: var(--accent); font-size: 1.05rem; letter-spacing: .16em;
  margin-bottom: 14px; opacity: .95;
}
.cta-card h2 {
  font-family: var(--font-serif); font-weight: 600;
  font-size: clamp(1.6rem, 4vw, 2.3rem); color: #fff; line-height: 1.55;
  margin: 0 0 16px; letter-spacing: .04em;
}
.cta-lead {
  color: rgba(255,255,255,.82); font-size: .98rem; line-height: 1.85;
  margin: 0 auto 36px; max-width: 560px;
}
.cta-actions {
  display: grid; grid-template-columns: 1fr 1fr; gap: 18px;
  max-width: 620px; margin: 0 auto;
}
.cta-btn {
  display: flex; align-items: center; gap: 16px;
  padding: 20px 24px; border-radius: 12px;
  text-decoration: none;
  transition: transform .2s, box-shadow .2s;
  text-align: left;
}
.cta-btn:hover { transform: translateY(-3px); text-decoration: none; }
.cta-btn svg { width: 26px; height: 26px; flex: none; }
.cta-btn-body { display: flex; flex-direction: column; }
.cta-btn-label { font-size: .74rem; letter-spacing: .14em; opacity: .8; margin-bottom: 3px; }
.cta-btn-value { font-family: var(--font-serif); font-size: 1.2rem; font-weight: 600; letter-spacing: .04em; line-height: 1.1; }
.cta-btn--tel {
  background: #fff; color: var(--teal-darker);
  box-shadow: 0 10px 30px rgba(0,0,0,.2);
}
.cta-btn--tel:hover { box-shadow: 0 16px 38px rgba(0,0,0,.28); color: var(--teal-darker); }
.cta-btn--tel svg { color: var(--teal); }
.cta-btn--web {
  background: var(--accent); color: #fff;
  box-shadow: 0 10px 30px rgba(179,153,95,.4);
}
.cta-btn--web:hover { background: var(--accent-dark, #9c8250); color: #fff; box-shadow: 0 16px 38px rgba(179,153,95,.5); }

/* サブページの旧CTAバンド（section--teal 内の .cta-band） */
.cta-band { text-align: center; }
.cta-band h2 { font-family: var(--font-serif); font-size: clamp(1.5rem, 4vw, 2.1rem); color: #fff; margin: 0 0 12px; }
.cta-band p { color: rgba(255,255,255,.85); margin: 0 auto; max-width: 560px; }
.cta-band .actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-top: 26px; }
.cta-band .btn-outline { color: #fff; border-color: rgba(255,255,255,.7); background: transparent; }
.cta-band .btn-outline:hover { background: #fff; color: var(--teal-dark); }

/* ----------------------- footer ----------------------- */
.site-footer { background: var(--ink); color: #cdd5db; padding: 56px 0 120px; font-size: .92rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 36px; }
.site-footer h4 { color: #fff; font-size: 1rem; margin-bottom: 14px; }
.site-footer a { color: #cdd5db; }
.site-footer a:hover { color: var(--mint); }
.footer-nav { list-style: none; padding: 0; margin: 0; }
.footer-nav li { padding: 5px 0; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); margin-top: 40px; padding-top: 22px; text-align: center; font-size: .82rem; color: #8b97a1; }

/* ----------------------- clinic gallery & equipment ----------------------- */
.clinic-gallery {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px;
}
.equipment-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px;
}
.equipment-grid--2 {
  grid-template-columns: repeat(2, 1fr); max-width: 860px; margin: 0 auto;
}

/* photo frame (placeholder that becomes a photo later) */
.pframe {
  margin: 0; aspect-ratio: 4/3;
  background:
    linear-gradient(135deg, rgba(221,209,183,.35) 0%, rgba(238,231,215,.7) 100%);
  border: 1.5px dashed rgba(179,153,95,.4);
  border-radius: 10px;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 10px;
  position: relative; overflow: hidden;
  transition: border-color .2s, transform .25s ease;
}
.pframe:hover { border-color: rgba(179,153,95,.7); transform: translateY(-2px); }
.pframe .pf-icon {
  width: 34px; height: 34px; color: rgba(179,153,95,.55);
  flex: none;
}
.pframe figcaption {
  font-size: .82rem; color: var(--muted);
  font-family: var(--font-sans); letter-spacing: .04em;
  text-align: center; padding: 0 10px;
}
.pframe img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; z-index: 1;
}
.pframe img + .pf-icon, .pframe img + .pf-icon + figcaption { display: none; }
/* 写真あり時はキャプションを写真下部にオーバーレイ */
.pframe:has(img) figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 2;
  background: linear-gradient(to top, rgba(0,0,0,.6) 0%, rgba(0,0,0,.35) 55%, transparent 100%);
  color: #fff; padding: 20px 12px 10px;
  font-size: .8rem; letter-spacing: .06em;
}
.pframe--wide { aspect-ratio: 3/2; }

.equip-card {
  background: #fff; border-radius: 12px; overflow: hidden;
  box-shadow: 0 4px 20px rgba(31,42,55,.06);
  border: 1px solid var(--line);
  display: flex; flex-direction: column;
}
.equip-card .pframe {
  border: 0; border-radius: 0; margin: 0;
  background:
    linear-gradient(135deg, rgba(210,196,168,.45) 0%, rgba(232,222,200,.75) 100%);
}
.equip-body { padding: 22px 24px 26px; }
.equip-body h3 {
  font-family: var(--font-serif); font-size: 1.2rem;
  margin: 0 0 10px; color: var(--teal-darker);
}
.equip-body p {
  font-size: .93rem; color: var(--ink); line-height: 1.8; margin: 0;
}

@media (max-width: 900px) {
  .clinic-gallery { grid-template-columns: repeat(3, 1fr); gap: 12px; }
  .equipment-grid { grid-template-columns: 1fr; gap: 20px; }
}
@media (max-width: 640px) {
  .clinic-gallery { grid-template-columns: 1fr 1fr; gap: 10px; }
  .pframe figcaption { font-size: .76rem; }
  .pframe .pf-icon { width: 28px; height: 28px; }
}

/* ----------------------- mobile sticky CTA ----------------------- */
.mobile-cta {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 90; display: none;
  grid-template-columns: 1fr 1fr; gap: 10px; padding: 10px 12px;
  padding-bottom: calc(10px + env(safe-area-inset-bottom));
  background: rgba(255,255,255,.97); backdrop-filter: blur(10px);
  box-shadow: 0 -6px 24px rgba(31,42,55,.14);
}
.mobile-cta a {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  border-radius: 999px; padding: 14px 8px; font-weight: 700; font-size: .98rem;
  text-decoration: none; line-height: 1; transition: .2s;
}
.mobile-cta svg { width: 19px; height: 19px; flex: none; }
.mobile-cta .tel { background: #fff; color: var(--teal-dark); border: 1.5px solid var(--teal); }
.mobile-cta .tel:active { background: var(--teal-light); }
.mobile-cta .resv { background: var(--accent); color: #fff; box-shadow: 0 5px 16px rgba(179,153,95,.45); }
.mobile-cta .resv:active { background: var(--accent-dark); }

/* ----------------------- breadcrumbs ----------------------- */
.breadcrumb { background: var(--sand); border-bottom: 1px solid var(--line); }
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 12px 0; font-size: .82rem; color: var(--muted); }
.breadcrumb li::after { content: "›"; margin-left: 8px; color: var(--line); }
.breadcrumb li:last-child::after { content: ""; }

/* ----------------------- page hero (sub pages) ----------------------- */
.page-hero {
  background: linear-gradient(160deg, #eaf3f8 0%, #f3ece0 100%); padding: 60px 0;
  border-bottom: 1px solid var(--line);
}
.page-hero .en { color: var(--teal); font-family: var(--font-en); font-style: italic; font-weight: 600; letter-spacing: .05em; font-size: 1.3rem; }
.page-hero h1 { font-family: var(--font-serif); font-size: clamp(1.7rem, 4.5vw, 2.5rem); margin: 6px 0 0; }

/* prose */
.prose h2 { font-family: var(--font-serif); font-size: 1.55rem; margin-top: 1.8em; padding-bottom: .35em; border-bottom: 2px solid var(--teal-light); }
.prose h3 { font-size: 1.2rem; color: var(--teal-dark); margin-top: 1.5em; }
.prose table { width: 100%; border-collapse: collapse; margin: 1em 0; }
.prose th, .prose td { border: 1px solid var(--line); padding: 12px 14px; text-align: left; }
.prose thead th { background: var(--teal-dark); color: #fff; }
.prose tbody th { background: var(--sand); }

/* 写真の差し込み枠（プレースホルダー。後で<img>に差し替え） */
.img-slot {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 4px; text-align: center; aspect-ratio: 16 / 9; margin: 1.7em 0; padding: 24px;
  border-radius: var(--radius); border: 2px dashed var(--mint);
  background: var(--teal-light); color: var(--teal-dark); font-weight: 700; font-size: .95rem;
}
.img-slot::before { content: "📷"; font-size: 1.9rem; line-height: 1; opacity: .85; margin-bottom: 4px; }
.img-slot small { font-weight: 500; color: var(--muted); font-size: .78rem; }
.img-slot.portrait { aspect-ratio: 3 / 4; max-width: 420px; margin-left: auto; margin-right: auto; }

.faq-item { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 20px 24px; margin-bottom: 14px; }
.faq-item .q { font-weight: 700; color: var(--teal-dark); margin: 0 0 8px; display: flex; gap: 10px; }
.faq-item .q::before { content: "Q"; color: var(--accent); font-family: var(--font-serif); }
.faq-item .a { color: var(--muted); margin: 0; }

/* ----------------------- responsive ----------------------- */
@media (max-width: 1140px) {
  .header-tel { display: none; }
  .main-nav ul { gap: 15px; }
}

@media (max-width: 900px) {
  .hero { min-height: 520px;
    background-image:
      linear-gradient(180deg, rgba(22,44,58,.5) 0%, rgba(22,44,58,.42) 45%, rgba(22,44,58,.72) 100%),
      url('../images/hero.jpg'),
      linear-gradient(120deg, #6ea7c7, #aed4e7);
    background-position: 70% center;
  }
  .hero-inner { padding: 56px 0 72px; max-width: 100%; }
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .implant-banner { grid-template-columns: 1fr; }
  .ib-img { order: -1; min-height: 210px; }
  .menu-grid { grid-template-columns: repeat(3, 1fr); }
  .access-layout { grid-template-columns: 1fr; gap: 22px; }
  .ac-card { padding: 28px 24px; }
  .ac-card--hours { padding: 26px 20px; }
  .hours-table th, .hours-table td { font-size: .82rem; padding: 10px 2px; }
  .hours-table tbody th { font-size: .82rem; padding-left: 4px; }
  .cta-actions { grid-template-columns: 1fr; }
  .access-section { padding: 68px 0 78px; }
  .cta-section { padding: 68px 0 78px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  /* ハンバーガーメニュー（タブレット以下） */
  .main-nav {
    position: fixed; inset: var(--header-h) 0 0 0; background: #fff; padding: 24px;
    transform: translateX(100%); transition: transform .28s ease; overflow-y: auto;
    border-top: 1px solid var(--line);
  }
  .nav-open .main-nav { transform: translateX(0); }
  .main-nav ul { flex-direction: column; gap: 0; }
  .main-nav li { border-bottom: 1px solid var(--line); }
  .main-nav a { display: block; padding: 15px 4px; font-size: 1.05rem; }
  .nav-toggle { display: block; }
  /* 開いた白いメニュー内ではリンクを濃色に */
  body.home .site-header .main-nav a { color: var(--ink); }
  /* モバイルでは診療案内をアコーディオンに */
  .main-nav .sub-toggle {
    display: flex; width: 100%; padding: 15px 4px; font-size: 1.05rem;
    justify-content: space-between; color: var(--ink);
  }
  .main-nav .submenu {
    position: static; transform: none; opacity: 1; visibility: visible;
    min-width: 0; box-shadow: none; border: 0; padding: 0 0 8px 16px;
    display: none; background: var(--sand-light, #faf6ef);
    border-radius: 0;
  }
  .main-nav .has-sub.open .submenu { display: block; }
  .main-nav .has-sub:hover .submenu { display: none; }
  .main-nav .submenu { columns: 1; }
  .main-nav .submenu li { border-bottom: 0; }
  .main-nav .submenu a { padding: 14px 8px; font-size: .95rem; }
}
@media (max-width: 720px) {
  .header-cta .btn { display: none; }
  /* スマホはスライドショー無効・オーバーレイ二重掛け防止 */
  .hero-slides { display: none; }
  .hero::before { display: none; }
  /* hero（スマホ：full-bleed写真＋オーバーレイテキスト、白箱撤廃） */
  .hero {
    flex-direction: row; align-items: center; min-height: 68vh;
    background-image:
      linear-gradient(165deg, rgba(16,32,42,.5) 0%, rgba(16,32,42,.2) 42%, rgba(16,32,42,.68) 100%),
      url('../images/hero-mobile.jpg'),
      linear-gradient(120deg, #6ea7c7, #aed4e7);
    background-size: cover; background-position: 62% 40%; background-repeat: no-repeat;
  }
  .hero::after {
    content: ""; display: block;
    position: absolute; left: 0; right: 0; bottom: -1px; height: 74px; z-index: 1;
    background: linear-gradient(to top, var(--paper), rgba(255,255,255,0));
  }
  body.home .hero { min-height: 68vh; margin-top: calc(-1 * var(--header-h)); }
  body.home .hero .hero-inner { padding-top: calc(var(--header-h) + 32px); padding-bottom: 80px; }
  .hero-inner { max-width: 100%; padding: 40px 0 90px; position: relative; z-index: 2; }
  .hero .hero-en {
    font-size: 1.15rem; color: #fff; opacity: .95; margin-bottom: 10px;
    text-shadow: 0 2px 12px rgba(0,0,0,.4);
  }
  .hero h1 { font-size: 1.7rem; line-height: 1.6; margin-bottom: 16px; }
  /* 白ハイライトボックスをスマホでは撤廃 → 白文字＋シャドウ */
  body.home .hero h1 { color: #fff; text-shadow: 0 2px 14px rgba(0,0,0,.5); }
  body.home .hero h1 .ln {
    display: inline; background: transparent; padding: 0;
    line-height: 1.6; border-radius: 0;
  }
  body.home .hero h1 .ln .hl {
    color: #fff; padding: 0 0 3px; background: none;
    border-bottom: 2.5px solid rgba(255,255,255,.55);
  }
  .hero .lead {
    color: #fff; font-size: .95rem; margin-bottom: 24px;
    text-shadow: 0 1px 8px rgba(0,0,0,.5);
  }
  .hero-actions { flex-direction: column; align-items: stretch; gap: 10px; }
  .hero-actions .btn { width: 100%; }
  .btn-lg { padding: 15px 22px; font-size: 1rem; }
  .hero-badges { display: flex; gap: 8px; margin-top: 22px; flex-wrap: wrap; }
  .hero-badges span {
    background: rgba(255,255,255,.15); color: #fff; font-size: .78rem;
    padding: 6px 13px; border: 1px solid rgba(255,255,255,.28);
    backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  }
  /* セクション見出し・余白 */
  .section-head { margin-bottom: 36px; }
  .section-head .en { font-size: 1.2rem; }
  .greeting { grid-template-columns: 1fr; gap: 28px; }
  .greeting-photo { aspect-ratio: 4/3; min-height: auto; max-height: 60vh; }
  .greeting-photo img { object-position: center 25%; }
  .greeting-body .sign { text-align: left; }
  /* 特徴バー（スマホ：アイコン左＋テキストの横並びでコンパクトに） */
  .strip { grid-template-columns: 1fr; margin-top: -28px; }
  .strip > div { display: flex; align-items: center; gap: 16px; text-align: left; padding: 16px 20px; }
  .strip > div + div { border-left: 0; border-top: 1px solid var(--line); }
  .strip .ico { margin-bottom: 0; flex: none; }
  .strip .ico svg { width: 28px; height: 28px; }
  .strip strong { font-size: 1rem; }
  .strip-txt { display: flex; flex-direction: column; }
  .menu-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .mcard { min-height: 150px; }
  .mcard .ja { font-size: 1.05rem; }
  /* 特色治療（スマホ） */
  .feature-cards { grid-template-columns: 1fr; gap: 14px; }
  .fcard { min-height: 240px; }
  .ib-text { padding: 32px 26px; }
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .mobile-cta { display: grid; }
  .section { padding: 52px 0; }
  .site-footer { padding-bottom: 120px; }
  .footer-nav li { padding: 10px 0; }
  .news-list li { flex-wrap: wrap; gap: 8px 12px; }
  .news-item, .news-item.has-img { grid-template-columns: 1fr; gap: 10px; }
  .news-item.has-img .news-photo { grid-column: 1; }
  .news-photo { max-width: 100%; }

  /* mobile: 上部余白圧縮＋読み易いページヒーロー */
  :root { --header-h: 64px; }
  .brand .logo-text small { display: none; }
  .page-hero { padding: 36px 0 42px; }
  .page-hero h1 { font-size: 1.55rem; }
  .page-hero .narrow { font-size: .92rem; }
  body.home .hero { min-height: 78vh; }
  .hero h1 { line-height: 1.65; }
  body.home .hero h1 .ln .hl { padding-bottom: 2px; }

  /* mobile: 表を横スワイプ可能に */
  .prose .table-scroll {
    overflow-x: auto; -webkit-overflow-scrolling: touch;
    margin: 1.2em -8px; padding: 0 8px 4px;
  }
  .prose .table-scroll table { min-width: 480px; margin: 0; }
  .prose table { font-size: .88rem; }
  .prose th, .prose td { padding: 8px 8px; }

  /* mobile: 医院の理念（greeting）カード */
  .grid-3 .reason {
    background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
    padding: 22px 20px; display: flex; gap: 14px; align-items: flex-start;
  }
  .grid-3 .reason .num {
    font-family: var(--font-en); font-style: italic; color: var(--accent);
    font-size: 2rem; font-weight: 600; line-height: 1; flex: none;
  }
  .grid-3 .reason h3 {
    font-family: var(--font-serif); font-size: 1.08rem; margin: 0 0 6px;
    color: var(--teal-darker);
  }
  .grid-3 .reason p { color: var(--ink); font-size: .9rem; line-height: 1.75; margin: 0; }
}

@media (max-width: 420px) {
  .hours-table th, .hours-table td { font-size: .76rem; padding: 8px 1px; }
  .hours-table tbody th { font-size: .72rem; padding-left: 2px; }
  .mcard .ja { font-size: 1rem; letter-spacing: 0; }
}

/* legacy-surface-decoration-v1 */
.page-hero,.section,.cta-section,.site-footer{position:relative;isolation:isolate;overflow:hidden}
.page-hero>*,.section>*,.cta-section>*,.site-footer>*{position:relative;z-index:1}
.page-hero{background:radial-gradient(ellipse at 84% 18%,rgba(118,139,144,.15),transparent 40%),linear-gradient(128deg,#f3f4f1 0%,#fbfbf8 54%,#e9eeec 100%)}
.page-hero:before{content:"";position:absolute;z-index:0;right:-16vw;top:-21vw;width:48vw;height:48vw;border:1px solid rgba(72,96,102,.11);border-radius:50%;box-shadow:0 0 0 7vw rgba(104,127,132,.022);pointer-events:none}
.section:not(.section--teal):not(.section--sand){background:radial-gradient(ellipse at 10% 78%,rgba(132,150,153,.09),transparent 42%),linear-gradient(120deg,#fff 0%,#fbfbf8 58%,#f0f3f1 100%)}
.section--sand{background:radial-gradient(ellipse at 88% 22%,rgba(142,157,158,.11),transparent 40%),linear-gradient(132deg,#f5f4ef 0%,#fbfaf6 54%,#ecefeb 100%)}
.section:not(.section--teal):before,.section--sand:before{content:"";position:absolute;z-index:0;left:-18vw;bottom:-24vw;width:46vw;height:46vw;border:1px solid rgba(72,96,102,.08);border-radius:50%;pointer-events:none}
.section--sand:before{left:auto;right:-20vw;bottom:auto;top:-24vw}
.section--teal{background:radial-gradient(ellipse at 84% 16%,rgba(255,255,255,.10),transparent 38%),linear-gradient(125deg,#536065 0%,#687579 52%,#49565b 100%)}
.section--teal:before{content:"";position:absolute;z-index:0;right:-17vw;bottom:-28vw;width:50vw;height:50vw;border:1px solid rgba(255,255,255,.13);border-radius:50%;box-shadow:0 0 0 7vw rgba(255,255,255,.015);pointer-events:none}
:where(.faq-item,.card,.ac-card,.menu-card,.doctor-card,.news-item){background:linear-gradient(138deg,rgba(255,255,255,.96),rgba(242,245,243,.88))}
.site-footer{background:radial-gradient(ellipse at 86% 16%,rgba(255,255,255,.075),transparent 34%),linear-gradient(128deg,#303a3e 0%,#414b4f 54%,#293337 100%)}
.site-footer:before{content:"";position:absolute;z-index:0;right:-19vw;top:-28vw;width:48vw;height:48vw;border:1px solid rgba(255,255,255,.09);border-radius:50%;pointer-events:none}
@media(max-width:700px){.page-hero:before,.section:not(.section--teal):before,.section--sand:before,.section--teal:before,.site-footer:before{width:108vw;height:108vw;opacity:.6}.page-hero:before{right:-50vw;top:-40vw}.section:not(.section--teal):before{left:-58vw;bottom:-42vw}.section--sand:before,.site-footer:before{right:-58vw;top:-45vw}.section--teal:before{right:-58vw;bottom:-45vw}}
/* legacy pages logo 05 refresh */
.brand .logo-mark,
.footer-logo .logo-mark {
  display: inline-block !important;
  width: 46px !important;
  height: 34px !important;
  min-width: 46px !important;
  font-size: 0 !important;
  line-height: 0 !important;
  background: url("../assets/logo-mark-05-official-v2.webp") center / contain no-repeat !important;
  border: 0 !important;
  border-radius: 0 !important;
  color: transparent !important;
}
.footer-logo .logo-mark { filter: brightness(0) invert(1); opacity: .9; }
@media (max-width: 768px) {
  .brand .logo-mark,
  .footer-logo .logo-mark { width: 39px !important; height: 29px !important; min-width: 39px !important; }
}
/* logo 05 final visibility */ .brand .logo-mark,.footer-logo .logo-mark{width:58px!important;height:43px!important;min-width:58px!important;background-image:url("../assets/logo-mark-05-official-v2.webp")!important;background-size:contain!important}@media(max-width:768px){.brand .logo-mark,.footer-logo .logo-mark{width:46px!important;height:35px!important;min-width:46px!important}}

/* Temporary booking pause: keep phone access while hiding every web-reservation entry point. */
a[href*="yoyaq.vercel.app"] { display: none !important; }
.booking-guide { display: none !important; }
.cta-links:has(a[href*="yoyaq.vercel.app"]),
.sticky-sp-actions:has(a[href*="yoyaq.vercel.app"]) {
  grid-template-columns: 1fr !important;
}
.sticky-sp-actions:has(a[href*="yoyaq.vercel.app"]) a[href^="tel:"] {
  width: 100% !important;
}

/* mobile-performance-legacy-v1 */
@media(max-width:700px){body{padding-bottom:calc(72px + env(safe-area-inset-bottom))!important}.site-header{position:sticky!important;top:0!important;backdrop-filter:none!important;-webkit-backdrop-filter:none!important;box-shadow:none!important}.mobile-cta,.sticky-sp-actions{grid-template-columns:1fr!important;backdrop-filter:none!important;-webkit-backdrop-filter:none!important}}
/* Official logo 05 sizing. */
.brand .logo-mark{width:52px!important;height:52px!important;min-width:52px!important;background-image:url("../assets/logo-mark-05-official-v2.webp")!important}
.footer-logo .logo-mark{width:56px!important;height:56px!important;min-width:56px!important;background-image:url("../assets/logo-mark-05-official-v2.webp")!important}
@media(max-width:768px){.brand .logo-mark{width:44px!important;height:44px!important;min-width:44px!important}.footer-logo .logo-mark{width:48px!important;height:48px!important;min-width:48px!important}}
/* full-page layout audit: legacy pages */
html,body,main{width:100%;max-width:100%}
main,main>section,main>section>*,.container,.header-inner,.main-nav,.prose{min-width:0}
:where(.grid,.grid-2,.grid-3,.footer-grid,.greeting,.reasons-grid,.equipment-grid,.clinic-gallery)>*{min-width:0}
:where(.prose,.section,.page-hero) :where(h1,h2,h3,h4,p,li,th,td,dt,dd){max-width:100%;overflow-wrap:anywhere}
.table-scroll{max-width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch}
@media(max-width:720px){
:where(.prose,.section,.page-hero) :where(h1,h2,h3,h4,p,li,th,td,dt,dd){overflow-wrap:normal;word-break:normal}
.container{padding-left:20px;padding-right:20px}
.brand{min-width:0;gap:10px}
.brand .logo-text{min-width:0}
.brand .logo-text strong{font-size:1rem;white-space:nowrap}
}
