/* ========================================
   Base Styles
   ======================================== */

:root {
  --container: min(100%, 1040px);
  --space-2: 1rem;
  --space-6: 3rem;
  --text: #333;
  --bg: #fff;
}

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

html {
  font-size: 62.5%;
  scroll-behavior: smooth;
}

body {
  font-family: 'Noto Sans JP', sans-serif;
  font-size: 1.6rem;
  line-height: 1.7;
  color: var(--text);
  background-color: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  /* text-align: justify; */
  /* word-break: break-word; */
  letter-spacing: 0.07em;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-size: inherit;
  font-weight: inherit;
  margin: 0;
}

a {
  color: inherit;
  text-decoration: none;
  transition: opacity .25s ease;
}

a:hover,
a:focus-visible {
  text-decoration: underline;
  opacity: 0.7;
}

ul,
ol {
  list-style: none;
}

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

button {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
}

.container {
  inline-size: var(--container);
  margin-inline: auto;
  padding-inline: var(--space-2);
}

section {
  padding-block: var(--space-6);
}


/* ========================================
   LP: Base Layout & Hero
   ======================================== */

.lp {
  color: var(--text);
  background: #fff;
  font-feature-settings: "palt";
}

/* ===== FV ===== */
.fv {
  position: relative;
  width: 100%;
  aspect-ratio: 2881 / 671;
  background: url("../images/fv-top-pc.webp") center/cover no-repeat;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  line-height: 1.4;
}

@media (max-width: 768px) {
  .fv {
    aspect-ratio: 750 / 336;
    background: url("../images/fv-top-sp.webp") center/cover no-repeat;
  }
}

.fv__inner {
  color: #222;
}

.fv__title {
  font-size: 4.2rem;
  font-weight: 700;
}

@media (max-width: 768px) {
  .fv__title {
    font-size: 3rem;
    font-weight: 700;
  }
}

.fv__eyebrow {
  font-size: 2.4rem;
}

@media (max-width: 768px) {
  .fv__eyebrow {
    font-size: 1.8rem;
  }
}


/* ========================================
   LP: Intro Section
   ======================================== */

.intro {
  background: #fff;
  padding-block: clamp(32px, 8vw, 88px);
}

.intro__lead {
  max-inline-size: 72ch;
  margin-inline: auto;
  line-height: 1.9;
  font-size: 1.8rem;
}

@media (max-width: 768px) {
  .intro__lead {
    line-height: 1.7;
    font-size: 1.6rem;
    padding: 1rem;
  }
}

.intro_heading {
  font-weight: bold;
  font-size: 2rem;
}

.intro__desc {
  font-size: 1.8rem;
  margin-block: 0 1rem;
}

.intro__list {
  list-style: decimal;
  margin-left: 1.6em;
  margin-block: 1.5rem;
}

.intro__list li {
  margin-bottom: 0.8em;
  line-height: 1.7;
}

@media (max-width: 768px) {
  .intro__list li {
    line-height: 1.6;
    margin-bottom: 0.3rem;
  }
}

.intro__list li::marker {
  font-weight: bold;
  font-size: 2rem;
}

.intro__note {
  display: block;
  font-size: 1.8rem;
  color: #666;
  line-height: 1.7;
}

@media (max-width: 768px) {
  .intro__note {
    display: block;
    font-size: 1.6rem;
    color: #666;
    line-height: 1.4;
  }
}


/* ========================================
   Region Navigation
   ======================================== */

#region-title {
  font-size: 2.8rem;
  font-weight: bold;
  text-align: center;
  margin-bottom: 3rem;
}

@media (max-width: 768px) {
  #region-title {
    font-size: 2.2rem;
    margin-bottom: 2rem;
  }
}

.region-nav {
  background: #fff;
  padding-block: clamp(12px, 2.5vw, 20px) clamp(24px, 5vw, 56px);
}

@media (max-width: 768px) {
  .region-nav {
    padding-block: 24px 50px;
  }
}

.region-nav__item {
  display: flex;
  flex-direction: column;
}

.region-nav__menu {
  min-inline-size: 100%;
  margin-top: 8px;
  padding: 1rem;
  background: #fff;
  border: 1px solid #ddd;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .08);
}

