/*! HTML5 Boilerplate v9.0.1 | MIT License | https://html5boilerplate.com/ */

/* main.css 3.0.0 | MIT License | https://github.com/h5bp/main.css#readme */
/*
 * What follows is the result of much research on cross-browser styling.
 * Credit left inline and big thanks to Nicolas Gallagher, Jonathan Neal,
 * Kroc Camen, and the H5BP dev community and team.
 */

/* ==========================================================================
   Base styles: opinionated defaults
   ========================================================================== */

html {
  color: #222;
  font-size: 1em;
  line-height: 1.4;
}

/*
 * Remove text-shadow in selection highlight:
 * https://twitter.com/miketaylr/status/12228805301
 *
 * Customize the background color to match your design.
 */

::-moz-selection {
  background: #b3d4fc;
  text-shadow: none;
}

::selection {
  background: #b3d4fc;
  text-shadow: none;
}

/*
 * A better looking default horizontal rule
 */

hr {
  display: block;
  height: 1px;
  border: 0;
  border-top: 1px solid #ccc;
  margin: 1em 0;
  padding: 0;
}

/*
 * Remove the gap between audio, canvas, iframes,
 * images, videos and the bottom of their containers:
 * https://github.com/h5bp/html5-boilerplate/issues/440
 */

audio,
canvas,
iframe,
img,
svg,
video {
  vertical-align: middle;
}

/*
 * Remove default fieldset styles.
 */

fieldset {
  border: 0;
  margin: 0;
  padding: 0;
}

/*
 * Allow only vertical resizing of textareas.
 */

textarea {
  resize: vertical;
}

/* ==========================================================================
   Author's custom styles
   ========================================================================== */

/* ===== CSS Variables & Reset ===== */
:root {
  /* Colors from original Squarespace theme */
  --white: #fff;
  --black: #1a1a1a;
  --dark: #1d1d1d;
  --bright-bg: #1E303F;
  --light-bg: #f5f5f4;
  --accent: #99B1AC;
  --light-accent: #d4e4df;
  --text-dark: #1a1a1a;
  --text-light: #fff;
  --text-muted: #545454;

  /* Spacing */
  --site-gutter: 4vw;
  --max-width: 1200px;

  /* Fonts - matching original */
  --heading-font: 'Poppins', sans-serif;
  --body-font: 'Montserrat', sans-serif;
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--body-font);
  font-size: 16px;
  line-height: 1.68;
  color: var(--text-dark);
  background: var(--white);
  overflow-x: hidden;
}

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

a {
  color: inherit;
  text-decoration: none;
}

ul {
  list-style: disc;
  padding-left: 20px;
}

h1, h2, h3, h4 {
  font-family: var(--heading-font);
  font-weight: 600;
  line-height: 1.3;
}

h2 {
  font-size: clamp(1.5rem, 3vw, 2.2rem);
}

h3 {
  font-size: clamp(1.25rem, 2.5vw, 1.75rem);
}

h4 {
  font-size: 1.1rem;
}

p {
  margin-bottom: 0.75em;
}

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

/* ===== Buttons ===== */
.btn {
  display: inline-block;
  padding: 14px 28px;
  font-family: var(--body-font);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.btn-primary {
  background: var(--text-dark);
  color: var(--white);
  border-color: var(--text-dark);
  border-radius: 50px;
}

.btn-primary:hover {
  background: transparent;
  color: var(--text-dark);
}

/* Theme-specific button overrides */
.dark-theme .btn-primary,
.black-theme .btn-primary {
  background: var(--white);
  color: var(--black);
  border-color: var(--white);
}

.dark-theme .btn-primary:hover,
.black-theme .btn-primary:hover {
  background: transparent;
  color: var(--white);
}

/* ===== Header ===== */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 2.3vw var(--site-gutter);
  transition: transform 0.4s ease, background 0.3s ease;
}

.site-header.scrolled-down {
  transform: translateY(-100%);
}

