/* Healthra Medical Center — light, marble-bright, gold as hairline only.
   Ratio: white/cream ~80%, dark brown bands ~15%, gold ~5% (1–2px lines,
   small caps labels, letterforms — never a fill).
   Shared by all twelve pages; built via build.py from partials/. */

/* Self-hosted fonts (latin subset, variable weight), preloaded from
   templates/base.html — no third-party request on page load. */
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 500 600;
  font-display: swap;
  src: url("/fonts/cormorant-garamond.woff2") format("woff2");
}
@font-face {
  font-family: "Source Sans 3";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("/fonts/source-sans-3.woff2") format("woff2");
}

:root {
  --brown-900: #2E2521;
  --brown-700: #4A3C34;
  --cream:     #F5F1EA;
  --white:     #FFFFFF;
  --gold:      #C9A24B;
  /* Gold TEXT on cream/white must use this darker gold (5.39:1 on cream);
     #C9A24B is for text on the dark bands and for decorative hairlines/dots. */
  --gold-on-light: #7A5E28;
  --text:      #1C1715;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  font-family: "Source Sans 3", "Helvetica Neue", Arial, sans-serif;
  font-size: 20px;
  line-height: 1.65;
  color: var(--text);
  background: var(--white);
}

h1, h2, h3 {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 500;
  line-height: 1.25;
  margin: 0 0 0.5em;
  color: var(--brown-900);
}
h1 { font-size: 2.6rem; line-height: 1.15; }
h2 { font-size: 2.1rem; }
h3 { font-size: 1.5rem; }
@media (min-width: 900px) {
  h1 { font-size: 3.6rem; }
  h2 { font-size: 2.5rem; }
}

p { margin: 0 0 1em; }

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

.wrap {
  max-width: 1100px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}
/* The single reading column: every element inside shares this width,
   centered, so text, hairlines, and lists always align edge to edge. */
.narrow { max-width: 680px; }

/* Eyebrow labels: small caps sans, tracked */
.eyebrow {
  font-family: "Source Sans 3", sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--brown-700);
  margin: 0 0 20px;
}
.section-dark .eyebrow,
.cta-band .eyebrow { color: var(--gold); }

/* Never let a form number (I-693) break across lines */
.nowrap { white-space: nowrap; }

/* Subtitle line directly under a page-head H1 */
.page-sub {
  font-family: "Source Sans 3", sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-on-light);
  margin: 0 0 1em;
}

/* Gold hairline under a heading — opt in with .gold-rule */
.gold-rule::after {
  content: "";
  display: block;
  width: 56px;
  height: 2px;
  background: var(--gold);
  margin-top: 22px;
}

/* Links and focus */
a { color: var(--brown-700); text-underline-offset: 3px; }
:focus-visible {
  outline: 3px solid var(--brown-900);
  outline-offset: 3px;
}
.section-dark :focus-visible,
.cta-band :focus-visible,
.site-header :focus-visible,
.site-footer :focus-visible { outline-color: var(--white); }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--brown-900);
  color: var(--white);
  padding: 16px 24px;
  z-index: 100;
}
.skip-link:focus-visible { left: 0; }

/* Buttons — every tap target at least 56px tall. No gold fills, ever. */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 14px 36px;
  font-family: "Source Sans 3", sans-serif;
  font-size: 1.05rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 4px;
}
.btn-primary {
  background: var(--brown-900);
  color: var(--white);
  border: 1px solid var(--gold);
}
.btn-secondary {
  background: transparent;
  color: var(--brown-900);
  border: 1px solid var(--brown-700);
}
.section-dark .btn-secondary,
.cta-band .btn-secondary {
  color: var(--white);
  border-color: var(--gold);
}
.btn-big {
  font-size: 1.15rem;
  width: 100%;
  text-align: center;
}
@media (min-width: 700px) {
  .btn-big { width: auto; }
}

/* ============ Header: dark brown bar, gold hairline on the bottom edge */
.site-header {
  background: var(--brown-900);
  padding: 12px 0;
  border-bottom: 1px solid var(--gold);
  position: relative;
}
.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.home-link { text-decoration: none; }
.wordmark {
  display: block;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 500;
  font-size: 1.6rem;
  letter-spacing: 0;
  margin: 0;
  line-height: 1.1;
}
.wordmark-sub {
  display: block;
  font-family: "Source Sans 3", sans-serif;
  /* Sized and tracked relative to the serif line above so that
     "MEDICAL CENTER" renders the same width as "Healthra" (±2px)
     at every lockup size (header and footer). Measured, not eyeballed. */
  font-size: 0.3875em;
  font-weight: 600;
  letter-spacing: 0.1124em;
  white-space: nowrap;
  text-transform: uppercase;
}

