/* =====================================================================
   WAVES — css/events.css
   EVENTS ページ固有のレイアウト/装飾。すべて :root トークンで構築。
   Riso-zine：非対称12カラム、刷りズレ、1pxヘアライン、档案インデックス。
   ===================================================================== */

/* ── Section rhythm ─────────────────────────────────────── */
.scene { position: relative; }
.section-title { margin-top: var(--space-2); }
.jp-head.section-title { font-size: var(--step-2); line-height: 1.18; }

/* Body max-width tuned so 8-12 カラムの答え が読みやすい */
.residents__lead p,
.lineup__note p { max-width: 40ch; color: var(--color-fg); }

/* =====================================================================
   HERO
   ===================================================================== */
.hero {
  display: flex;
  align-items: flex-end;
  padding-block: clamp(7rem, 12vh, 12rem) var(--space-6);
  overflow: clip;
}
.hero__inner {
  position: relative;
  z-index: 3;
  width: 100%;
}
.hero__kicker { color: var(--color-muted); margin-bottom: var(--space-3); }

.hero__title {
  font-size: var(--step-mega);
  line-height: 0.86;
  letter-spacing: -0.04em;
  /* bleed slightly off the left edge on purpose */
  margin-left: -0.02em;
}

.hero__body {
  max-width: 46ch;
  margin-top: var(--space-4);
  grid-column: auto;
}

/* off-canvas ghost number */
.hero__ghost {
  top: 14vh;
  right: -2vw;
  font-size: clamp(8rem, 26vw, 30rem);
  z-index: 1;
}

/* Rotating 45rpm disc — echo of the signature 針 origin */
.hero__disc {
  position: absolute;
  top: clamp(4rem, 12vh, 10rem);
  right: clamp(1.5rem, 8vw, 9rem);
  width: clamp(9rem, 20vw, 20rem);
  aspect-ratio: 1;
  border-radius: 50%;
  z-index: 2;
  background:
    repeating-radial-gradient(circle at 50% 50%,
      rgba(22,19,15,0.0) 0 3px,
      rgba(22,19,15,0.12) 3px 4px),
    conic-gradient(from 0deg, #16130f, #241f18 30%, #16130f 60%, #2a241c 85%, #16130f);
  box-shadow: inset 0 0 0 1px rgba(22,19,15,0.4);
  animation: spin45 6s linear infinite;
  will-change: transform;
}
.hero__disc-label {
  position: absolute;
  inset: 34%;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 42%, var(--klein-blue), #1a279e);
  box-shadow: inset 0 0 0 1px rgba(242,233,216,0.25);
}
.hero__disc-label::after {
  content: "45";
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: clamp(0.6rem, 1.6vw, 1rem);
  letter-spacing: 0.08em;
  color: var(--color-on-surface);
}
.hero__disc-dot {
  position: absolute;
  top: 50%; left: 50%;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--color-accent);
  transform: translate(-50%, -50%);
  z-index: 2;
}
@keyframes spin45 { to { transform: rotate(360deg); } }

.hero__vlabel {
  position: absolute;
  top: 50%;
  right: clamp(0.6rem, 2vw, 2rem);
  transform: translateY(-50%);
  z-index: 3;
  height: max-content;
}

.scroll-cue {
  display: inline-flex;
  align-items: center;
  gap: 0.9em;
  margin-top: var(--space-5);
  color: var(--color-muted);
}
.scroll-cue .mono { color: inherit; }
.scroll-cue__line {
  display: block;
  width: clamp(3rem, 8vw, 6rem);
  height: 1px;
  background: var(--color-fg);
  transform-origin: left;
  animation: cue-draw 2.4s var(--ease-inout-power4) infinite;
}
@keyframes cue-draw {
  0%, 100% { transform: scaleX(0.2); opacity: 0.4; }
  50% { transform: scaleX(1); opacity: 1; }
}

/* =====================================================================
   LINEUP — 档案風リスト
   ===================================================================== */
.lineup__head { margin-bottom: var(--space-4); align-items: end; }
.lineup__note { align-self: end; }

.lineup__list { border-top: 1px solid var(--color-hairline); }
.night { border-bottom: 1px solid var(--color-hairline); }

.night__link {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(8rem, 12vw) 1fr auto;
  align-items: center;
  gap: clamp(1rem, 3vw, 3rem);
  padding: clamp(1.4rem, 3vw, 2.6rem) clamp(0.6rem, 2vw, 1.6rem);
  transition: color 0.5s var(--ease-out-expo);
  overflow: hidden;
}
/* Klein-blue wipe on hover, drawn from the left */
.night__link::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--color-surface);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.55s var(--ease-inout-power4);
  z-index: 0;
}
.night__link > * { position: relative; z-index: 1; }
.night__link:hover,
.night__link:focus-visible { color: var(--color-on-surface); }
.night__link:hover::before,
.night__link:focus-visible::before { transform: scaleX(1); }

