/* Look taken from the Slow Bal Day Taipei promo cards: forest-green grunge background, chunky yellow
   display type with a stepped green shadow, cream paper cards with dark-green text, red times,
   hand-drawn cream stars. Change the colours here; everything else uses these variables. */
@font-face {
  font-family: "Bowlby One";
  src: url("assets/fonts/bowlby-one-latin-400.woff2") format("woff2");
  font-display: swap;
}

:root {
  --green: #0e3b22;          /* page background */
  --green-dark: #082a17;
  --green-step: #4f8a2b;     /* the stepped "3D" shadow under yellow type */
  --cream: #f6ebc9;          /* paper cards + body text */
  --ink: #123d22;            /* text on cream */
  --yellow: #ffd447;
  --red: #b02a1e;            /* times + prices on cream */
  --muted: #c9d6b8;
  --line: rgb(246 235 201 / 0.18);
  --radius: 10px;
  --wrap: 60rem;
  --display: "Bowlby One", "Arial Black", "PingFang TC", "Noto Sans TC", "Microsoft JhengHei", sans-serif;
  --font: system-ui, -apple-system, "Segoe UI", "PingFang TC", "Noto Sans TC", "Microsoft JhengHei", sans-serif;
  --step-shadow: 2px 2px 0 var(--green-step), 4px 4px 0 var(--green-step), 6px 6px 0 var(--green-dark);
  /* Hand-drawn-ish star, cream stroke. */
  --star: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 40'%3E%3Cpath d='M20 3 L24.5 15.5 L37 16 L27 24 L31 37 L20 29 L9 37 L13 24 L3 16 L15.5 15.5 Z' fill='none' stroke='%23f6ebc9' stroke-width='2.2' stroke-linejoin='round'/%3E%3C/svg%3E");
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 5rem; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  color: var(--cream);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.65;
  background-color: var(--green);
  /* Grunge: soft vignette + fine SVG noise, like the printed-poster texture. */
  background-image:
    radial-gradient(ellipse at 50% 0%, rgb(255 255 255 / 0.05), transparent 60%),
    radial-gradient(ellipse at 50% 120%, rgb(0 0 0 / 0.45), transparent 60%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .35 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-attachment: fixed, fixed, scroll;
}
body:lang(zh) { letter-spacing: 0.02em; }

img { max-width: 100%; height: auto; display: block; }
a { color: var(--yellow); text-underline-offset: 0.2em; }
a:hover { color: var(--cream); }
:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; border-radius: 4px; }
[hidden] { display: none !important; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: 1rem; }
@media (min-width: 48rem) { .wrap { padding-inline: 2rem; } }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

.skip-link {
  position: absolute; left: 1rem; top: -4rem; z-index: 100;
  background: var(--yellow); color: var(--ink); padding: 0.5rem 1rem; border-radius: 0 0 8px 8px; font-weight: 800;
}
.skip-link:focus { top: 0; }

/* Placeholder copy ([TBD] / 【待填】) is outlined so nothing unfinished ships unnoticed. */
.tbd { outline: 1px dashed var(--yellow); outline-offset: 2px; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: rgb(8 42 23 / 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 0.5rem 1rem; padding-block: 0.6rem;
}
.brand {
  font-family: var(--display); color: var(--yellow); text-decoration: none; text-transform: uppercase;
  max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.controls { display: flex; align-items: center; gap: 0.75rem; margin-left: auto; }

.year-picker { display: flex; align-items: center; gap: 0.4rem; font-size: 0.9rem; color: var(--muted); }
.year-picker select {
  font: inherit; font-weight: 700; color: var(--cream); background: var(--green-dark);
  border: 1px solid var(--line); border-radius: 8px; min-height: 44px; padding: 0 2rem 0 0.75rem;
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--cream) 50%), linear-gradient(-45deg, transparent 50%, var(--cream) 50%);
  background-position: right 1rem center, right 0.65rem center;
  background-size: 0.35rem 0.35rem; background-repeat: no-repeat;
}

.lang-switch ul {
  display: flex; margin: 0; padding: 3px; list-style: none;
  border: 1px solid var(--line); border-radius: 999px;
}
.lang-switch a {
  display: grid; place-items: center; min-width: 44px; min-height: 38px; padding: 0 0.8rem;
  border-radius: 999px; color: var(--cream); text-decoration: none; font-weight: 700; font-size: 0.9rem;
}
.lang-switch a[aria-current] { background: var(--yellow); color: var(--ink); }

/* ---------- past-year banner ---------- */
.past-banner { background: var(--yellow); color: var(--ink); font-weight: 600; padding-block: 0.6rem; }
.past-banner a { color: var(--ink); font-weight: 800; }

