/* =========================================================================
   PHI GALLERY — design system
   DIY poster art: dark ground, bold display face, show flyers as the stars.
   Motif: φ (the golden ratio, 1.618) drives the type & spacing rhythm.
   Dark-committed, mobile-first, zero framework JS.
   ========================================================================= */

/* Fonts (Anton + Space Grotesk) are loaded via <link> in <head>; the stacks
   below fall back gracefully to a condensed system face if they don't load. */

/* ---- Design tokens ------------------------------------------------------- */
:root {
  /* Ground & ink */
  --ink:        #0b0b0d;
  --ink-2:      #131317;
  --ink-3:      #1b1b21;
  --ink-4:      #26262e;
  --line:       rgba(244, 241, 234, 0.12);
  --line-soft:  rgba(244, 241, 234, 0.07);

  /* Paper (text) */
  --paper:      #f4f1ea;
  --paper-dim:  #b7b3aa;
  --paper-faint:#8a877f;

  /* Accents — φ gold + ember */
  --gold:       #e8b84b;
  --gold-bright:#f7d179;
  --gold-deep:  #b8892a;
  --ember:      #ff5a3c;
  --ember-soft: rgba(255, 90, 60, 0.14);

  /* Semantic */
  --focus:      #8ecaff;

  /* Type */
  --font-display: "Anton", "Archivo Narrow", "Oswald", "Arial Narrow", system-ui, sans-serif;
  --font-body: "Space Grotesk", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-mono: ui-monospace, "SFMono-Regular", "Menlo", "Consolas", monospace;

  /* Fluid type scale (base is comfortable for long reads) */
  --fs-xs:   clamp(0.72rem, 0.70rem + 0.10vw, 0.78rem);
  --fs-sm:   clamp(0.83rem, 0.80rem + 0.14vw, 0.92rem);
  --fs-base: clamp(1.00rem, 0.97rem + 0.18vw, 1.10rem);
  --fs-lg:   clamp(1.18rem, 1.10rem + 0.40vw, 1.40rem);
  --fs-xl:   clamp(1.45rem, 1.28rem + 0.85vw, 1.95rem);
  --fs-2xl:  clamp(1.95rem, 1.55rem + 2.00vw, 3.05rem);
  --fs-3xl:  clamp(2.6rem, 1.9rem + 3.4vw, 4.6rem);
  --fs-hero: clamp(3.0rem, 1.9rem + 6.2vw, 7.2rem);

  /* Spacing — loosely φ-stepped */
  --sp-1: 0.32rem;
  --sp-2: 0.52rem;
  --sp-3: 0.84rem;
  --sp-4: 1.36rem;
  --sp-5: 2.2rem;
  --sp-6: 3.56rem;
  --sp-7: 5.76rem;

  --wrap: 74rem;
  --wrap-narrow: 46rem;
  --radius: 4px;
  --radius-lg: 8px;

  --shadow: 0 2px 6px rgba(0,0,0,0.4), 0 14px 40px rgba(0,0,0,0.35);
  --ring: 0 0 0 3px rgba(232, 184, 75, 0.35);

  color-scheme: dark;
}

/* ---- Reset -------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; background-color: var(--ink); }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

body {
  font-family: var(--font-body);
  font-size: var(--fs-base);
  line-height: 1.65;
  color: var(--paper);
  background-color: var(--ink);
  background-image:
    radial-gradient(1200px 600px at 15% -10%, rgba(232,184,75,0.06), transparent 60%),
    radial-gradient(900px 500px at 100% 0%, rgba(255,90,60,0.05), transparent 55%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Print grain over everything — the whole site reads like one riso run.
   Decorative only: pointer-events off, soft-light so text contrast survives. */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='0.55'/%3E%3C/svg%3E");
  opacity: 0.28;
  mix-blend-mode: soft-light;
}

img, svg, video { display: block; max-width: 100%; height: auto; }
img { background: var(--ink-2); }
/* eleventy-img wraps optimized images in <picture>; keep it out of layout so
   object-fit / sizing rules apply straight to the inner <img>. */
