/* ==========================================================================
   Rendezvous Run Club — brand tokens
   Colors sampled directly from club artwork (badge logo, wordmark, flyers)
   ========================================================================== */
:root {
  --cream:      #fdf8f0;
  --cream-dim:  #f5eddf;
  --navy:       #1e2a5e;
  --periwinkle: #5968a9;
  --sage:       #7a9a95;
  --pink:       #ff8fc7;
  --ink:        #1c1c1c;

  --font-display: "DIN Condensed", "Arial Narrow", Arial, sans-serif;
  --font-body: Arial, Helvetica, sans-serif;

  --max-width: 1120px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

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

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: var(--navy);
  margin: 0 0 0.4em;
}

h2 { font-size: clamp(2rem, 4.5vw, 3rem); }
h3 { font-size: 1.4rem; }

p { margin: 0 0 1em; }

a { color: var(--periwinkle); }

.section {
  padding: 88px 0;
}

.section-head {
  max-width: 640px;
  margin-bottom: 48px;
}

.section-head .kicker {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--periwinkle);
  font-size: 0.95rem;
  margin-bottom: 10px;
}

.section-head p {
  color: #4a4a4a;
  font-size: 1.05rem;
}

/* buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 14px 28px;
  border-radius: 999px;
  border: 2px solid transparent;
  line-height: 1;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: var(--periwinkle);
  color: var(--cream);
}
.btn-primary:hover { box-shadow: 0 8px 20px rgba(89, 104, 169, 0.35); }

.btn-outline {
  background: transparent;
  color: var(--navy);
  border-color: var(--navy);
}
.btn-outline:hover { background: var(--navy); color: var(--cream); }

/* ==========================================================================
   Header / nav
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(253, 248, 240, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid rgba(30, 42, 94, 0.1);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 12px;
  padding-bottom: 12px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}
.brand img { height: 46px; width: auto; }
.brand span {
  font-family: var(--font-display);
  font-weight: 800;
  color: var(--navy);
  font-size: 1.1rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1.1;
}

.main-nav { display: flex; align-items: center; gap: 28px; }
.main-nav a {
  color: var(--navy);
  text-decoration: none;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-size: 0.95rem;
}
.main-nav a:hover { color: var(--periwinkle); }
.main-nav .btn { font-size: 0.85rem; padding: 10px 20px; }

.nav-toggle { display: none; }

@media (max-width: 720px) {
  .main-nav {
    position: fixed;
    inset: 64px 0 0 0;
    background: var(--cream);
    flex-direction: column;
    align-items: flex-start;
    padding: 32px 24px;
    gap: 20px;
    transform: translateX(100%);
    transition: transform 0.25s ease;
  }
  .main-nav.open { transform: translateX(0); }
  .nav-toggle {
    display: block;
    background: none;
    border: none;
    font-size: 1.6rem;
    color: var(--navy);
    cursor: pointer;
  }
}

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
  position: relative;
  overflow: hidden;
  padding: 64px 0 80px;
}

.hero .wrap {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero-badge {
  width: min(340px, 80vw);
  justify-self: center;
}

.hero h1 {
  font-size: clamp(2.6rem, 6vw, 4.2rem);
  line-height: 0.98;
  margin-bottom: 0.25em;
}
.hero h1 em {
  font-style: normal;
  color: var(--periwinkle);
}

.hero .tagline {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--sage);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 1.25rem;
  margin-bottom: 1em;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: 22px 0 28px;
}
.hero-meta .chip {
  background: var(--navy);
  color: var(--cream);
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.85rem;
  padding: 8px 16px;
  border-radius: 999px;
}
.hero-meta .chip.alt { background: var(--sage); }

.hero-cta { display: flex; gap: 16px; flex-wrap: wrap; }

.triangle {
  position: absolute;
  width: 0; height: 0;
  border-style: solid;
}
.triangle-1 {
  top: -30px; right: -30px;
  border-width: 0 90px 120px 90px;
  border-color: transparent transparent var(--sage) transparent;
  opacity: 0.85;
  transform: rotate(12deg);
}
.triangle-2 {
  bottom: 20px; left: -40px;
  border-width: 0 60px 80px 60px;
  border-color: transparent transparent var(--pink) transparent;
  opacity: 0.7;
  transform: rotate(-18deg);
}

@media (max-width: 860px) {
  .hero .wrap { grid-template-columns: 1fr; text-align: center; }
  .hero-meta, .hero-cta { justify-content: center; }
  .triangle-1 { top: -10px; right: -10px; border-width: 0 50px 66px 50px; }
  .triangle-2 { display: none; }
}

/* ==========================================================================
   Events
   ========================================================================== */
.events { background: var(--navy); }
.events .section-head h2, .events .section-head p { color: var(--cream); }
.events .section-head .kicker { color: var(--pink); }
.events .section-head p { color: #d7dcef; }

.event-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.event-card {
  background: var(--cream);
  border-radius: 18px;
  padding: 26px 24px;
  position: relative;
  overflow: hidden;
}
.event-card .date {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.8rem;
  color: var(--navy);
  line-height: 1;
}
.event-card .day {
  font-family: var(--font-display);
  font-weight: 700;
  text-transform: uppercase;
  color: var(--periwinkle);
  letter-spacing: 0.08em;
  font-size: 0.9rem;
  margin-bottom: 14px;
  display: block;
}
.event-card .detail {
  font-size: 0.98rem;
  color: #333;
  margin: 4px 0;
}
.event-card .detail .pin { color: var(--periwinkle); margin-right: 4px; }
.event-card .badge {
  display: inline-block;
  margin-top: 12px;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--sage);
  background: rgba(122, 154, 149, 0.15);
  padding: 4px 10px;
  border-radius: 999px;
}
.event-card.special { background: var(--pink); }
.event-card.special .day { color: var(--navy); }