/* The lockup is the ONLY place gradients are allowed: two metals,
   matching the real lobby sign. Fallback color first, so browsers
   without background-clip show solid metal instead of invisible text. */
.wm-gold {
  color: #C9A24B;
  background: linear-gradient(168deg,
    #8A6B2F 0%,  #C9A24B 18%, #F3E3A8 37%,
    #C9A24B 54%, #9A7636 71%, #E8D28F 87%, #B8923F 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.wm-silver {
  color: #AEB3B8;
  background: linear-gradient(168deg,
    #6E7276 0%,  #B9BEC3 20%, #F2F4F6 40%,
    #AEB3B8 57%, #7C8186 74%, #DDE1E4 90%, #9BA0A5 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Nav links: cream, uppercase, tracked; active page gets a gold hairline */
.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
}
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 56px;
  white-space: nowrap;
  padding: 8px 12px;
  font-family: "Source Sans 3", sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--cream);
}
body[data-page="inicio"]    .site-nav a[data-nav="inicio"],
body[data-page="servicios"] .site-nav a[data-nav="servicios"],
body[data-page="inmigracion"] .site-nav a[data-nav="inmigracion"],
body[data-page="visita"]    .site-nav a[data-nav="visita"],
body[data-page="seguros"]   .site-nav a[data-nav="seguros"],
body[data-page="nosotros"]  .site-nav a[data-nav="nosotros"],
body[data-page="contacto"]  .site-nav a[data-nav="contacto"] {
  color: var(--white);
  box-shadow: inset 0 -2px 0 var(--gold);
}

.lang-link {
  display: inline-flex;
  align-items: center;
  min-height: 56px;
  padding: 8px 12px;
  font-family: "Source Sans 3", sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: underline;
  text-underline-offset: 4px;
  color: var(--cream);
}

.header-phone { padding: 12px 18px; font-size: 0.95rem; white-space: nowrap; }
.phone-short { display: none; }

.menu-btn {
  display: none;
  min-height: 56px;
  min-width: 80px;
  padding: 8px 16px;
  font-family: "Source Sans 3", sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: transparent;
  color: var(--cream);
  border: 1px solid var(--gold);
  border-radius: 4px;
  cursor: pointer;
}
.menu-btn[aria-expanded="true"] {
  background: var(--brown-700);
  color: var(--white);
}

/* Mobile: nav collapses into a panel; the call button never hides */
@media (max-width: 1099px) {
  .lang-link-desktop { display: none; }
  .menu-btn { display: inline-flex; align-items: center; justify-content: center; }
  .phone-full { display: none; }
  .phone-short { display: inline; }
  .header-phone { padding: 12px 20px; }

  .js .site-nav { display: none; }
  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--brown-900);
    border-bottom: 1px solid var(--gold);
    z-index: 60;
  }
  .site-nav.open { display: block; }
  .site-nav ul { display: block; padding: 8px 0 16px; }
  .site-nav a, .site-nav .lang-link {
    display: flex;
    min-height: 56px;
    padding: 8px 24px;
    font-size: 1rem;
  }
  body[data-page="inicio"]    .site-nav a[data-nav="inicio"],
  body[data-page="servicios"] .site-nav a[data-nav="servicios"],
  body[data-page="inmigracion"] .site-nav a[data-nav="inmigracion"],
  body[data-page="visita"]    .site-nav a[data-nav="visita"],
  body[data-page="seguros"]   .site-nav a[data-nav="seguros"],
  body[data-page="nosotros"]  .site-nav a[data-nav="nosotros"],
  body[data-page="contacto"]  .site-nav a[data-nav="contacto"] {
    box-shadow: inset 4px 0 0 var(--gold);
    color: var(--white);
  }
}
@media (min-width: 1100px) {
  .nav-lang { display: none; }
  /* Eight items on one line: tighter item gap and tracking, and the
     15px legibility floor (the old 0.82rem was 13.12px). */
  .site-nav a {
    font-size: 15px;
    letter-spacing: 0.06em;
    padding: 8px 7px;
  }
}

