/* 地図本体の描画を引き継ぎ、一覧と県カードにLPと同じあしらいを使う。 */
.area-index {
  --gray: #4A4A4A;
  --map-gray: color-mix(in srgb, var(--gray) 18%, var(--paper));
  --map-gray-active: color-mix(in srgb, var(--gray) 12%, var(--paper));
}
.area-index .page { width: min(100%, 1060px); }
.area-index .content { max-width: 810px; margin-inline: auto; }
.helmet-symbol { position: absolute; width: 0; height: 0; }
.masthead { padding: clamp(18px, 4vw, 44px) var(--gutter) 12px; text-align: center; }
.masthead p { margin-bottom: 4px; font-size: .875rem; font-weight: 900; }
.masthead h1 { font-size: clamp(2.25rem, 5.8vw, 4.25rem); letter-spacing: .025em; }
.masthead h1::after {
  content: ''; display: block; width: 40px; height: 4px; margin: 12px auto 0;
  border-radius: 2px; background: var(--yellow);
}
.posters { padding: clamp(12px, 2.5vw, 28px) var(--gutter) clamp(24px, 4vw, 44px); }
.poster { max-width: 580px; margin-inline: auto; overflow: hidden; border-radius: var(--radius); }
.poster img { width: 100%; background: var(--black); }
.maps {
  margin-inline: var(--gutter); padding: clamp(12px, 3.4vw, 36px);
  border-radius: var(--radius); background: var(--white);
}
.map-inner { max-width: 730px; margin-inline: auto; }
.legend {
  display: flex; flex-wrap: wrap; gap: 5px 15px; align-items: center;
  margin-bottom: 10px; font-size: .875rem; font-weight: 700;
}
.legend > span { display: inline-flex; align-items: center; gap: 5px; min-height: 26px; }
.legend .pin { width: 24px; height: 26px; }
.legend-gray { width: 14px; height: 14px; background: var(--map-gray); border: 1px solid var(--gray); }
.legend-coverage { font-weight: 900; }
.map-stage { position: relative; border: 1px solid var(--line); border-radius: 14px; }
.geo-stage { background: var(--paper); }
.geo-svg { display: block; width: 100%; height: auto; aspect-ratio: 1000 / 1046; }
.okinawa-frame rect { stroke: var(--black); }
.okinawa-frame text { fill: var(--black); font-size: 23px; font-weight: 900; }
.geo-svg[data-view="kyushu"] [data-island-part],
.geo-svg[data-view="islands"] [data-mainland-part] { display: none; }
.geo-svg .prefecture {
  fill: var(--map-gray); stroke: var(--white); stroke-width: 1.2px;
  stroke-linejoin: round; vector-effect: non-scaling-stroke;
  transition: fill .14s, filter .14s, transform .14s;
}
.geo-svg [data-has-cases="true"] .prefecture { fill: var(--yellow); stroke: var(--black); }
.geo-svg [data-pref] { cursor: pointer; outline: none; }
.geo-svg [data-has-cases="true"]:is(.is-highlighted, .is-selected, :focus-visible) .prefecture {
  fill: var(--light); filter: drop-shadow(1px 2px 2px rgb(17 17 17 / .38)); transform: translateY(-2px);
}
.geo-svg [data-has-cases="false"]:is(.is-highlighted, .is-selected, :focus-visible) .prefecture {
  fill: var(--map-gray-active); stroke: var(--yellow); stroke-width: 2px; stroke-dasharray: 3 2;
}
.geo-svg [data-has-cases][data-pref]:focus-visible .prefecture { stroke: var(--focus); stroke-width: 3px; }
.geo-pin { cursor: pointer; }
.geo-pin use { transform: scale(var(--pin-scale, .6)); }
.geo-labels text {
  fill: var(--black); stroke: var(--paper); stroke-width: .23em; stroke-linejoin: round;
  font-size: var(--label-size); font-weight: 900; text-anchor: middle; dominant-baseline: central;
  paint-order: stroke fill;
}
.geo-tip {
  position: absolute; z-index: 3; pointer-events: none; color: var(--black);
  width: max-content; max-width: calc(100% - 16px); padding: 6px 12px;
  background: var(--white); border: 1px solid var(--line); box-shadow: 0 4px 12px var(--shade);
  border-radius: 14px; font-size: .8125rem; font-weight: 900;
}
.geo-tip span { display: block; font-weight: 700; }
.map-help { margin: 12px 0 8px; font-size: .875rem; }
.region-buttons, .inset-buttons { display: flex; flex-wrap: wrap; gap: 8px; }
.region-buttons button, .inset-buttons button {
  min-height: 44px; padding: 5px 13px; border: 1px solid var(--line);
  border-radius: 999px; background: var(--white); font-size: .875rem; font-weight: 900;
}
:is(.region-buttons, .inset-buttons) button:hover { background: var(--yellow-wash); }
:is(.region-buttons, .inset-buttons) button[aria-pressed="true"] {
  background: var(--yellow); border-color: var(--yellow);
}
.inset-buttons { margin-top: 8px; }
.directory { margin-top: 26px; padding-top: 16px; border-top: 1px solid var(--line); }
.directory h3 { margin-bottom: 12px; font-size: 1.125rem; }
.directory-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 24px;
}
.directory h4 { margin-bottom: 6px; font-size: .9375rem; }
.directory ul {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 8rem), 1fr));
  gap: 6px; margin: 0; padding: 0; list-style: none;
}
.directory a {
  display: grid; align-content: center; min-height: 44px; padding: 5px 9px;
  border-radius: 14px; background: var(--paper); font-size: .875rem; font-weight: 700; text-decoration: none;
}
.directory a:hover { background: var(--yellow-wash); text-decoration: underline; }
.directory a span { font-size: .75rem; font-weight: 500; }
.directory a[data-track="none"] span { color: var(--gray); }

