/* ==========================================
   関崎歯科医院 - メインスタイルシート
   ==========================================
   カラーパレット（CSS変数）
   --primary:    hsl(152 40% 42%)  メイングリーン
   --bg:         hsl(140 20% 98%)  ページ背景
   --foreground: hsl(150 10% 15%)  テキスト
   --border:     hsl(145 15% 88%)  ボーダー
   --accent:     hsl(148 30% 90%)  アクセント背景
   ========================================== */

/* ==========================================
   リセット・ベース
   ========================================== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Noto Sans JP", sans-serif;
  background: hsl(140 20% 98%);
  color: hsl(150 10% 15%);
  -webkit-font-smoothing: antialiased;
}

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

/* スクロールバー非表示 */
::-webkit-scrollbar {
  display: none;
}

/* ==========================================
   ランディングセクション
   ========================================== */

/* ブロックのフレックス拡縮アニメーション */
.block-transition {
  transition:
    flex 0.5s cubic-bezier(0.4, 0, 0.2, 1),
    box-shadow 0.3s ease,
    border-radius 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* a タグで使う場合のリセット（block-transition と併用） */
a.block-transition {
  text-decoration: none;
  color: inherit;
}

/* 動画パネル：動画が常にパネルを完全に覆うよう微調整
   flex アニメーション中に背景が透けないよう 4px のバッファ */
[data-block="movie"] video {
  top: -4px;
  left: -4px;
  right: -4px;
  bottom: -4px;
  width: calc(100% + 8px);
  height: calc(100% + 8px);
}

/* 動画パネル拡大時：rounded を解除して端の欠けを防ぐ */
[data-block="movie"].block-hovered {
  border-radius: 0.5rem;
}

/* ホバー時に表示されるテキスト */
.hover-desc {
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  transition:
    opacity 0.4s ease,
    max-height 0.4s ease;
}

.block-hovered .hover-desc {
  opacity: 1;
  max-height: 120px;
}

/* ホバー時に表示される「詳しく見る」矢印 */
.hover-arrow {
  opacity: 0;
  transition: opacity 0.3s ease;
}

.block-hovered .hover-arrow {
  opacity: 1;
}

/* 下段パネル：ホバー時にアイコン・ラベル文字のみ拡大（パネル自体は拡縮しない） */
.panel-icon {
  transition:
    transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
    box-shadow 0.3s ease;
}

.block-hovered .panel-icon {
  transform: scale(1.15) translateY(-2px);
}

.panel-label {
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: inline-block;
}

.block-hovered .panel-label {
  transform: scale(1.1);
}

/* 英字サブラベル */
.panel-sub {
  transition: opacity 0.3s ease;
}

/* パネル全体のホバー演出 */
.info-panel {
  transition:
    transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
    box-shadow 0.3s ease,
    border-color 0.3s ease;
}

.info-panel.block-hovered {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px -4px rgba(0, 0, 0, 0.12) !important;
}

/* ==========================================
   ランディング：ルート・ヘッダー
   ========================================== */

.landing-root {
  height: 100dvh;
  background: hsl(140 20% 98%);
}

.landing-header {
  padding: clamp(8px, 1vh, 16px) clamp(12px, 2vw, 32px);
  background: hsla(0, 0%, 100%, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-color: hsl(145 15% 88%);
  z-index: 40;
}

.landing-logo {
  gap: clamp(6px, 0.8vw, 12px);
}

.landing-logo__bar {
  height: clamp(28px, 3vh, 40px);
  width: 4px;
  background: hsl(152 40% 42%);
}

.landing-logo__title {
  font-size: clamp(24px, 2.8vw, 40px);
  color: hsl(150 10% 15%);
}

.landing-logo__subtitle {
  font-size: clamp(14px, 1.2vw, 20px);
  color: hsl(152 40% 42%);
  letter-spacing: 0.15em;
}

.landing-header__actions {
  gap: clamp(8px, 1vw, 16px);
}

.landing-tel-link {
  padding: clamp(10px, 1.2vh, 18px) clamp(20px, 2.4vw, 36px);
  font-size: clamp(20px, 1.7vw, 28px);
  background: hsl(152 40% 42%);
  color: white;
  gap: clamp(8px, 1vw, 16px);
  box-shadow: 0 4px 14px -2px hsla(152, 40%, 42%, 0.3);
}

.landing-tel-link__icon {
  width: clamp(24px, 2vw, 32px);
  height: clamp(24px, 2vw, 32px);
}

/* ==========================================
   ランディング：パネルエリア
   ========================================== */

.panel-area {
  padding: clamp(8px, 1vw, 16px);
  gap: clamp(6px, 0.6vw, 10px);
}

.panel-row {
  gap: clamp(6px, 0.6vw, 10px);
}

.panel-row--top {
  flex: 3;
}
.panel-row--bottom {
  flex: 1;
}

/* ==========================================
   ランディング：サービスパネル（上段）
   ========================================== */

.service-panel__img {
  filter: saturate(0.88) brightness(0.96);
}

.service-panel__overlay {
  background: linear-gradient(
    to top,
    hsla(150, 10%, 10%, 0.75),
    hsla(150, 10%, 10%, 0.15),
    transparent
  );
}

.service-panel__deco {
  top: clamp(4px, 0.5vh, 8px);
  right: clamp(8px, 1vw, 16px);
  color: hsla(0, 0%, 100%, 0.1);
}

.service-panel__deco--xl {
  font-size: clamp(48px, 7vw, 120px);
}
.service-panel__deco--lg {
  font-size: clamp(36px, 5vw, 80px);
}

.service-panel__body {
  padding: clamp(10px, 1.2vw, 20px);
}

.service-panel__title {
  font-size: clamp(14px, 1.6vw, 28px);
  color: white;
  margin-bottom: clamp(2px, 0.3vh, 6px);
}

.service-panel__desc {
  font-size: clamp(8px, 0.7vw, 12px);
  color: hsla(0, 0%, 100%, 0.85);
}

.service-panel__cta {
  font-size: clamp(8px, 0.65vw, 11px);
  color: white;
  margin-top: clamp(2px, 0.3vh, 4px);
}

.service-panel__cta-icon {
  width: clamp(10px, 0.8vw, 14px);
  height: clamp(10px, 0.8vw, 14px);
}

/* ==========================================
   ランディング：動画パネル（上段中央）
   ========================================== */

.movie-panel__video-wrap {
  background: hsl(150 10% 15%);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.18);
}

.movie-panel__body {
  padding: clamp(10px, 1.2vw, 20px);
}

.movie-panel__title {
  font-size: clamp(12px, 1.4vw, 24px);
  color: black;
}

.movie-panel__desc {
  font-size: clamp(8px, 0.7vw, 12px);
  color: hsla(0, 0%, 100%, 0.75);
}

/* ==========================================
   ランディング：インフォパネル（下段）共通
   ========================================== */

.info-panel__accent {
  height: 3px;
}

.info-panel__deco {
  border-radius: 50%;
}

.info-panel__deco--lg {
  right: -20%;
  bottom: -30%;
  width: clamp(80px, 8vw, 140px);
  height: clamp(80px, 8vw, 140px);
}

.info-panel__deco--sm {
  left: -10%;
  top: -20%;
  width: clamp(60px, 6vw, 100px);
  height: clamp(60px, 6vw, 100px);
}

.info-panel__icon-box {
  width: clamp(36px, 3.4vw, 52px);
  height: clamp(36px, 3.4vw, 52px);
  margin-bottom: clamp(6px, 0.5vh, 10px);
}

.info-panel__icon-svg {
  width: clamp(16px, 1.5vw, 22px);
  height: clamp(16px, 1.5vw, 22px);
}

.info-panel__label {
  font-size: clamp(10px, 0.9vw, 15px);
  color: hsl(150 10% 15%);
}

.info-panel__sub {
  font-size: clamp(7px, 0.55vw, 10px);
  color: hsl(150 5% 55%);
  margin-top: clamp(1px, 0.15vh, 3px);
  letter-spacing: 0.08em;
}

.info-panel__arrow {
  font-size: clamp(7px, 0.55vw, 10px);
  margin-top: clamp(3px, 0.3vh, 6px);
}

.info-panel__arrow-icon {
  width: clamp(8px, 0.6vw, 12px);
  height: clamp(8px, 0.6vw, 12px);
}

/* ==========================================
   インフォパネル：カラーバリエーション
   ========================================== */

/* グリーン（お知らせ） */
.info-panel--green {
  background: linear-gradient(145deg, hsl(148 35% 97%), hsl(152 25% 94%));
  border: 1px solid hsl(148 25% 88%);
}
.info-panel--green .info-panel__accent {
  background: linear-gradient(to right, hsl(152 40% 42%), hsl(170 40% 55%));
}
.info-panel--green .info-panel__deco--lg {
  background: radial-gradient(
    circle,
    hsla(152, 40%, 42%, 0.06),
    transparent 70%
  );
}
.info-panel--green .info-panel__deco--sm {
  background: radial-gradient(
    circle,
    hsla(152, 35%, 50%, 0.04),
    transparent 65%
  );
}
.info-panel--green .info-panel__icon-box {
  background: linear-gradient(135deg, hsl(152 40% 42%), hsl(162 38% 48%));
  box-shadow: 0 4px 12px -2px hsla(152, 40%, 42%, 0.25);
}
.info-panel--green .info-panel__arrow {
  color: hsl(152 40% 42%);
}

/* ブルー（アクセス） */
.info-panel--blue {
  background: linear-gradient(145deg, hsl(200 30% 97%), hsl(210 22% 94%));
  border: 1px solid hsl(205 22% 88%);
}
.info-panel--blue .info-panel__accent {
  background: linear-gradient(to right, hsl(210 50% 55%), hsl(190 45% 58%));
}
.info-panel--blue .info-panel__deco--lg {
  background: radial-gradient(
    circle,
    hsla(210, 45%, 50%, 0.06),
    transparent 70%
  );
}
.info-panel--blue .info-panel__deco--sm {
  background: radial-gradient(
    circle,
    hsla(210, 35%, 55%, 0.04),
    transparent 65%
  );
}
.info-panel--blue .info-panel__icon-box {
  background: linear-gradient(135deg, hsl(210 50% 55%), hsl(195 45% 52%));
  box-shadow: 0 4px 12px -2px hsla(210, 50%, 50%, 0.25);
}
.info-panel--blue .info-panel__arrow {
  color: hsl(210 50% 55%);
}

/* オレンジ（診療日） */
.info-panel--orange {
  background: linear-gradient(145deg, hsl(35 40% 97%), hsl(28 30% 94%));
  border: 1px solid hsl(30 28% 88%);
}
.info-panel--orange .info-panel__accent {
  background: linear-gradient(to right, hsl(30 55% 55%), hsl(45 50% 58%));
}
.info-panel--orange .info-panel__deco--lg {
  background: radial-gradient(
    circle,
    hsla(35, 45%, 50%, 0.06),
    transparent 70%
  );
}
.info-panel--orange .info-panel__deco--sm {
  background: radial-gradient(
    circle,
    hsla(35, 35%, 55%, 0.04),
    transparent 65%
  );
}
.info-panel--orange .info-panel__icon-box {
  background: linear-gradient(135deg, hsl(30 55% 55%), hsl(42 50% 55%));
  box-shadow: 0 4px 12px -2px hsla(30, 50%, 50%, 0.25);
}
.info-panel--orange .info-panel__arrow {
  color: hsl(30 55% 50%);
}

/* パープル（院長） */
.info-panel--purple {
  background: linear-gradient(145deg, hsl(270 25% 97%), hsl(265 18% 94%));
  border: 1px solid hsl(268 18% 88%);
}
.info-panel--purple .info-panel__accent {
  background: linear-gradient(to right, hsl(270 40% 58%), hsl(285 35% 60%));
}
.info-panel--purple .info-panel__deco--lg {
  background: radial-gradient(
    circle,
    hsla(270, 35%, 55%, 0.06),
    transparent 70%
  );
}
.info-panel--purple .info-panel__deco--sm {
  background: radial-gradient(
    circle,
    hsla(270, 30%, 55%, 0.04),
    transparent 65%
  );
}
.info-panel--purple .info-panel__icon-box {
  background: linear-gradient(135deg, hsl(270 40% 58%), hsl(280 35% 55%));
  box-shadow: 0 4px 12px -2px hsla(270, 40%, 50%, 0.25);
}
.info-panel--purple .info-panel__arrow {
  color: hsl(270 40% 55%);
}

/* ==========================================
   セクション共通（コンテナ・ヘッダー）
   ========================================== */

.section--accent-bg {
  background: hsl(148 30% 90% / 0.4);
}
.section--padded {
  padding: 4rem 1rem;
}

.section__container {
  max-width: 1280px;
  padding: 4rem 1rem;
}

.section__container--narrow {
  max-width: 520px;
}

.section__container--no-pad {
  max-width: 1280px;
}

.section__header {
  margin-bottom: 2.5rem;
}

/* 現在ページ表示用の無効化リンク（nav/footer/sitemap で共通） */
.is-current-page {
  opacity: 0.7;
  cursor: default;
}

/* 機能未実装パネルの無効化表示（お知らせなど）
   親要素にグレースケール＋透過をかけて、disable 感を視覚的に表現
   ホバーでも色は変化させず、常に同じ disable 表示を保つ */
.is-coming-soon {
  filter: grayscale(0.7) opacity(0.75);
  cursor: default;
}

.info-panel__coming-soon {
  color: hsl(150 5% 55%);
  letter-spacing: 0.04em;
}

/* ==========================================
   アクセスセクション
   ========================================== */

.access-image {
  border-color: hsl(145 15% 88%);
  aspect-ratio: 4/3;
  min-height: 240px;
}

.access-image > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(0.88) brightness(0.96);
}