picture { display: contents; }
a { color: var(--gold-bright); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--gold); }
ul, ol { padding-left: 1.2em; }

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
  border-radius: 2px;
}

::selection { background: var(--gold); color: var(--ink); }

/* ---- Typography --------------------------------------------------------- */
h1, h2, h3, h4 { line-height: 1.02; font-weight: 400; text-wrap: balance; }

.display, h1.display {
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.005em;
  font-weight: 400;
}

.kicker {
  font-family: var(--font-body);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-size: var(--fs-sm);
  color: var(--gold);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5ch;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: var(--fs-xs);
  color: var(--paper-dim);
}

.lede { font-size: var(--fs-lg); color: var(--paper-dim); max-width: 46ch; }

/* ---- Layout ------------------------------------------------------------- */
.wrap { width: min(100% - 2.4rem, var(--wrap)); margin-inline: auto; }
.wrap-narrow { width: min(100% - 2.4rem, var(--wrap-narrow)); margin-inline: auto; }
.section { padding-block: var(--sp-6); }
.section--tight { padding-block: var(--sp-5); }
.stack > * + * { margin-top: var(--sp-4); }

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: var(--sp-3);
  margin-bottom: var(--sp-5);
  padding-bottom: var(--sp-3);
  /* Hand-drawn marker line instead of a hairline rule */
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='7' viewBox='0 0 120 7'%3E%3Cpath d='M0 3.5 Q15 1 30 3.5 T60 3.5 T90 3.5 T120 3.5' fill='none' stroke='%23e8b84b' stroke-width='1.6' stroke-linecap='round' opacity='0.5'/%3E%3C/svg%3E")
    left bottom repeat-x;
}
.section-head h2 {
  font-family: var(--font-display);
  text-transform: uppercase;
  font-size: var(--fs-2xl);
  letter-spacing: 0.01em;
  /* Off-register second ink pass */
  text-shadow: 0.05em 0.05em 0 rgba(255, 90, 60, 0.3);
}
.section-head .link-more { font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em; font-size: var(--fs-sm); }

.grid { display: grid; gap: var(--sp-4); }
.grid--3 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 20rem), 1fr)); }
.grid--2 { grid-template-columns: repeat(auto-fill, minmax(min(100%, 26rem), 1fr)); }
.grid--artists { grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr)); }

/* ---- Skip link ---------------------------------------------------------- */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  background: var(--gold);
  color: var(--ink);
  padding: 0.6rem 1rem;
  font-weight: 700;
}
.skip-link:focus { left: 0.6rem; top: 0.6rem; }

/* ---- Announcement banner ------------------------------------------------ */
.banner {
  background: var(--ember);
  color: #180a06;
  text-align: center;
  font-weight: 600;
  font-size: var(--fs-sm);
  padding: 0.55rem 1rem;
}
.banner a { color: #180a06; text-decoration: underline; }

/* ---- Header ------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: color-mix(in srgb, var(--ink) 88%, transparent);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--line-soft);
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  min-height: 4.2rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--paper);
  text-decoration: none;
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 1.5rem;
  line-height: 1;
}
.brand:hover { color: var(--paper); }
.brand picture { display: inline-flex; flex: none; }
.brand__mark { width: 2.1rem; height: 2.1rem; flex: none; }
img.brand__mark { border-radius: 5px; object-fit: cover; background: none; } /* header: real logo badge */
span.brand__mark { color: var(--gold); }                                    /* footer: gold φ glyph */
.brand__mark svg { width: 100%; height: 100%; }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  color: var(--paper);
  border-radius: var(--radius);
  padding: 0.5rem 0.7rem;
  font: inherit;
  cursor: pointer;
  align-items: center;
  gap: 0.5ch;
}
.nav-toggle svg { width: 1.2rem; height: 1.2rem; }

