/* Hang Nadim Fun Run — asset-led festival identity */
:root {
  --green: #8DBF48;
  --teal: #3EADA6;
  --mint: #7FEFE2;
  --orange: #F38F2D;
  --red: #FF1F1F;
  --yellow: #FFCA17;
  --cyan: #0FB8DE;
  --purple: #CE58E0;
  --white: #FFFFFF;
  --black: #000000;
  --ink: #111111;
  --paper: #ffffff;
  --maxw: 1220px;
  --gutter: clamp(18px, 4vw, 56px);
  --display: 'Barlow Condensed', 'Arial Narrow', Impact, sans-serif;
  --sport: 'Barlow', system-ui, sans-serif;
  --body: 'Manrope', system-ui, sans-serif;
  --shadow: 10px 12px 0 var(--black);
  --soft-shadow: 0 18px 44px rgba(0, 0, 0, .18);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}
html,
body { max-width: 100%; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--mint);
  font-family: var(--body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button, input, textarea, select { font: inherit; }
:focus-visible { outline: 4px solid var(--purple); outline-offset: 4px; }

.wrap { width: min(100%, var(--maxw)); margin-inline: auto; padding-inline: var(--gutter); }
.skip-link { position: fixed; left: 12px; top: 12px; z-index: 999; padding: 10px 14px; background: var(--yellow); color: var(--black); transform: translateY(-150%); }
.skip-link:focus { transform: none; }
.pattern-layer,
.pattern-block { position: absolute; inset: 0; background-image: url('../assets/Pattern.png'); background-size: 320px; opacity: .18; pointer-events: none; mix-blend-mode: multiply; }

.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  background: linear-gradient(to bottom left, var(--cyan), var(--teal));
  border: 4px solid transparent;
  border-bottom-color: var(--black);
  border-radius: 0;
  box-shadow: none;
  transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}
.site-nav.is-stuck {
  top: 16px;
  width: calc(100% - 32px);
  max-width: 1340px;
  border-color: var(--black);
  border-radius: 0;
  box-shadow: 6px 6px 0 var(--black);
}
.nav-shell {
  width: 100%;
  margin-inline: auto;
  padding: 6px 16px;
  display: flex;
  align-items: center;
  gap: 24px;
}
.brand { display: inline-flex; align-items: center; flex: none; }
.brand img { width: clamp(110px, 12vw, 150px); height: auto; filter: drop-shadow(3px 3px 0 rgba(0, 0, 0, .28)); }
.nav-links { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.nav-links a {
  font-family: var(--sport);
  font-weight: 900;
  font-style: italic;
  text-transform: uppercase;
  text-decoration: none;
  letter-spacing: .03em;
  padding: 6px 12px;
  font-size: 0.95rem;
  border-radius: 999px;
  color: var(--black);
}
.nav-links a:hover { background: var(--yellow); }
.nav-links .nav-action { background: var(--red); color: var(--white); box-shadow: 4px 4px 0 var(--black); }
.nav-toggle { display: none; margin-left: auto; width: 48px; height: 42px; border: 3px solid var(--black); background: var(--yellow); box-shadow: 4px 4px 0 var(--black); }
.nav-toggle span { display: block; width: 24px; height: 3px; margin: 4px auto; background: var(--black); }

.hero {
  position: relative;
  width: 100%;
  height: auto;
  background: transparent;
  display: flex;
  flex-direction: column;
  padding: 0;
}
.hero::before {
  display: none;
}
.hero-logo { display: none; }
.hero-stage {
  position: relative;
  width: 100%;
  height: calc(92vh - 64px); /* Slightly smaller than full viewport, but bigger than 85vh */
  min-height: 500px;
  max-height: 950px;
  z-index: 1;
  padding: 0;
  margin: 0;
  line-height: 0;
  background: var(--teal);
}
.hero-stage img {
  width: 100%;
  height: 100%;
  display: block;
  max-width: none;
  max-height: none;
  margin: 0;
  object-fit: contain;
  object-position: center bottom; /* Anchor runners to the bottom strip */
}
.hero-logo { display: none; }
.hero-copy-card {
  position: relative;
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  padding: clamp(40px, 6vw, 80px) 24px;
  text-align: center;
}
.kicker {
  margin: 0 0 10px;
  font-family: var(--sport);
  font-weight: 900;
  font-style: italic;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--purple);
}