.access-image__overlay {
  position: absolute;
  inset: 0;
  background: hsla(148, 30%, 20%, 0.12);
  pointer-events: none;
}

.access-info {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.access-info__row {
  display: flex;
  gap: 1rem;
}

.access-info__row-body {
  flex: 1;
}

.access-info__icon {
  width: 20px;
  height: 20px;
}

.access-info__title {
  font-size: 0.875rem;
  font-weight: 600;
  color: hsl(150 10% 15%);
  margin-bottom: 0.25rem;
}

.access-info__title--loose {
  margin-bottom: 0.5rem;
}

.access-info__text {
  font-size: 0.875rem;
  color: hsl(150 5% 45%);
  line-height: 1.7;
}

.access-info__tel {
  color: hsl(152 40% 42%);
  font-weight: 600;
  font-size: 1.1rem;
}

.access-info__note {
  font-size: 0.75rem;
  color: hsl(150 5% 45%);
  margin-top: 0.5rem;
}

.access-info__note--tight {
  margin-top: 0.25rem;
}

/* 診療時間テーブル */
.clinic-table th.is-weekday {
  color: black;
}
.clinic-table th.is-sat {
  color: hsl(217 91% 60%);
}
.clinic-table th.is-sun {
  color: hsl(0 84.2% 60.2%);
}

.clinic-table__time {
  font-size: 0.7rem;
  color: hsl(150 10% 15%);
  font-weight: 500;
}

.access-map {
  margin-top: 1.5rem;
  border-radius: 1rem;
  overflow: hidden;
  border: 1px solid hsl(145 15% 88%);
}

.access-map > iframe {
  border: 0;
  display: block;
}

/* ==========================================
   カレンダーセクション
   ========================================== */

.calendar-card {
  border-radius: 1rem;
  border: 1px solid hsl(145 15% 88%);
  background: white;
  padding: 1.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.calendar-card__nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}

.calendar-card__title {
  font-size: 1.125rem;
  font-weight: 600;
  color: hsl(150 10% 15%);
}

.calendar-grid--header {
  margin-bottom: 0.5rem;
}

.calendar-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid hsl(145 15% 88%);
}

