/* ProAmigos — "The place carries it". Brand red, Righteous + Josefin Sans. */
:root {
  --paper: #ffffff;
  --tone: #f2f1ee;
  --ink: #161616;
  --soft: #4d4d4d;
  --red: #d22f25;
  --m: clamp(20px, 3vw, 40px);           /* the one pair of page margins */
  --gap: clamp(96px, 12vw, 200px);       /* between sections */
  /* five sizes */
  --s: 15px;
  --b: 18px;
  --l: clamp(20px, 1.7vw, 24px);
  --d: clamp(40px, 4.4vw, 64px);
  --x: clamp(64px, 7.4vw, 120px);
  --display: "Righteous", system-ui, sans-serif;
  --body: "Josefin Sans", Arial, sans-serif;
  --ease: cubic-bezier(.22, 1, .36, 1);
}

* { box-sizing: border-box; }
body { margin: 0; font: 400 var(--b)/1.55 var(--body); color: var(--ink); background: var(--paper); }
img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 4px; }
h1, h2, h3 { margin: 0; font-weight: 400; }
p { margin: 0 0 1em; }
.display { font-family: var(--display); text-transform: uppercase; letter-spacing: .02em; line-height: 1; font-size: var(--d); }
.big { font-family: var(--display); font-size: var(--x); line-height: .85; letter-spacing: -.01em; }
.red { color: var(--red); }
.lead { font-size: var(--l); line-height: 1.45; }
.small { font-size: var(--s); }
.wrap { padding-inline: var(--m); }
.measure { max-width: 60ch; }
.grid { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; }
.section { padding-block: calc(var(--gap) / 2); }
.tone { background: var(--tone); }
.center { text-align: center; }

/* Header: wordmark, five links */
.site-header { display: flex; align-items: center; justify-content: space-between; padding: 16px var(--m); position: relative; z-index: 5; background: var(--paper); }
.home .site-header { position: absolute; left: 0; right: 0; background: transparent; }
.logo img { height: 72px; width: auto; mix-blend-mode: multiply; }
.nav { display: flex; gap: clamp(16px, 2.4vw, 36px); list-style: none; margin: 0; padding: 0; }
.nav a { position: relative; display: inline-block; font-size: var(--b); text-decoration: none; padding-block: 6px; transition: color .2s; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease); }
.nav a:hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
.nav a:hover { color: var(--red); }
.nav .donate a { color: var(--red); font-weight: 600; }
.menu-toggle { display: none; background: none; border: 0; font: 600 var(--b) var(--body); color: var(--ink); padding: 10px 0; cursor: pointer; }

