/* hidden 属性は display 指定より必ず優先させる（flex/grid 要素の非表示不具合を防止） */
[hidden] {
  display: none !important;
}

/* スクリーンリーダー/クローラ専用（視覚的には非表示だが DOM/アクセシビリティには存在）。
   個別アトラクションページの SSR ユニーク本文に使用し、可視 UI は一切変えない。 */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

:root {
  --bg: #f4f5fa;
  --bg-elev: #ffffff;
  --surface: #ffffff;
  --surface-2: #f0f1f7;
  --text: #12131a;
  --text-sub: #6b6f80;
  --border: rgba(18, 19, 26, 0.08);
  --shadow: 0 6px 20px rgba(18, 19, 26, 0.08);
  --accent: #4a4de7;
  --accent-ink: #ffffff;

  /* 混雑度カラー */
  --c-empty: #16a34a;
  --c-low: #65a30d;
  --c-mid: #d97706;
  --c-high: #ea580c;
  --c-full: #dc2626;
  --c-off: #94a3b8;
  --c-paused: #db2777; /* 休止中: ピンク */
  --c-sat: #2563eb; /* 土曜 */
  --c-sun: #dc2626; /* 日曜・祝日 */
  --c-dpa: #7c5cbf;
  --c-pp: #1f7a70;

  --header-h: env(safe-area-inset-top, 0px);
  --radius: 18px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b1020;
    --bg-elev: #12172a;
    --surface: #161c33;
    --surface-2: #1e2540;
    --text: #eef1fb;
    --text-sub: #9aa2bd;
    --border: rgba(255, 255, 255, 0.08);
    --shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
    --accent: #7c7fff;
    --accent-ink: #0b1020;
    --c-empty: #22c55e;
    --c-low: #84cc16;
    --c-mid: #f59e0b;
    --c-high: #fb923c;
    --c-full: #f87171;
    --c-off: #64748b;
    --c-sat: #60a5fa;
    --c-sun: #f87171;
    --c-dpa: #b39ddb;
    --c-pp: #4ecdc4;
  }
}

/* ユーザーが明示的に選択したテーマ（システム設定より優先） */
:root[data-theme="dark"] {
  --bg: #0b1020;
  --bg-elev: #12172a;
  --surface: #161c33;
  --surface-2: #1e2540;
  --text: #eef1fb;
  --text-sub: #9aa2bd;
  --border: rgba(255, 255, 255, 0.08);
  --shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  --accent: #7c7fff;
  --accent-ink: #0b1020;
  --c-empty: #22c55e;
  --c-low: #84cc16;
  --c-mid: #f59e0b;
  --c-high: #fb923c;
  --c-full: #f87171;
  --c-off: #64748b;
  --c-paused: #db2777;
  --c-sat: #60a5fa;
  --c-sun: #f87171;
  --c-dpa: #b39ddb;
  --c-pp: #4ecdc4;
}

/* ライトモード: 屋外・直射日光下でも視認しやすい高コントラストなテーマ */
:root[data-theme="light"] {
  --bg: #ffffff;
  --bg-elev: #ffffff;
  --surface: #ffffff;
  --surface-2: #e9ecf5;
  --text: #000000;
  --text-sub: #3a4051;
  --border: rgba(0, 0, 0, 0.22);
  --shadow: 0 4px 14px rgba(0, 0, 0, 0.18);
  --accent: #1d4ed8;
  --accent-ink: #ffffff;
  --c-empty: #15803d;
  --c-low: #4d7c0f;
  --c-mid: #b45309;
  --c-high: #c2410c;
  --c-full: #b91c1c;
  --c-off: #475569;
  --c-paused: #be185d;
  --c-sat: #1d4ed8;
  --c-sun: #b91c1c;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html {
  height: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans",
    "Noto Sans JP", "Segoe UI", Roboto, sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: contain;
}

.app {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  max-width: 640px;
  margin: 0 auto;
}

/* ---------- Header ---------- */
.header {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: calc(env(safe-area-inset-top, 0px) + 12px)
    max(16px, env(safe-area-inset-left)) 12px
    max(16px, env(safe-area-inset-right));
  background: color-mix(in srgb, var(--bg-elev) 82%, transparent);
  backdrop-filter: saturate(180%) blur(16px);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  border-bottom: 1px solid var(--border);
}

.header__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.header__title {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.header__logo {
  font-size: 26px;
  line-height: 1;
}

.header__titletext {
  min-width: 0;
}

.header__title h1 {
  margin: 0;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.header__subtitle {
  margin: 2px 0 0;
  font-size: 11px;
  color: var(--text-sub);
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
}

.updated {
  margin: 0;
  font-size: 12px;
  color: var(--text-sub);
  font-variant-numeric: tabular-nums;
}

/* ---------- 営業時間バー（ヘッダー下部） ---------- */
.parkhours-bar {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: calc(100% - 32px);
  margin: 12px 16px 12px;
  padding: 10px 16px;
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
  border-radius: 12px;
  font-family: inherit;
  font-size: 14px;
  color: inherit;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.15s ease, transform 0.12s ease;
}

.parkhours-bar__row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
}

.parkhours-bar__hint {
  color: var(--text-sub);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: 0.01em;
}

.parkhours-bar:hover {
  background: color-mix(in srgb, var(--accent) 18%, transparent);
}

.parkhours-bar:active {
  transform: scale(0.985);
}

.parkhours-bar__icon {
  font-size: 16px;
  flex-shrink: 0;
}

.parkhours-bar__label {
  color: var(--text-sub);
  font-size: 12px;
  flex-shrink: 0;
}

.parkhours-bar__time {
  font-size: 17px;
  font-weight: 800;
  letter-spacing: 0.03em;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* ヒント（営業時間行の下に置き、時間が折り返されないようにする） */
.parkhours-bar__meta {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px 8px;
  max-width: 100%;
}

.parkhours-bar__more {
  flex: none;
  margin-left: 2px;
  color: var(--accent);
  font-size: 18px;
  font-weight: 700;
  line-height: 1;
}

/* ---------- 営業時間オーバーレイ ---------- */
html.is-hours-overlay,
html.is-hours-overlay body {
  overflow: hidden;
}

.hours-overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.hours-overlay__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 12, 24, 0.52);
  border: 0;
  padding: 0;
  cursor: pointer;
}

