:root {
  --purple: #542e75;
  --purple-dark: #3d2058;
  --purple-soft: #f3eef7;
  --white: #ffffff;
  --ink: #25212a;
  --muted: #625c68;
  --line: #e7e0ec;
  --page: #fbfafc;
  --shadow: 0 14px 40px rgba(47, 30, 62, 0.10);
  --radius: 18px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--page);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}

a { color: inherit; }

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

.section-wrap {
  width: min(1160px, calc(100% - 40px));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255,255,255,0.97);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(10px);
}

.header-inner {
  width: min(1220px, calc(100% - 36px));
  min-height: 92px;
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: 28px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--purple);
  font-weight: 750;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.brand img { width: 112px; height: auto; }

.site-nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 2px;
}

.site-nav a {
  text-decoration: none;
  font-weight: 650;
  font-size: 0.94rem;
  padding: 12px 11px;
  border-radius: 10px;
  color: #4a4350;
}

.site-nav a:hover,
.site-nav a:focus-visible,
.site-nav a.active {
  color: var(--purple);
  background: var(--purple-soft);
}

.nav-toggle,
.nav-toggle-label { display: none; }

.hero {
  position: relative;
  min-height: 430px;
  overflow: hidden;
  background: var(--purple-dark);
}

.hero > img {
  width: 100%;
  height: 430px;
  object-fit: cover;
  object-position: center;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(40,19,57,.82) 0%, rgba(84,46,117,.54) 42%, rgba(84,46,117,.10) 72%, rgba(84,46,117,0) 100%);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  width: min(1160px, calc(100% - 40px));
  margin-inline: auto;
  display: flex;
  align-items: center;
}

.hero-copy {
  max-width: 610px;
  color: white;
  padding: 34px 0;
  text-shadow: 0 2px 18px rgba(0,0,0,.28);
}

