/* ============================================
   VET EHON TEMPLATE
   動物病院・やさしいパステルの絵本風
   ミント／ラベンダー／ベビーピンク／そら色／バター色
   手描き風SVGの雲と草、波線の区切り、ふわっと浮く動き
============================================ */

:root {
  /* Color — 多色パステル。文字と線はくすんだ藤色のインク */
  --sky: #d6ecf8;
  --sky-deep: #9ccbe8;
  --mint: #c9ecdd;
  --mint-deep: #7fc6a8;
  --lav: #e6e0f6;
  --lav-deep: #a998dc;
  --pink: #ffdce3;
  --pink-deep: #ef8fa6;
  --pink-dark: #d36d87;
  --butter: #fff1b8;
  --grass: #a8d89a;
  --grass-deep: #86c278;
  --paper: #fffcf4; /* 絵本の紙 */
  --ink: #5b5470; /* 線と文字 */
  --ink-soft: #7d7790;
  --night: #4a5576; /* よるのページ（単色） */
  --white: #ffffff;

  /* Font */
  --font-body: "Zen Maru Gothic", "Hiragino Maru Gothic ProN", sans-serif;
  --font-title: "Kiwi Maru", "Zen Maru Gothic", serif;

  /* Shape — 手描きっぽく、角丸をすこしずつ不揃いに */
  --line: 2.5px solid var(--ink);
  --blob-a: 46% 54% 52% 48% / 54% 46% 54% 46%;
  --blob-b: 58% 42% 44% 56% / 48% 56% 44% 52%;
  --radius: 26px;
  --radius-full: 999px;

  --container: 1120px;
  --gutter: clamp(16px, 4vw, 40px);
  --header-h: 74px;

  /* ふわっとしたイージング */
  --soft: cubic-bezier(0.22, 0.9, 0.32, 1);
}

/* ---------- Reset ---------- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 16px;
  background: var(--paper);
  color: var(--ink);
  line-height: 1.9;
  letter-spacing: 0.04em;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* 演出で一瞬はみ出しても横スクロールを出さない（clip は sticky を壊さない） */
main {
  overflow-x: clip;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

ul,
ol {
  list-style: none;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  background: none;
  border: none;
}

:focus-visible {
  outline: 3px dashed var(--pink-dark);
  outline-offset: 4px;
}

section[id] {
  scroll-margin-top: calc(var(--header-h) + 8px);
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 200;
  padding: 8px 16px;
  background: var(--ink);
  color: var(--white);
  border-radius: var(--radius-full);
}

.skip-link:focus {
  top: 12px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.sp-only {
  display: none;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* ---------- 見出し（絵本のタイトルっぽく、まるい書体） ---------- */
.eyebrow {
  display: inline-block;
  margin-bottom: 10px;
  padding: 2px 14px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--ink-soft);
  background: var(--white);
  border: 2px solid var(--ink);
  border-radius: var(--blob-a);
}

.section-title {
  font-family: var(--font-title);
  font-weight: 500;
  font-size: clamp(26px, 3.6vw, 38px);
  line-height: 1.45;
  letter-spacing: 0.06em;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 52px;
  padding: 12px 28px;
  font-weight: 700;
  font-size: 16px;
  border: var(--line);
  border-radius: var(--radius-full);
  transition: transform 0.3s var(--soft), background 0.2s ease;
}

.btn:hover {
  transform: translateY(-3px);
}

.btn--pink {
  background: var(--pink-deep);
  color: var(--white);
  text-shadow: 0 1px 0 rgba(91, 84, 112, 0.25);
}

.btn--pink:hover {
  background: var(--pink-dark);
}

.btn--line {
  background: var(--white);
}

.btn--block {
  width: 100%;
}

/* ---------- Header ---------- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-h);
  transition: box-shadow 0.3s ease;
}

/* 背景は疑似要素に（ヘッダー自体に効果を付けるとモバイルメニューが閉じ込められるため） */
.header::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--paper);
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: -1;
}

.header.is-scrolled::before {
  opacity: 1;
}

.header.is-scrolled {
  box-shadow: 0 2px 0 rgba(91, 84, 112, 0.18);
}

.header__inner {
  max-width: 1280px;
  height: 100%;
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo__mark svg {
  display: block;
}

.logo__text {
  display: flex;
  flex-direction: column;
  font-family: var(--font-title);
  font-size: 20px;
  line-height: 1.2;
  letter-spacing: 0.06em;
}

.logo__text small {
  margin-top: 3px;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
}

.nav__list {
  display: flex;
  align-items: center;
  gap: 2px;
}

.nav__link {
  position: relative;
  display: block;
  padding: 8px 12px;
  font-weight: 700;
  font-size: 15px;
}

/* 手描きの波線アンダーライン */
.nav__link:not(.nav__link--cta)::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 2px;
  height: 6px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 6'%3E%3Cpath d='M0 3q5-4 10 0t10 0' fill='none' stroke='%23ef8fa6' stroke-width='2'/%3E%3C/svg%3E") repeat-x;
  background-size: 20px 6px;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--soft);
}