.calendar-legend__item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.calendar-legend__swatch {
  width: 14px;
  height: 14px;
  border-radius: 3px;
  flex-shrink: 0;
}

.calendar-legend__swatch--closed {
  background: hsl(350 52% 94%);
  border: 1px solid hsl(350 35% 84%);
}

.calendar-legend__swatch--partial {
  background: hsl(210 75% 93%);
  border: 1px solid hsl(210 45% 82%);
}

.calendar-legend__swatch--pm-closed {
  background: hsl(38 92% 90%);
  border: 1px solid hsl(32 55% 72%);
}

.calendar-legend__label {
  font-size: 0.75rem;
  color: hsl(150 5% 45%);
}

/* ==========================================
   院長紹介セクション
   ========================================== */

.director-header {
  margin-bottom: 1.5rem;
}

.director-header__role {
  font-size: 0.875rem;
  color: hsl(152 40% 42%);
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.director-header__name {
  font-size: 1.75rem;
  font-weight: 600;
  color: hsl(150 10% 15%);
  margin-bottom: 0.25rem;
  letter-spacing: 0.05em;
}

.director-header__furigana {
  font-size: 0.8rem;
  color: hsl(150 5% 45%);
  letter-spacing: 0.05em;
}

.director-bio {
  font-size: 0.875rem;
  color: hsl(150 5% 45%);
  line-height: 1.8;
  margin-bottom: 2rem;
}

.skill-card {
  border-radius: 0.75rem;
  border: 1px solid hsl(145 15% 88%);
  background: white;
  padding: 1rem;
}

.skill-card__head {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.skill-card__icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  margin-top: 2px;
}

.skill-card__title {
  font-size: 0.75rem;
  font-weight: 600;
  color: hsl(150 10% 15%);
  margin-bottom: 0.35rem;
}

.skill-card__text {
  font-size: 0.75rem;
  color: hsl(150 5% 45%);
  line-height: 1.7;
}

.skill-card__publisher {
  color: hsl(152 40% 42%);
  font-weight: 500;
}

/* ==========================================
   フッター
   ========================================== */

.site-footer {
  border-top: 1px solid hsl(145 15% 88%);
  background: white;
}

.site-footer__container {
  max-width: 1280px;
  padding: 3rem 1rem;
}

.site-footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.site-footer-brand__logo {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: hsl(152 40% 42%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.site-footer-brand__logo-text {
  color: white;
  font-size: 0.875rem;
  font-weight: 700;
}

.site-footer-brand__name {
  font-size: 1rem;
  font-weight: 600;
  color: hsl(150 10% 15%);
}

.site-footer__tagline {
  font-size: 0.75rem;
  color: hsl(150 5% 45%);
  line-height: 1.7;
}

.site-footer__group-title {
  font-size: 0.7rem;
  font-weight: 600;
  color: hsl(150 10% 15%);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1rem;
}

.site-footer__group-links {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.site-footer__bottom {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid hsl(145 15% 88%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.site-footer__copyright {
  font-size: 0.7rem;
  color: hsl(150 5% 45%);
}

.site-footer__bottom-links {
  display: flex;
  gap: 1rem;
}

.site-footer__bottom-links .footer-link {
  font-size: 0.7rem;
}

/* ==========================================
   モバイルメニュー：電話アイコン
   ========================================== */

.mobile-menu__tel-icon {
  width: 20px;
  height: 20px;
}

.mobile-menu__tel-note {
  font-size: 0.75rem;
  color: hsl(150 5% 55%);
  margin-top: 0.5rem;
}

/* ==========================================
   セクション共通スタイル
   ========================================== */

.section-label {
  font-size: 0.75rem;
  font-weight: 500;
  color: hsl(152 40% 42%);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.section-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: hsl(150 10% 15%);
  line-height: 1.3;
}

@media (min-width: 1024px) {
  .section-title {
    font-size: 1.875rem;
  }
}

/* ==========================================
   アクセスセクション
   ========================================== */

/* アイコン付きの情報アイテム */
.info-icon-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 0.75rem;
  background: hsl(148 30% 90%);
  flex-shrink: 0;
}

/* 診療時間テーブル */
.clinic-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
}

.clinic-table th,
.clinic-table td {
  padding: 0.5rem 0.75rem;
  border: 1px solid hsl(145 15% 88%);
  text-align: center;
}

.clinic-table th {
  background: hsl(148 30% 90%);
  font-weight: 600;
  color: hsl(150 10% 15%);
  font-size: 0.75rem;
}

.clinic-table td {
  color: hsl(150 5% 45%);
}

.clinic-table .open {
  color: hsl(152 40% 42%);
  font-weight: 600;
}

.clinic-table .closed {
  color: hsl(0 84.2% 60.2%);
  font-weight: 500;
}

.clinic-table .partial {
  color: hsl(152 40% 42%);
  font-weight: 600;
}

/* ==========================================
   診療日カレンダー
   ========================================== */

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

/* 曜日ヘッダー */
.cal-day-header {
  text-align: center;
  font-size: 0.7rem;
  font-weight: 500;
  padding: 0.5rem 0;
}

.cal-day-header.sun {
  color: hsl(0 84.2% 60.2%);
}
.cal-day-header.sat {
  color: hsl(217 91% 60%);
}
.cal-day-header.thu {
  color: black;
}
.cal-day-header.weekday {
  color: black;
}

/* 月送りボタン（前月／翌月） */
.calendar-nav-btn {
  padding: 0.5rem;
  border-radius: 0.5rem;
  border: none;
  background: none;
  cursor: pointer;
  color: hsl(150 10% 15%);
  transition: background 0.15s ease;
}

.calendar-nav-btn:hover {
  background: hsl(148 30% 90%);
}

.calendar-nav-btn:focus-visible {
  outline: 2px solid hsl(152 40% 42%);
  outline-offset: 2px;
}

.calendar-nav-btn svg {
  width: 20px;
  height: 20px;
}

/* 日付セル */
.cal-cell {
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-radius: 0.5rem;
  font-size: 0.8rem;
  cursor: default;
  transition: background 0.15s;
  min-width: 0;
  overflow: hidden;
}

/* 日付数字（全セル中央寄せで統一） */
.cal-cell__num {
  font-size: 0.78rem;
  line-height: 1.15;
  font-weight: 600;
  text-align: center;
}

/* 土日の数字色（曜日ヘッダーと揃える） */
.cal-cell--dow-0 .cal-cell__num {
  color: hsl(0 84.2% 52%);
}

.cal-cell--dow-6 .cal-cell__num {
  color: hsl(217 91% 52%);
}

/* 平日・その他は既定の墨色 */
.cal-cell--dow-1 .cal-cell__num,
.cal-cell--dow-2 .cal-cell__num,
.cal-cell--dow-3 .cal-cell__num,
.cal-cell--dow-4 .cal-cell__num,
.cal-cell--dow-5 .cal-cell__num {
  color: hsl(150 10% 18%);
}

.cal-cell.normal {
  background: transparent;
}

.cal-cell.normal:hover {
  background: hsl(148 28% 94%);
}

/* 休診：ピンク系（参考カレンダー）＋下に「休診」ラベル */
.cal-cell.closed {
  background: hsl(350 52% 94%);
  border: 1px solid hsl(350 35% 84%);
  font-weight: 500;
}

.cal-cell__closed-bar {
  margin-top: auto;
  width: 100%;
  align-self: stretch;
  background: hsl(340 48% 40%);
  color: hsl(0 0% 100%);
  font-size: clamp(0.52rem, 1.6vw, 0.62rem);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-align: center;
  padding: 0.28rem 0 0.32rem;
  line-height: 1;
  border-radius: 0 0 calc(0.5rem - 1px) calc(0.5rem - 1px);
  flex-shrink: 0;
}

/* 土曜短縮診療（水色） */
.cal-cell.partial {
  background: hsl(210 75% 93%);
  border: 1px solid hsl(210 45% 82%);
  font-weight: 500;
}

.cal-cell.partial .cal-cell__num {
  color: hsl(220 58% 36%);
}

.cal-cell.partial.cal-cell--dow-6 .cal-cell__num {
  color: hsl(217 91% 44%);
}

.cal-cell.partial:hover {
  background: hsl(210 70% 90%);
}

/* 午後休診（data/calendar-data.json の afternoonClosed） */
.cal-cell.pm-closed {
  background: hsl(38 92% 90%);
  border: 1px solid hsl(32 55% 72%);
  font-weight: 500;
}

.cal-cell.pm-closed .cal-cell__num {
  color: hsl(28 55% 28%);
}

.cal-cell.pm-closed.cal-cell--dow-0 .cal-cell__num {
  color: hsl(0 84.2% 42%);
}

.cal-cell.pm-closed.cal-cell--dow-6 .cal-cell__num {
  color: hsl(217 91% 38%);
}

.cal-cell.pm-closed:hover {
  background: hsl(38 88% 86%);
}

/* ==========================================
   フッター
   ========================================== */

.footer-link {
  font-size: 0.75rem;
  color: hsl(150 5% 45%);
  transition: color 0.2s;
}

.footer-link:hover {
  color: hsl(152 40% 42%);
}

/* ==========================================
   レスポンシブグリッド
   ========================================== */

.grid-access {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

.grid-director {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

/* 院長ブロック：イラスト＋文面を一枚のカードに */
.director-card {
  background: linear-gradient(
    180deg,
    hsl(0 0% 100% / 0.97) 0%,
    hsl(148 40% 99% / 0.98) 100%
  );
  border: 1px solid hsl(145 20% 86%);
  border-radius: 1.25rem;
  padding: clamp(1.25rem, 3.5vw, 2.25rem);
  box-shadow:
    0 20px 50px -24px hsla(152, 35%, 28%, 0.14),
    0 8px 20px -12px hsla(150, 20%, 18%, 0.06);
}

.director-card .grid-director {
  gap: clamp(1.25rem, 3vw, 2rem);
  align-items: stretch;
}

.director-card__body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.director-card__media {
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

/* 資格カードをカード内で一段だけ柔らかく区切る
   grid-skills 配下でも、director-card__body 直下でも同じ見た目になるように */
.director-card .grid-skills > div,
.director-card .skill-card {
  background: hsl(148 35% 97%) !important;
  border-color: hsl(145 18% 90%) !important;
}

/* director-card 直下に置かれた skill-card は横幅いっぱい */
.director-card__body > .skill-card {
  width: fit-content;
  box-sizing: border-box;
}

.grid-skills {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.grid-skills p {
  word-break: break-all;
  overflow-wrap: break-word;
  min-width: 0;
}

.grid-skills > div > div > div {
  min-width: 0;
}

.grid-footer {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

/* sm: 640px以上 */
@media (min-width: 640px) {
  .grid-footer {
    grid-template-columns: 1fr 1fr;
  }
  .grid-skills {
    grid-template-columns: 1fr 1fr;
  }
  .footer-bottom {
    flex-direction: row !important;
  }
}

/* lg: 1024px以上 */
@media (min-width: 1024px) {
  .grid-access {
    grid-template-columns: 1fr 1fr;
  }
  .grid-director {
    grid-template-columns: 2fr 3fr;
  }
  .director-card__media {
    justify-content: stretch;
  }
  .director-card .director-photo {
    margin-left: 0;
    margin-right: 0;
    width: 100%;
  }
  .grid-footer {
    grid-template-columns: 2fr 1fr 1fr;
  }
  .grid-skills {
    grid-template-columns: 1fr 1fr 1fr;
  }
  .director-photo-placeholder,
  .director-photo {
    max-width: none !important;
    aspect-ratio: 4/5 !important;
  }
}

/* ==========================================
   動画パネル：ホバー時テキスト非表示
   ========================================== */

/* バッジ・下部テキストにトランジションを付ける */
.movie-ui {
  transition: opacity 0.4s ease;
}

/* ホバー（拡大）時はテキストをフェードアウトして動画のみ表示 */
.block-hovered .movie-ui {
  opacity: 0;
}

/* ==========================================
   画像プレースホルダー
   （実際の画像が用意できたら差し替えてください）
   ========================================== */

/* 院長写真プレースホルダー */
.director-photo-placeholder {
  background: linear-gradient(135deg, hsl(148 30% 88%), hsl(152 40% 70%));
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: white;
}

/* 院長イラスト（カード内で馴染むマット） */
.director-photo {
  margin: 0 auto;
  aspect-ratio: 3 / 4;
  max-width: 320px;
  width: 100%;
  border-radius: 1rem;
  border: 1px solid hsl(145 25% 88% / 0.9);
  border-left: 3px solid hsl(152 40% 42% / 0.5);
  background: linear-gradient(
    165deg,
    hsl(148 34% 96%) 0%,
    hsl(152 26% 93%) 50%,
    hsl(148 30% 95%) 100%
  );
  box-shadow:
    0 10px 32px -14px hsla(152, 36%, 30%, 0.12),
    inset 0 1px 0 hsl(0 0% 100% / 0.5);
}

.director-photo img {
  position: absolute;
  top: 0.65rem;
  left: 50%;
  transform: translateX(-50%);
  max-width: calc(100% - 1.3rem);
  max-height: calc(100% - 1.3rem);
  width: auto;
  height: auto;
  object-fit: contain;
  object-position: top center;
}

/* 一般歯科ブロック背景
   差し替え先: images/illust-general.jpg */
.img-general {
  background: linear-gradient(135deg, hsl(152 35% 30%), hsl(152 40% 50%));
}

/* 小児矯正ブロック背景
   差し替え先: images/illust-kids.jpg */
.img-pediatric {
  background: linear-gradient(135deg, hsl(170 40% 30%), hsl(162 40% 52%));
}

/* 外観写真プレースホルダー
   差し替え先: images/clinic-exterior.jpg */
.img-exterior {
  background: linear-gradient(135deg, hsl(148 25% 75%), hsl(148 30% 88%));
}

/* メニューパネル（デフォルト非表示、開閉はJSで制御） */
.mobile-menu {
  display: block;
  pointer-events: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 200;
  background: hsla(0, 0%, 100%, 0.97);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 80px 1.25rem 2rem;
  overflow-y: auto;
  opacity: 0;
  transform: translateY(-10px);
  transition:
    opacity 0.3s ease,
    transform 0.3s ease;
}

.mobile-menu.is-open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.mobile-menu__nav {
  display: flex;
  flex-direction: column;
  max-width: 480px;
  margin: 0 auto;
}

.mobile-menu__link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 0.5rem;
  font-size: 0.95rem;
  font-weight: 500;
  color: hsl(150 10% 20%);
  border-bottom: 1px solid hsl(145 15% 90%);
  transition:
    color 0.2s,
    background 0.2s;
}

.mobile-menu__link:hover {
  background: hsl(148 30% 95%);
  color: hsl(152 40% 42%);
}

.mobile-menu__link:active {
  background: hsl(148 30% 92%);
}

.mobile-menu__tel {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid hsl(145 15% 88%);
  text-align: center;
}

.mobile-menu__tel-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 2rem;
  font-size: 1.1rem;
  font-weight: 600;
  color: white;
  background: hsl(152 40% 42%);
  border-radius: 9999px;
  box-shadow: 0 4px 14px -2px hsla(152, 40%, 42%, 0.3);
  transition:
    transform 0.2s,
    box-shadow 0.2s;
}

.mobile-menu__tel-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px -2px hsla(152, 40%, 42%, 0.35);
}

/* ==========================================
   スマホ対応（767px 以下）
   ========================================== */

@media (max-width: 767px) {
  /* ランディング：高さ auto でスクロール可能に */
  #landing {
    height: auto !important;
    min-height: 100dvh;
    overflow: visible;
  }

  /* パネルエリア：高さ固定を解除 */
  #panel-area {
    flex: none !important;
    padding: 8px !important;
    gap: 8px !important;
    overflow: visible;
  }

  /* ---- 上段：縦積みに変更 ---- */
  #top-row {
    flex-direction: column !important;
    flex: none !important;
    gap: 8px;
  }

  /* 動画パネル：最上部 */
  [data-block="movie"] {
    order: 1;
    flex: none !important;
    height: 56vw;
    min-height: 200px;
    /* 拡大ホバー効果を無効化 */
    border-radius: 1rem !important;
  }

  /* 一般歯科パネル：2番目 */
  [data-block="general"] {
    order: 2;
    flex: none !important;
    height: 40vw;
    min-height: 150px;
  }

  /* 小児矯正パネル：3番目 */
  [data-block="pediatric"] {
    order: 3;
    flex: none !important;
    height: 40vw;
    min-height: 150px;
  }

  /* ---- 動画パネルのテキスト：モバイルでは非表示（上に詰める） ---- */
  .movie-ui {
    display: none !important;
  }

  /* ---- ホバー系要素：モバイルでは非表示 ---- */
  .hover-desc {
    display: none !important;
  }

  .hover-arrow {
    display: none !important;
  }

  /* ホバーアニメーション無効 */
  .block-transition {
    transition: none !important;
  }

  /* ---- 下段：折り返しグリッドに変更 ---- */
  #bottom-row {
    display: flex !important;
    flex-wrap: nowrap !important;
    justify-content: space-between !important;
    flex: none !important;
    height: auto !important;
    gap: 6px;
    padding-bottom: 12px;
    overflow-x: hidden;
  }

  /* 下段各パネル：4枚を横一列 */
  #bottom-row > * {
    flex: 1 1 0 !important;
    height: 80px !important;
    min-height: 0 !important;
    min-width: 0 !important;
    border-radius: 0.75rem !important;
    padding: 10px 6px !important;
  }

  /* 下段アイコン：少し小さく */
  #bottom-row > * > .panel-icon {
    width: 28px !important;
    height: 28px !important;
    margin-bottom: 4px !important;
    border-radius: 8px !important;
  }

  #bottom-row > * > .panel-icon svg {
    width: 14px !important;
    height: 14px !important;
  }

  /* 下段ラベル文字サイズ */
  #bottom-row > * span[class*="font-semibold"] {
    font-size: 11px !important;
  }

  /* ヘッダー電話ボタン：モバイル共通デザイン */
  header a[href^="tel"].tel-link,
  .sub-header .tel-link {
    padding: 8px 14px 8px 12px !important;
    border-radius: 8px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    gap: 6px !important;
    font-size: 0 !important;
    width: auto !important;
    height: auto !important;
    background: hsl(152 40% 42%) !important;
    box-shadow: 0 2px 8px -2px hsla(152, 40%, 42%, 0.35) !important;
  }

  header a[href^="tel"].tel-link span,
  .sub-header .tel-link .tel-number {
    display: none !important;
  }

  header a[href^="tel"].tel-link svg,
  .sub-header .tel-link svg {
    width: 16px !important;
    height: 16px !important;
    flex-shrink: 0;
  }

  /* 「TEL」ラベル表示 */
  header a[href^="tel"].tel-link::after,
  .sub-header .tel-link::after {
    content: "TEL";
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: white;
    line-height: 1;
  }

  header a[href^="tel"].tel-link::before,
  .sub-header .tel-link::before {
    display: none !important;
  }
}

