/* ==========================================================================
     · palette    : white / light background, near-black #191818,
                    blue #4761FF used ONLY as a restrained accent
     · typography : Montserrat (headings + body), Roboto Mono (technical
                    labels / code)
     · motifs     : technical-blueprint framing, thin grid lines, rocket
                    trail / gear mark, technical-document aesthetic
   ========================================================================== */

:root {
  /* brand palette */
  --ink:          #191818;             /* near-black - primary text & graphics */
  --ink-soft:     #555252;             /* secondary text */
  --ink-faint:    rgba(25, 24, 24, .55);
  --paper:        #ffffff;
  --paper-tint:   #f6f7f9;             /* light technical gray */
  --line:         #e3e4e6;             /* hairline borders */
  --line-strong:  #c8c9cc;
  --accent:       #4761FF;             /* restrained blue accent */
  --accent-ink:   #2f4aef;             /* accent darkened for text contrast */
  --ring:         rgba(25, 24, 24, .06); /* blueprint grid line color */

  /* type */
  --sans: 'Montserrat', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --mono: 'Roboto Mono', 'Cascadia Mono', Consolas, monospace;

  /* layout */
  --page-max: 1080px;
  --nav-h: 64px;
}

/* Touch interaction optimizations */
* { -webkit-tap-highlight-color: transparent; }
input, textarea, button, select, a {
  touch-action: manipulation;
}

*, *::before, *::after { box-sizing: border-box; }

[hidden] { display: none !important; }

html { scroll-behavior: auto; }