.hours-overlay__sheet {
  position: relative;
  z-index: 1;
  width: min(100%, 520px);
  max-height: min(88vh, 720px);
  overflow: auto;
  background: var(--surface);
  color: var(--text);
  border-radius: 20px 20px 0 0;
  box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.28);
  padding: 18px 18px calc(env(safe-area-inset-bottom, 0px) + 20px);
  animation: hours-sheet-up 0.22s ease both;
}

@keyframes hours-sheet-up {
  from {
    transform: translateY(18px);
    opacity: 0.6;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@media (min-width: 640px) {
  .hours-overlay {
    align-items: center;
    padding: 24px;
  }

  .hours-overlay__sheet {
    border-radius: 20px;
    max-height: min(84vh, 720px);
  }
}

.hours-overlay__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
  padding-top: 6px;
}

.hours-overlay__title {
  margin: 0;
  padding-top: 8px;
  font-size: 18px;
  font-weight: 800;
  line-height: 1.3;
}

.hours-overlay__close {
  flex: none;
  width: 44px;
  height: 44px;
  margin-top: 10px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--surface-2);
  color: var(--text);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
}

.hours-overlay__note {
  margin: 0 0 14px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.45;
  color: var(--text-sub);
}

.excl-cal {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 12px;
  margin-bottom: 14px;
  touch-action: pan-y;
  user-select: none;
}

.excl-cal__nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}

/* 月送りスライド（ビュー切替と同じ） */
.excl-cal__viewport {
  position: relative;
  overflow: hidden;
}

.excl-cal__viewport.is-swiping .excl-cal__panel {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  will-change: transform;
}

.excl-cal__month {
  margin: 0;
  font-size: 15px;
  font-weight: 800;
}

.excl-cal__navbtn {
  width: 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.excl-cal__weekdays,
.excl-cal__grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}

.excl-cal__weekdays {
  margin-bottom: 4px;
}

.excl-cal__wd {
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-sub);
  padding: 4px 0;
}

.excl-cal__wd.is-sun {
  color: var(--c-sun);
}

.excl-cal__wd.is-sat {
  color: var(--c-sat);
}

.excl-cal__day {
  position: relative;
  min-height: 58px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  border-radius: 10px;
  padding: 11px 1px 3px;
  color: var(--text);
  background: color-mix(in srgb, var(--surface) 70%, transparent);
  overflow: hidden;
  min-width: 0;
}

.excl-cal__num {
  font-size: 13px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}

.excl-cal__hrs {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  width: 100%;
  max-width: 100%;
  font-size: 8.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--text-sub);
  text-align: center;
}

.excl-cal__hrs > span {
  display: block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: clip;
  white-space: nowrap;
}

.excl-cal__hrs--empty {
  opacity: 0.35;
}

.excl-cal__day.is-sat .excl-cal__num {
  color: var(--c-sat);
}

.excl-cal__day.is-sun .excl-cal__num,
.excl-cal__day.is-holiday .excl-cal__num {
  color: var(--c-sun);
}

.excl-cal__day.is-out {
  opacity: 0.42;
  background: transparent;
}

.excl-cal__day.is-out .excl-cal__num {
  font-weight: 600;
}

.excl-cal__day.is-today {
  box-shadow: inset 0 0 0 2px var(--accent);
  background: color-mix(in srgb, var(--accent) 10%, var(--surface));
}

@media (min-width: 400px) {
  .excl-cal__day {
    min-height: 64px;
  }

  .excl-cal__hrs {
    font-size: 9.5px;
  }
}

.month-crowd {
  margin-top: 12px;
  padding: 12px 12px 10px;
  border-radius: 12px;
  background: var(--surface-2);
  border: 1px solid var(--border);
}

.month-crowd__title {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 800;
}

.month-crowd__body {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.7;
  color: var(--text);
}

.month-crowd__note {
  margin: 10px 0 0;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.55;
  color: var(--text-sub);
}

/* ---------- 全体の混雑傾向 ---------- */
.overview {
  display: block;
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 5px solid var(--ov, var(--c-mid));
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 12px;
  overflow: hidden;
}

.overview__head {
  appearance: none;
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  margin: 0;
  padding: 14px 16px;
  border: none;
  background: color-mix(in srgb, var(--ov, var(--c-mid)) 14%, var(--surface));
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.overview__head:active {
  background: color-mix(in srgb, var(--ov, var(--c-mid)) 22%, var(--surface));
}

.overview.is-open .overview__head {
  padding-bottom: 10px;
}

.overview__dot {
  flex: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--ov, var(--c-mid));
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--ov, var(--c-mid)) 28%, transparent);
}

.overview__body {
  flex: 1;
  min-width: 0;
}

.overview__level {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 6px;
  color: var(--ov, var(--c-mid));
  line-height: 1.25;
}

.overview__level-lead {
  font-size: 17px;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.overview__level-val {
  font-size: 23px;
  font-weight: 900;
  letter-spacing: 0.02em;
}

.overview__chevron {
  flex: none;
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--text-sub);
  border-bottom: 2px solid var(--text-sub);
  transform: rotate(45deg);
  transition: transform 0.2s ease;
  opacity: 0.75;
  margin-top: -4px;
}

.overview.is-open .overview__chevron {
  transform: rotate(225deg);
  margin-top: 4px;
}

.overview__content {
  padding: 0 16px 12px;
}

.overview__charts {
  width: 100%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.overview__chart {
  min-width: 0;
  width: 100%;
}

.overview__mlabel {
  font-size: 10px;
  font-weight: 700;
  color: var(--text-sub);
  margin-bottom: 4px;
  text-align: center;
}

/* ---------- ツールバー（更新時刻＋説明＋ソート） ---------- */
.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 0 2px 10px;
}

.toolbar__left {
  min-width: 0;
}

.note {
  margin: 2px 0 0;
  font-size: 10px;
  color: var(--text-sub);
  line-height: 1.35;
}

