:root {
  /* Brand colors */
  --green: #1f7a4d;
  --teal: #00a7b7;
  --gold: #ffc845;
  --navy: #111827;
  --fog: #f3f4f6;
  --mist: #f9fafb;
  --ink: #1a1a1a;
  --white: #ffffff;

  /* Navy opacity variants */
  --navy-90: rgba(17, 24, 39, 0.9);
  --navy-80: rgba(17, 24, 39, 0.8);
  --navy-70: rgba(17, 24, 39, 0.7);
  --navy-60: rgba(17, 24, 39, 0.6);
  --navy-20: rgba(17, 24, 39, 0.2);
  --navy-15: rgba(17, 24, 39, 0.15);
  --navy-12: rgba(17, 24, 39, 0.12);
  --navy-08: rgba(17, 24, 39, 0.08);

  /* Bauhaus: no rounded corners, sharp edges */
  --radius: 0;
  --radius-full: 50%;
}

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

html,
body {
  overflow-x: hidden;
}

body {
  font-family: "DM Sans", "Futura", system-ui, -apple-system, sans-serif;
  color: var(--ink);
  background: var(--white);
  line-height: 1.6;
}

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

img {
  max-width: 100%;
}

/* Bauhaus: strong container with visible structure */
.container {
  width: min(1120px, 92vw);
  margin: 0 auto;
}

/* Header - clean horizontal line, no shadows */
.site-header {
  background: var(--white);
  border-bottom: 3px solid var(--navy);
  position: sticky;
  top: 0;
  z-index: 10;
}

.header-content {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  padding: 1.5rem 0 1.75rem;
}

.brand {
  display: flex;
  gap: 1.25rem;
  align-items: center;
}

.brand-logo {
  width: 64px;
  height: 64px;
}

.brand-eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.25em;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--navy-60);
}

/* Typography - Bauhaus: strong hierarchy, geometric sans-serif */
h1,
h2,
h3 {
  font-family: "Futura", "DM Sans", system-ui, sans-serif;
  line-height: 1.1;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

h1 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  color: var(--navy);
}

h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  color: var(--navy);
  position: relative;
  display: inline-block;
}

/* Bauhaus geometric accent on h2 */
h2::before {
  content: "";
  position: absolute;
  left: -1.5rem;
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 12px;
  background: var(--gold);
}

h3 {
  font-size: 1.1rem;
  text-transform: none;
  letter-spacing: 0;
}

/* Navigation - Bauhaus: uppercase, geometric */
.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--navy-70);
}

.site-nav a {
  padding-bottom: 0.25rem;
  border-bottom: 2px solid transparent;
  transition: border-color 0.15s;
}

.site-nav a:hover,
.site-nav a:focus {
  border-color: var(--teal);
  color: var(--navy);
}

/* Hero - Bauhaus: bold color block, geometric shapes */
.hero {
  padding: 5rem 0;
  background: var(--navy);
  color: var(--white);
  position: relative;
  overflow: hidden;
}

/* Bauhaus decorative circle */
.hero::before {
  content: "";
  position: absolute;
  right: -100px;
  top: -100px;
  width: 400px;
  height: 400px;
  border: 40px solid var(--gold);
  border-radius: var(--radius-full);
  opacity: 0.3;
}

/* Bauhaus decorative triangle */
.hero::after {
  content: "";
  position: absolute;
  left: 5%;
  bottom: -50px;
  width: 0;
  height: 0;
  border-left: 80px solid transparent;
  border-right: 80px solid transparent;
  border-bottom: 140px solid var(--teal);
  opacity: 0.2;
}

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

/* Bauhaus pill - full circle ends */
.pill {
  display: inline-flex;
  padding: 0.4rem 1rem;
  background: var(--green);
  color: var(--white);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin-bottom: 1.5rem;
}

.hero h2 {
  color: var(--white);
  text-transform: none;
  font-size: clamp(1.75rem, 4vw, 2.75rem);
}

.hero h2::before {
  display: none;
}

.lead {
  font-size: 1.1rem;
  margin: 1.25rem 0 2rem;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.7;
}

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

/* Buttons - Bauhaus: sharp edges, bold */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.9rem 2rem;
  border: 3px solid var(--white);
  background: var(--white);
  color: var(--navy);
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.button:hover,
.button:focus {
  background: transparent;
  color: var(--white);
  outline: none;
}

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

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

.button-secondary:hover,
.button-secondary:focus {
  background: var(--white);
  color: var(--navy);
}

/* Hero card - Bauhaus: flat, colored block */
.hero-card {
  background: var(--white);
  color: var(--ink);
  padding: 2.5rem;
  border-left: 8px solid var(--gold);
}

.hero-card h3 {
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 1rem;
}

