/* =========================================================================
   HALLE8 — Public design system
   Black · White · sparingly Pink. DO LESS.
   All brand-tunable values live here as tokens (see §5, §6, §38, §39).
   ========================================================================= */

:root {
  /* ---- Color tokens -------------------------------------------------- */
  --black: #000000;
  --white: #ffffff;

  /* HALLE8 accent — saturated magenta. Change this one value to reskin. */
  --halle8-pink: #e6006e;

  --ink: var(--white);            /* default text on black */
  --ink-dim: rgba(255, 255, 255, 0.55);
  --ink-faint: rgba(255, 255, 255, 0.28);
  --hairline: rgba(255, 255, 255, 0.16);
  --bg: var(--black);

  /* ---- Type tokens --------------------------------------------------- */
  /* Impact is reserved for the logo / iconic "8" ONLY (§6). */
  --font-logo: "Impact", "Haettenschweiler", "Franklin Gothic Bold",
    "Arial Narrow Bold", sans-serif;
  /* Editorial / UI face. Futura PT is NOT bundled (licensing, §6) — a
     geometric sans fallback stack is used until licensed assets exist. */
  --font-sans: "Futura PT", "Futura", "Avenir Next", "Century Gothic",
    "Helvetica Neue", Arial, sans-serif;

  /* ---- Spacing / rhythm --------------------------------------------- */
  --page-x: 24px;
  --section-y: clamp(64px, 14vh, 160px);
  --max-w: 1080px;

  /* ---- Motion -------------------------------------------------------- */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---- Reset (minimal) ------------------------------------------------- */
*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-weight: 400;
  line-height: 1.35;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
}

a { color: inherit; text-decoration: none; }

img { max-width: 100%; display: block; }

/* Visible, restrained focus for keyboard users (§32) */
:focus-visible {
  outline: 2px solid var(--halle8-pink);
  outline-offset: 3px;
}

/* ---- Layout scaffolding --------------------------------------------- */
.wrap {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--page-x);
}

.site {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main { flex: 1 0 auto; }

/* =========================================================================
   Header / nav
   ========================================================================= */
.masthead {
  padding: 22px 0 18px;
}
.masthead .wrap {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
}

.logo {
  font-family: var(--font-logo);
  font-weight: 400;
  font-size: 26px;
  letter-spacing: 0.02em;
  line-height: 1;
  text-transform: uppercase;
}
.logo .eight { color: var(--halle8-pink); }

.nav {
  display: flex;
  gap: 22px;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
.nav a { transition: color 0.25s var(--ease); }
.nav a:hover,
.nav a[aria-current="page"] { color: var(--ink); }

/* =========================================================================
   Shared type utilities
   ========================================================================= */
.eyebrow {
  font-size: 12px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin: 0;
}
.accent { color: var(--halle8-pink); }

.display {
  font-family: var(--font-sans);
  font-weight: 800;               /* Futura PT Extra Bold → heaviest fallback */
  text-transform: uppercase;
  line-height: 0.92;
  letter-spacing: -0.01em;
  margin: 0;
}

/* =========================================================================
   Home hero
   ========================================================================= */
.hero {
  padding-top: clamp(40px, 12vh, 120px);
  padding-bottom: var(--section-y);
}
.hero__brand {
  font-family: var(--font-logo);
  text-transform: uppercase;
  font-size: clamp(72px, 24vw, 220px);
  line-height: 0.82;
  letter-spacing: 0.01em;
  margin: 0;
}
.hero__brand .eight { color: var(--halle8-pink); }
.hero__tag {
  margin: 22px 0 0;
  font-size: 13px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--ink-dim);
}

/* =========================================================================
   "Next" block (home) + event header (event page)
   ========================================================================= */
.next {
  border-top: 1px solid var(--hairline);
  padding-top: 40px;
  padding-bottom: var(--section-y);
}
.next__label {
  margin-bottom: 28px;
}

.event-title {
  font-weight: 800;
  text-transform: uppercase;
  line-height: 0.9;
  letter-spacing: -0.01em;
  margin: 0;
  font-size: clamp(44px, 13vw, 120px);
}
.event-title .no {
  display: block;              /* "NO." stays white; only the digits are pink */
}
.event-title .no .num { color: var(--halle8-pink); }

.meta {
  margin-top: 34px;
  display: grid;
  gap: 6px;
  font-size: 15px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
}
.meta .dim { color: var(--ink-dim); }

/* Lineup */
.lineup {
  margin-top: 44px;
  display: grid;
  gap: 2px;
}
.lineup__row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
  padding: 16px 0;
  border-top: 1px solid var(--hairline);
}
.lineup__row:last-child { border-bottom: 1px solid var(--hairline); }
.lineup__name {
  font-weight: 700;
  text-transform: uppercase;
  font-size: clamp(22px, 6vw, 34px);
  line-height: 1;
  letter-spacing: 0.01em;
}
.lineup__time {
  font-size: 12px;
  letter-spacing: 0.16em;
  color: var(--ink-dim);
  white-space: nowrap;
  text-transform: uppercase;
}