.nav__link:hover::after {
  transform: scaleX(1);
}

.nav__link--cta {
  margin-left: 8px;
  padding: 9px 18px;
  background: var(--pink-deep);
  color: var(--white);
  border: var(--line);
  border-radius: var(--radius-full);
}

.nav__link--cta:hover {
  background: var(--pink-dark);
}

.nav-toggle {
  display: none;
  position: relative;
  z-index: 110;
  width: 50px;
  height: 50px;
  background: var(--white);
  border: var(--line);
  border-radius: var(--blob-a);
}

.nav-toggle span {
  position: absolute;
  left: 13px;
  width: 20px;
  height: 2.5px;
  background: var(--ink);
  border-radius: 3px;
  transition: transform 0.3s var(--soft), opacity 0.2s;
}

.nav-toggle span:nth-child(1) {
  top: 16px;
}
.nav-toggle span:nth-child(2) {
  top: 23px;
}
.nav-toggle span:nth-child(3) {
  top: 30px;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}
.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ---------- Hero（絵本の見開き） ---------- */
.hero {
  position: relative;
  padding-top: calc(var(--header-h) + 24px);
  background: var(--sky);
  overflow: hidden;
}

.cloud {
  position: absolute;
  fill: var(--white);
  stroke: var(--ink);
  stroke-width: 2.2;
  stroke-linejoin: round;
  pointer-events: none;
}

.cloud--a {
  top: 110px;
  left: 3%;
  width: 150px;
}

.cloud--b {
  top: 70px;
  right: 34%;
  width: 110px;
  opacity: 0.9;
}

.cloud--c {
  bottom: 170px;
  right: 2%;
  width: 130px;
}

.hero__inner {
  position: relative;
  z-index: 1;
  max-width: var(--container);
  margin: 0 auto;
  padding: 40px var(--gutter) 150px;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  align-items: center;
  gap: clamp(28px, 5vw, 64px);
}

.hero__open {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  padding: 6px 16px;
  font-size: 14px;
  font-weight: 700;
  background: var(--white);
  border: 2px solid var(--ink);
  border-radius: var(--radius-full);
}

.hero__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--ink-soft);
  flex-shrink: 0;
}

.hero__open.is-open .hero__dot {
  background: var(--mint-deep);
  box-shadow: 0 0 0 4px rgba(127, 198, 168, 0.35);
}

