/* ===== LIGHT PREMIUM DESIGN TOKENS — hex fallbacks (all engines) ===== */
:root {
  color-scheme: light;

  /* Core palette — hex fallbacks */
  --bg:        #F7F8FC;
  --surface:   #FFFFFF;
  --surface-2: #EFF1F7;
  --border:    #DCE0EA;
  --text:      #1B1F2E;
  --text-dim:  #5C6882;
  --accent:    #D12B47;
  --accent-2:  #6B35C4;
  --gold:      #856400;
  --accent-hover: #B32340;
  --accent-tint:  rgba(209,43,71,0.09);

  /* Gradient/surface aliases (used by specific components) */
  --hero-bg:   linear-gradient(135deg, #EFF1F7 0%, #FAF0F3 100%);
  --footer-bg: #EFF1F7;
  --bg2:       var(--surface-2);

  /* Shape */
  --radius:    14px;
  --radius-lg: 20px;

  /* Fluid type scale (1.25 ratio) */
  --fs-1:    clamp(0.86rem, 0.8rem + 0.3vw, 0.95rem);
  --fs-2:    clamp(1rem, 0.9rem + 0.5vw, 1.15rem);
  --fs-3:    clamp(1.3rem, 1.1rem + 1vw, 1.6rem);
  --fs-hero: clamp(1.9rem, 1.4rem + 3vw, 3.2rem);

  /* Backward-compat aliases (existing pages use these) */
  --primary:    var(--accent);
  --dark:       var(--bg);
  --darker:     var(--footer-bg);
  --light:      var(--surface);
  --gray:       var(--text-dim);
  --green:      #10b981;
  --blue:       #2563eb;
  --orange:     #f59e0b;
  --cn-primary: var(--accent);
  --cn-accent:  var(--accent-2);
  --cn-bg:      var(--bg);
  --cn-text:    var(--text);
  --cn-muted:   var(--text-dim);
  --cn-border:  var(--border);
}

/* ===== OKLCH OVERRIDE — richer gamut on supporting engines ===== */
@supports (color: oklch(0 0 0)) {
  :root {
    --bg:        oklch(0.985 0.003 265);
    --surface:   oklch(1 0 0);
    --surface-2: oklch(0.963 0.007 265);
    --border:    oklch(0.895 0.008 265);
    --text:      oklch(0.215 0.022 265);
    --text-dim:  oklch(0.476 0.025 265);
    --accent:    oklch(0.535 0.188 12);
    --accent-2:  oklch(0.490 0.168 300);
    --gold:      oklch(0.500 0.130 78);
    --accent-hover: color-mix(in oklch, var(--accent), black 12%);
    --accent-tint:  color-mix(in oklch, var(--accent) 9%, transparent);

    --hero-bg:   linear-gradient(135deg, oklch(0.963 0.007 265) 0%, oklch(0.975 0.008 350) 100%);
    --footer-bg: oklch(0.963 0.007 265);
  }
}

/* ===== OPTIONAL DARK THEME — restores original luxury-dark palette ===== */
@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --bg:        #16213e;
    --surface:   #1a2540;
    --surface-2: #222e4a;
    --border:    #2d3a52;
    --text:      #eef0f5;
    --text-dim:  #94a3b8;
    --accent:    #e94560;
    --accent-2:  #a855f7;
    --gold:      #d4a017;
    --accent-hover: #ec5a74;
    --accent-tint:  rgba(233,69,96,0.14);
    --hero-bg:   linear-gradient(135deg, #16213e 0%, #1e1040 60%, #280e18 100%);
    --footer-bg: #0d1728;
  }
}
@supports (color: oklch(0 0 0)) {
  @media (prefers-color-scheme: dark) {
    :root {
      --bg:        oklch(0.15 0.015 265);
      --surface:   oklch(0.19 0.02 265);
      --surface-2: oklch(0.24 0.025 265);
      --border:    oklch(0.30 0.02 265);
      --text:      oklch(0.95 0.01 265);
      --text-dim:  oklch(0.72 0.02 265);
      --accent:    oklch(0.68 0.19 12);
      --accent-2:  oklch(0.72 0.15 300);
      --gold:      oklch(0.80 0.13 85);
      --accent-hover: color-mix(in oklch, var(--accent), white 12%);
      --accent-tint:  color-mix(in oklch, var(--accent) 14%, transparent);
      --hero-bg:   linear-gradient(135deg, oklch(0.15 0.015 265) 0%, oklch(0.18 0.04 290) 60%, oklch(0.20 0.07 15) 100%);
      --footer-bg: oklch(0.11 0.015 265);
    }
  }
}