.night__idx {
  font-size: clamp(2.4rem, 5vw, 4.4rem);
  color: var(--color-muted);
  transition: color 0.5s var(--ease-out-expo);
}
.night__link:hover .night__idx,
.night__link:focus-visible .night__idx { color: var(--color-accent); }

.night__meta { display: flex; flex-direction: column; gap: 0.3em; color: var(--color-muted); }
.night__link:hover .night__meta,
.night__link:focus-visible .night__meta { color: var(--color-on-surface); }
.night__time { color: var(--color-accent); }

.night__main { display: flex; flex-direction: column; gap: 0.4em; }
.night__title {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: var(--step-1);
  line-height: 1.15;
  letter-spacing: 0.01em;
  font-feature-settings: "palt" 1;
}
.night__en {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.62em;
  letter-spacing: 0.1em;
  color: var(--color-muted);
  margin-left: 0.4em;
}
.night__link:hover .night__en,
.night__link:focus-visible .night__en { color: var(--color-on-surface); }
.night__desc { font-size: var(--step-0); line-height: 1.6; max-width: 44ch; }

.night__go { font-size: var(--step-1); transition: transform 0.5s var(--ease-out-expo); }
.night__link:hover .night__go,
.night__link:focus-visible .night__go { transform: translateX(0.4em); color: var(--color-accent); }

/* =====================================================================
   RESIDENTS — 非対称に重なるSVGポートレート
   ===================================================================== */
.residents { padding-block: var(--space-4); }
.residents__count {
  position: absolute;
  top: clamp(-2rem, -2vw, -1rem);
  right: var(--page-inline);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(10rem, 34vw, 34rem);
  line-height: 0.7;
  letter-spacing: -0.05em;
  color: transparent;
  -webkit-text-stroke: 1px var(--color-hairline);
  z-index: 0;
  pointer-events: none;
  user-select: none;
}
.residents__head { margin-bottom: var(--space-5); align-items: end; position: relative; z-index: 1; }
.residents__lead { align-self: end; }

.residents__grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--gutter);
  row-gap: var(--space-4);
  align-items: start;
}
.resident { position: relative; }
.resident--a { grid-column: 1 / 6; }
.resident--b { grid-column: 6 / 11; margin-top: var(--space-6); }
.resident--c { grid-column: 3 / 9; margin-top: calc(var(--space-4) * -0.4); }

.resident__inner {
  position: relative;
  background: var(--color-bg);
  border: 1px solid var(--color-hairline);
  padding: var(--space-3);
  overflow: hidden;
}
.resident--a .resident__inner { background: var(--color-surface); color: var(--color-on-surface); border-color: transparent; }
.resident--a .resident__note { color: rgba(242,233,216,0.82); }
.resident--a .resident__role { color: var(--color-accent); }
.resident--b .resident__inner { background: var(--color-fg); color: var(--color-bg); border-color: transparent; }
.resident--b .resident__note { color: rgba(242,233,216,0.72); }

.resident__spine {
  position: absolute;
  top: var(--space-2);
  right: var(--space-2);
  color: currentColor;
  opacity: 0.55;
  height: max-content;
}
.resident__face {
  width: clamp(6rem, 12vw, 11rem);
  height: auto;
  color: currentColor;
  margin: var(--space-2) 0 var(--space-3);
  opacity: 0.9;
}
.resident__id { display: flex; flex-direction: column; gap: 0.5em; }
.resident__name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: var(--step-2);
  line-height: 0.9;
  letter-spacing: -0.02em;
}
.resident__role { font-size: var(--step--1); }
.resident__note { font-size: var(--step-0); line-height: 1.75; max-width: 32ch; }

/* =====================================================================
   JOIN — 2カラム対比（来る/回す）on Klein-blue panel
   ===================================================================== */
.join {
  padding-block: var(--space-6);
  overflow: clip;
}
.join__ghost {
  color: var(--color-on-surface);
  opacity: 0.06;
  top: 8%;
  left: -1vw;
  font-size: clamp(7rem, 24vw, 26rem);
}
.join__head { position: relative; z-index: 1; margin-bottom: var(--space-5); }
.join__head .mono { color: var(--color-accent); }
.join__title { color: var(--color-on-surface); }
.section-title.join__title { font-size: var(--step-3); line-height: 1.1; }

.join__cols {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--gutter);
  align-items: start;
}
.join__col {
  border-top: 1px solid var(--color-hairline-light);
  padding-top: var(--space-3);
}
.join__col:nth-child(2) { margin-top: var(--space-5); }
.join__idx { color: var(--color-on-surface); opacity: 0.55; display: block; margin-bottom: var(--space-2); }
.join__sub {
  color: var(--color-on-surface);
  font-size: var(--step-1);
  margin-bottom: var(--space-2);
}
.join__body {
  color: rgba(242,233,216,0.9);
  font-size: var(--step-0);
  line-height: 1.85;
  max-width: 38ch;
  margin-bottom: var(--space-3);
}
.join__facts { display: flex; flex-direction: column; gap: 0.6em; color: var(--color-on-surface); }
.join__facts li { position: relative; padding-left: 1.4em; }
.join__facts li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.55em;
  width: 0.7em; height: 1px;
  background: var(--color-accent);
}