.hero__title {
  font-family: var(--font-title);
  font-weight: 500;
  font-size: clamp(27px, 3.5vw, 44px);
  line-height: 1.55;
  letter-spacing: 0.02em;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.hero__line {
  display: block;
}

/* 一行ずつふわっと出る（JSが付けるクラスで開始。JSタイマーでも保険あり） */
.js-ehon .hero__line,
.js-ehon .hero__lead,
.js-ehon .hero__btns,
.js-ehon .hero__photo {
  opacity: 0;
  transform: translateY(12px);
}

.hero.is-ready .hero__line,
.hero.is-ready .hero__lead,
.hero.is-ready .hero__btns,
.hero.is-ready .hero__photo {
  opacity: 1;
  transform: none;
  transition: opacity 0.8s ease-out, transform 0.8s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.hero.is-ready .hero__line:nth-child(2) {
  transition-delay: 0.12s;
}
.hero.is-ready .hero__line:nth-child(3) {
  transition-delay: 0.24s;
}
.hero.is-ready .hero__lead {
  transition-delay: 0.4s;
}
.hero.is-ready .hero__btns {
  transition-delay: 0.5s;
}
.hero.is-ready .hero__photo--sub {
  transition-delay: 0.3s;
}

.hero__mark {
  display: inline;
  /* 手描きのマーカー（ピンクの帯）。改行しても帯が切れない */
  background: linear-gradient(transparent 58%, var(--pink) 58% 92%, transparent 92%);
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
  padding: 0 4px;
}

.hero__lead {
  margin: 22px 0 30px;
  font-size: 16px;
  line-height: 2;
  color: var(--ink);
}

.hero__btns {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero__page--pic {
  position: relative;
  min-height: 420px;
}

.hero__photo {
  position: relative;
  width: 82%;
  margin-left: auto;
  border: var(--line);
  border-radius: var(--blob-a);
  overflow: hidden;
  background: var(--white);
}

.hero__photo img {
  width: 100%;
  aspect-ratio: 9 / 10;
  object-fit: cover;
}

.hero__photo--sub {
  position: absolute;
  left: 0;
  bottom: -24px;
  width: 40%;
  border-radius: 50%;
  border-width: 3px;
}

.hero__photo--sub img {
  aspect-ratio: 1;
}


.hero__note {
  position: absolute;
  top: -10px;
  left: 6%;
  padding: 14px 18px;
  font-family: var(--font-title);
  font-size: 16px;
  line-height: 1.5;
  text-align: center;
  background: var(--butter);
  border: var(--line);
  border-radius: 50% 50% 50% 8px / 60% 60% 40% 10px;
  transform: rotate(-6deg);
}

.hills {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  width: 100%;
  height: 140px;
  z-index: 2;
}

.hills__back {
  fill: var(--grass);
  stroke: var(--ink);
  stroke-width: 2;
}

.hills__front {
  fill: var(--paper);
  stroke: var(--ink);
  stroke-width: 2;
}

.hills__grass path {
  fill: none;
  stroke: var(--grass-deep);
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- 波線の区切り ---------- */
.wave {
  display: block;
  width: 100%;
  height: 46px;
  margin-bottom: -1px;
}

.wave path {
  stroke: none;
}

.wave--flip {
  transform: scaleY(-1);
  margin: -1px 0 0;
}

.wave--mint path {
  fill: var(--mint);
}
.wave--pink path {
  fill: var(--pink);
}
.wave--lav path {
  fill: var(--lav);
}

/* ---------- お知らせ ---------- */
.news {
  padding: 24px 0 56px;
}

.news__inner {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 16px 40px;
  align-items: start;
}

.news__title {
  font-family: var(--font-title);
  font-weight: 500;
  font-size: 24px;
  letter-spacing: 0.2em;
  padding-top: 6px;
}

.news__list li {
  display: grid;
  grid-template-columns: auto auto 1fr;
  gap: 4px 14px;
  align-items: baseline;
  padding: 14px 0;
  font-size: 15px;
  border-bottom: 2px dashed rgba(91, 84, 112, 0.25);
}

.news__list time {
  font-weight: 700;
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}

.news__tag {
  padding: 0 10px;
  font-size: 13px;
  font-weight: 700;
  border-radius: var(--radius-full);
  border: 1.5px solid var(--ink);
}

.news__tag--pink {
  background: var(--pink);
}
.news__tag--mint {
  background: var(--mint);
}
.news__tag--lav {
  background: var(--lav);
}

/* ---------- 診療時間 ---------- */
.hours {
  background: var(--mint);
  padding: 40px 0 56px;
}

.hours__inner {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 40px;
  align-items: center;
}

.hours__desc {
  margin-top: 16px;
  font-size: 15px;
}

.hours__now {
  display: inline-block;
  margin-top: 20px;
  padding: 8px 18px;
  font-weight: 700;
  font-size: 15px;
  background: var(--white);
  border: 2px dashed var(--ink);
  border-radius: 18px;
}

.hours__now.is-open {
  border-style: solid;
  background: var(--butter);
}

.hours__board {
  padding: 28px 24px 22px;
  background: var(--paper);
  border: var(--line);
  border-radius: 34px 28px 36px 26px;
  box-shadow: 6px 8px 0 var(--mint-deep);
}

.timetable {
  width: 100%;
  border-collapse: separate;
  border-spacing: 4px;
  table-layout: fixed;
  text-align: center;
}

.timetable th,
.timetable td {
  padding: 10px 2px;
  font-size: 16px;
  border-radius: 14px;
}

.timetable thead th {
  font-family: var(--font-title);
  font-weight: 500;
  background: var(--sky);
}

.timetable thead th:first-child {
  background: none;
}

.timetable thead th[data-day="6"] {
  background: var(--lav);
}

.timetable thead th[data-day="0"],
.timetable thead th[data-day="h"] {
  background: var(--pink);
}

.timetable tbody th {
  width: 104px;
  font-weight: 700;
  font-size: 15px;
  line-height: 1.4;
  text-align: left;
  padding-left: 6px;
}

.timetable tbody th small {
  display: block;
  font-size: 12px;
  font-weight: 500;
  color: var(--ink-soft);
  letter-spacing: 0;
}

.timetable td {
  background: var(--white);
}

/* きょうの列（JSが .is-today を付ける） */
.timetable .is-today {
  background: var(--butter) !important;
  box-shadow: inset 0 0 0 2px var(--ink);
}

.timetable thead .is-today {
  position: relative;
}

.timetable thead .is-today::after {
  content: "きょう";
  position: absolute;
  top: -22px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  color: var(--pink-dark);
}

.mk {
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  font-weight: 700;
  line-height: 1;
  border-radius: 50%;
}

.mk--o {
  color: var(--mint-deep);
  font-size: 22px;
}

.mk--t {
  color: var(--lav-deep);
  font-size: 18px;
}

.mk--x {
  color: rgba(91, 84, 112, 0.45);
  font-size: 18px;
}

.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
  margin-top: 14px;
  font-size: 14px;
}

.legend li {
  display: flex;
  align-items: center;
  gap: 2px;
}

.legend .mk {
  width: 24px;
  height: 24px;
}

.hours__memo {
  margin-top: 8px;
  font-size: 14px;
  color: var(--ink-soft);
}

/* ---------- 診療対象動物 ---------- */
.animals {
  padding: 72px 0 80px;
}

.animals__head {
  text-align: center;
  margin-bottom: 44px;
}

.animals__list {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
}

.animal {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.animal:nth-child(even) {
  margin-top: 36px; /* 高さを互い違いにして、ならび方をゆるく */
}

.animal__pic {
  display: block;
  width: 100%;
  max-width: 170px;
  padding: 10px;
  border-radius: var(--blob-b);
  border: var(--line);
  margin-bottom: 14px;
}

.animal__pic img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 50%;
}


.animal--pink .animal__pic {
  background: var(--pink);
}
.animal--mint .animal__pic {
  background: var(--mint);
}
.animal--yellow .animal__pic {
  background: var(--butter);
}
.animal--lav .animal__pic {
  background: var(--lav);
}
.animal--sky .animal__pic {
  background: var(--sky);
}

.animal strong {
  font-family: var(--font-title);
  font-weight: 500;
  font-size: 20px;
}

.animal span:last-child {
  font-size: 14px;
  color: var(--ink-soft);
  line-height: 1.6;
}

.animals__note {
  max-width: 640px;
  margin: 40px auto 0;
  padding: 12px 20px;
  font-size: 14px;
  text-align: center;
  background: var(--sky);
  border-radius: 20px;
}

/* ---------- 診療科目（もくじ） ---------- */
.services {
  padding: 24px 0 96px;
}

.services__inner {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: start;
}

.services__book {
  position: sticky;
  top: calc(var(--header-h) + 20px);
  padding: 40px 40px 32px 56px;
  background: var(--white);
  border: var(--line);
  border-radius: 10px 30px 30px 10px;
  box-shadow: -10px 0 0 var(--lav), -10px 0 0 2.5px var(--ink);
}

/* 本の綴じ目 */
.services__book::before {
  content: "";
  position: absolute;
  top: 18px;
  bottom: 18px;
  left: 22px;
  border-left: 2px dashed rgba(91, 84, 112, 0.3);
}

.services__book .section-title {
  margin-bottom: 18px;
}

.toc li {
  display: grid;
  grid-template-columns: 36px auto 1fr;
  grid-template-areas:
    "no name lead"
    ". desc desc";
  align-items: center;
  column-gap: 10px;
  padding: 14px 0;
}

.toc li + li {
  border-top: 1.5px solid rgba(91, 84, 112, 0.12);
}

.toc__no {
  grid-area: no;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  font-family: var(--font-title);
  font-size: 16px;
  border: 2px solid var(--ink);
  border-radius: var(--blob-a);
}

.toc li:nth-child(6n + 1) .toc__no {
  background: var(--pink);
}
.toc li:nth-child(6n + 2) .toc__no {
  background: var(--mint);
}
.toc li:nth-child(6n + 3) .toc__no {
  background: var(--butter);
}
.toc li:nth-child(6n + 4) .toc__no {
  background: var(--lav);
}
.toc li:nth-child(6n + 5) .toc__no {
  background: var(--sky);
}
.toc li:nth-child(6n + 6) .toc__no {
  background: var(--pink);
}

.toc__name {
  grid-area: name;
  font-family: var(--font-title);
  font-size: 18px;
  word-break: keep-all;
}

/* 点線のリーダー */
.toc__lead {
  grid-area: lead;
  height: 2px;
  margin-top: 6px;
  background: radial-gradient(circle, var(--ink-soft) 1px, transparent 1.5px) left / 8px 2px repeat-x;
  opacity: 0.6;
}

.toc__desc {
  grid-area: desc;
  font-size: 14px;
  color: var(--ink-soft);
  line-height: 1.7;
}

.services__pics {
  display: grid;
  gap: 22px;
}

.pic {
  border: var(--line);
  background: var(--white);
  padding: 10px 10px 8px;
  border-radius: 18px;
}

.pic img {
  border-radius: 12px;
  width: 100%;
  object-fit: cover;
}

.pic figcaption {
  padding: 8px 4px 2px;
  font-size: 14px;
  line-height: 1.6;
}

.pic--a {
  transform: rotate(-2deg);
}

.pic--b {
  width: 74%;
  margin-left: auto;
  transform: rotate(2.5deg);
}

.pic--b img {
  aspect-ratio: 1;
}

.pic--c {
  width: 86%;
  transform: rotate(-1deg);
}

/* ---------- スタッフ ---------- */
.staff {
  background: var(--pink);
  padding: 48px 0 72px;
}

.staff__head {
  margin-bottom: 40px;
}

.director {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 48px;
  align-items: center;
}

.director__pic {
  padding: 14px;
  background: var(--paper);
  border: var(--line);
  border-radius: var(--blob-b);
}

.director__pic img {
  width: 100%;
  aspect-ratio: 7 / 8;
  object-fit: cover;
  border-radius: var(--blob-a);
}

.director__role {
  font-size: 14px;
  font-weight: 700;
  color: var(--pink-dark);
}

.director__name {
  font-family: var(--font-title);
  font-weight: 500;
  font-size: 30px;
  line-height: 1.4;
}

.director__name small {
  display: block;
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--ink-soft);
}

/* ふきだし */
.bubble {
  position: relative;
  margin: 20px 0 24px;
  padding: 20px 24px;
  font-size: 16px;
  background: var(--white);
  border: var(--line);
  border-radius: 30px;
}

.bubble::before {
  content: "";
  position: absolute;
  left: -14px;
  top: 30px;
  width: 22px;
  height: 22px;
  background: var(--white);
  border-left: var(--line);
  border-bottom: var(--line);
  transform: rotate(45deg) skew(10deg, 10deg);
}

.director__dl div {
  display: grid;
  grid-template-columns: 70px 1fr;
  gap: 12px;
  padding: 6px 0;
  font-size: 15px;
}

.director__dl dt {
  font-weight: 700;
}

.crew {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  margin-top: 64px;
}

.crew__item {
  padding: 24px 22px;
  background: var(--paper);
  border: var(--line);
  border-radius: 28px 34px 26px 36px;
}

.crew__item:nth-child(2) {
  transform: translateY(24px);
}

.crew__item--text {
  background: var(--butter);
  align-self: center;
}

.crew__pic {
  display: block;
  width: 96px;
  margin-bottom: 12px;
}

.crew__pic img {
  border-radius: 50%;
  border: 2px solid var(--ink);
  aspect-ratio: 1;
  object-fit: cover;
}

.crew__role {
  font-size: 13px;
  font-weight: 700;
  color: var(--pink-dark);
}

.crew__name {
  font-family: var(--font-title);
  font-size: 19px;
}

.crew__word {
  margin-top: 8px;
  font-size: 15px;
  line-height: 1.8;
}

/* ---------- 設備 ---------- */
.facility {
  padding: 80px 0;
}

.facility__head {
  margin-bottom: 36px;
  text-align: right;
}

.facility__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.fac {
  position: relative;
}

.fac img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: var(--line);
  border-radius: 24px;
}

.fac--big {
  grid-column: span 2;
  grid-row: span 2;
}

.fac--big img {
  height: 100%;
  aspect-ratio: auto;
  min-height: 360px;
}

.fac--wide {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 24px;
  align-items: center;
}

.fac--wide img {
  aspect-ratio: 16 / 8;
}

.fac figcaption {
  margin-top: 10px;
  font-size: 15px;
  line-height: 1.7;
}

.fac figcaption strong {
  display: block;
  font-family: var(--font-title);
  font-weight: 500;
  font-size: 18px;
}

.fac--big figcaption {
  position: absolute;
  left: 16px;
  bottom: 16px;
  max-width: 320px;
  padding: 12px 16px;
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: 18px;
}

.fac--wide figcaption {
  padding: 22px 26px;
  background: var(--sky);
  border-radius: 26px;
}

/* ---------- 初診の流れ（おさんぽ道） ---------- */
.first {
  padding: 24px 0 96px;
}

.first__head {
  margin-bottom: 48px;
}

.road {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

/* くねくね道（点線の波） */
.road::before {
  content: "";
  position: absolute;
  top: 26px;
  left: 6%;
  right: 6%;
  height: 20px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 80 20'%3E%3Cpath d='M0 10q20-12 40 0t40 0' fill='none' stroke='%237fc6a8' stroke-width='3' stroke-dasharray='6 6' stroke-linecap='round'/%3E%3C/svg%3E") repeat-x;
  background-size: 80px 20px;
}

.road__step {
  position: relative;
}

.road__step:nth-child(even) {
  margin-top: 40px;
}

.road__no {
  position: relative;
  display: grid;
  place-items: center;
  width: 60px;
  height: 60px;
  margin-bottom: 14px;
  font-family: var(--font-title);
  font-size: 24px;
  background: var(--butter);
  border: var(--line);
  border-radius: var(--blob-a);
}

.road__step:nth-child(2) .road__no {
  background: var(--pink);
}
.road__step:nth-child(3) .road__no {
  background: var(--lav);
}
.road__step:nth-child(4) .road__no {
  background: var(--mint);
}

.road__step h3 {
  font-family: var(--font-title);
  font-weight: 500;
  font-size: 19px;
  margin-bottom: 6px;
}

.road__step p {
  font-size: 15px;
  line-height: 1.8;
}

.first__bring {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
  align-items: center;
  margin-top: 56px;
  padding: 20px 28px;
  border: 2.5px dashed var(--ink);
  border-radius: 26px;
}

.first__bring h3 {
  font-family: var(--font-title);
  font-weight: 500;
  font-size: 18px;
  padding: 2px 14px;
  background: var(--butter);
  border-radius: var(--radius-full);
}

.first__bring ul {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 24px;
  font-size: 15px;
}

.first__bring li::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 8px;
  vertical-align: 2px;
  border-radius: 50%;
  background: var(--pink-deep);
}

/* ---------- ご予約・お問い合わせ ---------- */
.contact {
  background: var(--lav);
  padding: 48px 0 72px;
}

.contact__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

.contact__lead {
  margin: 14px 0 24px;
  font-size: 15px;
}

.way {
  display: grid;
  gap: 2px;
  margin-bottom: 14px;
  padding: 16px 22px;
  background: var(--white);
  border: var(--line);
  border-radius: 22px;
  transition: transform 0.3s var(--soft);
}

.way:hover {
  transform: translateX(4px);
}

.way__label {
  font-size: 13px;
  font-weight: 700;
  color: var(--ink-soft);
}

.way__main {
  font-family: var(--font-title);
  font-size: 22px;
  line-height: 1.4;
}

.way__sub {
  font-size: 14px;
  color: var(--ink-soft);
}

.way--tel {
  background: var(--pink-deep);
  color: var(--white);
}

.way--tel .way__label,
.way--tel .way__sub {
  color: var(--white);
}

.way--tel .way__main {
  font-size: 30px;
  letter-spacing: 0.06em;
}

.way--line .way__main {
  color: #2f8f5b;
}

.contact__pic {
  margin-top: 20px;
  width: 70%;
  border: var(--line);
  border-radius: 20px;
  transform: rotate(-2deg);
}

/* 便せん風フォーム */
.letter {
  position: relative;
  padding: 36px 32px 28px;
  background:
    repeating-linear-gradient(transparent 0 37px, rgba(156, 203, 232, 0.45) 37px 39px),
    var(--paper);
  border: var(--line);
  border-radius: 14px;
  box-shadow: 8px 10px 0 var(--lav-deep);
}

.letter__title {
  font-family: var(--font-title);
  font-weight: 500;
  font-size: 22px;
}

.letter__note {
  margin: 4px 0 18px;
  font-size: 14px;
  color: var(--ink-soft);
}

.field {
  display: grid;
  gap: 6px;
  margin-bottom: 16px;
  border: none;
}

.field label,
.field legend {
  font-size: 15px;
  font-weight: 700;
}

.req {
  margin-left: 8px;
  padding: 0 8px;
  font-size: 12px;
  color: var(--white);
  background: var(--pink-deep);
  border-radius: var(--radius-full);
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 48px;
  padding: 10px 14px;
  font-size: 16px;
  background: var(--white);
  border: 2px solid var(--ink);
  border-radius: 16px;
}

.field textarea {
  resize: vertical;
  line-height: 1.7;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--pink-dark);
  box-shadow: 0 0 0 4px var(--pink);
}

