/*
  Zulu Challenge
  ANNOUNCEMENT — keep this sentence identical in the header of every page:
  2027 registration is open. View routes

  Two families: Bebas Neue (self-hosted) and the body stack.
*/

@font-face {
  font-family: "Bebas Neue";
  src: url("/assets/fonts/bebas-neue.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #14110e;
  --bg-2: #1c1814;
  --bg-3: #26211c;
  --text: #f4eddf;
  --cream: #f4eddf;
  --muted: #d7cfc0;
  --accent: #f05a28;
  --accent-2: #ffb088;
  --mustard: #f6c945;
  --olive: #6d7a45;
  --ink: #140e0b;
  --line: rgba(244, 237, 223, 0.16);
  --focus: #ffe08a;
  --font-display: "Bebas Neue", "Arial Narrow", "Franklin Gothic Medium", Impact, sans-serif;
  --font-body: "Segoe UI", system-ui, sans-serif;
  --max: 1120px;
  --edge: clamp(1.5rem, 5vw, 5.5rem);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.55;
  overflow-x: clip;
}

main {
  flex: 1;
}

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

a {
  color: var(--accent-2);
}

a:hover {
  color: var(--text);
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  margin: 0 0 0.75rem;
}

h1 {
  font-size: clamp(2.5rem, 9vw, 5.4rem);
  max-width: 14ch;
}

h2 {
  font-size: clamp(1.8rem, 4.5vw, 3.1rem);
  max-width: 22ch;
}

h3 {
  font-size: clamp(1.35rem, 2.4vw, 1.85rem);
}

p {
  margin: 0 0 1rem;
}

ul,
ol {
  margin: 0 0 1rem;
  padding-left: 1.15rem;
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: 0.75rem;
  top: -4rem;
  z-index: 80;
  background: var(--focus);
  color: var(--ink);
  padding: 0.7rem 1rem;
  font-weight: 700;
  text-decoration: none;
}

.skip-link:focus {
  top: 0.75rem;
}

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

.wrap {
  width: min(var(--max), calc(100% - 2rem));
  margin-inline: auto;
}

.eyebrow {
  margin: 0 0 0.75rem;
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.lede {
  max-width: 38rem;
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  color: var(--muted);
}

/* EARLYBIRD BANNER — text and on/off live in /includes/earlybird.html. Remove after Nov 30. */
.earlybird-banner {
  margin: 0;
  padding: 0.65rem var(--edge);
  background: var(--accent);
  color: var(--ink);
  text-align: center;
  font-weight: 800;
  font-size: 0.9375rem;
}

.promo-banner {
  margin: 0;
  padding: 0.55rem var(--edge);
  background: #100e0c;
  color: var(--cream);
  text-align: center;
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.4;
}

.promo-banner a {
  color: var(--mustard);
  font-weight: 800;
  text-underline-offset: 0.18em;
}

.promo-banner a:hover {
  color: var(--cream);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: #f4eddf;
  border-bottom: 1px solid rgba(23, 23, 20, 0.1);
  color: #171714;
}

.header-inner {
  width: 100%;
  margin-inline: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1rem;
  min-height: 4rem;
  padding: 0.35rem var(--edge);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  min-height: 44px;
  color: #171714;
  text-decoration: none;
  line-height: 1;
}

.logo-mark {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  background: var(--accent);
  box-shadow: 4px 4px 0 #171714;
  flex-shrink: 0;
}

.logo-mark img {
  width: 26px;
  height: 26px;
  object-fit: contain;
}

.logo-text {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  text-align: left;
}

.logo-name {
  font-family: var(--font-display);
  font-size: 1.25rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  line-height: 1;
}

.logo-tag {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(23, 23, 20, 0.6);
}

.logo:hover {
  color: #171714;
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  place-items: center;
  background: transparent;
  color: #171714;
  border: 1px solid rgba(23, 23, 20, 0.2);
  padding: 0;
  cursor: pointer;
}

.nav-toggle-bars,
.nav-toggle-bars::before,
.nav-toggle-bars::after {
  display: block;
  width: 18px;
  height: 2px;
  background: #171714;
  content: "";
  position: relative;
}

.nav-toggle-bars::before {
  position: absolute;
  top: -6px;
}

.nav-toggle-bars::after {
  position: absolute;
  top: 6px;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.15rem 0.75rem;
  margin-left: auto;
}

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 0 0.55rem;
  text-decoration: none;
  font-weight: 700;
}

.site-nav a:not(.btn) {
  color: #171714;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.site-nav a:not(.btn):hover {
  color: #171714;
  text-decoration: underline;
  text-underline-offset: 0.28em;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.65rem 1.1rem;
  border: 2px solid transparent;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  line-height: 1.2;
}

.btn-accent {
  background: var(--accent);
  color: var(--ink);
}

.btn-accent:hover {
  background: #ff7347;
  color: var(--ink);
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--line);
}

