/* ========== Global Styles ========== */
:root {
  /* Color Palette */
  --color-primary: #2d7f4f;
  --color-primary-light: #4a9966;
  --color-accent: #1a5c3a;
  --color-neutral-light: #f5f3f0;
  --color-neutral-medium: #e8e4e0;
  --color-neutral-dark: #4a4a4a;
  --color-text: #2c2c2c;
  --color-white: #ffffff;
  --color-border: #d4d0cc;

  /* Typography */
  --font-family-serif: "Georgia", serif;
  --font-family-sans: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;                        /* ← これを追加！ */
  font-family: var(--font-family-sans);
  color: var(--color-text);
  background-color: var(--color-white);
  line-height: 1.7;
  padding-top: 0px;                 /* 必要ならここはこのまま */
}



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

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 16px;
}

/* ========== Common Components ========== */

.section-title {
  font-size: 32px;
  font-weight: 700;
  font-family: var(--font-family-serif);
  text-align: center;
  margin-bottom: 8px;
  color: var(--color-text);
}

.section-subtitle {
  text-align: center;
  color: var(--color-neutral-dark);
  font-size: 14px;
  margin-bottom: 40px;
}

.btn {
  display: inline-block;
  padding: 12px 32px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: background-color 0.3s ease, color 0.3s ease, transform 0.2s ease, box-shadow 0.2s ease;
  border: 1px solid transparent;
  cursor: pointer;
}

.btn-primary {
  background-color: var(--color-primary);
  color: var(--color-white);
  border-color: var(--color-primary);
}

.btn-primary:hover {
  background-color: var(--color-accent);
  border-color: var(--color-accent);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
}

.btn-outline {
  background-color: transparent;
  color: var(--color-primary);
  border-color: var(--color-primary);
}

.btn-outline:hover {
  background-color: var(--color-primary-light);
  color: var(--color-white);
}



/* ========== Header ========== */

.header {
  position: fixed;          /* ← sticky から fixed に */
  top: 0;
  left: 0;
  width: 100%;              /* 画面幅いっぱいに */
  z-index: 1000;
  background-color: var(--color-white);
  border-bottom: 1px solid var(--color-neutral-medium);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}


.header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  gap: 32px;
}

.logo {
  display: flex;
  align-items: center;   /* アイコンと文字を縦位置センターに */
  gap: 12px;             /* アイコンと文字の間隔 */
}

/* 追加：ロゴのテキスト部分を縦並びに */
.logo-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

/* 追加：アイコンのサイズ */
.logo-icon {
  width: 48px;           /* 大きさはお好みで 32〜56px くらいに調整 */
  height: auto;
}


.logo-sub {
  font-size: 11px;
  color: var(--color-neutral-dark);
}

.logo h1 {
  font-size: 22px;
  font-weight: 700;
  font-family: var(--font-family-serif);
  color: var(--color-primary);
}

.header-contact {
  text-align: right;
  font-size: 12px;
  color: var(--color-neutral-dark);
}

.header-access {
  margin-bottom: 4px;
}

.header-phone-label {
  display: inline-block;
  margin-right: 8px;
  font-size: 11px;
  color: var(--color-neutral-dark);
}

.phone-number {
  font-size: 18px;
  font-weight: 700;
  color: var(--color-primary);
  text-decoration: none;
}

.phone-number:hover {
  color: var(--color-primary-light);
}

.header-hours {
  margin-top: 4px;
}

/* ヘッダー内 CTAボタン */
.header-cta {
  text-align: right;          /* 右寄せ */
  margin-bottom: 4px;         /* ナビとの間の余白 */
}

.header-cta__btn {
  padding: 8px 24px;          /* 少し細めのボタンに調整 */
  font-size: 13px;
}

/* ロゴの右側（CTA＋連絡先）をまとめる */
.header-right {
  display: flex;
  align-items: center;
  gap: 24px;          /* ボタンと文字の距離（お好みで調整） */
}




/* Navigation */

.navbar {
  border-top: 1px solid var(--color-neutral-medium);
}