.join__cta {
  position: relative;
  z-index: 1;
  margin-top: var(--space-5);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3);
}
.join__cta-note { color: rgba(242,233,216,0.7); max-width: 30ch; }

/* =====================================================================
   FOOTER — 到達点
   ===================================================================== */
.site-footer {
  position: relative;
  padding-block: var(--space-6) var(--space-4);
  overflow: clip;
}
.footer__rule { margin-bottom: var(--space-3); }
.footer__top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}
.footer__kicker { color: var(--color-muted); }
.footer__spine { color: var(--color-muted); height: max-content; }

.footer__big {
  font-family: var(--font-display);
  font-weight: 800;
  text-transform: none;
  font-size: clamp(3.4rem, 13vw, 13rem);
  line-height: 0.92;
  letter-spacing: -0.03em;
  font-feature-settings: "palt" 1;
  margin: var(--space-3) 0 var(--space-5);
}
.footer__en {
  font-family: var(--font-body);
  font-weight: 700;
}

.footer__grid { align-items: start; row-gap: var(--space-4); }
.footer__addr { line-height: 1.9; }
.footer__addr p { color: var(--color-fg); }
.footer__nav {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  align-items: flex-start;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--step-1);
  text-transform: uppercase;
  letter-spacing: -0.01em;
}
@media (min-width: 721px) {
  .footer__nav { align-items: flex-end; text-align: right; }
}

.footer__base {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-5);
  padding-top: var(--space-2);
  border-top: 1px solid var(--color-hairline);
  color: var(--color-muted);
}

/* =====================================================================
   RESPONSIVE
   ===================================================================== */
@media (max-width: 1024px) {
  .resident--a { grid-column: 1 / 8; }
  .resident--b { grid-column: 6 / 13; margin-top: var(--space-5); }
  .resident--c { grid-column: 2 / 10; }
}

@media (max-width: 720px) {
  .hero { padding-block: clamp(6rem, 14vh, 9rem) var(--space-5); }
  .hero__disc { top: clamp(4.5rem, 14vh, 7rem); right: 1rem; width: clamp(7rem, 30vw, 10rem); }
  .hero__vlabel {
    position: static;
    transform: none;
    display: inline-block;
    margin-top: var(--space-4);
  }
  .hero__body { max-width: none; }

  .night__link {
    grid-template-columns: auto 1fr;
    grid-template-areas:
      "idx meta"
      "idx main"
      "idx go";
    gap: 0.6rem 1rem;
    align-items: start;
    padding-block: 1.4rem;
  }
  .night__idx { grid-area: idx; font-size: 2.6rem; align-self: start; }
  .night__meta { grid-area: meta; flex-direction: row; gap: 1em; flex-wrap: wrap; }
  .night__main { grid-area: main; }
  .night__go { grid-area: go; }
  .night__desc { max-width: none; }

  .residents__grid { grid-template-columns: 1fr; }
  .resident--a, .resident--b, .resident--c {
    grid-column: 1 / -1;
    margin-top: 0;
  }
  .resident--b { margin-top: 0; }
  .residents__count { font-size: clamp(8rem, 46vw, 16rem); top: -1rem; }
  .resident__spine {
    position: static;
    display: inline-block;
    margin-bottom: var(--space-1);
    letter-spacing: 0.14em;
  }

  .join__cols { grid-template-columns: 1fr; gap: var(--space-4); }
  .join__col:nth-child(2) { margin-top: 0; }
  .join__body { max-width: none; }

  .footer__top { align-items: center; }
  .footer__spine { letter-spacing: 0.14em; }
  .footer__base { flex-direction: column; gap: 0.4em; }
}

@media (max-width: 480px) {
  .hero__title { font-size: clamp(3.6rem, 22vw, 6rem); }
  .brandmark { font-size: var(--step-0); }
  .site-nav { gap: 0.85rem; }
  .night__meta { flex-direction: column; gap: 0.2em; }
}

/* Large screens: keep the composition inside the designed shell,
   let the disc + ghost breathe rather than stretch. */
@media (min-width: 1900px) {
  .hero__ghost { right: 2vw; }
}

/* =====================================================================
   REDUCED MOTION — page-local safety
   ===================================================================== */
@media (prefers-reduced-motion: reduce) {
  .hero__disc { animation: none !important; }
  .scroll-cue__line { animation: none !important; transform: scaleX(1); opacity: 0.6; }
}