.sort {
  display: inline-flex;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 2px;
  flex: none;
}

.sortbtn {
  border: none;
  background: transparent;
  color: var(--text-sub);
  font-size: 12px;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.sortbtn.is-active {
  background: var(--accent);
  color: var(--accent-ink);
}

.iconbtn {
  flex: none;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease;
}

.iconbtn:active {
  transform: scale(0.92);
  background: var(--surface-2);
}

.iconbtn.is-loading svg {
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ---------- パーク切替（TDL / TDS） ---------- */
.parkbar {
  margin-top: 12px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 4px;
}

.parkbtn {
  appearance: none;
  border: none;
  background: transparent;
  color: var(--text-sub);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: -0.03em;
  padding: 8px 6px;
  border-radius: 11px;
  cursor: pointer;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.parkbtn__mark {
  font-size: 16px;
  line-height: 1;
  flex: none;
}

.parkbtn__copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1px;
  min-width: 0;
  text-align: left;
}

.parkbtn__label {
  font-size: 11px;
  font-weight: 800;
  line-height: 1.25;
  white-space: normal;
  max-width: 100%;
}

.parkbtn__code {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: color-mix(in srgb, var(--text-sub) 80%, transparent);
  line-height: 1.1;
}

.parkbtn.is-active .parkbtn__code {
  color: color-mix(in srgb, var(--text) 72%, transparent);
}

.parkbtn.is-active {
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
}

.card__pass {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 4px;
  max-width: 148px;
}

.card__pass-badge {
  display: inline-flex;
  align-items: center;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.02em;
  padding: 2px 7px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--c-dpa) 18%, transparent);
  color: var(--c-dpa);
  border: 1px solid color-mix(in srgb, var(--c-dpa) 40%, transparent);
}

.card__pass-badge--dpa {
  background: color-mix(in srgb, var(--c-dpa) 18%, transparent);
  color: var(--c-dpa);
  border-color: color-mix(in srgb, var(--c-dpa) 40%, transparent);
}

.card__pass-badge--pp {
  background: color-mix(in srgb, var(--c-pp) 18%, transparent);
  color: var(--c-pp);
  border-color: color-mix(in srgb, var(--c-pp) 40%, transparent);
}

.card__pass-badge.is-sale {
  background: var(--c-empty);
  color: #fff;
  border-color: transparent;
}

.card__pass-badge.is-soldout {
  background: color-mix(in srgb, var(--text-sub) 18%, var(--surface));
  color: var(--text-sub);
  border-color: color-mix(in srgb, var(--text-sub) 35%, transparent);
}

.pass-board {
  margin: 0 0 12px;
  padding: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
}

.pass-board__head {
  appearance: none;
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  margin: 0;
  padding: 12px 14px;
  border: none;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.pass-board__head:active {
  background: var(--surface-2);
}

.pass-board.is-open .pass-board__head {
  padding-bottom: 8px;
}

.pass-board__title {
  margin: 0;
  flex: 1;
  min-width: 0;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.pass-board__chevron {
  flex: none;
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--text-sub);
  border-bottom: 2px solid var(--text-sub);
  transform: rotate(45deg);
  transition: transform 0.2s ease;
  opacity: 0.75;
  margin-top: -4px;
}

.pass-board.is-open .pass-board__chevron {
  transform: rotate(225deg);
  margin-top: 4px;
}

.pass-board__content {
  padding: 0 14px 12px;
}

.pass-board__block + .pass-board__block {
  margin-top: 14px;
}

.pass-board__h {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 8px;
  font-size: 11px;
  font-weight: 800;
  color: var(--text-sub);
  line-height: 1.4;
}

.pass-board__h::before {
  content: "";
  width: 4px;
  height: 12px;
  border-radius: 999px;
  background: currentColor;
  flex: none;
}

.pass-board__block--dpa .pass-board__h {
  color: var(--c-dpa);
}

.pass-board__block--pp .pass-board__h {
  color: var(--c-pp);
}

.pass-board__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 6px;
}

.pass-board__item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 10px;
  background: var(--surface-2);
  border: 1px solid transparent;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
}

.pass-board__item.is-sale {
  background: color-mix(in srgb, var(--c-empty) 16%, var(--surface));
  border-color: color-mix(in srgb, var(--c-empty) 28%, transparent);
}

.pass-board__item.is-soldout {
  background: color-mix(in srgb, var(--text-sub) 8%, var(--surface));
}

.pass-board__item.is-soldout .pass-board__name {
  color: var(--text-sub);
}

.pass-board__name {
  flex: 1;
  min-width: 0;
}

.pass-board__pill {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  min-width: 4.5em;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.02em;
  line-height: 1.2;
  white-space: nowrap;
  background: color-mix(in srgb, var(--text-sub) 16%, transparent);
  color: var(--text-sub);
}

.pass-board__item.is-sale .pass-board__pill {
  background: var(--c-empty);
  color: #fff;
}

.pass-board__item.is-soldout .pass-board__pill {
  background: var(--c-off);
  color: #fff;
}

.pass-board__item.is-target .pass-board__pill {
  background: transparent;
  color: var(--text-sub);
  border: 1px solid color-mix(in srgb, var(--text-sub) 40%, transparent);
}

.pass-board__time {
  flex: none;
  font-size: 12px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
  color: var(--text);
}

.pass-board__item.is-soldout .pass-board__time {
  color: var(--text-sub);
}

.pass-board__time.is-predict {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-sub);
}

.pass-board__none {
  margin: 0;
  font-size: 12px;
  color: var(--text-sub);
}

/* ---------- 表示切替タブ（待ち時間 / ショー / 行動計画） ---------- */
.modebar {
  margin-top: 12px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 4px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 4px;
}