.primary-nav ul {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.2rem;
  padding: 0;
  margin: 0;
}
.primary-nav a {
  display: inline-block;
  padding: 0.5rem 0.8rem;
  color: var(--paper-dim);
  text-decoration: none;
  font-weight: 600;
  font-size: var(--fs-sm);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-radius: var(--radius);
}
.primary-nav a:hover { color: var(--paper); background: var(--ink-3); }
.primary-nav a[aria-current="page"] { color: var(--gold); }
.primary-nav a[aria-current="page"]::after {
  content: "";
  display: block;
  height: 2px;
  background: var(--gold);
  margin-top: 2px;
  border-radius: 2px;
}

@media (max-width: 860px) {
  .nav-toggle { display: inline-flex; }
  .primary-nav {
    position: absolute;
    left: 0; right: 0; top: 100%;
    background: var(--ink-2);
    border-bottom: 1px solid var(--line);
    display: none;
    padding: var(--sp-3) 0 var(--sp-4);
  }
  .primary-nav[data-open="true"] { display: block; }
  .primary-nav ul { flex-direction: column; align-items: stretch; gap: 0; width: min(100% - 2.4rem, var(--wrap)); margin-inline: auto; }
  .primary-nav a { padding: 0.85rem 0.6rem; border-bottom: 1px solid var(--line-soft); font-size: var(--fs-base); }
  .primary-nav a[aria-current="page"]::after { display: none; }
}

/* ---- Buttons ------------------------------------------------------------ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55ch;
  font-family: var(--font-body);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: var(--fs-sm);
  text-decoration: none;
  padding: 0.8rem 1.35rem;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.08s ease, background 0.15s ease, color 0.15s ease;
  line-height: 1;
}
.btn:active { transform: translateY(1px); }
/* Screen-print offset: a second ink layer that shifts when you press */
.btn--primary { background: var(--gold); color: var(--ink); box-shadow: 3px 3px 0 0 var(--ember); }
.btn--primary:hover { background: var(--gold-bright); color: var(--ink); transform: translate(-1px, -1px); box-shadow: 4px 4px 0 0 var(--ember); }
.btn--primary:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 0 var(--ember); }
.btn--ember { background: var(--ember); color: #180a06; box-shadow: 3px 3px 0 0 var(--gold-deep); }
.btn--ember:hover { filter: brightness(1.08); color: #180a06; transform: translate(-1px, -1px); box-shadow: 4px 4px 0 0 var(--gold-deep); }
.btn--ember:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 0 var(--gold-deep); }
.btn--ghost { background: transparent; color: var(--paper); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--gold); border-style: dashed; color: var(--gold); }
.btn--sm { padding: 0.55rem 0.9rem; font-size: var(--fs-xs); }