.region-nav__menu[hidden] {
  display: none;
}

.region-nav__menu-item {
  display: block;
  margin-bottom: 1rem;
  font-size: 1.8rem;
}

.region-nav__list {
  display: grid;
  grid-template-columns: repeat(4, 180px);
  justify-content: center;
  gap: 32px;
}

@media (max-width: 768px) {
  .region-nav__list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 30px 12px;
    max-width: 480px;
    margin: 1rem auto;
  }
}

.region-nav__btn {
  --bg: #4f8bcf;
  --shadow: 0 2px 0 color-mix(in oklab, var(--bg), #000 25%);
  inline-size: 100%;
  min-block-size: 48px;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: var(--bg);
  font-weight: 700;
  font-size: 2.2rem;
  padding-block: 0.9rem;
  line-height: 1;
  box-shadow: var(--shadow);
  cursor: pointer;
  user-select: none;
  transition: transform .12s ease,
    background-color .15s ease,
    box-shadow .15s ease,
    filter .15s ease;
  position: relative;
}

@media (max-width: 768px) {
  .region-nav__btn {
    font-size: 1.8rem;
    padding-block: 0.8rem;
  }
}

.region-nav__item--has-menu>.region-nav__btn::after {
  content: "";
  position: absolute;
  inset-inline-end: 20px;
  inset-block-start: 52%;
  transform: translateY(-52%) rotate(0deg);
  border-left: 0.7rem solid transparent;
  border-right: 0.7rem solid transparent;
  border-top: 1.2rem solid #fff;
  transition: transform .15s ease;
}

@media (max-width: 768px) {
  .region-nav__item--has-menu>.region-nav__btn::after {
    inset-inline-end: 18px;
  }
}

.region-nav__item--has-menu.is-open>.region-nav__btn::after {
  transform: translateY(-52%) rotate(180deg);
}

.region-nav__btn:is(:hover, :focus-visible):not(:active) {
  background: color-mix(in oklab, var(--bg) 92%, white 8%);
  filter: brightness(1.05);
}

.region-nav__btn:active {
  transform: translateY(2px);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, .16);
}

.region-nav__btn.is-active,
.region-nav__btn[aria-pressed="true"] {
  filter: saturate(1.05) brightness(.98);
}

/* Region button colors */
.region-nav__btn[data-region="hokkaido"] {
  --bg: #0071be;
}

.region-nav__btn[data-region="tohoku"] {
  --bg: #8770a7;
}

.region-nav__btn[data-region="koshin"] {
  --bg: #e84572;
}

.region-nav__btn[data-region="kanto"] {
  --bg: #ea5539;
}

.region-nav__btn[data-region="chubu"] {
  --bg: #e8b100;
}

.region-nav__btn[data-region="kinki"] {
  --bg: #34a068;
}

.region-nav__btn[data-region="chugoku"] {
  --bg: #2999a6;
}

.region-nav__btn[data-region="kyushu"] {
  --bg: #3e8fbf;
}


/* ========================================
   kanto sub menu
   ======================================== */

.region-nav__menu-item--has-sub>.region-nav__menu-btn {
  position: relative;
  padding-right: 1.8em;
}

.region-nav__menu-item--has-sub>.region-nav__menu-btn::after {
  content: "";
  position: absolute;
  right: 0.8em;
  top: 50%;
  transform: translateY(-50%) rotate(0deg);
  border-left: 0.4rem solid transparent;
  border-right: 0.4rem solid transparent;
  border-top: 0.7rem solid #333;
  transition: transform .15s ease;
}

.region-nav__menu-item--has-sub.is-open>.region-nav__menu-btn::after {
  transform: translateY(-50%) rotate(180deg);
}

