/* ==========================================================================
   Luberon Dairy Supply. Layout, type and motion from the Kyakasengula Dairy Farm site.
   1. Tokens  2. Base  3. Layout  4. Buttons  5. Header & nav  6. Hero
   7. About  8. Products  9. How to order  10. Contact  11. Footer
   12. Floating WhatsApp  13. Motion  14. Reduced motion
   ========================================================================== */

/* 1. Tokens ---------------------------------------------------------------- */
:root {
  --brand-900:  #0F2A44;
  --brand-700:  #1D4E7A;          /* 8.7:1 white on it */
  --brand-100:  #E4EEF6;
  --accent-700: #8A4F0E;          /* 6:1 on cream-50 */
  --cream-50:   #FAF6EC;
  --white:      #FFFFFF;
  --ink:        #1B2430;
  --ink-soft:   #4A5563;          /* 7:1 on cream-50 */
  --line:       rgba(15, 42, 68, 0.12);

  --font-head: "Zilla Slab", Georgia, "Times New Roman", serif;
  --font-accent: "Lora", Georgia, serif;
  --font-body: "DM Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --radius-sm: 10px;
  --radius:    18px;
  --radius-lg: 28px;
  --shadow-sm: 0 1px 2px rgba(15, 42, 68, 0.06), 0 2px 8px rgba(15, 42, 68, 0.05);
  --shadow:    0 2px 4px rgba(15, 42, 68, 0.05), 0 12px 32px rgba(15, 42, 68, 0.10);

  --header-h: 84px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --section-pad: clamp(4rem, 9vw, 7rem);
  --gutter: 16px;
}

@media (min-width: 768px)  { :root { --gutter: 24px; } }
@media (min-width: 1024px) { :root { --gutter: 32px; } }

/* 2. Base ------------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 72px;
}

body {
  margin: 0;
  background: var(--cream-50);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

h1, h2, h3, h4 {
  font-family: var(--font-head);
  line-height: 1.12;
  margin: 0;
  text-wrap: balance;
}

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

a { color: var(--brand-700); text-underline-offset: 3px; }

ul, ol { list-style: none; margin: 0; padding: 0; }
figure { margin: 0; }
address { font-style: normal; }

:focus-visible {
  outline: 3px solid var(--accent-700);
  outline-offset: 3px;
  border-radius: 4px;
}

.visually-hidden {
  position: absolute !important;
  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: 16px; top: 12px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--white);
  color: var(--brand-900);
  font-weight: 600;
  border-radius: var(--radius-sm);
  transform: translateY(-160%);
  transition: transform 0.2s var(--ease-out);
}
.skip-link:focus { transform: translateY(0); }

.icon {
  width: 24px; height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* 3. Layout ---------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: var(--section-pad); }
.section-soft { background: var(--brand-100); }

.section-head { max-width: 680px; margin-bottom: clamp(2.5rem, 5vw, 3.5rem); }

.eyebrow {
  font-family: var(--font-accent);
  font-style: italic;
  font-size: 1.125rem;
  color: var(--accent-700);
  margin-bottom: 0.5rem;
}

h2 {
  font-size: clamp(2rem, 4.2vw, 3rem);
  font-weight: 700;
  color: var(--brand-700);
  letter-spacing: -0.01em;
}

.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}

@media (hover: hover) {
  .card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
}

.frame {
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--brand-100);
}
.frame img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.9s var(--ease-out);
}
@media (hover: hover) {
  .frame:hover img { transform: scale(1.04); }
}

/* 4. Buttons --------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 48px;
  padding: 0.75rem 1.6rem;
  border: 2px solid transparent;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: transform 0.25s var(--ease-out), background-color 0.25s ease,
              color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}
.btn:active { transform: translateY(0) scale(0.97); }

.btn-primary { background: var(--brand-700); color: var(--white); }
.btn-outline { border-color: var(--brand-700); color: var(--brand-700); }
.btn-outline-light { border-color: var(--white); color: var(--white); }
.btn-whatsapp { background: var(--brand-100); color: var(--brand-900); }
.btn-sm { min-height: 44px; padding: 0.55rem 1.1rem; font-size: 0.9375rem; }

@media (hover: hover) {
  .btn:hover { transform: translateY(-2px); }
  .btn-primary:hover { background: var(--brand-900); box-shadow: 0 8px 20px rgba(15, 42, 68, 0.25); }
  .btn-outline:hover { background: var(--brand-700); color: var(--white); }
  .btn-outline-light:hover { background: var(--white); color: var(--brand-900); }
  .btn-whatsapp:hover { background: var(--brand-700); color: var(--white); }
}

/* 5. Header & nav ---------------------------------------------------------- */
/* No transform or filter on .site-header: the mobile nav inside it is position:fixed. */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  height: var(--header-h);
  color: var(--white);
}

