/* AGAPE FOUNDATION INC — History, Sovereignty & Agape
   Palette and typography follow the film: navy, gold, cream. */

@font-face {
  font-family: 'Cinzel';
  src: url('assets/fonts/Cinzel.ttf') format('truetype');
  font-weight: 400 900;
  font-display: swap;
}
@font-face {
  font-family: 'EB Garamond';
  src: url('assets/fonts/EBGaramond.ttf') format('truetype');
  font-weight: 400 800;
  font-display: swap;
}
@font-face {
  font-family: 'EB Garamond';
  src: url('assets/fonts/EBGaramondItalic.ttf') format('truetype');
  font-style: italic;
  font-weight: 400 800;
  font-display: swap;
}

:root {
  --navy: #0e2a47;
  --navy-deep: #081c30;
  --navy-ink: #061523;
  --gold: #c9a227;
  --gold-light: #e0c25e;
  --cream: #f5efe0;
  --cream-dim: #cfc6ae;
  --paper: #f7f2e6;
  --paper-line: #ddd2b6;
  --ink: #17202c;
  --ink-soft: #4a5566;
  --rule: rgba(201, 162, 39, 0.42);
  --serif: 'EB Garamond', 'Iowan Old Style', Georgia, 'Times New Roman', serif;
  --display: 'Cinzel', 'EB Garamond', Georgia, serif;
  --wrap: 1160px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--navy-deep);
  color: var(--cream);
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.68;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a { color: var(--gold-light); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

.wrap { width: min(100% - 2.6rem, var(--wrap)); margin-inline: auto; }

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--gold); color: var(--navy-ink); padding: .6rem 1rem;
}
.skip:focus { left: .5rem; top: .5rem; }

/* ---------------------------------------------------------------- header */
.masthead {
  position: sticky; top: 0; z-index: 50;
  background: rgba(6, 21, 35, .93);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--rule);
}
.masthead .wrap {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1.5rem; min-height: 74px; flex-wrap: wrap;
  padding-block: .7rem;
}
.wordmark {
  font-family: var(--display); font-weight: 700;
  font-size: 1.02rem; letter-spacing: .22em; text-transform: uppercase;
  color: var(--cream); line-height: 1.25;
}
.wordmark span { display: block; color: var(--gold); font-size: .62rem; letter-spacing: .34em; }
.wordmark:hover { text-decoration: none; }
.nav { display: flex; gap: 1.5rem; flex-wrap: wrap; }
.nav a {
  font-size: .78rem; letter-spacing: .17em; text-transform: uppercase;
  color: var(--cream-dim); padding-block: .3rem;
  border-bottom: 1px solid transparent;
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--cream); border-bottom-color: var(--gold); text-decoration: none; }

