:root {
  --bg: #fdfdfc;
  --card: #ffffff;
  --green: #0a7a3a;
  --muted: #4a5568;
  --radius: 16px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  background:
    linear-gradient(180deg, rgba(10, 40, 20, 0.02), rgba(255, 255, 255, 0.02)),
    radial-gradient(800px 400px at 10% 10%, rgba(10, 122, 58, 0.03), transparent 10%),
    var(--bg);
  color: #0f1b1a;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.45;
  padding-bottom: 0;
}

.wrap {
  max-width: var(--site-wrap-max);
  margin: 0 auto;
  padding: 20px;
}

main {
  margin-top: 12px;
}

h1,
h2,
h3 {
  margin: 0 0 8px;
  font-weight: 700;
  line-height: 1.2;
  color: #0f1b1a;
  letter-spacing: -0.03em;
}

h1 {
  font-size: 34px;
  color: #ffffff;
}

h2 {
  font-size: 22px;
  color: var(--green);
}

h3 {
  font-size: 18px;
}

p {
  margin: 4px 0 10px;
  font-size: 16px;
  line-height: 1.6;
  color: var(--muted);
}

.section {
  margin-bottom: 32px;
}

.surface {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  border: 2px solid rgba(9, 9, 9, 0.02);
  border-top: 3px solid rgba(184, 134, 11, 0.2);
  box-shadow: 0 18px 60px rgba(20, 30, 20, 0.04);
}

.hero-section {
  text-align: left;
  padding: 54px 48px 42px;
  min-height: 340px;
  border-radius: 22px;
  margin-bottom: 32px;
  color: #fdfdfc;
  text-shadow: 0 1px 0 rgba(0, 0, 0, 0.25);
  position: relative;
  overflow: hidden;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.hero-section p {
  color: #ffffff;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
  max-width: 720px;
  font-size: 17px;
  line-height: 1.55;
}

.badge-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  margin: 10px 0 8px;
}

.badge {
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #ffffff;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.18);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 20px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
  margin: 8px;
}

.btn-primary {
  background: linear-gradient(180deg, var(--green), #07602c);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(6, 80, 40, 0.15);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(6, 80, 40, 0.2);
}

.btn-secondary {
  background: linear-gradient(180deg, #ffffff, #f6f5f2);
  color: var(--muted);
  border-color: rgba(0, 0, 0, 0.06);
  box-shadow: 0 2px 8px rgba(10, 20, 10, 0.06);
}

.btn-secondary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(10, 20, 10, 0.1);
}

.hero-section .btn-secondary {
  background: linear-gradient(180deg, var(--green), #07602c);
  color: #ffffff;
  border-color: rgba(184, 134, 11, 0.2);
  box-shadow: 0 4px 12px rgba(6, 80, 40, 0.15);
}

.hero-section .btn-secondary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(6, 80, 40, 0.2);
}

.program-stat-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  max-width: 780px;
  margin: 18px 0 8px;
}

.program-stat {
  min-height: 78px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.14);
  backdrop-filter: blur(5px);
}

.program-stat strong,
.program-stat span {
  display: block;
}

.program-stat strong {
  color: #ffffff;
  font-size: 24px;
  line-height: 1.1;
  margin-bottom: 6px;
}

.program-stat span {
  color: rgba(255, 255, 255, 0.86);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
}

.program-profile-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 20px;
}

.program-profile-card {
  min-height: 150px;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid rgba(10, 20, 10, 0.08);
  background: linear-gradient(180deg, rgba(250, 252, 249, 0.96), #ffffff);
}

.program-profile-card span {
  display: block;
  margin-bottom: 7px;
  color: rgba(184, 134, 11, 0.96);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.program-profile-card p {
  margin: 0;
  font-size: 15px;
  line-height: 1.48;
}

#visit-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 0;
  margin: 18px 0 0;
  list-style: none;
  counter-reset: visit-step;
}

#visit-list li {
  position: relative;
  min-height: 122px;
  padding: 16px 16px 16px 58px;
  border-radius: 12px;
  border: 1px solid rgba(10, 20, 10, 0.08);
  background: #ffffff;
  color: var(--muted);
}

#visit-list li::before {
  counter-increment: visit-step;
  content: counter(visit-step);
  position: absolute;
  left: 16px;
  top: 16px;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(10, 122, 58, 0.1);
  color: var(--green);
  font-size: 14px;
  font-weight: 800;
}

.visit-step-title,
.visit-step-text {
  display: block;
}

.visit-step-title {
  margin-bottom: 6px;
  color: #10231b;
  font-size: 16px;
  font-weight: 800;
  line-height: 1.25;
}

.visit-step-text {
  font-size: 15px;
  line-height: 1.5;
}

.program-moment-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.program-moment-card {
  display: block;
  min-height: 220px;
  padding: 16px;
  border-radius: 12px;
  border: 1px solid rgba(10, 20, 10, 0.08);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(249, 251, 248, 0.98));
  text-decoration: none;
  color: inherit;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.program-moment-card:hover,
.program-moment-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(10, 122, 58, 0.22);
  box-shadow: 0 18px 38px rgba(10, 20, 10, 0.08);
}