/* ---- Tags / badges ------------------------------------------------------ */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 0.45ch;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: var(--fs-xs);
  padding: 0.28em 0.66em;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--paper-dim);
  background: var(--ink-3);
  white-space: nowrap;
}
.tag--music        { color: var(--gold-bright); border-color: rgba(232,184,75,0.4); }
.tag--exhibit-opening { color: #7fd8ff; border-color: rgba(127,216,255,0.4); }
.tag--workshop     { color: #b6f09a; border-color: rgba(182,240,154,0.4); }
.tag--sound-healing{ color: #d6b3ff; border-color: rgba(214,179,255,0.4); }
.tag--market       { color: #ffb37f; border-color: rgba(255,179,127,0.4); }
.tag--other        { color: var(--paper-dim); }
.tag--status-current  { color: var(--ink); background: var(--gold); border-color: var(--gold); }
.tag--status-upcoming { color: #7fd8ff; border-color: rgba(127,216,255,0.4); }
.tag--status-past     { color: var(--paper-faint); }
.tag--role { color: var(--gold); border-color: rgba(232,184,75,0.35); background: transparent; }
/* Tags on cards sit like stickers slapped on the poster */
.card .tag { transform: rotate(-1.5deg); box-shadow: 1.5px 1.5px 0 rgba(0, 0, 0, 0.4); }
.card .tag:nth-of-type(even) { transform: rotate(1deg); }

.badge-free { color: var(--ember); font-weight: 700; }

/* ---- Cards -------------------------------------------------------------- */
/* Posters on a wall: each card hangs at a slightly different angle under a
   strip of tape, and straightens up when you reach for it. */
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--ink-2);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  transform: rotate(var(--tilt, 0deg));
  transition: border-color 0.15s ease, transform 0.18s ease;
}
.grid > .card:nth-child(3n + 1) { --tilt: -0.65deg; }
.grid > .card:nth-child(3n + 2) { --tilt: 0.45deg; }
.grid > .card:nth-child(3n)     { --tilt: -0.3deg; }
.card:hover { border-color: var(--line); transform: rotate(0deg) translateY(-3px); }
/* Tape */
.card::after {
  content: "";
  position: absolute;
  top: -0.65rem;
  left: 50%;
  width: 5.5rem;
  height: 1.5rem;
  transform: translateX(-50%) rotate(-3deg);
  background: linear-gradient(rgba(244, 241, 234, 0.16), rgba(244, 241, 234, 0.10));
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  pointer-events: none;
  z-index: 3;
}
.card a.card__link::after {
  content: "";
  position: absolute;
  inset: 0;
}
.card__media {
  aspect-ratio: 4 / 5;
  background: var(--ink-3);
  overflow: hidden;
  border-radius: calc(var(--radius-lg) - 1px) calc(var(--radius-lg) - 1px) 0 0;
}
.card__media img { width: 100%; height: 100%; object-fit: cover; }
.card--wide .card__media { aspect-ratio: 16 / 10; }
.card__body { padding: var(--sp-3) var(--sp-4) var(--sp-4); display: flex; flex-direction: column; align-items: flex-start; gap: 0.5rem; flex: 1; }
.card__body > .card__footer, .card__body > .card__meta { align-self: stretch; }
.card__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; font-size: var(--fs-xs); color: var(--paper-faint); }
.card__date { color: var(--paper-dim); font-weight: 600; font-size: var(--fs-sm); }
.card__title {
  font-family: var(--font-display);
  text-transform: uppercase;
  font-size: var(--fs-lg);
  line-height: 1.05;
  letter-spacing: 0.01em;
}
.card__title a { color: var(--paper); text-decoration: none; }
.card:hover .card__title a { color: var(--gold-bright); }
.card__excerpt { color: var(--paper-dim); font-size: var(--fs-sm); }
.card__footer { margin-top: auto; padding-top: var(--sp-2); display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; }

/* Event row (list variant) */
.event-row {
  display: grid;
  grid-template-columns: 5.5rem 1fr auto;
  gap: var(--sp-4);
  align-items: center;
  padding: var(--sp-4) 0;
  border-bottom: 1px solid var(--line-soft);
}
.event-row__date {
  text-align: center;
  font-family: var(--font-display);
  line-height: 0.95;
  color: var(--gold);
  /* Rubber-stamped date */
  border: 1.5px solid rgba(232, 184, 75, 0.45);
  border-radius: 6px;
  padding: 0.5rem 0.2rem;
  transform: rotate(-2.5deg);
  background: var(--ink-2);
}
.event-row__date .mon { display: block; font-size: 0.8rem; letter-spacing: 0.14em; }
.event-row__date .day { display: block; font-size: 2.2rem; color: var(--paper); }
.event-row__date .yr { display: block; font-size: 0.72rem; color: var(--paper-faint); letter-spacing: 0.1em; }
.event-row__body { min-width: 0; }
.event-row__title { font-family: var(--font-display); text-transform: uppercase; font-size: var(--fs-lg); line-height: 1.05; }
.event-row__title a { color: var(--paper); text-decoration: none; }
.event-row__title a:hover { color: var(--gold-bright); }
.event-row__meta { color: var(--paper-faint); font-size: var(--fs-sm); display: flex; flex-wrap: wrap; gap: 0.4rem 0.9rem; margin-top: 0.2rem; }
.event-row__cta { text-align: right; }
@media (max-width: 640px) {
  .event-row { grid-template-columns: 4rem 1fr; }
  .event-row__cta { grid-column: 2; text-align: left; }
}

/* ---- Hero --------------------------------------------------------------- */
.hero {
  position: relative;
  isolation: isolate;
  min-height: min(84vh, 46rem);
  display: flex;
  align-items: end;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}
.hero__media { position: absolute; inset: 0; z-index: -2; }
.hero__media img { width: 100%; height: 100%; object-fit: cover; }
.hero__media video {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.9s ease;
}
.hero__media video.is-playing { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .hero__media video { display: none; }
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(to top, var(--ink) 6%, rgba(11,11,13,0.55) 46%, rgba(11,11,13,0.25) 100%);
}
.hero__inner { padding-block: var(--sp-6) var(--sp-6); }
/* Kicker as a rubber stamp */
.hero__kicker {
  display: inline-block;
  margin-bottom: var(--sp-4);
  padding: 0.45rem 0.75rem;
  border: 1.5px solid var(--gold);
  border-radius: 3px;
  transform: rotate(-1.5deg);
  background: rgba(11, 11, 13, 0.55);
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.35);
}
.hero h1 {
  font-family: var(--font-display);
  text-transform: uppercase;
  font-size: var(--fs-hero);
  letter-spacing: 0.004em;
  max-width: 16ch;
  /* Depth + an off-register ember pass, like a two-color print */
  text-shadow: 0 2px 30px rgba(0,0,0,0.5), 0.045em 0.045em 0 rgba(255, 90, 60, 0.4);
}
.hero__sub { margin-top: var(--sp-4); max-width: 52ch; font-size: var(--fs-lg); color: var(--paper); }
.hero__actions { margin-top: var(--sp-5); display: flex; flex-wrap: wrap; gap: var(--sp-3); }

/* Decorative φ watermark */
.phi-mark {
  position: absolute;
  z-index: -1;
  font-family: var(--font-display);
  color: var(--paper);
  opacity: 0.03;
  line-height: 1;
  pointer-events: none;
  user-select: none;
}

/* ---- Word strip ---------------------------------------------------------- */
/* Scrolling repeating-word divider under the hero — gig-poster marquee. */
.ticker {
  display: flex;
  overflow: hidden;
  border-block: 1px solid var(--line);
  background: var(--ink-2);
}
.ticker__track { display: flex; width: max-content; animation: ticker-scroll 40s linear infinite; }
@keyframes ticker-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker__track { animation: none; } }
.ticker__track > span {
  display: block;
  white-space: nowrap;
  padding: 0.6rem 0;
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: var(--fs-base);
  color: var(--gold);
}
.ticker b { font-weight: 400; color: var(--ember); padding-inline: 0.6ch; }