.modebtn {
  appearance: none;
  border: none;
  background: transparent;
  color: var(--text-sub);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: -0.02em;
  padding: 9px 2px;
  border-radius: 11px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-width: 0;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.modebtn__icon {
  font-size: 14px;
  line-height: 1;
  flex: none;
}

.modebtn__label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* 幅の狭い端末ではアイコンを省いてラベル全文を優先表示 */
@media (max-width: 380px) {
  .modebtn {
    font-size: 12px;
    gap: 0;
  }
  .modebtn__icon {
    display: none;
  }
}

.modebtn.is-active {
  background: var(--accent);
  color: var(--accent-ink);
  box-shadow: 0 2px 8px color-mix(in srgb, var(--accent) 45%, transparent);
}

/* ---------- 言語切替（営業時間の上・スクロール非固定） ---------- */
.langbar {
  margin: 12px max(16px, env(safe-area-inset-left)) 0
    max(16px, env(safe-area-inset-right));
  display: flex;
  gap: 6px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 4px;
}

.langbtn {
  flex: 1;
  appearance: none;
  border: none;
  background: transparent;
  color: var(--text-sub);
  font-size: 13px;
  font-weight: 700;
  padding: 8px 6px;
  border-radius: 9px;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.langbtn.is-active {
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

/* ---------- Stats ---------- */
.stats {
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.stat {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 8px 6px;
  text-align: center;
}

.stat__num {
  display: block;
  font-size: 20px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.stat__label {
  font-size: 11px;
  color: var(--text-sub);
}

/* ---------- Main / list ---------- */
.main {
  flex: 1;
  /* padding-top は 0 にし、parkhours-bar の margin-bottom(12px) だけで
     上の要素との間隔を確保する。header 側の padding-bottom(12px) があるため
     営業時間バーが非表示の場合も隙間は崩れない。 */
  padding: 0 max(16px, env(safe-area-inset-left)) 24px
    max(16px, env(safe-area-inset-right));
}

.list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  animation: rise 0.35s ease both;
}

.card.is-chartable {
  cursor: pointer;
}

.card.is-chartable:active {
  background: color-mix(in srgb, var(--surface-2) 40%, var(--surface));
}

.card__head {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.card__aside {
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.card__time-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.card__chevron {
  flex: none;
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--text-sub);
  border-bottom: 2px solid var(--text-sub);
  transform: rotate(45deg);
  transition: transform 0.2s ease;
  opacity: 0.7;
  margin-top: -2px;
}

.card.is-open .card__chevron {
  transform: rotate(225deg);
  margin-top: 2px;
}

.card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 5px;
  background: var(--tier, var(--c-off));
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
}

.card__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.card__title {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-width: 0;
  flex: 1;
}

.card__thumb {
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: 8px;
  overflow: hidden;
  background: color-mix(in srgb, var(--text-sub) 18%, var(--surface-2));
}

.card__thumb-img {
  display: block;
  width: 48px;
  height: 48px;
  object-fit: cover;
}

.card__thumb-img[hidden] {
  display: none;
}

.card__name {
  font-size: 18px;
  font-weight: 800;
  line-height: 1.35;
  margin: 0;
  min-width: 0;
  flex: 1;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card__meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.card__badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 700;
  color: var(--tier, var(--c-off));
}

.card__badge::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
}

.card__range {
  font-size: 11px;
  color: var(--text-sub);
  font-variant-numeric: tabular-nums;
}

.card__time {
  flex: none;
  text-align: right;
  min-width: 88px;
}

.card__num {
  font-size: 44px;
  font-weight: 900;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  color: var(--tier, var(--text));
}

.card__unit {
  font-size: 16px;
  font-weight: 800;
  color: var(--text-sub);
  margin-left: 3px;
}

.card__na {
  font-size: 20px;
  font-weight: 800;
  color: var(--c-off);
}

/* 時間帯別グラフ（スパークライン＋目盛り） */
.card__chart {
  display: grid;
  grid-template-columns: 24px 1fr;
  grid-template-rows: 1fr 13px;
  column-gap: 4px;
  height: 68px;
  margin-top: 4px;
}

/* カード内グラフの横フリック切替（本日 / 直近1ヶ月） */
.cchart {
  margin-top: 2px;
}

.cchart__tabs {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 2px;
  justify-content: flex-start;
}

.cchart__tab {
  appearance: none;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text-sub);
  font-size: 10px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.cchart__hint {
  margin-left: auto;
  font-size: 9px;
  color: var(--text-sub);
  white-space: nowrap;
  opacity: 0.75;
}

.cchart__tab.is-active {
  background: color-mix(in srgb, var(--tier, var(--c-mid)) 18%, var(--surface));
}

/* ビュー間スワイプアニメーション用ラッパー */
.views-wrap {
  position: relative;
  overflow: hidden;
}
.views-wrap.is-swiping > #waitView,
.views-wrap.is-swiping > #showView,
.views-wrap.is-swiping > #planView {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  will-change: transform;
}

.cchart__track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  overscroll-behavior-x: contain;
}

.cchart__track::-webkit-scrollbar {
  display: none;
}

.cchart__pane {
  flex: 0 0 100%;
  scroll-snap-align: start;
  min-width: 0;
}

/* アコーディオン内: 概要 / 基本情報 / FAQ（展開時のみ表示・FVは不変） */
.card__guide {
  margin-top: 12px;
  padding: 12px 2px 4px;
  border-top: 1px solid var(--border);
  color: var(--text);
  font-size: 13px;
  line-height: 1.65;
}

.card__guide-section + .card__guide-section {
  margin-top: 14px;
}

.card__guide-title {
  margin: 0 0 6px;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.01em;
  color: var(--text);
}

.card__guide-desc {
  margin: 0;
  color: var(--text-sub);
  font-size: 13px;
  line-height: 1.7;
}

.card__guide-dl {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.card__guide-row {
  display: grid;
  grid-template-columns: 5.5em 1fr;
  gap: 8px;
  align-items: baseline;
}

.card__guide-row dt {
  margin: 0;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-sub);
}

.card__guide-row dd {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.card__guide-faq {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.card__guide-qa {
  margin: 0;
}

.card__guide-q,
.card__guide-a {
  margin: 0;
  font-size: 13px;
  line-height: 1.65;
}

.card__guide-q {
  font-weight: 700;
  color: var(--text);
}

.card__guide-a {
  margin-top: 2px;
  color: var(--text-sub);
}

.card__guide-qmark,
.card__guide-amark {
  font-weight: 800;
  color: color-mix(in srgb, var(--tier, var(--c-mid)) 55%, var(--text));
}

.card__chart.is-empty {
  display: flex;
  align-items: center;
  position: relative;
}

.chart-yaxis {
  grid-column: 1;
  grid-row: 1;
  position: relative;
}

.chart-plot {
  grid-column: 2;
  grid-row: 1;
  position: relative;
}

.chart-xaxis {
  grid-column: 2;
  grid-row: 2;
  position: relative;
}

.chart-plot svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  overflow: visible;
}

.ylab {
  position: absolute;
  right: 0;
  font-size: 9px;
  line-height: 1;
  color: var(--text-sub);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.xlab {
  position: absolute;
  top: 1px;
  font-size: 7.5px;
  line-height: 1;
  color: var(--text-sub);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* 月間グラフ: X軸に全日付(1〜月末)＋曜日を2段表示するため軸を高めにする */
.card__chart--month {
  grid-template-rows: 1fr 20px;
  height: 80px;
}

.xlab--day {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
}

.xlab--day b {
  font-size: 6px;
  font-weight: 700;
}

.xlab--day i {
  font-size: 5.5px;
  font-style: normal;
  opacity: 0.85;
}

.spark-area {
  fill: var(--tier, var(--c-off));
  opacity: 0.12;
}

.spark-line {
  fill: none;
  stroke: var(--tier, var(--c-off));
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}

.spark-dot {
  fill: var(--tier, var(--c-off));
}

.spark-grid {
  stroke: var(--border);
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
}

.chart-dot {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--tier, var(--c-off));
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--tier, var(--c-off)) 25%, transparent);
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.daymark {
  position: absolute;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  box-shadow: 0 0 0 1px var(--surface);
}

.chart-note {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  font-size: 11px;
  color: var(--text-sub);
}

.chart-note--overlay {
  left: 50%;
  transform: translate(-50%, -50%);
  white-space: nowrap;
}

.chart-val {
  position: absolute;
  font-size: 8px;
  font-weight: 700;
  line-height: 1;
  color: var(--text);
  background: color-mix(in srgb, var(--surface) 78%, transparent);
  padding: 1px 2px;
  border-radius: 3px;
  white-space: nowrap;
  pointer-events: none;
  font-variant-numeric: tabular-nums;
}

/* 取得不可カード */
.card.is-off {
  box-shadow: none;
  background: var(--surface-2);
  opacity: 0.78;
}

/* メンテナンス休止中 */
.section-off {
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
}

.section-off:first-child {
  margin-top: 0;
}

.section-off__head {
  appearance: none;
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  margin: 0;
  padding: 12px 14px;
  border: none;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.section-off__head:active {
  background: var(--surface-2);
}

.section-off__title {
  flex: 1;
  min-width: 0;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.01em;
  color: var(--text-sub);
}

.section-off__count {
  flex: none;
  min-width: 1.5em;
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: var(--text-sub);
  background: var(--surface-2);
}

.section-off__chevron {
  flex: none;
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--text-sub);
  border-bottom: 2px solid var(--text-sub);
  transform: rotate(45deg);
  transition: transform 0.2s ease;
  opacity: 0.75;
  margin-top: -4px;
}

.section-off.is-open .section-off__chevron {
  transform: rotate(225deg);
  margin-top: 4px;
}

.section-off__list {
  list-style: none;
  margin: 0;
  padding: 0 8px 10px;
  display: grid;
  gap: 8px;
}

.section-off__list .card {
  margin: 0;
}

/* セクション見出し */
.section-title {
  margin: 18px 4px 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--text-sub);
}

.section-title:first-child {
  margin-top: 2px;
}

/* ---------- 行動計画 ---------- */
.toolbar--plan {
  margin-bottom: 12px;
  align-items: flex-start;
}

.plan-reset {
  appearance: none;
  flex: none;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text);
  font-size: 12px;
  font-weight: 800;
  padding: 8px 12px;
  border-radius: 999px;
  cursor: pointer;
}