/* Solid background lives on a pseudo-element so it can fade and shrink with transform/opacity. */
.site-header::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--brand-900);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.18);
  opacity: 0;
  transform: scaleY(1);
  transform-origin: top;
  transition: opacity 0.35s ease, transform 0.35s var(--ease-out);
}

/* Legibility for the transparent state over the photo. */
.site-header::after {
  content: "";
  position: absolute;
  inset: 0 0 -40px 0;
  background: linear-gradient(to bottom, rgba(8, 22, 38, 0.55), rgba(8, 22, 38, 0));
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.site-header.is-scrolled::before { opacity: 1; transform: scaleY(0.81); }
.site-header.is-scrolled::after { opacity: 0; }

/* Without JavaScript the header cannot detect scroll, so it stays solid. main.js adds html.js. */
html:not(.js) .site-header::before { opacity: 1; }
html:not(.js) .site-header::after { opacity: 0; }

.header-inner {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--white);
  text-decoration: none;
  transform-origin: left center;
  transition: transform 0.35s var(--ease-out);
}

.brand-logo {
  width: 56px; height: 56px;
  object-fit: contain;
  padding: 3px;
  background: var(--cream-50);
  border-radius: 50%;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
}

.brand-name {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.25rem;
  line-height: 1;
}
.brand-name span {
  display: block;
  margin-top: 3px;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brand-100);
}

/* Shrink: 84px bar scales to 68px, contents move up 8px and the logo scales down. */
.site-header.is-scrolled .brand { transform: translateY(-8px) scale(0.86); }
.site-header.is-scrolled .nav-toggle { transform: translateY(-8px); }

.nav-link {
  position: relative;
  display: inline-block;
  padding: 0.5rem 0;
  color: inherit;
  font-weight: 500;
  text-decoration: none;
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 2px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s var(--ease-out);
}
.nav-link.is-active::after,
.nav-link[aria-current="true"]::after { transform: scaleX(1); }
@media (hover: hover) { .nav-link:hover::after { transform: scaleX(1); } }

.site-header :focus-visible { outline-color: var(--cream-50); }

/* Hamburger */
.nav-toggle {
  position: relative;
  z-index: 3;
  display: inline-grid;
  place-items: center;
  width: 48px; height: 48px;
  margin-right: -8px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--white);
  cursor: pointer;
  transition: transform 0.35s var(--ease-out);
}
.nav-toggle-bar,
.nav-toggle-bar::before,
.nav-toggle-bar::after {
  display: block;
  width: 24px; height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 0.35s var(--ease-out), opacity 0.2s ease;
}
.nav-toggle-bar { position: relative; }
.nav-toggle-bar::before,
.nav-toggle-bar::after { content: ""; position: absolute; left: 0; }
.nav-toggle-bar::before { transform: translateY(-7px); }
.nav-toggle-bar::after  { transform: translateY(7px); }

.nav-open .nav-toggle-bar { background: transparent; }
.nav-open .nav-toggle-bar::before { transform: rotate(45deg); background: var(--white); }
.nav-open .nav-toggle-bar::after  { transform: rotate(-45deg); background: var(--white); }