/* ---- Prose (markdown bodies) ------------------------------------------- */
.prose { max-width: 65ch; }
.prose > * + * { margin-top: 1.1em; }
.prose h2 { font-family: var(--font-display); text-transform: uppercase; font-size: var(--fs-xl); margin-top: 1.8em; }
.prose h3 { font-family: var(--font-display); text-transform: uppercase; font-size: var(--fs-lg); margin-top: 1.5em; letter-spacing: 0.01em; }
.prose p, .prose li { color: #e7e3da; }
.prose a { text-decoration: underline; }
.prose blockquote {
  border-left: 3px solid var(--gold);
  padding-left: 1rem;
  color: var(--paper-dim);
  font-style: italic;
}
.prose img { border-radius: var(--radius); margin-block: 1.4em; }
.prose hr { border: none; border-top: 1px solid var(--line); margin-block: 2em; }
.prose code { font-family: var(--font-mono); font-size: 0.9em; background: var(--ink-3); padding: 0.1em 0.4em; border-radius: 3px; }
.prose table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.prose th, .prose td { text-align: left; padding: 0.55rem 0.7rem; border-bottom: 1px solid var(--line); }
.prose th { color: var(--gold); text-transform: uppercase; letter-spacing: 0.08em; font-size: var(--fs-xs); }

/* ---- Detail page layout ------------------------------------------------- */
.detail { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--sp-5); }
@media (min-width: 900px) {
  .detail--media { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: start; }
}
.detail__flyer { position: sticky; top: 5.5rem; border: 1px solid var(--line); border-radius: var(--radius-lg); transform: rotate(-0.8deg); }
.detail__flyer img { width: 100%; border-radius: calc(var(--radius-lg) - 1px); }
.detail__flyer::after {
  content: "";
  position: absolute;
  top: -0.7rem;
  left: 50%;
  width: 6.5rem;
  height: 1.6rem;
  transform: translateX(-50%) rotate(-3deg);
  background: linear-gradient(rgba(244, 241, 234, 0.16), rgba(244, 241, 234, 0.10));
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  pointer-events: none;
}
.detail__title { font-family: var(--font-display); text-transform: uppercase; font-size: var(--fs-3xl); letter-spacing: 0.005em; }
.detail__meta { display: flex; flex-wrap: wrap; gap: 0.7rem 0.9rem; align-items: center; color: var(--paper-dim); font-size: var(--fs-sm); margin-block: var(--sp-3); }
.detail__meta strong { color: var(--paper); }
.detail__meta > span + span::before { content: "·"; color: var(--paper-faint); margin-right: 0.9rem; }