body {
  margin: 0;
  font-family: var(--sans);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 {
  font-family: var(--sans);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 0 0 .5em;
}

h1 { font-size: clamp(2.1rem, 5vw, 3.3rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
h3 { font-size: 1.05rem; }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

a { color: var(--ink); }
a:hover, a:focus-visible { color: var(--accent-ink); }

img { max-width: 100%; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

::selection { background: var(--accent); color: #fff; }

.mono { font-family: var(--mono); }

.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;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  z-index: 100;
  background: var(--ink);
  color: #fff;
  padding: .55rem 1rem;
  font-family: var(--mono);
  font-size: .8rem;
  text-decoration: none;
}
.skip-link:focus { left: 0; top: 0; color: #fff; }

.noscript-note {
  padding: 1rem 1.25rem;
  border: 1px solid var(--accent);
  background: #fff;
  font-size: .8rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: #ffffff;
  border-bottom: 1px solid var(--line);
}

.brand-mark {
  width: 48px;
  height: 48px;
  display: block;
  flex: none;
  object-fit: contain;
}

.brand .brand-mark {
  width: 60px;
  height: 60px;
}

/* horizontal logo (SAT wordmark + symbol) - hidden on desktop, shown on mobile */
.brand-horizontal {
  display: none;
  height: 44px;
  width: auto;
  object-fit: contain;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: var(--page-max);
  margin: 0 auto;
  padding: .6rem 1.5rem;
  padding: .6rem max(1.5rem, env(safe-area-inset-right)) .6rem max(1.5rem, env(safe-area-inset-left));
}

/* brand mark + wordmark */
.brand {
  display: inline-flex;
  align-items: center;
  gap: .75rem;
  text-decoration: none;
  color: var(--ink);
  font-weight: 700;
  font-size: 1.12rem;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.brand-short { display: none; }

/* menu */
.nav-menu {
  display: flex;
  align-items: center;
  gap: .25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-link {
  display: inline-block;
  padding: .6rem 1rem;
  text-decoration: none;
  color: var(--ink);
  font-weight: 600;
  font-size: 1rem;
  border-bottom: 2px solid transparent;
  transition: color .15s ease, border-color .15s ease;
}
.nav-link:hover { color: var(--accent-ink); }
.nav-link[aria-current="page"] { border-bottom-color: var(--accent); }

/* disabled item - muted, non-interactive (enabled via articlesEnabled flag) */
.nav-link--disabled {
  color: var(--ink-faint);
  cursor: default;
}
.nav-link--disabled:hover { color: var(--ink-faint); }

/* hamburger toggle (hidden on desktop) */
.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  background: none;
  border: 1px solid var(--line);
  color: var(--ink);
  cursor: pointer;
  padding: 0;
}

/* Mobile menu backdrop */
@media (max-width: 720px) {
  body.menu-open {
    overflow: hidden;
  }
}

/* language switcher */
.nav-item--lang {
  display: flex;
  align-items: center;
  gap: .15rem;
  margin-left: .85rem;
  padding-left: .85rem;
  border-left: 1px solid var(--line);
}
.lang-btn {
  background: none;
  border: 0;
  padding: .25rem .4rem;
  font-family: var(--mono);
  font-weight: 600;
  font-size: .8rem;
  letter-spacing: .08em;
  color: var(--ink-soft);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: color .15s ease, border-color .15s ease;
}
.lang-btn:hover { color: var(--ink); }
.lang-btn.is-active { color: var(--ink); border-bottom-color: var(--accent); }
.lang-divider { color: var(--line-strong); font-family: var(--mono); font-size: .8rem; }


main {
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 2rem 1.5rem 3.5rem;
  padding: 2rem max(1.5rem, env(safe-area-inset-right)) 3.5rem max(1.5rem, env(safe-area-inset-left));
}

.view { animation: view-in .18s ease; }

@keyframes view-in {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

.sec-head { margin: 0 0 1.75rem; }

.sec-kicker {
  display: flex;
  align-items: center;
  gap: .6rem;
  margin: 0 0 .5rem;
  font-family: var(--mono);
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
/* thin blue rule - restricted accent per brand manual */
.sec-kicker::before {
  content: "";
  flex: none;
  width: 1.5rem;
  height: 2px;
  background: var(--accent);
}

.hero {
  position: relative;
  border: 1px dashed rgba(25, 24, 24, .35);   /* blueprint cutting guide */
  background:
    linear-gradient(to right, var(--ring) 1px, transparent 1px),   /* thin technical grid */
    linear-gradient(to bottom, var(--ring) 1px, transparent 1px),
    var(--paper);
  background-size: 28px 28px;
  padding: clamp(2.75rem, 7vw, 4.75rem) clamp(1.25rem, 4vw, 3rem);
  margin-bottom: 4rem;
}

/* thin accent rule across the top - restrained blue */
.hero::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--accent);
}

.kicker {
  margin: 0 0 1.1rem;
  font-family: var(--mono);
  font-size: .74rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.hero-sub {
  max-width: 64ch;
  margin-top: 1rem;
  font-size: 1.06rem;
  color: var(--ink-soft);
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2.25rem;
}

.hero-coord {
  margin: 2.5rem 0 0;
  font-size: .72rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.hero-coord::before {
  content: "// ";
  color: var(--accent);
}


/* fills the entire hero section, sits behind content */
.hero-gallery {
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 0;
}

/* each image fills the gallery frame */
.hero-gallery-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 800ms ease;
  z-index: 0;
}

/* active slide is visible */
.hero-gallery-img.active {
  opacity: 1;
}

/* dark overlay so text stays readable */
.hero-gallery-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: rgba(0, 0, 0, 0.55);
  pointer-events: none;
}

/* content sits above gallery and overlay */
.hero-content {
  position: relative;
  z-index: 2;
}

/* when gallery is active, hero text becomes white over the dark overlay */
.hero-gallery ~ .hero-content .kicker,
.hero-gallery ~ .hero-content h1,
.hero-gallery ~ .hero-content .hero-sub,
.hero-gallery ~ .hero-content .hero-coord {
  color: #fff;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.7), 0 0 4px rgba(0, 0, 0, 0.5);
}
.hero-gallery ~ .hero-content .hero-coord::before {
  color: rgba(255, 255, 255, 0.6);
}

/* buttons adapt to the dark gallery background */
.hero-gallery ~ .hero-content .btn--primary {
  background: #fff;
  color: #111;
}
.hero-gallery ~ .hero-content .btn--primary:hover {
  background: var(--accent);
  color: #fff;
}
.hero-gallery ~ .hero-content .btn--ghost {
  border-color: rgba(255, 255, 255, 0.8);
  color: #fff;
}
.hero-gallery ~ .hero-content .btn--ghost:hover {
  background: #fff;
  color: #111;
}

/* dot navigation — bottom-right corner */
.hero-gallery-dots {
  position: absolute;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 3;
  display: flex;
  gap: 0.5rem;
}

/* individual dot */
.hero-gallery-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.7);
  background: transparent;
  cursor: pointer;
  padding: 0;
  transition: background 300ms ease;
}

/* active dot — filled white */
.hero-gallery-dot.active {
  background: #fff;
}

/* when hero has no gallery, hide gallery elements */
.hero--no-gallery .hero-gallery,
.hero--no-gallery .hero-gallery-overlay,
.hero--no-gallery .hero-gallery-dots {
  display: none;
}

/* small screens — reduce dot size and gap */
@media (max-width: 720px) {
  .hero-gallery-dots {
    gap: 0.35rem;
  }
  .hero-gallery-dot {
    width: 8px;
    height: 8px;
  }
}

/* respect reduced motion preference */
@media (prefers-reduced-motion: reduce) {
  .hero-gallery-img {
    transition: none;
  }
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .8rem 1.4rem;
  font-family: var(--sans);
  font-weight: 700;
  font-size: .9rem;
  letter-spacing: .02em;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.btn--primary { background: var(--ink); color: #fff; }
.btn--primary:hover { background: var(--accent); color: #fff; }

.btn--ghost { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn--ghost:hover { background: var(--ink); color: #fff; }

.btn .material-icons { font-size: 18px; }



.section-block { margin-top: 4rem; }

.structures-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  border: 1px solid var(--line);
  background: #fff;
}

.structure {
  flex: 1;
  display: flex;
  align-items: baseline;
  gap: .8rem;
  padding: 1.5rem;
}
/* hairline separator between structures ("A | B | C") */
.structure + .structure { border-left: 1px solid var(--line); }

.structure-id {
  font-size: .74rem;
  font-weight: 600;
  letter-spacing: .1em;
  color: var(--accent);
}
.structure-name { font-weight: 700; font-size: 1.02rem; }

.what-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.25rem;
}

.card {
  border: 1px solid var(--line);
  background: #fff;
  padding: 1.75rem 1.5rem;
  transition: border-color .18s ease, box-shadow .18s ease;
}
.card:hover { border-color: var(--line-strong); }

.card-icon {
  display: inline-grid;
  place-items: center;
  width: 48px;
  height: 48px;
  flex: none;
  border: 1px solid var(--line);
  color: var(--ink);
  margin-bottom: 1.15rem;
}
.card-icon .material-icons { font-size: 24px; }

.card h3 { margin-bottom: .35rem; font-size: 1.05rem; }
.card p { font-size: .95rem; color: var(--ink-soft); }

/* "What we do" cards - each gets a full-bleed background image with dark overlay */
.what-grid .card {
  position: relative;
  isolation: isolate;
  transition: transform .2s ease;
}
.what-grid .card:hover {
  transform: scale(1.03);
}
.what-grid .card::before {
  content: "";
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  z-index: 0;
}
.what-grid .card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 0;
}
.what-grid .card > * {
  position: relative;
  z-index: 1;
}
.what-grid .card h3,
.what-grid .card p {
  color: #fff;
}
.what-grid .card .card-icon {
  border-color: rgba(255, 255, 255, 0.4);
  color: #fff;
}

/* Card 1 — Cubesat prototyping */
.what-grid .card:nth-child(1)::before {
  background-image: url('img/cubesat.webp');
}

/* Card 2 — High-altitude balloons */
.what-grid .card:nth-child(2)::before {
  background-image: url('img/balloon.webp');
}

/* Card 3 — Rocket design */
.what-grid .card:nth-child(3)::before {
  background-image: url('img/rocket.webp');
}

/* Card 4 — Avionics systems */
.what-grid .card:nth-child(4)::before {
  background-image: url('img/avionics.webp');
}



.sponsors-grid {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 2.5rem;
  border: 1px solid var(--line);
  background: #fff;
  padding: 2.5rem 2rem;
}

.sponsors-note {
  width: 100%;
  text-align: center;
  font-size: .9rem;
  color: var(--ink-soft);
  margin: 0;
}

.sponsor-logo {
  height: 60px;
  width: auto;
  object-fit: contain;
  display: block;
  opacity: .75;
  transition: opacity .2s ease;
  filter: saturate(0.7);
}

.sponsor-logo:hover {
  opacity: 1;
  filter: saturate(1);
}

@media (max-width: 720px) {
  .sponsors-grid {
    gap: 1.5rem;
    padding: 1.5rem 1.25rem;
  }
  .sponsor-logo {
    height: 44px;
  }
}

@media (max-width: 480px) {
  .sponsors-grid {
    gap: 1.25rem;
    padding: 1.25rem 1rem;
  }
  .sponsor-logo {
    height: 36px;
  }
}



.about-flow { max-width: 74ch; }
.affiliation-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  border: 1px solid var(--line);
  background: #fff;
  padding: 1.5rem;
}
.affiliation-strip > p {
  max-width: 48ch;
  color: var(--ink-soft);
  margin: 0;
  font-size: .95rem;
}
.affiliation-logos {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}
.aff-logo {
  height: 64px;
  width: auto;
  object-fit: contain;
  display: block;
  transition: transform .2s ease;
}
.aff-logo:hover {
  transform: scale(1.08);
}
@media (max-width: 720px) {
  .aff-logo { height: 52px; }
}
.about-lead { font-weight: 600; font-size: 1.08rem; }
.about-flow p { color: var(--ink-soft); }
.about-lead, .about-flow .about-web { color: var(--ink); }

.about-web {
  display: flex;
  align-items: center;
  gap: .5rem;
  margin-top: 1.5rem;
  font-size: .85rem;
}
.about-web .material-icons { font-size: 18px; color: var(--accent); }

.board-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
}

/* Compact list for additional board members (vice president, secretary, etc.) */
.board-compact {
  list-style: none;
  margin: 1.25rem 0 0;
  padding: 0;
  border: 1px solid var(--line);
  background: #fff;
}
.board-compact-item {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .75rem 1.25rem;
  font-size: .9rem;
}
.board-compact-icon {
  flex: none;
  width: 32px;
  height: 32px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 18px;
}
.board-compact-item + .board-compact-item {
  border-top: 1px solid var(--line);
}
.board-compact-role {
  flex: 0 0 140px;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.board-compact-name {
  font-weight: 600;
  color: var(--ink);
}
.board-compact-mail {
  margin-left: auto;
  font-size: .78rem;
  color: var(--ink-soft);
  text-decoration: none;
  transition: color .15s ease;
}
.board-compact-mail:hover {
  color: var(--accent-ink);
  text-decoration: underline;
}

.person { display: flex; gap: 1.1rem; align-items: flex-start; }
.person-role {
  margin: 0 0 .4rem;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.person h3 { margin: 0 0 .25rem; font-size: 1.05rem; }
.person-mail {
  font-size: .8rem;
  color: var(--ink-soft);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color .15s ease, border-color .15s ease;
  word-break: break-all;
}
.person-mail:hover { color: var(--accent-ink); border-color: var(--accent); }

.areas-flow { max-width: 74ch; }
.areas-flow > p { color: var(--ink-soft); }

.areas-list {
  list-style: none;
  margin: 1.5rem 0 0;
  padding: 0;
  display: flex;
  border: 1px solid var(--line);
  background: #fff;
}
.areas-list li {
  flex: 1;
  display: flex;
  align-items: baseline;
  gap: .8rem;
  padding: 1.2rem 1.5rem;
  font-size: .9rem;
  font-weight: 600;
}
.areas-list li + li { border-left: 1px solid var(--line); }
.area-id { color: var(--accent); font-size: .74rem; font-weight: 600; letter-spacing: .1em; }



.contact-flow { max-width: 780px; }
.contact-note { color: var(--ink-soft); max-width: 60ch; }
.contact-subtitle {
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 0 0 .75rem;
}

.contact-list {
  list-style: none;
  margin: 2rem 0 0;
  padding: 0;
  border: 1px solid var(--line);
  background: #fff;
}
.contact-row {
  display: flex;
  gap: 1.15rem;
  align-items: flex-start;
  padding: 1.35rem 1.5rem;
}
.contact-row + .contact-row { border-top: 1px solid var(--line); }
.contact-row .card-icon { margin-bottom: 0; flex: none; }

.contact-label {
  margin: 0 0 .3rem;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.contact-value {
  font-weight: 700;
  font-size: 1.02rem;
  color: var(--ink);
  text-decoration: none;
  word-break: break-word;
}
a.contact-value:hover { color: var(--accent-ink); text-decoration: underline; text-underline-offset: 3px; }
p.contact-value { margin: 0; }




.comingsoon-box {
  border: 1px dashed rgba(25, 24, 24, .4);
  background: var(--paper-tint);
  padding: 3rem 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  text-align: center;
  color: var(--ink-soft);
}
.comingsoon-box .material-icons { font-size: 40px; color: var(--ink); }
.comingsoon-box p { max-width: 46ch; margin: 0; }




.site-footer {
  border-top: 1px solid var(--line);
  background: var(--paper-tint);
  margin-top: 4rem;
}

.footer-main {
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 2.25rem 1.5rem;
  padding: 2.25rem max(1.5rem, env(safe-area-inset-right)) 2.25rem max(1.5rem, env(safe-area-inset-left));
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1.5rem;
}

.footer-brand { display: flex; gap: .85rem; align-items: flex-start; }
.footer-brand .brand-mark { width: 38px; height: 38px; }
.footer-name { margin: 0; font-weight: 700; font-size: .95rem; }
.footer-sub { margin: .2rem 0 0; font-size: .85rem; color: var(--ink-soft); max-width: 46ch; }

.footer-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: .55rem;
  font-size: .82rem;
}
.icon-link {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  color: var(--ink-soft);
  text-decoration: none;
  transition: color .15s ease;
}
.icon-link:hover { color: var(--accent-ink); }
.icon-link .material-icons { font-size: 16px; }

.footer-meta {
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 1rem 1.5rem 1.5rem;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: .5rem 2rem;
  font-size: .72rem;
  letter-spacing: .06em;
  color: var(--ink-soft);
}
.footer-meta p { margin: 0; }








/* MOBILE SUPPORT CRAP */

/* Tablet and below */
@media (max-width: 720px) {
  body { font-size: 15px; }

  .nav {
    padding: .6rem 1rem;
    padding: .6rem max(1rem, env(safe-area-inset-right)) .6rem max(1rem, env(safe-area-inset-left));
  }

  /* brand switches to horizontal logo on mobile */
  .brand .brand-mark { display: none; }
  .brand-name { display: none; }
  .brand-horizontal { display: block; }

  /* hamburger visible */
  .nav-toggle { display: inline-flex; }

  /* dropdown menu - improved with smooth animation */
  .nav-menu {
    position: absolute;
    top: calc(100% + 1px);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: #fff;
    border-bottom: 1px solid var(--line);
    padding: .5rem 1rem 1rem;
    display: none;
    box-shadow: 0 12px 24px -18px rgba(0, 0, 0, .25);
    max-height: calc(100vh - var(--nav-h));
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  .nav.is-open .nav-menu { display: flex; }

  .nav-link {
    display: block;
    padding: .8rem .25rem;
    border-bottom: 1px solid var(--line);
    min-height: 44px;
    display: flex;
    align-items: center;
  }
  .nav-link[aria-current="page"] { border-bottom-color: var(--accent); }

  .nav-item--lang {
    margin: .75rem 0 0;
    padding: .5rem 0 0;
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  /* Improve language buttons touch targets */
  .lang-btn {
    padding: .5rem .6rem;
    min-height: 44px;
    min-width: 44px;
  }

  /* structures / areas stack vertically */
  .structures-list, .areas-list { flex-direction: column; }
  .structure + .structure, .areas-list li + li { border-left: 0; border-top: 1px solid var(--line); }
  .structure, .areas-list li { padding: 1.1rem 1.25rem; }

  main {
    padding: 1.25rem 1rem 3rem;
    padding: 1.25rem max(1rem, env(safe-area-inset-right)) 3rem max(1rem, env(safe-area-inset-left));
  }
  .hero { margin-bottom: 3rem; }
  .section-block { margin-top: 3rem; }

  /* Improve hero grid background for mobile - reduce grid size */
  .hero {
    background-size: 20px 20px;
  }

  /* Improve CTA buttons on mobile */
  .hero-cta {
    flex-direction: column;
    align-items: flex-start;
  }
  .hero-cta .btn {
    width: 100%;
    justify-content: center;
    min-height: 48px;
  }

  /* Improve card grid for mobile */
  .what-grid {
    grid-template-columns: 1fr;
  }

  /* Improve board grid for mobile */
  .board-grid {
    grid-template-columns: 1fr;
  }

  /* Compact board list stacks vertically on mobile */
  .board-compact-item {
    flex-direction: column;
    align-items: flex-start;
    gap: .25rem;
    padding: .65rem 1rem;
  }
  .board-compact-role {
    flex: none;
  }

  /* Improve affiliation strip for mobile */
  .affiliation-strip {
    flex-direction: column;
    align-items: flex-start;
  }

  /* Improve contact rows for mobile */
  .contact-row {
    flex-direction: column;
    gap: .75rem;
  }

  /* Improve footer for mobile */
  .footer-main {
    flex-direction: column;
    gap: 1.5rem;
  }

  .footer-meta {
    flex-direction: column;
    text-align: center;
    gap: .5rem;
  }
}

/* Small phones (below 480px) */
@media (max-width: 480px) {
  body { font-size: 14px; }

  h1 { font-size: clamp(1.6rem, 6vw, 2.1rem); }
  h2 { font-size: clamp(1.2rem, 4vw, 1.5rem); }

  .nav {
    padding: .5rem .75rem;
    padding: .5rem max(.75rem, env(safe-area-inset-right)) .5rem max(.75rem, env(safe-area-inset-left));
  }

  .brand-horizontal {
    height: 36px;
  }

  .brand {
    gap: .5rem;
    font-size: 1rem;
  }

  .hero {
    padding: clamp(1.75rem, 5vw, 2.75rem) clamp(1rem, 3vw, 1.25rem);
    background-size: 16px 16px;
  }

  .hero-sub {
    font-size: .95rem;
  }

  .card {
    padding: 1.25rem 1rem;
  }

  .structure, .areas-list li {
    padding: .9rem 1rem;
  }

  .contact-row {
    padding: 1rem 1.15rem;
  }

  main {
    padding: 1rem .75rem 2.5rem;
    padding: 1rem max(.75rem, env(safe-area-inset-right)) 2.5rem max(.75rem, env(safe-area-inset-left));
  }

  .aff-logo {
    height: 44px;
  }

  .footer-main {
    padding: 1.5rem .75rem;
    padding: 1.5rem max(.75rem, env(safe-area-inset-right)) 1.5rem max(.75rem, env(safe-area-inset-left));
  }
}

/* Landscape orientation on phones */
@media (max-height: 500px) and (orientation: landscape) {
  .hero {
    padding: 1.5rem 1.25rem;
  }

  .hero-cta {
    flex-direction: row;
  }
  .hero-cta .btn {
    width: auto;
  }

  .nav-menu {
    max-height: calc(100vh - var(--nav-h));
  }
}

/* Dark mode support for mobile browsers that auto-dim */
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #ffffff;
    --paper-tint: #f6f7f9;
  }
}