.navbar ul {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: 32px;
  padding: 10px 0;
  font-size: 14px;
}

.navbar a {
  text-decoration: none;
  color: var(--color-text);
  position: relative;
  padding-bottom: 4px;
}

.navbar a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background-color: var(--color-primary);
  transition: width 0.25s ease;
}

.navbar a:hover::after,
.navbar a:focus-visible::after {
  width: 100%;
}



/* ========== Hero ========== */

.hero {
  position: relative;
  padding: clamp(80px, 18vh, 120px) 0;
  width: 100%;
  background-image: url("assets/TOP1.png");   /* ここで背景画像を指定 */
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: #ffffff;                     /* テキストを白ベースに */
}

/* うっすら暗くして文字を読みやすくするオーバーレイ */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.15),
    rgba(0, 0, 0, 0.15)
  );
}

.hero-inner {
  position: relative;
  z-index: 1;           /* オーバーレイより前に出す */
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 24px;
}
.hero-tagline {
  font-size: clamp(11px, 1.2vw, 14px);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #ffffff;
  margin-bottom: 10px;
}

.hero-content h2 {
  font-size: clamp(26px, 3.6vw, 48px);
  font-weight: 700;
  font-family: var(--font-family-serif);
  line-height: 1.3;
  margin-bottom: 12px;
  color: #ffffff;
}

.hero-lead {
  font-size: clamp(14px, 1.6vw, 20px);
  color: #ffffff;
  margin-bottom: 24px;
}

/* 右側のダミー画像カラムは不要なので非表示にしておく */
.hero-image {
  display: none;
}

/* ヒーロー左下の子どもたちの歯みがき写真 */
.hero-kids {
  position: absolute;
  left: clamp(16px, 5vw, 56px);   /* 画面左端からの余白 */
  bottom: clamp(24px, 4vh, 40px); /* 画面下からの余白 */
  z-index: 2;
}

.hero-kids img {
  display: block;
  width: min(540px, 32vw);       /* 大きさはお好みで調整 */
  height: auto;
  border-radius: 10px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
}
@media (max-width: 768px) {
  /* 診療時間表はSPでは非表示 */
  .hero-schedule {
    display: none;
  }

  /* 歯みがき写真もSPでは非表示 */
  .hero-kids {
    display: none;
  }
}


/* タブレット〜小PC（780px〜1024px）のヒーロー調整 */
@media (min-width: 780px) and (max-width: 1024px) {
  .hero {
    min-height: 60vh;
    padding: 60px 0 80px;
    display: flex;
    align-items: flex-start; /* 上寄せ */
  }

  .hero-inner {
    transform: none;
    padding: 40px 40px 0;
    align-items: flex-start;
    text-align: left;
  }
}

@media (min-width: 1025px) {
  .hero {
    min-height: calc(100vh - 120px);
    padding: 0;
    display: flex;
    align-items: flex-start; /* 上寄せ（顔と被らないように） */
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    background-color: transparent;
  }
}

/* PCのとき、ヒーロー内の文字を上部に配置 */
@media (min-width: 1025px) {
  .hero-inner {
    transform: none;           /* translateY を完全にリセット */
    padding-top: 60px;         /* 上からの余白で位置を調整（40px〜80px でお好みに） */
    align-items: flex-start;   /* 左寄せ */
    text-align: left;
  }
}



/* ヒーロー右下の診療時間ボックス */
.hero-schedule {
  position: absolute;
  right: clamp(16px, 5vw, 56px); /* 画面右端からの余白 */
  bottom: clamp(24px, 4vh, 40px); /* 画面下からの余白 */
  z-index: 2;
}

.hero-schedule img {
  display: block;
  /* ★一回り大きく */
  width: min(540px, 34vw);
  height: auto;
  border-radius: 6px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
}



/* ========== News / お知らせ ========== */

.news-bar {
  background-color: var(--color-neutral-light);
  border-top: 1px solid var(--color-neutral-medium);
  border-bottom: 1px solid var(--color-neutral-medium);
  font-size: 14px;
  margin-top: 20px;   /* ← ここを追加（上に白い余白20px） */
}