.eyebrow {
  margin: 0 0 8px;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.eyebrow.purple { color: var(--purple); }

.hero h1 {
  margin: 0;
  font-size: clamp(2.6rem, 6vw, 5rem);
  line-height: 0.98;
  letter-spacing: -0.045em;
}

.hero-copy > p:last-child {
  max-width: 540px;
  margin: 20px 0 0;
  font-size: clamp(1rem, 2vw, 1.22rem);
  line-height: 1.55;
}

.intro {
  max-width: 840px;
  padding: 66px 0 24px;
  text-align: center;
  font-size: 1.06rem;
  color: var(--muted);
}

.intro-lead {
  margin: 0 0 12px;
  color: var(--purple);
  font-size: clamp(1.55rem, 3vw, 2.15rem);
  font-weight: 800;
  letter-spacing: -0.025em;
}

.intro p:last-child { margin: 0; }

.quick-links { padding: 44px 0 82px; }

.section-heading {
  text-align: center;
  margin-bottom: 30px;
}

.section-heading h2,
.about-strip h2 {
  margin: 0;
  color: var(--purple-dark);
  font-size: clamp(1.8rem, 3.5vw, 2.7rem);
  line-height: 1.15;
  letter-spacing: -0.035em;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.feature-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  transition: transform .18s ease, box-shadow .18s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 46px rgba(47, 30, 62, 0.15);
}

.icon-circle {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  margin-bottom: 22px;
  background: var(--purple-soft);
  color: var(--purple);
  font-size: 1.35rem;
  font-weight: 800;
}

.feature-card h3 {
  margin: 0 0 8px;
  color: var(--purple);
  font-size: 1.35rem;
}

.feature-card p {
  margin: 0 0 26px;
  color: var(--muted);
}

.button {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 11px 18px;
  border-radius: 999px;
  background: var(--purple);
  color: white;
  text-decoration: none;
  font-weight: 750;
  font-size: .94rem;
  transition: background .18s ease, transform .18s ease;
}

.button:hover,
.button:focus-visible {
  background: var(--purple-dark);
  transform: translateY(-1px);
}

.about-strip {
  background: var(--purple);
  color: white;
}

.about-strip-inner {
  min-height: 270px;
  padding-block: 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 44px;
}

.about-strip-inner > div { max-width: 760px; }

.about-strip h2 { color: white; margin-bottom: 14px; }
.about-strip p { margin: 0; max-width: 720px; }

.button-light {
  flex: 0 0 auto;
  color: var(--purple);
  background: white;
}

.button-light:hover,
.button-light:focus-visible {
  color: var(--purple-dark);
  background: #f6f0f8;
}

.site-footer {
  background: #2b1c36;
  color: rgba(255,255,255,.83);
  font-size: .9rem;
}

.footer-inner {
  min-height: 100px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-inner p { margin: 0; }

.footer-inner nav { display: flex; gap: 18px; flex-wrap: wrap; }
.footer-inner a { text-decoration: none; }
.footer-inner a:hover { color: white; }

@media (max-width: 940px) {
  .brand span { display: none; }
  .card-grid { grid-template-columns: 1fr; }
  .feature-card { min-height: auto; }
}

@media (max-width: 760px) {
  .header-inner { min-height: 78px; }
  .brand img { width: 96px; }

  .nav-toggle-label {
    display: grid;
    gap: 5px;
    width: 44px;
    height: 44px;
    margin-left: auto;
    place-content: center;
    cursor: pointer;
    border-radius: 10px;
    background: var(--purple-soft);
  }

  .nav-toggle-label span {
    display: block;
    width: 21px;
    height: 2px;
    background: var(--purple);
    border-radius: 3px;
  }

  .site-nav {
    position: absolute;
    display: none;
    top: 78px;
    left: 0;
    right: 0;
    margin: 0;
    padding: 12px 20px 20px;
    background: white;
    border-bottom: 1px solid var(--line);
    box-shadow: 0 12px 22px rgba(50, 30, 64, .09);
  }

  .site-nav a { display: block; padding: 13px 14px; }
  .nav-toggle:checked ~ .site-nav { display: block; }

  .hero,
  .hero > img { min-height: 390px; height: 390px; }
  .hero > img { object-position: 58% center; }
  .hero::after { background: linear-gradient(90deg, rgba(39,18,55,.86), rgba(84,46,117,.48)); }

  .intro { padding-top: 48px; }
  .quick-links { padding-top: 32px; padding-bottom: 56px; }
  .feature-card { padding: 26px; }

  .about-strip-inner {
    align-items: flex-start;
    flex-direction: column;
    gap: 26px;
  }

  .footer-inner {
    padding-block: 28px;
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}


/* Interior pages */
.page-hero { background: linear-gradient(135deg,var(--purple-dark),var(--purple)); color:#fff; }
.page-hero .section-wrap { padding: 70px 0 64px; }
.page-hero .eyebrow { color:#e5d8ef; }
.page-hero h1 { margin:0; font-size:clamp(2.35rem,5vw,4.3rem); line-height:1; letter-spacing:-.045em; }
.page-hero p:last-child { max-width:760px; margin:18px 0 0; color:rgba(255,255,255,.88); font-size:1.08rem; }
.content-section { padding:64px 0; }
.content-section + .content-section { padding-top:0; }
.prose { max-width:860px; }
.prose h2 { color:var(--purple-dark); font-size:clamp(1.65rem,3vw,2.35rem); line-height:1.2; letter-spacing:-.03em; margin:0 0 18px; }
.prose h3 { color:var(--purple); font-size:1.25rem; margin:34px 0 10px; }
.prose p { color:var(--muted); margin:0 0 18px; }
.prose .lead { color:var(--ink); font-size:1.15rem; }
.two-col { display:grid; grid-template-columns:minmax(0,1.5fr) minmax(260px,.8fr); gap:46px; align-items:start; }
.info-panel { background:var(--purple-soft); border:1px solid var(--line); border-radius:var(--radius); padding:28px; }
.info-panel h3 { color:var(--purple); margin:0 0 10px; }
.info-panel p { margin:0 0 16px; color:var(--muted); }
.info-panel p:last-child { margin-bottom:0; }
.notice { padding:18px 20px; border-radius:14px; background:#fff8df; border:1px solid #ead996; color:#5d5028; margin:18px 0; }
.outing-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:20px; }
.outing-card { background:#fff; border:1px solid var(--line); border-radius:var(--radius); padding:28px; box-shadow:var(--shadow); }
.outing-card .date { color:var(--purple); font-weight:800; margin:0 0 5px; }
.outing-card h2 { color:var(--purple-dark); margin:0 0 6px; font-size:1.45rem; }
.outing-card .address { font-weight:650; color:var(--ink); }
.outing-card p { color:var(--muted); margin:10px 0 0; }
.outing-card.tbc { background:var(--purple-soft); box-shadow:none; }
.year-section { margin-top:46px; }
.year-section:first-child { margin-top:0; }
.year-heading { display:flex; align-items:center; gap:14px; margin-bottom:18px; }
.year-heading h2 { margin:0; color:var(--purple-dark); font-size:2rem; }
.year-heading::after { content:""; height:1px; background:var(--line); flex:1; }
.report-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:18px; }
.report-card { background:#fff; border:1px solid var(--line); border-radius:16px; padding:24px; }
.report-card time { display:block; color:var(--purple); font-size:.82rem; font-weight:800; text-transform:uppercase; letter-spacing:.07em; }
.report-card h3 { margin:7px 0 8px; color:var(--purple-dark); font-size:1.25rem; }
.report-card p { margin:0; color:var(--muted); }
.report-card .report-link { display:inline-block; margin-top:16px; color:var(--purple); font-weight:750; text-decoration:none; }
.report-card .report-link:hover { text-decoration:underline; }
.report-card .coming { margin-top:16px; display:inline-block; font-size:.82rem; font-weight:750; color:#73677b; background:var(--purple-soft); border-radius:999px; padding:6px 10px; }
.history-block { display:grid; grid-template-columns:minmax(0,1.35fr) minmax(250px,.65fr); gap:34px; align-items:start; margin-bottom:34px; }
.history-block.reverse { grid-template-columns:minmax(250px,.65fr) minmax(0,1.35fr); }
.history-block img { width:100%; border-radius:16px; box-shadow:var(--shadow); }
.photo-caption { margin:8px 0 0; text-align:center; font-size:.87rem; color:var(--muted); }
.history-gallery { display:grid; grid-template-columns:repeat(3,1fr); gap:14px; margin-top:28px; }
.history-gallery figure { margin:0; }
.history-gallery img { width:100%; aspect-ratio:4/3; object-fit:cover; border-radius:14px; }
.contact-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:22px; max-width:820px; }
.contact-card { background:#fff; border:1px solid var(--line); border-radius:var(--radius); padding:30px; box-shadow:var(--shadow); }
.contact-card h2 { color:var(--purple); margin:0 0 8px; }
.contact-card p { color:var(--muted); }
.contact-card .button { margin-top:10px; }
.report-article { max-width:820px; }
.report-article .report-meta { color:var(--purple); font-weight:800; text-transform:uppercase; letter-spacing:.08em; font-size:.82rem; }
.report-article h1 { color:var(--purple-dark); font-size:clamp(2rem,4vw,3.4rem); line-height:1.05; letter-spacing:-.04em; }
.report-placeholder { background:var(--purple-soft); border:1px solid var(--line); padding:24px; border-radius:16px; color:var(--muted); margin:28px 0; }
@media (max-width:800px) { .two-col,.history-block,.history-block.reverse { grid-template-columns:1fr; } .outing-grid,.report-grid,.contact-grid { grid-template-columns:1fr; } .history-gallery { grid-template-columns:repeat(2,1fr); } }
@media (max-width:520px) { .history-gallery { grid-template-columns:1fr; } .page-hero .section-wrap { padding:54px 0 50px; } }


/* Rally report archive and article additions */
.report-year-nav{display:flex;gap:10px;flex-wrap:wrap;margin:0 0 28px;}
.year-pill{display:inline-flex;align-items:center;justify-content:center;min-height:40px;padding:9px 16px;border-radius:999px;background:var(--purple-soft);border:1px solid var(--line);color:var(--purple);font-weight:750;text-decoration:none;}
.year-pill.active,.year-pill:hover{background:var(--purple);color:#fff;border-color:var(--purple);}
.archive-intro{margin-bottom:28px;}
.archive-links-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px;}
.archive-link-card{display:flex;flex-direction:column;gap:6px;padding:24px;border-radius:18px;background:#fff;border:1px solid var(--line);box-shadow:var(--shadow);text-decoration:none;}
.archive-link-card strong{color:var(--purple-dark);font-size:1.12rem;}
.archive-link-card span{color:var(--muted);}
.archive-link-year{color:var(--purple);font-weight:800;letter-spacing:.08em;text-transform:uppercase;font-size:.8rem;}
.report-grid-archive{grid-template-columns:1fr;}
.report-card--thumb{padding:0;overflow:hidden;display:grid;grid-template-columns:minmax(190px,240px) minmax(0,1fr);box-shadow:var(--shadow);align-items:stretch;}
.report-thumb{display:block;height:100%;min-height:180px;background:var(--purple-soft);}
.report-thumb img{width:100%;height:100%;object-fit:cover;}
.report-card-body{padding:22px 24px;display:flex;flex-direction:column;}
.report-card-body h3{margin:7px 0 8px;}
.report-title-link{text-decoration:none;color:inherit;}
.report-title-link:hover{text-decoration:underline;}
.back-link{margin:0 0 18px;}
.back-link a{color:var(--purple);font-weight:700;text-decoration:none;}
.back-link a:hover{text-decoration:underline;}
.report-feature{margin:0 0 26px;}
.report-feature img{width:100%;max-height:460px;object-fit:cover;border-radius:18px;box-shadow:var(--shadow);}
.report-body p{margin:0 0 18px;color:var(--muted);}
.report-body figure{margin:28px 0;}
.report-body img{width:100%;height:auto;border-radius:16px;box-shadow:var(--shadow);}
.report-body figcaption{margin-top:8px;text-align:center;color:var(--muted);font-size:.9rem;}
.report-body table{width:100%;border-collapse:collapse;margin:22px 0;background:#fff;border:1px solid var(--line);}
.report-body td,.report-body th{border:1px solid var(--line);padding:10px 12px;vertical-align:top;color:var(--muted);}
@media (max-width:900px){.archive-links-grid{grid-template-columns:1fr;}.report-card--thumb{grid-template-columns:1fr;}.report-thumb{min-height:220px;}}


/* Smaller rally report images for low-resolution source material */
.report-feature { text-align: center; }
.report-feature img {
  width: auto;
  max-width: min(100%, 560px);
  max-height: 380px;
  margin-inline: auto;
  object-fit: contain;
}
.report-body figure { text-align: center; }
.report-body img {
  width: auto;
  max-width: min(100%, 480px);
  max-height: 420px;
  margin-inline: auto;
  object-fit: contain;
}
@media (max-width: 600px) {
  .report-feature img,
  .report-body img {
    max-width: 100%;
    max-height: none;
  }
}


/* Magazine-style rally report image layout */
.report-article {
  max-width: 900px;
}

/* Keep the opening/feature image modest so low-resolution images are not enlarged. */
.report-feature {
  text-align: center;
  margin: 0 0 28px;
}
.report-feature img {
  width: auto;
  max-width: min(100%, 520px);
  max-height: 360px;
  margin-inline: auto;
  object-fit: contain;
}

/* Smaller photos can sit within the story and let the text flow around them. */
.report-body figure.report-photo-left,
.report-body figure.report-photo-right {
  width: min(34%, 280px);
  margin-top: 5px;
  margin-bottom: 18px;
  clear: both;

  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: white;
}
.report-body figure.report-photo-left {
  float: left;
  margin-left: 0;
  margin-right: 24px;
}

.report-body figure.report-photo-right {
  float: right;
  margin-right: 0;
  margin-left: 24px;
}

.report-body figure.report-photo-centre {
  clear: both;
  width: min(100%, 460px);
  margin: 26px auto;

  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: white;
}

.report-body figure.report-photo-left img,
.report-body figure.report-photo-right img,
.report-body figure.report-photo-centre img {
  width: 100%;
  height: auto;
  max-width: none;
  max-height: none;
  margin: 0;
  display: block;

  border-radius: 0;
  box-shadow: none;
}
.report-body figure.report-photo-left figcaption,
.report-body figure.report-photo-right figcaption,
.report-body figure.report-photo-centre figcaption {
  margin-top: 7px;
  line-height: 1.35;
}
.report-float-clear {
  clear: both;
}

/* Avoid narrow text columns on tablets and phones. */
@media (max-width: 720px) {
  .report-body figure.report-photo-left,
  .report-body figure.report-photo-right,
  .report-body figure.report-photo-centre {
    float: none;
    clear: both;
    width: min(100%, 420px);
    margin: 24px auto;
  }
  .report-feature img,
  .report-body figure img {
    max-height: none;
  }
}