.hero h1, .hero-copy-card h1, .section-head h2, .about h2, .terms h2, .contact h2 {
  margin: 0;
  font-family: var(--display);
  font-weight: 900;
  font-style: italic;
  text-transform: uppercase;
  line-height: .86;
  letter-spacing: -.02em;
  -webkit-text-stroke: 1.5px var(--black);
  text-shadow: 4px 4px 0 var(--black);
}
.hero h1, .hero-copy-card h1 { font-size: clamp(3rem, 6.4vw, 5.7rem); color: var(--orange); }
.hero h1 span, .hero-copy-card h1 span { color: var(--purple); }
.hero-glass-box {
  position: absolute;
  top: auto;
  left: clamp(24px, 4vw, 56px);
  bottom: clamp(24px, 4vw, 56px);
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: clamp(16px, 3vw, 24px);
  border-radius: 8px;
  color: var(--white);
  z-index: 10;
  display: flex;
  flex-direction: column;
  gap: clamp(12px, 2vw, 16px);
  text-align: left;
}
.hero-glass-text h2 {
  font-family: var(--display);
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  margin: 0 0 10px;
  line-height: 1.1;
  color: var(--white);
  letter-spacing: 0.02em;
}
.hero-glass-text p {
  font-family: var(--sport);
  font-size: clamp(1rem, 2vw, 1.3rem);
  font-weight: 800;
  margin: 0;
  color: var(--white);
  letter-spacing: 0.05em;
}
.date-row {
  display: flex;
  align-items: center;
  gap: 12px;
}
.hero-countdown {
  font-family: var(--sport);
  font-size: clamp(1rem, 2vw, 1.3rem);
  font-weight: 900;
  color: var(--yellow);
  text-shadow: 2px 2px 0 var(--black);
  margin: 0;
  display: flex;
  gap: 6px;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 0; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 20px;
  border: 4px solid var(--black);
  box-shadow: 5px 5px 0 var(--black);
  color: var(--black);
  background: var(--yellow);
  font-family: var(--sport);
  font-weight: 900;
  font-style: italic;
  text-transform: uppercase;
  text-decoration: none;
  letter-spacing: .04em;
  transition: transform .18s, box-shadow .18s;
}
.btn:hover { transform: translate(3px, 3px); box-shadow: 2px 2px 0 var(--black); }
.btn-red { background: var(--red); color: var(--white); }
.btn-outline,
.btn-white { background: var(--white); }

.energy-strip { overflow: hidden; background: var(--yellow); border-block: 5px solid var(--black); }
.strip-track { width: max-content; display: flex; animation: marquee 24s linear infinite; }
.strip-track span {
  padding: 14px 24px;
  font-family: var(--display);
  font-size: 1.35rem;
  font-style: italic;
  font-weight: 900;
  text-transform: uppercase;
  white-space: nowrap;
}
.strip-track span:nth-child(3n+1) { color: var(--red); }
.strip-track span:nth-child(3n+2) { color: var(--teal); }
.strip-track span:nth-child(3n+3) { color: var(--purple); }
@keyframes marquee { to { transform: translateX(-50%); } }