.region-nav__submenu {
  margin-top: 5px;
  padding-left: 1rem;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.region-nav__submenu[hidden] {
  display: none;
}

.region-nav__submenu-item .region-nav__menu-btn {
  font-size: 1.6rem;
  padding-block: 0.4rem;
}


/* ========================================
   Category Content Area
   ======================================== */

.category-content {
  background: #f4f3f1;
  padding-top: 10rem;
  padding-bottom: 10rem;
  opacity: 1;
  transition: opacity 0.2s ease;
  /* height: 100%; */
}

@media (max-width: 768px) {
  .category-content {
    padding-top: 50px;
  }
}

.category-content.is-changing {
  opacity: 0;
}


/* ========================================
   Area Heading (地域見出し)
   ======================================== */

.area-head {
  color: #fff;
  font-weight: 700;
  text-align: center;
  padding: 12px;
  margin: 0 auto 32px;
  max-width: 1100px;
  width: 100%;
}

@media (max-width: 768px) {
  .area-head {
    max-width: 100%;
    width: 100%;
    margin: 0 auto 30px;
  }
}

.area-head__title {
  color: #fff;
  font-size: 2.4rem;
  letter-spacing: .05em;
}

@media (max-width: 768px) {
  .area-head__title {
    font-size: 2.4rem;
  }
}

.area-head--hokkaido {
  background: #2f73c7;
}

.area-head--tohoku {
  background: #745aa8;
}

.area-head--koshin {
  background: #da3b63;
}

.area-head--kanto {
  background: #e06b4f;
}

.area-head--chubu {
  background: #dea630;
}

.area-head--kinki {
  background: #34a068;
}

.area-head--chugoku {
  background: #2999a6;
}

.area-head--kyushu {
  background: #3e8fbf;
}


/* ========================================
   Clinic Card (Card + Table)
   ======================================== */

.clinic-card {
  background: #fff;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .08);
  padding: 24px;
  margin: 50px auto;
  max-width: 1100px;
  width: 100%;

  /* default color */
  --exam-accent: #2f73c7;
  --exam-border: #2a62a8;
  --exam-header-bg: #f3f5fb;
  --exam-pill-bg: #c9d2ea;
  --exam-pill-text: #1f355a;
}

@media (max-width: 768px) {
  .clinic-card {
    background: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, .08);
    padding: 20px;
    margin: 0 auto 50px;
  }
}

.clinic-card:last-of-type {
  margin-bottom: 0;
}

.clinic-card__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-left: 5px;
  margin-bottom: 5px;
  gap: 16px;
}

.clinic-card__name {
  font-size: 2.4rem;
  font-weight: 700;
  color: #111;
  line-height: 1.7;
  min-width: 0;
  flex: 1;
}

@media (max-width: 768px) {
  .clinic-card__name {
    font-size: 1.9rem;
    line-height: 1.4;
  }
}

.clinic-card__name a {
  text-decoration: none;
  border-bottom: 2px solid currentColor;
  padding-bottom: 2px;
  transition: opacity .3s ease;
}

.clinic-card__name a:hover {
  opacity: 0.65;
}

.clinic-card__titleWrap {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

/* 共通バッジ */
.clinic-card__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.2em 0.6em;
  border-radius: 5px;
  font-size: 1.6rem;
  font-weight: 700;
  color: #fff;
}

/* 新規 */
.clinic-card__badge--new {
  background: #e24f7c;
}

/* 移転 */
.clinic-card__badge--move {
  background: #1f6ad5;
}

.clinic-card__chip {
  inline-size: 80px;
  block-size: 80px;
  background: var(--exam-accent);
  color: #fff;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
  letter-spacing: .06em;
  flex-shrink: 0;
}

@media (max-width: 768px) {
  .clinic-card__chip {
    inline-size: 60px;
    block-size: 60px;
    font-size: 1.4rem;
  }
}

.clinic-card__info {
  display: grid;
  row-gap: 0.45rem;
  margin-bottom: 16px;
  padding-left: 5px;
}

.clinic-card__info-item {
  display: flex;
  align-items: baseline;
  font-size: 1.6rem;
  column-gap: 1rem;
  white-space: nowrap;
}

@media (max-width: 768px) {
  .clinic-card__info-item {
    font-size: 1.5rem;
  }
}

.clinic-card__info-label {
  flex: 0 0 auto;
  font-weight: 700;
  color: #333;
  margin-right: .25rem;
}