/* ------------------------------------------------------------------ hero */
.hero { position: relative; padding-block: 3.4rem 3rem; background: linear-gradient(180deg, #0c2540 0%, #081c30 100%); }
.kicker {
  font-size: .72rem; letter-spacing: .3em; text-transform: uppercase;
  color: var(--gold); margin: 0 0 .9rem;
}
h1, h2, h3 { font-family: var(--display); font-weight: 600; line-height: 1.14; margin: 0; }
h1 { font-size: clamp(2.1rem, 5.4vw, 3.9rem); letter-spacing: .015em; }
h2 { font-size: clamp(1.5rem, 3.2vw, 2.3rem); }
h3 { font-size: 1.15rem; letter-spacing: .02em; }
.hero .lede { font-size: clamp(1.05rem, 2vw, 1.3rem); color: var(--cream-dim); max-width: 62ch; margin: 1.1rem 0 0; }
.hero-rule { width: 118px; height: 3px; background: var(--gold); margin: 1.5rem 0 1.4rem; }
.meta { display: flex; flex-wrap: wrap; gap: .5rem 1.6rem; margin: 0 0 1.8rem; padding: 0; list-style: none; }
.meta li { font-size: .76rem; letter-spacing: .18em; text-transform: uppercase; color: var(--cream-dim); }
.meta li strong { color: var(--gold-light); font-weight: 600; }

/* ----------------------------------------------------------------- video */
.player { border: 1px solid var(--rule); background: #000; box-shadow: 0 26px 70px rgba(0, 0, 0, .5); }
.player video { width: 100%; aspect-ratio: 16 / 9; background: #000; }
.player-bar {
  display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; align-items: center;
  justify-content: space-between; padding: .85rem 1.1rem;
  background: var(--navy-ink); border-top: 1px solid var(--rule);
  font-size: .78rem; letter-spacing: .13em; text-transform: uppercase; color: var(--cream-dim);
}
.player-bar a { color: var(--gold-light); }
.film-note { font-size: .95rem; color: var(--cream-dim); margin: 1rem 0 0; max-width: 70ch; }

/* --------------------------------------------------------------- sections */
.section { padding-block: 4rem; }
.section--paper { background: var(--paper); color: var(--ink); }
.section--paper .kicker { color: #9c7c12; }
.section--paper .lede, .section--paper p { color: #3b4554; }
.section--paper a { color: #8a6b0d; }
.section--ink { background: var(--navy-ink); }
.section-head { max-width: 74ch; margin-bottom: 2.4rem; }
.section-head p { color: inherit; }

.rule-pair { border-top: 1px solid var(--rule); margin-bottom: 2.4rem; }

/* films sections list */
.reel { display: grid; gap: 0; border-top: 1px solid var(--rule); }
.reel article {
  display: grid; grid-template-columns: 92px minmax(0, 1fr) minmax(0, 320px);
  gap: 1.6rem; align-items: start;
  padding: 1.9rem 0; border-bottom: 1px solid var(--rule);
}
.reel .numeral { font-family: var(--display); font-weight: 700; font-size: 2.1rem; color: var(--gold); line-height: 1; }
.reel h3 { font-size: 1.32rem; margin-bottom: .5rem; }
.reel p { margin: 0 0 .7rem; color: var(--cream-dim); font-size: 1rem; }
.reel .stamp {
  display: inline-block; font-size: .66rem; letter-spacing: .22em; text-transform: uppercase;
  color: var(--navy-ink); background: var(--gold); padding: .28rem .6rem; margin-bottom: .7rem;
}
.reel img { width: 100%; border: 1px solid var(--rule); }
.section--paper .reel { border-color: var(--paper-line); }
.section--paper .reel article { border-color: var(--paper-line); }
.section--paper .reel p { color: #4a5566; }

/* quote panels */
.quote {
  border-left: 3px solid var(--gold); padding: .2rem 0 .2rem 1.4rem;
  margin: 1.1rem 0; font-size: 1.02rem; color: var(--cream-dim);
}
.section--paper .quote { color: #3b4554; }
.quote cite { display: block; font-style: normal; font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: #9c7c12; margin-top: .5rem; }

/* programs */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.4rem; }
.card { border: 1px solid var(--rule); padding: 1.5rem 1.4rem; background: rgba(255, 255, 255, .02); }
.card h3 { color: var(--gold-light); margin-bottom: .55rem; }
.card p { margin: 0; font-size: .98rem; color: var(--cream-dim); }
.section--paper .card { background: #fffdf7; border-color: var(--paper-line); }
.section--paper .card h3 { color: #8a6b0d; }
.section--paper .card p { color: #4a5566; }

.initiatives { display: grid; gap: 1rem; margin-top: 1.6rem; }
.initiative { border-top: 1px solid var(--rule); padding-top: 1rem; }
.initiative h3 { font-size: 1.05rem; color: var(--cream); }
.initiative span { font-size: .74rem; letter-spacing: .18em; text-transform: uppercase; color: var(--gold); }
.initiative p { margin: .45rem 0 0; font-size: .97rem; color: var(--cream-dim); }

/* notice */
.notice { border: 1px solid var(--gold); padding: 1.4rem 1.5rem; background: rgba(201, 162, 39, .07); }
.notice h3 { color: var(--gold-light); margin-bottom: .6rem; }
.notice p { margin: 0 0 .7rem; color: var(--cream); font-size: 1rem; }
.notice p:last-child { margin-bottom: 0; }
.section--paper .notice { background: rgba(201, 162, 39, .1); }
.section--paper .notice p { color: var(--ink); }
.section--paper .notice h3 { color: #8a6b0d; }

/* downloads */
.downloads { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1.2rem; }
.dl { border: 1px solid var(--rule); padding: 1.4rem; display: flex; flex-direction: column; gap: .35rem; }
.dl strong { font-family: var(--display); font-size: 1.02rem; color: var(--cream); }
.section--paper .dl strong { color: var(--ink); }
.dl span { font-size: .88rem; color: var(--cream-dim); }
.section--paper .dl span { color: #4a5566; }
.dl a { margin-top: .7rem; font-size: .78rem; letter-spacing: .16em; text-transform: uppercase; }

/* tables and lists */
table.src { width: 100%; border-collapse: collapse; font-size: .98rem; }
table.src th, table.src td { text-align: left; vertical-align: top; padding: .95rem .9rem; border-bottom: 1px solid var(--paper-line); }
table.src th { font-family: var(--display); font-size: .74rem; letter-spacing: .18em; text-transform: uppercase; color: #8a6b0d; }
table.src td:first-child { width: 34%; }

ol.quotes { list-style: none; counter-reset: q; padding: 0; margin: 0; }
ol.quotes li {
  counter-increment: q; position: relative; padding: 1.05rem 0 1.05rem 3rem;
  border-bottom: 1px solid var(--paper-line); color: #3b4554;
}
ol.quotes li::before {
  content: counter(q, decimal-leading-zero);
  position: absolute; left: 0; top: 1.15rem;
  font-family: var(--display); font-weight: 700; color: var(--gold); font-size: .95rem;
}
ol.quotes cite { display: block; font-style: normal; font-size: .78rem; letter-spacing: .13em; text-transform: uppercase; color: #8a6b0d; margin-top: .45rem; }

.transcript { max-width: 74ch; }
.transcript .cue { margin: 0 0 1.15rem; }
.transcript .cue span { display: block; font-size: .72rem; letter-spacing: .18em; color: var(--gold); margin-bottom: .2rem; }
.section--paper .transcript .cue span { color: #8a6b0d; }
.transcript .cue p { margin: 0; }

.checklist { list-style: none; padding: 0; margin: 0; display: grid; gap: .8rem; }
.checklist li { padding-left: 1.6rem; position: relative; }
.checklist li::before { content: "—"; position: absolute; left: 0; color: var(--gold); }

/* footer */
.footer { background: var(--navy-ink); border-top: 1px solid var(--rule); padding-block: 3rem 2.4rem; }
.footer .grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2rem; }
.footer h3 { font-size: .76rem; letter-spacing: .2em; text-transform: uppercase; color: var(--gold); margin-bottom: .9rem; }
.footer ul { list-style: none; padding: 0; margin: 0; }
.footer li { margin-bottom: .45rem; font-size: .95rem; color: var(--cream-dim); }
.footer .creed { font-family: var(--display); letter-spacing: .24em; color: var(--cream); font-size: .95rem; }
.footer .fine { margin-top: 2.4rem; padding-top: 1.3rem; border-top: 1px solid var(--rule); font-size: .82rem; color: var(--cream-dim); }

@media (max-width: 900px) {
  .reel article { grid-template-columns: 62px minmax(0, 1fr); }
  .reel article img { grid-column: 2; }
  .footer .grid { grid-template-columns: 1fr; }
  body { font-size: 18px; }
}
@media (max-width: 560px) {
  .reel article { grid-template-columns: 1fr; }
  .reel article img, .reel .numeral { grid-column: 1; }
  .reel .numeral { font-size: 1.5rem; }
}

/* the quotation list also appears on the navy ground — keep it legible */
.section:not(.section--paper) ol.quotes li { color: var(--cream); border-bottom-color: var(--rule); }
.section:not(.section--paper) ol.quotes cite { color: var(--gold-light); }
/* ------------------------------------------------- USDA pages & forms */
.steps { list-style: none; counter-reset: s; padding: 0; margin: 0; display: grid; gap: 1.1rem; }
.steps li { counter-increment: s; position: relative; padding-left: 3rem; }
.steps li::before {
  content: counter(s); position: absolute; left: 0; top: .1rem;
  font-family: var(--display); font-weight: 700; color: var(--gold);
  border: 1px solid var(--rule); width: 1.9rem; height: 1.9rem;
  display: grid; place-items: center; font-size: .95rem;
}
.section--paper .steps li::before { color: #8a6b0d; border-color: var(--paper-line); }
.steps h3 { font-size: 1.06rem; margin-bottom: .3rem; }
.steps p { margin: 0; }

table.limits { width: 100%; border-collapse: collapse; font-size: .95rem; }
table.limits th, table.limits td { padding: .55rem .7rem; border-bottom: 1px solid var(--paper-line); text-align: left; }
table.limits thead th {
  font-family: var(--display); font-size: .7rem; letter-spacing: .16em; text-transform: uppercase;
  color: #8a6b0d; position: sticky; top: 0; background: var(--paper);
}
table.limits td:nth-child(2), table.limits td:nth-child(3) { font-variant-numeric: tabular-nums; white-space: nowrap; }
table.limits tbody tr:nth-child(even) { background: rgba(201, 162, 39, .05); }
.scroll { max-height: 30rem; overflow: auto; border: 1px solid var(--paper-line); }

.form-note { font-size: .92rem; color: #4a5566; }
.form { display: grid; gap: 2.2rem; }
fieldset { border: 0; padding: 0; margin: 0; }
fieldset > legend {
  font-family: var(--display); font-size: 1.1rem; color: var(--ink);
  padding: 0 0 .3rem; border-bottom: 1px solid var(--paper-line); width: 100%; margin-bottom: 1.3rem;
}
fieldset > legend .band {
  display: block; font-family: var(--serif); font-size: .72rem; letter-spacing: .2em;
  text-transform: uppercase; color: #8a6b0d; margin-bottom: .25rem;
}
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1.1rem; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 1.1rem; }
#preapp .field { display: block; }
#preapp .field > span {
  display: block; font-size: .74rem; letter-spacing: .14em; text-transform: uppercase;
  color: #8a6b0d; margin-bottom: .35rem;
}
#preapp .field .req { color: #8a2f2f; }
#preapp .field input, #preapp .field select, #preapp .field textarea {
  width: 100%; font-family: var(--serif); font-size: 1.02rem; color: var(--ink);
  background: #fffdf7; border: 1px solid var(--paper-line); border-radius: 0; padding: .58rem .68rem;
}
#preapp .field textarea { min-height: 5.4rem; resize: vertical; }
#preapp .field input:focus, #preapp .field select:focus, #preapp .field textarea:focus {
  outline: 2px solid var(--gold); outline-offset: 1px; background: #fff;
}
#preapp .field .hint { display: block; font-size: .82rem; color: #6b7482; margin-top: .3rem; }
.choices { display: flex; flex-wrap: wrap; gap: .4rem 1.5rem; }
.choices label { display: inline-flex; align-items: center; gap: .5rem; font-size: .98rem; color: var(--ink); }
.repeat { display: grid; gap: 1rem; }
.repeat-row { border: 1px dashed var(--paper-line); padding: 1rem; display: grid; gap: .95rem; background: #fffdf7; }
.repeat-row .row-head { display: flex; justify-content: space-between; align-items: baseline; }
.repeat-row .row-head strong { font-family: var(--display); font-size: .84rem; letter-spacing: .16em; text-transform: uppercase; color: #8a6b0d; }
.remove { background: none; border: 0; font: inherit; font-size: .8rem; color: #8a2f2f; cursor: pointer; text-decoration: underline; }
.add {
  justify-self: start; background: none; border: 1px solid var(--paper-line); background: #fffdf7;
  font: inherit; font-size: .8rem; letter-spacing: .14em; text-transform: uppercase;
  color: #8a6b0d; padding: .5rem .9rem; cursor: pointer;
}
.add:hover, .remove:hover { text-decoration: underline; }
#preapp .consent { display: grid; grid-template-columns: auto 1fr; gap: .7rem; align-items: start; font-size: .95rem; color: #3b4554; margin: 0 0 1rem; }
#preapp .consent input { margin-top: .35rem; width: 1.05rem; height: 1.05rem; }
#preapp .consent strong { color: var(--ink); }
.submit-row { display: flex; flex-wrap: wrap; align-items: center; gap: 1.1rem; margin-top: 1.6rem; }
button.primary {
  font-family: var(--display); font-size: .92rem; letter-spacing: .18em; text-transform: uppercase;
  background: var(--gold); color: var(--navy-ink); border: 1px solid var(--gold);
  padding: .85rem 1.5rem; cursor: pointer;
}
button.primary:hover { background: var(--gold-light); }
button.primary[disabled] { opacity: .55; cursor: progress; }
.status { margin-top: 1.4rem; padding: 1.1rem 1.2rem; border: 1px solid var(--paper-line); background: #fffdf7; display: none; }
.status.show { display: block; }
.status.ok { border-color: #2f6b3a; background: #f2f8f2; }
.status.err { border-color: #8a2f2f; background: #fdf5f4; }
.status h3 { font-size: 1rem; margin-bottom: .5rem; }
.status p { margin: 0 0 .6rem; font-size: .96rem; color: #3b4554; }
.status code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .95rem; color: var(--ink); }
.hp { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.pill {
  display: inline-block; font-size: .68rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--navy-ink); background: var(--gold); padding: .3rem .6rem;
}
.section--paper .lede { font-size: 1.05rem; }/* ================================================================ e-signature */
.hero--slim { padding-block: 2.6rem 2.2rem; }

.sign-layout { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 2.6rem; align-items: start; }

.sign-form { display: grid; gap: 1.9rem; }

.field-group {
  border: 1px solid var(--paper-line); background: #fffdf7;
  padding: 1.5rem 1.5rem 1.7rem; margin: 0;
}
.field-group legend {
  font-family: var(--display); font-size: .76rem; letter-spacing: .2em;
  text-transform: uppercase; color: #8a6b0d; padding: 0 .5rem;
}

.field { display: block; margin-bottom: 1.05rem; }
.field:last-child { margin-bottom: 0; }
.field-label { display: block; font-size: .95rem; color: #3b4554; margin-bottom: .4rem; }
.field-label em { font-style: italic; color: #6b7280; font-size: .85rem; }

.field input[type="text"],
.field input[type="email"],
.field input[type="date"],
.field textarea {
  width: 100%; font-family: var(--serif); font-size: 1.02rem; color: var(--ink);
  background: #fff; border: 1px solid var(--paper-line); border-radius: 2px;
  padding: .6rem .7rem; line-height: 1.5;
}
.field textarea { resize: vertical; min-height: 7rem; }
.field input:focus, .field textarea:focus {
  outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(201, 162, 39, .18);
}

.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem; }

/* mode switch */
.mode-switch { display: flex; gap: .6rem; margin-bottom: 1.1rem; }
.mode { display: inline-flex; align-items: center; gap: .5rem; cursor: pointer;
  border: 1px solid var(--paper-line); background: #fff; padding: .5rem .9rem;
  font-size: .85rem; letter-spacing: .1em; text-transform: uppercase; color: #3b4554; }
.mode:has(input:checked) { border-color: var(--gold); background: rgba(201, 162, 39, .12); color: #6f5609; }
.mode input { accent-color: #8a6b0d; }

/* signature pad */
.pad-wrap { position: relative; border: 1px dashed #c9b98c; background: #fff; }
.pad { display: block; width: 100%; height: 210px; touch-action: none; cursor: crosshair; }
.pad-hint {
  position: absolute; inset: auto 0 0 0; margin: 0; padding: .5rem .8rem;
  font-size: .82rem; color: #9aa0a8; pointer-events: none; text-align: center;
}
.pad-actions { display: flex; gap: .7rem; margin-top: .8rem; flex-wrap: wrap; }

.typed-input { font-style: italic; font-size: 1.5rem !important; }

.consent { display: grid; grid-template-columns: auto 1fr; gap: .8rem; align-items: start;
  font-size: .98rem; color: #3b4554; margin-bottom: 1.1rem; }
.consent input { margin-top: .35rem; width: 1.1rem; height: 1.1rem; accent-color: #8a6b0d; }

.form-error { margin: 0 0 1rem; padding: .7rem .9rem; background: #fdf0ee;
  border-left: 3px solid #a8402f; color: #7c2d1c; font-size: .95rem; }

.form-actions { display: flex; gap: .8rem; flex-wrap: wrap; }

/* buttons */
.btn {
  font-family: var(--serif); font-size: .82rem; letter-spacing: .14em;
  text-transform: uppercase; padding: .72rem 1.25rem; cursor: pointer;
  border: 1px solid var(--gold); border-radius: 2px;
}
.btn--gold { background: var(--gold); color: var(--navy-ink); border-color: var(--gold); }
.btn--gold:hover { background: var(--gold-light); }
.btn--ghost { background: transparent; color: #6f5609; border-color: #c9b98c; }
.btn--ghost:hover { border-color: var(--gold); background: rgba(201, 162, 39, .1); }

/* aside notices */
.sign-aside { display: grid; gap: 1.2rem; }
.notice--plain { border-color: var(--paper-line); background: #fffdf7; }
.section--paper .notice--plain { border-color: var(--paper-line); background: #fffdf7; }
.notice--plain h3 { color: #6f5609; }
.notice--plain p { color: #4a5566; }

/* record */
.record-img {
  width: 100%; border: 1px solid var(--rule);
  box-shadow: 0 22px 60px rgba(0, 0, 0, .45); background: #fff;
}
.record-actions { display: flex; gap: .8rem; flex-wrap: wrap; margin-top: 1.5rem; }

@media (max-width: 980px) {
  .sign-layout { grid-template-columns: 1fr; }
.field-row { grid-template-columns: 1fr; }
}

/* printing: only the signed record reaches paper */
@media print {
  .masthead, .hero, .footer, #signIntro, .record-actions, .film-note,
  #record .section-head, .skip { display: none !important; }
  body { background: #fff; color: #000; font-size: 12pt; }
  .section { padding: 0 !important; }
  .record-img { border: 0; box-shadow: none; }
  #record .wrap { width: 100%; }
}

/* --------------------------------------------------- four-column footer */
.footer .grid { grid-template-columns: 1.3fr 1fr 1fr 1fr; }
@media (max-width: 900px) { .footer .grid { grid-template-columns: 1fr; } }
/* ------------------------------------------------- housing gallery */
/* Merged from the supplied AGAPE gallery code, scoped under .housing-gallery and coloured from this
   site's palette. Images use object-fit: contain so nothing is cropped and watermarks stay visible. */
.housing-gallery .gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  margin-top: 2.2rem;
}
.housing-gallery .gallery-card {
  margin: 0;
  background: #fffdf7;
  border: 1px solid var(--paper-line);
  border-radius: 12px;
  overflow: hidden;
}
.housing-gallery .gallery-card.featured { grid-column: 1 / -1; }
.housing-gallery .image-link {
  display: block;
  background: var(--paper);
  border-bottom: 1px solid var(--paper-line);
}
.housing-gallery .gallery-card img {
  display: block;
  width: 100%;
  height: 270px;
  object-fit: contain;
}
.housing-gallery .gallery-card.featured img { height: auto; max-height: 650px; }
.housing-gallery .gallery-card figcaption { padding: 18px 18px 20px; }
.housing-gallery .gallery-card h3 {
  font-family: var(--display);
  font-size: 1.02rem;
  letter-spacing: .03em;
  margin: 0 0 .45rem;
  color: var(--ink);
}
.housing-gallery .gallery-card p { font-size: .95rem; margin: 0; color: #4a5566; }
.housing-gallery .tag {
  display: inline-block; font-size: 11px; letter-spacing: 1.4px; text-transform: uppercase;
  color: #8a6b0d; margin-bottom: 6px;
}
.housing-gallery .view-link {
  display: inline-block; margin-top: 12px; font-size: 13px; color: #8a6b0d;
  text-decoration: underline; text-underline-offset: 3px;
}
.housing-gallery .gallery-note {
  margin-top: 1.8rem; font-size: 13px; line-height: 1.7; color: #4a5566; max-width: 70ch;
}
.housing-gallery .gallery-cta { margin-top: 1.6rem; display: flex; flex-wrap: wrap; gap: 16px; align-items: center; }
/* A photograph that has not been placed in assets/ yet reads as a stated gap, not a broken icon. */
.housing-gallery .gallery-card.is-missing .image-link {
  min-height: 200px; display: flex; align-items: center; justify-content: center;
}
.housing-gallery .gallery-card.is-missing .image-link::after {
  content: "Photograph not yet uploaded"; font-size: 13px; letter-spacing: .04em; color: #7c3428;
}
@media (max-width: 900px) {
  .housing-gallery .gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 580px) {
  .housing-gallery .gallery-grid { grid-template-columns: 1fr; }
  .housing-gallery .gallery-card img { height: auto; }
}

/* ------------------------------------------------- film autoplay control */
.player-bar .sound-toggle {
  background: var(--gold);
  color: var(--navy-ink);
  border: 0;
  cursor: pointer;
  font-family: var(--serif);
  font-size: .78rem;
  letter-spacing: .13em;
  text-transform: uppercase;
  padding: .45rem .85rem;
}
.player-bar .sound-toggle:hover { background: var(--gold-light); }
.player-bar .sound-toggle[aria-pressed="true"] { background: var(--cream); }

/* The player is the positioning context for the sound prompt that sits over the picture. */
.player { position: relative; }
.sound-prompt {
  position: absolute;
  left: 1rem;
  bottom: 3.9rem;
  z-index: 2;
  background: var(--gold);
  color: var(--navy-ink);
  border: 0;
  cursor: pointer;
  font-family: var(--serif);
  font-size: .82rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  padding: .6rem 1rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .45);
}
.sound-prompt:hover { background: var(--gold-light); }