.hero-card ul {
  margin: 1rem 0 1.5rem;
  padding-left: 1.25rem;
}

.hero-card li {
  margin-bottom: 0.5rem;
}

.quiet {
  color: var(--navy-60);
  font-size: 0.9rem;
}

/* Sections - Bauhaus: alternating bold blocks */
.section {
  padding: 5rem 0;
  background: var(--white);
}

.section-muted {
  background: var(--fog);
  position: relative;
}

/* Geometric accent on muted sections */
.section-muted::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 6px;
  background: linear-gradient(90deg, var(--green) 33%, var(--teal) 33% 66%, var(--gold) 66%);
}

.section-header {
  max-width: 720px;
  margin-bottom: 3rem;
  padding-left: 1.5rem;
}

.section-header p {
  margin-top: 0.75rem;
  color: var(--navy-70);
}

/* Event widget - clean box */
.event-widget {
  background: var(--white);
  border: 2px solid var(--navy-15);
  padding: 1.5rem;
}

/* Card grid */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

/* Cards - Bauhaus: flat, strong borders */
.card {
  background: var(--white);
  border: 2px solid var(--navy);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  position: relative;
}

/* Colored corner accent */
.card:nth-child(1)::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 40px;
  height: 40px;
  background: var(--green);
}

.card:nth-child(2)::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 40px;
  height: 40px;
  background: var(--teal);
}

.card:nth-child(3)::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 40px;
  height: 40px;
  background: var(--gold);
}

.card-meta {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--navy-60);
}

/* Tags - Bauhaus: simple rectangles */
.tag-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag-list li {
  padding: 0.25rem 0.6rem;
  background: var(--navy);
  color: var(--white);
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.text-link {
  color: var(--teal);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  border-bottom: 2px solid currentColor;
  display: inline-block;
}

.text-link:hover,
.text-link:focus {
  color: var(--green);
}

/* Event card grid - responsive layout for 4-10 cards */
.event-card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

/* Event cards - Bauhaus style with colored corner accents */
.event-card {
  background: var(--white);
  border: 2px solid var(--navy);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  position: relative;
}

/* Cycling colored corner accents for event cards */
.event-card:nth-child(6n+1)::before { content: ""; position: absolute; top: 0; right: 0; width: 40px; height: 40px; background: var(--green); }
.event-card:nth-child(6n+2)::before { content: ""; position: absolute; top: 0; right: 0; width: 40px; height: 40px; background: var(--teal); }
.event-card:nth-child(6n+3)::before { content: ""; position: absolute; top: 0; right: 0; width: 40px; height: 40px; background: var(--gold); }
.event-card:nth-child(6n+4)::before { content: ""; position: absolute; top: 0; right: 0; width: 40px; height: 40px; background: var(--teal); }
.event-card:nth-child(6n+5)::before { content: ""; position: absolute; top: 0; right: 0; width: 40px; height: 40px; background: var(--green); }
.event-card:nth-child(6n+6)::before { content: ""; position: absolute; top: 0; right: 0; width: 40px; height: 40px; background: var(--gold); }

/* Event source badges */
.event-source {
  display: inline-block;
  padding: 0.3rem 0.6rem;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  align-self: flex-start;
}

.event-source--library {
  background: var(--teal);
  color: var(--white);
}

.event-source--community {
  background: var(--green);
  color: var(--white);
}

.event-source--library-green {
  background: var(--green);
  color: var(--white);
}

.event-source--library-gold {
  background: var(--gold);
  color: var(--navy);
}

.event-card h3 {
  font-size: 1.15rem;
  text-transform: none;
  letter-spacing: 0;
  line-height: 1.3;
  padding-right: 2.5rem;
}

.event-meta {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--navy);
}

.event-location {
  font-size: 0.85rem;
  color: var(--navy-70);
  margin-bottom: 0.25rem;
}

.event-card > p:not(.event-meta):not(.event-location) {
  color: var(--navy-80);
  font-size: 0.95rem;
  line-height: 1.5;
  flex-grow: 1;
}

/* Event button styling */
.event-button {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
  margin-top: 0.75rem;
  align-self: flex-start;
  padding: 0.7rem 1.5rem;
  font-size: 0.8rem;
}

.event-button:hover,
.event-button:focus {
  background: var(--teal);
  border-color: var(--teal);
  color: var(--white);
}

/* Split layout */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

/* Callout - bold color block */
.callout {
  background: var(--gold);
  color: var(--navy);
  padding: 2.5rem;
  position: relative;
}

.callout::before {
  content: "";
  position: absolute;
  bottom: 0;
  right: 0;
  width: 60px;
  height: 60px;
  background: var(--navy);
  clip-path: polygon(100% 0, 100% 100%, 0 100%);
}

