/* ============================================================
   home-hub.css — A案 ホームのヒーロー内に対象者2入口を統合
   設置事業者(医療機関 / 自治体)向けの振り分けハブ
   ============================================================ */

/* hero shell: ブランドメッセージ(左) + 写真(右) */
.hub-hero { background: linear-gradient(var(--hero-1), var(--hero-2)); overflow: clip; position: relative; }
.hub-hero__grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(36px, 4.5vw, 64px);
  align-items: center; padding-block: clamp(40px, 6vw, 80px);
}
.hub-hero__intro .tag { margin-bottom: 16px; }
.hub-hero__title {
  font-family: var(--ff-display); font-weight: 700; color: var(--ink-2);
  font-size: clamp(27px, 3.7vw, 40px); line-height: 1.34; letter-spacing: .03em; margin: 0; text-wrap: balance;
}
.hub-hero__title .accent { color: var(--primary); }
.hub-hero__title .hl {
  background: linear-gradient(transparent 58%, var(--mark-hl) 58%); padding-inline: 3px;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.hub-hero__lead { color: var(--ink); margin: 18px 0 0; font-size: clamp(15px, 1.35vw, 16.5px); line-height: 1.85; max-width: none; white-space: nowrap; }

.hub-hero__media { position: relative; }
.hub-hero__media .blob {
  position: absolute; inset: -8% -10% -10% -4%; background: var(--primary-soft);
  border-radius: 46% 54% 58% 42% / 54% 44% 56% 46%; opacity: .8; z-index: 0;
  transform: rotate(-4deg);
}
/* 手描き風のアウトライン: 写真から少しずらして重ねる */
.hub-hero__media .blob-line {
  position: absolute; inset: 3% -3% -4% 4%; z-index: 2; pointer-events: none;
  border: 2px solid var(--primary);
  border-radius: 56% 44% 50% 50% / 44% 56% 46% 54%;
  opacity: .55;
}
.hub-hero__media .media-img, .hub-hero__media image-slot {
  position: relative; z-index: 1; display: block; width: 100%;
  height: clamp(340px, 41vw, 480px); box-shadow: var(--shadow-lg);
  border-radius: 58% 42% 54% 46% / 46% 54% 44% 56%;
}

/* 対象者の二択ハブ — 医療機関 / 自治体 を同等に */
.hub-routes-wrap { border-top: none; background: var(--hero-2); padding-top: clamp(44px, 5.5vw, 72px); padding-bottom: clamp(56px, 7vw, 88px); }
.hub-routes-lead {
  text-align: center; font-family: var(--ff-display); font-weight: 500; letter-spacing: .04em;
  color: var(--ink); font-size: clamp(18px, 2.1vw, 23px); margin: 0 0 10px;
}
.hub-routes-sub { text-align: center; color: var(--muted); font-size: 14px; margin: 0 0 clamp(32px,4vw,44px); }

.hub-routes { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(20px, 2.4vw, 28px); max-width: 980px; margin-inline: auto; align-items: stretch; }
.hub-routes > * { display: flex; }
.hub-routes > * > .hub-route { width: 100%; }
.hub-route {
  display: flex; flex-direction: column; position: relative; overflow: hidden;
  background: #fff; border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--shadow-md);
  transition: transform .22s var(--ease), box-shadow .22s, border-color .22s;
}
.hub-route:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: var(--primary-soft); }
.hub-route__top { height: 6px; background: var(--primary); }
.hub-route--muni .hub-route__top { background: var(--accent); }