/* Definition-style fact list */
.facts { display: grid; grid-template-columns: auto 1fr; gap: 0.4rem 1.2rem; font-size: var(--fs-sm); }
.facts dt { color: var(--gold); font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; font-size: var(--fs-xs); align-self: center; }
.facts dd { color: var(--paper); }

/* ---- Gallery grid (exhibit / artist work) ------------------------------ */
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 14rem), 1fr)); gap: var(--sp-3); }
.gallery figure { margin: 0; }
.gallery img { border-radius: var(--radius); width: 100%; aspect-ratio: 1; object-fit: cover; }
.gallery figcaption { font-size: var(--fs-xs); color: var(--paper-faint); margin-top: 0.4rem; }

/* ---- Info / NAP / visit ------------------------------------------------- */
.hours-table { width: 100%; border-collapse: collapse; }
.hours-table td { padding: 0.5rem 0; border-bottom: 1px solid var(--line-soft); font-size: var(--fs-sm); }
.hours-table td:last-child { text-align: right; color: var(--paper-dim); }
.hours-table tr[data-today="true"] td { color: var(--gold); font-weight: 600; }
.hours-table tr[data-today="true"] td:last-child { color: var(--gold); }
.hours-table .closed { color: var(--paper-faint); }

.map-embed {
  aspect-ratio: 16 / 9;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  /* Dark ground while the iframe loads (or if it's blocked) so the panel
     doesn't flash as a white slab; the loaded map dims to sit in the theme
     and lifts to full strength on interaction. */
  background: var(--ink-3);
  color-scheme: light;
  filter: grayscale(0.35) contrast(1.05) brightness(0.82);
  transition: filter 0.2s ease;
}
.map-embed:hover, .map-embed:focus-within { filter: grayscale(0) contrast(1) brightness(1); }

.info-grid { display: grid; gap: var(--sp-5); }
@media (min-width: 820px) { .info-grid { grid-template-columns: 1fr 1fr; } }

.panel {
  position: relative;
  background: var(--ink-2);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  padding: var(--sp-4);
}
/* Print-shop registration marks in opposite corners */
.panel::before, .panel::after {
  content: "";
  position: absolute;
  width: 0.65rem;
  height: 0.65rem;
  pointer-events: none;
}
.panel::before { top: 0.5rem; left: 0.5rem; border-top: 2px solid rgba(232, 184, 75, 0.4); border-left: 2px solid rgba(232, 184, 75, 0.4); }
.panel::after { bottom: 0.5rem; right: 0.5rem; border-bottom: 2px solid rgba(232, 184, 75, 0.4); border-right: 2px solid rgba(232, 184, 75, 0.4); }

/* ---- Forms -------------------------------------------------------------- */
.field { display: flex; flex-direction: column; gap: 0.35rem; margin-bottom: var(--sp-3); }
.field label { font-weight: 600; font-size: var(--fs-sm); text-transform: uppercase; letter-spacing: 0.06em; color: var(--paper-dim); }
.field input, .field textarea, .field select {
  font: inherit;
  color: var(--paper);
  background: var(--ink-3);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.7rem 0.85rem;
}
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--gold); box-shadow: var(--ring); outline: none; }
/* Honeypot — visually removed, still submitted; bots fill it, humans don't. */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { font-size: var(--fs-sm); margin-top: var(--sp-2); }
.form-status.is-ok { color: var(--gold); }
.form-status.is-error { color: var(--ember); }

