/* COSRT 50th Anniversary — site styles
   System font stacks only (no third-party font requests — see privacy.html). */

:root {
  --navy-900: #14273e;
  --navy-700: #1f3d5c;
  --navy-500: #2c4a63;
  --gold-500: #c9a227;
  --gold-300: #e3c565;
  --cream-100: #faf7f0;
  --cream-200: #f1ead9;
  --ink-900: #1c1c1c;
  --ink-600: #4a4a4a;
  --white: #ffffff;

  --font-heading: Georgia, "Times New Roman", serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 1rem;
  --space-4: 1.5rem;
  --space-5: 2.5rem;
  --space-6: 4rem;

  --max-width: 68rem;
  --radius: 6px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink-900);
  background: var(--cream-100);
}

h1, h2, h3 {
  font-family: var(--font-heading);
  line-height: 1.2;
  color: var(--navy-900);
}

h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.125rem); }
h3 { font-size: 1.25rem; }

a {
  color: var(--navy-700);
}

a:hover {
  color: var(--gold-500);
}

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

/* ---------- Header / nav ---------- */

.site-header {
  background: var(--navy-900);
  color: var(--white);
}

.site-header__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--space-3) var(--space-4);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
}

.site-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  color: var(--white);
  text-decoration: none;
}

.site-title strong {
  color: var(--gold-300);
  font-weight: normal;
}

.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

.site-nav a {
  color: var(--white);
  text-decoration: none;
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius);
}

.site-nav a:hover {
  background: var(--navy-500);
  color: var(--white);
}

.site-nav a[aria-current="page"] {
  color: var(--gold-300);
  border-bottom: 2px solid var(--gold-300);
  border-radius: 0;
}

/* ---------- Hero ---------- */

.hero {
  background: linear-gradient(135deg, var(--navy-900) 0%, var(--navy-500) 100%);
  color: var(--white);
  text-align: center;
  padding: var(--space-6) var(--space-4);
}

.hero__badge {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: clamp(4rem, 12vw, 7rem);
  line-height: 1;
  color: var(--gold-300);
  margin: 0 0 var(--space-2);
}

.hero h1 {
  color: var(--white);
  margin: 0 0 var(--space-3);
}

.hero p {
  max-width: 46rem;
  margin: 0 auto var(--space-4);
  font-size: 1.125rem;
}

/* ---------- Layout blocks ---------- */

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-4);
}

.section {
  padding: var(--space-5) 0;
}

.section--tint {
  background: var(--cream-200);
}

.section__intro {
  max-width: 46rem;
}

.card-grid {
  list-style: none;
  padding: 0;
  margin: var(--space-4) 0 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
  gap: var(--space-4);
}

.card {
  background: var(--white);
  border: 1px solid var(--cream-200);
  border-radius: var(--radius);
  padding: var(--space-4);
}

.card h3 {
  margin-top: 0;
}

/* ---------- Buttons ---------- */

.button {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  text-decoration: none;
  font-weight: 600;
  border: 2px solid var(--gold-500);
  background: var(--gold-500);
  color: var(--navy-900);
}

.button:hover {
  background: var(--gold-300);
  border-color: var(--gold-300);
  color: var(--navy-900);
}

.button--ghost {
  background: transparent;
  color: var(--white);
}

.button--ghost:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--white);
}

/* ---------- Gallery / carousel ---------- */

.gallery-section {
  padding: var(--space-5) 0;
}

.gallery-section--tint {
  background: var(--cream-200);
}

.gallery-section--pending p {
  font-style: italic;
  color: var(--ink-600);
}

.swiper {
  aspect-ratio: 3 / 2;
  max-width: 56rem;
  margin: var(--space-4) auto 0;
  background: var(--navy-900);
  border-radius: var(--radius);
  overflow: hidden;
}

.swiper-slide {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* The <a> is the flex item that shrinks to make room for the caption;
   the image then fills it without overflowing (portrait photos included). */
.swiper-slide a {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
}

.swiper-slide img {
  width: auto;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.slide-caption {
  margin: 0;
  padding: 0.5rem 1rem;
  width: 100%;
  flex: 0 0 auto;
  color: var(--cream-100);
  font-size: 0.9375rem;
  text-align: center;
}

.gallery-note {
  text-align: center;
  color: var(--ink-600);
  font-size: 0.9375rem;
}

/* Swiper colour overrides */

.swiper .swiper-pagination-bullet-active {
  background: var(--gold-300);
}

.swiper-button-prev,
.swiper-button-next {
  color: var(--gold-300);
}

/* PhotoSwipe custom caption (registered in js/gallery.js) */

.pswp__custom-caption {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 16px);
  max-width: 28rem;
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius);
  background: rgba(20, 39, 62, 0.85);
  color: var(--cream-100);
  font-size: 0.9rem;
  text-align: center;
}

/* ---------- Timeline skeleton ---------- */

.timeline {
  list-style: none;
  padding: 0;
  margin: var(--space-4) 0 0;
  border-left: 3px solid var(--gold-500);
}

.timeline li {
  position: relative;
  padding: 0 0 var(--space-4) var(--space-4);
}

.timeline li::before {
  content: "";
  position: absolute;
  left: -0.5rem;
  top: 0.4rem;
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 50%;
  background: var(--gold-500);
}

.timeline time {
  font-weight: 700;
  color: var(--navy-700);
}

/* ---------- Footer ---------- */

.site-footer {
  background: var(--navy-900);
  color: var(--cream-100);
  margin-top: var(--space-6);
  padding: var(--space-4) 0;
  font-size: 0.9375rem;
}

.site-footer .container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--space-3);
}

.site-footer a {
  color: var(--cream-100);
}

.site-footer a:hover {
  color: var(--gold-300);
}

.site-footer__legal p {
  margin: 0 0 var(--space-1);
}

.site-footer__disclaimer {
  font-size: 0.8125rem;
  max-width: 34rem;
  color: rgba(250, 247, 240, 0.75);
}

/* ---------- Callout notice (about.html, privacy.html) ---------- */

.notice {
  border: 2px solid var(--gold-500);
  border-radius: var(--radius);
  background: var(--white);
  padding: var(--space-4);
  margin: var(--space-4) 0;
}

.notice p:first-child {
  margin-top: 0;
}

.notice p:last-child {
  margin-bottom: 0;
}

/* ---------- Utilities ---------- */

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

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

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