.btn-ghost:hover {
  border-color: var(--text);
  color: var(--text);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.btn-contact {
  background: transparent;
  color: #171714;
  border-color: rgba(23, 23, 20, 0.25);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 0.5rem 1rem;
}

.btn-contact:hover {
  background: #171714;
  color: #fff;
  border-color: #171714;
}

.btn-register {
  background: var(--accent);
  color: #fff;
  border-color: transparent;
  box-shadow: 3px 3px 0 #171714;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.55rem 1rem;
  gap: 0.35rem;
}

.btn-register:hover {
  background: #ff7347;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 5px 5px 0 #171714;
}

#events-heading,
#challenges-heading,
#why-heading,
#groups-heading,
#vendors {
  scroll-margin-top: 6.5rem;
}

@media (max-width: 639px) {
  .logo-text {
    display: none;
  }
}

@media (max-width: 1023px) {
  .header-actions {
    margin-left: auto;
  }

  .site-nav {
    flex-basis: 100%;
    flex-direction: column;
    align-items: stretch;
    margin-left: 0;
    padding-bottom: 0.75rem;
  }

  .site-nav ul {
    flex-direction: column;
    align-items: stretch;
  }

  .site-nav .btn {
    margin-left: 0;
    width: 100%;
  }

  .hero .cta-row {
    flex-direction: column;
    align-items: stretch;
  }

  .hero .btn-accent {
    width: 100%;
  }

  .js .nav-toggle {
    display: inline-grid;
  }

  .js .site-nav {
    display: none;
  }

  .js .site-nav.is-open {
    display: flex;
  }
}

.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: calc(100svh - 7.25rem);
  padding: 3rem var(--edge);
  overflow: hidden;
  background: #1a140f;
}

.hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: 70% center;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(16, 12, 9, 0.94) 0%,
    rgba(16, 12, 9, 0.82) 28%,
    rgba(16, 12, 9, 0.42) 52%,
    rgba(16, 12, 9, 0.08) 74%,
    rgba(16, 12, 9, 0) 100%
  );
}

.hero .wrap {
  position: relative;
  z-index: 1;
  width: min(980px, 100%);
  margin: 0;
}

.hero .eyebrow {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  margin: 0 0 0.65rem;
  padding: 0.2rem 0.55rem;
  background: var(--mustard);
  color: var(--ink);
  font-size: 0.875rem;
  letter-spacing: 0.08em;
}

.hero-place {
  margin: 0 0 1rem;
  color: var(--cream);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.hero h1 {
  max-width: none;
  margin: 0 0 1.1rem;
  color: var(--cream);
  font-size: clamp(56px, 10vw, 136px);
  font-weight: 400;
  line-height: 0.95;
  letter-spacing: 0.01em;
  overflow-wrap: normal;
}

.hero-line {
  display: block;
}

.hero h1 .is-accent {
  color: var(--accent);
}

.hero .lede {
  max-width: 34rem;
  margin: 0 0 1.35rem;
  padding-left: 0.9rem;
  border-left: 4px solid var(--accent);
  color: var(--cream);
  font-size: clamp(18px, 2vw, 22px);
  line-height: 1.45;
}

.hero-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--cream);
  font-size: 1.0625rem;
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 0.22em;
}

.hero-link:hover {
  color: var(--mustard);
}

@media (max-width: 1023px) {
  .hero::after {
    background: linear-gradient(
      180deg,
      rgba(16, 12, 9, 0.78) 0%,
      rgba(16, 12, 9, 0.9) 18%,
      rgba(16, 12, 9, 0.92) 72%,
      rgba(16, 12, 9, 0.62) 100%
    );
  }
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.25rem;
}

.section {
  padding: 3rem 0;
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  align-items: flex-end;
  margin-bottom: 1.25rem;
}

.section-head p {
  max-width: 38rem;
  color: var(--muted);
  margin: 0;
}

.card-grid {
  display: grid;
  gap: 0.9rem;
  grid-template-columns: 1fr;
}

.event-card,
.challenge-card,
.note-card,
.fact {
  background: var(--bg-3);
  border: 1px solid var(--line);
  padding: 1.1rem;
  min-width: 0;
}

.event-card {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.event-card-soon {
  border-style: dashed;
}

.event-card h3,
.challenge-card h3,
.note-card h3 {
  margin-bottom: 0.35rem;
}

.event-card p,
.challenge-card p,
.note-card p {
  margin: 0;
}

.card-note {
  color: var(--muted);
}

.tag {
  align-self: flex-start;
  margin: 0 0 0.35rem;
  padding: 0.2rem 0.45rem;
  background: var(--accent);
  color: var(--ink);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.event-card .btn,
.challenge-card .btn {
  margin-top: auto;
  align-self: flex-start;
}

.challenge-grid,
.note-grid {
  display: grid;
  gap: 0.9rem;
}

.price {
  margin-top: 0.75rem;
  font-family: var(--font-display);
  font-size: 2rem;
  letter-spacing: 0.03em;
}

.gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  list-style: none;
  padding: 0;
  margin: 0;
}

.gallery-btn {
  display: block;
  width: 100%;
  min-height: 44px;
  padding: 0;
  border: 1px solid var(--line);
  background: var(--bg-3);
  cursor: pointer;
}

.gallery-btn img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.faq-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.5rem;
}