.field--chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.field--chips legend {
  width: 100%;
  margin-bottom: 6px;
}

.field--chips label {
  position: relative;
}

.field--chips input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  min-height: 0;
}

.field--chips span {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 6px 16px;
  font-size: 15px;
  font-weight: 700;
  background: var(--white);
  border: 2px solid var(--ink);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: background 0.2s ease;
}

.field--chips input:checked + span {
  background: var(--mint);
}

.field--chips input:focus-visible + span {
  outline: 3px dashed var(--pink-dark);
  outline-offset: 3px;
}

.letter__msg {
  min-height: 1.6em;
  margin-top: 12px;
  font-size: 15px;
  font-weight: 700;
  color: var(--pink-dark);
}

/* ---------- アクセス ---------- */
.access {
  padding: 48px 0 88px;
}

.access__inner {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 48px;
  align-items: center;
}

.access__dl {
  margin-top: 20px;
}

.access__dl div {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 12px;
  padding: 12px 0;
  font-size: 15px;
  border-bottom: 2px dashed rgba(91, 84, 112, 0.22);
}

.access__dl dt {
  font-weight: 700;
}

.access__dl a {
  display: inline-block;
  padding: 10px 0;
  margin: -10px 0;
  font-weight: 700;
  text-decoration: underline wavy var(--pink-deep);
  text-underline-offset: 5px;
}