.news-bar__inner {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 10px 0;
}

/* 左側の「お知らせ」ラベル */
.news-bar__label {
  font-size: 12px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--color-neutral-dark);
  white-space: nowrap;
}

/* 右側のお知らせリンク部分 */
.news-bar__list {
  flex: 1;
}

.news-bar__item {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--color-text);
}

.news-bar__item time {
  font-size: 14px;
  color: var(--color-neutral-dark);
}

/* 右端の矢印っぽいマーク（参考デザイン風） */
.news-bar__item::after {
  content: "→";
  margin-left: auto;
  font-size: 18px;
  line-height: 1;
  display: inline-block;
  transform: translateY(-1px);  /* ← 上に1pxずらす。気になる場合は -2px / 0px など調整 */
}


.news-bar__item:hover {
  text-decoration: underline;
}

/* SPでは中央揃え＆日付とテキストを横並びに */
@media (max-width: 768px) {
  .news-bar__inner {
    flex-direction: column;
    align-items: center;   /* 全体を中央に */
    gap: 6px;
    text-align: center;    /* テキスト中央揃え */
  }

  .news-bar__label {
    margin-right: 0;
  }

  .news-bar__list {
    width: 100%;
  }

  .news-bar__item {
    display: flex;
    flex-wrap: wrap;       /* 幅が足りないときは折り返す */
    align-items: center;
    justify-content: center;
    gap: 4px;
  }

  .news-bar__item time,
  .news-bar__item span {
    display: inline-block;
  }

  .news-bar__item::after {
    display: none;         /* SPでは矢印は非表示のまま */
  }
}





/* ========== Feature (3 promises) ========== */

.feature {
  padding: 72px 0;
  background-color: var(--color-white);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.feature-card {
  background-color: var(--color-white);
  border-radius: 10px;
  padding: 24px 22px 26px;
  border: 1px solid var(--color-border);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.03);
  text-align: left;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 26px rgba(0, 0, 0, 0.08);
}

.feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  background-color: var(--color-primary);
  color: var(--color-white);
  font-weight: 700;
  margin-bottom: 14px;
  font-size: 16px;
}

.feature-card h3 {
  font-size: 18px;
  margin-bottom: 10px;
  color: var(--color-text);
}

.feature-card p {
  font-size: 14px;
  color: var(--color-neutral-dark);
}

/* 特徴カードのサムネイル画像 */
.feature-thumb {
  margin-bottom: 16px;
  border-radius: 10px;
  overflow: hidden;         /* 角丸の中に画像を収める */
}

.feature-thumb img {
  display: block;
  width: 100%;
  height: 180px;            /* お好みで 160〜220px くらいに調整 */
  object-fit: cover;        /* カード幅に合わせてトリミング */
}


/* SPでは特徴カードを1列に */
@media (max-width: 768px) {
  .feature-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}




/* ========== Aftercare / 治療後のその先 ========== */

.aftercare {
  padding: 80px 0;
  background-color: #f7f4ec; /* 少し黄みがかった明るいベージュ */
}

.aftercare-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 48px;
  align-items: center;
}

.aftercare-title {
  font-family: var(--font-family-serif);
  font-size: 30px;
  line-height: 1.6;
  margin-bottom: 24px;
}

.aftercare-list {
  list-style: none;
  margin: 0;
  padding: 0;
  margin-bottom: 28px;
}

.aftercare-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 0;
  border-bottom: 1px solid var(--color-neutral-medium);
}

.aftercare-item:first-child {
  border-top: 1px solid var(--color-neutral-medium);
}