/* Set times without names — used until the line-up is announced (§2).
   Same .lineup system: when artists are confirmed, a .lineup__name moves
   in on the left and the slot returns to the right as .lineup__time. */
.lineup__slot {
  font-weight: 700;
  text-transform: uppercase;
  font-size: clamp(20px, 5.4vw, 30px);
  line-height: 1;
  letter-spacing: 0.02em;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;   /* digits stay in column */
  font-feature-settings: "tnum" 1;
}
/* Without names the rows carry little content — keep the block a poster
   column instead of letting "Closing" drift to the far page edge. */
.lineup--times { max-width: 560px; }

/* =========================================================================
   Call to action
   ========================================================================= */
.cta {
  margin-top: 48px;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 18px 28px;
  min-height: 56px;                /* generous touch target (§9, §32) */
  border: 1px solid var(--white);
  color: var(--white);
  font-size: 13px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  transition: background 0.28s var(--ease), color 0.28s var(--ease),
    border-color 0.28s var(--ease);
}
.cta:hover {
  background: var(--white);
  color: var(--black);
}
.cta__mark { color: var(--halle8-pink); transition: color 0.28s var(--ease); }
.cta:hover .cta__mark { color: var(--black); }

/* =========================================================================
   Footer
   ========================================================================= */
.foot {
  flex-shrink: 0;
  border-top: 1px solid var(--hairline);
  padding: 28px 0 40px;
}
.foot .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  justify-content: space-between;
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
.foot a:hover { color: var(--ink-dim); }
.foot__links { display: flex; gap: 20px; }

/* =========================================================================
   Access request form
   ========================================================================= */
.form-intro { padding-top: clamp(40px, 10vh, 96px); }
.form-intro .event-title { font-size: clamp(38px, 11vw, 92px); }

.form {
  margin-top: 48px;
  padding-bottom: var(--section-y);
  max-width: 520px;
}
.field { margin-bottom: 26px; }
.field label {
  display: block;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 10px;
}
.field .opt { color: var(--ink-faint); }
.field input {
  width: 100%;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--hairline);
  color: var(--white);
  font-family: var(--font-sans);
  font-size: 18px;
  letter-spacing: 0.02em;
  padding: 12px 2px;
  min-height: 48px;
  transition: border-color 0.25s var(--ease);
}
.field input::placeholder { color: var(--ink-faint); }
.field input:focus {
  outline: none;
  border-bottom-color: var(--halle8-pink);
}
.field input:invalid:not(:placeholder-shown) {
  border-bottom-color: var(--halle8-pink);
}

/* Honeypot — visually and physically removed, still submitted for bots. */
.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.form__error {
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--halle8-pink);
  margin: 0 0 20px;
}

.form__note {
  font-size: 11px;
  line-height: 1.6;
  letter-spacing: 0.06em;
  color: var(--ink-faint);
  text-transform: uppercase;
  margin: 8px 0 30px;
}

.submit {
  appearance: none;
  cursor: pointer;
  background: var(--white);
  color: var(--black);
  border: 1px solid var(--white);
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  padding: 20px 30px;
  min-height: 56px;
  width: 100%;
  transition: background 0.25s var(--ease), color 0.25s var(--ease);
}
.submit:hover { background: transparent; color: var(--white); }

/* Confirmation state (shown after submit) */
.confirm {
  margin-top: 48px;
  padding-bottom: var(--section-y);
  max-width: 520px;
}
.confirm .status {
  display: inline-block;
  font-weight: 700;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  font-size: 13px;
  color: var(--halle8-pink);
  border: 1px solid var(--halle8-pink);
  padding: 12px 18px;
  margin-bottom: 26px;
}
.confirm p {
  font-size: 14px;
  line-height: 1.7;
  letter-spacing: 0.04em;
  color: var(--ink-dim);
  text-transform: uppercase;
}
.hidden { display: none !important; }