.section { position: relative; padding-block: clamp(64px, 10vw, 128px); }
.section-head { max-width: 740px; margin-bottom: clamp(28px, 5vw, 56px); }
.section-head h2, .about h2, .terms h2, .contact h2 { font-size: clamp(3rem, 8vw, 6.2rem); color: var(--white); }
.section-head p:last-child { margin: 14px 0 0; font-weight: 700; font-size: clamp(1rem, 1.6vw, 1.2rem); }
.categories { background: var(--orange); }
.categories .section-head h2 { color: var(--yellow); }
.categories .kicker { color: var(--white); }
.category-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(20px, 4vw, 44px); }
.race-card {
  display: grid;
  grid-template-columns: minmax(120px, .45fr) 1fr;
  min-height: 390px;
  background: var(--white);
  border: 5px solid var(--black);
  box-shadow: var(--shadow);
  transform: rotate(-1deg);
}
.race-card-10 { transform: rotate(1deg); }
.race-distance {
  display: grid;
  place-items: center;
  font-family: var(--display);
  font-size: clamp(5.5rem, 15vw, 11rem);
  font-weight: 900;
  font-style: italic;
  line-height: .8;
  color: var(--white);
  -webkit-text-stroke: 3px var(--black);
  text-shadow: 6px 6px 0 var(--black);
  writing-mode: vertical-rl;
  transform: rotate(180deg);
}
.race-card-5 .race-distance { background: var(--teal); }
.race-card-10 .race-distance { background: var(--purple); }
.race-body { padding: clamp(20px, 4vw, 34px); }
.race-label { margin: 0 0 8px; color: var(--red); font-family: var(--sport); font-weight: 900; font-style: italic; text-transform: uppercase; }
.race-body h3 { margin: 0; font-family: var(--display); font-size: clamp(2.2rem, 5vw, 4rem); font-weight: 900; font-style: italic; text-transform: uppercase; line-height: .9; }
.price { display: inline-block; margin: 18px 0; padding: 8px 12px; background: var(--yellow); border: 3px solid var(--black); font-family: var(--sport); font-weight: 900; font-size: 1.35rem; }
ul { padding-left: 1.15rem; }
.race-card li, .route-copy li, .mission li { margin: 8px 0; font-weight: 700; }