.plan-reset:active {
  transform: scale(0.96);
}

/* 選択中ショー直下に差し込むパネル行 */
.plan-swap-item {
  list-style: none;
  margin: 0;
  padding: 0;
}

.plan-swap {
  margin: 0 0 4px;
  padding: 14px;
  background: color-mix(in srgb, var(--c-mid) 12%, var(--surface));
  border: 1px solid color-mix(in srgb, var(--c-mid) 45%, transparent);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.plan-pick.is-selecting {
  border-color: color-mix(in srgb, var(--c-mid) 55%, transparent);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--c-mid) 30%, transparent);
  background: color-mix(in srgb, var(--c-mid) 10%, var(--surface));
}

.plan-swap__title {
  font-size: 15px;
  font-weight: 900;
  color: var(--c-mid);
  margin-bottom: 6px;
}

/* 入れ替え先ショー名（NEW なら冒頭） */
.plan-swap__dest {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 0 0 8px;
  font-size: 15px;
  font-weight: 900;
  color: var(--text);
  line-height: 1.35;
}

.plan-swap__dest .show-new {
  flex: none;
  margin-right: 0;
  margin-top: 1px;
}

.plan-swap__dest-name {
  min-width: 0;
  word-break: break-word;
}

.plan-swap__lead {
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.45;
}