/* =========================================================================
   Legal / text pages (Impressum, Datenschutz)
   ========================================================================= */
.legal { padding-top: clamp(40px, 10vh, 96px); padding-bottom: var(--section-y); }
.legal h1 {
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  line-height: 0.95;
  margin: 0 0 40px;
  /* Sized so long words (e.g. "DATENSCHUTZ") never overflow narrow screens. */
  font-size: clamp(30px, 8.5vw, 72px);
  overflow-wrap: break-word;
}
.legal__block { margin-bottom: 34px; max-width: 560px; }
.legal__block .eyebrow { margin-bottom: 12px; }
.legal p {
  margin: 0;
  font-size: 16px;
  line-height: 1.65;
  letter-spacing: 0.02em;
  color: var(--ink);
}
.legal p + p { margin-top: 14px; }
.legal a { border-bottom: 1px solid var(--hairline); }
.legal a:hover { border-bottom-color: var(--halle8-pink); }
.legal .todo { color: var(--halle8-pink); }
.legal ul { margin: 10px 0 0; padding-left: 18px; }
.legal li {
  font-size: 16px;
  line-height: 1.6;
  letter-spacing: 0.02em;
  color: var(--ink);
  margin-bottom: 6px;
}
.legal .stand { color: var(--ink-dim); font-size: 13px; letter-spacing: 0.06em; }

/* =========================================================================
   Restrained reveal (§8) — fade + slight rise. Disabled for reduced motion.
   Progressive enhancement: the hidden state applies ONLY when JS is active
   (root gets a `.js` class). Without JS, all content is fully visible.
   ========================================================================= */
.js .reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.js .reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* =========================================================================
   Intro — the "8" appears in white, charges up with magenta from the
   bottom, then calmly shrinks and glides into the header logo. Plays once
   per session; skipped without JS, on repeat visits, and for
   prefers-reduced-motion (decided in the head script).
   ========================================================================= */
.intro { display: none; }

.intro-play .intro {
  display: flex;
  position: fixed;
  inset: 0;
  z-index: 100;
  align-items: center;
  justify-content: center;
  background: var(--black);
  transition: background 0.5s var(--ease);
  /* Safety net: if app.js never runs, the overlay releases the page. */
  animation: introSafety 0s linear 6s forwards;
}

.intro__eight {
  font-family: var(--font-logo);
  font-size: clamp(140px, 42vmin, 340px);
  line-height: 1;
  color: var(--white);
  opacity: 0;
  transition:
    opacity 0.65s var(--ease),
    background-position 1.35s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform, opacity, background-position;
}

/* The magenta "charge": the glyph is clipped over a two-tone gradient
   (bottom half magenta, top half white, double height). Sliding the
   background window makes the magenta rise through the 8 from below. */
@supports (-webkit-background-clip: text) or (background-clip: text) {
  .intro__eight {
    color: transparent;
    background-image: linear-gradient(
      to top,
      var(--halle8-pink) 49.5%,
      var(--white) 50.5%
    );
    background-size: 100% 200%;
    background-position: 0 0;            /* fully white */
    -webkit-background-clip: text;
    background-clip: text;
  }
}

/* Stage 1 — the 8 appears, white. */
.intro--appear .intro__eight { opacity: 1; }

/* Stage 2 — charge: magenta rises bottom → top. */
.intro--charge .intro__eight { background-position: 0 100%; }

/* Stage 3 — charged: shrink and glide into the header logo
   (transform set inline by JS; the page fades in beneath). */
.intro--fly { background: transparent; }

@keyframes introSafety {
  to { opacity: 0; visibility: hidden; pointer-events: none; }
}

/* =========================================================================
   Larger viewports — adapt, don't redecorate (mobile first, §9)
   ========================================================================= */
@media (min-width: 720px) {
  :root { --page-x: 48px; }
  .nav { gap: 30px; }
  .meta { grid-template-columns: repeat(2, auto); gap: 10px 64px; justify-content: start; }
}

@media (min-width: 1040px) {
  :root { --page-x: 64px; }
}
