:root {
  --color-maroon: #7a1f2b;
  --color-maroon-dark: #5c1520;
  --color-gold: #c9a227;
  --color-gold-light: #e8d48b;
  --color-cream: #faf6f0;
  --color-cream-dark: #f0e8dc;
  --color-forest: #2d4a3e;
  --color-text: #2c2420;
  --color-text-muted: #5c5248;
  --color-white: #ffffff;
  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-body: "Source Sans 3", "Segoe UI", sans-serif;
  --shadow-soft: 0 4px 24px rgba(44, 36, 32, 0.08);
  --shadow-medium: 0 8px 32px rgba(44, 36, 32, 0.12);
  --radius: 12px;
  --radius-lg: 20px;
  --header-height: 80px;
  --max-width: 1140px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--color-text);
  background: var(--color-cream);
}

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

a {
  color: var(--color-maroon);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--color-maroon-dark);
}

.container {
  width: min(100% - 2.5rem, var(--max-width));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  z-index: 9999;
  padding: 0.75rem 1.25rem;
  background: var(--color-maroon);
  color: var(--color-white);
  border-radius: 0 0 var(--radius) var(--radius);
  text-decoration: none;
}

.skip-link:focus {
  top: 0;
}

/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(250, 246, 240, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(122, 31, 43, 0.1);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--header-height);
  gap: 1.5rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  text-decoration: none;
  color: inherit;
}

.logo-mark {
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.logo-text small {
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-maroon);
  max-width: 16rem;
  line-height: 1.3;
}

.site-nav ul {
  display: flex;
  gap: 0.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav a {
  display: block;
  padding: 0.625rem 1rem;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  color: var(--color-text);
  border-radius: 999px;
  transition: background 0.2s, color 0.2s;
}

.site-nav a:hover,
.site-nav a:focus-visible,
.site-nav a.is-active {
  background: rgba(122, 31, 43, 0.08);
  color: var(--color-maroon);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: none;
  border-radius: var(--radius);
  background: transparent;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 1.5rem;
  height: 2px;
  margin-inline: auto;
  background: var(--color-maroon);
  transition: transform 0.25s, opacity 0.25s;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Hero */

.hero {
  position: relative;
  overflow: hidden;
  padding: 5rem 0 6rem;
  background:
    linear-gradient(135deg, var(--color-maroon-dark) 0%, var(--color-maroon) 45%, #9a3a2f 100%);
  color: var(--color-white);
}

.hero-pattern {
  position: absolute;
  inset: 0;
  opacity: 0.08;
  background-image:
    radial-gradient(circle at 20% 30%, var(--color-gold) 1px, transparent 1px),
    radial-gradient(circle at 80% 70%, var(--color-gold) 1px, transparent 1px);
  background-size: 48px 48px;
}

.hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.hero-content {
  position: relative;
  max-width: 42rem;
}

/* Spinning globe */

.hero-journey {
  margin: 0;
  padding: 1.25rem;
  background: rgba(0, 0, 0, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(8px);
}

.globe-wrap {
  position: relative;
  width: 100%;
  max-width: 34rem;
  margin-inline: auto;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.globe-canvas {
  display: block;
  filter: drop-shadow(0 12px 32px rgba(0, 0, 0, 0.35));
  animation: globe-fade-in 0.8s ease both;
}

.globe-loading,
.globe-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1.5rem;
  color: rgba(255, 255, 255, 0.85);
}

.globe-loading[hidden],
.globe-fallback[hidden] {
  display: none;
}

.globe-loading {
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  color: var(--color-gold-light);
}

.globe-fallback p {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.6;
}

.journey-caption {
  margin: 1.25rem 0 0;
  padding-top: 1rem;
  font-size: 0.95rem;
  line-height: 1.5;
  text-align: center;
  color: rgba(255, 255, 255, 0.85);
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.journey-caption strong {
  color: var(--color-gold-light);
}

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

@keyframes globe-fade-in {
  from { opacity: 0; transform: scale(0.94); }
  to { opacity: 1; transform: scale(1); }
}

.hero-eyebrow {
  margin: 0 0 1rem;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-gold-light);
}

.hero h1 {
  margin: 0 0 1.25rem;
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 5vw, 3.75rem);
  font-weight: 700;
  line-height: 1.15;
}

.hero-lead {
  margin: 0 0 2rem;
  font-size: 1.2rem;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.92);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.875rem 1.75rem;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 999px;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: var(--color-gold);
  color: var(--color-maroon-dark);
  box-shadow: var(--shadow-soft);
}

.btn-primary:hover {
  background: var(--color-gold-light);
  color: var(--color-maroon-dark);
}

.btn-secondary {
  background: transparent;
  color: var(--color-white);
  border: 2px solid rgba(255, 255, 255, 0.5);
}

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

/* Sections */

.section {
  padding: 5rem 0;
}

.section-label {
  margin: 0 0 0.5rem;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-gold);
}

.section-header h2,
.split-content h2,
.about-text h2,
.contact-layout h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-maroon-dark);
}