.benefits { background: var(--mint); }
.benefits .section-head h2 { color: var(--cyan); }
.benefit-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.benefit {
  min-height: 170px;
  display: grid;
  place-items: center;
  gap: 10px;
  text-align: center;
  padding: 22px 16px;
  background: var(--white);
  border: 4px solid var(--black);
  box-shadow: 6px 6px 0 var(--black);
}
.benefit:nth-child(4n+1) { background: var(--yellow); }
.benefit:nth-child(4n+2) { background: var(--white); }
.benefit:nth-child(4n+3) { background: #ffefe0; }
.benefit:nth-child(4n+4) { background: #f7e2ff; }
.benefit img { width: 76px; height: 76px; object-fit: contain; }
.benefit strong { font-family: var(--sport); font-weight: 900; text-transform: uppercase; line-height: 1.1; }
.benefit-note { margin: 28px 0 0; font-weight: 800; }

.race-info { overflow: hidden; background: var(--teal); }
.race-info .wrap { position: relative; z-index: 1; }
.race-info .section-head h2 { color: var(--yellow); }
.race-info .section-head p:last-child, .race-info .kicker { color: var(--white); }
.info-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.info-card { padding: 24px; background: var(--white); border: 4px solid var(--black); box-shadow: 6px 6px 0 var(--black); }
.info-card span { display: inline-flex; padding: 5px 10px; background: var(--red); color: var(--white); border: 3px solid var(--black); font-family: var(--display); font-weight: 900; font-size: 1.45rem; transform: skew(-8deg); }
.info-card h3, .rule strong, .route-copy h3, .mission h3, .terms-list h3 { margin: 14px 0 8px; font-family: var(--display); font-size: 2rem; font-style: italic; font-weight: 900; text-transform: uppercase; line-height: .95; }
.info-card p, .rule p { margin: 0; font-weight: 700; }
.rules-grid { margin-top: 22px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.rule { padding: 20px; background: var(--yellow); border: 4px solid var(--black); }
.rule:nth-child(even) { background: var(--mint); }
.ban-strip { margin-top: 22px; display: flex; flex-wrap: wrap; align-items: center; gap: 20px; padding: 18px 22px; background: var(--red); color: var(--white); border: 5px solid var(--black); box-shadow: var(--shadow); }
.ban-strip strong { font-family: var(--display); font-size: 2.4rem; font-style: italic; font-weight: 900; text-transform: uppercase; line-height: .9; }
.ban-strip div { display: flex; align-items: center; gap: 10px; font-weight: 900; }
.ban-strip img { width: 58px; height: 58px; background: var(--white); border: 3px solid var(--black); border-radius: 50%; }

.routes { background: var(--cyan); }
.routes .section-head h2 { color: var(--white); }
.routes-grid { display: flex; flex-direction: column; gap: 48px; }
.route-panel { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr); gap: 24px; align-items: stretch; }
.map-frame, .jersey-frame { background: var(--white); border: 5px solid var(--black); box-shadow: var(--shadow); padding: 10px; }
.map-frame img { width: 100%; height: 100%; object-fit: contain; }
.route-copy { padding: clamp(22px, 4vw, 34px); background: var(--yellow); border: 5px solid var(--black); box-shadow: 8px 8px 0 var(--black); }
.route-copy h3 { font-size: clamp(3rem, 8vw, 5.8rem); }

.jersey { background: var(--white); }
.jersey .section-head h2 { color: var(--orange); }
.jersey-layout { display: grid; grid-template-columns: .85fr 1.15fr; gap: clamp(24px, 5vw, 60px); align-items: center; }
.jersey-frame { background: var(--teal); }
.jersey-frame img { max-height: 720px; width: 100%; object-fit: contain; }
.size-table { width: 100%; border-collapse: collapse; margin-top: 24px; border: 4px solid var(--black); font-weight: 800; }
.size-table th { background: var(--black); color: var(--white); text-align: left; }
.size-table th, .size-table td { padding: 11px 12px; border: 3px solid var(--black); }
.size-table tr:nth-child(odd) td { background: var(--mint); }
.size-table tr:nth-child(even) td { background: var(--yellow); }

.about { overflow: hidden; background: var(--purple); color: var(--white); }
.about .wrap { position: relative; z-index: 1; }
.about .kicker { color: var(--yellow); }
.about-layout { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(26px, 5vw, 64px); }
.about-lead p:last-child, .mission { font-weight: 700; font-size: 1.05rem; }
.mission { padding: clamp(20px, 4vw, 34px); background: var(--white); color: var(--black); border: 5px solid var(--black); box-shadow: var(--shadow); transform: rotate(1deg); }
.mission h3 { color: var(--red); }

.faq { background: var(--yellow); }
.faq .section-head h2 { color: var(--red); }
.faq-layout { display: grid; grid-template-columns: .75fr 1.25fr; gap: clamp(24px, 5vw, 54px); align-items: start; }
.accordion { background: var(--white); border: 5px solid var(--black); box-shadow: var(--shadow); }
.faq-item + .faq-item { border-top: 4px solid var(--black); }
.faq-item button { width: 100%; display: flex; justify-content: space-between; gap: 20px; padding: 20px; background: transparent; border: 0; cursor: pointer; text-align: left; font-family: var(--sport); font-weight: 900; text-transform: uppercase; }
.faq-item button span { width: 24px; height: 24px; flex: none; position: relative; }
.faq-item button span::before, .faq-item button span::after { content: ""; position: absolute; background: var(--red); }
.faq-item button span::before { left: 0; right: 0; top: 10px; height: 4px; }
.faq-item button span::after { top: 0; bottom: 0; left: 10px; width: 4px; transition: transform .2s; }
.faq-item.is-open button span::after { transform: scaleY(0); }
.faq-item > div { max-height: 0; overflow: hidden; transition: max-height .25s ease; }
.faq-item p { margin: 0; padding: 0 20px 22px; font-weight: 700; }

.terms { background: var(--green); }
.terms .section-head h2, .terms h2 { color: var(--white); }
.terms-grid { display: grid; grid-template-columns: .65fr 1.35fr; gap: clamp(24px, 5vw, 54px); }
.terms-card { align-self: start; padding: 26px; background: var(--orange); border: 5px solid var(--black); box-shadow: var(--shadow); }
.terms-list { display: grid; gap: 16px; }
.terms-list article { padding: 20px; background: var(--white); border: 4px solid var(--black); }
.terms-list p { margin: 0; font-weight: 700; }

.contact { padding: clamp(46px, 7vw, 90px) 0; background: linear-gradient(135deg, var(--cyan), var(--mint)); }
.contact-panel { display: grid; grid-template-columns: 260px 1fr; gap: clamp(20px, 5vw, 52px); align-items: center; padding-block: 20px; }
.contact-panel img { width: 100%; filter: drop-shadow(5px 5px 0 rgba(0, 0, 0, .28)); }
.contact a { font-weight: 900; }
.footer { background: var(--black); color: var(--white); padding: 22px 0; font-weight: 800; }
.footer-inner { display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.footer p { margin: 0; }

.reveal { opacity: 0; transform: translateY(24px); transition: opacity .5s ease, transform .5s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; } .strip-track { animation: none; } }

@media (max-width: 980px) {
  .nav-links { position: absolute; top: calc(100% + 12px); left: 0; right: 0; display: none; flex-direction: column; align-items: stretch; padding: 16px; background: var(--cyan); border: 4px solid var(--black); border-radius: 0; box-shadow: 4px 4px 0 var(--black); }
  .site-nav.is-open .nav-links { display: flex; }
  .nav-links a { border: 3px solid var(--black); background: var(--white); text-align: center; }
  .nav-toggle { display: block; }
  .hero { min-height: auto; display: flex; flex-direction: column; padding: 0; gap: 0; }
  .hero-logo { display: none; }
  .hero-stage { position: relative; width: 100%; height: auto; z-index: 1; padding: 0; overflow: hidden; line-height: 0; }
  .hero-stage img { width: 100%; height: auto; max-width: none; max-height: none; margin-left: 0; object-fit: contain; display: block; }
  .hero-copy-card { padding: clamp(40px, 8vw, 80px) 24px; margin: 0 auto; text-align: center; }
  .hero h1, .hero-copy-card h1 { font-size: clamp(3rem, 13vw, 5.8rem); }
  .category-grid, .about-layout, .faq-layout, .terms-grid, .jersey-layout, .route-panel.is-active, .rules-grid { grid-template-columns: 1fr; }
  .benefit-grid { grid-template-columns: repeat(2, 1fr); }
  .info-grid { grid-template-columns: 1fr; }
  .contact-panel { grid-template-columns: 1fr; }
  .contact-panel img { width: min(260px, 70%); }
}
@media (max-width: 640px) {
  .nav-shell { padding-block: 8px; }
  .brand img { width: 142px; }
  .hero-logo { display: none; }
  .hero-stage {
    position: relative;
    width: 100%;
    height: auto;
    margin: 0;
    padding: 0;
    line-height: 0;
    border: none;
    background: var(--teal);
  }
  .hero-stage img {
    width: 100%;
    height: 100vw;
    display: block;
    max-width: none;
    max-height: none;
    margin: 0;
    object-fit: cover;
    object-position: center bottom;
  }
  .hero-copy-card { padding: clamp(40px, 8vw, 60px) 16px; margin: 0 auto; text-align: center; }
  .hero h1 { font-size: clamp(1.82rem, 8.2vw, 2.75rem); line-height: .92; text-shadow: 2px 2px 0 var(--black); overflow-wrap: anywhere; word-break: break-word; -webkit-text-stroke-width: 1px; }
  .hero-copy-card h1 { font-size: clamp(2.75rem, 14vw, 4.5rem); line-height: .92; text-shadow: 3px 3px 0 var(--black); -webkit-text-stroke-width: 1.5px; }
  .hero-copy-card p:not(.kicker) { font-size: 1rem; line-height: 1.5; font-weight: 700; }
  .hero-glass-box { position: relative; top: auto; bottom: auto; left: auto; right: auto; margin: 0; border-radius: 0; width: 100%; backdrop-filter: none; background: var(--teal); padding: 24px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 20px; }
  .hero-glass-text { display: flex; flex-direction: column; align-items: center; }
  .hero-actions { width: 100%; justify-content: center; }
  .hero-actions .btn { width: 100%; }
  .section { padding-block: 56px; }
  .section-head h2, .about h2, .terms h2, .contact h2 { font-size: clamp(2.75rem, 15vw, 4.8rem); text-shadow: 3px 3px 0 var(--black); }
  .race-card { grid-template-columns: 1fr; min-height: auto; box-shadow: 6px 6px 0 var(--black); }
  .race-distance { writing-mode: horizontal-tb; transform: none; min-height: 130px; }
  .benefit-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .benefit { padding: 16px 8px; }
  .benefit img { width: 56px; height: 56px; }
  .benefit strong { font-size: 0.9em; }
  .ban-strip { box-shadow: 6px 6px 0 var(--black); }
  .routes-grid { grid-template-columns: 1fr; }
  .route-panel { display: grid; grid-template-columns: 1fr; gap: 24px; }
