/* =========================================================
   Shinsei Clinic – Cleaned Stylesheet (sidebar 部分削除版)
   - Tokens
   - Base / Layout
   - Hero / KV
   - Sections / Headings
   - Grid / Cards / Tiles
   - Columns / Portrait
   - Department
   - Map / Info
   - Buttons
   - Footer (responsive)
   - PageTop (inline / fixed)
========================================================= */

/* ========== Tokens ========== */
:root {
  --brand: #0168b3;
  /* 基調ブルー */
  --ink: #333;
  --paper: #fff;
  --muted: #6f7b86;
  --tint: #fdeee6;
  /* セクション淡桃 */
  --card: #ffffff;
  --line: #e8edf3;
  --radius: 14px;
  --shadow: 0 8px 22px rgba(0, 0, 0, .06);
  --container: 1120px;

  /* KV 見出し */
  --kv-blue: #2b69a4;
  /* 青帯 */
  --kv-accent: #f0b19d;
  /* ピーチ */
  --kv-bar-h: 20px;
  /* 下線の太さ */
  --kv-stick-w: 12px;
  /* 右棒の幅 */
  --kv-stick-up: 100%;
  /* 右棒の上方向伸び */
}

/* ========== Base / Layout ========== */
* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: "Noto Sans JP", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  line-height: 1.8;
}

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

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 28px;
  /* 余白やや広め */
}

/* ========== Hero / KV ========== */
.hero {
  position: relative;
  min-height: 420px;
  display: flex;
  align-items: flex-end;
  background: url('/images/kv-about.png') center/cover no-repeat;
}

.hero__title {
  position: relative;
  z-index: 1;
  color: #fff;
  margin: 0;
  padding: 28px 0 32px;
  font-size: clamp(28px, 4.2vw, 44px);
  font-weight: 700;
  letter-spacing: .04em;
}

/* KV 見出し（横帯と縦棒がつながる） */
.kv {
  position: relative;
  display: inline-block;
  margin-bottom: 0;
  transform: translateY(-26px);
}

@media (min-width:768px) {
  .kv {
    transform: translateY(-34px);
  }
}

.kv__label {
  position: relative;
  z-index: 1;
  color: #fff;
  background: var(--kv-blue);
  font-weight: 800;
  letter-spacing: .02em;
  font-size: clamp(22px, 3.8vw, 34px);
  padding: 14px 22px;
}

/* 横帯（右棒の幅ぶん延長） */
.kv::after {
  content: "";
  position: absolute;
  left: 0;
  right: auto;
  width: calc(100% + var(--kv-stick-w));
  height: var(--kv-bar-h);
  bottom: calc(-1 * var(--kv-bar-h));
  background: var(--kv-accent);
}

/* 右の縦棒（横帯と連結） */
.kv::before {
  content: "";
  position: absolute;
  right: calc(-1 * var(--kv-stick-w));
  bottom: calc(-1 * var(--kv-bar-h));
  width: var(--kv-stick-w);
  height: calc(var(--kv-bar-h) + var(--kv-stick-up));
  background: var(--kv-accent);
}

/* ========== Sections / Headings ========== */
.section {
  padding-block: clamp(36px, 6vw, 72px);
}

.section--tint {
  background: var(--tint);
}

.block+.block {
  margin-top: 28px;
}

.lead {
  margin-top: 12px;
  color: #444;
}

/* 左バー＋全幅ライン＋短い青線の見出し */
.sec-head {
  position: relative;
  isolation: isolate;
  padding-left: 16px;
  margin-bottom: 32px;
  /* 広げすぎない適正値 */
}

.sec-head::before {
  content: "";
  position: absolute;
  left: 0;
  top: .15em;
  bottom: .15em;
  width: 6px;
  border-radius: 3px;
  background: var(--brand);
}

.sec-head::after {
  content: "";
  position: absolute;
  left: 16px;
  right: 0;
  bottom: -2px;
  height: 2px;
  background: #d7dee6;
  z-index: 0;
}

.sec-head__title {
  position: relative;
  display: inline-block;
  margin: 0;
  padding-bottom: 8px;
  font-weight: 800;
  font-size: clamp(22px, 3.4vw, 32px);
  color: var(--brand);
  z-index: 1;
}

.sec-head__title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 120px;
  height: 2px;
  background: var(--brand);
  z-index: 2;
}