.section-header.centered {
  text-align: center;
  max-width: 40rem;
  margin-inline: auto;
  margin-bottom: 3rem;
}

.section-intro {
  margin: 1rem 0 0;
  color: var(--color-text-muted);
}

/* Heritage */

.heritage {
  background: var(--color-white);
}

.content-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  margin-top: 2.5rem;
}

.content-card {
  padding: 1.75rem;
  background: var(--color-cream);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(122, 31, 43, 0.08);
  transition: box-shadow 0.25s, transform 0.25s;
}

.content-card:hover {
  box-shadow: var(--shadow-soft);
  transform: translateY(-3px);
}

.content-card h3 {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--color-maroon);
}

.content-card p {
  margin: 0;
  color: var(--color-text-muted);
}

/* Edmonton */

.edmonton {
  background: var(--color-cream-dark);
}

.split-layout {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 3rem;
  align-items: center;
}

.split-content p {
  color: var(--color-text-muted);
}

.highlight-panel {
  padding: 2.5rem;
  background: var(--color-forest);
  color: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-medium);
}

.highlight-panel blockquote {
  margin: 0;
}

.highlight-panel p {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-style: italic;
  line-height: 1.5;
}

/* About */

.about-card {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 3rem;
  align-items: center;
  padding: 3rem;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(122, 31, 43, 0.08);
}

.about-purpose {
  font-size: 1.25rem;
  color: var(--color-text);
}

.about-text p:last-child {
  color: var(--color-text-muted);
}

.about-visual {
  display: flex;
  justify-content: center;
}

.about-logo {
  width: 12rem;
  height: 12rem;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: var(--shadow-medium);
}

/* Programs */

.programs {
  background: var(--color-white);
}

.program-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1.25rem;
}

.program-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.5rem;
  align-items: start;
  padding: 1.75rem 2rem;
  background: var(--color-cream);
  border-radius: var(--radius-lg);
  border-left: 4px solid var(--color-gold);
  transition: box-shadow 0.25s;
}

.program-item:hover {
  box-shadow: var(--shadow-soft);
}

.program-icon {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--color-maroon);
  opacity: 0.35;
  line-height: 1;
}

.program-item h3 {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: var(--color-maroon-dark);
}

.program-item p {
  margin: 0;
  color: var(--color-text-muted);
}

/* Membership Form */

.membership {
  background: var(--color-cream-dark);
}

.membership-form {
  max-width: 42rem;
  margin-inline: auto;
  padding: 2.5rem;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(122, 31, 43, 0.08);
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-field-full {
  grid-column: 1 / -1;
}

.form-field label {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--color-text);
}

.required {
  color: var(--color-maroon);
}

.optional {
  font-weight: 400;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.form-field input,
.form-field textarea {
  width: 100%;
  padding: 0.875rem 1rem;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.5;
  color: var(--color-text);
  background: var(--color-cream);
  border: 2px solid transparent;
  border-radius: var(--radius);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-field input:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--color-maroon);
  box-shadow: 0 0 0 3px rgba(122, 31, 43, 0.12);
}

.form-field input:invalid:not(:placeholder-shown),
.form-field textarea:invalid:not(:placeholder-shown),
.form-field input.is-invalid,
.form-field textarea.is-invalid {
  border-color: #b33a3a;
}

.form-field textarea {
  resize: vertical;
  min-height: 5rem;
}