/* Mobile and tablet: off-canvas panel */
@media (max-width: 1179.98px) {
  .site-nav {
    position: fixed;
    top: 0; right: 0;
    z-index: 2;
    width: min(86vw, 360px);
    height: 100vh;
    height: 100dvh;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    padding: calc(var(--header-h) + 1rem) 2rem 2rem;
    background: var(--brand-900);
    box-shadow: -12px 0 40px rgba(0, 0, 0, 0.25);
    overflow-y: auto;
    transform: translateX(100%);
    visibility: hidden;
    transition: transform 0.45s var(--ease-out), visibility 0s linear 0.45s;
  }
  .nav-open .site-nav {
    transform: translateX(0);
    visibility: visible;
    transition: transform 0.45s var(--ease-out), visibility 0s;
  }
  .nav-list { display: flex; flex-direction: column; gap: 0.25rem; }
  .nav-link { font-family: var(--font-head); font-size: 1.625rem; font-weight: 600; padding: 0.4rem 0; }
  .nav-cta { align-self: flex-start; }

  .nav-overlay {
    position: fixed;
    inset: 0;
    z-index: 1;
    background: rgba(6, 18, 32, 0.55);
    opacity: 0;
    transition: opacity 0.35s ease;
  }
  .nav-open .nav-overlay { opacity: 1; }
}

@media (max-width: 479.98px) {
  .brand-name { font-size: 1.0625rem; }
  .brand-logo { width: 48px; height: 48px; }
}

/* Desktop: inline nav */
@media (min-width: 1180px) {
  .nav-toggle, .nav-overlay { display: none !important; }
  .site-nav {
    display: flex;
    align-items: center;
    gap: 2rem;
    transition: transform 0.35s var(--ease-out);
  }
  .nav-list { display: flex; gap: 1.75rem; }
  .nav-link { font-size: 0.975rem; }
  .nav-cta { min-height: 44px; padding: 0.55rem 1.25rem; font-size: 0.9375rem; }
  .site-header.is-scrolled .site-nav { transform: translateY(-8px); }
}

html.nav-open { overflow: hidden; }

/* 6. Hero ------------------------------------------------------------------ */
.hero {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: center;
  padding-block: calc(var(--header-h) + clamp(2rem, 5vw, 3.5rem)) clamp(4.5rem, 9vw, 6.5rem);
  overflow: hidden;
  color: var(--white);
  background: var(--brand-900);
}

/* Full-bleed photo behind the hero, darkened so white text stays above 4.5:1. */
.hero-media {
  position: absolute;
  inset: 0;
  z-index: -2;
}
.hero-media img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 60%;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(to right, rgba(9, 26, 43, 0.9) 0%, rgba(9, 26, 43, 0.72) 50%, rgba(9, 26, 43, 0.45) 100%),
    linear-gradient(to top, rgba(9, 26, 43, 0.6), rgba(9, 26, 43, 0) 40%);
}
@media (max-width: 959.98px) {
  .hero::after { background: rgba(9, 26, 43, 0.8); }
}

.hero-grid {
  display: grid;
  gap: clamp(3rem, 6vw, 4.5rem);
  align-items: center;
}

@media (min-width: 960px) {
  .hero { min-height: min(100vh, 880px); min-height: min(100svh, 880px); }
  .hero-grid { grid-template-columns: 1.05fr 1fr; }
}

.hero-slogan {
  font-family: var(--font-accent);
  font-style: italic;
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--brand-100);
  margin-bottom: 1rem;
}
.hero-slogan span { margin-inline: 0.35em; opacity: 0.7; }

.hero h1 {
  font-size: clamp(2.6rem, 6vw, 4.6rem);
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: -0.015em;
  margin-bottom: 1.25rem;
}

.hero-line {
  text-wrap: pretty;
  font-size: clamp(1.0625rem, 1.6vw, 1.25rem);
  color: var(--cream-50);
  margin-bottom: 2.25rem;
}

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

.hero-visual {
  position: relative;
  max-width: 600px;
  margin-bottom: 2.5rem;
}
@media (min-width: 960px) { .hero-visual { justify-self: end; width: 100%; margin-bottom: 0; } }

.hero-frame {
  aspect-ratio: 5 / 4;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--brand-700);
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.35);
}
.hero-frame img { width: 100%; height: 100%; object-fit: cover; object-position: 45% center; }