.program-moment-meta {
  display: inline-flex;
  margin-bottom: 10px;
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(10, 122, 58, 0.08);
  color: #426050;
  font-size: 13px;
  font-weight: 700;
}

.program-moment-card h3 {
  color: var(--green);
  font-size: 17px;
  line-height: 1.25;
}

.program-moment-card p {
  margin-bottom: 0;
  font-size: 15px;
  line-height: 1.52;
}

.image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin: 24px 0;
}

.gallery-figure {
  margin: 0;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(10, 20, 10, 0.08);
  background: #ffffff;
  box-shadow: 0 4px 16px rgba(10, 20, 10, 0.08);
}

.gallery-figure img {
  width: 100%;
  height: 210px;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform 0.2s ease;
}

.gallery-figure:hover img {
  transform: scale(1.02);
}

.gallery-figure figcaption {
  min-height: 58px;
  padding: 10px 12px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.42;
}

.gallery-card {
  border-radius: 14px;
  border: 2px solid rgba(9, 9, 9, 0.02);
  border-top: 2px solid rgba(184, 134, 11, 0.2);
  padding: 16px;
}

.program-gallery-card {
  min-height: 268px;
  display: grid;
  align-content: center;
}

/* ── Embedded program gallery ─────────────────────────────────────────────── */

.prog-gallery-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: flex-start;
  margin-bottom: 12px;
  grid-column: 1 / -1;  /* span full width inside .image-grid's CSS grid */
}


.prog-gallery-card {
  position: relative;
  display: block;
  flex: none;
  overflow: hidden;
  border-radius: 10px;
  background: #edf3ed;
  text-decoration: none;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.10);
  transition: transform 0.20s ease, box-shadow 0.20s ease;
}

.prog-gallery-card:hover,
.prog-gallery-card:focus-visible {
  transform: translateY(-3px);
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.16);
}

.prog-gallery-card img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.prog-gallery-footer {
  text-align: right;
  margin-top: 4px;
  grid-column: 1 / -1;
}

.prog-gallery-all-link {
  color: var(--green, #0a7a3a);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

.prog-gallery-all-link:hover {
  text-decoration: underline;
}

.prog-gallery-loading,
.prog-gallery-empty {
  color: var(--muted, #4a5568);
  font-size: 15px;
  padding: 16px 0;
  margin: 0;
  grid-column: 1 / -1;
}

.program-impact-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding: 0;
  margin: 18px 0 8px;
  list-style: none;
}

.program-impact-list li {
  min-height: 108px;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid rgba(10, 122, 58, 0.1);
  background: rgba(10, 122, 58, 0.04);
  color: #263a31;
  font-size: 15px;
  line-height: 1.5;
}

footer {
  text-align: center;
  padding: 24px;
  border-top: 1px solid rgba(184, 134, 11, 0.25);
  color: var(--muted);
  font-size: 14px;
}

/* Desktop-only layout lock */
.wrap {
  width: 1200px;
  max-width: none;
  min-width: 1200px;
  padding: 20px;
}

main {
  margin-top: 12px;
}

h1 {
  font-size: 34px;
}

h2 {
  font-size: 22px;
}

.surface {
  padding: 24px;
}

.hero-section {
  padding: 54px 48px 42px;
  min-height: 420px;
  border-radius: 22px;
  margin-bottom: 32px;
}

.image-grid {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.gallery-card {
  padding: 16px;
  border-radius: 14px;
}

.btn {
  width: auto;
  margin: 8px;
}

footer {
  padding: 24px;
}

/* ── Hero: Ken Burns zoom ──────────────────────────────────── */

.hero-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: inherit;
  z-index: 0;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  will-change: transform;
  animation: heroZoom 26s ease-in-out infinite alternate;
}

@keyframes heroZoom {
  from { transform: scale(1.0) translate(0, 0); }
  to   { transform: scale(1.12) translate(-1.5%, 0.8%); }
}

/* Per-programme zoom origins — tuned to where each photo's subject sits */
body.program-page--vijnana-harate .hero-bg img {
  transform-origin: 48% 45%;   /* presenter + seated students, slight left */
}
body.program-page--vijnana-aranya .hero-bg img {
  transform-origin: 50% 58%;   /* outdoor circle, centred slightly low */
}
body.program-page--vijnana-yuvati .hero-bg img {
  transform-origin: 64% 50%;   /* instructor + buckets on the right */
}
body.program-page--vijnana-nataka .hero-bg img {
  transform-origin: 42% 38%;   /* main stage actors, centre-left */
}
body.program-page--ganitha-mela .hero-bg img {
  transform-origin: 40% 52%;   /* students around the floor activity */
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: inherit;
  pointer-events: none;
  background: linear-gradient(
    160deg,
    rgba(4, 16, 10, 0.68) 0%,
    rgba(6, 24, 14, 0.46) 100%
  );
}

.hero-content {
  position: relative;
  z-index: 2;
}

@media (prefers-reduced-motion: reduce) {
  .hero-bg img {
    animation: none;
  }
}