.aftercare-badge {
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background-color: var(--color-white);
  border: 1px solid var(--color-primary-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 600;
  color: var(--color-primary);
}

.aftercare-item-text {
  font-size: 16px;
  color: var(--color-text);
}

/* CTAボタン（黒いピル型＋矢印） */
.btn-dark {
  background-color: #333333;
  color: #ffffff;
  border-color: #333333;
}

.btn-dark:hover {
  background-color: #111111;
  border-color: #111111;
}

.aftercare-cta {
  margin-top: 6px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.aftercare-cta-arrow {
  font-size: 18px;
}

/* 右側の写真 */
.aftercare-image img {
  border-radius: 14px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.16);
  object-fit: cover;
}







/* ========== Services ========== */

.services {
  padding: 72px 0;
  background-color: var(--color-white);
}

/* 背景レイヤー */
.services-bg {
  position: relative;
  margin-top: 32px;
  padding: 40px 40px 48px;
}

/* 左下付近：背景写真 */
.services-bg::before {
  content: "";
  position: absolute;
  /* ★ 左下に寄せる */
  left: -150px;
  bottom: 0;
  /* サイズはお好みで調整 */
  width: 72%;   /* ← 横を少し広く */
  height: 85%;  /* ← 縦も少し高く */

  background-image: url("assets/ha.jpg");
  background-size: cover;
  background-position: center bottom;
  opacity: 0.12;
  z-index: 1;          /* 一番下（カードより後ろ） */
}

/* 右上付近：縦長ボックス（写真と少し重なる） */
.services-bg::after {
  content: "";
  position: absolute;
  /* ★ 右上に寄せる */
  right: -30px;
  top: 0;
  width: 50%;          /* 右側 4割くらいの帯 */
  height: 80%;         /* 上から 70% くらいまで */

  background-color: #e8e4e0;
  opacity: 0.4;
  z-index: 0;          /* 写真よりは前・カードよりは後ろ */
}

/* カードは一番手前 */
.services-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}




/* ここから下は今まで通りでOK（既存の service-card など） */
.service-card {
  background-color: var(--color-white);
  border-radius: 10px;
  border: 1px solid var(--color-border);
  padding: 22px 20px 24px;
  text-align: left;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.service-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 26px rgba(0, 0, 0, 0.08);
}

.service-image {
  height: 120px;
  border-radius: 10px;
  margin-bottom: 16px;
  background: linear-gradient(
    135deg,
    rgba(45, 127, 79, 0.07),
    rgba(26, 92, 58, 0.35)
  );
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: var(--color-white);
  font-weight: 600;
}

.service-image {
  height: 120px;
  border-radius: 10px;
  margin-bottom: 16px;
  overflow: hidden;          /* 角丸の中に画像をおさめる */
}

/* 追加：画像の表示ルール */
.service-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;         /* カードいっぱいにトリミング */
}




/* ========== Message (greeting) ========== */

.message {
  padding: 72px 0;
  background-color: var(--color-neutral-light);
}

.message-content {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 48px;
  align-items: center;
}

.message-text h2 {
  font-size: 28px;
  font-family: var(--font-family-serif);
  margin-bottom: 16px;
}

.message-text p {
  font-size: 14px;
  color: var(--color-text);
  margin-bottom: 14px;
}

.message-text .btn {
  margin-top: 10px;
}

.message-image .doctor-photo {
  height: 260px;
  border-radius: 16px;
  border: 1px solid var(--color-border);
  background: repeating-linear-gradient(
    -45deg,
    var(--color-neutral-medium),
    var(--color-neutral-medium) 6px,
    var(--color-neutral-light) 6px,
    var(--color-neutral-light) 12px
  );
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-neutral-dark);
  font-weight: 600;
}




/* ========== Doctor ========== */

.doctor {
  margin-top: -100px;
  padding: 72px 0;
  background-color: var(--color-neutral-light);
}

.doctor-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr);
  gap: 48px;
  align-items: center;
}

.doctor-photo-large {
  height: 280px;
  border-radius: 16px;
  border: 1px solid var(--color-border);
  background: linear-gradient(135deg, rgba(45,127,79,0.12), rgba(74,153,102,0.5));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-white);
  font-weight: 600;
}

.doctor-info h2 {
  font-size: 28px;
  font-family: var(--font-family-serif);
  margin-bottom: 8px;
}

.doctor-info h3 {
  font-size: 20px;
  margin-bottom: 4px;
}