/* ---- Footer ------------------------------------------------------------- */
.site-footer {
  position: relative;
  overflow: hidden;
  margin-top: var(--sp-7);
  border-top: 1px solid var(--line);
  background: var(--ink-2);
  padding-block: var(--sp-6) var(--sp-5);
}
/* Ghost wordmark, like the back of a screen-printed tee */
.site-footer::before {
  content: "PHI GALLERY";
  position: absolute;
  top: -0.18em;
  right: -0.04em;
  z-index: 0;
  font-family: var(--font-display);
  font-size: clamp(5rem, 16vw, 13rem);
  line-height: 1;
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 1px rgba(244, 241, 234, 0.07);
  pointer-events: none;
  user-select: none;
}
.site-footer > .wrap { position: relative; z-index: 1; }
.footer-grid { display: grid; gap: var(--sp-5); }
@media (min-width: 720px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; } }
.footer-brand .brand { font-size: 1.8rem; margin-bottom: var(--sp-3); }
.nap { font-style: normal; color: var(--paper-dim); line-height: 1.7; }
.nap strong { color: var(--paper); display: block; font-size: var(--fs-base); }
.nap a { color: var(--gold-bright); text-decoration: none; }
.footer-col h3 { font-family: var(--font-display); text-transform: uppercase; font-size: var(--fs-base); letter-spacing: 0.06em; color: var(--paper); margin-bottom: var(--sp-3); }
.footer-col ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.5rem; }
.footer-col a { color: var(--paper-dim); text-decoration: none; font-size: var(--fs-sm); }
.footer-col a:hover { color: var(--gold); }
.footer-bottom {
  margin-top: var(--sp-5);
  padding-top: var(--sp-4);
  border-top: 1px solid var(--line-soft);
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-3);
  justify-content: space-between;
  align-items: center;
  color: var(--paper-faint);
  font-size: var(--fs-xs);
}
.social-links { display: flex; gap: 0.55rem; align-items: center; }
.social-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--paper-dim);
  background: transparent;
  transition: color .15s ease, background-color .15s ease, border-color .15s ease, transform .15s ease;
}
.social-btn:hover,
.social-btn:focus-visible { color: var(--ink); background: var(--gold); border-color: var(--gold); transform: translateY(-1px); }
.social-btn svg { width: 1.2rem; height: 1.2rem; fill: currentColor; }

/* ---- Breadcrumbs -------------------------------------------------------- */
.breadcrumbs { font-size: var(--fs-xs); color: var(--paper-faint); padding-block: var(--sp-3) 0; }
.breadcrumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 0.4rem; padding: 0; margin: 0; }
.breadcrumbs li::after { content: "/"; margin-left: 0.4rem; color: var(--line); }
.breadcrumbs li:last-child::after { content: ""; }
.breadcrumbs a { color: var(--paper-dim); text-decoration: none; }
.breadcrumbs a:hover { color: var(--gold); }

/* ---- Utilities ---------------------------------------------------------- */
.text-center { text-align: center; }
.muted { color: var(--paper-dim); }
.faint { color: var(--paper-faint); }
.mt-0 { margin-top: 0; }
.flow > * + * { margin-top: var(--sp-3); }
.cluster { display: flex; flex-wrap: wrap; gap: var(--sp-3); align-items: center; }
.divider { height: 1px; background: var(--line); border: none; margin-block: var(--sp-5); }
.empty-state { color: var(--paper-faint); font-style: italic; padding: var(--sp-4) 0; }
.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}

/* ---- 404 ---------------------------------------------------------------- */
.error-page { min-height: 60vh; display: grid; place-items: center; text-align: center; padding-block: var(--sp-6); }
.error-page .code { font-family: var(--font-display); font-size: clamp(5rem, 20vw, 12rem); color: var(--gold); line-height: 0.8; }