.access__map {
  padding: 12px;
  background: var(--mint);
  border: var(--line);
  border-radius: var(--blob-b);
}

.access__map iframe {
  display: block;
  width: 100%;
  height: 380px;
  border: 0;
  border-radius: 34px 40px 30px 44px;
}

/* ---------- 夜間・緊急 ---------- */
.night {
  position: relative;
  padding: 72px 0;
  background-color: var(--night);
  /* 小さな星（点だけ。きらきらさせない） */
  background-image:
    radial-gradient(circle, rgba(255, 241, 184, 0.85) 1.4px, transparent 2px),
    radial-gradient(circle, rgba(255, 255, 255, 0.5) 1px, transparent 1.6px);
  background-size: 140px 120px, 90px 70px;
  background-position: 20px 30px, 60px 10px;
  color: var(--white);
  overflow: hidden;
}

.night__moon {
  position: absolute;
  top: 36px;
  right: 8%;
  width: 72px;
  fill: var(--butter);
  stroke: var(--ink);
  stroke-width: 2;
}

.night__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px 48px;
  align-items: center;
}

.eyebrow--night {
  color: var(--night);
}

.night__title {
  font-family: var(--font-title);
  font-weight: 500;
  font-size: clamp(24px, 3vw, 32px);
  line-height: 1.5;
  margin-bottom: 12px;
  word-break: keep-all;
}