.field-error {
  min-height: 1.25rem;
  font-size: 0.875rem;
  color: #b33a3a;
}

.form-note {
  margin: 1.25rem 0 0;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

.form-checkbox-field {
  margin-top: 0.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--color-cream-dark);
}

.checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: 0.875rem;
  padding: 1.25rem;
  background: var(--color-cream);
  border-radius: var(--radius);
  border: 2px solid transparent;
  transition: border-color 0.2s;
}

.checkbox-group.is-invalid {
  border-color: #b33a3a;
}

.checkbox-group input[type="checkbox"] {
  flex-shrink: 0;
  width: 1.25rem;
  height: 1.25rem;
  margin-top: 0.2rem;
  accent-color: var(--color-maroon);
  cursor: pointer;
}

.checkbox-group label {
  font-weight: 500;
  font-size: 1rem;
  line-height: 1.55;
  color: var(--color-text);
  cursor: pointer;
}

.dues-note {
  margin: 0.75rem 0 0 1.25rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--color-maroon);
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2rem;
}

.form-actions .btn {
  border: none;
  cursor: pointer;
}

.btn-outline {
  background: transparent;
  color: var(--color-maroon);
  border: 2px solid var(--color-maroon) !important;
}

.btn-outline:hover {
  background: rgba(122, 31, 43, 0.08);
  color: var(--color-maroon-dark);
}

.form-success {
  max-width: 42rem;
  margin-inline: auto;
  padding: 2.5rem;
  text-align: center;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  border: 2px solid var(--color-forest);
}

.form-success h3 {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-size: 1.75rem;
  color: var(--color-forest);
}

.form-success p {
  margin: 0 0 1.5rem;
  color: var(--color-text-muted);
}

/* Contact */

.contact {
  background: linear-gradient(180deg, var(--color-cream-dark), var(--color-cream));
}

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

.contact-layout > div > p {
  color: var(--color-text-muted);
}

.contact-card {
  padding: 2rem;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
}

.contact-card h3 {
  margin: 0 0 1.25rem;
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--color-maroon);
}

.contact-details {
  list-style: none;
  margin: 0 0 1.25rem;
  padding: 0;
}

.contact-details li {
  display: grid;
  gap: 0.25rem;
  padding: 0.875rem 0;
  border-bottom: 1px solid var(--color-cream-dark);
}

.contact-details li:last-child {
  border-bottom: none;
}

.contact-label {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-gold);
}

.contact-note {
  margin: 0;
  font-size: 0.95rem;
  color: var(--color-text-muted);
}

/* Footer */

.site-footer {
  padding: 2rem 0;
  background: var(--color-maroon-dark);
  color: rgba(255, 255, 255, 0.85);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.footer-inner p {
  margin: 0;
  font-size: 0.95rem;
}

.back-to-top {
  color: var(--color-gold-light);
  text-decoration: none;
  font-weight: 600;
}

.back-to-top:hover {
  color: var(--color-white);
}

/* Responsive */

@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .hero-journey {
    max-width: 36rem;
    margin-inline: auto;
  }

  .split-layout,
  .about-card,
  .contact-layout {
    grid-template-columns: 1fr;
  }

  .about-visual {
    order: -1;
  }

  .about-logo {
    width: 9rem;
    height: 9rem;
  }
}

@media (max-width: 768px) {
  body {
    font-size: 1.05rem;
  }

  .nav-toggle {
    display: flex;
  }

  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-cream);
    border-bottom: 1px solid rgba(122, 31, 43, 0.1);
    padding: 1rem;
    display: none;
  }

  .site-nav.is-open {
    display: block;
  }

  .site-nav ul {
    flex-direction: column;
  }

  .site-nav a {
    padding: 0.875rem 1rem;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .hero-journey {
    order: -1;
    max-width: 32rem;
    margin-inline: auto;
  }

  .hero {
    padding: 4rem 0 5rem;
  }

  .section {
    padding: 3.5rem 0;
  }

  .about-card {
    padding: 2rem;
  }

  .program-item {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .membership-form {
    padding: 1.75rem;
  }
}

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

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

  .globe-canvas {
    animation: none;
  }
}