/* ==========================================
   ハンバーガー・メニュー（共通定義は上部参照）
   ========================================== */

/* ヘッダー右側にハンバーガー分の余白を確保（ハンバーガー幅 42px + ボタン間ギャップ 16px + 右端余白） */
header,
.sub-header {
  padding-right: calc(clamp(12px, 2vw, 32px) + 42px + 16px) !important;
}

/* ハンバーガーボタン：常時固定表示。ヘッダーの縦中央に揃える */
#hamburger-btn {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 42px;
  height: 42px;
  padding: 0;
  border: none;
  border-radius: 8px;
  background: hsla(0, 0%, 100%, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  cursor: pointer;
  z-index: 300;
  position: fixed;
  top: clamp(6px, 0.9vh, 12px);
  right: clamp(12px, 2vw, 32px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition:
    background 0.2s,
    box-shadow 0.2s;
}

#hamburger-btn:hover {
  background: hsl(148 30% 92%);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.12);
}

#hamburger-btn .hamburger__line {
  display: block;
  width: 22px;
  height: 2px;
  background: hsl(150 10% 25%);
  border-radius: 2px;
  transition:
    transform 0.3s ease,
    opacity 0.3s ease;
}

#hamburger-btn.is-open .hamburger__line:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

#hamburger-btn.is-open .hamburger__line:nth-child(2) {
  opacity: 0;
}

#hamburger-btn.is-open .hamburger__line:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ==========================================
   トップに戻る（右下固定）
   ========================================== */

.back-to-top {
  position: fixed;
  right: max(1rem, env(safe-area-inset-right, 0px));
  bottom: max(1rem, env(safe-area-inset-bottom, 0px));
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: hsl(152 40% 42%);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 4px 14px -2px hsla(152, 40%, 42%, 0.45);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    background 0.2s ease;
}

.back-to-top:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px -4px hsla(152, 40%, 42%, 0.4);
  background: hsl(152 40% 36%);
}

.back-to-top:focus-visible {
  outline: 2px solid hsl(152 40% 42%);
  outline-offset: 3px;
}

.back-to-top svg {
  width: 22px;
  height: 22px;
}