.night p {
  font-size: 15px;
}

.night__dl {
  display: grid;
  gap: 12px;
}

.night__dl div {
  padding: 16px 20px;
  background: rgba(255, 255, 255, 0.1);
  border: 2px solid rgba(255, 255, 255, 0.55);
  border-radius: 22px;
}

.night__dl dt {
  font-size: 15px;
  font-weight: 700;
}

.night__dl dt small {
  display: block;
  font-size: 13px;
  font-weight: 500;
  opacity: 0.85;
}

.night__dl dd a {
  display: inline-block;
  padding: 4px 0;
  font-family: var(--font-title);
  font-size: 26px;
  letter-spacing: 0.06em;
  color: var(--butter);
}

.night__tip {
  grid-column: 1 / -1;
  padding: 10px 18px;
  background: rgba(255, 220, 227, 0.16);
  border-radius: 16px;
}

/* ---------- Footer ---------- */
.footer {
  padding: 48px 0 40px;
  background: var(--paper);
  text-align: center;
  border-top: 2.5px solid var(--ink);
}

.footer__name {
  font-family: var(--font-title);
  font-size: 22px;
}

.footer__addr {
  font-size: 14px;
  color: var(--ink-soft);
}

.footer__nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0 20px;
  margin: 12px 0;
}