/* data-theme overrides (UI toggle) */
:root[data-theme="light"] {
  color-scheme: light;
  --bg:        #F7F8FC;
  --surface:   #FFFFFF;
  --surface-2: #EFF1F7;
  --border:    #DCE0EA;
  --text:      #1B1F2E;
  --text-dim:  #5C6882;
  --accent:    #D12B47;
  --accent-2:  #6B35C4;
  --gold:      #856400;
  --accent-hover: #B32340;
  --accent-tint:  rgba(209,43,71,0.09);
  --hero-bg:   linear-gradient(135deg, #EFF1F7 0%, #FAF0F3 100%);
  --footer-bg: #EFF1F7;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg:        #16213e;
  --surface:   #1a2540;
  --surface-2: #222e4a;
  --border:    #2d3a52;
  --text:      #eef0f5;
  --text-dim:  #94a3b8;
  --accent:    #e94560;
  --accent-2:  #a855f7;
  --gold:      #d4a017;
  --accent-hover: #ec5a74;
  --accent-tint:  rgba(233,69,96,0.14);
  --hero-bg:   linear-gradient(135deg, #16213e 0%, #1e1040 60%, #280e18 100%);
  --footer-bg: #0d1728;
}

/* ===== RESET ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, "Noto Sans JP", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }
button { font-family: inherit; }

/* ===== ACCESSIBILITY ===== */
/* Focus-visible ring */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

/* Reduced-motion: keep display but kill transitions/animations */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* ===== PR BAR ===== */
/* Solid accent stripe — deliberate bold band above the white header */
.prbar {
  display: block;
  background: var(--accent);
  color: #fff;
  text-align: center;
  font-size: 12px;
  padding: 6px 12px;
  cursor: pointer;
  text-decoration: none;
}
.prbar b { color: #fff; font-weight: 800; }

/* Dark theme restores the original dark PR bar */
@media (prefers-color-scheme: dark) {
  .prbar { background: linear-gradient(90deg, #1e0a2e, #341020); }
  .prbar b { color: var(--gold); }
}
:root[data-theme="dark"] .prbar { background: linear-gradient(90deg, #1e0a2e, #341020); }
:root[data-theme="dark"] .prbar b { color: var(--gold); }
:root[data-theme="light"] .prbar { background: var(--accent); }
:root[data-theme="light"] .prbar b { color: #fff; }

/* ===== SUBNAV ===== */
.subnav {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  gap: 2px;
  overflow-x: auto;
  /* Chip-strip on mobile: single row, no wrap, horizontal scroll */
  white-space: nowrap;
  padding: 0 16px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none; /* hide scrollbar on Firefox */
}
.subnav::-webkit-scrollbar { display: none; }
.subnav-in {
  max-width: 1120px;
  margin: 0 auto;
  display: flex;
  gap: 2px;
  width: 100%;
  flex-wrap: nowrap;
}
.subnav a {
  padding: 8px 14px;
  font-size: 12.5px;
  color: var(--text-dim);
  white-space: nowrap;
  border-bottom: 3px solid transparent;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}
.subnav a:hover,
.subnav a.on {
  color: var(--text);
  border-bottom-color: var(--accent);
}

/* Header free-word search. Replaces the in-body 「コンサートを探す」 button —
   comparable JP listing sites (ぴあ / イープラス / ぶらあぼ) all put one box in
   the header rather than an action button in the page body. */
.hd-search {
  display: flex;
  align-items: center;
  gap: 7px;
  /* Yields space before the nav does — the nav must never be clipped
     (「団員募集」 lost its tail and 「トピックス」 vanished entirely at 1440px). */
  flex: 0 1 240px;
  min-width: 140px;
  margin-left: auto;
  padding: 0 12px;
  height: 38px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--text-dim);
  transition: border-color .15s, background .15s;
}
.hd-search:focus-within {
  border-color: var(--accent);
  background: var(--surface);
}
.hd-search input {
  flex: 1 1 auto;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  font: inherit;
  font-size: 13px;
  color: var(--text);
}
.hd-search input::placeholder { color: var(--text-dim); }
/* The nav owns the row; the box only appears when there is genuinely space
   left over. Below this the mobile search icon in .mob-hd-ctrl takes over. */
@media (max-width: 1199px) { .hd-search { display: none; } }

/* ===== HERO REEL (BANNER CAROUSEL) ===== */
/* One track translated with translate3d. The previous scheme positioned every
   slide absolutely and swapped .on/.prev/.next classes, which only encodes three
   states — it breaks as soon as there are more than three slides, and the hero
   now carries five concerts plus one promo.
   Measured before the change: the active slide was 61% of the viewport on
   desktop with 635px of the next slide clipped off-screen. */
.bnr {
  position: relative;
  margin-bottom: 18px;
}
.bnr-viewport {
  overflow: hidden;
  border-radius: var(--radius-lg);
  touch-action: pan-y;
}
.bnr-track {
  display: flex;
  /* How far one step moves the track. MUST equal the slide's outer width
     (basis + margin) — translating a flat 100% per step while slides are
     92%+8px wide drifts a little further left on every advance, and by the
     third slide the active card is partly off-screen. */
  --bnr-step: calc(92% + 8px);
  /* Signature motion: ease-out-quint. Fast departure, soft landing — reads as a
     physical glide. 380ms; longer feels sluggish on high-refresh screens. */
  transition: transform 380ms cubic-bezier(0.22, 1, 0.36, 1);
  /* No will-change: holding a compositor layer for six image-bearing slides for
     the whole visit costs memory and buys nothing while the reel is still. */
}
.bnr-slide {
  /* SP: 92% so exactly one neighbour peeks by 8% — never a half-cut third slide */
  flex: 0 0 92%;
  margin-right: 8px;
  position: relative;
  opacity: 0.45;
  transform: scale(0.95);
  transition: opacity 380ms cubic-bezier(0.22, 1, 0.36, 1),
              transform 380ms cubic-bezier(0.22, 1, 0.36, 1);
}
.bnr-slide[data-active='true'] { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .bnr-track,
  .bnr-slide { transition: none; }
}

.bnr-card {
  position: relative;
  display: block;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--surface-2);
  border: 1px solid var(--border);
  text-decoration: none;
  color: inherit;
}
/* The visual box. CardVisual lays a blurred copy under a `contain` image, so the
   whole flyer is visible whatever its aspect ratio (measured range 0.71–2.60).
   4/3 on phones, 16/9 on desktop — see docs/DESIGN-DIRECTION-v2.md §3.3. */
.bnr-visual.cv-hero { aspect-ratio: 4 / 3; }
.bnr-card-promo .bnr-visual { aspect-ratio: 4 / 3; }

/* Text sits in the lower band only. A scrim that darkens towards the bottom
   keeps white text legible over both a bright flyer and a dark stage photo,
   and the area behind the text is usually the blurred backdrop, which is
   easier to read against than a sharp image. */
.bnr-scrim {
  position: absolute;
  inset: 0;
  /* Darkening is confined to the bottom ~30%. Collapsing the caption from four
     stacked blocks to title + one row shortened the text area enough that the
     gradient no longer has to start at 40% — it was swallowing over half the
     flyer and reading as a black band. */
  background: linear-gradient(
    to bottom,
    transparent 0%,
    transparent 52%,
    rgba(0, 0, 0, 0.26) 72%,
    rgba(0, 0, 0, 0.72) 88%,
    rgba(0, 0, 0, 0.84) 100%
  );
  pointer-events: none;
}
.bnr-body {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 0 20px 20px;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.85);
}
.bnr-kicker {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  text-shadow: none;
  flex-shrink: 0;
}
/* One caption row: badge + date (+ venue/price on wide screens) left, CTA right */
.bnr-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.bnr-title {
  font-size: 20px;
  font-weight: 800;
  line-height: 1.3;
  margin: 0 0 7px;
  color: #fff;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-wrap: balance;
}
.bnr-meta {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 12px;
  font-size: 12px;
  color: rgba(255, 255, 255, .92);
  min-width: 0;          /* lets the venue text ellipsis instead of pushing the CTA */
  overflow: hidden;
}
.bnr-meta span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.bnr-cta {
  display: inline-block;
  flex-shrink: 0;
  white-space: nowrap;
  font-size: 12px;
  font-weight: 700;
  padding: 8px 14px;
  border-radius: 999px;
  background: #fff;
  color: #1b1f2e;
  text-shadow: none;
  transition: opacity .15s;
}
@media (hover: hover) and (pointer: fine) {
  .bnr-card:hover .bnr-cta { opacity: .85; }
}

/* Progress bar — signals that the reel is on a timer. Restarts on every slide
   change (the React key remounts it) and freezes while paused. */
.bnr-prog {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 3px;
  background: rgba(0, 0, 0, .12);
  border-radius: 999px;
  overflow: hidden;
  z-index: 5;
}
.bnr-prog-fill {
  display: block;
  height: 100%;
  width: 100%;
  background: var(--accent);
  transform-origin: left center;
  animation: bnr-prog-grow linear forwards;
}
.bnr-prog-fill[data-paused='true'] { animation-play-state: paused; }
@keyframes bnr-prog-grow {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}
@media (prefers-reduced-motion: reduce) {
  .bnr-prog { display: none; }
}

/* Dots */
.bnr .dots {
  display: flex;
  gap: 7px;
  justify-content: center;
  padding: 12px 0 2px;
}
.bnr .dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  border: 0;
  padding: 0;
  background: var(--border);
  cursor: pointer;
  position: relative;
  transition: transform .18s cubic-bezier(0.2, 0.8, 0.2, 1), background .18s;
}
/* Expands the hit area to 44px without changing the painted dot */
.bnr .dot::after { content: ''; position: absolute; inset: -18px; }
.bnr .dot.on { background: var(--accent); transform: scale(1.5); }
@media (prefers-reduced-motion: reduce) {
  .bnr .dot { transition: none; }
}

/* Arrows */
.bnr .arr {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 6;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .12);
  background: rgba(15, 15, 20, .62);
  color: #fff;
  font-size: 17px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s;
}
.bnr .arr:hover { background: rgba(15, 15, 20, .88); }
.bnr .arr.l { left: 14px; }
.bnr .arr.r { right: 14px; }

/* Pause / Play */
.bnr-pause {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 7;
  background: rgba(15, 15, 20, .60);
  border: 1px solid rgba(255, 255, 255, .08);
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  transition: background .15s;
}
.bnr-pause:hover { background: rgba(15, 15, 20, .82); }
/* 36px painted, 44px touch target (WCAG 2.5.8 comfort target) */
.bnr-pause::after { content: ''; position: absolute; inset: -4px; }

/* Desktop */
@media (min-width: 761px) {
  .bnr-track { --bnr-step: 100%; }
  .bnr-slide { flex-basis: 100%; margin-right: 0; opacity: 1; transform: none; }
  /* 56vh, not 66vh: at 900px tall the hero was 617px = 69% of the fold, so
     nothing below it was ever visible without scrolling. Capping it lets the
     first concerts peek above the fold and signals that the page continues. */
  .bnr-visual.cv-hero,
  .bnr-card-promo .bnr-visual { aspect-ratio: 16 / 9; max-height: 56vh; }
  .bnr-body { padding: 0 40px 34px; }
  .bnr-title { font-size: 30px; }
  .bnr-meta { font-size: 13px; }
  .bnr-cta { font-size: 13px; padding: 10px 20px; }
  .bnr .arr.l { left: 20px; }
  .bnr .arr.r { right: 20px; }
}

/* Mobile — the hero box is only ~245px tall, so the text block has to stay
   small or it eats half the slide and collides with the flyer's own artwork. */
@media (max-width: 760px) {
  .bnr .arr { width: 38px; height: 38px; font-size: 15px; }
  .bnr .arr.l { left: 8px; }
  .bnr .arr.r { right: 8px; }
  /* Needs the descendant form: `.bnr-meta span` sets display:inline-flex and
     outranks a bare `.bnr-meta-more` on specificity. */
  .bnr-meta .bnr-meta-more { display: none; }
  .bnr-body { padding: 0 14px 12px; }
  .bnr-title { font-size: 17px; margin-bottom: 6px; }
  .bnr-kicker { font-size: 10px; padding: 2px 8px; }
  .bnr-meta { font-size: 11.5px; gap: 8px; }
  .bnr-cta { font-size: 11px; padding: 6px 11px; }
  .bnr-line { gap: 10px; }
  /* Shorter box, so the gradient has to reach working strength sooner — but it
     still only occupies the bottom third rather than half the slide. */
  .bnr-scrim {
    background: linear-gradient(
      to bottom,
      transparent 0%,
      transparent 44%,
      rgba(0, 0, 0, 0.34) 66%,
      rgba(0, 0, 0, 0.78) 86%,
      rgba(0, 0, 0, 0.88) 100%
    );
  }
}


/* ===== HEADER ===== */
header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  color: var(--text);
  position: sticky;
  top: 0;
  z-index: 100;
}
.hd-in {
  max-width: 1120px;
  margin: 0 auto;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  /* NO flex-wrap — single row on all breakpoints */
}

/* ── Logo ── */
.logo {
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--text);
  text-decoration: none;
  flex-shrink: 0;
}
.logo-img {
  display: block;
  flex-shrink: 0;
  height: 36px;
  width: auto;
}
.logo-tagline {
  display: block;
  font-size: 9px;
  font-weight: 400;
  color: var(--text-dim);
  letter-spacing: 1px;
  white-space: nowrap;
}

/* ── Desktop nav ── */
nav.main {
  display: flex;
  gap: 2px;
  /* Was flex:1, which let the nav shrink while overflow:hidden silently
     clipped it once the header search box appeared — the tail of 団員募集
     was cut and トピックス vanished entirely at 1440px. The search box is
     the element that yields now. */
  flex: 0 0 auto;
  flex-wrap: nowrap;
  overflow: hidden;
}
nav.main a {
  padding: 7px 11px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-dim);
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  transition: opacity .15s;
}
nav.main a:hover { background: var(--accent-tint); color: var(--text); }
nav.main a.on { background: var(--accent); color: #fff; }

/* ── Mobile header controls (search icon + hamburger) ── */
/* Shown on mobile, hidden on desktop */
.mob-hd-ctrl {
  display: none;
  align-items: center;
  gap: 4px;
  margin-left: auto;
  flex-shrink: 0;
}
.mob-hd-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  color: var(--text);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: background .15s;
  text-decoration: none;
}
.mob-hd-btn:hover { background: var(--accent-tint); }