.pref-card {
  width: min(calc(100% - 48px), 776px); max-width: 100%;
  max-height: calc(100vh - 48px); max-height: calc(100dvh - 48px); padding: 0;
  border: 0; border-radius: 22px; background: var(--white); color: var(--text);
  box-shadow: 0 14px 32px var(--shade);
  overflow: hidden;
}
.pref-card::backdrop { background: rgba(17, 17, 17, .66); }
.pref-card[open] { display: flex; flex-direction: column; }
.pref-card:not([open]) { display: none; }
.card-head {
  flex: none;
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  padding: 10px clamp(16px, 3vw, 24px); background: var(--yellow);
}
.card-head h2 { min-width: 0; font-size: clamp(1.35rem, 3.5vw, 2rem); }
.card-head form { flex: none; margin: 0; }
.card-close {
  display: grid; place-items: center; width: 44px; height: 44px;
  border: 1px solid var(--line); border-radius: 50%; background: var(--white);
  font-size: 1.5rem; line-height: 1; font-weight: 900;
}
.card-close:hover { background: var(--yellow-wash); }
.card-body {
  min-height: 0; padding: 16px clamp(16px, 3vw, 24px) 24px;
  overflow: auto; overscroll-behavior: contain;
}
.card-status { font-size: 1.125rem; }
.assurance { margin: 12px 0 0; list-style: none; }
.card-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 18px; }
.card-link-secondary { background: var(--white); }
.card-link-secondary:hover { background: var(--paper); }

@media (max-width: 719px) {
  .directory-grid { grid-template-columns: minmax(0, 1fr); }
  .pref-card {
    inset: auto 0 0; width: 100%; max-height: 88vh; max-height: 88dvh;
    margin: 0; border-radius: 20px 20px 0 0;
  }
  .pref-card[open] { animation: sheet-in .18s ease-out both; }
  .card-head h2 { font-size: clamp(1.18rem, 5.2vw, 1.45rem); }
  .card-body { padding-bottom: calc(20px + env(safe-area-inset-bottom)); }
  @keyframes sheet-in { from { transform: translateY(100%); } to { transform: translateY(0); } }
}

@media (max-width: 359px) {
  .card-actions .pill { flex: 1 1 auto; }
}

@media (prefers-reduced-motion: reduce) {
  .geo-svg [data-has-cases="true"]:is(.is-highlighted, .is-selected, :focus-visible) .prefecture { transform: none; }
}