/* ---------- hero: a typographic poster ---------- */
.hero { position: relative; isolation: isolate; overflow: hidden; text-align: center; }
.hero::before, .hero::after {
  content: ""; position: absolute; z-index: -1; background: var(--star) no-repeat center / contain; opacity: 0.9;
}
.hero::before { width: 3rem; height: 3rem; left: 6%; top: 18%; transform: rotate(-12deg); }
.hero::after { width: 2.25rem; height: 2.25rem; right: 8%; top: 30%; transform: rotate(14deg); }
.hero-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; opacity: 0.35; }
.hero-text { padding-block: 3.5rem 3rem; display: flex; flex-direction: column; align-items: center; }

.hero-year {
  order: -1; margin: 0 0 1.25rem; display: flex; align-items: center; gap: 0.9rem;
  font-weight: 700; letter-spacing: 0.3em; font-size: 0.95rem; color: var(--cream);
}
.hero-year::before, .hero-year::after { content: ""; width: 3rem; height: 1px; background: var(--cream); opacity: 0.7; }

.hero h1 {
  margin: 0 0 1rem; font-family: var(--display); font-weight: 400; color: var(--yellow);
  text-transform: uppercase; line-height: 1.02; letter-spacing: 0.01em;
  font-size: clamp(2.6rem, 11vw, 5.75rem); text-wrap: balance; text-shadow: var(--step-shadow);
}
.tagline {
  margin: 0 0 2rem; font-weight: 900; color: var(--cream); line-height: 1.3;
  font-size: clamp(1.4rem, 5.5vw, 2.4rem); text-wrap: balance; max-width: 22ch;
  text-shadow: 3px 3px 0 var(--green-dark);
}

/* When / where as a cream paper card, like the poster panels. */
.facts {
  display: grid; gap: 0.75rem 2.5rem; margin: 0 0 2rem; padding: 1.1rem 1.5rem; text-align: left;
  background: var(--cream); color: var(--ink); border-radius: var(--radius);
  box-shadow: 5px 5px 0 var(--green-dark); rotate: -1deg;
}
@media (min-width: 40rem) { .facts { grid-template-columns: auto auto; } }
.facts dt { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.12em; color: var(--red); font-weight: 800; }
.facts dd { margin: 0; font-weight: 800; font-size: 1.15rem; }

.hero-cta { margin: 0; }
.btn {
  display: inline-flex; align-items: center; min-height: 48px; padding: 0 1.6rem;
  background: var(--yellow); color: var(--ink); font-weight: 900; text-decoration: none;
  border-radius: 999px; box-shadow: 3px 3px 0 var(--green-step), 6px 6px 0 var(--green-dark);
}
.btn:hover { background: var(--cream); color: var(--ink); }
.btn-ghost { background: transparent; color: var(--cream); box-shadow: inset 0 0 0 2px var(--cream); }
.btn-ghost:hover { background: var(--cream); color: var(--ink); }
/* Non-link call to action (e.g. "Tickets at the door"): same pill shape, not clickable. */
.pill {
  display: inline-block; padding: 0.55rem 1.4rem; border-radius: 999px;
  border: 2px dashed var(--yellow); color: var(--yellow); font-weight: 900; font-size: 1.1rem;
}
.note { color: var(--muted); }

/* ---------- section nav ---------- */
.section-nav { border-block: 1px solid var(--line); background: rgb(8 42 23 / 0.5); }
.section-nav ul {
  display: flex; gap: 0.25rem; margin: 0 auto; list-style: none;
  overflow-x: auto; scrollbar-width: none;
}
@media (min-width: 48rem) { .section-nav ul { justify-content: center; } }
.section-nav a {
  display: block; padding: 0.75rem; white-space: nowrap;
  color: var(--cream); text-decoration: none; font-weight: 700;
}
.section-nav a:hover { color: var(--yellow); }

/* ---------- sections ---------- */
.section { padding-block: 3.5rem 1rem; }
.section h2 {
  margin: 0 0 1.75rem; font-family: var(--display); font-weight: 400; color: var(--yellow);
  font-size: clamp(2rem, 7.5vw, 3.25rem); line-height: 1.1; text-transform: uppercase;
  text-shadow: var(--step-shadow); text-align: center;
}
.section h3 { margin: 0 0 0.5rem; font-size: 1.25rem; line-height: 1.3; }
.prose { max-width: 62ch; margin-inline: auto; }
.prose p { margin: 0 0 1em; white-space: pre-line; }
#about .prose { font-size: 1.15rem; text-align: center; }