.hero-inset {
  position: absolute;
  left: clamp(-3rem, -4vw, -1rem);
  bottom: -2.5rem;
  width: 46%;
  aspect-ratio: 5 / 3;
  overflow: hidden;
  border: 5px solid var(--cream-50);
  border-radius: var(--radius);
  background: var(--brand-700);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
}
.hero-inset img { width: 100%; height: 100%; object-fit: cover; }

@media (max-width: 959.98px) {
  .hero-inset { left: auto; right: -0.5rem; width: 50%; }
}

/* 7. About ----------------------------------------------------------------- */
.split {
  display: grid;
  gap: clamp(2.5rem, 5vw, 4.5rem);
  align-items: center;
}
.split-text h2 { margin-bottom: 1.5rem; }
.split-text p { color: var(--ink-soft); max-width: 60ch; }
.split-media { aspect-ratio: 4 / 3; box-shadow: var(--shadow); }

@media (min-width: 900px) {
  .split { grid-template-columns: 1.05fr 1fr; }
}

.values {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
}
.split + .values,
.split + h3 + .values { margin-top: clamp(3.5rem, 7vw, 5rem); }
.value-card { padding: 1.75rem; }
.value-card .icon,
.offer .icon {
  box-sizing: content-box;
  width: 26px; height: 26px;
  padding: 13px;
  margin-bottom: 1.25rem;
  border-radius: 50%;
  background: var(--brand-100);
  color: var(--accent-700);
}
.value-card h4 { font-size: 1.3rem; font-weight: 600; color: var(--brand-700); margin-bottom: 0.5rem; }
.value-card p { font-size: 0.975rem; color: var(--ink-soft); }

/* 8. Products ------------------------------------------------------------- */
.offer-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr));
}
.offer { padding: 1.75rem 1.5rem; }
.offer .icon { background: var(--cream-50); }
.offer h3 { font-size: 1.3rem; font-weight: 600; color: var(--brand-700); margin-bottom: 0.4rem; }
.offer p { font-size: 0.975rem; color: var(--ink-soft); }

/* 9. How to order --------------------------------------------------------- */
.product-grid {
  display: grid;
  gap: 1.5rem;
}
@media (min-width: 768px) { .product-grid { grid-template-columns: 1fr 1fr; } }

/* Equal-height cards with the button pinned to the bottom, so the two calls to action line up. */
.product {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: clamp(1.75rem, 4vw, 2.5rem);
}
.product .btn { margin-top: auto; }
.product h3 { font-size: clamp(1.625rem, 3vw, 2rem); font-weight: 700; color: var(--brand-700); margin: 1rem 0 1rem; }

.badge {
  display: inline-block;
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.badge-live { background: var(--brand-700); color: var(--white); }
.badge-soft { background: var(--brand-100); color: var(--brand-900); }

.chips { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1.5rem; }
.chips li {
  padding: 0.35rem 0.9rem;
  border-radius: 999px;
  background: var(--brand-100);
  color: var(--brand-900);
  font-size: 0.9rem;
  font-weight: 500;
}

/* Three numbered steps under the order cards. */
.steps {
  display: grid;
  gap: 1.5rem;
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  padding-top: clamp(2.5rem, 5vw, 3.5rem);
  border-top: 1px solid var(--line);
}
@media (min-width: 768px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 2rem; } }

.step {
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: 1rem;
  align-items: start;
}
.step-num {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 52px; height: 52px;
  border-radius: 50%;
  background: var(--brand-100);
  color: var(--accent-700);
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.5rem;
  line-height: 1;
}
.step h3 { font-size: 1.3rem; font-weight: 600; color: var(--brand-700); margin: 0.2rem 0 0.35rem; }
.step p { font-size: 0.975rem; color: var(--ink-soft); }

/* The stand-in mark is an SVG drop: give it a little more breathing room than a raster logo. */
.brand-logo { padding: 7px; }
.footer-logo { padding: 12px; }

/* 10. Contact -------------------------------------------------------------- */
.contact-grid {
  display: grid;
  gap: 2.5rem;
}
@media (min-width: 960px) { .contact-grid { grid-template-columns: 1fr 1.25fr; gap: 3.5rem; } }