/* 小見出し */
.hd {
  margin: 0 0 18px;
  font-size: clamp(22px, 3.4vw, 32px);
  font-weight: 700;
  color: var(--brand);
}

.hd--bar {
  position: relative;
  padding-left: 14px;
}

.hd--bar::before {
  content: "";
  position: absolute;
  left: 0;
  top: .2em;
  bottom: .2em;
  width: 6px;
  border-radius: 4px;
  background: var(--brand);
}

.subhd {
  margin: 18px 0 10px;
  font-weight: 700;
  font-size: clamp(18px, 2.6vw, 22px);
  color: #0f2b45;
}

/* ========== Grid / Cards / Tiles ========== */
.grid {
  display: grid;
  gap: clamp(14px, 2.4vw, 24px);
}

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

@media (min-width:768px) {
  .grid--3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(16px, 3vw, 24px);
}

.card--flat {
  box-shadow: none;
  border: 1px solid var(--line);
  background: #fff;
}

.list {
  margin: 0;
  padding-left: 1.2em;
}

.list li {
  margin: .35em 0;
}

/* Tiles（看護部理念） */
.tile {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 18px;
  text-align: left;
}

.tile__icon {
  width: 48px;
  height: 48px;
  margin-bottom: 12px;
}

.tile__icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.tile__title {
  margin: 0 0 4px;
  font-weight: 700;
}

.tile__text {
  margin: 0;
  color: #44525f;
}

/* ========== Columns / Portrait ========== */
.cols {
  display: grid;
  gap: 24px;
}

@media (min-width:960px) {
  .cols {
    grid-template-columns: 1fr 1.2fr;
  }
}

.portrait {
  aspect-ratio: 4/5;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: var(--shadow);
  background: #fafafa;
}

.portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.sign {
  text-align: right;
  margin-top: 18px;
}

/* ========== Department ========== */
.dept-highlight {
  display: grid;
  gap: 20px;
  margin-bottom: 22px;
}

@media (min-width:900px) {
  .dept-highlight {
    grid-template-columns: 1.2fr 1fr;
  }
}

.dept-highlight__thumb {
  aspect-ratio: 13/8;
  overflow: hidden;
  border-radius: 12px;
  background: #f6f7f9;
}

.dept-highlight__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dept-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
}

.dept-card__ph {
  aspect-ratio: 5/3;
  background: #f6f7f9;
}

.dept-card__ph img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dept-card__title {
  margin: 12px 16px 0;
  font-weight: 700;
}

.dept-card__text {
  margin: 6px 16px 16px;
  color: #44525f;
}

/* ========== Map / Info ========== */
.map {
  margin-bottom: 18px;
}

.map__ph {
  height: 420px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #f2f4f7;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #7a8794;
}

/* 地図 iframe（角丸・比率固定） */
.map-frame {
  width: 100%;
  aspect-ratio: 16/9;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  background: #eef3f7;
}

.map-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

/* 情報ブロック */
.info-cards {
  margin-top: 10px;
}

.info {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px 16px;
}

.info__icon {
  font-size: 20px;
  line-height: 1;
}

/* 下の3カード（ピル風） */
.contact-row {
  display: grid;
  gap: 16px;
  margin-top: 16px;
  grid-template-columns: 1fr;
}

@media (min-width:900px) {
  .contact-row {
    grid-template-columns: repeat(3, 1fr);
  }
}

.info-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 18px 22px;
}

.info-card__icon {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #e9f2fb;
  color: var(--brand);
  font-size: 16px;
  line-height: 1;
}

.info-card__text {
  line-height: 1.6;
}

/* ========== Affiliated (関連施設) – 安定レイアウト補強 ========== */
.aff {
  display: grid;
  grid-template-columns: 1fr;
  /* SP: 縦積み */
  gap: clamp(14px, 2.4vw, 24px);
  align-items: start;
  /* アイテム上揃えでズレ防止 */
  border-bottom: 1px solid var(--line);
  padding: 18px 0;
}

@media (min-width:900px) {
  .aff {
    grid-template-columns: 1.2fr 1fr;
    /* PC: 2カラム */
  }
}

/* Grid内のはみ出し防止（Safari含む） */
.aff__ph,
.aff__body {
  min-width: 0;
  /* ← 無いと長文で横崩れ */
}

/* サムネイルの比率固定とにじみ防止 */
.aff__ph {
  aspect-ratio: 16/10;
  /* 既存値を踏襲 */
  overflow: hidden;
  border-radius: 12px;
  background: #f6f7f9;
  display: block;
}