.faq-list a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 0.6rem 0.9rem;
  background: var(--bg-3);
  border: 1px solid var(--line);
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
}

.faq-list a:hover {
  border-color: var(--accent);
  color: var(--text);
}

.cta-band {
  padding: 3rem 0;
  background:
    linear-gradient(180deg, rgba(240, 90, 40, 0.16), transparent 70%),
    var(--bg-2);
}

.contact-form {
  display: grid;
  gap: 0.85rem;
  max-width: 36rem;
}

.filters {
  display: grid;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.filters label,
.contact-form label {
  display: block;
  font-weight: 700;
  margin-bottom: 0.3rem;
}

.filters input,
.filters select,
.share-box input,
.contact-form input,
.contact-form textarea,
textarea {
  width: 100%;
  max-width: 100%;
  min-height: 44px;
  padding: 0.55rem 0.7rem;
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--line);
  font: inherit;
}

.event-count {
  color: var(--muted);
}

.breadcrumbs {
  padding-top: 1rem;
}

.breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.4rem;
  list-style: none;
  padding: 0;
  margin: 0;
}

.breadcrumbs a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--accent-2);
}

.breadcrumbs li:not(:last-child)::after {
  content: "/";
  margin-left: 0.4rem;
  color: var(--muted);
}

.page-intro {
  padding: 1rem 0 2rem;
}

.page-intro h1 {
  max-width: 22ch;
}

.facts {
  display: grid;
  gap: 0.75rem;
  margin: 0 0 1.5rem;
}

.fact dt {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.fact dd {
  margin: 0.3rem 0 0;
  font-size: 1.15rem;
}

.prose {
  max-width: 68ch;
}

.prose a {
  font-weight: 700;
}

.replace {
  color: var(--accent-2);
  font-weight: 800;
}

.draft-note {
  max-width: 68ch;
  margin: 0 0 1.5rem;
  padding: 1rem 1.15rem;
  background: var(--bg-3);
  border-left: 4px solid var(--mustard);
  color: var(--cream);
  font-weight: 700;
}

.table-wrap {
  overflow-x: auto;
  max-width: 100%;
  margin-bottom: 1rem;
}

table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

th,
td {
  text-align: left;
  padding: 0.75rem;
  border-bottom: 1px solid var(--line);
}

th {
  color: var(--muted);
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.share-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 0.75rem;
}

details.faq {
  border: 1px solid var(--line);
  background: var(--bg-3);
  margin-bottom: 0.55rem;
}

details.faq summary {
  min-height: 44px;
  padding: 0.75rem 1rem;
  cursor: pointer;
  font-weight: 800;
  list-style: none;
}

details.faq summary::-webkit-details-marker {
  display: none;
}

details.faq summary::after {
  content: "+";
  float: right;
  color: var(--accent);
}

details.faq[open] summary::after {
  content: "–";
}

details.faq .faq-body {
  padding: 0 1rem 1rem;
  color: var(--muted);
}

dialog {
  width: min(960px, calc(100% - 2rem));
  max-height: calc(100vh - 2rem);
  background: var(--bg-2);
  color: var(--text);
  border: 1px solid var(--line);
  padding: 1rem;
}

dialog::backdrop {
  background: rgba(0, 0, 0, 0.75);
}

.site-footer {
  margin-top: auto;
  padding: 2.5rem 0 1.5rem;
  background: var(--bg-2);
  border-top: 1px solid var(--line);
}

.footer-grid {
  display: grid;
  gap: 1.5rem;
}

.footer-grid ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.city-links {
  grid-column: 1 / -1;
}

.city-links ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 1.25rem;
}

.province-group + .province-group {
  margin-top: 2rem;
}

.footer-grid a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--text);
  text-decoration: none;
}

.footer-grid a:hover {
  color: var(--accent);
}

.footer-title {
  margin: 0 0 0.4rem;
  font-family: var(--font-display);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.legal {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1rem;
  align-items: center;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.legal a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--text);
}

.legal p {
  margin: 0;
}

[hidden] {
  display: none !important;
}

@media (min-width: 640px) {
  .card-grid,
  .challenge-grid,
  .note-grid {
    grid-template-columns: 1fr 1fr;
  }

  .filters {
    grid-template-columns: 1fr 1.4fr;
    align-items: end;
  }

  .facts {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 800px) {
  .footer-grid {
    grid-template-columns: 1.3fr 1fr 1fr;
  }

  .gallery {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (min-width: 1024px) {
  .card-grid {
    grid-template-columns: 1fr 1fr 1fr;
  }

  .challenge-grid {
    grid-template-columns: 1fr 1fr 1fr;
  }

  .nav-toggle {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .btn-register:hover {
    transform: none;
  }
}