/* ── Mobile bottom tab bar ── */
.mob-btmbar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 200;
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding-bottom: env(safe-area-inset-bottom);
}
.mob-tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 10px 4px 8px;
  min-height: 60px;
  color: var(--text-dim);
  font-size: 10px;
  font-weight: 600;
  text-decoration: none;
  background: transparent;
  border: none;
  cursor: pointer;
  font-family: inherit;
  transition: color .15s;
}
.mob-tab:hover,
.mob-tab.on { color: var(--accent); }
/* Center "search" tab — prominent */
.mob-tab.center {
  color: #fff;
  background: var(--accent);
  border-radius: 14px 14px 0 0;
  margin: 0 2px;
  padding-top: 14px;
  padding-bottom: 10px;
}
.mob-tab.center:hover { background: var(--accent-hover); color: #fff; }
.mob-tab.center.on { background: var(--accent-hover); color: #fff; }
.mob-tab span { line-height: 1; }

/* ── Mobile menu sheet ── */
.mob-sheet {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  top: 30%;  /* slides up from 30% */
  z-index: 300;
  background: var(--surface);
  border-top: 2px solid var(--accent);
  border-radius: 18px 18px 0 0;
  overflow-y: auto;
  padding-bottom: env(safe-area-inset-bottom);
  transform: translateY(100%);
  transition: transform .28s cubic-bezier(.4,0,.2,1);
}
.mob-sheet.open {
  display: block;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  .mob-sheet { transition: none; }
}
.mob-sheet-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px 12px;
  font-size: 15px;
  color: var(--text);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: var(--surface);
  z-index: 1;
}
.mob-sheet-close {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface-2);
  border: none;
  border-radius: 50%;
  color: var(--text);
  cursor: pointer;
  font-size: 14px;
}
.mob-sheet-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  padding: 8px 16px 16px;
}
.mob-sheet-link {
  display: flex;
  align-items: center;
  padding: 14px 10px;
  font-size: 14px;
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  min-height: 48px;
}
.mob-sheet-link:hover { color: var(--accent); }