.footer__nav a {
  display: inline-block;
  padding: 10px 4px;
  font-size: 14px;
  font-weight: 700;
}

.footer__copy {
  font-size: 12px;
  color: var(--ink-soft);
}

.to-top {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 90;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  background: var(--white);
  border: var(--line);
  border-radius: var(--blob-a);
  opacity: 0;
  visibility: hidden;
  transform: translateY(16px);
  transition: opacity 0.3s ease, transform 0.4s var(--soft), visibility 0.3s;
}

.to-top.is-show {
  opacity: 1;
  visibility: visible;
  transform: none;
}

/* ---------- Scroll reveal（ふわっと浮いて出てくる） ----------
   html.js-ehon のときだけ隠す＝JSが動かなければ最初から見える */
.js-ehon [data-fuwa] {
  opacity: 0;
  transform: translateY(20px);
}

.js-ehon [data-fuwa].is-visible {
  opacity: 1;
  transform: none;
  transition: opacity 0.7s ease-out, transform 0.7s cubic-bezier(0.2, 0.7, 0.2, 1);
}

/* 回転させている要素は、出たあとも角度を保つ */
.js-ehon .pic--a.is-visible {
  transform: rotate(-2deg);
}
.js-ehon .pic--b.is-visible {
  transform: rotate(2.5deg);
}
.js-ehon .pic--c.is-visible {
  transform: rotate(-1deg);
}
.js-ehon .crew__item:nth-child(2).is-visible {
  transform: translateY(24px);
}

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .nav__link {
    padding: 8px 8px;
    font-size: 14px;
  }

  .logo__text small {
    display: none;
  }
}

@media (max-width: 960px) {
  .nav-toggle {
    display: block;
  }

  .nav {
    position: fixed;
    inset: 0;
    z-index: 105;
    display: grid;
    place-items: center;
    background: var(--sky);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-16px);
    transition: opacity 0.3s ease-out, transform 0.3s cubic-bezier(0.2, 0.7, 0.2, 1), visibility 0.3s;
  }

  .nav.is-open {
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  .nav__list {
    flex-direction: column;
    gap: 6px;
  }

  .nav__link {
    padding: 12px 24px;
    font-family: var(--font-title);
    font-size: 20px;
    text-align: center;
  }

  .nav__link--cta {
    margin: 12px 0 0;
  }

  body.nav-open {
    overflow: hidden;
  }

  .hero__inner {
    grid-template-columns: 1fr;
    padding-bottom: 140px;
  }

  .hero__page--pic {
    min-height: 0;
    max-width: 520px;
    width: 100%;
    margin: 0 auto;
  }

  .cloud--b {
    right: 8%;
  }

  .services__book {
    position: relative;
    top: auto;
  }

  .hours__inner,
  .services__inner,
  .director,
  .contact__inner,
  .access__inner,
  .night__inner {
    grid-template-columns: 1fr;
  }

  .hours__inner {
    gap: 28px;
  }

  .animals__list {
    grid-template-columns: repeat(3, 1fr);
  }

  .animal:nth-child(even) {
    margin-top: 0;
  }

  .services__pics {
    grid-template-columns: 1fr 1fr;
  }

  .pic--a {
    grid-column: 1 / -1;
  }

  .pic--b,
  .pic--c {
    width: 100%;
  }

  .director__pic {
    max-width: 380px;
  }

  .crew {
    grid-template-columns: 1fr 1fr;
  }

  .crew__item:nth-child(2),
  .js-ehon .crew__item:nth-child(2).is-visible {
    transform: none;
  }

  .crew__item--text {
    grid-column: 1 / -1;
  }

  .road {
    grid-template-columns: 1fr 1fr;
    row-gap: 36px;
  }

  .road::before {
    display: none;
  }

  .road__step:nth-child(even) {
    margin-top: 0;
  }

  .contact__pic {
    display: none;
  }
}