/* ============ Sections — let them breathe */
.section {
  padding: 64px 0;
  background: var(--white);
}
.section-cream { background: var(--cream); }
.section-dark {
  background: var(--brown-900);
  color: var(--cream);
}
.section-dark h1, .section-dark h2, .section-dark h3 { color: var(--gold); }
.section-dark a { color: var(--cream); }
@media (min-width: 900px) {
  .section { padding: 120px 0; }
}

/* One owner per gap: when two same-background sections are adjacent,
   the shared space belongs to the LOWER section's padding-top; the
   upper one gives up its padding-bottom. Colored bands are exempt —
   their padding is INSIDE the band and both edges must keep it. The
   CTA band and plans/ticker bands are untouched either way: they are
   not `.section`, and the CTA band sits outside <main>. */
main .section:not(.section-cream):not(.section-dark):not(.page-head):has(+ .section:not(.section-cream):not(.section-dark)) {
  padding-bottom: 0;
}
/* With the padding zeroed, the last child's bottom margin would collapse
   out of the section and widen the gap past 80px — same single-owner fix
   as the page head: the structural padding owns the gap, margins don't. */
main .section:not(.section-cream):not(.section-dark):not(.page-head):has(+ .section:not(.section-cream):not(.section-dark)) .wrap > :last-child {
  margin-bottom: 0;
}
/* A light section keeps clear space above a colored band, so content
   (e.g. a button) never sits on the band's edge. */
main .section:not(.section-cream):not(.section-dark):not(.page-head):has(+ .section-cream),
main .section:not(.section-cream):not(.section-dark):not(.page-head):has(+ .section-dark) {
  padding-bottom: 48px;
}
@media (min-width: 900px) {
  main .section:not(.section-cream):not(.section-dark):not(.page-head):has(+ .section-cream),
  main .section:not(.section-cream):not(.section-dark):not(.page-head):has(+ .section-dark) {
    padding-bottom: 80px;
  }
  /* Two light text sections in a row read as one flow: 80px gap,
     owned by the lower section. 120px stays wherever a section meets
     a colored band or a photo moment. */
  main .section:not(.section-cream):not(.section-dark):not(.page-head)
    + .section:not(.section-cream):not(.section-dark) {
    padding-top: 80px;
  }
}

/* Page heads (subpages) sit a bit tighter at the top, and OWN the
   tight gap to the content below them: a head and its content are one
   unit, so the head keeps a small padding-bottom and the plain section
   after it contributes no padding-top. A colored band after a head
   keeps its own interior padding (it is inside the band, not gap). */
.page-head { padding-bottom: 32px; }
main .page-head + .section:not(.section-cream):not(.section-dark) {
  padding-top: 0;
}
/* The head's padding-bottom is the gap's single owner: the last
   element's own margin must not add to it (an H1's 28.8px bottom
   margin was widening the gap on pages whose head ends at the H1). */
main .page-head .wrap > :last-child { margin-bottom: 0; }
@media (min-width: 900px) {
  .page-head { padding-top: 96px; padding-bottom: 48px; }
}

.section-intro {
  font-size: 1.1rem;
}

/* Hero — bright, like the room */
.hero { background: var(--cream); }
.hero-inner {
  display: grid;
  padding-top: 64px;
  padding-bottom: 64px;
}
.hero-sub {
  font-size: 1.15rem;
  max-width: 34ch;
  margin-bottom: 1.6em;
}
.hero-hours {
  margin-top: 24px;
  font-size: 1rem;
  color: var(--brown-700);
}
.hero-photo { margin-top: 48px; }
.hero-photo img,
.split-photo img,
.photo-large img {
  width: 100%;
  max-width: 440px;
  margin: 0 auto;
  border: 1px solid var(--gold);
}
@media (min-width: 900px) {
  .hero-inner {
    grid-template-columns: 1fr 420px;
    gap: 80px;
    align-items: center;
    padding-top: 120px;
    padding-bottom: 120px;
  }
  .hero-photo { margin-top: 0; }
}

/* Split: copy beside a portrait photo */
.split {
  display: grid;
  gap: 48px;
}
.address-lines { font-size: 1.15rem; }
@media (min-width: 900px) {
  .split {
    grid-template-columns: 1fr 420px;
    gap: 80px;
    align-items: center;
  }
}
/* A split whose photo column is removed (slot commented out awaiting
   new photos): the lone text column takes the full width. */
.split > :only-child { grid-column: 1 / -1; }

/* Services page: one block per service, hairline rules between.
   (Top spacing comes from the page-head's own padding-bottom.) */