/* Buttons: one shape, flat */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 0 30px; border: 0; border-radius: 999px; background: var(--red); color: #fff; font: 600 var(--b) var(--body); text-decoration: none; cursor: pointer; transition: transform .25s var(--ease), background-color .2s; }
.btn:hover { background: #b9261d; transform: translateY(-2px); }
.btn:active { transform: scale(.97); transition-duration: .08s; }
.btn:focus-visible, a:focus-visible { outline: 3px solid var(--red); outline-offset: 3px; }
.btn.paper { background: var(--paper); color: var(--ink); }
.btn.paper:hover { background: var(--tone); }
.btn img { width: 16px; height: 16px; }
.arrow-link { font-weight: 600; text-decoration: none; display: inline-flex; gap: 8px; }
.arrow-link::after { content: "→"; transition: transform .25s var(--ease); }
.arrow-link:hover::after { transform: translateX(4px); }

/* ---------- Home hero: a window that opens to the edges ---------- */
.hero { position: relative; height: 100svh; }
.hero .stage { position: relative; height: 100svh; overflow: hidden; }
.hero .picture { position: absolute; inset: 0; }
.hero .picture img { width: 100%; height: 100%; object-fit: cover; }
.hero .text { position: absolute; inset: auto var(--m) var(--m) var(--m); display: flex; justify-content: space-between; align-items: flex-end; gap: 32px; color: #fff; }
.hero .text::before { content: ""; position: absolute; inset: -32px calc(-1 * var(--m)) calc(-1 * var(--m)); background: rgba(0,0,0,.38); z-index: -1; }
.hero h1 { font-size: clamp(44px, 5vw, 80px); line-height: .95; max-width: 9.5em; }
.hero .aside { max-width: 30ch; }
.hero-facts { list-style: none; display: flex; gap: 32px; margin: 40px 0 0; padding: 0; }
.hero-facts li { font-size: var(--s); color: var(--soft); max-width: 12ch; line-height: 1.35; }
.hero-facts b { display: block; font-family: var(--display); font-weight: 400; font-size: var(--l); color: var(--red); margin-bottom: 4px; }
.hero .aside p { font-size: var(--b); }
.hero-live .hero { height: 200svh; }
.hero-live .hero .stage { position: sticky; top: 0; }
.hero-live .hero .picture { clip-path: inset(var(--iy, 14svh) var(--ix, 32vw)); }
.hero-live .hero .text { color: var(--ink); inset: auto auto var(--ty, 14svh) var(--m); width: var(--tw, 50vw); flex-direction: column; align-items: flex-start; gap: 32px; }
.hero-live .hero .text::before { display: none; }
.hero-live .hero h1 { max-width: none; }
.hero-live .hero .aside { max-width: 40ch; }
.hero-live .hero .aside > p { font-size: var(--l); line-height: 1.4; }
.hero .caption { position: absolute; right: var(--m); top: 16px; font-size: var(--s); color: #fff; opacity: 0; }

/* ---------- About: wide photo, picture tile, facts ---------- */
.about h2 { margin-bottom: 32px; }
.about .intro { row-gap: 24px; }
.about .intro .lead { grid-column: 1 / 7; }
.about .intro .more { grid-column: 8 / 13; color: var(--soft); }
.mosaic { margin-top: 72px; row-gap: 16px; column-gap: 16px; align-items: start; }
.mosaic .wide { grid-column: 1 / 9; position: relative; }
.mosaic .wide img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.mosaic .note { position: absolute; top: 0; right: 0; width: 340px; padding: 20px 22px; background: var(--paper); margin: 0; }
.mosaic .side { grid-column: 9 / 13; }
.mosaic .side figure { margin: 0; }
.mosaic .side img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.mosaic figcaption { font-size: var(--s); color: var(--soft); margin-top: 8px; }
.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 16px; margin: 24px 0 0; }
.facts dt { font-size: var(--s); color: var(--soft); }
.facts dd { margin: 2px 0 0; font-size: var(--l); }

/* ---------- Stats: a figure on the photograph's edge ---------- */
.figure-band { position: relative; height: 88svh; min-height: 520px; overflow: hidden; color: #fff; margin-top: var(--gap); }
.figure-band > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.figure-band::after { content: ""; position: absolute; inset: 65% 0 0; background: rgba(0,0,0,.42); }
.figure-band h2 { position: absolute; top: 24px; left: var(--m); z-index: 1; font-size: var(--l); }
.figure-band .num { position: absolute; left: var(--m); bottom: 8px; z-index: 1; margin: 0; }
.figure-band .why { position: absolute; right: var(--m); bottom: 32px; z-index: 1; max-width: 28ch; text-align: right; margin: 0; }
.place { margin-top: 48px; row-gap: 48px; }
.place .bg { grid-column: 1 / 7; }
.place .figs { grid-column: 7 / 13; display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-content: start; }
.place .figs p { margin: 0; }
.place .figs b { font-family: var(--display); font-size: var(--d); font-weight: 400; line-height: 1; color: var(--red); }
.charts { margin-top: 24px; row-gap: 48px; }
.charts article { grid-column: span 6; }
.charts img { width: 100%; background: #fff; margin-bottom: 20px; }
.charts h3 { font-size: var(--l); margin-bottom: 8px; }
.panorama { margin: var(--gap) 0 0; }
.panorama video { width: 100%; height: 62svh; object-fit: cover; background: var(--tone); }
.panorama figcaption { margin: 12px 0 0; color: var(--soft); }
.panorama + .site-footer, figure.panorama:last-child { margin-bottom: 0; }

/* ---------- Work: one slide, two neighbours ---------- */
.work h2 { margin-bottom: 48px; }
.strip { display: flex; gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding-inline: 13.5vw; }
.strip::-webkit-scrollbar { display: none; }
.strip figure { flex: 0 0 73vw; margin: 0; scroll-snap-align: center; }
.strip img { width: 100%; aspect-ratio: 16 / 9.2; object-fit: cover; transition: transform .6s var(--ease); }
.strip figcaption { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: 24px; margin-top: 20px; }
.strip figcaption b { grid-column: 1 / 7; font-weight: 600; }
.strip figcaption span { grid-column: 7 / 13; color: var(--soft); }
.strip-controls { display: flex; justify-content: space-between; align-items: center; margin-top: 32px; }
.strip-controls .pager { display: flex; gap: 8px; }
.round { width: 52px; height: 52px; border-radius: 50%; border: 0; background: var(--tone); color: var(--ink); font-size: 22px; cursor: pointer; transition: transform .25s var(--ease), background-color .2s; }
.round:hover { background: var(--red); color: #fff; }
.round:active { transform: scale(.92); }

/* ---------- CTA: last photograph, text beside ---------- */
.give { display: grid; grid-template-columns: 7fr 5fr; min-height: 90svh; margin-top: var(--gap); background: var(--tone); }
.give > img { width: 100%; height: 100%; object-fit: cover; }
.give .copy { align-self: end; padding: var(--m) var(--m) clamp(40px, 8vh, 96px) clamp(24px, 4vw, 64px); }
.give .copy h2 { margin-bottom: 24px; }
.give .badges { width: 160px; margin-top: 16px; }

/* ---------- Footer ---------- */
.site-footer { background: var(--red); color: #fff; padding: clamp(64px, 8vw, 112px) var(--m) 28px; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.f-main { display: grid; grid-template-columns: 6fr 3fr 3fr; gap: 48px; padding-bottom: clamp(56px, 7vw, 96px); }
.f-name { font-family: var(--display); font-size: var(--d); line-height: 1; margin: 0 0 20px; }
.f-brand p:not(.display) { max-width: 40ch; margin-bottom: 28px; }
.f-brand .btn.paper { color: var(--red); }
.f-brand .btn.paper:hover { text-decoration: none; background: var(--tone); }
.f-col h2 { font-size: var(--l); font-weight: 600; margin-bottom: 16px; }
.f-col p { margin: 0 0 16px; }
.f-col a { display: inline-block; }
nav.f-col { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.f-meta { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 12px 32px; font-size: var(--s); opacity: .95; }
.f-meta p { margin: 0; }
.f-meta .credits { flex: 1 1 360px; max-width: 70ch; opacity: .9; }
.f-meta .credits a { text-decoration: underline; }

.signup { margin: 0 0 28px; max-width: 420px; }
.signup label { display: block; font-weight: 600; margin-bottom: 10px; }
.signup-row { display: flex; gap: 8px; }
.signup input { flex: 1; min-width: 0; padding: 0 18px; min-height: 52px; border: 0; border-radius: 999px; font: inherit; color: var(--ink); }
.signup input:focus { outline: 3px solid #fff; outline-offset: 2px; }
.signup .btn.paper { flex: none; }
.form-status { margin: 10px 0 0; min-height: 1.5em; }
.hp { position: absolute; left: -9999px; }

/* ---------- Inner pages ---------- */
.page-title { padding: clamp(48px, 8vw, 120px) var(--m) clamp(32px, 4vw, 64px); }
.page-title.with-picture { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: end; }
.page-title.with-picture img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.page-title h1 { font-size: var(--x); line-height: .9; }
.page-title p { margin-top: 24px; max-width: 46ch; }

.people { display: grid; grid-template-columns: repeat(3, 1fr); gap: 72px 32px; }
.people img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; margin-bottom: 20px; transition: transform .6s var(--ease); }
.people figure { margin: 0; overflow: hidden; }
.people article:hover img { transform: scale(1.03); }
.people h3 { font-size: var(--l); margin-bottom: 8px; }
.people .role { color: var(--red); font-weight: 600; }

.people .logo-fill { object-fit: contain; background: var(--paper); padding: 15%; mix-blend-mode: multiply; }

.project { padding-block: calc(var(--gap) / 2); }
.project h2 { font-size: var(--l); margin-bottom: 8px; }
.project .kind { color: var(--soft); margin-bottom: 24px; }
.gallery { position: relative; }
.slides { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; background: var(--ink); }
.slides::-webkit-scrollbar { display: none; }
.slides img { flex: 0 0 100%; width: 100%; aspect-ratio: 16 / 9; object-fit: contain; scroll-snap-align: center; }
.gallery .arrow { position: absolute; top: calc(50% - 26px); }
.gallery .prev { left: 16px; }
.gallery .next { right: 16px; }
.gallery .count { position: absolute; right: 16px; top: 16px; background: var(--ink); color: #fff; font-size: var(--s); padding: 4px 12px; border-radius: 999px; }
.thumbs { display: flex; gap: 8px; margin-top: 12px; overflow-x: auto; padding: 4px; }
.thumbs button { padding: 0; border: 0; background: none; cursor: pointer; flex: 0 0 auto; opacity: .5; outline: 3px solid transparent; outline-offset: 2px; transition: opacity .2s, outline-color .2s, transform .2s var(--ease); }
.thumbs button:hover { opacity: .9; }
.thumbs button:active { transform: scale(.95); }
.thumbs button[aria-current="true"] { opacity: 1; outline-color: var(--red); }
.thumbs img { width: 72px; height: 72px; object-fit: cover; }

.give-band { display: grid; grid-template-columns: 7fr 5fr; background: var(--red); color: #fff; }
.give-band > img { width: 100%; height: 100%; min-height: 520px; object-fit: cover; }
.give-band .copy { padding: clamp(40px, 6vw, 96px) var(--m) clamp(40px, 6vw, 96px) clamp(24px, 4vw, 64px); align-self: center; }
.give-band h1 { margin-bottom: 24px; }
.give-band .badges { width: 160px; margin-top: 16px; }
.grid > .half { grid-column: span 6; }
.give-band .member { max-width: 44ch; margin-top: 32px; padding-top: 24px; border-top: 1px solid rgb(255 255 255 / .35); }
.give .copy .btn + .small { margin-top: 20px; }

.events { row-gap: 72px; }
.events article { grid-column: span 6; }
.events img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; margin-bottom: 20px; }
.events h3 { font-size: var(--l); margin-bottom: 8px; }

.contact { display: grid; grid-template-columns: 7fr 5fr; gap: clamp(32px, 6vw, 96px); }
.form { display: grid; gap: 14px; }
.form h2, .form h3 { font-size: var(--l); margin-bottom: 8px; }
.form input, .form textarea { width: 100%; padding: 16px; border: 2px solid transparent; border-radius: 0; background: var(--tone); font: inherit; font-size: var(--b); color: var(--ink); transition: border-color .2s, background-color .2s; }
.form input:focus, .form textarea:focus { outline: none; background: var(--paper); border-color: var(--red); }
.form textarea { min-height: 160px; resize: vertical; }
.form .btn { justify-self: start; }
.info h2, .info h3 { font-size: var(--l); margin-bottom: 12px; }
.info a { color: var(--red); }

.sponsor-hero { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 48px; background: #17458f; color: #fff; padding: clamp(48px, 8vw, 120px) var(--m); }
.sponsor-hero h1 { font-size: var(--x); line-height: .9; margin-bottom: 24px; }
.sponsors ul { list-style: none; margin: 0; padding: 0; columns: 3 280px; column-gap: 24px; }
.sponsors li { font-size: var(--l); padding: 10px 0; break-inside: avoid; transition: color .2s, transform .3s var(--ease); }
.sponsors li:hover { color: var(--red); transform: translateX(6px); }

/* ---------- Motion ---------- */
@keyframes settle { from { transform: scale(1.1); } }
.js [data-rise] { opacity: 0; transform: translateY(24px); transition: opacity .8s var(--ease), transform .8s var(--ease); transition-delay: var(--delay, 0ms); }
.js [data-rise].in { opacity: 1; transform: none; }
.figure-band > img { transform: scale(var(--zoom, 1.08)); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation: none !important; }
  .js [data-rise] { opacity: 1; transform: none; }
  .figure-band > img { transform: none; }
}

/* ---------- Tablet & phone ---------- */
@media (max-width: 900px) {
  .menu-toggle { display: block; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; gap: 0; padding: 8px var(--m) 24px; background: var(--paper); }
  .nav.open { display: flex; }
  .nav a { display: block; padding: 12px 0; font-size: var(--l); }
  .about .intro .lead, .about .intro .more, .mosaic .wide, .mosaic .side, .place .bg, .place .figs, .charts article, .events article, .grid > .half { grid-column: 1 / -1; }
  .mosaic .note { position: static; width: auto; padding: 16px 0 0; }
  .mosaic .wide img { aspect-ratio: 4 / 3; }
  .people { grid-template-columns: 1fr 1fr; }
  .contact, .give, .give-band, .sponsor-hero { grid-template-columns: 1fr; }
  .f-main { grid-template-columns: 1fr 1fr; }
  .f-brand { grid-column: 1 / -1; }
  /* Phones and tablets: headline, the harbor full width, then the sentence and button */
  .hero { height: auto; padding-bottom: 72px; }
  .hero .stage { height: auto; overflow: visible; display: flex; flex-direction: column; padding-top: 8px; }
  .hero .text { display: contents; color: var(--ink); }
  .hero .text::before { display: none; }
  .hero h1 { order: 1; font-size: min(var(--d), 9vw); line-height: .95; padding: 0 var(--m); margin-bottom: 24px; max-width: none; }
  .hero .picture { order: 2; position: relative; height: min(48svh, 92vw); overflow: hidden; }
  .hero .picture img { object-position: 50% 60%; animation: settle 1.8s var(--ease) both; }
  .hero .aside { order: 3; max-width: 46ch; padding: 24px var(--m) 0; }
  .hero .aside > p { font-size: var(--l); line-height: 1.4; }
  .hero .caption, .hero-facts { display: none; }
  .give > img, .give-band > img { height: 60svh; min-height: 0; }
  .give-band .copy { order: -1; }
  .page-title.with-picture { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .page-title h1, .sponsor-hero h1 { font-size: 12vw; }
  .figure-band { height: 80svh; }
  .figure-band .num { font-size: 30vw; }
  .figure-band::after { inset: 45% 0 0; }
  .figure-band .why { left: var(--m); right: var(--m); bottom: calc(30vw + 8px); text-align: left; }
  .strip { padding-inline: 11vw; gap: 10px; }
  .strip figure { flex-basis: 78vw; }
  .strip img { aspect-ratio: 4 / 5; }
  .strip figcaption { display: block; }
  .strip figcaption span { display: block; }
  .people { grid-template-columns: 1fr; }
  .f-meta { flex-direction: column; }
  .hero-facts { display: none; }
}
html:not(.hero-live) .home .site-header { position: relative; background: var(--paper); }