.plan-swap__opts {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.plan-swap__opt {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px;
}

.plan-swap__opt-head {
  font-size: 14px;
  font-weight: 900;
  color: var(--accent);
  margin-bottom: 6px;
  font-variant-numeric: tabular-nums;
}

.plan-swap__drop-label {
  font-size: 11px;
  font-weight: 800;
  color: var(--text-sub);
  margin-bottom: 4px;
}

.plan-swap__drops {
  margin: 0 0 10px;
  padding-left: 1.2em;
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.5;
}

.plan-swap__drop {
  list-style: inherit;
}

.plan-swap__drop .show-new {
  margin-right: 6px;
  vertical-align: 0.12em;
}

.plan-swap__drop-title {
  margin-left: 6px;
  word-break: break-word;
}

.plan-swap__drops b {
  color: var(--c-full);
  font-variant-numeric: tabular-nums;
}

.plan-swap__do {
  appearance: none;
  width: 100%;
  border: none;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 13px;
  font-weight: 800;
  padding: 9px 14px;
  cursor: pointer;
}

.plan-swap__do:active {
  transform: scale(0.98);
}

/* 行動計画: 空き回の開始時刻一覧 */
.plan-slotpick {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.plan-slotpick__btn {
  appearance: none;
  flex: 0 0 auto;
  min-width: 3.6em;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--accent);
  font-size: 14px;
  font-weight: 900;
  padding: 8px 10px;
  cursor: pointer;
  font-variant-numeric: tabular-nums;
  text-align: center;
  line-height: 1.2;
}

.plan-slotpick__btn:active {
  transform: scale(0.98);
  background: color-mix(in srgb, var(--accent) 12%, var(--surface));
}

.plan-swap__cancel {
  appearance: none;
  display: block;
  width: 100%;
  margin-top: 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--text-sub);
  font-size: 13px;
  font-weight: 800;
  padding: 9px 14px;
  cursor: pointer;
}

.plan-picksec {
  margin-top: 14px;
}

.plan-picksec__head {
  appearance: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  margin: 0 0 8px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface-2);
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.plan-picksec__head:active {
  background: color-mix(in srgb, var(--surface-2) 70%, var(--surface));
}

.plan-section-title {
  margin: 0;
  font-size: 14px;
  font-weight: 800;
  color: var(--text);
}

.plan-picksec__chevron {
  flex: none;
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--text-sub);
  border-bottom: 2px solid var(--text-sub);
  transform: rotate(45deg);
  transition: transform 0.2s ease;
  opacity: 0.75;
  margin-top: -4px;
}

.plan-picksec.is-open .plan-picksec__chevron {
  transform: rotate(225deg);
  margin-top: 4px;
}

.plan-picksec:not(.is-open) .plan-picksec__body {
  display: none;
}

.plan-timeline {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 12px 12px 12px 48px;
  min-height: 320px;
  overflow: hidden;
}

.plan-timeline__rail {
  position: absolute;
  left: 40px;
  top: 12px;
  bottom: 12px;
  width: 3px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 45%, var(--border));
}

.plan-timeline__ticks {
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 40px;
  z-index: 12;
  pointer-events: none;
}