.site-header.scrolled-up {
  transform: translateY(0);
  background: rgba(0, 0, 0, 0.45);
}

.header-gradient {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.35) 0%, transparent 100%);
  pointer-events: none;
  z-index: -1;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--max-width);
  margin: 0 auto;
}

.header-logo img {
  height: 77px;
  width: auto;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 1.5em;
}

.nav-link {
  font-family: var(--body-font);
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--white);
  padding: 8px 0;
  transition: opacity 0.2s ease;
}

.nav-link:hover {
  opacity: 0.7;
}

/* Dropdown */
.nav-dropdown {
  position: relative;
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: var(--white);
  min-width: 220px;
  padding: 12px 0;
  border-radius: 4px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.12);
  z-index: 100;
}

.nav-dropdown:hover .dropdown-menu {
  display: block;
}

.dropdown-menu a {
  display: block;
  padding: 8px 20px;
  font-size: 0.8rem;
  color: var(--text-dark);
  transition: background 0.2s;
}

.dropdown-menu a:hover {
  background: var(--light-bg);
}

/* Burger */
.burger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
}

.burger-inner {
  width: 28px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.top-bun, .bottom-bun {
  height: 1px;
  background: var(--white);
  transition: all 0.3s ease;
}

.burger.active .top-bun {
  transform: rotate(45deg) translateY(4.5px);
}

.burger.active .bottom-bun {
  transform: rotate(-45deg) translateY(-4.5px);
}

/* Mobile Menu */
.mobile-menu {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--bright-bg);
  z-index: 999;
  padding: 100px var(--site-gutter) 40px;
  overflow-y: auto;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.mobile-menu.open {
  display: block;
  opacity: 1;
}

.mobile-nav {
  display: flex;
  flex-direction: column;
}

.mobile-nav-link,
.mobile-folder-toggle {
  display: block;
  padding: 12px 0;
  font-family: var(--heading-font);
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--white);
  border: none;
  background: none;
  text-align: left;
  cursor: pointer;
  width: 100%;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.mobile-folder-content {
  display: none;
  padding-left: 20px;
}

.mobile-folder-content.open {
  display: block;
}

.mobile-folder-content a {
  display: block;
  padding: 10px 0;
  font-size: 0.95rem;
  color: rgba(255,255,255,0.8);
}

/* ===== Sections ===== */
.section {
  position: relative;
  width: 100%;
}

.section-content {
  position: relative;
  z-index: 2;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--site-gutter);
}

/* Section sizes */
.hero-section {
  min-height: 80vh;
  display: flex;
  align-items: flex-end;
}

.section-small {
  padding: 60px 0;
}

.section-medium {
  padding: 100px 0;
}

.section-custom {
  padding: calc(10vmax / 10) 0;
  min-height: 10vh;
}

/* Section backgrounds / themes */
.dark-theme {
  background: var(--dark);
  color: var(--white);
}

.bright-theme {
  background: var(--bright-bg);
  color: var(--white);
}

.light-theme {
  background: var(--light-bg);
  color: var(--text-dark);
}

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

.default-theme {
  background: var(--white);
  color: var(--text-dark);
}

/* Background image/video */
.section-background {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 0;
  overflow: hidden;
}

.hero-video,
.bg-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
}

.section-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: #000;
}

/* Hero content */
.hero-content {
  padding-bottom: 60px;
  width: 100%;
}

.hero-content h2 {
  max-width: 600px;
  font-size: clamp(1.5rem, 3.5vw, 2.5rem);
}

/* Two column layout */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

.col-left, .col-right {
  min-width: 0;
}

.text-col {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: flex-start;
}

.text-large {
  font-size: 1.1rem;
  line-height: 1.7;
}

/* Section images */
.section-image {
  width: 100%;
  border-radius: 0;
}

.section-image.contain {
  object-fit: contain;
}