.callout h3 {
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 1rem;
}

/* Mission grid */
.mission-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
}

.mission-grid h3 {
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding-bottom: 0.75rem;
  border-bottom: 3px solid var(--teal);
  margin-bottom: 1rem;
}

.mission-grid ul,
.mission-grid ol {
  padding-left: 1.5rem;
}

.mission-grid li {
  margin-bottom: 0.5rem;
}

/* Form - Bauhaus: clean, structured */
.form-card {
  background: var(--white);
  padding: 2.5rem;
  border: 3px solid var(--navy);
  display: grid;
  gap: 1.25rem;
}

.form-card h3 {
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--navy-20);
}

label {
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--navy-80);
  display: grid;
  gap: 0.5rem;
}

input {
  padding: 0.9rem 1rem;
  border: 2px solid var(--navy-20);
  font-family: inherit;
  font-size: 1rem;
  transition: border-color 0.15s;
}

input:focus {
  outline: none;
  border-color: var(--teal);
}

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

.form-card .button {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
  margin-top: 0.5rem;
}

.form-card .button:hover,
.form-card .button:focus {
  background: var(--green);
  border-color: var(--green);
  color: var(--white);
}

/* Contact section */
.contact {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.contact-card {
  background: var(--green);
  color: var(--white);
  padding: 2rem;
  position: relative;
}

.contact-card::before {
  content: "";
  position: absolute;
  top: -10px;
  left: 20px;
  width: 30px;
  height: 30px;
  background: var(--gold);
  border-radius: var(--radius-full);
}

.contact-card h3 {
  color: var(--white);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.75rem;
}

.contact-card p {
  opacity: 0.9;
}

.signup-form {
  display: flex;
  gap: 0.5rem;
  margin-top: 1rem;
}

.signup-form input {
  flex: 1;
  padding: 0.75rem 1rem;
  border: 2px solid var(--white);
  background: var(--white);
  font-size: 0.95rem;
}

.signup-form .button {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
  padding: 0.75rem 1.25rem;
}

.signup-form .button:hover,
.signup-form .button:focus {
  background: var(--white);
  color: var(--navy);
}

/* Footer - bold block */
.site-footer {
  background: var(--navy);
  color: var(--white);
  padding: 3rem 0;
  position: relative;
}

.site-footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 6px;
  background: linear-gradient(90deg, var(--gold) 25%, var(--teal) 25% 50%, var(--green) 50% 75%, var(--white) 75%);
}

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

.footer-left {
  display: grid;
  gap: 0.75rem;
}

.footer-left p:first-child {
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.footer-partner {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--white);
  font-size: 0.85rem;
  opacity: 0.8;
  transition: opacity 0.15s;
}

.footer-partner:hover,
.footer-partner:focus {
  opacity: 1;
}

.footer-partner img {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
}

.site-footer .quiet {
  color: rgba(255, 255, 255, 0.6);
}

/* Responsive - Bauhaus: maintain structure */
@media (max-width: 900px) {
  .hero-content,
  .split,
  .mission-grid,
  .contact {
    grid-template-columns: 1fr;
  }

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

  .hero::before {
    width: 200px;
    height: 200px;
    border-width: 20px;
    right: -50px;
    top: -50px;
  }

  .hero::after {
    border-left-width: 40px;
    border-right-width: 40px;
    border-bottom-width: 70px;
  }
}

/* Hamburger menu toggle - hidden on desktop */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  position: absolute;
  top: 1.5rem;
  right: 4vw;
}

.nav-toggle-bar {
  display: block;
  width: 24px;
  height: 3px;
  background: var(--navy);
  margin: 5px 0;
  transition: transform 0.2s, opacity 0.2s;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) {
  transform: rotate(45deg) translate(5px, 6px);
}

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

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -6px);
}

@media (max-width: 720px) {
  .header-content {
    position: relative;
    padding-right: 50px;
  }

  .nav-toggle {
    display: block;
    z-index: 20;
  }

  .site-nav {
    display: none;
    flex-direction: column;
    gap: 0;
    background: var(--white);
    border-top: 2px solid var(--navy-15);
    padding-top: 1rem;
  }

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

  .site-nav a {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--navy-08);
  }

  .hero {
    padding: 3.5rem 0;
  }

  .section {
    padding: 3.5rem 0;
  }

  h2::before {
    left: -1rem;
    width: 8px;
    height: 8px;
  }

  .section-header {
    padding-left: 1rem;
  }

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

  .event-card-grid {
    grid-template-columns: 1fr;
  }

  .footer-content {
    flex-direction: column;
    text-align: center;
  }

  .footer-partner {
    margin-top: 1rem;
  }
}