.service {
  padding: 40px 0;
  border-bottom: 1px solid var(--gold);
}
.service:first-child { border-top: 1px solid var(--gold); }
.service h2 { font-size: 1.7rem; margin-bottom: 0.4em; }
.service p { margin: 0; }
@media (min-width: 900px) {
  .service h2 { font-size: 1.9rem; }
}

/* About page: the largest photos on the site */
.photo-large {
  margin: 0 0 56px;
}
.photo-large img { max-width: 720px; }
.photo-large figcaption {
  max-width: 720px;
  margin: 12px auto 0;
  font-size: 0.95rem;
  color: var(--brown-700);
}
.photo-large:last-child { margin-bottom: 0; }

/* Insurance */
.plans {
  list-style: none;
  padding: 0;
  margin: 0 0 40px;
  border-top: 1px solid var(--gold);
}
.plans li {
  padding: 18px 0;
  border-bottom: 1px solid var(--gold);
  font-size: 1.15rem;
  font-weight: 600;
}

/* Contact page */
.contact-grid {
  display: grid;
  gap: 40px;
  margin-bottom: 64px;
}
@media (min-width: 700px) {
  .contact-grid { grid-template-columns: repeat(2, 1fr); }
}
.contact-label {
  font-family: "Source Sans 3", sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--brown-700);
  margin-bottom: 16px;
}
.phone-link {
  font-size: 1.3rem;
  font-weight: 600;
  display: inline-block;
  padding: 10px 0;
  color: var(--brown-900);
}
.map-frame {
  border: 1px solid var(--gold);
}
.map-frame iframe {
  display: block;
  width: 100%;
  height: 420px;
  border: 0;
}

/* ============ Closing CTA band — one deliberate dark band on every page */
.cta-band {
  background: var(--brown-900);
  color: var(--cream);
  text-align: center;
  padding: 88px 0;
}
.cta-band h2 {
  color: var(--gold);
}
.cta-band p { margin-bottom: 1.6em; }
@media (min-width: 900px) {
  .cta-band { padding: 120px 0; }
}

/* Footer */
.site-footer {
  background: var(--brown-900);
  color: var(--cream);
  padding: 72px 0 160px;  /* room for the sticky call bar */
  text-align: center;
  border-top: 1px solid var(--gold);
}
.site-footer a { color: var(--cream); font-weight: 600; }
.wordmark-footer {
  margin-bottom: 20px;
  font-size: 1.9rem;
}
.footer-legal { font-size: 0.85rem; color: #BDB3A9; }
@media (min-width: 900px) {
  .site-footer { padding-bottom: 72px; }
}

/* Sticky mobile call bar — white, hairline on top */
.call-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  background: var(--white);
  border-top: 1px solid var(--gold);
  z-index: 50;
}
.call-bar-btn { width: 100%; }
@media (min-width: 900px) {
  .call-bar { display: none; }
}

/* Services ticker — thin dark band under the hero, gold hairlines */
.ticker-band {
  position: relative;
  background: var(--brown-900);
  border-top: 1px solid var(--gold);
  border-bottom: 1px solid var(--gold);
}
.ticker {
  display: flex;
  overflow: hidden;
  padding: 16px 0;
}
.ticker-track {
  display: flex;
  flex-shrink: 0;
  min-width: max-content;
  margin: 0;
  padding: 0;
  list-style: none;
  /* 72s keeps the same px/s reading speed as the 40s eleven-item loop
     now that the track holds twenty items. */
  animation: ticker-scroll 72s linear infinite;
}
.ticker-track li {
  display: flex;
  align-items: center;
  white-space: nowrap;
  color: var(--cream);
  font-size: 1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
}
.ticker-track li::after {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--gold);
  margin: 0 28px;
  flex-shrink: 0;
}
@keyframes ticker-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-100%); }
}
.ticker-band:hover .ticker-track,
.ticker-band:focus-within .ticker-track,
.ticker-band.paused .ticker-track {
  animation-play-state: paused;
}

/* Pause/play button — needs JS, so hidden without it */
.ticker-toggle { display: none; }
.js .ticker-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  min-width: 44px;
  min-height: 44px;
  padding: 0;
  background: var(--brown-900);
  color: var(--cream);
  border: 1px solid var(--gold);
  border-radius: 4px;
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  cursor: pointer;
}
.js .ticker-toggle:focus-visible {
  outline: 3px solid var(--white);
  outline-offset: 2px;
}

