/* ==========================================================
   Samskriya Foundation – Gallery
   Brand tokens match samskriyafoundation.org (Avada theme)
   ========================================================== */
:root {
  --green: #6dbe45;
  --green-dark: #4f9a2c;
  --lime: #b8d432;
  --ink: #333333;
  --muted: #666666;
  --bg: #ffffff;
  --bg-soft: #f9f9fb;
  --bg-alt: #f2f3f5;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(16, 24, 40, 0.08);
  --font: "Karla", Arial, Helvetica, sans-serif;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
body.no-scroll { overflow: hidden; }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h4 { line-height: 1.2; margin: 0; }

.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
}

.btn {
  display: inline-block;
  padding: 12px 26px;
  border-radius: 999px;
  font-weight: 700;
  transition: background .25s, color .25s, transform .25s;
}
.btn:hover { transform: translateY(-2px); }

/* ---------- Header (samskriyafoundation.org) ---------- */
.site-header { --navy: #112a34; }
.site-header .container { max-width: none; padding-left: 48px; padding-right: 48px; }
.site-footer .container { max-width: 1440px; padding: 0 30px; }

.top-bar { background: var(--green); color: #fff; font-size: 16px; }
.top-bar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 48px;
}
.top-contact strong { font-weight: 600; }
.top-social { display: flex; gap: 22px; }
.top-social a { display: grid; place-items: center; transition: opacity .2s; }
.top-social a:hover { opacity: .8; }
.top-social svg { width: 20px; height: 20px; fill: #fff; }

.main-header { background: var(--navy); }
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 103px;
}
.logo img { height: auto; }
.logo-desktop { width: 350px; }
.logo-mobile { display: none; width: 250px; }

.main-nav > ul { display: flex; align-items: center; margin: 0; padding: 0; list-style: none; }
.main-nav li { position: relative; list-style: none; }
.main-nav > ul > li + li { margin-left: 38px; }
.main-nav > ul > li > a {
  display: flex;
  align-items: center;
  height: 103px;
  position: relative;
  color: #fff;
  font-size: 18px;
  font-weight: 500;
  letter-spacing: .015em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color .2s;
}
.main-nav > ul > li > a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 26px;
  height: 6px;
  background: var(--green);
  opacity: 0;
  transition: opacity .2s;
}
.main-nav > ul > li:hover > a,
.main-nav > ul > li.current > a { color: var(--green); }
.main-nav > ul > li:hover > a::after,
.main-nav > ul > li.current > a::after { opacity: 1; }