.aff__ph img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* はみ出し・歪み防止 */
  display: block;
}

/* 小要素の余白とタイポ微調整 */
.aff__org {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: .95em;
}

.aff__title {
  margin: 0 0 10px;
  font-size: clamp(18px, 3vw, 22px);
  line-height: 1.35;
}

.aff__text {
  margin: 0;
  color: #44525f;
  line-height: 1.8;
}

/* セクションの下線が二重にならないよう最終要素を消す */
.aff:last-of-type {
  border-bottom: 0;
}

/* ボタンの行頭が詰まらないよう軽く余白 */
.aff .btn--more {
  margin-top: 10px;
}

/* レイアウトの“ガタつき”対策：画像の読み込み中高さ保持 */
@supports not (aspect-ratio: 1) {
  .aff__ph {
    position: relative;
    padding-top: 62.5%;
  }

  /* 16:10 ≒ 62.5% */
  .aff__ph>img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
}

/* ========== Buttons ========== */
.btn {
  display: inline-block;
  padding: .55em 1.1em;
  border-radius: 999px;
  border: 1px solid #c7d6e6;
  color: #0f2b45;
  text-decoration: none;
  background: #fff;
  transition: .2s ease;
}

.btn:hover {
  background: #eef5fb;
}

/* 詳しく見る（立体感あり） */
.btn--more {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  border-radius: 10px;
  background: #2b69a4;
  color: #fff;
  font-weight: 700;
  letter-spacing: .02em;
  text-decoration: none;
  border: 1px solid #1f5c90;
  box-shadow: 0 3px 0 #174a76, 0 8px 18px rgba(43, 105, 164, .18);
  transition: background .2s ease, box-shadow .2s ease, transform .03s ease;
}

.btn--more::after {
  content: "›";
  font-size: 1.2em;
  line-height: 1;
  transform: translateY(1px);
}

.btn--more:hover {
  background: #235f9a;
  box-shadow: 0 3px 0 #174a76, 0 12px 24px rgba(43, 105, 164, .25);
}

.btn--more:focus-visible {
  outline: 3px solid #a7c8ff;
  outline-offset: 2px;
}

.btn--more:active {
  transform: translateY(2px);
  box-shadow: 0 1px 0 #174a76, 0 6px 14px rgba(43, 105, 164, .22);
}

/* ========== Footer (responsive) ========== */
.sitefooter {
  background: var(--brand);
  color: #fff;
  margin-top: clamp(36px, 6vw, 60px);
}

.sitefooter__inner {
  display: grid;
  gap: 18px;
  align-items: center;
  padding: 18px 0;
}

@media (min-width:900px) {
  .sitefooter__inner {
    grid-template-columns: 1.2fr 1fr auto;
  }
}

.sitefooter__brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.sitefooter__brand img {
  width: 72px;
  height: 72px;
  border-radius: 999px;
  background: #fff;
}

.sitefooter__name {
  font-weight: 700;
  font-size: 18px;
}

.sitefooter__addr {
  font-size: 14px;
  opacity: .9;
}

.sitefooter__meta {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 6px;
  font-size: 14px;
}

.recruit {
  display: inline-block;
  padding: .6em 1.1em;
  background: #ff7ea7;
  color: #fff;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 700;
}

/* ページ下帯 */
.pagetop {
  background: #0d5a98;
}

.pagetop a {
  display: block;
  text-align: center;
  color: #fff;
  text-decoration: none;
  padding: 10px 0;
  font-size: 12px;
  letter-spacing: .08em;
}

/* ---- 新デザイン Footer（Shinsei） ---- */
.sitefooter--shinsei {
  background: #fff;
  color: #2b2b2b;
  position: relative;
}

/* 3カラム（ロゴ / 情報 / CTA） */
.sitefooter--shinsei .footer__inner {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  column-gap: clamp(16px, 3vw, 40px);
  align-items: center;
  padding: clamp(20px, 4vw, 40px) 0;
  min-width: 0;
}

.footer__brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer__logo {
  width: clamp(96px, 10vw, 120px);
  height: auto;
}

.footer__info-row {
  display: grid;
  align-items: start;
  min-width: 0;
  grid-template-columns: 1.1fr 0.9fr;
  /* 左やや広め */
  gap: clamp(12px, 2.5vw, 28px);
}

.footer__info-left {
  display: grid;
  gap: 12px;
}