.section-image.cover {
  object-fit: cover;
  height: 100%;
  min-height: 300px;
}

/* Accent banner */
.accent-banner {
  background: var(--accent);
  padding: 3%;
  border-radius: 6px;
  margin-bottom: 20px;
}

.accent-banner h2 {
  color: var(--white);
  font-size: clamp(1.1rem, 2vw, 1.5rem);
}

.light-accent {
  color: var(--light-accent);
}

.updates-content {
  font-size: 0.9rem;
  line-height: 1.7;
}

.updates-content ul {
  margin-left: 20px;
}

/* Parallax bg image section */
.has-bg-image .section-background img {
  object-position: 50% 50%;
}

/* ===== Newsletter ===== */
.newsletter-form {
  max-width: 500px;
}

.newsletter-description {
  font-size: 0.95rem;
  margin-bottom: 16px;
}

.form-row {
  display: flex;
  gap: 10px;
}

.form-input {
  flex: 1;
  padding: 14px 16px;
  font-family: var(--body-font);
  font-size: 0.85rem;
  border: 1px solid #ccc;
  background: transparent;
  color: var(--text-dark);
  outline: none;
  transition: border-color 0.2s;
}

.form-input::placeholder {
  color: #999;
}

.form-input:focus {
  border-color: var(--text-dark);
}

.newsletter-btn {
  white-space: nowrap;
}

.newsletter-footnote {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 10px;
}

.form-success {
  font-size: 1.1rem;
  font-weight: 600;
  padding: 20px 0;
}

/* ===== Footer ===== */
.site-footer {
  padding: 60px 0;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--site-gutter);
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
}

.footer-col a {
  transition: opacity 0.2s;
}

.footer-col a:hover {
  opacity: 0.7;
}

.footer-info h4 {
  margin-bottom: 12px;
}

.footer-info p {
  font-size: 0.85rem;
  line-height: 1.7;
}

.footer-links p,
.footer-social p {
  font-size: 0.85rem;
  line-height: 2;
}

/* ===== Animations (matching Squarespace fade-in) ===== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.animate-in {
  animation: fadeInUp 1.2s ease forwards;
}

.section {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.section.visible {
  opacity: 1;
  transform: translateY(0);
}

/* First section should be visible immediately */
.hero-section {
  opacity: 1;
  transform: none;
}

/* ===== Responsive ===== */
@media (max-width: 799px) {
  .header-nav {
    display: none;
  }

  .burger {
    display: block;
  }

  .header-logo img {
    height: 29px;
  }

  .site-header {
    padding: 16px var(--site-gutter);
  }

  .two-col {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .reverse-mobile {
    display: flex;
    flex-direction: column-reverse;
  }

  .hero-section {
    min-height: 70vh;
  }

  .hero-content {
    padding-bottom: 40px;
  }

  .section-image.cover {
    min-height: 250px;
  }

  .footer-top {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .section-small {
    padding: 40px 0;
  }

  .section-medium {
    padding: 60px 0;
  }

  .form-row {
    flex-direction: column;
  }
}

@media (min-width: 800px) and (max-width: 1024px) {
  .header-logo img {
    height: 50px;
  }

  .nav-link {
    font-size: 0.7rem;
  }

  .header-nav {
    gap: 1em;
  }
}

/* ===== Image Gallery ===== */
.image-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.image-gallery img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  border-radius: 4px;
  transition: transform 0.3s ease;
}

.image-gallery img:hover {
  transform: scale(1.02);
}

/* ===== Logo Grid ===== */
.logo-grid {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 30px;
}

.logo-grid img {
  max-height: 80px;
  max-width: 160px;
  object-fit: contain;
  filter: grayscale(0.3);
  transition: filter 0.3s;
}

.logo-grid img:hover {
  filter: grayscale(0);
}

/* Sponsor logo grid — 2-3 column grid of logos */
.sponsor-logo-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  align-items: center;
}