.main-nav .nav-button > a {
  height: auto;
  padding: 13px 29px;
  background: var(--green);
  color: #fff;
}
.main-nav .nav-button > a::after { display: none; }
.main-nav .nav-button:hover > a { background: var(--lime); color: #fff; }

.sub-menu {
  position: absolute;
  top: 100%; left: 0;
  z-index: 10;
  width: 200px;
  margin: 0;
  padding: 0;
  background: #fff;
  border-top: 3px solid var(--green);
  box-shadow: 0 4px 12px rgba(0, 0, 0, .1);
  visibility: hidden;
  opacity: 0;
  transition: opacity .2s ease-in;
}
.main-nav li:hover > .sub-menu,
.main-nav li:focus-within > .sub-menu { visibility: visible; opacity: 1; }
.sub-menu a {
  display: block;
  padding: 7px 20px;
  line-height: 19px;
  font-size: 16px;
  color: #000;
  border-bottom: 1px solid var(--bg-alt);
  transition: background-color .2s, color .2s;
}
.sub-menu li:last-child a { border-bottom: 0; }
.sub-menu a:hover { background: var(--bg-alt); color: var(--green); }

.nav-toggle { display: none; }
.nav-burger { display: none; cursor: pointer; width: 30px; height: 24px; position: relative; }
.nav-burger span,
.nav-burger span::before,
.nav-burger span::after {
  position: absolute;
  left: 0;
  width: 100%; height: 3px;
  background: var(--lime);
  transition: transform .25s, opacity .25s;
}
.nav-burger span { top: 50%; transform: translateY(-50%); }
.nav-burger span::before { content: ""; top: -9px; }
.nav-burger span::after  { content: ""; top: 9px; }

/* ---------- Cover ---------- */
.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: min(78vh, 680px);
  padding: 90px 0 110px;
  overflow: hidden;
  background: #0f2a1f;
  color: #fff;
  isolation: isolate;
}
/* Tilted photo collage drifting slowly behind the text */
.hero-mosaic {
  position: absolute;
  inset: -30% -20%;
  z-index: -2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
  transform: rotate(-8deg);
}
.hero-row {
  display: flex;
  gap: 16px;
  width: max-content;
  animation: heroDrift 90s linear infinite;
}
.hero-row:nth-child(2) { animation-direction: reverse; animation-duration: 110s; }
.hero-row:nth-child(3) { animation-duration: 75s; }
.hero-row img {
  width: 260px;
  height: 195px;
  object-fit: cover;
  border-radius: 14px;
}
/* Deep green wash keeps the text readable over the photos */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse at 15% 50%, rgba(15, 42, 31, .96) 0%, rgba(15, 42, 31, .78) 45%, rgba(15, 42, 31, .3) 100%),
    linear-gradient(180deg, rgba(79, 154, 44, .25), rgba(15, 42, 31, .6));
}
/* Soft curve into the gallery below */
.hero::after {
  content: "";
  position: absolute;
  left: -5%; right: -5%; bottom: -1px;
  height: 70px;
  background: var(--bg-soft);
  border-radius: 50% 50% 0 0 / 100% 100% 0 0;
}
.hero-content { position: relative; animation: fadeIn .8s ease both; }
.hero-eyebrow {
  display: inline-block;
  margin: 0 0 18px;
  padding: 6px 16px;
  border: 1px solid rgba(184, 212, 50, .6);
  border-radius: 999px;
  color: var(--lime);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.hero-title {
  max-width: 900px;
  margin: 0 0 18px;
  font-size: clamp(36px, 6vw, 64px);
  font-weight: 800;
  line-height: 1.08;
}
.hero-title em {
  font-style: normal;
  color: var(--lime);
}
.hero-lead {
  max-width: 560px;
  margin: 0 0 34px;
  color: rgba(255, 255, 255, .85);
  font-size: clamp(17px, 2vw, 20px);
}
.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 40px;
  margin: 0 0 38px;
  padding: 0;
  list-style: none;
}
.hero-stats li { display: flex; flex-direction: column; }
.hero-stats strong { font-size: clamp(30px, 4vw, 40px); font-weight: 800; line-height: 1; }
.hero-stats span {
  margin-top: 6px;
  color: rgba(255, 255, 255, .7);
  font-size: 13px;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: 999px;
  background: var(--green);
  color: #fff;
  font-weight: 700;
  box-shadow: 0 10px 30px rgba(109, 190, 69, .35);
  transition: background .2s, transform .2s;
}
.hero-cta:hover { background: var(--green-dark); transform: translateY(-2px); }
.hero-cta:focus-visible { outline: 3px solid var(--lime); outline-offset: 3px; }
.hero-cta span { animation: heroBounce 1.8s ease-in-out infinite; }

@keyframes heroDrift { to { transform: translateX(-50%); } }
@keyframes heroBounce { 50% { transform: translateY(4px); } }

/* ---------- Gallery ---------- */
.gallery-section { background: var(--bg-soft); padding: 30px 0 90px; }
.filters { scroll-margin-top: 24px; }

.filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-bottom: 40px;
}
.filter {
  font: inherit;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: 10px 20px;
  border-radius: 999px;
  border: 2px solid var(--green);
  background: transparent;
  color: var(--green-dark);
  cursor: pointer;
  transition: background .2s, color .2s;
}
.filter:hover { background: rgba(109, 190, 69, .12); }
.filter.active { background: var(--green); color: #fff; }
.filter:focus-visible,
.item:focus-visible { outline: 3px solid var(--lime); outline-offset: 3px; }

/* Year groups */
.year-group { margin-bottom: 64px; }
.year-group:last-child { margin-bottom: 0; }
.year-group[hidden] { display: none; }
.year-heading {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 26px;
  font-size: clamp(30px, 4vw, 42px);
  font-weight: 800;
  color: var(--ink);
}
.year-heading span {
  position: relative;
  padding-left: 22px;
}
.year-heading span::before {
  content: "";
  position: absolute;
  left: 0; top: 50%;
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 5px rgba(109, 190, 69, .2);
  transform: translateY(-50%);
}
.year-heading::after {
  content: "";
  flex: 1;
  height: 2px;
  background: linear-gradient(90deg, var(--green), rgba(184, 212, 50, 0));
}

/* Uniform grid: every card the same size, photos in reading order */
.gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.item {
  position: relative;
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-alt);
  box-shadow: var(--shadow);
  cursor: zoom-in;
  animation: fadeIn .45s ease both;
}
.item[hidden] { display: none; }
.item img {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform .6s cubic-bezier(.2, .7, .2, 1);
}
.item figcaption {
  position: absolute;
  inset: auto 0 0 0;
  padding: 40px 18px 16px;
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  background: linear-gradient(to top, rgba(0, 0, 0, .78), transparent);
  opacity: 0;
  transform: translateY(12px);
  transition: opacity .35s, transform .35s;
}
.tag {
  display: block;
  margin-bottom: 4px;
  color: var(--lime);
  font-size: 12px;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.item:hover img,
.item:focus-visible img { transform: scale(1.06); }
.item:hover figcaption,
.item:focus-visible figcaption { opacity: 1; transform: none; }

/* "Click to zoom" hint on hover */
.item::after {
  content: "⤢  Click to zoom";
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  padding: 6px 12px;
  border-radius: 999px;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  background: rgba(0, 0, 0, .65);
  pointer-events: none;
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity .25s, transform .25s;
}
.item:hover::after,
.item:focus-visible::after { opacity: 1; transform: none; }
@media (hover: none) {
  .item::after { display: none; }
}

/* Divisions with school/title details: caption always visible below the photo */
.item[data-cat="read-a-way-library"],
.item[data-cat="steps-to-success"],
.item[data-cat="strive-women-empowerment"],
.item[data-cat="exhibition-and-competitions"],
.item[data-cat="stem-lab"],
.item[data-cat="stem-lab-in-a-backpack"] { background: var(--bg); }
.item[data-cat="read-a-way-library"] figcaption,
.item[data-cat="steps-to-success"] figcaption,
.item[data-cat="strive-women-empowerment"] figcaption,
.item[data-cat="exhibition-and-competitions"] figcaption,
.item[data-cat="stem-lab"] figcaption,
.item[data-cat="stem-lab-in-a-backpack"] figcaption {
  position: relative;
  display: block;
  padding: 14px 16px 16px;
  color: var(--ink);
  font-size: 15px;
  background: var(--bg);
  opacity: 1;
  transform: none;
}
.item[data-cat="read-a-way-library"] .tag,
.item[data-cat="steps-to-success"] .tag,
.item[data-cat="strive-women-empowerment"] .tag,
.item[data-cat="exhibition-and-competitions"] .tag,
.item[data-cat="stem-lab"] .tag,
.item[data-cat="stem-lab-in-a-backpack"] .tag { color: var(--green-dark); }
/* Keep each program name's own casing (not all capitals) */
.filter[data-filter="read-a-way-library"],
.item[data-cat="read-a-way-library"] .tag,
.lb-figure figcaption[data-cat="read-a-way-library"] .tag,
.filter[data-filter="steps-to-success"],
.filter[data-filter="strive-women-empowerment"],
.item[data-cat="strive-women-empowerment"] .tag,
.filter[data-filter="exhibition-and-competitions"],
.item[data-cat="exhibition-and-competitions"] .tag,
.item[data-cat="steps-to-success"] .tag,
.lb-figure figcaption[data-cat="steps-to-success"] .tag,
.lb-figure figcaption[data-cat="strive-women-empowerment"] .tag,
.lb-figure figcaption[data-cat="exhibition-and-competitions"] .tag,
.filter[data-filter="stem-lab"],
.item[data-cat="stem-lab"] .tag,
.lb-figure figcaption[data-cat="stem-lab"] .tag,
.filter[data-filter="stem-lab-in-a-backpack"],
.item[data-cat="stem-lab-in-a-backpack"] .tag,
.lb-figure figcaption[data-cat="stem-lab-in-a-backpack"] .tag { text-transform: none; }

/* Inside one division the category label is the same on every photo, so hide it */
body[data-filter]:not([data-filter="all"]) .tag { display: none; }

/* Division banner, shown above the photos while that filter is selected */
.cat-banner { margin: 0 0 40px; }
.cat-banner img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 14px;
}
/* Photo banner with the division name written over it */
.cat-banner.has-text {
  position: relative;
  overflow: hidden;
  border-radius: 14px;
}
.cat-banner.has-text img {
  aspect-ratio: 8 / 3;
  object-fit: cover;
  object-position: center 40%;
  border-radius: 0;
}
.cat-banner.has-text::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(15, 42, 31, .88) 0%, rgba(15, 42, 31, .55) 40%, rgba(15, 42, 31, 0) 70%);
}
.cat-banner figcaption {
  position: absolute;
  left: clamp(20px, 5vw, 56px);
  top: 50%;
  z-index: 1;
  max-width: 46%;
  color: #fff;
  transform: translateY(-50%);
}
.cat-banner-title {
  display: block;
  margin-bottom: 10px;
  font-size: clamp(26px, 4.4vw, 52px);
  font-weight: 800;
  line-height: 1.05;
}
.cat-banner-title::after {
  content: "";
  display: block;
  width: 64px;
  height: 4px;
  margin-top: 14px;
  border-radius: 2px;
  background: var(--lime);
}
.cat-banner-text {
  display: block;
  color: rgba(255, 255, 255, .88);
  font-size: clamp(14px, 1.7vw, 19px);
  line-height: 1.45;
}
.item[data-cat="read-a-way-library"] .school,
.item[data-cat="steps-to-success"] .school,
.item[data-cat="strive-women-empowerment"] .school,
.item[data-cat="exhibition-and-competitions"] .school,
.item[data-cat="stem-lab"] .school,
.item[data-cat="stem-lab-in-a-backpack"] .school { display: block; font-weight: 800; line-height: 1.3; }
.item[data-cat="read-a-way-library"] .desc,
.item[data-cat="steps-to-success"] .desc,
.item[data-cat="strive-women-empowerment"] .desc,
.item[data-cat="exhibition-and-competitions"] .desc,
.item[data-cat="stem-lab"] .desc,
.item[data-cat="stem-lab-in-a-backpack"] .desc {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.5;
}