.clinic-card__info-value {
  flex: 1 1 auto;
  font-weight: 700;
  color: #555;
  min-width: 0;
  white-space: nowrap;
  word-break: normal;
  text-overflow: ellipsis;
  overflow: hidden;
}


/* ===== Table ===== */
@media (max-width: 768px) {
  .exam-wrap {
    position: relative;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}

@media (max-width: 768px) {
  .scroll-hint {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);

    min-width: 70%;
    max-width: 320px;
    padding: 25px;
    border-radius: 15px;

    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    font-size: 1.5rem;
    text-align: center;

    display: flex;
    flex-direction: column-reverse;
    align-items: center;
    gap: 8px;

    pointer-events: none;
    opacity: 0;
    transition: opacity 0.35s ease;
    z-index: 10;
  }

  .scroll-hint::before {
    content: "⇆";
    font-size: 2.8rem;
    line-height: 1;
    margin-bottom: 4px;
  }

  .exam-wrap.is-scrollable .scroll-hint {
    opacity: 1;
  }

  .exam-wrap.is-scrolled .scroll-hint {
    opacity: 0;
  }
}

/* Chrome / Safari / iOS */
.exam-wrap::-webkit-scrollbar {
  height: 5px;
}

.exam-wrap::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 4px;
}

.exam-wrap::-webkit-scrollbar-track {
  background: transparent;
}

.exam {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
  text-align: center;
  line-height: 1.4;
  font-size: 14px;
}

@media (max-width: 768px) {
  .exam {
    min-width: 1100px;
  }
}

.exam th,
.exam td {
  font-weight: 700;
}

/* ○だけを太く見せる（ダッシュや数字には効かない） */
.exam td[data-bind-mark].is-circle-mark {
  text-shadow:
    0.05em 0 0 currentColor,
    -0.05em 0 0 currentColor,
    0 0.05em 0 currentColor,
    0 -0.05em 0 currentColor;
}

.exam [data-i18n],
.exam [data-i18n-html],
.exam [data-bind],
.exam [data-bind-mark] {
  font-weight: 700 !important;
}

.exam th,
.exam td {
  border: 3px solid var(--exam-border);
  padding: 0.8rem;
  white-space: nowrap;
  height: 60px;
  vertical-align: middle;
}

.exam .exam__hd {
  background: var(--exam-header-bg);
  font-weight: 700;
}

.exam .pill {
  background: var(--exam-pill-bg);
  color: var(--exam-pill-text);
  font-weight: 700;
}

.pill__link {
  display: block;
  width: 100%;
  border: none;
  background: transparent;
  font: inherit;
  color: #0071be;
}

.pill__link span {
  font-size: 1.3rem;
  line-height: 1;
  border-bottom: 1px solid currentColor;
  padding-bottom: 0.2rem;
}

.exam .val {
  background: #fff;
  font-weight: 700;
}

.exam [data-bind-mark] {
  font-weight: 700;
}

.exam [data-i18n],
.exam [data-i18n-html],
.exam [data-bind] {
  font-weight: 700;
}

td.val.val--wrap {
  text-align: left;
  padding-left: 2.8rem;
}

.t-center {
  text-align: center;
}

.val--wrap {
  white-space: normal;
}

/* ===== Notes ===== */
.clinic-card__note {
  color: #333;
  font-size: 1.7rem;
  padding: 2rem 1rem 0;
}

@media (max-width: 768px) {
  .clinic-card__note {
    font-size: 1.6rem;
    padding: 2rem 0 0;
  }
}

.clinic-card__note-title {
  font-weight: 700;
  margin-bottom: .35rem;
  color: #222;
}


/* ========================================
   Region-based Table Color Variations
   ======================================== */

.clinic-card[data-region="hokkaido"] {
  --exam-accent: #2f73c7;
  --exam-border: #2a62a8;
  --exam-header-bg: #f3f5fb;
  --exam-pill-bg: #c9d2ea;
  --exam-pill-text: #1f355a;
}

.clinic-card[data-region="tohoku"] {
  --exam-accent: #745aa8;
  --exam-border: #5b4586;
  --exam-header-bg: #f4f1fb;
  --exam-pill-bg: #d7cdea;
  --exam-pill-text: #3f315e;
}