.footer__addr {
  font-size: clamp(14px, 1.8vw, 16px);
  line-height: 1.9;
  letter-spacing: .02em;
}

/* Footer – TEL と FAX を縦並びに */
.footer__telbox {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

.footer__tel {
  display: flex;
  align-items: center;
}

.footer__tel-ico {
  font-size: 22px;
  line-height: 1;
  transform: translateY(-1px);
}

.footer__tel-num {
  font-size: 32px;
  letter-spacing: .03em;
}

.footer__fax {
  font-size: clamp(14px, 1.8vw, 16px);
  color: #666;
}

.footer__info-right {
  display: grid;
  gap: 10px;
}

.footer__hours-hd {
  font-weight: 700;
  margin-bottom: 2px;
  color: #222;
  letter-spacing: .02em;
}

.footer__hourline {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 6px 0;
}

.footer__hourtime {
  font-size: clamp(14px, 1.8vw, 16px);
  letter-spacing: .01em;
  white-space: normal;
}

.chip {
  display: inline-block;
  min-width: clamp(68px, 10vw, 92px);
  padding: .45em .9em;
  border-radius: 12px;
  font-size: clamp(12px, 2.6vw, 16px);
  font-weight: 800;
  text-align: center;
  color: #fff;
}

.chip--weekday {
  background: #f6a8ae;
}

.chip--sat {
  background: #2d6bcf;
}

.footer__cta {
  display: flex;
  justify-content: flex-end;
}

.btn-recruit {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  padding: clamp(10px, 1.6vw, 16px) clamp(16px, 2.4vw, 28px);
  border-radius: 999px;
  background: linear-gradient(90deg, #f8a6b4 0%, #f7b7a3 100%);
  color: #fff;
  font-weight: 800;
  letter-spacing: .08em;
  box-shadow: 0 8px 18px rgba(0, 0, 0, .08);
  transition: transform .15s ease, box-shadow .15s ease;
}

.btn-recruit i {
  font-style: normal;
  font-weight: 800;
  transform: translateX(0);
}

.btn-recruit:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 22px rgba(0, 0, 0, .12);
}

.btn-recruit:hover i {
  transform: translateX(2px);
}

/* 下部ピーチ帯 */
.footer__bar {
  height: 34px;
  background: #f6b7ab;
  width: 100%;
}

/* Footer レスポンシブ */
@media (max-width:1080px) {
  .sitefooter--shinsei .footer__inner {
    grid-template-columns: auto minmax(0, 1fr);
    row-gap: 24px;
  }

  .footer__cta {
    justify-content: flex-start;
  }
}

@media (max-width:900px) {
  .footer__info-row {
    grid-template-columns: 1fr 1fr;
    gap: 18px;
  }
}

@media (max-width:720px) {
  .sitefooter--shinsei .footer__inner {
    grid-template-columns: 1fr;
    row-gap: 18px;
    text-align: left;
    padding-left: clamp(16px, 5vw, 32px);
    padding-right: clamp(16px, 5vw, 32px);
  }

  .footer__brand {
    justify-content: flex-start;
  }

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

  .footer__cta {
    justify-content: stretch;
  }

  .btn-recruit {
    width: 100%;
    justify-content: center;
  }
}

@media (max-width:480px) {
  .footer__logo {
    width: 84px;
  }

  .footer__bar {
    height: 28px;
  }
}

/* ========== PageTop（inline / fixed） ========== */
/* 右下寄せの控えめ表示（既存セクション用） */
.pagetop--right {
  background: transparent;
  position: relative;
}

.pagetop--right a {
  position: absolute;
  right: 18px;
  bottom: 10px;
  color: #7f7f7f;
  font-weight: 800;
  letter-spacing: .16em;
  text-decoration: none;
}

@media (max-width:1200px) {
  .sitefooter__inner {
    column-gap: 24px;
  }

  .pagetop--right a {
    right: 12px;
    bottom: 8px;
    font-size: 12px;
  }
}

/* 固定表示の PageTop ボタン */
.pagetop-fixed {
  position: fixed;
  right: 24px;
  bottom: 28px;
  z-index: 999;
}

.pagetop-fixed a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-decoration: none;
  color: #fff;
  background: linear-gradient(90deg, #f8a6b4, #f7b7a3);
  border-radius: 999px;
  box-shadow: 0 6px 16px rgba(0, 0, 0, .18);
  transition: transform .2s ease, box-shadow .2s ease, opacity .2s ease;
  opacity: .92;
}

.pagetop-fixed a::before {
  content: "▲";
  font-size: 11px;
  transform: translateY(-1px);
}

.pagetop-fixed a:hover {
  transform: translateY(-4px);
  opacity: 1;
  box-shadow: 0 10px 22px rgba(0, 0, 0, .26);
}

@media (max-width:600px) {
  .pagetop-fixed {
    right: 16px;
    bottom: 20px;
  }

  .pagetop-fixed a {
    padding: 10px 14px;
    font-size: 12px;
  }
}

/* =========================================================
   Spacing & Visibility Patch（sidebar関係は除去）
========================================================= */
/* ---- 基本の行間・可読性 ---- */
:root {
  --vr-gap: clamp(40px, 7vw, 88px);
  /* セクション上下余白（やや広めに） */
  --pad-inline: clamp(16px, 4vw, 32px);
  /* コンテナ左右パディング */
}

body {
  line-height: 1.9;
  /* 行間を少し広げて読みやすく */
  text-wrap: pretty;
  /* 不自然な改行を抑制 */
  hanging-punctuation: first;
  /* 句読点のぶら下げ（対応ブラウザのみ） */
}

.container {
  padding-inline: var(--pad-inline);
}

.section {
  padding-block: var(--vr-gap);
}

.sec-head {
  margin-bottom: clamp(16px, 3.5vw, 28px);
}

.sec-body p {
  margin: 0 0 1em;
}

/* 見出しの下線の間隔を適正化 */
.sec-head__title {
  padding-bottom: 10px;
}

.sec-head__title::after {
  bottom: -3px;
}

/* Grid / Cards / Tiles の余白微調整 */
.grid {
  gap: clamp(14px, 2.6vw, 26px);
}

.tile {
  padding: clamp(16px, 3.2vw, 22px);
}

.tile__text,
.dept-card__text {
  line-height: 1.9;
}

.cols {
  gap: clamp(16px, 3vw, 28px);
}

/* 画像のにじみ/段差防止 */
.portrait,
.dept-card__ph,
.dept-highlight__thumb,
.aff__ph {
  image-rendering: -webkit-optimize-contrast;
  backface-visibility: hidden;
}

/* KV ラベルのタッチ余白（SP時） */
.kv__label {
  padding: clamp(12px, 3.6vw, 16px) clamp(18px, 5.2vw, 24px);
}

/* マップ：上マージン & 角丸の視認性強化 */
.map-frame {
  margin-top: 8px;
  box-shadow: 0 1px 0 rgba(0, 0, 0, .06);
}

/* 情報カード行（ピル風） */
.contact-row {
  gap: clamp(12px, 2.4vw, 18px);
}

.info-card {
  padding: clamp(14px, 2.8vw, 20px) clamp(16px, 3.2vw, 24px);
}

.info-card__text {
  text-wrap: balance;
}

/* ボタンのアクセシビリティ（最小44px確保） */
.btn--more {
  min-height: 44px;
}

.btn--more:focus-visible {
  outline: 3px solid #a7c8ff;
  outline-offset: 3px;
}

/* フッター：文字間と折返し調整 */
.footer__info-row {
  gap: clamp(14px, 2.8vw, 28px);
}

.footer__tel-num {
  font-size: clamp(24px, 4vw, 32px);
  word-break: keep-all;
}

.footer__addr,
.footer__hourtime {
  text-wrap: balance;
}

/* ページトップ：タップしやすさを少し強化 */
.pagetop-fixed a {
  min-height: 44px;
}

/* 文字数が多い見出しの折返し最適化 */
.aff__title,
.dept-card__title,
.subhd {
  text-wrap: balance;
}

/* 長いURLや電話番号の折返し暴走防止 */
main,
footer {
  overflow-wrap: anywhere;
}

/* コントラスト環境（Windows HCM等）配慮 */
@media (forced-colors: active) {

  .btn--more,
  .btn-recruit {
    border: 1px solid CanvasText;
  }

  .sec-head::before {
    background: CanvasText;
  }
}

/* 動きが苦手なユーザー配慮 */
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    animation: none !important;
  }
}

/* きめ細かな SP 最適化 */
@media (max-width:720px) {
  .sec-head {
    padding-left: 14px;
  }

  .sec-head::before {
    width: 5px;
  }

  .footer__tel-num {
    font-size: clamp(22px, 6vw, 28px);
  }
}