.empty { text-align: center; color: var(--muted); }

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: none; }
}

/* ---------- CTA ---------- */
.cta { background: linear-gradient(110deg, var(--green), var(--lime)); color: #fff; padding: 60px 0; }
.cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 30px; }
.cta h2 { font-size: clamp(24px, 3vw, 34px); font-weight: 800; max-width: 640px; }
.cta p { margin: 10px 0 0; opacity: .95; }
.btn-light { background: #fff; color: var(--green-dark); white-space: nowrap; }
.btn-light:hover { background: var(--ink); color: #fff; }

/* ---------- Footer (samskriyafoundation.org) ---------- */
.site-footer { font-size: 16px; }
.footer-widgets {
  background: #e8e8e8;
  border-top: 6px solid #f16022;
  color: #333;
  padding: 60px 0 64px;
}
.footer-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}
.site-footer h4 {
  margin: 0 0 20px;
  color: #112a34;
  font-size: 32px;
  font-weight: 800;
  line-height: 1.1;
  text-transform: uppercase;
}
.site-footer p { margin: 0 0 16px; }
.site-footer a { transition: color .2s; }
.site-footer a:hover { color: var(--muted); }
.footer-about-img { width: 100%; max-width: 400px; height: auto; margin: 0 auto 16px; }

.btn-more {
  display: inline-block;
  padding: 7px 18px;
  background: var(--green);
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  text-transform: uppercase;
  transition: background .2s;
}
.site-footer .btn-more:hover { background: var(--lime); color: #fff; }

.footer-menu { list-style: none; margin: 0; padding: 0; }
.footer-menu li { border-bottom: 1px solid var(--muted); }
.footer-menu li:first-child a { padding-top: 0; }
.footer-menu a { display: block; padding: 12px 0 12px 14px; position: relative; }
.footer-menu a::before {
  content: "\203A";
  position: absolute;
  left: 0;
}

.footer-contact { text-align: center; }
.footer-contact p { text-align: left; }
.footer-logo { width: 100%; max-width: 400px; height: auto; margin: 0 auto 16px; }
.phone-indent { padding-left: 88px; }
.footer-contact p + h4 { margin-top: 28px; }

.footer-social { display: flex; justify-content: center; gap: 10px; }
.footer-social a { display: grid; place-items: center; padding: 8px; color: #fff; }
.footer-social svg { width: 24px; height: 24px; fill: #fff; }
.footer-social .s-fb { background: #3b5998; }
.footer-social .s-ig { background: #3f729b; }
.footer-social .s-li { background: #0077b5; }
.footer-social .s-yt { background: #cd201f; }
.footer-social a:hover { opacity: .85; }

.copyright {
  background: #112a34;
  color: rgba(255, 255, 255, .8);
  padding: 10px 0;
  font-size: 15px;
  text-align: center;
}
.copyright strong { color: #fff; font-weight: 600; }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 80px;
  background: rgba(10, 14, 8, .94);
  animation: fadeIn .25s ease;
}
.lightbox[hidden] { display: none; }
.lb-figure { margin: 0; width: fit-content; max-width: 1100px; text-align: center; }
.lb-figure img {
  max-height: 78vh;
  max-width: min(1100px, calc(100vw - 160px));
  width: auto;
  margin: 0 auto;
  border-radius: 10px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, .5);
}
.lb-figure figcaption { margin-top: 16px; color: #fff; font-weight: 700; font-size: 18px; }
.item .desc { display: none; }

/* School name + description box */
.lb-figure figcaption.has-details {
  margin: 18px 0 0;
  padding: 18px 24px;
  text-align: left;
  background: #1c2318;
  border-left: 5px solid var(--green);
  border-radius: 0 10px 10px 0;
}
.has-details .school { display: block; font-size: 22px; font-weight: 800; line-height: 1.25; }
.has-details .desc {
  display: block;
  margin-top: 6px;
  color: #d5dccf;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.6;
}
.lb-close,
.lb-nav {
  position: absolute;
  border: 0;
  cursor: pointer;
  color: #fff;
  background: rgba(255, 255, 255, .1);
  border-radius: 50%;
  display: grid;
  place-items: center;
  transition: background .2s;
}
.lb-close:hover,
.lb-nav:hover { background: var(--green); }
.lb-close { top: 20px; right: 24px; width: 46px; height: 46px; font-size: 30px; line-height: 1; }
.lb-nav { top: 50%; transform: translateY(-50%); width: 52px; height: 52px; font-size: 20px; }
.lb-prev { left: 20px; }
.lb-next { right: 20px; }
.lb-count { position: absolute; top: 30px; left: 30px; color: #c9d1c2; font-weight: 600; font-size: 15px; }

/* ---------- Responsive ---------- */
@media (max-width: 1200px) {
  .top-bar-inner { flex-direction: column; justify-content: center; gap: 6px; padding: 8px 0; text-align: center; }
  .header-inner { position: relative; min-height: 0; padding-top: 14px; padding-bottom: 14px; }
  .logo-desktop { display: none; }
  .logo-mobile { display: block; }
  .nav-burger { display: block; }
  .main-nav {
    position: absolute;
    top: 100%; left: 0; right: 0;
    z-index: 40;
    background: #fff;
    max-height: 0;
    overflow: hidden;
    visibility: hidden;
    transition: max-height .35s, visibility .35s;
  }
  .nav-toggle:checked ~ .main-nav { max-height: 80vh; overflow-y: auto; visibility: visible; }
  .nav-toggle:checked + .nav-burger span { background: transparent; }
  .nav-toggle:checked + .nav-burger span::before { transform: translateY(9px) rotate(45deg); }
  .nav-toggle:checked + .nav-burger span::after  { transform: translateY(-9px) rotate(-45deg); }
  .main-nav > ul { flex-direction: column; align-items: stretch; }
  .main-nav > ul > li + li { margin-left: 0; }
  .main-nav > ul > li > a,
  .main-nav .nav-button > a {
    justify-content: center;
    height: auto;
    min-height: 42px;
    padding: 8px 16px;
    background: #fff;
    color: #000;
    font-size: 24px;
    text-transform: none;
    border-bottom: 1px solid var(--bg-alt);
  }
  .main-nav > ul > li > a::after { display: none; }
  .main-nav > ul > li:hover > a,
  .main-nav > ul > li.current > a,
  .main-nav .nav-button:hover > a { background: #fff; color: var(--muted); }
  .sub-menu { position: static; width: auto; border-top: 0; box-shadow: none; visibility: visible; opacity: 1; }
  .sub-menu a { text-align: center; padding: 10px 16px; font-size: 18px; border-bottom: 1px solid var(--bg-alt); }
  .sub-menu li:last-child a { border-bottom: 1px solid var(--bg-alt); }
}

@media (max-width: 1100px) {
  .gallery { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 960px) {
  .cta-inner { flex-direction: column; text-align: center; }
}

@media (max-width: 800px) {
  .footer-grid { grid-template-columns: 1fr; gap: 40px; }
}

@media (max-width: 640px) {
  .container { padding: 0 16px; }
  .logo-mobile { width: 200px; }
  .site-header .container,
  .site-footer .container { padding-left: 16px; padding-right: 16px; }
  .gallery { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .item { border-radius: 10px; }
  .item figcaption { display: none; }
  .filter { padding: 8px 14px; font-size: 12px; }
  .hero { min-height: 0; padding: 60px 0 90px; }
  .hero-row img { width: 180px; height: 135px; }
  .hero::after { height: 40px; }
  .cat-banner.has-text img { aspect-ratio: 16 / 9; }
  .cat-banner figcaption { max-width: 70%; }
  .year-group { margin-bottom: 44px; }
  .year-heading { margin-bottom: 16px; }
  .lightbox { padding: 70px 12px; }
  .lb-figure img { max-width: calc(100vw - 24px); }
  .lb-nav { top: auto; bottom: 18px; transform: none; width: 46px; height: 46px; }
  .lb-prev { left: calc(50% - 56px); }
  .lb-next { right: calc(50% - 56px); }
}

@media (max-width: 380px) {
  .gallery { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