.clinic-card[data-region="koshin"] {
  --exam-accent: #da3b63;
  --exam-border: #b02c4c;
  --exam-header-bg: #fdf2f5;
  --exam-pill-bg: #f7c7d5;
  --exam-pill-text: #731b32;
}

.clinic-card[data-region="kanto"] {
  --exam-accent: #e06b4f;
  --exam-border: #b34c35;
  --exam-header-bg: #fdf3f0;
  --exam-pill-bg: #f7ccb9;
  --exam-pill-text: #772d1f;
}

.clinic-card[data-region="chubu"] {
  --exam-accent: #dea630;
  --exam-border: #b38221;
  --exam-header-bg: #fdf7ea;
  --exam-pill-bg: #f7e0af;
  --exam-pill-text: #7b5614;
}

.clinic-card[data-region="kinki"] {
  --exam-accent: #34a068;
  --exam-border: #27764f;
  --exam-header-bg: #e9f7f0;
  --exam-pill-bg: #bbe3cd;
  --exam-pill-text: #175234;
}

.clinic-card[data-region="chugoku"] {
  --exam-accent: #2999a6;
  --exam-border: #1f717b;
  --exam-header-bg: #e9f6f8;
  --exam-pill-bg: #badee2;
  --exam-pill-text: #154c52;
}

.clinic-card[data-region="kyushu"] {
  --exam-accent: #3e8fbf;
  --exam-border: #2f6f93;
  --exam-header-bg: #ecf5fb;
  --exam-pill-bg: #bfd8ee;
  --exam-pill-text: #214862;
}

/* ========================================
   Modal (Pop Up)
   ======================================== */

.sedation-modal[hidden] {
  display: none;
}

.sedation-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;

  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.sedation-modal.is-open {
  opacity: 1;
  pointer-events: auto;
}

.sedation-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .6);
}

.sedation-modal__content {
  position: relative;
  z-index: 1;
  max-width: 640px;
  width: calc(100% - 32px);
  max-height: 80vh;
  overflow-y: auto;
  background: #fff;
  border-radius: 8px;
  padding: 2.4rem 2rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .18);

  transform: scale(0.95);
  opacity: 0;
  transition: transform .3s ease, opacity .3s ease;
}

.sedation-modal.is-open .sedation-modal__content {
  transform: scale(1);
  opacity: 1;
}

.sedation-modal__close {
  position: absolute;
  border: none;
  background: transparent;
  font-size: 2.4rem;
  line-height: 1;
  cursor: pointer;
  color: #666;
  transition: opacity .3s ease;
}

.sedation-modal__close:hover {
  color: #000;
  font-weight: bold;
}

.sedation-help__title {
  font-size: 2rem;
}


/* ========================================
   page top 戻る ボタン
   ======================================== */
.pageTop-btn {
  position: fixed;
  right: 16px;
  bottom: 28px;
  width: 52px;
  height: 52px;
  background: #fff;
  border-radius: 50%;
  border: 1.5px solid #ccc;
  cursor: pointer;
  z-index: 1000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, .15);
  opacity: 0;
  transform: translateY(70px);
  transition: opacity .3s ease, transform .3s ease;
}

.pageTop-btn::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;

  width: 11px;
  height: 11px;
  border-top: 2px solid #333;
  border-right: 2px solid #333;

  transform: translate(-50%, -50%) rotate(-45deg);
}

.pageTop-btn.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (hover: hover) {
  .pageTop-btn:hover {
    box-shadow: 0 6px 18px rgba(0, 0, 0, .22);
    transform: translateY(-3px);
  }
}

@media (max-width: 375px) {
  .pageTop-btn {
    width: 44px;
    height: 44px;
    right: 10px;
    bottom: 20px;
  }

  .pageTop-btn::before {
    width: 9px;
    height: 9px;
  }
}

@media (max-width: 340px) {
  .pageTop-btn {
    width: 38px;
    height: 38px;
    right: 8px;
    bottom: 16px;
  }

  .pageTop-btn::before {
    width: 8px;
    height: 8px;
  }
}