/* Reduced motion: no animation — a static, wrapped, centered row */
@media (prefers-reduced-motion: reduce) {
  .ticker { padding: 16px; justify-content: center; }
  .ticker-track {
    animation: none;
    flex-wrap: wrap;
    justify-content: center;
    min-width: 0;
    row-gap: 10px;
  }
  .ticker-track[aria-hidden="true"] { display: none; }
  .ticker-track li:last-child::after { display: none; }
  .js .ticker-toggle { display: none; }
}

/* Accepted-plans row — static cream band below the ticker */
.plans-band {
  background: var(--cream);
  padding: 18px 16px;
  text-align: center;
}
.plans-row {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  font-size: 1rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: baseline;
  column-gap: 14px;
  row-gap: 6px;
}
.plans-row-label {
  color: var(--gold-on-light);
  font-size: 0.8rem;
  font-weight: 700;
}
.plans-row-names {
  color: var(--brown-700);
  font-weight: 600;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: baseline;
  column-gap: 10px;
  row-gap: 4px;
}
.plans-dot { color: var(--gold-on-light); }

/* Gold eyebrow variant — only for light backgrounds, so it uses the
   darker gold that clears 4.5:1 on cream/white */
.eyebrow-gold { color: var(--gold-on-light); }

/* Static services grid on the homepage — names only, gold hairlines */
.services-grid {
  list-style: none;
  margin: 36px 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  column-gap: 28px;
}
.services-grid li {
  padding: 14px 2px;
  border-bottom: 1px solid var(--gold);
  font-weight: 600;
}
@media (min-width: 900px) {
  .services-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Homepage: the twenty services grouped into five categories, each a
   full-width stacked row — category name + summary in a fixed narrow
   left column, its services wrapping into as many columns as fit on
   the right. Row heights follow content, so uneven item counts can
   never leave a hole. Mobile: name above, services beneath. */
.service-groups {
  display: grid;
  gap: 48px;
  margin: 36px 0;
}
.service-group h3 {
  font-size: 1.5rem;
  margin-bottom: 0.25em;
}
.group-sum {
  margin: 0 0 0.6em;
}
.service-group ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  column-gap: 28px;
  align-content: start;
}
.service-group li {
  padding: 14px 2px;
  border-bottom: 1px solid var(--gold);
  font-weight: 600;
}
@media (min-width: 900px) {
  .service-groups { row-gap: 56px; }
  .service-group {
    display: grid;
    grid-template-columns: 240px 1fr;
    grid-template-rows: auto 1fr;
    column-gap: 48px;
  }
  .service-group h3 { grid-column: 1; }
  .service-group .group-sum { grid-column: 1; margin-bottom: 0; }
  .service-group ul {
    grid-column: 2;
    grid-row: 1 / span 2;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  }
}

/* Numbered steps — Primera visita / Your first visit.
   Custom counters so each row (and its hairline) spans the full
   column width; the number hangs in the row's own left padding. */
.steps {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}
.steps li {
  position: relative;
  padding: 16px 0 16px 2.2em;
  border-bottom: 1px solid var(--gold);
  counter-increment: step;
}
.steps li::before {
  content: counter(step) ".";
  position: absolute;
  left: 0;
  font-weight: 700;
  color: var(--brown-700);
}
.steps li:last-child { border-bottom: none; }

/* Feature blocks — Nosotros, "Lo que nos hace distintos" */
.feature { margin-top: 40px; }
/* When a feature opens a section, the section's own spacing rules
   are the gap's single owner — no added margin. */
.wrap > .feature:first-child { margin-top: 0; }
.feature h3 { margin: 0 0 0.3em; }
.feature p { margin: 0; }

/* Full-width photo moment — edge to edge, no frame, no overlay.
   The slot is a landscape window; portrait or landscape files both
   fill it (object-fit: cover crops to the window). */
.photo-moment {
  margin: 0;
  width: 100%;
}
.photo-moment img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}
@media (min-width: 900px) {
  .photo-moment img { aspect-ratio: 21 / 9; }
}

/* Split variant: photo on the left at desktop, for layout variety */
@media (min-width: 900px) {
  .split-reverse { grid-template-columns: 420px 1fr; }
  .split-reverse > :first-child { order: 2; }
}

/* Fade-up on scroll — 400ms, once per section, JS-gated so content
   is always visible without JS, and fully off under reduced motion */
.js main .section,
.js main .photo-moment {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 400ms ease-out, transform 400ms ease-out;
}
.js main .section.in-view,
.js main .photo-moment.in-view {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  .js main .section,
  .js main .photo-moment {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