.doctor-credentials {
  font-size: 13px;
  color: var(--color-neutral-dark);
  margin-bottom: 14px;
}

.doctor-info p {
  font-size: 14px;
  color: var(--color-text);
  margin-bottom: 16px;
}

.doctor-features {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 32px;
  margin-top: 8px;
}

.feature-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.feature-label {
  font-size: 12px;
  color: var(--color-neutral-dark);
}

.feature-value {
  font-size: 15px;
  font-weight: 600;
  color: var(--color-primary);
}

/* ========== Access ========== */

.access {
  padding: 72px 0;
  background-color: var(--color-white);
}

.access-content {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 88px;
  align-items: center;
}

.map-placeholder {
  height: 260px;
  border-radius: 16px;
  background: repeating-linear-gradient(
    -45deg,
    var(--color-neutral-medium),
    var(--color-neutral-medium) 6px,
    var(--color-neutral-light) 6px,
    var(--color-neutral-light) 12px
  );
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-neutral-dark);
  font-weight: 600;
}

.access-info h3 {
  font-size: 20px;
  margin-bottom: 8px;
}

.address {
  font-size: 14px;
  margin-bottom: 16px;
}

.access-detail {
  font-size: 14px;
  margin-bottom: 8px;
}


/* アクセス右側の待合室写真 */
.access-photo {
  margin-bottom: 16px;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.12);
}

.access-photo img {
  display: block;
  width: 100%;
  height: auto;      /* 縦横比を保ったまま縮小 */
  object-fit: cover;
}

/* 地図の枠（角丸＋影） */
.map-frame {
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.12);
  margin-bottom: 16px; /* 下に待合写真を置くなら少し余白 */
}

/* Google マップ iframe */
.map-frame iframe {
  display: block;
  width: 100%;
  height: 280px;   /* お好みで 260〜350px くらいに調整 */
  border: 0;
}

/* アクセス欄の電話番号だけ緑色に */
.address-tel {
  color: var(--color-primary); /* すでに使っている緑のメインカラー */
  font-weight: 700;
}


/* ========== Hours ========== */

.hours {
  padding: 72px 0;
  background-color: var(--color-neutral-light);
}

.hours-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  background-color: var(--color-white);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.05);
}

.hours-table th,
.hours-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--color-neutral-medium);
  text-align: center;
}

.hours-table th {
  background-color: var(--color-primary);
  color: var(--color-white);
  font-weight: 600;
}

.hours-table tr:last-child td {
  border-bottom: none;
}

.hours-table .closed {
  background-color: #f8d7da;
  color: #842029;
  font-weight: 600;
}


/* 診療時間セクション */
.hours {
  padding: 72px 0;
  background-color: #f7f5f0; /* お好みで。今の背景に合わせてOK */
}

.hours-image {
  margin-top: 24px;
  max-width: 960px;          /* 画像の最大横幅（大きめに） */
  margin-left: auto;
  margin-right: auto;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.12);
}

.hours-image img {
  display: block;
  width: 100%;
  height: auto;              /* 縦横比を保って拡大縮小 */
}



/* ========== Contact ========== */

.contact {
  padding: 72px 0;
  background-color: var(--color-white);
}

.contact .section-subtitle {
  margin-bottom: 32px;
}

.contact-form {
  max-width: 720px;
  margin: 0 auto;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin-bottom: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-neutral-dark);
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 6px;
  border: 1px solid var(--color-border);
  font-family: var(--font-family-sans);
  font-size: 14px;
  color: var(--color-text);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 2px rgba(45, 127, 79, 0.16);
}

.contact-form textarea {
  resize: vertical;
  min-height: 140px;
}

.submit-button {
  width: 100%;
  margin-top: 8px;
  padding: 14px;
  border-radius: 999px;
  border: none;
  background-color: var(--color-primary);
  color: var(--color-white);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.submit-button:hover {
  background-color: var(--color-accent);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.12);
  transform: translateY(-1px);
}

/* ========== Footer ========== */