/* ── Backdrop overlay ── */
.mob-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 299;
  background: rgba(0,0,0,.55);
}

/* ── Mobile-specific rules ── */
@media (max-width: 760px) {
  /* Show mobile controls, hide desktop nav in header */
  nav.main { display: none; }
  .mob-hd-ctrl { display: flex; }
  .logo-tagline { display: none; }

  /* Show bottom bar and backdrop */
  .mob-btmbar { display: flex; }
  .mob-overlay { display: block; animation: fadeIn .2s; }

  /* Ensure content is not hidden behind fixed bottom bar */
  body { padding-bottom: calc(64px + env(safe-area-inset-bottom)); }

  /* Toast: float above bottom bar */
  .toast { bottom: calc(80px + env(safe-area-inset-bottom)); }
}

/* ── Screen-reader-only utility ── */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border-width: 0;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  @keyframes fadeIn { from { opacity: 1; } }
}

/* ===== BUTTONS ===== */
.btn {
  border: none;
  border-radius: 8px;
  padding: 8px 15px;
  font-size: 13px;
  cursor: pointer;
  font-weight: 700;
  transition: opacity .15s;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 5px;
}
.btn:hover { opacity: .85; }
.btn-p { background: var(--accent); color: #fff; }
.btn-g { background: transparent; color: var(--text); border: 1px solid var(--border); }
.btn-o { background: transparent; color: var(--accent); border: 2px solid var(--accent); }
.btn-w { background: var(--surface-2); color: var(--text); border: 1px solid var(--border); }

/* ===== LAYOUT ===== */
main {
  max-width: 1120px;
  margin: 0 auto;
  padding: 24px 16px 60px;
  min-height: 60vh;
}
/* Legacy class kept for any direct usage */
.cn-main { max-width: 1120px; margin: 0 auto; padding: 24px 16px 60px; }

.crumb { font-size: 12px; color: var(--text-dim); margin-bottom: 14px; }
.crumb a { color: var(--accent); }
/* Home page h1 — deliberately small: the visual hero is the carousel below. */
.home-h1 { font-size: 15px; font-weight: 800; margin: 0 0 10px; line-height: 1.5; }
.home-h1-sub { display: inline-block; margin-left: 8px; font-size: 12px; font-weight: 400; color: var(--text-dim); }
.sec { margin-bottom: 40px; }
.sec-h {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 14px;
  gap: 10px;
  flex-wrap: wrap;
}
.sec-h h2 {
  font-size: 19px;
  border-left: 5px solid var(--accent);
  padding-left: 10px;
  color: var(--text);
  text-wrap: balance;
}
.sec-h .more { font-size: 13px; color: var(--accent); font-weight: 600; }

/* ===== HERO ===== */
.hero {
  background: var(--hero-bg);
  color: var(--text);
  border-radius: var(--radius-lg);
  padding: 34px 28px;
  margin-bottom: 30px;
  border: 1px solid var(--border);
}
.hero h1 {
  font-size: 24px;
  margin-bottom: 6px;
  color: var(--text);
  text-wrap: balance;
}
.hero p { color: var(--text-dim); font-size: 13.5px; margin-bottom: 18px; }
.hero .acts { display: flex; gap: 10px; flex-wrap: wrap; }

/* ===== GRID & CARDS ===== */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(245px, 1fr));
  gap: 14px;
}
.grid3 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 14px;
}

/* Area chips — plain GET links, so filtering works without JS and each area is
   a crawlable entry point. Whether a concert is reachable is decided by where
   it is before anything else, and the home page offered no way to say so. */
.area-chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 14px 0 4px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.area-chips::-webkit-scrollbar { display: none; }
.area-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  min-height: 36px;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
  transition: border-color .15s, background .15s, color .15s;
}
@media (hover: hover) and (pointer: fine) {
  .area-chip:hover {
    border-color: var(--accent);
    background: var(--accent-tint);
    color: var(--accent);
  }
}
.area-chip-n {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-dim);
}
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  transition: transform .15s;
  display: flex;
  flex-direction: column;
  color: var(--text);
  text-decoration: none;
  /* Soft elevation — makes cards lift off the light page ground */
  box-shadow: 0 1px 3px rgba(27,31,46,0.07);
}
/* hover lift はマウス等の細かいポインタでのみ。タッチ端末では tap 後に
   hover 状態が貼り付いてカードが浮いたままになる */