.event-note {
  margin-top: 28px;
  color: #d7dcef;
  font-size: 0.92rem;
}

.august-callout {
  margin-top: 32px;
  border: 2px dashed rgba(255,255,255,0.35);
  border-radius: 18px;
  padding: 22px 26px;
  color: var(--cream);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.august-callout strong { color: var(--pink); }

/* ==========================================================================
   Gallery
   ========================================================================== */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
.gallery-grid figure {
  margin: 0;
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  cursor: pointer;
}
.gallery-grid img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}
.gallery-grid figure:hover img { transform: scale(1.06); }
.gallery-grid figcaption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 8px 10px;
  font-size: 0.75rem;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #fff;
  background: linear-gradient(transparent, rgba(0,0,0,0.55));
  opacity: 0;
  transition: opacity 0.2s ease;
}
.gallery-grid figure:hover figcaption { opacity: 1; }

.gallery-grid figure.extra { display: none; }
.gallery-grid.expanded figure.extra { display: block; }

.gallery-more { text-align: center; margin-top: 32px; }
.gallery-more p { margin: 16px 0 0; }

@media (max-width: 860px) {
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
}

/* lightbox */
.lightbox {
  position: fixed; inset: 0;
  background: rgba(20, 20, 30, 0.92);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 40px;
}
.lightbox.open { display: flex; }
.lightbox img {
  max-width: 100%;
  max-height: 85vh;
  border-radius: 10px;
}
.lightbox-close {
  position: absolute;
  top: 24px; right: 32px;
  background: none;
  border: none;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
  line-height: 1;
}
.lightbox-nav {
  position: absolute;
  top: 50%; transform: translateY(-50%);
  background: rgba(255,255,255,0.15);
  border: none;
  color: #fff;
  font-size: 2rem;
  width: 52px; height: 52px;
  border-radius: 50%;
  cursor: pointer;
}
.lightbox-nav.prev { left: 24px; }
.lightbox-nav.next { right: 24px; }

/* partner modal */
.partner-cta { text-align: center; margin-top: 40px; }

.modal {
  position: fixed; inset: 0;
  background: rgba(20, 20, 30, 0.6);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 24px;
}
.modal.open { display: flex; }
.modal-card {
  position: relative;
  background: var(--cream);
  border-radius: 20px;
  max-width: 440px;
  width: 100%;
  padding: 40px;
  text-align: center;
}
.modal-card p { color: #333; }
.modal-close {
  position: absolute;
  top: 16px; right: 20px;
  background: none;
  border: none;
  font-size: 1.8rem;
  color: var(--navy);
  cursor: pointer;
  line-height: 1;
}

/* ==========================================================================
   About
   ========================================================================== */
.about .wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: start;
}
.about-copy p { color: #333; font-size: 1.05rem; }
.about-copy .founder {
  font-size: 0.95rem;
  color: var(--sage);
  font-weight: 700;
}

.how-to-join {
  background: var(--cream-dim);
  border-radius: 20px;
  padding: 32px;
}
.how-to-join h3 { margin-bottom: 16px; }
.how-to-join ol {
  margin: 0;
  padding-left: 22px;
}
.how-to-join li {
  margin-bottom: 14px;
  color: #333;
}
.how-to-join li strong { color: var(--navy); }

@media (max-width: 860px) {
  .about .wrap { grid-template-columns: 1fr; }
}

/* ==========================================================================
   Sponsors
   ========================================================================== */
.sponsors { background: var(--cream-dim); }

.sponsor-logos {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}
.sponsor-card {
  background: #fff;
  border-radius: 16px;
  padding: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 110px;
  filter: grayscale(1);
  opacity: 0.75;
  transition: filter 0.2s ease, opacity 0.2s ease, transform 0.2s ease;
}
.sponsor-card:hover {
  filter: grayscale(0);
  opacity: 1;
  transform: translateY(-3px);
}
.sponsor-card img { max-height: 60px; width: auto; margin: 0 auto; }
.sponsor-card.dark { background: var(--navy); }

.sponsor-text-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}
.sponsor-chip {
  font-family: var(--font-display);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--navy);
  background: #fff;
  border: 1px solid rgba(30,42,94,0.15);
  border-radius: 999px;
  padding: 10px 20px;
  font-size: 0.9rem;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background: var(--navy);
  color: var(--cream);
  padding: 56px 0 32px;
}
.footer-top {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 32px;
  margin-bottom: 32px;
}
.footer-brand { display: flex; align-items: center; gap: 12px; }
.footer-brand img { height: 40px; }
.footer-brand span {
  font-family: var(--font-display);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.footer-links { display: flex; gap: 40px; flex-wrap: wrap; }
.footer-links h4 {
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--pink);
  font-size: 0.85rem;
  margin-bottom: 12px;
}
.footer-links a {
  display: block;
  color: var(--cream);
  text-decoration: none;
  margin-bottom: 8px;
  font-size: 0.95rem;
  opacity: 0.9;
}
.footer-links a:hover { opacity: 1; text-decoration: underline; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.15);
  padding-top: 20px;
  font-size: 0.85rem;
  opacity: 0.75;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

@media (max-width: 600px) {
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .section { padding: 64px 0; }
}