.card { background: var(--cream); color: var(--ink); border-radius: var(--radius); padding: 1.25rem; box-shadow: 4px 4px 0 var(--green-dark); }
.card a { color: var(--ink); }

/* schedule: cream rows, red times, divider — as on the workshop card */
.day + .day { margin-top: 2.5rem; }
.day h3 {
  font-size: 1.35rem; font-weight: 900; text-align: center; margin-bottom: 1rem;
  display: flex; align-items: center; justify-content: center; gap: 0.75rem;
}
.day h3::before, .day h3::after { content: ""; width: 1.4rem; height: 1.4rem; background: var(--star) no-repeat center / contain; flex: none; }
.day-note { margin: -0.25rem auto 1rem; max-width: 42rem; text-align: center; color: var(--muted); white-space: pre-line; font-weight: 600; }
.timeline { list-style: none; margin: 0 auto; padding: 0; max-width: 42rem; display: grid; gap: 0.6rem; }
.timeline li {
  display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 0 1rem;
  background: var(--cream); color: var(--ink); border-radius: var(--radius); padding: 0.75rem 1rem;
  box-shadow: 3px 3px 0 var(--green-dark);
}
.time {
  font-weight: 900; font-variant-numeric: tabular-nums; color: var(--red); white-space: nowrap;
  padding-right: 1rem; border-right: 2px solid rgb(18 61 34 / 0.35); font-size: 1.05rem;
}
.item-title { margin: 0; font-weight: 800; }
.item-detail { margin: 0.1rem 0 0; font-size: 0.9rem; opacity: 0.8; }
@media (max-width: 26rem) {
  .timeline li { grid-template-columns: 1fr; }
  .time { border-right: 0; padding-right: 0; }
}

/* lineup */
.lineup, .tiers, .gallery { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; }
.lineup { grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 16rem)); justify-content: center; }
.lineup .card { position: relative; text-align: center; }
.lineup img, .monogram { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 8px; margin-bottom: 1rem; }
.monogram {
  display: grid; place-items: center; font-family: var(--display); font-size: 4.5rem;
  background: var(--green); color: var(--yellow); text-shadow: var(--step-shadow);
}
.role { margin: 0; color: var(--red); font-weight: 700; }
.lineup a {
  position: absolute; top: 0.75rem; right: 0.75rem; display: grid; place-items: center;
  width: 44px; height: 44px; border-radius: 50%; background: var(--yellow); color: var(--ink); text-decoration: none; font-weight: 900;
}

/* tickets */
.tiers { grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); margin-bottom: 1.75rem; }
.tiers p { margin: 0.25rem 0 0; }
.price { font-family: var(--display); font-size: 1.75rem; color: var(--red); }
.sold-out { opacity: 0.75; }
.sold-out .price { text-decoration: line-through; color: rgb(18 61 34 / 0.6); }
.badge {
  display: inline-block; margin: 0 0 0.5rem; padding: 0.1rem 0.7rem; border-radius: 999px;
  background: var(--red); color: var(--cream); font-size: 0.8rem; font-weight: 800;
}
#tickets-body > .hero-cta, #tickets-body > .note { text-align: center; }

/* venue */
#venue-body { text-align: center; }
address { font-style: normal; color: var(--muted); margin-bottom: 1.25rem; }

/* gallery */
.gallery { grid-template-columns: repeat(auto-fill, minmax(min(100%, 16rem), 1fr)); }
.gallery img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--radius); }

/* faq */
.faq { max-width: 42rem; margin-inline: auto; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; padding: 1rem 0; font-weight: 800; font-size: 1.1rem; }
.faq summary::marker { color: var(--yellow); }
.faq .prose { padding-bottom: 1rem; color: var(--muted); }

/* ---------- footer ---------- */
.site-footer { margin-top: 4rem; padding-block: 2.5rem 3rem; border-top: 1px solid var(--line); text-align: center; }
.contact { margin: 0 0 1.75rem; font-size: 1.1rem; font-weight: 700; }
.contact a { display: inline-block; padding-block: 0.5rem; }
.footer-h { font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.2em; color: var(--muted); margin: 0 0 0.5rem; }
.social { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem 1.25rem; list-style: none; margin: 0 0 1.5rem; padding: 0; }
.social a { display: inline-block; padding-block: 0.6rem; font-weight: 800; }
.copyright { margin: 0; color: var(--muted); font-size: 0.9rem; letter-spacing: 0.08em; }

.load-error { margin: 2rem 1rem; padding: 1rem; border: 2px solid var(--yellow); border-radius: var(--radius); }