@media (hover: hover) and (pointer: fine) {
  .card:hover { transform: translateY(-2px); }
}
/* 44px の小さなサムネイルでは blur(18px) が箱に対して過大になる */
.cd-rail-rel-cover .cv-bg { filter: blur(6px) saturate(1.15); }
/* ビジュアル枠。aspect-ratio は必須 — px 固定 height にすると素材の縦横比に
   関係なく箱が決まり、はみ出した分が捨てられる。旧実装は 132px 固定 (実測
   347x132 = 2.63:1) で、縦長フライヤーの 73% を切り落としていた。
   16:9 の根拠は docs/DESIGN-DIRECTION-v2.md §3.3。 */
.cv {
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  color: #fff;
  position: relative;
  flex-shrink: 0;
  overflow: hidden;
}
/* 収集した実写画像を二重レイヤーで敷く。ブランドカバー (Cover) が最下層に残る
   ので、画像が 404/403/ORB で落ちてもカバーが見えるだけで済む (JS 不要)。

   .cv-bg  … 同じ画像を cover + blur で敷き、contain が残す余白を埋める
   .cv-img … 実画像。contain なので絶対に切れない

   フライヤーの縦横比は実測 0.71〜2.60 に散る。どの固定箱でも余白は必ず出るので、
   「切らずに、余白をぼかしで埋める」以外に全面表示を成立させる方法がない。
   背景を CSS background-image にしないのは、プリロードスキャナが background を
   見ないため。同じ <img> にすると 1 リクエストに重複排除される。 */
.cv-bg,
.cv-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}
.cv-bg {
  object-fit: cover;
  /* scale(1.12) は blur が箱の縁で薄くなるのを外へ逃がすため。省略不可。
     静的な blur なので will-change は付けない (常時レイヤー保持は無駄) */
  filter: blur(18px) saturate(1.15);
  transform: scale(1.12);
}
.cv-img {
  object-fit: contain;
}