@media (max-width: 640px) {
  :root {
    --header-h: 64px;
  }

  body {
    font-size: 15px;
  }

  .sp-only {
    display: inline;
  }

  .pc-only {
    display: none;
  }

  .logo__text {
    font-size: 17px;
  }

  .section-title {
    font-size: 23px;
    letter-spacing: 0.03em;
  }

  .logo__mark svg {
    width: 36px;
    height: 36px;
  }

  .hero__inner {
    padding-top: 20px;
    padding-bottom: 120px;
  }

  .hero__lead {
    font-size: 15px;
  }

  .hero__btns .btn {
    flex: 1 1 100%;
  }

  .hero__note {
    font-size: 14px;
    left: 0;
  }

  .cloud--a {
    width: 96px;
    top: 80px;
    left: auto;
    right: 4%;
    opacity: 0.85;
  }

  .cloud--b {
    display: none;
  }

  .cloud--c {
    width: 90px;
    bottom: 120px;
  }

  .hills {
    height: 90px;
  }

  .news__inner {
    grid-template-columns: 1fr;
  }

  .news__list li {
    grid-template-columns: auto 1fr;
    font-size: 14px;
  }

  .news__list p {
    grid-column: 1 / -1;
  }

  .news__tag {
    justify-self: start;
  }

  /* 診療時間表：スマホでは表を詰めて、そのまま読めるように */
  .hours__board {
    padding: 22px 10px 16px;
    border-radius: 24px;
    box-shadow: 4px 6px 0 var(--mint-deep);
  }

  .timetable {
    border-spacing: 2px;
  }

  .timetable th,
  .timetable td {
    padding: 8px 0;
    font-size: 14px;
    border-radius: 9px;
  }

  .timetable tbody th {
    width: 60px;
    padding-left: 4px;
    font-size: 14px;
  }

  .timetable tbody th small {
    font-size: 10px;
    line-height: 1.3;
  }

  .mk {
    width: 22px;
    height: 22px;
  }

  .mk--o {
    font-size: 17px;
  }

  .mk--t,
  .mk--x {
    font-size: 14px;
  }

  .timetable thead .is-today::after {
    font-size: 10px;
    top: -18px;
  }

  .legend {
    font-size: 14px;
    padding: 0 6px;
  }

  .hours__memo {
    padding: 0 6px;
  }

  .animals__list {
    grid-template-columns: 1fr 1fr;
    gap: 24px 16px;
  }

  .animal:last-child {
    grid-column: 1 / -1;
  }

  .animal__pic {
    max-width: 140px;
  }

  .services__book {
    padding: 28px 20px 20px 38px;
  }

  .services__book::before {
    left: 14px;
  }

  .toc li {
    grid-template-columns: 32px 1fr;
    grid-template-areas:
      "no name"
      ". desc";
  }

  .toc__lead {
    display: none;
  }

  .toc__name {
    font-size: 17px;
  }

  .services__pics {
    grid-template-columns: 1fr;
  }

  .pic--b {
    width: 80%;
  }

  .crew {
    grid-template-columns: 1fr;
  }

  .bubble {
    font-size: 15px;
  }

  .bubble::before {
    display: none;
  }

  .facility__head {
    text-align: left;
  }

  .facility__grid {
    grid-template-columns: 1fr 1fr;
    gap: 14px;
  }

  .fac--big,
  .fac--wide {
    grid-column: 1 / -1;
    grid-row: auto;
  }

  .fac--big img {
    height: auto;
    min-height: 0;
    aspect-ratio: 4 / 3;
  }

  .fac--big figcaption {
    position: static;
    max-width: none;
    margin-top: 10px;
  }

  .fac--wide {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .fac figcaption {
    font-size: 14px;
  }

  .fac figcaption strong {
    font-size: 16px;
  }

  .road {
    grid-template-columns: 1fr;
    row-gap: 20px;
  }

  .road__step {
    display: grid;
    grid-template-columns: 60px 1fr;
    column-gap: 16px;
  }

  .road__no {
    grid-row: span 2;
  }

  .first__bring {
    padding: 18px 20px;
  }

  .way--tel .way__main {
    font-size: 26px;
  }

  .letter {
    padding: 28px 18px 22px;
    box-shadow: 5px 6px 0 var(--lav-deep);
  }

  .access__map iframe {
    height: 300px;
  }

  .access__dl div {
    grid-template-columns: 64px 1fr;
  }

  .night__moon {
    width: 52px;
    top: 24px;
  }

  .night__dl dd a {
    font-size: 23px;
  }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    animation-delay: 0s !important;
    transition-duration: 0.01ms !important;
  }

  .js-ehon [data-fuwa],
  .js-ehon .hero__line,
  .js-ehon .hero__lead,
  .js-ehon .hero__btns,
  .js-ehon .hero__photo {
    opacity: 1 !important;
    transform: none !important;
  }
}