.contact-info h3,
.contact-card h3 { font-size: 1.3rem; font-weight: 600; color: var(--brand-700); }
.contact-info h3 { margin-bottom: 0.75rem; }
.contact-info address { font-size: 1.0625rem; margin-bottom: 1.5rem; }

.contact-meta { margin: 0 0 2rem; display: grid; gap: 0.9rem; }
.contact-meta div { display: grid; gap: 0.1rem; }
.contact-meta dt {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.contact-meta dd { margin: 0; }

.contact-cards {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
  align-content: start;
}
.contact-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.25rem;
  padding: 1.5rem;
}
.person-role { font-size: 0.9375rem; color: var(--ink-soft); margin: 0; }
.contact-card .person-role { margin-bottom: 0.6rem; }
.contact-link {
  font-weight: 600;
  font-size: 1.0625rem;
  text-decoration: none;
  overflow-wrap: break-word;
  margin-bottom: 0.75rem;
}
.contact-link:hover { text-decoration: underline; }

/* 11. Footer --------------------------------------------------------------- */
.site-footer {
  background: var(--brand-900);
  color: var(--brand-100);
  padding-top: clamp(3.5rem, 7vw, 5rem);
}
.site-footer a { color: var(--brand-100); text-decoration: none; }
.site-footer a:hover { color: var(--white); text-decoration: underline; }
.site-footer :focus-visible { outline-color: var(--cream-50); }

.footer-grid {
  display: grid;
  gap: 2.5rem;
  padding-bottom: 3rem;
}
@media (min-width: 640px)  { .footer-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1.2fr 1.2fr; } }

.footer-logo {
  width: 96px; height: 96px;
  object-fit: contain;
  padding: 5px;
  background: var(--cream-50);
  border-radius: 50%;
  margin-bottom: 1.25rem;
}
.footer-slogan {
  font-family: var(--font-accent);
  font-style: italic;
  font-size: 1.0625rem;
  max-width: 26ch;
}
.footer-title {
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 1rem;
}
.footer-col ul { display: grid; gap: 0.6rem; }
.footer-col li a { overflow-wrap: break-word; }
.footer-col address { max-width: 30ch; }

.footer-bottom { font-size: 0.9rem; }
.footer-bottom p {
  padding-block: 1.5rem;
  border-top: 1px solid rgba(228, 238, 246, 0.15);
}

/* 12. Floating WhatsApp ---------------------------------------------------- */
.whatsapp-float {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 40;
  display: grid;
  place-items: center;
  width: 58px; height: 58px;
  border-radius: 50%;
  background: var(--brand-700);
  color: var(--white);
  box-shadow: 0 8px 24px rgba(15, 42, 68, 0.35);
  transition: transform 0.3s var(--ease-out), background-color 0.25s ease;
}
.whatsapp-float svg { width: 30px; height: 30px; fill: currentColor; }
@media (hover: hover) {
  .whatsapp-float:hover { transform: translateY(-3px) scale(1.05); background: var(--brand-900); }
}
.nav-open .whatsapp-float { opacity: 0; pointer-events: none; }

/* 13. Motion ---------------------------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.8s var(--ease-out);
  transition-delay: var(--reveal-delay, 0ms);
}
.reveal.is-visible { opacity: 1; transform: none; }
.card.reveal.is-visible {
  transition: opacity 0.7s ease var(--reveal-delay, 0ms), transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}

/* Hero entrance: staggered fade-up; slow Ken Burns zoom on the background photo. */
.js .hero-content > *,
.js .hero-visual { animation: hero-up 0.9s var(--ease-out) both; }
.js .hero-content > :nth-child(2) { animation-delay: 0.08s; }
.js .hero-content > :nth-child(3) { animation-delay: 0.16s; }
.js .hero-content > :nth-child(4) { animation-delay: 0.24s; }
.js .hero-visual { animation-delay: 0.3s; }
.hero-media img { animation: ken-burns 24s ease-out both; transform-origin: 60% 50%; }

@keyframes hero-up { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: none; } }
@keyframes ken-burns { from { transform: scale(1.12); } to { transform: scale(1); } }

/* 14. Reduced motion -------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
