/* Black to the Trails — site styles.
   Colours are taken from the event artwork: a "carnival" palette on a warm
   off-white page, with near-black for text and dark sections. */
:root {
  --ink: #17121c;
  --ink-soft: #4a4350;
  --paper: #fffaf2;
  --white: #ffffff;
  --green: #76c94f;
  --green-deep: #2f6b1c;
  --yellow: #ffc22e;
  --orange: #ff5a1f;
  --pink: #c81e74;      /* dark enough for white text on top */
  --pink-bright: #ff4fa3;
  --purple: #6b3fd4;
  --teal: #1f6f78;
  --burgundy: #801a34;
  --stripe: linear-gradient(90deg, var(--green) 0 20%, var(--yellow) 20% 40%, var(--orange) 40% 60%, var(--pink-bright) 60% 80%, var(--purple) 80% 100%);
  --radius: 18px;
  --wrap: 1180px;
  --shadow: 0 10px 30px rgba(23, 18, 28, 0.10);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
body {
  margin: 0;
  font-family: 'Poppins', system-ui, sans-serif;
  font-weight: 400;
  font-size: 17px;
  line-height: 1.7;
  color: var(--ink);
  background: var(--paper);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--pink); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
strong, b { font-weight: 600; }
p { margin: 0 0 1em; }
h1, h2, h3, h4 {
  font-weight: 800; line-height: 1.08; letter-spacing: -0.01em;
  margin: 0 0 0.5em; text-transform: uppercase;
}
h1 { font-size: clamp(2.4rem, 7vw, 5rem); }
h2 { font-size: clamp(1.9rem, 4.5vw, 3.2rem); }
h3 { font-size: clamp(1.25rem, 2.5vw, 1.6rem); }
h4 { font-size: 1.05rem; letter-spacing: 0.02em; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 760px; }
.center { text-align: center; }
.center .button-row { justify-content: center; }
.lead { font-size: clamp(1.1rem, 2vw, 1.3rem); line-height: 1.6; }
.eyebrow {
  display: inline-block; font-weight: 700; font-size: 0.8rem; letter-spacing: 0.14em;
  text-transform: uppercase; margin-bottom: 1em; padding: 6px 14px; border-radius: 999px;
  background: var(--ink); color: var(--white);
}
.muted { color: var(--ink-soft); }
.small { font-size: 0.9rem; }

.skip { position: absolute; left: -999px; top: 0; background: var(--ink); color: #fff; padding: 10px 16px; z-index: 100; }
.skip:focus { left: 10px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--pink); color: var(--white) !important; text-decoration: none;
  font-weight: 700; font-size: 0.95rem; letter-spacing: 0.04em; text-transform: uppercase;
  padding: 14px 26px; border-radius: 999px; border: 2px solid var(--pink);
  font-family: inherit; cursor: pointer; line-height: 1.2; text-align: center;
  transition: transform 0.15s ease, background 0.15s ease;
}
.btn:hover { transform: translateY(-2px); background: var(--ink); border-color: var(--ink); }
.btn.dark { background: var(--ink); border-color: var(--ink); }
.btn.dark:hover { background: var(--pink); border-color: var(--pink); }
.btn.ghost { background: transparent; color: var(--ink) !important; border-color: var(--ink); }
.btn.ghost:hover { background: var(--ink); color: var(--white) !important; }
.on-dark .btn.ghost { color: var(--white) !important; border-color: var(--white); }
.on-dark .btn.ghost:hover { background: var(--white); color: var(--ink) !important; }
.button-row { display: flex; flex-wrap: wrap; gap: 12px; margin: 1.4em 0 0; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--white); box-shadow: 0 1px 0 rgba(0,0,0,0.06); }
.site-header::after { content: ""; display: block; height: 6px; background: var(--stripe); }
.header-inner { max-width: 1320px; margin: 0 auto; padding: 12px 24px; display: flex; align-items: center; gap: 24px; }
.logo img { height: 30px; width: auto; }
.nav { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.nav a, .nav summary {
  color: var(--ink); text-decoration: none; font-size: 0.95rem; font-weight: 600;
  padding: 8px 12px; border-radius: 999px; cursor: pointer; display: block;
}
.nav a:hover, .nav summary:hover { background: #f1ece4; }
.nav a[aria-current="page"] { background: var(--green); }
.nav details { position: relative; }
.nav summary { list-style: none; }
.nav summary::-webkit-details-marker { display: none; }
.nav summary::after { content: " ▾"; font-size: 0.7em; }
.nav .dropdown {
  position: absolute; top: calc(100% + 8px); left: 0; background: var(--white);
  padding: 8px; display: grid; gap: 2px; min-width: 190px; border-radius: 14px;
  box-shadow: var(--shadow);
}
.header-extras { display: flex; align-items: center; gap: 16px; }
.social { display: flex; gap: 10px; align-items: center; }
.social a { color: inherit; display: inline-flex; width: 36px; height: 36px; align-items: center; justify-content: center; border-radius: 50%; }
.social a:hover { background: rgba(0,0,0,0.08); }
.social svg { width: 18px; height: 18px; fill: currentColor; }
.header-btn { padding: 11px 20px; font-size: 0.85rem; }
.menu-toggle { display: none; background: none; border: 0; padding: 8px; margin-left: auto; cursor: pointer; }
.menu-toggle span { display: block; width: 26px; height: 3px; border-radius: 2px; background: var(--ink); margin: 5px 0; }

@media (max-width: 1060px) {
  .menu-toggle { display: block; }
  .header-inner { flex-wrap: wrap; padding: 10px 16px; }
  .logo img { height: 24px; }
  .nav, .header-extras { display: none; width: 100%; }
  .site-header.open .nav { display: flex; flex-direction: column; align-items: stretch; gap: 2px; padding: 8px 0; }
  .site-header.open .header-extras { display: flex; justify-content: space-between; padding: 8px 0 16px; }
  .nav a, .nav summary { font-size: 1.15rem; padding: 10px 12px; }
  .nav .dropdown { position: static; box-shadow: none; padding: 0 0 0 16px; }
}

/* ---------- Sections ---------- */
.section { padding: clamp(56px, 8vw, 96px) 0; }
.section.tight { padding: clamp(36px, 5vw, 56px) 0; }
.band-green { background: var(--green); }
.band-yellow { background: var(--yellow); }
.band-pink { background: var(--pink); color: var(--white); }
.band-purple { background: var(--purple); color: var(--white); }
.band-dark { background: var(--ink); color: var(--white); }
.band-white { background: var(--white); }
.on-dark a:not(.btn) { color: var(--yellow); }
.band-pink .btn, .band-purple .btn { background: var(--white); color: var(--ink) !important; border-color: var(--white); }
.band-pink .btn:hover, .band-purple .btn:hover { background: var(--ink); color: var(--white) !important; border-color: var(--ink); }
.band-dark .eyebrow, .band-pink .eyebrow, .band-purple .eyebrow { background: var(--white); color: var(--ink); }
.section-head { max-width: 760px; margin: 0 auto 40px; text-align: center; }

/* Full-width artwork banner at the top of a page */
.hero { background: var(--ink); }
.hero img { width: 100%; max-height: 78vh; object-fit: cover; object-position: center bottom; }

/* Page title band for pages without event facts */
.page-title { padding: clamp(48px, 7vw, 88px) 0 clamp(40px, 6vw, 64px); }
.page-title h1 { margin-bottom: 0.25em; }

/* Two columns that stack on small screens */
.split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(28px, 5vw, 64px); align-items: center; }
.split.top { align-items: start; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }

/* ---------- Cards ---------- */
.cards { display: grid; gap: 24px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.cards.two { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.card {
  background: var(--white); color: var(--ink); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow); display: flex; flex-direction: column;
}
.card .button-row { margin-top: auto; padding-top: 1.2em; }
.card.flush { padding: 0; overflow: hidden; }
.card.flush .card-body { padding: 24px 26px 28px; display: flex; flex-direction: column; flex: 1; }
.card-tag {
  align-self: flex-start; font-weight: 700; font-size: 0.8rem; letter-spacing: 0.1em; text-transform: uppercase;
  background: var(--yellow); padding: 5px 12px; border-radius: 999px; margin-bottom: 14px;
}
.card h3 { margin-bottom: 0.4em; }

/* Event cards on the home page */
.event-card { position: relative; padding: 32px; border-top: 10px solid var(--pink-bright); }
.event-card:nth-child(2) { border-top-color: var(--purple); }
.event-card .date { font-weight: 800; font-size: clamp(1.6rem, 3vw, 2.2rem); line-height: 1.1; text-transform: uppercase; margin-bottom: 0.2em; }

/* Big facts tiles */
.tiles { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.tile { border-radius: var(--radius); padding: 24px; background: var(--white); box-shadow: var(--shadow); }
.tile .big { display: block; font-weight: 800; font-size: clamp(1.6rem, 3vw, 2.3rem); line-height: 1.05; text-transform: uppercase; margin-bottom: 6px; }
.tile.green { background: var(--green); }
.tile.yellow { background: var(--yellow); }
.tile.pink { background: var(--pink); color: var(--white); }
.tile.purple { background: var(--purple); color: var(--white); }

/* Event key facts */
.facts { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); margin: 28px 0 8px; }
.fact { background: var(--white); border-radius: 14px; padding: 16px 20px; }
.fact .label { display: block; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-soft); }
.fact .value { font-weight: 700; font-size: 1.05rem; line-height: 1.35; }

/* Jump links on event pages */
.jump { position: sticky; top: 64px; z-index: 40; background: var(--paper); border-bottom: 1px solid #ece4d8; }
.jump ul { list-style: none; margin: 0 auto; padding: 10px 24px; display: flex; gap: 8px; overflow-x: auto; max-width: var(--wrap); }
.jump a { display: block; white-space: nowrap; text-decoration: none; color: var(--ink); font-weight: 600; font-size: 0.9rem; padding: 6px 14px; border-radius: 999px; border: 2px solid var(--ink); }
.jump a:hover { background: var(--ink); color: var(--white); }
@media (max-width: 1060px) { .jump { top: 56px; } }

/* Price cards */
.price-card { text-align: center; padding: 32px 24px; }
.price-card .distance { font-weight: 800; font-size: clamp(2.6rem, 5vw, 3.6rem); line-height: 1; margin-bottom: 4px; }
.price-card .price { font-weight: 800; font-size: 1.6rem; }
.price-card .age { margin-top: 14px; padding-top: 14px; border-top: 2px dashed #e4dccf; font-size: 0.95rem; }

/* Info list (address, parking, etc.) */
.info { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.info li { background: var(--white); border-radius: 14px; padding: 14px 18px; }
.info .label { display: block; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-soft); }

/* Route cards */
.route-img { background: #f3efe8; }
.route-meta { list-style: none; margin: 0 0 1em; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.route-meta li { background: var(--paper); border-radius: 999px; padding: 4px 12px; font-size: 0.85rem; font-weight: 600; }

/* Video */
.video { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; background: #000; box-shadow: var(--shadow); }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.videos { display: grid; gap: 24px; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.video.short { aspect-ratio: 9 / 16; }
.video.cover { display: block; width: 100%; padding: 0; border: 0; cursor: pointer; }
.video.cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .3s ease; }
.video.cover:hover img { transform: scale(1.03); }
.video.cover .play { position: absolute; left: 50%; bottom: 28px; width: 76px; height: 76px; margin-left: -38px; border-radius: 50%; background: var(--white); box-shadow: var(--shadow); display: grid; place-items: center; }
.video.cover .play svg { width: 34px; height: 34px; margin-left: 4px; fill: var(--ink); }
.video.cover:focus-visible { outline: 3px solid var(--white); outline-offset: 4px; }
.videos.shorts { grid-template-columns: repeat(auto-fit, minmax(240px, 340px)); justify-content: center; text-align: center; }

/* Photos */
.photo-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.photo-grid img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 12px; }
.photo-grid.wide img { aspect-ratio: 4 / 3; }
.rounded { border-radius: var(--radius); }

/* Activity tiles */
.activity { border-radius: var(--radius); overflow: hidden; background: var(--white); box-shadow: var(--shadow); text-decoration: none; color: var(--ink); }
.activity img { aspect-ratio: 1 / 1; object-fit: cover; width: 100%; }
.activity h3 { padding: 18px 22px; margin: 0; }

/* Logos */
.logos { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(200px, 340px)); justify-content: center; }
.logos a { background: var(--white); border-radius: var(--radius); padding: 28px; display: flex; align-items: center; justify-content: center; min-height: 160px; box-shadow: var(--shadow); }
.logos img { max-height: 110px; width: auto; }

/* News */
.post-card img { aspect-ratio: 16 / 10; object-fit: cover; width: 100%; }
.post-card h3 a { color: var(--ink); text-decoration: none; }
.post-card h3 a:hover { color: var(--pink); }
.article { max-width: 760px; margin: 0 auto; }
.article h1 { font-size: clamp(1.9rem, 4.5vw, 3rem); text-transform: none; }
.article .feature { border-radius: var(--radius); margin: 0 0 2em; }
.quote { border-left: 6px solid var(--pink-bright); padding: 4px 0 4px 20px; margin: 1.5em 0; }
.post-nav { border-top: 2px dashed #e4dccf; margin-top: 3em; padding-top: 1.5em; }

/* Contact form */
form label { display: block; font-weight: 600; margin: 1em 0 0.35em; font-size: 0.95rem; }
form .req { color: var(--ink-soft); font-weight: 400; }
form input, form textarea {
  width: 100%; font: inherit; font-size: 16px; padding: 13px 16px;
  border: 2px solid #ddd3c4; border-radius: 12px; background: var(--white);
}
form input:focus, form textarea:focus { outline: none; border-color: var(--purple); }
form textarea { min-height: 170px; resize: vertical; }
form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 520px) { form .row { grid-template-columns: 1fr; } }
form .btn { margin-top: 1.4em; }
.hidden { position: absolute; left: -9999px; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #e9e3ee; }
.site-footer::before { content: ""; display: block; height: 8px; background: var(--stripe); }
.footer-grid { display: grid; gap: 40px; grid-template-columns: 1.3fr 1fr 1fr; padding: 64px 24px 40px; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer h4 { color: var(--white); margin-bottom: 1em; }
.site-footer a { color: #e9e3ee; text-decoration: none; }
.site-footer a:hover { color: var(--yellow); }
.footer-logo { filter: invert(1); height: 30px; width: auto; margin-bottom: 18px; }
.footer-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.tra { display: flex; gap: 16px; align-items: center; }
.tra img { width: 76px; border-radius: 10px; background: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.12); padding: 20px 24px; font-size: 0.85rem; color: #b8aec2; }

/* Photo mosaic (event photos) */
.mosaic { display: grid; gap: 10px; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 210px; }
.mosaic img { width: 100%; height: 100%; object-fit: cover; border-radius: 14px; }
.mosaic .big { grid-column: span 2; grid-row: span 2; }
.mosaic .tall { grid-row: span 2; }
@media (max-width: 760px) { .mosaic { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 160px; } }
.credit { font-size: 0.8rem; color: var(--ink-soft); margin-top: 12px; }
.on-dark .credit { color: #b8aec2; }
.photo-feature { border-radius: var(--radius); width: 100%; aspect-ratio: 4 / 5; object-fit: cover; box-shadow: var(--shadow); }

.article { padding: 0 24px; }

/* Instagram grid (home page) */
.insta-grid { display: grid; gap: 10px; grid-template-columns: repeat(6, 1fr); margin-bottom: 8px; }
.insta-grid a { display: block; border-radius: 12px; overflow: hidden; }
.insta-grid img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; transition: transform 0.2s ease; }
.insta-grid a:hover img { transform: scale(1.04); }
@media (max-width: 860px) { .insta-grid { grid-template-columns: repeat(3, 1fr); } }