.badges {
  position: absolute;
  top: 8px;
  left: 8px;
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  z-index: 2;
}
.bdg {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 99px;
  background: rgba(0,0,0,.65);
  color: #fff;
}
.bdg.hot   { background: var(--orange); }
.bdg.free  { background: var(--green); }
.bdg.gift  { background: #8b5cf6; }
.bdg.child { background: #0ea5e9; }
.bdg.pro   { background: var(--surface-2); border: 1px solid var(--border); color: var(--text-dim); }
.cb {
  padding: 11px 13px 13px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.cg { font-size: 11px; font-weight: 700; color: var(--accent); }
/* Card title: clamp to 2 lines, min-height locks card grid alignment */
.ct {
  font-size: 13.5px;
  font-weight: 700;
  line-height: 1.45;
  color: var(--text);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  min-height: calc(1.45em * 2);
}
.cm {
  font-size: 11.5px;
  color: var(--text-dim);
  margin-top: auto;
  padding-top: 6px;
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}
.counts {
  display: flex;
  gap: 10px;
  font-size: 11px;
  color: var(--text-dim);
  padding-top: 5px;
}
.counts .ic-wrap {
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

/* ===== LIST ROWS ===== */
.rows { display: flex; flex-direction: column; gap: 10px; }
.row {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 13px 16px;
  display: flex;
  align-items: center;
  gap: 13px;
  cursor: pointer;
  transition: transform .15s;
  text-decoration: none;
  color: var(--text);
  box-shadow: 0 1px 3px rgba(27,31,46,0.05);
}
.row:hover { transform: translateY(-1px); }
.rn {
  font-size: 20px;
  font-weight: 800;
  color: var(--text-dim);
  min-width: 30px;
  text-align: center;
  font-style: italic;
}
.rows .row:nth-child(1) .rn { color: var(--gold); }
.rows .row:nth-child(2) .rn { color: #9ca3af; }
.rows .row:nth-child(3) .rn { color: #b87333; }
.ri { flex: 1; min-width: 0; }
.rv { font-size: 11.5px; color: var(--text-dim); white-space: nowrap; }

/* ===== PANEL / FORMS ===== */
.panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: 0 1px 3px rgba(27,31,46,0.06);
}
.frm {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}
.fld label { display: block; font-size: 11px; font-weight: 700; color: var(--text-dim); margin-bottom: 4px; }
.fld input, .fld select, .fld textarea {
  width: 100%;
  padding: 9px 11px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 13.5px;
  background: var(--surface-2);
  color: var(--text);
  font-family: inherit;
}
.fld input::placeholder,
.fld textarea::placeholder { color: var(--text-dim); }
.fld.full { grid-column: 1 / -1; }
.chips { display: flex; flex-wrap: wrap; gap: 7px; margin: 8px 0; }
.chip {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 99px;
  padding: 5px 13px;
  font-size: 12.5px;
  cursor: pointer;
  color: var(--text-dim);
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  transition: opacity .15s;
}
.chip:hover { border-color: var(--accent); color: var(--accent); }
.chip.on { background: var(--accent); border-color: var(--accent); color: #fff; }
.cnt { font-size: 12.5px; color: var(--text-dim); margin: 10px 0; }
.empty {
  text-align: center;
  padding: 44px 16px;
  color: var(--text-dim);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.empty .e { font-size: 36px; margin-bottom: 6px; }

/* ===== DETAIL ===== */
/* 詳細ページのヒーロー。230px 固定をやめ aspect-ratio + max-height に。
   CardVisual 側が contain なので縦長フライヤーも全面が見える。 */
.dt-hero {
  aspect-ratio: 16 / 9;
  max-height: 70vh;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 64px;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.dt-body {
  background: var(--surface);
  border: 1px solid var(--border);
  border-top: none;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  padding: 26px 30px;
  color: var(--text);
}
.dt-body h1 {
  font-size: 22px;
  margin: 4px 0;
  color: var(--text);
  text-wrap: balance;
}
.dt-sub { color: var(--text-dim); font-size: 14px; margin-bottom: 14px; }
.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; margin: 12px 0; }
.tbl th {
  text-align: left;
  color: var(--text-dim);
  font-weight: 600;
  padding: 9px 12px 9px 0;
  width: 110px;
  vertical-align: top;
  white-space: nowrap;
}
.tbl td { padding: 9px 0; color: var(--text); }
.tbl tr { border-bottom: 1px solid var(--border); }
.reacts { display: flex; gap: 9px; margin: 16px 0; flex-wrap: wrap; }
.reactb {
  border: 2px solid var(--border);
  background: var(--surface);
  border-radius: 99px;
  padding: 8px 18px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  color: var(--text);
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  transition: opacity .15s;
}
.reactb.on { border-color: var(--accent); color: var(--accent); background: var(--accent-tint); }
.h3 {
  font-size: 15.5px;
  font-weight: 800;
  border-left: 4px solid var(--accent);
  padding-left: 9px;
  margin: 22px 0 10px;
  color: var(--text);
}
.plist li {
  list-style: none;
  padding: 8px 0;
  border-bottom: 1px dashed var(--border);
  font-size: 13.5px;
  color: var(--text);
}
.plist .comp { color: var(--text-dim); font-size: 12px; margin-left: 8px; }
.ln { color: var(--accent); cursor: pointer; font-weight: 600; }

/* ===== CALENDAR ===== */
.cal {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
}
.cal-hd { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.cal-hd b { font-size: 17px; color: var(--text); }
.cal table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.cal th { font-size: 11px; color: var(--text-dim); padding: 6px 0; }
.cal td {
  border: 1px solid var(--border);
  height: 64px;
  vertical-align: top;
  padding: 4px;
  font-size: 11.5px;
  cursor: pointer;
  color: var(--text);
}
.cal td:hover { background: var(--accent-tint); }
.cal td.sel { background: var(--accent-tint); outline: 2px solid var(--accent); }
.cal td .d { font-weight: 700; }
.cal td.today .d { color: var(--accent); }
.cal .ev {
  background: var(--accent);
  color: #fff;
  border-radius: 4px;
  font-size: 9.5px;
  padding: 0 3px;
  margin-top: 2px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* ===== MISC ===== */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--surface-2);
  color: var(--text);
  border: 1px solid var(--border);
  padding: 11px 22px;
  border-radius: 99px;
  font-size: 13px;
  z-index: 400;
  opacity: 0;
  transition: opacity .3s;
  pointer-events: none;
  box-shadow: 0 4px 16px rgba(27,31,46,0.12);
}
.toast.show { opacity: 1; }
.pill {
  display: inline-block;
  background: var(--accent-tint);
  color: var(--accent);
  font-size: 11px;
  font-weight: 700;
  border-radius: 99px;
  padding: 2px 10px;
  margin-right: 6px;
}
.two { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; }
@media (max-width: 840px) {
  .two { grid-template-columns: 1fr; }
  .dt-body { padding: 20px; }
}
.side .panel { padding: 15px; }
.side h3 { font-size: 14px; font-weight: 800; margin-bottom: 9px; color: var(--text); }
.mini {
  display: flex;
  gap: 9px;
  padding: 8px 0;
  border-bottom: 1px dashed var(--border);
  cursor: pointer;
  font-size: 12.5px;
  color: var(--text);
  text-decoration: none;
}
.mini .ic {
  width: 38px;
  height: 38px;
  border-radius: 8px;
  flex-shrink: 0;
  min-width: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 17px;
}
.prose {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px 30px;
  font-size: 14px;
  color: var(--text);
}
.prose h1 { font-size: 21px; margin-bottom: 14px; color: var(--text); text-wrap: balance; }
.prose h2 { font-size: 16px; margin: 18px 0 8px; color: var(--text); }
.prose p { margin-bottom: 10px; }
.prose ul { margin: 0 0 10px 20px; }

/* ===== FOOTER ===== */
footer {
  background: var(--footer-bg);
  color: var(--text-dim);
  padding: 34px 16px;
  font-size: 12px;
  margin-top: 40px;
  border-top: 1px solid var(--border);
}
.ft-in {
  max-width: 1120px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 22px;
}
.ft-in h4 { color: var(--text); font-size: 13px; margin-bottom: 9px; }
.ft-in a { display: block; padding: 3px 0; color: var(--text-dim); }
.ft-in a:hover { color: var(--accent); }
.copyright { text-align: center; margin-top: 26px; color: var(--text-dim); }

/* ===== BACKWARD COMPAT (.cn-*) ===== */
/* These classes are used by existing pages (topics, musician, search, detail). */

.cn-card {
  display: block;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin-bottom: 12px;
  color: var(--text);
  transition: transform .15s;
}
.cn-card:hover {
  transform: translateY(-2px);
  text-decoration: none;
}
.cn-card-title { font-weight: 700; margin: 0 0 4px; font-size: 13.5px; color: var(--text); }
.cn-meta { color: var(--text-dim); font-size: 11.5px; }
.cn-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 99px;
  background: var(--accent);
  color: #fff;
  margin-right: 6px;
}
.cn-body { white-space: pre-wrap; margin-top: 16px; font-size: 14px; line-height: 1.7; color: var(--text); }
.cn-footer { color: var(--text-dim); font-size: 0.8rem; padding: 24px 16px; text-align: center; }

/* ─── Memo / コンサートログ ────────────────────────────────────────────────── */
.memo {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin-bottom: 12px;
}
.memo-hd {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 8px;
}
.avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  text-transform: uppercase;
}
.memo-user { font-size: 13px; font-weight: 700; color: var(--text); }
.memo-date { font-size: 11.5px; color: var(--text-dim); }
.memo-c { font-size: 12.5px; color: var(--accent); margin-bottom: 6px; text-decoration: none; display: block; }
.memo-c:hover { text-decoration: underline; }
.memo-t {
  font-size: 13.5px;
  line-height: 1.65;
  color: var(--text);
  margin-bottom: 10px;
  white-space: pre-wrap;
  word-break: break-word;
}
.memo-ft {
  display: flex;
  align-items: center;
  font-size: 12px;
  color: var(--text-dim);
  gap: 8px;
  flex-wrap: wrap;
}

/* Type tags — colors fixed for AA contrast on light surfaces */
.tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 9px;
  border-radius: 9999px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.tag.support  { background: rgba(133,100,0,0.12);  color: var(--gold); }
.tag.heard    { background: rgba(37,99,235,0.12);   color: #1d4ed8; }
.tag.appeared { background: rgba(16,185,129,0.12);  color: #065f46; }

/* Dark theme restores the original light-on-dark tag colors */
@media (prefers-color-scheme: dark) {
  .tag.heard    { background: rgba(37,99,235,0.20);  color: #60a5fa; }
  .tag.appeared { background: rgba(16,185,129,0.20); color: #34d399; }
}
:root[data-theme="dark"] .tag.heard    { background: rgba(37,99,235,0.20);  color: #60a5fa; }
:root[data-theme="dark"] .tag.appeared { background: rgba(16,185,129,0.20); color: #34d399; }

/* ===== SEARCH RESULTS PAGE — BATCH 3 ===== */

/* Sticky search hero bar */
.srp-hero {
  position: sticky;
  top: 57px;          /* sits immediately below the sticky header */
  z-index: 90;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  /* Bleed out to full width, cancelling main's padding */
  margin: -24px -16px 20px;
  padding: 12px 16px;
}
/* After the breadcrumb the hero is not the first box in <main>, so there is no top
   padding to cancel: the -24px pulled it up over the breadcrumb (about 10px hidden). */
.crumb + .srp-hero { margin-top: 0; }
.srp-hero-inner {
  display: flex;
  gap: 8px;
  align-items: center;
}
.srp-hero-input {
  flex: 1;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  font-size: 15px;
  font-family: inherit;
  min-height: 44px;
}
.srp-hero-input::placeholder { color: var(--text-dim); }
.srp-hero-input:focus-visible { outline: 2px solid var(--accent); outline-offset: 0; border-radius: 10px; }
.srp-hero-btn { flex-shrink: 0; gap: 5px; }
.srp-hero-quick {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 10px;
}
/* Quick-filter chips in hero use existing .chip/.chip.on styles */
.srp-hero-quick .chip { min-height: 36px; font-size: 12px; }

/* ── Body layout ── */
.srp-body {
  display: flex;
  gap: 24px;
  align-items: flex-start;
}

/* ── Desktop filter rail ── */
.srp-rail {
  width: 224px;
  flex-shrink: 0;
  position: sticky;
  top: 120px;   /* below sticky header + sticky hero */
  max-height: calc(100vh - 130px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
.srp-rail-hd {
  font-size: 13px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}
.srp-rail-section { margin-bottom: 16px; }
.srp-rail-section-label {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--text-dim);
  margin-bottom: 7px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.srp-rail-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.srp-rail-chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border: 1px solid var(--border);
  border-radius: 99px;
  font-size: 11.5px;
  color: var(--text-dim);
  background: var(--surface-2);
  cursor: pointer;
  min-height: 30px;
  white-space: nowrap;
  position: relative;
  transition: border-color .12s, color .12s, background .12s;
}
.srp-rail-chip:hover { border-color: var(--accent); color: var(--accent); }
.srp-rail-chip.on,
.srp-rail-chip:has(input:checked) {
  background: var(--accent-tint);
  border-color: var(--accent);
  color: var(--accent);
}
@media (max-width: 899px) { .srp-rail { display: none; } }

/* ── Main results column ── */
.srp-main { flex: 1; min-width: 0; }

/* ── Mobile filter toggle ── */
.srp-mobile-filter { margin-bottom: 12px; }
@media (min-width: 900px) { .srp-mobile-filter { display: none; } }
.srp-mobile-filter > summary {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
  min-height: 44px;
  color: var(--text);
}
.srp-mobile-filter > summary::-webkit-details-marker { display: none; }
.srp-mobile-badge {
  background: var(--accent);
  color: #fff;
  font-size: 11px;
  padding: 1px 7px;
  border-radius: 99px;
  font-weight: 700;
}
.srp-mobile-chevron { margin-left: auto; color: var(--text-dim); }
details[open] .srp-mobile-chevron { transform: rotate(180deg); }
.srp-mobile-filter-content {
  background: var(--surface);
  border: 1px solid var(--border);
  border-top: none;
  border-radius: 0 0 var(--radius) var(--radius);
  padding: 14px;
}

/* ── Active filter chips ── */
.srp-active {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin-bottom: 12px;
}
.srp-active-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  background: var(--accent-tint);
  border: 1px solid var(--accent);
  border-radius: 99px;
  font-size: 12px;
  color: var(--accent);
  text-decoration: none;
  min-height: 30px;
  transition: opacity .15s;
}
.srp-active-chip:hover { opacity: 0.75; }
.srp-clear-all {
  font-size: 12px;
  color: var(--text-dim);
  text-decoration: underline;
  margin-left: 2px;
}
.srp-clear-all:hover { color: var(--accent); }

/* ── Sort bar (segmented control) ── */
.srp-sort {
  display: flex;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}
.srp-sort-btn {
  flex: 1;
  border: none;
  background: var(--surface);
  color: var(--text-dim);
  font-size: 12px;
  font-weight: 600;
  font-family: inherit;
  padding: 7px 10px;
  min-height: 36px;
  cursor: pointer;
  white-space: nowrap;
  border-right: 1px solid var(--border);
  transition: background .12s, color .12s;
}
.srp-sort-btn:last-child { border-right: none; }
.srp-sort-btn:hover { background: var(--surface-2); color: var(--text); }
.srp-sort-btn.on { background: var(--accent); color: #fff; }
.srp-sort-count {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}
.srp-count-text { font-size: 12px; color: var(--text-dim); }

/* ── Results grid with container query ── */
.srp-grid-wrap { container-type: inline-size; }
.srp-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
@container (min-width: 560px) {
  .srp-grid { grid-template-columns: repeat(2, 1fr); }
}
@container (min-width: 860px) {
  .srp-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ── Search result card ── */
.srp-card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
  transition: transform .15s;
  box-shadow: 0 1px 3px rgba(27,31,46,0.06);
}
@media (prefers-reduced-motion: reduce) { .srp-card { transition: none; } }
.srp-card:hover { transform: translateY(-2px); }
/* 検索結果カードのビジュアル。カード一覧と同じ 16:9 に揃える (px 固定を廃止) */
.srp-card-visual {
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
}
.srp-card-body {
  padding: 12px 14px 14px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.srp-card-title {
  font-size: 13.5px;
  font-weight: 700;
  line-height: 1.45;
  color: var(--text);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  min-height: calc(1.45em * 2);
}
.srp-card-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 11.5px;
  color: var(--text-dim);
}
.srp-card-meta-row {
  display: flex;
  align-items: center;
  gap: 5px;
}
.srp-card-performers {
  font-size: 11px;
  color: var(--text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Sale status badges — AA contrast on light surfaces ── */
.sale-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 99px;
  font-size: 10.5px;
  font-weight: 700;
  white-space: nowrap;
}
.sale-badge.active    { background: rgba(6,95,70,.10);   color: #065f46; border: 1px solid rgba(6,95,70,.22); }
.sale-badge.ended     { background: var(--surface-2); color: var(--text-dim); }
.sale-badge.undecided { background: rgba(146,64,14,.09); color: #92400e; border: 1px solid rgba(146,64,14,.20); }
.sale-badge.info      { background: var(--surface-2); color: var(--text-dim); }

/* Dark theme restores original badge colors */
@media (prefers-color-scheme: dark) {
  .sale-badge.active   { background: rgba(16,185,129,.15); color: #10b981; border-color: rgba(16,185,129,.30); }
  .sale-badge.undecided{ background: rgba(245,158,11,.12); color: #f59e0b; border-color: rgba(245,158,11,.25); }
}
:root[data-theme="dark"] .sale-badge.active   { background: rgba(16,185,129,.15); color: #10b981; border-color: rgba(16,185,129,.30); }
:root[data-theme="dark"] .sale-badge.undecided{ background: rgba(245,158,11,.12); color: #f59e0b; border-color: rgba(245,158,11,.25); }

/* ── Pagination ── */
.srp-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 24px;
  font-size: 13px;
}
.srp-page-link {
  padding: 8px 18px;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  background: var(--surface);
  text-decoration: none;
  font-weight: 600;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  transition: opacity .15s;
}
.srp-page-link:hover { opacity: 0.8; }
.srp-page-info { color: var(--text-dim); }

/* ── Empty state ── */
.srp-empty {
  text-align: center;
  padding: 48px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.srp-empty-icon { font-size: 40px; margin-bottom: 12px; line-height: 1; }
.srp-empty-title { font-size: 15px; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.srp-empty-text  { font-size: 13px; color: var(--text-dim); margin-bottom: 14px; }
.srp-empty-suggestions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }

/* ── Date inputs in rail/mobile filter ── */
.srp-date-input {
  width: 100%;
  padding: 7px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--text);
  font-size: 12px;
  font-family: inherit;
  margin-bottom: 6px;
  min-height: 36px;
}
.srp-date-input:focus-visible { outline: 2px solid var(--accent); outline-offset: 0; }

/* ── Skeleton loading ── */
.skel {
  background: linear-gradient(
    90deg,
    var(--surface) 25%,
    var(--surface-2) 50%,
    var(--surface) 75%
  );
  background-size: 200% 100%;
  animation: skel-shimmer 1.5s ease-in-out infinite;
  border-radius: 6px;
}
@media (prefers-reduced-motion: reduce) {
  .skel { animation: none; background: var(--surface-2); }
}
@keyframes skel-shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
.srp-skel-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.srp-skel-visual { height: 110px; }
.srp-skel-body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 8px; }
.skel-line { height: 12px; border-radius: 4px; }

/* ===== CONCERT DETAIL — BATCH 4 (CSS-only tabs + desktop 2-col) ===== */

/* Desktop 2-column layout */
.cd-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  align-items: start;
}

@media (min-width: 900px) {
  .cd-layout {
    grid-template-columns: 1fr 320px;
    gap: 28px;
  }
}

/* Right rail — hidden on mobile, sticky on desktop */
.cd-rail { display: none; }

@media (min-width: 900px) {
  .cd-rail {
    display: block;
    position: sticky;
    /* Header is 57px tall (see .srp-hero comment) + 16px breathing room. */
    top: 73px;
    align-self: start;
    max-height: calc(100vh - 73px - 16px);
    overflow-y: auto;
    scrollbar-width: thin;
  }
}

/* Rail cards */
.cd-rail-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-bottom: 14px;
  box-shadow: 0 1px 3px rgba(27,31,46,0.06);
}
.cd-rail-card > h3 {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  margin-bottom: 10px;
}
.cd-rail-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
  line-height: 1.35;
}
.cd-rail-sub {
  font-size: 12px;
  color: var(--text-dim);
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
}
.cd-rail-price {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}
/* Compact related-concert rows in rail */
.cd-rail-related {
  display: flex;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  color: var(--text);
  align-items: flex-start;
  transition: opacity .15s;
}
.cd-rail-related:last-of-type { border-bottom: none; padding-bottom: 0; }
.cd-rail-related:hover { opacity: .8; }
.cd-rail-rel-cover {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}
.cd-rail-rel-info { flex: 1; min-width: 0; }
.cd-rail-rel-title {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  line-height: 1.4;
  transition: color .15s;
}
.cd-rail-related:hover .cd-rail-rel-title { color: var(--accent); }
.cd-rail-rel-date {
  font-size: 11px;
  color: var(--text-dim);
  margin-top: 3px;
  display: flex;
  align-items: center;
  gap: 3px;
}

/* ── CSS-only segmented tabs ── */

/* Hidden radio inputs — accessible but invisible */
.dt-tab-r {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

/* Tab strip */
.dt-tablist {
  display: flex;
  border-bottom: 1px solid var(--border);
  gap: 0;
  margin: 20px -30px 0;   /* bleed to dt-body edges */
  padding: 0 30px;
  overflow-x: auto;
  scrollbar-width: none;
}
.dt-tablist::-webkit-scrollbar { display: none; }

/* Each tab label */
.dt-tablabel {
  display: inline-flex;
  align-items: center;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-dim);
  border-bottom: 3px solid transparent;
  white-space: nowrap;
  cursor: pointer;
  min-height: 44px;
  margin-bottom: -1px;   /* sit on top of bottom border */
  transition: color .15s, border-color .15s;
}
.dt-tablabel:hover { color: var(--text); }

/* Active state: checked radio → highlight corresponding label + show panel */
#dt-tab-0:checked ~ .dt-tablist label[for="dt-tab-0"],
#dt-tab-1:checked ~ .dt-tablist label[for="dt-tab-1"] {
  color: var(--text);
  border-bottom-color: var(--accent);
}

/* Tab panels — all hidden by default */
.dt-panels { padding-top: 20px; }
.dt-panel   { display: none; }

/* Show the panel whose radio is checked */
#dt-tab-0:checked ~ .dt-panels .dt-panel-0 { display: block; }
#dt-tab-1:checked ~ .dt-panels .dt-panel-1 { display: block; }

/* Mobile: narrower dt-body padding, tabs bleed fix */
@media (max-width: 899px) {
  .dt-tablist {
    margin-left: -20px;
    margin-right: -20px;
    padding-left: 20px;
    padding-right: 20px;
  }
}

[aria-disabled=true]{cursor:default} input:disabled{opacity:.6}