/* card photo header — ビビッドな実写 */
.hub-route__photo { position: relative; display: block; height: clamp(150px, 17vw, 192px); overflow: hidden; }
.hub-route__photo .media-img, .hub-route__photo image-slot, .hub-route__photo img {
  display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 0;
}
.hub-route__photo-tint { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(13,40,28,0) 38%, rgba(13,40,28,.55) 100%); pointer-events: none; }
.hub-route--muni .hub-route__photo-tint { background: linear-gradient(180deg, rgba(60,42,8,0) 38%, rgba(60,42,8,.5) 100%); }
.hub-route__photo .hub-route__role {
  position: absolute; left: 14px; top: 14px; right: auto; bottom: auto; margin: 0; z-index: 2;
  color: #fff; background: var(--primary); padding: 5px 12px; border-radius: 9999px;
  font-family: var(--ff-display); font-weight: 700; font-size: 11px; letter-spacing: .06em;
  box-shadow: 0 4px 14px rgba(0,0,0,.18);
}
.hub-route--muni .hub-route__photo .hub-route__role { background: var(--accent-600); }
.hub-route__inner { position: relative; }
.hub-route__icon { margin-top: -52px; border: 4px solid #fff; position: relative; z-index: 2; background: #fff; box-shadow: var(--shadow-md); }
.hub-route__icon svg { width: 30px; height: 30px; }
.hub-route__inner { padding: clamp(26px, 2.6vw, 36px); display: flex; flex-direction: column; flex: 1; }
.hub-route__icon {
  width: 64px; height: 64px; border-radius: 9999px; display: grid; place-items: center;
  background: var(--primary-tint); color: var(--primary); margin-bottom: 20px;
}
.hub-route--muni .hub-route__icon { background: var(--accent-tint); color: var(--accent-600); }
.hub-route__icon svg { width: 32px; height: 32px; }
.hub-route h3 {
  font-family: var(--ff-display); font-weight: 700; font-size: clamp(20px, 2vw, 24px);
  color: var(--ink); margin: 0 0 6px; letter-spacing: .03em;
}
.hub-route__role { display: block; font-family: var(--ff-display); font-weight: 700; font-size: 12px; letter-spacing: .08em; color: var(--faint); margin: 0 0 14px; }
.hub-route p { color: var(--body); font-size: 14.5px; line-height: 1.85; margin: 0 0 22px; flex: 1; }
.hub-route__points { list-style: none; margin: 0 0 24px; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.hub-route__points li { color: var(--body); font-size: 13.5px; display: flex; align-items: flex-start; gap: 9px; }
.hub-route__points li::before { content: "✓"; color: var(--primary); font-weight: 700; flex: none; }
.hub-route--muni .hub-route__points li::before { color: var(--accent-600); }

@media (max-width: 860px) {
  .hub-hero__grid { grid-template-columns: 1fr; gap: 32px; }
  .hub-hero__lead { white-space: normal; }
  .hub-hero__media { order: -1; max-width: 520px; margin-inline: auto; }
  .hub-routes { grid-template-columns: 1fr; max-width: 480px; }
}

/* 共通の特長 strip */
.hub-feats { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(20px, 2.5vw, 32px); }
.hub-feat { text-align: center; }
.hub-feat__icon { width: 72px; height: 72px; border-radius: 9999px; background: #fff; box-shadow: var(--shadow-sm); display: grid; place-items: center; color: var(--primary); margin: 0 auto 16px; }
.hub-feat h3 { font-family: var(--ff-display); font-weight: 500; font-size: 18px; color: var(--ink); margin: 0 0 8px; letter-spacing: .03em; }
.hub-feat p { color: var(--body); font-size: 14px; line-height: 1.8; margin: 0; max-width: 30ch; margin-inline: auto; }
@media (max-width: 720px) { .hub-feats { grid-template-columns: 1fr; max-width: 420px; margin-inline: auto; gap: 28px; } }

/* ============================================================
   A案-2: 2入口をヒーロー左カラムに集約 — 写真と同時に1画面表示
   ============================================================ */
.hub2-hero__grid { grid-template-columns: 1.12fr .88fr; align-items: center; }
.hub2-hero__title { font-size: clamp(24px, 3.1vw, 35px); }
.hub2-hero__lead { margin-top: 14px; font-size: clamp(14px, 1.25vw, 15.5px); line-height: 1.8; max-width: 40ch; }

.hub2-routes { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: clamp(24px, 3vw, 32px); }
.hub2-route {
  display: flex; flex-direction: column; position: relative; overflow: hidden;
  background: #fff; border: 1px solid var(--line); border-radius: 18px;
  box-shadow: var(--shadow-sm); padding: 22px 22px 20px;
  transition: transform .2s var(--ease), box-shadow .2s, border-color .2s;
}
.hub2-route:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: var(--primary-soft); }
.hub2-route::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 5px; background: var(--primary); }
.hub2-route--muni::before { background: var(--accent); }
.hub2-route__icon { width: 48px; height: 48px; border-radius: 9999px; display: grid; place-items: center; background: var(--primary-tint); color: var(--primary); margin: 4px 0 14px; }
.hub2-route--muni .hub2-route__icon { background: var(--accent-tint); color: var(--accent-600); }
.hub2-route__icon svg { width: 26px; height: 26px; }
.hub2-route h3 { font-family: var(--ff-display); font-weight: 700; font-size: 18px; color: var(--ink); margin: 0 0 7px; letter-spacing: .03em; }
.hub2-route p { color: var(--body); font-size: 13px; line-height: 1.75; margin: 0 0 16px; flex: 1; }
.hub2-route .lnk { display: inline-flex; align-items: center; gap: 6px; font-family: var(--ff-display); font-weight: 700; font-size: 14px; color: var(--primary); letter-spacing: .03em; margin-top: auto; }
.hub2-route--muni .lnk { color: var(--accent-600); }
.hub2-route .lnk .arr { transition: transform .2s var(--ease); }
.hub2-route:hover .lnk .arr { transform: translateX(3px); }

@media (max-width: 860px) {
  .hub2-hero__grid { grid-template-columns: 1fr; }
  .hub2-routes { max-width: 520px; }
}
@media (max-width: 480px) {
  .hub2-routes { grid-template-columns: 1fr; }
}