.plan-timeline__tick {
  position: absolute;
  right: 10px;
  transform: translateY(-50%);
  font-size: 10px;
  font-weight: 700;
  color: var(--text-sub);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.plan-timeline__track {
  position: relative;
  min-height: 296px;
  width: 100%;
}

.plan-timeline__grid {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.plan-timeline__gridline {
  position: absolute;
  left: 0;
  right: 0;
  border-top: 1px dashed color-mix(in srgb, var(--border) 85%, var(--text-sub));
  opacity: 0.9;
}

.plan-timeline__park {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 10;
}

.plan-timeline__park .plan-timeline__gridline.is-park-open,
.plan-timeline__park .plan-timeline__gridline.is-park-close {
  border-top: 2px solid var(--accent);
  opacity: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.plan-timeline__park-label {
  transform: translateY(-50%);
  background: var(--surface);
  color: var(--accent);
  border: 1.5px solid var(--accent);
  border-radius: 6px;
  padding: 2px 10px;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.02em;
  line-height: 1.3;
  white-space: nowrap;
  box-shadow: 0 1px 4px color-mix(in srgb, var(--accent) 20%, transparent);
}

.plan-timeline__tick.is-park-open,
.plan-timeline__tick.is-park-close {
  color: var(--accent);
  font-weight: 900;
  font-size: 11px;
  z-index: 13;
}

/* 現在時刻ライン */
.plan-timeline__now {
  position: absolute;
  left: 0;
  right: 0;
  z-index: 11;
  pointer-events: none;
  border-top: 2px solid var(--c-full, #e53935);
  transform: translateY(-50%);
  display: flex;
  align-items: center;
}

.plan-timeline__now-label {
  margin-left: 0;
  transform: translateY(-50%);
  background: var(--c-full, #e53935);
  color: #fff;
  border-radius: 4px;
  padding: 1px 6px;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.02em;
  line-height: 1.35;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  box-shadow: 0 1px 3px color-mix(in srgb, var(--c-full, #e53935) 35%, transparent);
}

.plan-block {
  position: absolute;
  left: 8px;
  right: 0;
  min-height: 44px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid color-mix(in srgb, var(--accent) 40%, var(--border));
  background: color-mix(in srgb, var(--accent) 14%, var(--surface));
  color: var(--text);
  cursor: pointer;
  text-align: left;
  box-shadow: var(--shadow);
  z-index: 1;
  box-sizing: border-box;
  overflow: hidden;
}

.plan-block:active {
  transform: scale(0.98);
}

.plan-block.is-editing {
  z-index: 3;
  overflow: visible;
  min-height: auto;
  height: auto !important;
  border-color: var(--accent);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 35%, transparent);
}

.plan-block__time {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 900;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
  margin-bottom: 2px;
  line-height: 1.2;
}

.plan-block__time .show-new {
  flex: none;
  margin-right: 0;
  vertical-align: baseline;
  font-size: 10px;
  padding: 0 5px;
  border-width: 1.5px;
  box-sizing: border-box;
}

.plan-block__time-val {
  min-width: 0;
}

.plan-block__name {
  display: block;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.plan-block__menu {
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.plan-block__hint {
  font-size: 11px;
  color: var(--text-sub);
  font-weight: 600;
}

.plan-block__times {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.plan-block__times button {
  appearance: none;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-size: 12px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  padding: 4px 8px;
  border-radius: 7px;
  cursor: pointer;
}

.plan-block__times button:active {
  background: var(--surface-2);
}

.plan-block__actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.plan-block__actions button {
  appearance: none;
  border: none;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  padding: 6px 12px;
  cursor: pointer;
}

.plan-block__actions .is-danger {
  background: color-mix(in srgb, var(--c-full) 18%, var(--surface));
  color: var(--c-full);
}

.plan-block__actions .is-muted {
  background: var(--surface-2);
  color: var(--text-sub);
}

.plan-timeline__empty {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  text-align: center;
  font-size: 13px;
  color: var(--text-sub);
  font-weight: 600;
  pointer-events: none;
}

.plan-pick {
  cursor: pointer;
  border: none;
  width: 100%;
  text-align: left;
  font: inherit;
  color: inherit;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 14px;
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.plan-pick:active {
  transform: scale(0.98);
}

.plan-pick.is-planned {
  opacity: 1;
  cursor: pointer;
  background: color-mix(in srgb, var(--c-empty) 22%, var(--surface));
  border-color: color-mix(in srgb, var(--c-empty) 55%, transparent);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--c-empty) 25%, transparent);
  color: var(--c-empty);
}

.plan-pick .card__title {
  align-items: center;
}

.plan-pick__name {
  font-size: 17px;
  font-weight: 800;
  line-height: 1.35;
  min-width: 0;
  flex: 1;
}

.plan-pick__meta {
  flex: none;
  font-size: 11px;
  font-weight: 800;
  color: var(--text-sub);
  font-variant-numeric: tabular-nums;
}

.plan-pick.is-planned .plan-pick__name,
.plan-pick.is-planned .plan-pick__meta {
  color: var(--c-empty);
  font-weight: 800;
}

.plan-picklist {
  gap: 8px;
}

.plan-picklist > li {
  list-style: none;
}

/* ---------- ショー開始時間カード ---------- */
.toolbar--show {
  margin-bottom: 12px;
}

.showcard {
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  animation: rise 0.35s ease both;
}

.showcard::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 5px;
  background: var(--tier, var(--c-off));
}

.showcard__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.showcard__top .card__title {
  flex: 1;
  min-width: 0;
}

.showcard.is-guidable {
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.showcard.is-guidable:active {
  transform: scale(0.995);
}

.showcard__aside {
  flex: none;
  display: flex;
  align-items: center;
  gap: 8px;
}

.showcard__chevron {
  flex: none;
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--text-sub);
  border-bottom: 2px solid var(--text-sub);
  transform: rotate(45deg);
  transition: transform 0.2s ease;
  opacity: 0.7;
  margin-top: 6px;
}

.showcard.is-open .showcard__chevron {
  transform: rotate(225deg);
  margin-top: 10px;
}

.showfold {
  margin-top: 0;
}

.showfold__body {
  margin-top: 2px;
}

.showfold__body .card__guide {
  margin-top: 4px;
}

.showcard__name {
  font-size: 18px;
  font-weight: 800;
  line-height: 1.35;
  margin: 0;
  min-width: 0;
  flex: 1;
  overflow: hidden;
}

.showcard__name-text {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.showcard__ticket-note {
  margin: 8px 0 0;
  padding: 8px 10px;
  border-radius: 8px;
  background: color-mix(in srgb, var(--c-full, #e53935) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--c-full, #e53935) 35%, transparent);
  color: var(--ink, inherit);
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.45;
}

/* 新規ショーの NEW バッジ（3カ月間） */
.show-new {
  display: inline-block;
  flex: none;
  margin-right: 8px;
  padding: 1px 7px;
  border: 2px solid var(--c-full, #e53935);
  border-radius: 4px;
  color: var(--c-full, #e53935);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.06em;
  line-height: 1.35;
  vertical-align: 0.1em;
  white-space: nowrap;
}

/* ショー開始時間カードでは NEW を名称の上段に改行表示 */
.showcard__name > .show-new {
  display: inline-block;
  margin-right: 0;
  margin-bottom: 4px;
  vertical-align: baseline;
}

.plan-pick__name .show-new {
  vertical-align: 0.15em;
}

/* 次回開始までのカウントダウン */
.showcard__count {
  flex: none;
  text-align: right;
  min-width: 96px;
  line-height: 1;
}

.showcard__lead {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-sub);
  margin-bottom: 3px;
}

.showcard__num {
  font-size: 40px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  color: var(--tier, var(--text));
}

/* 1時間以上は従来サイズ */
.showcard__count.is-long .showcard__num {
  font-size: 24px;
}

.showcard__unit {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-sub);
  margin-left: 3px;
}

.showcard__count.is-long .showcard__unit {
  font-size: 12px;
  font-weight: 700;
  margin-left: 2px;
}

.showcard__count.is-long .showcard__lead {
  font-size: 10px;
  margin-bottom: 2px;
}

/* 開催中/まもなく/終了などのテキスト状態 */
.showcard__status {
  font-size: 22px;
  font-weight: 800;
  color: var(--tier, var(--c-off));
}

.showcard__meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.showcard__round {
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  font-weight: 800;
  color: var(--tier, var(--c-off));
  background: color-mix(in srgb, var(--tier, var(--c-off)) 14%, var(--surface));
  border: 1px solid color-mix(in srgb, var(--tier, var(--c-off)) 35%, transparent);
  border-radius: 999px;
  padding: 2px 9px;
  font-variant-numeric: tabular-nums;
}

/* 全開始時刻のチップ一覧（済/次回/未来を色分け） */
.showtimes {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.showtime {
  font-size: 12px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--text-sub);
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 7px;
  padding: 3px 8px;
}

.showtime.is-past {
  opacity: 0.42;
  text-decoration: line-through;
}

.showtime.is-next {
  color: var(--accent-ink);
  background: var(--tier, var(--accent));
  border-color: transparent;
}

.showcard.is-ended,
.showcard.is-suspended {
  box-shadow: none;
  background: var(--surface-2);
  opacity: 0.82;
}

/* ---------- Skeleton ---------- */
.skeletons {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.skel {
  height: 74px;
  border-radius: var(--radius);
  background: linear-gradient(
    100deg,
    var(--surface) 30%,
    var(--surface-2) 50%,
    var(--surface) 70%
  );
  background-size: 200% 100%;
  animation: shimmer 1.3s infinite;
}

@keyframes shimmer {
  to {
    background-position: -200% 0;
  }
}

/* ---------- States ---------- */
.offline {
  background: color-mix(in srgb, var(--c-mid) 18%, var(--surface));
  color: var(--text);
  border: 1px solid color-mix(in srgb, var(--c-mid) 40%, transparent);
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 12px;
  text-align: center;
}

/* 開園前の待機告知（個別カード最上部の別枠） */
.preopen-notice {
  display: flex;
  align-items: center;
  gap: 12px;
  background: linear-gradient(
    135deg,
    color-mix(in srgb, var(--accent) 20%, var(--surface)),
    color-mix(in srgb, var(--accent) 8%, var(--surface))
  );
  border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent);
  border-radius: 14px;
  padding: 14px 16px;
  /* toolbar の直下・カード一覧の直上に配置。横余白は <main> の padding が担う */
  margin: 0 0 12px;
  box-shadow: var(--shadow);
}

.preopen-notice__icon {
  font-size: 26px;
  line-height: 1;
  flex: none;
}

.preopen-notice__text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.preopen-notice__text strong {
  font-size: 16px;
  font-weight: 800;
}

.preopen-notice__text span {
  font-size: 12px;
  color: var(--text-sub);
}

.empty {
  text-align: center;
  color: var(--text-sub);
  padding: 40px 0;
}

.error {
  text-align: center;
  padding: 40px 16px;
  color: var(--text-sub);
}

.btn {
  margin-top: 12px;
  padding: 10px 22px;
  border: none;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}

.btn:active {
  transform: scale(0.96);
}

/* ---------- パークコンシェルジュ（待ち時間セクション最下部） ---------- */
.concierge {
  margin: 24px 0 12px;
  padding: 18px 18px 16px;
  background: color-mix(in srgb, var(--accent) 10%, var(--surface));
  border: 2.5px solid color-mix(in srgb, var(--accent) 55%, var(--border));
  border-radius: calc(var(--radius) + 2px);
  box-shadow:
    0 0 0 1px color-mix(in srgb, var(--accent) 18%, transparent),
    0 10px 28px color-mix(in srgb, var(--accent) 16%, transparent);
  position: relative;
  overflow: hidden;
}

.concierge::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 5px;
  background: var(--accent);
}

.concierge__head {
  margin: 0 0 10px;
  padding: 0 0 10px 4px;
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 28%, var(--border));
}

.concierge__head-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px 12px;
}

.concierge__title {
  margin: 0;
  font-size: 16px;
  font-weight: 900;
  color: var(--accent);
  letter-spacing: 0.03em;
}

.concierge__title--report {
  font-size: 17px;
  line-height: 1.45;
  letter-spacing: 0.02em;
}

.concierge__time {
  margin: 0;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: var(--text-sub);
  white-space: nowrap;
}

.concierge__time[hidden] {
  display: none;
}

.concierge__headline {
  margin: 0 0 10px;
  font-size: 17px;
  font-weight: 900;
  line-height: 1.45;
  color: var(--accent);
}

.concierge__summary {
  margin: 0 0 16px;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.65;
  color: var(--text);
}

.concierge__block {
  margin: 0 0 12px;
}

.concierge__block--lists {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.concierge__label {
  margin: 0 0 4px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--text-sub);
}

.concierge__label--action {
  margin: 0 0 8px;
  font-size: 15px;
  font-weight: 900;
  letter-spacing: 0.02em;
  color: var(--accent);
  line-height: 1.35;
}

.concierge__label--empty {
  color: var(--c-sat);
}

.concierge__label--busy {
  color: var(--c-full);
}

.concierge__talk {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.7;
  color: var(--text);
}

.concierge__talk p {
  margin: 0 0 0.65em;
}

.concierge__talk p:last-child {
  margin-bottom: 0;
}

.concierge__talk-list {
  margin: 0 0 0.65em;
  padding-left: 1.25em;
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
  color: inherit;
}

.concierge__talk-list:last-child {
  margin-bottom: 0;
}

.concierge__talk-list li {
  margin: 0 0 0.35em;
}

.concierge__talk-list li:last-child {
  margin-bottom: 0;
}

.concierge__list {
  margin: 0;
  padding-left: 1.2em;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.6;
  color: var(--text);
}

.concierge__list--empty {
  color: var(--c-sat);
}

.concierge__list--busy {
  color: var(--c-full);
}

.concierge__list li {
  margin: 0 0 4px;
}

.concierge__list li:last-child {
  margin-bottom: 0;
}

.concierge__disclaimer {
  margin: 4px 0 0;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--text-sub);
  white-space: pre-line;
}

/* ---------- iOS ホーム画面追加案内（テーマ切替の直上） ---------- */
.ios-home {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 2px 0;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.ios-home[hidden] {
  display: none;
}

.ios-home__icon {
  flex: none;
  font-size: 28px;
  line-height: 1;
}

.ios-home__text {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.ios-home__title {
  margin: 0;
  font-size: 14px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: 0.02em;
}

.ios-home__body {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.55;
  color: var(--text-sub);
}

/* ---------- テーマ切替（カード一覧の最下部） ---------- */
.thememode {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 22px 2px 4px;
}

.thememode__label {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-sub);
}

.thememode__btns {
  display: inline-flex;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 3px;
  gap: 2px;
}

.themebtn {
  appearance: none;
  border: none;
  background: transparent;
  color: var(--text-sub);
  font-size: 13px;
  font-weight: 700;
  padding: 8px 16px;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: background 0.15s ease, color 0.15s ease;
}

.themebtn__icon {
  font-size: 14px;
  line-height: 1;
}

.themebtn.is-active {
  background: var(--accent);
  color: var(--accent-ink);
  box-shadow: 0 2px 8px color-mix(in srgb, var(--accent) 40%, transparent);
}

/* ---------- Toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(env(safe-area-inset-bottom, 0px) + 20px);
  transform: translateX(-50%) translateY(20px);
  background: var(--text);
  color: var(--bg);
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  box-shadow: var(--shadow);
  opacity: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
  z-index: 50;
  pointer-events: none;
}

.toast.is-show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ---------- FAB (scroll top) ---------- */
.fab {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: calc(env(safe-area-inset-bottom, 0px) + 20px);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: none;
  background: var(--accent);
  color: var(--accent-ink);
  display: grid;
  place-items: center;
  box-shadow: var(--shadow);
  cursor: pointer;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 40;
}

.fab.is-show {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}