.sponsor-logo-grid img {
  width: 100%;
  max-height: 90px;
  object-fit: contain;
}

/* Affiliation rows — logo left, text right */
.affiliation-list {
  margin-top: 24px;
}

.affiliation-row {
  display: flex;
  align-items: center;
  gap: 40px;
  margin-bottom: 32px;
}

.affiliation-logo {
  flex: 0 0 120px;
  justify-items: center;
}

.affiliation-logo img {
  max-width: 120px;
  max-height: 100px;
  object-fit: contain;
}

.affiliation-text {
  flex: 1;
}

@media (max-width: 799px) {
  .affiliation-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
}

/* Federation page — vision block responsive */
@media (max-width: 799px) {
  .fed-story + .two-col + div[style*="max-width: 48%"] {
    max-width: 100% !important;
  }

  .sponsor-logo-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ===== Accordion (FAQ) ===== */
.accordion {
  border-top: 1px solid #ddd;
}

.accordion-item {
  border-bottom: 1px solid #ddd;
}

.accordion-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 20px 0;
  font-family: var(--body-font);
  font-size: 1rem;
  font-weight: 600;
  text-align: left;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-dark);
  gap: 16px;
}

.accordion-toggle:hover {
  opacity: 0.7;
}

.accordion-icon {
  flex-shrink: 0;
  transition: transform 0.3s ease;
}

.accordion-toggle[aria-expanded="true"] .accordion-icon {
  transform: rotate(180deg);
}

.accordion-content {
  display: none;
  padding: 0 0 20px;
  font-size: 0.95rem;
  line-height: 1.7;
}

.accordion-content p {
  margin-bottom: 0.6em;
}

.accordion-toggle[aria-expanded="true"] + .accordion-content {
  display: block;
}

/* ===== Contact Form ===== */
.contact-form {
  width: 100%;
}

.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.form-textarea {
  resize: vertical;
  min-height: 100px;
}

.form-input {
  width: 100%;
}

/* ===== Values Grid ===== */
.values-grid {
  margin-top: 16px;
}

.values-grid p {
  margin-bottom: 12px;
}

/* ===== Ordered list spacing ===== */
ol {
  padding-left: 20px;
}

ol li {
  margin-bottom: 16px;
  line-height: 1.7;
}

/* ===== Carousel ===== */
.carousel {
  position: relative;
  overflow: hidden;
}

.carousel-track-wrapper {
  overflow: hidden;
}

.carousel-track {
  display: flex;
  list-style: none;
  padding: 0;
  margin: 0;
  transition: transform 0.5s ease;
  gap: 20px;
}

.carousel-slide {
  flex: 0 0 calc(33.333% - 14px);
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.carousel-slide-img {
  position: relative;
  width: 100%;
  padding-bottom: 100%; /* 1:1 aspect ratio */
  overflow: hidden;
  background: #e8e8e8;
}

.carousel-slide-img img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.carousel-slide-text {
  padding: 16px 0;
  font-size: 0.9rem;
  line-height: 1.6;
}

.carousel-slide-text p {
  margin: 0;
}

/* Controls */
.carousel-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 20px;
}

.carousel-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: none;
  border: 1px solid #ccc;
  border-radius: 50%;
  cursor: pointer;
  color: var(--text-dark);
  transition: background 0.2s, border-color 0.2s;
}

.carousel-arrow:hover {
  background: var(--text-dark);
  border-color: var(--text-dark);
  color: var(--white);
}

.carousel-dots {
  display: flex;
  gap: 8px;
}

.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ccc;
  border: none;
  padding: 0;
  cursor: pointer;
  transition: background 0.2s;
}

.carousel-dot.active {
  background: var(--text-dark);
}

@media (max-width: 1024px) {
  .carousel-slide {
    flex: 0 0 calc(50% - 10px);
  }
}

@media (max-width: 599px) {
  .carousel-slide {
    flex: 0 0 100%;
  }
}