.footer {
  background-color: var(--color-neutral-dark);
  color: var(--color-white);
  padding: 48px 0 20px;
  margin-bottom: -74px;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px;
  margin-bottom: 32px;
  font-size: 13px;
}

.footer-section h4 {
  font-size: 15px;
  margin-bottom: 10px;
  font-weight: 600;
}

.footer-section p {
  line-height: 1.9;
}

.footer-section ul {
  list-style: none;
  padding: 0;
}

.footer-section li + li {
  margin-top: 4px;
}

.footer-section a {
  color: var(--color-white);
  text-decoration: none;
  font-size: 13px;
}

.footer-section a:hover {
  color: var(--color-primary-light);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  padding-top: 14px;
  text-align: center;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.8);
}

/* ========== Responsive ========== */

@media (max-width: 1024px) {
  .hero-inner,
  .message-content,
  .doctor-content,
  .access-content {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero-image {
    order: -1;
  }

  .services-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }


}

@media (max-width: 768px) {
  .footer {
  margin-bottom: 0px;
}

  .header-top {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .header-contact {
    text-align: left;
  }

  .navbar ul {
    flex-wrap: wrap;
    gap: 16px;
  }

  .hero {
    padding: 48px 0;
  }

  .hero-inner {
    gap: 32px;
  }

  .hero-content h2 {
    font-size: 30px;
  }

  .hero-lead {
    font-size: 16px;
  }

  .feature,
  .message,
  .services,
  .doctor,
  .access,
  .hours,
  .contact {
    padding: 56px 0;
  }

  .services-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .footer-content {
    grid-template-columns: minmax(0, 1fr);
  }

  .form-row {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 480px) {
  .navbar ul {
    justify-content: flex-start;
  }

  .hero-content h2 {
    font-size: 24px;
  }

  .section-title {
    font-size: 26px;
  }

  .feature-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .services-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}


/* ========= ヘッダー固定を解除 ========= */
.header {
  position: static !important;  /* 追従しない普通のヘッダーに戻す */
}



/* ===== SP Header Hamburger ＆ layout ===== */

/* PCでは非表示にしておくボタンの基本スタイル */
.nav-toggle {
  display: none;                    /* PCでは見せない */
  width: 50px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--color-neutral-medium);
  border-radius: 999px;
  background-color: var(--color-white);
  cursor: pointer;
  align-items: center;
  justify-content: center;
  flex-direction: column;           /* 三本線を縦に並べる */
}

.nav-toggle:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* 三本線 */
.nav-toggle__bar {
  display: block;
  width: 20px;
  height: 2px;
  border-radius: 999px;
  background-color: var(--color-text);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.nav-toggle__bar + .nav-toggle__bar {
  margin-top: 4px;
}

/* 開いた時のアニメーション */
.nav-toggle.is-open .nav-toggle__bar:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}
.nav-toggle.is-open .nav-toggle__bar:nth-child(2) {
  opacity: 0;
}
.nav-toggle.is-open .nav-toggle__bar:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* ▼ スマホ（〜768px）用レイアウト ▼ */
@media (max-width: 768px) {
  /* ハンバーガーをヘッダー右上に固定するための基準 */
  .header .container {
    position: relative;
  }

  /* ロゴ → その下にCTAが来るように縦並び */
  .header-top {
    flex-direction: column;
    align-items: flex-start;
    padding: 12px 16px;
    gap: 8px;
  }

  /* CTA＋連絡先ブロックを縦並びにして左寄せ */
  .header-right {
    margin-left: 0;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }

  /* CTAボタンをロゴの下・左寄せ＆少し小さく */
  .header-cta {
    text-align: left;
    margin-bottom: 0;
  }

  .header-cta__btn {
    padding: 6px 16px;
    font-size: 12px;
  }

  /* SPでは住所・電話などは非表示 */
  .header-contact {
    display: none;
  }

  /* ハンバーガーメニューを右上に固定配置 */
  .nav-toggle {
    display: inline-flex;
    position: absolute;
    top: 16px;
    right: 16px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  }

  /* ドロワーメニュー（閉じているときは非表示） */
  .navbar {
    border-top: 1px solid var(--color-neutral-medium);
    display: none;
  }

  .navbar.is-open {
    display: block;
  }

  .navbar ul {
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    padding: 8px 16px 16px;
  }

  .navbar li + li {
    margin-top: 8px;
  }

  /* フッター文字も少しだけ小さく */
  .footer-section h4 {
    font-size: 14px;
  }
  .footer-section p,
  .footer-section li,
  .footer-bottom {
    font-size: 11px;
  }

    /* 診療時間表はSPでは非表示 */
  .hero-schedule {
    display: none;
  }
}


/* ▼ SP：ヒーロー画像を少し大きく見せる ▼ */
@media (max-width: 768px) {
  .hero {
    /* セクション自体の高さを伸ばして、画像の見える面積を増やす */
    min-height: 40vh;          /* 画面の約8割の高さまで広げる */
    padding: 72px 0 96px;      /* 上下の余白も少し増やす */
    background-position: center top;  /* 上側を少し強調して表示 */
  }

  .hero-inner {
    padding: 0 16px;           /* 左右に少し余白を足してバランス調整 */
  }

    .hero-inner {
    transform: translateY(-50px);  /* 数字を -20px ～ -60px くらいでお好み調整OK */
  }
}

/* SPでは「治療後のその先」を縦並びにして、CTAの下に画像を配置 */
@media (max-width: 768px) {
  .aftercare-inner {
    grid-template-columns: minmax(0, 1fr);  /* 1列レイアウト */
    gap: 32px;
  }

  /* 念のため順番を指定（テキスト → 画像） */
  .aftercare-text {
    order: 1;
  }

  .aftercare-image {
    order: 2;
    justify-self: center;      /* 中央寄せ */
    max-width: 360px;          /* 好みで調整可 */
  }

  .aftercare-image img {
    width: 100%;
    height: auto;
  }
}

/* SPでは「初めての方はこちら」ボタンを中央配置 */
@media (max-width: 768px) {
  .aftercare-cta {
    display: flex;              /* テキスト＋矢印を横並びのまま */
    align-items: center;
    gap: 10px;
    width: fit-content;         /* 中身の幅に合わせる */
    margin: 16px auto 0;        /* 左右 auto で全体を中央に */
  }
}

/* SP：院長メッセージのレイアウト調整 */
@media (max-width: 768px) {
  /* グリッドは1列のまま＋上下の余白少し広めに */
  .message-content {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
  }

  /* 写真を先に表示（上） */
  .message-image {
    order: -1;          /* ← これで写真ブロックが先頭に来る */
  }

  /* テキストは後ろ（下） */
  .message-text {
    order: 1;
  }

  /* 「院長プロフィールを見る」ボタンを中央に */
  .message-text .btn {
    display: block;
    width: fit-content;
    margin: 24px auto 0;   /* 左右 auto で中央配置 */
  }
}


/* SP：アクセス欄の余白＆中央揃え */
@media (max-width: 768px) {
  /* セクション上の余白を少し詰める */
  .access {
    padding-top: 40px;   /* 好みで 32px〜40px くらいに調整OK */
  }

  /* テキストとボタンを中央寄せ */
  .access-info {
    text-align: center;
    margin-top: -70px;
  }

  /* 見出しの上マージンを消して、上の余白を詰める */
  .access-info h3 {
    margin-top: 0;
  }

  /* 予約ボタンをど真ん中に */
  .access-info .btn {
    display: inline-block;
    margin: 24px auto 0;  /* 左右 auto で中央に */
  }
}

@media (max-width: 768px) {
.doctor {
  margin-top: -50px;}
}


@media (max-width: 768px) {
.footer {
  margin-bottom: -56px;
}
}

/* === SPでの横スクロール対策（診療内容セクション） === */
@media (max-width: 768px) {
  /* 背景カードの装飾はSPでは非表示にする */
  .services-bg::before,
  .services-bg::after {
    display: none;
  }

  /* ついでに内側の余白も少しだけ調整（お好みで） */
  .services-bg {
    padding: 32px 16px 40px;
  }
}
