/* =============================================================================
 * IEC page and section styles. Consumes tokens.css; logical properties for
 * RTL/LTR. Breakpoints: sm 640 / md 768 / lg 1024. Each component keeps its
 * phone and tablet rules next to its base rules.
 * ========================================================================== */

/* ---- Hero -------------------------------------------------------------------
   A photograph under a brand-green scrim; the copy anchors to the start edge.
   16:9 from 768px, the art-directed 4:5 crop below it. min-height, not height,
   so a long Arabic headline grows the section. */

/* Read by the navbar too (a sibling), so declared at the root. */
:root {
  --hero-gutter: clamp(1.5rem, 4.2vw, 5.5rem);
  --hero-measure: 1720px;
}

.hero-card-wrapper {
  width: 100%;
  padding-inline: clamp(0.75rem, 2.2vw, 2.5rem);
  padding-block-start: 0.5rem;
  padding-block-end: clamp(1.5rem, 3.5vw, 3rem);
}

/* The copy is placed by PROPORTION of the card, not by viewport maths: three
   rows — slack, copy, less slack. It used to be bottom-anchored and padded up by
   a slice of the viewport, so every disagreement about `svh` (Chrome vs an
   embedded preview, two window heights) moved the headline. Row 1 keeps a floor
   of the header height because the bar is fixed over this card. */
.hero {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-rows: minmax(var(--header-height), 1fr) auto minmax(0, 0.34fr);
  min-height: clamp(34rem, 88vh, 60rem);
  min-height: clamp(34rem, 88svh, 60rem);
  background: var(--color-green-900);
  color: var(--color-on-brand);
}

.hero--framed {
  margin: clamp(0.5rem, 1.6vw, 1.5rem);
  border-radius: clamp(20px, 3vw, 36px);
  box-shadow: 0 20px 50px -10px rgba(0, 0, 0, 0.28),
    0 0 0 1px rgba(255, 255, 255, 0.08) inset;
}

.hero__body {
  grid-row: 2;
  display: flex;
  width: 100%;
}

@media (min-width: 768px) {
  .hero {
    min-height: clamp(38rem, 88vh, 60rem);
    min-height: clamp(38rem, 88svh, 60rem);
  }
}

/* Desktop: the copy hangs from the top of the card at a distance derived from
   WIDTH, and the last row swallows whatever height is left — so a taller window
   grows the space below the copy instead of pushing the copy down. A share of
   the card (`1fr`) could not do this: the card's own height still tracks the
   screen, so any fraction of it moves with the window. `minmax` is what keeps a
   short window safe — when there is not enough height for the full offset the
   top row gives way first, down to the header's clearance, so the CTA stays on
   screen rather than being pushed under the fold. */
@media (min-width: 1024px) {
  .hero {
    grid-template-rows:
      minmax(var(--header-height), clamp(18.5rem, 14.5rem + 6.5vw, 27rem)) auto minmax(clamp(1.25rem, 0.5rem + 1.6vw, 3rem), 1fr);
  }
}

/* Phone: the card ends inside the first screen so the next section peeks. */
@media (max-width: 767px) {
  .hero-card-wrapper {
    padding-block-end: 1rem;
  }

  .hero {
    min-height: clamp(34rem, 92vh, 52rem);
    min-height: clamp(34rem, 92svh, 52rem);
    /* Less bottom slack than desktop: the card is short and the copy is tall. */
    grid-template-rows: minmax(var(--header-height), 1fr) auto minmax(0, 0.14fr);
  }
}

.hero__media {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero__img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 40%;
}

.hero__scrim {
  position: absolute;
  inset: 0;
}

/* Scrim: heaviest at the reading edge, nearly clear over the architecture;
   mirrored with the writing direction. The head (first layer) carries the white
   navbar across the full header width, so it runs deeper and heavier than a
   vignette would — the #حتى_نصنع campaign photograph is bright under the nav. */
.scrim-hero {
  background:
    linear-gradient(to bottom,
      rgba(6, 36, 24, .74) 0%, rgba(6, 36, 24, .46) 12%,
      rgba(6, 36, 24, .16) 24%, rgba(6, 36, 24, 0) 36%),
    linear-gradient(var(--hero-scrim-dir, to left),
      rgba(6, 36, 24, .985) 0%, rgba(6, 36, 24, .975) 14%,
      rgba(6, 36, 24, .93) 24%, rgba(6, 36, 24, .74) 34%,
      rgba(6, 36, 24, .42) 47%, rgba(6, 36, 24, .16) 66%,
      rgba(6, 36, 24, .02) 100%),
    linear-gradient(to bottom,
      rgba(6, 36, 24, .16) 0%, rgba(6, 36, 24, .04) 42%, rgba(6, 36, 24, .20) 100%);
}

@media (min-width: 768px) and (max-width: 1279px) {
  .scrim-hero {
    background:
      linear-gradient(to bottom,
        rgba(6, 36, 24, .74) 0%, rgba(6, 36, 24, .46) 12%,
        rgba(6, 36, 24, .16) 24%, rgba(6, 36, 24, 0) 36%),
      linear-gradient(var(--hero-scrim-dir, to left),
        rgba(6, 36, 24, .985) 0%, rgba(6, 36, 24, .975) 22%,
        rgba(6, 36, 24, .93) 36%, rgba(6, 36, 24, .74) 48%,
        rgba(6, 36, 24, .44) 62%, rgba(6, 36, 24, .18) 80%,
        rgba(6, 36, 24, .04) 100%),
      linear-gradient(to bottom,
        rgba(6, 36, 24, .16) 0%, rgba(6, 36, 24, .04) 42%, rgba(6, 36, 24, .20) 100%);
  }
}

[dir='rtl'] .scrim-hero {
  --hero-scrim-dir: to left;
}

[dir='ltr'] .scrim-hero {
  --hero-scrim-dir: to right;
}

/* Phone: the old ramp reached .95, opaque enough to erase the photograph — so
   the picture appeared to STOP under the headline. Ends at .74 instead: dark
   enough for white text, sheer enough to keep the building visible. The top
   stops carry a heavier head so the navbar mark clears on a light photograph. */
@media (max-width: 767px) {
  .scrim-hero {
    background: linear-gradient(to bottom,
        rgba(6, 36, 24, .36) 0%, rgba(6, 36, 24, .42) 32%,
        rgba(6, 36, 24, .56) 60%, rgba(6, 36, 24, .68) 82%, rgba(6, 36, 24, .74) 100%);
  }
}

/* Vertical placement belongs to the grid rows above; this is breathing room
   only, in rem so it cannot reintroduce a viewport dependency. */
.hero__inner {
  position: relative;
  z-index: 10;
  width: 100%;
  margin-inline-start: 0;
  margin-inline-end: auto;
  max-width: 100%;
  padding-inline: var(--hero-gutter);
  padding-block: clamp(1rem, 0.6rem + 1.2vw, 2rem);
}

/* Start-anchored column, narrow enough to stay inside the green half. */
.hero__content {
  max-width: min(clamp(34rem, 26rem + 6vw, 42rem), 100%);
}

.hero__title {
  margin-top: 0;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 1.5rem + 2.6vw, 4.8rem);
  line-height: 1.25;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: #ffffff;
  text-shadow: 0 4px 28px rgba(0, 0, 0, 0.45);
}

.hero__title-line {
  display: block;
}

.hero__title .dot {
  color: #ffffff;
}

.hero__title b {
  font-weight: inherit;
  color: #ffffff;
  /* the accent word is white now; the gold-300 accent was retired */
}

.hero__lede {
  margin-top: 1.35rem;
  max-width: min(520px, 100%);
  font-size: clamp(1rem, 0.86rem + 0.36vw, 1.25rem);
  line-height: 1.9;
  color: rgba(255, 255, 255, 0.85);
}

.hero__cta {
  margin-top: 2.35rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.875rem 1.5rem;
}

@media (max-width: 767px) {
  .hero__cta {
    margin-top: 1.75rem;
  }
}

.hero__cta .btn {
  width: 100%;
}

@media (min-width: 640px) {
  .hero__cta .btn {
    width: auto;
  }
}

.hero__link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 44px;
  color: var(--color-on-brand);
  font-size: var(--text-body-lg);
  font-weight: 500;
  text-decoration: none;
  transition: color var(--motion-fast) var(--ease-standard);
}

.hero__link-label {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-decoration-color: rgba(255, 255, 255, .45);
  text-underline-offset: 0.15em;
  transition: text-decoration-color var(--motion-fast) var(--ease-standard);
}

.hero__link-arrow {
  display: inline-flex;
  transition: transform var(--motion-fast) var(--ease-out);
}

[dir='ltr'] .hero__link-arrow {
  transform: scaleX(-1);
}

@media (hover: hover) {
  .hero__link:hover {
    color: var(--color-gold-300);
  }

  .hero__link:hover .hero__link-label {
    text-decoration-color: var(--color-gold-300);
  }

  .hero__link:hover .hero__link-arrow {
    transform: translateX(-3px);
  }

  [dir='ltr'] .hero__link:hover .hero__link-arrow {
    transform: scaleX(-1) translateX(-3px);
  }
}

/* With no primary button (registration closed) the link is promoted to one. */
.hero__cta .hero__link:only-child {
  width: 100%;
  justify-content: center;
  min-height: clamp(3rem, 2.7rem + 0.9vw, 3.5rem);
  padding-inline: clamp(1.8rem, 1.2rem + 1.4vw, 2.75rem);
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: #084c36;
  color: #ffffff;
  font-size: clamp(1rem, 0.92rem + 0.22vw, 1.1rem);
  font-weight: 600;
  box-shadow: 0 10px 25px -4px rgba(0, 0, 0, 0.4);
  transition: all var(--motion-base) var(--ease-out);
}

.hero__cta .hero__link:only-child .hero__link-label {
  text-decoration: none;
}

@media (min-width: 640px) {
  .hero__cta .hero__link:only-child {
    width: auto;
    justify-content: flex-start;
  }
}

@media (hover: hover) {
  .hero__cta .hero__link:only-child:hover {
    background: #17754c;
    border-color: rgba(255, 255, 255, 0.4);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 14px 30px -4px rgba(23, 117, 76, 0.5);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero__cta .hero__link:only-child {
    transition: background-color var(--motion-base) var(--ease-out),
      border-color var(--motion-base) var(--ease-out),
      color var(--motion-base) var(--ease-out);
  }

  .hero__cta .hero__link:only-child:hover {
    transform: none;
  }
}

/* Entrance stagger; gated on scripting so no-JS never hides the copy. */
@media (scripting: enabled) {
  [data-hero] {
    opacity: 0;
    animation: iec-hero-in 600ms var(--ease-out) both;
    animation-delay: var(--hero-delay, 0ms);
  }
}

@keyframes iec-hero-in {
  from {
    opacity: 0;
    transform: translateY(22px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

@media (scripting: enabled) and (prefers-reduced-motion: reduce) {
  [data-hero] {
    opacity: 1;
    transform: none;
    animation: none;
  }
}

/* ---- Impact / proof card -------------------------------------------------- */
.proof-section {
  width: 100%;
  scroll-margin-top: clamp(4.5rem, 6vw, 6rem);
}

.proof-card-wrapper {
  width: 100%;
  padding-inline: clamp(0.75rem, 2.2vw, 2.5rem);
  padding-block: clamp(1rem, 2.5vw, 2.25rem);
}

.proof-card {
  --mint: #8fe6c6;
  background:
    radial-gradient(120% 90% at 12% 0%, rgba(52, 141, 100, 0.38) 0%, rgba(52, 141, 100, 0) 55%),
    radial-gradient(90% 80% at 100% 100%, rgba(143, 230, 198, 0.16) 0%, rgba(143, 230, 198, 0) 50%),
    linear-gradient(150deg, #0c4630 0%, #072818 52%, #041b11 100%);
  color: #ffffff;
  border-radius: clamp(20px, 3vw, 36px);
  padding: clamp(2.5rem, 5vw, 4.5rem) clamp(1.75rem, 4.5vw, 4rem);
  box-shadow:
    0 24px 60px -12px rgba(4, 27, 17, 0.5),
    0 0 0 1px rgba(255, 255, 255, 0.1) inset,
    0 1px 0 rgba(255, 255, 255, 0.14) inset;
  position: relative;
  isolation: isolate;
  overflow: hidden;
}

/* Soft green light leaking in from the top-left corner. */
.proof-card::before {
  content: "";
  position: absolute;
  top: -30%;
  inset-inline-start: -15%;
  width: 60%;
  height: 80%;
  background: radial-gradient(closest-side, rgba(143, 230, 198, 0.22), transparent 70%);
  filter: blur(30px);
  pointer-events: none;
  z-index: -1;
}

/* ---- Decorative IEC-mark hexagons ---- */
.impact-deco {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  color: rgba(143, 230, 198, 0.5);
  z-index: -1;
}

.impact-deco__hex {
  position: absolute;
  opacity: 0.07;
  will-change: transform;
}

.impact-deco__hex--a {
  width: clamp(360px, 40vw, 620px);
  top: -18%;
  inset-inline-end: -12%;
}

.impact-deco__hex--b {
  width: clamp(300px, 32vw, 480px);
  bottom: -26%;
  inset-inline-start: -10%;
  opacity: 0.05;
}

.impact-deco__hex--c {
  width: clamp(160px, 16vw, 240px);
  top: 44%;
  inset-inline-end: 6%;
  opacity: 0.06;
}

@media (max-width: 767px) {
  .impact-deco__hex--c {
    display: none;
  }
}

/* Zero-gravity drift: each mark wanders on its own path, speed and
   direction, never settling — no easing that implies a resting point. */
@media (prefers-reduced-motion: no-preference) {
  .impact-deco__hex {
    animation: iec-hex-drift-a 34s linear infinite alternate;
  }

  .impact-deco__hex--b {
    animation-name: iec-hex-drift-b;
    animation-duration: 47s;
  }

  .impact-deco__hex--c {
    animation-name: iec-hex-drift-c;
    animation-duration: 29s;
  }
}

@keyframes iec-hex-drift-a {
  0% {
    transform: translate3d(0, 0, 0) rotate(0deg);
  }

  30% {
    transform: translate3d(3%, -4%, 0) rotate(6deg);
  }

  55% {
    transform: translate3d(-2%, 3%, 0) rotate(-4deg);
  }

  80% {
    transform: translate3d(4%, 5%, 0) rotate(3deg);
  }

  100% {
    transform: translate3d(-3%, -2%, 0) rotate(-6deg);
  }
}

@keyframes iec-hex-drift-b {
  0% {
    transform: translate3d(0, 0, 0) rotate(0deg);
  }

  25% {
    transform: translate3d(-4%, 3%, 0) rotate(-5deg);
  }

  50% {
    transform: translate3d(3%, 5%, 0) rotate(4deg);
  }

  75% {
    transform: translate3d(5%, -3%, 0) rotate(7deg);
  }

  100% {
    transform: translate3d(-2%, 4%, 0) rotate(-3deg);
  }
}

@keyframes iec-hex-drift-c {
  0% {
    transform: translate3d(0, 0, 0) rotate(0deg);
  }

  35% {
    transform: translate3d(6%, 4%, 0) rotate(-8deg);
  }

  65% {
    transform: translate3d(-5%, -5%, 0) rotate(9deg);
  }

  100% {
    transform: translate3d(4%, -6%, 0) rotate(-5deg);
  }
}

.impact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  align-items: center;
  max-width: var(--hero-measure, 1400px);
  margin-inline: auto;
  position: relative;
  z-index: 1;
}

@media (min-width: 1024px) {
  .impact-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr);
    gap: clamp(3rem, 5vw, 5.5rem);
    align-items: center;
  }
}

.impact-lead-col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.impact-heading {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 1.8rem + 1.6vw, 3.4rem);
  line-height: 1.2;
  font-weight: 700;
  color: #ffffff;
  margin-top: 0;
  margin-bottom: 1.25rem;
  letter-spacing: -0.02em;
}

.impact-desc {
  font-size: clamp(0.95rem, 0.9rem + 0.15vw, 1.08rem);
  line-height: 1.85;
  color: rgba(255, 255, 255, 0.75);
  margin: 0;
  max-width: 500px;
}

.impact-desc--sub {
  margin-top: 1rem;
  opacity: 0.88;
}

.impact-stats-col {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 620px;
}

.impact-stats-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem 1.25rem;
  width: 100%;
}

@media (min-width: 640px) {
  .impact-stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(1.25rem, 2vw, 1.75rem);
  }
}

.impact-stat-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: clamp(1rem, 1.8vw, 1.4rem);
  border-radius: clamp(14px, 1.6vw, 20px);
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08) inset;
  transition: transform var(--motion-base) var(--ease-out),
    border-color var(--motion-base) var(--ease-out),
    background-color var(--motion-base) var(--ease-out);
}

@media (hover: hover) {
  .impact-stat-item:hover {
    transform: translateY(-3px);
    border-color: rgba(143, 230, 198, 0.45);
    background: rgba(255, 255, 255, 0.06);
  }
}

.impact-stat__ic {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  margin-bottom: 0.9rem;
  border-radius: 10px;
  color: var(--mint, #8fe6c6);
  background: rgba(143, 230, 198, 0.12);
  border: 1px solid rgba(143, 230, 198, 0.22);
}

.impact-stat-num-row {
  display: flex;
  align-items: baseline;
  gap: 0.2rem;
  margin-bottom: 0.45rem;
}

.impact-stat-plus {
  font-family: var(--font-display);
  font-size: 0.65em;
  font-weight: 700;
  color: var(--mint, #8fe6c6);
  line-height: 1;
}

.impact-stat-num {
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 1.35rem + 1.5vw, 2.8rem);
  font-weight: 700;
  color: #ffffff;
  line-height: 1.05;
  letter-spacing: -0.03em;
  white-space: nowrap;
}

.impact-stat-title {
  font-size: clamp(1.05rem, 0.98rem + 0.2vw, 1.25rem);
  font-weight: 700;
  color: #ffffff;
  margin: 0 0 0.35rem 0;
  letter-spacing: -0.01em;
}

.impact-stat-desc {
  font-size: 0.875rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.65);
  margin: 0;
}

/* Phone: the desktop 2x2 at a phone measure. */
@media (max-width: 767px) {
  .proof-card-wrapper {
    padding-block: 0.75rem 1rem;
  }

  .proof-card {
    padding: 2rem 1.5rem 2.25rem;
  }

  .impact-grid {
    gap: 2rem;
  }

  .impact-heading {
    font-size: clamp(2rem, 1.4rem + 3vw, 2.6rem);
    margin-bottom: 0.875rem;
  }

  .impact-desc {
    font-size: 0.95rem;
    line-height: 1.75;
  }

  .impact-stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.875rem;
  }

  .impact-stat-item {
    padding: 1rem 0.9rem;
  }

  .impact-stat__ic {
    width: 2rem;
    height: 2rem;
    margin-bottom: 0.65rem;
  }

  .impact-stat-num {
    font-size: clamp(1.7rem, 1rem + 2.8vw, 2.6rem);
    letter-spacing: -0.02em;
  }

  .impact-stat-title {
    font-size: 0.95rem;
    margin-bottom: 0.25rem;
  }

  .impact-stat-desc {
    font-size: 0.8125rem;
    line-height: 1.5;
  }
}

/* Below 380px a seven-digit figure no longer fits half a card. */
@media (max-width: 379px) {
  .impact-stats-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .impact-stat-num {
    font-size: 2.2rem;
  }
}

/* ---- About / vision / mission ---------------------------------------------- */
.about-heading {
  font-size: clamp(2.25rem, 1.6rem + 1.85vw, 4rem);
  font-weight: 600;
  color: #247C62;
  text-align: center;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.about-sub {
  margin-top: 0.75rem;
  font-size: clamp(1.05rem, 0.92rem + 0.42vw, 1.6rem);
  font-weight: 400;
  color: #374151;
  text-align: center;
  line-height: 1.6;
  max-width: 38em;
  margin-inline: auto;
}

.duo-grid {
  margin-top: 2.75rem;
  display: grid;
  gap: 1.5rem;
  align-items: stretch;
}

@media (min-width: 768px) {
  .duo-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.75rem;
  }
}

.vm-card {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  border-radius: 1.5rem;
  color: #fff;
  box-shadow:
    0 24px 60px -12px rgba(4, 27, 17, 0.5),
    0 0 0 1px rgba(255, 255, 255, 0.1) inset,
    0 1px 0 rgba(255, 255, 255, 0.14) inset;
  transition: transform var(--motion-gentle) var(--ease-out), box-shadow var(--motion-gentle) var(--ease-out);
  min-height: clamp(460px, 380px + 6vw, 620px);
}

/* Same premium treatment as the About card: a soft light bleeding in
   from the top-inner corner. */
.vm-card::before {
  content: "";
  position: absolute;
  top: -30%;
  inset-inline-start: -15%;
  width: 60%;
  height: 80%;
  background: radial-gradient(closest-side, rgba(143, 230, 198, 0.2), transparent 70%);
  filter: blur(30px);
  pointer-events: none;
  z-index: -1;
}

.vm-card:hover {
  transform: translateY(-8px);
  box-shadow:
    0 30px 70px -12px rgba(4, 27, 17, 0.55),
    0 0 0 1px rgba(255, 255, 255, 0.14) inset,
    0 1px 0 rgba(255, 255, 255, 0.16) inset;
}

.vm-card--vision {
  background:
    radial-gradient(120% 90% at 12% 0%, rgba(52, 141, 100, 0.38) 0%, rgba(52, 141, 100, 0) 55%),
    radial-gradient(90% 80% at 100% 100%, rgba(143, 230, 198, 0.16) 0%, rgba(143, 230, 198, 0) 50%),
    linear-gradient(150deg, #0c4630 0%, #072818 52%, #041b11 100%);
}

.vm-card--mission {
  background:
    radial-gradient(120% 90% at 12% 0%, rgba(63, 100, 150, 0.4) 0%, rgba(63, 100, 150, 0) 55%),
    radial-gradient(90% 80% at 100% 100%, rgba(150, 190, 240, 0.14) 0%, rgba(150, 190, 240, 0) 50%),
    linear-gradient(150deg, #123049 0%, #0c1f33 52%, #081521 100%);
}

.vm-card--mission::before {
  background: radial-gradient(closest-side, rgba(150, 190, 240, 0.18), transparent 70%);
}

.vm-card__top {
  padding: 2.5rem 2.25rem 1.75rem 2.25rem;
}

.vm-card__title {
  font-size: clamp(2rem, 1.5rem + 1.35vw, 3.5rem);
  font-weight: 600;
  color: #fff;
  margin: 0 0 0.625rem;
  line-height: 1.2;
}

.vm-card__desc {
  font-size: clamp(1.05rem, 0.97rem + 0.26vw, 1.35rem);
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.95);
  margin: 0;
}

.vm-card__photo-wrap {
  height: clamp(18.5rem, 15rem + 6.5vw, 27rem);
  width: 100%;
  overflow: hidden;
  position: relative;
  background: rgba(0, 0, 0, 0.14);
  margin-top: auto;
}

.vm-card__photo {
  height: 100%;
  width: 100%;
  object-fit: cover;
  object-position: center 35%;
  display: block;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.vm-card--mission .vm-card__photo {
  object-position: center 50%;
}

.vm-card:hover .vm-card__photo {
  transform: scale(1.05);
}

/* Drop-in slot without a photo yet */
.vm-card__placeholder {
  height: 100%;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  background: rgba(0, 0, 0, 0.08);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.vm-card__placeholder-pattern {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.18) 1.25px, transparent 1.25px);
  background-size: 18px 18px;
  opacity: 0.7;
}

.vm-card__placeholder-badge {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1.25rem;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.25);
  font-size: 0.95rem;
  font-weight: 600;
  color: #fff;
}

@media (max-width: 767px) {
  .about-heading {
    font-size: clamp(1.9rem, 1.3rem + 3vw, 2.5rem);
  }

  .about-sub {
    font-size: 1rem;
  }

  .duo-grid {
    margin-top: 2rem;
    gap: 1.25rem;
  }

  /* Height follows the content on a phone. */
  .vm-card {
    min-height: 0;
    border-radius: 1.25rem;
  }

  .vm-card__top {
    padding: 1.75rem 1.5rem 1.375rem;
  }

  .vm-card__title {
    font-size: 1.75rem;
  }

  .vm-card__desc {
    font-size: 1rem;
    line-height: 1.6;
  }

  .vm-card__photo-wrap {
    height: clamp(12rem, 52vw, 16rem);
  }
}

/* ---- Initiatives ----------------------------------------------------------- */
.initiatives-heading {
  font-size: clamp(2.25rem, 1.6rem + 1.85vw, 4rem);
  font-weight: 800;
  color: #247C62;
  text-align: center;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.initiatives-sub {
  margin-top: 0.75rem;
  font-size: clamp(1.05rem, 0.92rem + 0.42vw, 1.6rem);
  font-weight: 500;
  color: #374151;
  text-align: center;
  line-height: 1.6;
}

@media (max-width: 767px) {
  .initiatives-heading {
    font-size: clamp(1.9rem, 1.3rem + 3vw, 2.5rem);
  }

  .initiatives-sub {
    font-size: 1rem;
  }
}

.cards-3 {
  margin-top: 2.75rem;
  display: grid;
  gap: 1.5rem;
  align-items: stretch;
}

@media (min-width: 768px) {
  .cards-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .cards-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Tablet: the odd third card sits centred at column width, not against one edge. */
@media (min-width: 768px) and (max-width: 1023px) {
  .cards-3>.init-card:last-child:nth-child(odd) {
    grid-column: 1 / -1;
    width: calc(50% - 0.75rem);
    justify-self: center;
  }
}

.init-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  border-radius: 1.5rem;
  padding: 2.25rem 1.75rem 1.75rem 1.75rem;
  color: #fff;
  text-align: center;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.12), 0 8px 10px -6px rgba(0, 0, 0, 0.08);
  transition: transform var(--motion-gentle) var(--ease-out), box-shadow var(--motion-gentle) var(--ease-out);
}

.init-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 35px -8px rgba(0, 0, 0, 0.25);
}

/* Brand colour per initiative slug */
.init-card--ahhil {
  background-color: #247C62;
}

.init-card--thara {
  background-color: #4C0677;
}

.init-card--tamakkan {
  background-color: #E2510A;
}

.init-card__top {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.875rem;
  flex: 1 1 auto;
}

.init-card__logo-wrap {
  height: 4.5rem;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.init-card__logo-img {
  max-height: 100%;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.08));
}

.init-card__title {
  font-size: clamp(1.625rem, 1.35rem + 0.75vw, 2.25rem);
  font-weight: 800;
  color: #fff;
  margin: 0.25rem 0 0;
  line-height: 1.3;
}

.init-card__desc {
  font-size: clamp(0.9375rem, 0.87rem + 0.22vw, 1.15rem);
  line-height: 1.75;
  color: rgba(255, 255, 255, 0.95);
  margin: 0;
}

.init-card__more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  font-size: 0.9375rem;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  margin-top: auto;
  transition: opacity var(--motion-base), transform var(--motion-base);
}

.init-card__more:hover {
  opacity: 0.85;
  text-decoration: none;
  transform: translateX(-3px);
}

[dir="ltr"] .init-card__more:hover {
  transform: translateX(3px);
}

.init-card__img-wrap {
  margin-top: 2rem;
  height: 13.5rem;
  width: 100%;
  overflow: hidden;
  border-radius: 1.125rem;
  background: rgba(0, 0, 0, 0.12);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.init-card__img {
  height: 100%;
  width: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform 0.4s var(--ease-out);
}

.init-card:hover .init-card__img {
  transform: scale(1.04);
}

@media (max-width: 767px) {
  .cards-3 {
    margin-top: 2rem;
    gap: 1.25rem;
  }

  .init-card {
    padding: 1.75rem 1.25rem 1.25rem;
    border-radius: 1.25rem;
  }

  .init-card__logo-wrap {
    height: 3.75rem;
  }

  .init-card__title {
    font-size: 1.45rem;
  }

  .init-card__img-wrap {
    margin-top: 1.5rem;
    height: clamp(10rem, 48vw, 13rem);
    border-radius: 0.875rem;
  }

  /* Thumb-sized target; the text link itself is unchanged. */
  .init-card__more {
    min-height: 2.75rem;
    padding: 0.5rem 0.75rem;
    margin-top: 0.25rem;
  }
}

/* ---- Partners: framed infinite marquee ------------------------------------ */
.partners-section {
  position: relative;
  overflow: hidden;
  padding-block: clamp(1.25rem, 2.8vw, 2.5rem);
  background: transparent;
}

.partners-frame-wrapper {
  width: 100%;
  padding-inline: clamp(0.75rem, 2.2vw, 2.5rem);
}

.partners-frame {
  background: #f7f4ed;
  border-radius: clamp(20px, 3vw, 36px);
  border: 1px solid rgba(8, 76, 54, 0.1);
  padding: clamp(2.25rem, 3.8vw, 3.5rem) clamp(1.75rem, 3.5vw, 3.5rem);
  box-shadow: 0 16px 40px -12px rgba(8, 76, 54, 0.05),
    0 0 0 1px rgba(255, 255, 255, 0.8) inset;
  position: relative;
  overflow: hidden;
}

.partners-bar {
  display: flex;
  align-items: center;
  border-bottom: 1px solid rgba(8, 76, 54, 0.1);
  padding-bottom: clamp(1rem, 1.8vw, 1.5rem);
  margin-bottom: clamp(1.75rem, 2.8vw, 2.5rem);
  width: 100%;
}

.partners-title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 1.2rem + 1.2vw, 3rem);
  font-weight: 700;
  color: #141715;
  letter-spacing: -0.02em;
  line-height: 1;
  margin: 0;
}

.partners-stage-wrap {
  position: relative;
  width: 100%;
}

.partners-marquee {
  position: relative;
  width: 100%;
  overflow: hidden;
  padding: 0.75rem 0;
  mask-image: linear-gradient(to right, transparent 0%, #000 6%, #000 94%, transparent 100%);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 6%, #000 94%, transparent 100%);
}

/* The track holds the logos twice, so translating by half loops seamlessly. */
.partners-marquee__track {
  display: flex;
  align-items: center;
  gap: clamp(2.5rem, 4.5vw, 5rem);
  width: max-content;
  will-change: transform;
  animation: iec-marquee 45s linear infinite;
}

.partners-stage-wrap:hover .partners-marquee__track,
.partners-stage-wrap.is-paused .partners-marquee__track {
  animation-play-state: paused;
}

@keyframes iec-marquee {
  0% {
    transform: translate3d(0, 0, 0);
  }

  100% {
    transform: translate3d(-50%, 0, 0);
  }
}

[dir="rtl"] .partners-marquee__track {
  animation: iec-marquee-rtl 45s linear infinite;
}

@keyframes iec-marquee-rtl {
  0% {
    transform: translate3d(0, 0, 0);
  }

  100% {
    transform: translate3d(50%, 0, 0);
  }
}

.partner-card {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  height: clamp(3.25rem, 2.8rem + 1vw, 4.25rem);
  width: auto;
  min-width: clamp(7.5rem, 6.5rem + 2vw, 10rem);
  background: transparent;
  padding: 0.25rem 0.75rem;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
}

.partner-card:hover {
  transform: translateY(-4px) scale(1.08);
}

.partner-card__glass {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

/* Monochrome at rest, full colour on hover */
.partner-card__img {
  max-height: clamp(2.2rem, 1.8rem + 0.8vw, 2.85rem);
  width: auto;
  max-width: 100%;
  object-fit: contain;
  filter: grayscale(100%) contrast(110%) opacity(0.6);
  transition: filter 0.35s cubic-bezier(0.16, 1, 0.3, 1), transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
}

.partner-card:hover .partner-card__img {
  filter: grayscale(0%) contrast(100%) opacity(1) drop-shadow(0 4px 14px rgba(0, 0, 0, 0.12));
  transform: scale(1.06);
}

@media (max-width: 767px) {
  .partners-section {
    padding-block: 0.75rem 1rem;
  }

  .partners-frame {
    padding: 1.5rem 1.25rem 1.25rem;
  }

  .partners-bar {
    padding-bottom: 0.875rem;
    margin-bottom: 1.25rem;
  }

  .partners-marquee__track {
    gap: 1.75rem;
  }

  .partner-card {
    min-width: 6rem;
    height: 3rem;
    padding: 0.25rem 0.5rem;
  }

  .partner-card__img {
    max-height: 2rem;
  }
}

/* Slide controls (dots + pause). Rendered for the keyboard pause contract,
   hidden by design while the strip runs as a marquee. */
.partners__controls-wrap {
  display: none;
}

.partners__controls-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1rem;
  border-radius: 9999px;
  background: var(--color-surface-raised);
  border: 1px solid var(--color-line);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
}

.partners__dots {
  display: flex;
  max-width: 100%;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
}

.partners__dot-btn {
  display: grid;
  place-items: center;
  padding: 0.25rem;
  min-width: 1.5rem;
  min-height: 1.5rem;
}

.partners__dot {
  display: block;
  height: 0.5rem;
  width: 0.5rem;
  border-radius: 9999px;
  background: var(--color-neutral-500);
  transition: background-color var(--motion-base);
}

.partners__dot-btn:hover .partners__dot {
  background: var(--color-neutral-600);
}

.partners__dot-track {
  display: block;
  height: 0.5rem;
  width: 2.25rem;
  overflow: hidden;
  border-radius: 9999px;
  background: var(--color-neutral-500);
}

.partners__dot-fill {
  display: block;
  height: 100%;
  width: 100%;
  transform-origin: left;
  border-radius: 9999px;
  background: linear-gradient(to right, var(--color-green-400), var(--color-green-700));
  animation: iec-fill 5000ms linear forwards;
}

[dir="rtl"] .partners__dot-fill {
  transform-origin: right;
}

.partners.is-paused .partners__dot-fill,
.partners-stage-wrap.is-paused .partners__dot-fill {
  animation-play-state: paused;
}

.partners__toggle {
  margin-inline-start: 0.5rem;
  color: var(--color-muted);
  transition: color var(--motion-base);
}

.partners__toggle:hover {
  color: var(--color-ink);
}

.partners__toggle-icon {
  display: grid;
  place-items: center;
}

.partners__toggle-icon svg:last-child {
  display: none;
}

.partners__toggle-icon.is-playing svg:first-child {
  display: none;
}

.partners__toggle-icon.is-playing svg:last-child {
  display: block;
}

@keyframes iec-fill {
  from {
    transform: scaleX(0);
  }

  to {
    transform: scaleX(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  .partners__toggle {
    display: none;
  }

  .partners__dot-fill {
    display: none;
  }

  .partners-marquee__track {
    animation: none;
  }
}

/* ---- Profile cards (alumni / board archive / consultants) ------------------ */
.profile-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  border-radius: var(--radius-xl);
  border: 1px solid var(--color-line);
  background: var(--color-surface-raised);
  padding: 1.75rem 1.5rem;
  text-align: center;
  box-shadow: var(--shadow-sm);
  height: 100%;
  transition: transform var(--motion-gentle) var(--ease-out), box-shadow var(--motion-gentle) var(--ease-out);
}

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

.profile-card__photo {
  margin-bottom: 0.75rem;
  height: 5.5rem;
  width: 5.5rem;
  border-radius: 9999px;
  border: 2.5px solid var(--color-green-300);
  object-fit: cover;
}

.profile-card__avatar {
  margin-bottom: 0.75rem;
  display: grid;
  height: 5rem;
  width: 5rem;
  place-items: center;
  border-radius: 9999px;
  background: linear-gradient(to bottom right, var(--color-green-100), var(--color-green-50));
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-green-700);
  box-shadow: inset 0 0 0 1px var(--color-green-200);
}

.profile-card__name {
  font-size: var(--text-body-lg);
  font-weight: 700;
  color: var(--color-ink);
}

.profile-card__meta {
  font-size: var(--text-body-sm);
  color: var(--color-muted);
}

.profile-card__bio {
  margin-top: 0.5rem;
  font-size: var(--text-body-sm);
  color: var(--color-muted);
}

.profile-card__linkedin {
  margin-top: 0.75rem;
  display: grid;
  height: 2.75rem;
  width: 2.75rem;
  place-items: center;
  border-radius: var(--radius-lg);
  background: var(--color-green-50);
  color: var(--color-link);
  transition: background-color var(--motion-base), color var(--motion-base);
}

.profile-card__linkedin:hover {
  background: var(--color-green-700);
  color: #fff;
}

.people-grid {
  margin-top: 2.5rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

.people-grid-3 {
  margin-top: 2.5rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

/* Two-up from 360px: the cards are compact (name + batch). */
@media (min-width: 360px) and (max-width: 639px) {
  .people-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 640px) {

  .people-grid,
  .people-grid-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .people-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .people-grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 639px) {

  .people-grid,
  .people-grid-3 {
    margin-top: 2rem;
    gap: 0.875rem;
  }

  .profile-card {
    padding: 1.5rem 1rem;
    border-radius: var(--radius-lg);
  }

  .profile-card__photo,
  .profile-card__avatar {
    height: 4.5rem;
    width: 4.5rem;
  }

  .profile-card__name {
    font-size: 1rem;
  }

  .profile-card__meta {
    font-size: 0.875rem;
  }
}

/* ---- Empty state ------------------------------------------------------------ */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  border-radius: var(--radius-xl);
  border: 1px dashed var(--color-line);
  background: var(--color-surface-sunken);
  padding: 4rem 2rem;
  text-align: center;
}

.empty-state__icon {
  display: grid;
  height: 3rem;
  width: 3rem;
  place-items: center;
  border-radius: 9999px;
  background: var(--color-green-50);
  color: var(--color-link);
}

.empty-state__title {
  font-size: var(--text-body-lg);
  font-weight: 600;
  color: var(--color-ink);
}

.empty-state__body {
  max-width: 36em;
  color: var(--color-muted);
}

@media (max-width: 639px) {
  .empty-state {
    padding: 2.5rem 1.25rem;
  }
}

/* ---- Join CTA --------------------------------------------------------------- */
.join-cta {
  padding-block: 4rem 2rem;
}

.join-cta__card {
  position: relative;
  overflow: hidden;
  border-radius: 1.75rem;
  background: transparent;
}

.join-cta__content {
  display: grid;
  gap: 2.5rem;
  align-items: center;
}

@media (min-width: 900px) {
  .join-cta__content {
    grid-template-columns: 1.1fr 1fr;
    gap: 3.5rem;
  }
}

.join-cta__text-col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.25rem;
}

.join-cta__title {
  font-size: clamp(2.5rem, 1.8rem + 2.1vw, 4.5rem);
  font-weight: 800;
  color: #247C62;
  line-height: 1.15;
  margin: 0;
}

.join-cta__body-text {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  font-size: clamp(1.05rem, 0.92rem + 0.42vw, 1.5rem);
  line-height: 1.7;
  color: #374151;
}

.join-cta__body-text p {
  margin: 0;
}

.join-cta__actions {
  margin-top: 0.5rem;
}

.btn-join {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: #247C62;
  color: #ffffff;
  font-size: 1.125rem;
  font-weight: 700;
  padding: 0.875rem 2.5rem;
  border-radius: 0.625rem;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(36, 124, 98, 0.25);
  transition: all var(--motion-base) var(--ease-out);
}

.btn-join:hover {
  background-color: #1C6752;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(36, 124, 98, 0.35);
  color: #ffffff;
}

.join-cta__photo-col {
  width: 100%;
}

/* The poster is shown whole on a white ground (object-fit: contain). */
.join-cta__photo-frame {
  position: relative;
  height: 22rem;
  width: 100%;
  border-radius: 1.5rem;
  overflow: hidden;
  background: #ffffff;
  box-shadow: 0 12px 30px -8px rgba(0, 0, 0, 0.1);
}

.join-cta__img {
  height: 100%;
  width: 100%;
  object-fit: contain;
  object-position: center;
  display: block;
  background: #ffffff;
}

/* Drop-in slot without a photo yet */
.join-cta__placeholder {
  height: 100%;
  width: 100%;
  position: relative;
  background: #f8fafc;
  border: 1.5px dashed rgba(36, 124, 98, 0.25);
  border-radius: 1.5rem;
}

.join-cta__placeholder-pattern {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(36, 124, 98, 0.15) 1.25px, transparent 1.25px);
  background-size: 18px 18px;
  opacity: 0.6;
}

@media (max-width: 899px) {
  .join-cta {
    padding-block: 2.5rem 1rem;
  }

  .join-cta__content {
    gap: 1.75rem;
  }

  .join-cta__title {
    font-size: clamp(2rem, 1.4rem + 3vw, 2.75rem);
  }

  .join-cta__body-text {
    font-size: 1rem;
  }

  .join-cta__photo-frame {
    height: clamp(12rem, 45vw, 18rem);
  }

  /* Stacked layouts show the slot only once it holds a photo. */
  .join-cta__photo-col:has(.join-cta__placeholder) {
    display: none;
  }
}

@media (max-width: 639px) {
  .btn-join {
    width: 100%;
  }
}

/* ---- Standalone page bits --------------------------------------------------- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.container--narrow {
  max-width: 720px;
}

.about-intro {
  margin-top: 1.5rem;
  font-size: var(--text-body-lg);
  line-height: 2;
  color: var(--color-ink);
}

.archive-banner {
  margin-bottom: 2rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-gold-400);
  background: rgba(232, 206, 140, .15);
  padding: 0.75rem 1.25rem;
  font-size: var(--text-body-sm);
  color: var(--color-ink);
}

.archive-banner a {
  font-weight: 600;
  color: var(--color-link);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.mt-block {
  margin-top: 2.5rem;
}

/* Privacy stub */
.placeholder {
  min-height: 55vh;
  min-height: 55svh;
}

.placeholder__inner {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.25rem;
}

.placeholder__title {
  font-size: var(--text-h1);
  line-height: var(--lh-h1);
  font-weight: 700;
  color: var(--color-ink);
}

.placeholder__body {
  max-width: 42em;
  font-size: var(--text-body-lg);
  color: var(--color-muted);
}

/* 404 */
.notfound {
  min-height: 60vh;
  min-height: 60svh;
}

.notfound__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  text-align: center;
}

/* green-600 reads 3.30:1 on white (WCAG large text); the numeral is decorative. */
.notfound__code {
  font-size: var(--text-display);
  line-height: var(--lh-display);
  font-weight: 700;
  color: var(--color-green-600);
}

.notfound__title {
  margin: 0;
}

.notfound__msg {
  max-width: 30em;
  font-size: var(--text-body-lg);
  color: var(--color-muted);
}

/* ---- Events list + detail --------------------------------------------------- */
.events-grid {
  margin-top: 1.5rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 640px) {
  .events-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .events-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.event-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: var(--radius-xl);
  border: 1px solid var(--color-line);
  background: var(--color-surface-raised);
  box-shadow: var(--shadow-sm);
  transition: transform var(--motion-gentle) var(--ease-out), box-shadow var(--motion-gentle) var(--ease-out);
}

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

.event-card__cover {
  position: relative;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: linear-gradient(to bottom right, var(--color-green-100), var(--color-green-200));
}

.event-card__cover img {
  position: absolute;
  inset: 0;
  height: 100%;
  width: 100%;
  object-fit: cover;
  transition: transform var(--motion-slow);
}

.event-card:hover .event-card__cover img {
  transform: scale(1.03);
}

.event-card__logo {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
}

.event-card__logo img {
  height: 3rem;
  width: auto;
  opacity: .2;
}

.event-card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1.5rem;
}

.event-card__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem 0.75rem;
  font-size: var(--text-body-sm);
}

.event-card__date {
  color: var(--color-link);
}

.event-card__time {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  color: var(--color-muted);
}

.event-card__title {
  font-size: var(--text-h4);
  line-height: var(--lh-h4);
  font-weight: 700;
  color: var(--color-ink);
}

.event-card__title-link {
  color: inherit;
  text-decoration: none;
  transition: color var(--motion-fast);
}

.event-card__title-link:hover {
  color: var(--color-link);
}

.event-card__desc {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: var(--text-body-sm);
  line-height: 1.6;
  color: var(--color-muted);
}

.event-card__loc {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-size: var(--text-body-sm);
  color: var(--color-muted);
}

.event-card__footer {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--color-line);
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.event-card__btn-register {
  width: 100%;
  text-align: center;
  justify-content: center;
}

@media (max-width: 639px) {
  .event-card__body {
    padding: 1.25rem;
  }
}

.event-detail__wrap {
  max-width: 760px;
}

.event-detail__back {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: var(--text-body-sm);
  font-weight: 600;
  color: var(--color-link);
}

.event-detail__back:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.event-detail__back svg {
  transition: transform var(--motion-base);
}

[dir="rtl"] .event-detail__back svg {
  transform: rotate(180deg);
}

.event-detail__title {
  margin-top: 1.5rem;
  font-size: var(--text-h1);
  line-height: var(--lh-h1);
  font-weight: 700;
  color: var(--color-ink);
}

.event-detail__meta {
  margin-top: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  font-size: var(--text-body-sm);
  color: var(--color-muted);
}

.event-detail__meta span,
.event-detail__meta time {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
}

.event-detail__cover {
  position: relative;
  margin-top: 2rem;
  aspect-ratio: 16/9;
  overflow: hidden;
  border-radius: var(--radius-xl);
  background: var(--color-green-100);
}

.event-detail__cover img {
  position: absolute;
  inset: 0;
  height: 100%;
  width: 100%;
  object-fit: cover;
}

.event-detail__desc {
  margin-top: 2rem;
  white-space: pre-line;
  font-size: var(--text-body-lg);
  line-height: 2;
  color: var(--color-ink);
}

.event-detail__register {
  margin-top: 2rem;
}

/* ---- Events page (teaser layout) ------------------------------------------- */
.events-simple-page {
  width: 100%;
  background: #ffffff;
  padding: 2.5rem 0 5rem;
  font-family: var(--font-sans);
}

.events-breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: #556860;
  margin-bottom: 1.5rem;
}

.events-breadcrumb a {
  color: #556860;
  text-decoration: none;
  transition: color 0.2s ease;
}

.events-breadcrumb a:hover {
  color: #084c36;
}

.events-breadcrumb-sep {
  color: #a0b0a8;
}

.events-breadcrumb-current {
  color: #084c36;
  font-weight: 600;
}

.events-simple-hero {
  margin-bottom: 3.5rem;
}

/* `.gov-gold-bar` is defined in team.css, which this page does not load. */
.events-simple-hero .gov-gold-bar {
  width: 56px;
  height: 3px;
  border-radius: 2px;
  background: #c5a869;
  margin: 0 0 1.25rem;
}

.events-simple-title {
  font-size: clamp(2rem, 1.6rem + 1.5vw, 2.75rem);
  font-weight: 700;
  color: #152620;
  line-height: 1.25;
  margin: 0 0 0.75rem;
}

.events-simple-sub {
  font-size: 1.0625rem;
  line-height: 1.7;
  color: #556860;
  margin: 0;
  max-width: 680px;
}

.events-teaser-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: #fbfdfc;
  border: 1px solid #dce5e0;
  border-radius: 8px;
  padding: 3.5rem 2rem;
  max-width: 720px;
  margin: 0 auto;
  border-top: 4px solid #084c36;
  box-shadow: 0 10px 25px -5px rgba(8, 76, 54, 0.04);
}

.events-teaser-icon {
  display: grid;
  place-items: center;
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  background: #edf5f1;
  color: #084c36;
  margin-bottom: 1.5rem;
}

.events-teaser-heading {
  font-size: clamp(1.35rem, 1.15rem + 0.6vw, 1.75rem);
  font-weight: 700;
  color: #0c2b20;
  margin: 0 0 0.65rem;
}

.events-teaser-text {
  font-size: 1.05rem;
  line-height: 1.7;
  color: #556860;
  max-width: 32em;
  margin: 0 0 2.25rem;
}

.events-teaser-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.events-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.4rem;
  border-radius: 4px;
  font-size: 0.9375rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}

.events-btn--primary {
  background: #084c36;
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(8, 76, 54, 0.18);
}

.events-btn--primary:hover {
  background: #063828;
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(8, 76, 54, 0.25);
}

.events-btn--outline {
  background: #ffffff;
  color: #084c36;
  border: 1px solid #c2d8cd;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.events-btn--outline:hover {
  background: #f4f8f6;
  border-color: #084c36;
  color: #084c36;
  transform: translateY(-2px);
}

@media (max-width: 639px) {
  .events-simple-page {
    padding: 1.5rem 0 3.5rem;
  }

  .events-breadcrumb {
    margin-bottom: 1.25rem;
  }

  .events-simple-hero {
    margin-bottom: 2rem;
  }

  .events-teaser-card {
    padding: 2.5rem 1.25rem;
  }

  .events-teaser-actions {
    width: 100%;
    flex-direction: column;
    gap: 0.75rem;
  }

  .events-btn {
    width: 100%;
    justify-content: center;
    min-height: 2.875rem;
  }
}

/* ---- Forms: shared fields --------------------------------------------------- */
.form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.field-stack {
  display: flex;
  flex-direction: column;
  gap: 1.35rem;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.field__label {
  font-size: 0.875rem;
  font-weight: 600;
  color: #18382f;
}

.field__req {
  color: #b91c1c;
  font-weight: 700;
}

.field__error {
  font-size: 0.8125rem;
  color: #b91c1c;
  font-weight: 500;
}

.input-icon-wrap {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  inset-inline-start: 1rem;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #7f9189;
  transition: color 0.2s ease, transform 0.2s ease;
}

.field-input {
  width: 100%;
  border-radius: 0.625rem;
  border: 1.5px solid #d8e2dd;
  background: #f9fbfb;
  padding: 0.75rem 1rem;
  font-size: 0.95rem;
  color: #142822;
  transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  font-family: inherit;
}

.field-input--has-icon {
  padding-inline-start: 2.75rem;
}

/* An LTR input inside the Arabic page: the icon sits on the wrapper's start
   (right), but the input's own inline-start is the left. Pad the icon's side. */
[dir='rtl'] .field-input--has-icon[dir='ltr'] {
  padding-left: 1rem;
  padding-right: 2.75rem;
}

.field-input:hover {
  border-color: #a6bcb2;
  background: #ffffff;
}

.field-input:focus {
  outline: none;
  border-color: #086447;
  background: #ffffff;
  box-shadow: 0 0 0 4px rgba(8, 100, 71, 0.12);
}

.input-icon-wrap:focus-within .input-icon {
  color: #086447;
  transform: scale(1.08);
}

.field-input[aria-invalid="true"] {
  border-color: #b91c1c;
  background-color: #fef8f8;
  box-shadow: 0 0 0 3px rgba(185, 28, 28, 0.1);
}

.field-input::placeholder {
  color: #a2b0aa;
}

.field-input--textarea {
  min-height: 8.5rem;
  line-height: 1.6;
  resize: vertical;
}

.select-wrap {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
}

.field-input--select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  cursor: pointer;
  padding-inline-end: 2.75rem;
}

.select-icon {
  position: absolute;
  inset-inline-end: 1rem;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #79837d;
  transition: color 0.2s ease;
}

.field-input--select:focus+.select-icon {
  color: #086447;
}

.field-grid-2 {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 640px) {
  .field-grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.form__error-banner {
  border-radius: 0.5rem;
  background: rgba(185, 28, 28, 0.08);
  padding: 0.75rem 1rem;
  font-size: 0.875rem;
  color: #b91c1c;
}

/* Off-screen anti-abuse field */
.honeypot {
  position: absolute;
  left: -9999px;
  height: 0;
  width: 0;
  overflow: hidden;
}

/* 16px on phones, or iOS Safari zooms into every focused field. */
@media (max-width: 767px) {
  .field-input {
    font-size: 1rem;
  }
}

/* ---- Join page --------------------------------------------------------------- */
.join-section {
  position: relative;
  padding: 4rem 0 6.5rem;
  background-color: #f7faf8;
  background-image:
    radial-gradient(ellipse at 50% 0%, rgba(8, 100, 71, 0.08) 0%, transparent 65%),
    radial-gradient(circle at 1px 1px, rgba(8, 100, 71, 0.05) 1px, transparent 1px);
  background-size: 100% 100%, 24px 24px;
}

.join-header {
  text-align: center;
  margin-bottom: 2.75rem;
}

.join-title {
  font-size: clamp(2rem, 1.6rem + 1.6vw, 2.75rem);
  font-weight: 700;
  color: #14392f;
  line-height: 1.25;
  margin: 0 0 0.875rem;
  letter-spacing: -0.01em;
}

.join-subtitle {
  font-size: 1.125rem;
  line-height: 1.7;
  color: #5a6b64;
  max-width: 52ch;
  margin: 0 auto;
}

.join-card {
  background: #ffffff;
  border: 1px solid rgba(8, 100, 71, 0.14);
  border-top: 4px solid #d1ab5c;
  border-radius: 1.5rem;
  padding: 2.25rem 1.5rem;
  box-shadow: 0 24px 50px -12px rgba(8, 100, 71, 0.09), 0 4px 16px -2px rgba(8, 100, 71, 0.03);
}

@media (min-width: 640px) {
  .join-card {
    padding: 3.25rem 3rem;
  }
}

.form--join {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.join-fieldset {
  border: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.join-step-head {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.5rem;
}

.join-step-badge {
  width: 2.35rem;
  height: 2.35rem;
  border-radius: 50%;
  background: #eaf4ef;
  border: 1.5px solid #b5decb;
  color: #086447;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9375rem;
  flex-shrink: 0;
}

.join-step-badge--gold {
  background: #fffdf5;
  border-color: #f1dfa8;
  color: #b38b2a;
}

.join-step-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #14392f;
  margin: 0;
  line-height: 1.3;
}

.join-step-desc {
  font-size: 0.84375rem;
  color: #71817b;
  margin: 0.2rem 0 0;
}

.join-divider {
  border: none;
  border-top: 1px solid #e7ecea;
  margin: 0.5rem 0;
}

/* Committee preference cards (mirror the hidden selects) */
.comm-cards-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}

@media (min-width: 600px) {
  .comm-cards-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 900px) {
  .comm-cards-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.comm-card {
  position: relative;
  text-align: start;
  background: #ffffff;
  border: 1.5px solid #dce5e1;
  border-radius: 0.875rem;
  padding: 1.25rem 1.125rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02);
}

.comm-card:hover {
  border-color: #086447;
  transform: translateY(-2px);
  box-shadow: 0 8px 18px -4px rgba(8, 100, 71, 0.12);
}

.comm-card__icon {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 0.625rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #eaf4ef;
  color: #086447;
  flex-shrink: 0;
  transition: all 0.2s ease;
}

.comm-card:hover .comm-card__icon {
  background: #086447;
  color: #ffffff;
}

.comm-card__title {
  font-size: 1.0625rem;
  font-weight: 700;
  color: #14392f;
  margin: 0;
}

.comm-card__desc {
  font-size: 0.8125rem;
  color: #64756e;
  line-height: 1.5;
  margin: 0;
}

.comm-card__rank-badge {
  position: absolute;
  inset-block-start: 0.75rem;
  inset-inline-end: 0.75rem;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: 6px;
  background: transparent;
  color: transparent;
  letter-spacing: -0.01em;
  transition: all 0.2s ease;
}

.comm-card.is-selected-1 {
  border-color: #086447;
  background: #f2f8f5;
  box-shadow: 0 0 0 2px #086447, 0 8px 20px -4px rgba(8, 100, 71, 0.15);
}

.comm-card.is-selected-1 .comm-card__rank-badge {
  background: #086447;
  color: #ffffff;
  box-shadow: 0 2px 6px rgba(8, 100, 71, 0.25);
}

.comm-card.is-selected-2 {
  border-color: #0d835e;
  background: #f6faf8;
  box-shadow: 0 0 0 1.5px #0d835e;
}

.comm-card.is-selected-2 .comm-card__rank-badge {
  background: #0d835e;
  color: #ffffff;
  box-shadow: 0 2px 6px rgba(13, 131, 94, 0.25);
}

.comm-card.is-selected-3 {
  border-color: #2b9975;
  background: #fbfdfc;
  box-shadow: 0 0 0 1.5px #2b9975;
}

.comm-card.is-selected-3 .comm-card__rank-badge {
  background: #2b9975;
  color: #ffffff;
  box-shadow: 0 2px 6px rgba(43, 153, 117, 0.25);
}

/* The real selects stay in the form (submitted, no-JS fallback) but are driven by the cards. */
.comm-selects-container {
  display: none;
}

.join-trust-card {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.125rem 1.25rem;
  background: #f4f8f6;
  border: 1px solid #dbe8e2;
  border-radius: 0.875rem;
  margin-top: 0.5rem;
}

.join-trust-icon {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 0.5rem;
  background: #e2f0ea;
  color: #086447;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 0.125rem;
}

.join-trust-content {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.join-trust-title {
  font-size: 0.875rem;
  font-weight: 700;
  color: #14392f;
  margin: 0;
}

.join-trust-text {
  font-size: 0.8125rem;
  line-height: 1.6;
  color: #5a6e66;
  margin: 0;
}

.join-submit-wrap {
  display: flex;
  justify-content: flex-start;
  padding-top: 0.5rem;
}

.join-submit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.625rem;
  min-width: 200px;
  padding: 1rem 2.5rem;
  font-size: 1.0625rem;
  font-weight: 700;
  background: linear-gradient(180deg, #086447 0%, #064d38 100%);
  color: #ffffff;
  border-radius: 0.75rem;
  border: none;
  cursor: pointer;
  box-shadow: 0 10px 24px -4px rgba(8, 100, 71, 0.35);
  transition: all 0.2s ease;
}

.join-submit-btn:hover {
  background: linear-gradient(180deg, #0a7352 0%, #085a42 100%);
  transform: translateY(-2px);
  box-shadow: 0 14px 28px -4px rgba(8, 100, 71, 0.45);
}

.join-submit-btn:active {
  transform: translateY(0);
}

/* Success and closed states */
.form-success {
  border-radius: 1.5rem;
  border: 1px solid rgba(8, 100, 71, 0.18);
  background: #ffffff;
  padding: 3.5rem 2rem;
  text-align: center;
  box-shadow: 0 20px 45px -10px rgba(8, 100, 71, 0.08);
}

.form-success__icon {
  width: 4.5rem;
  height: 4.5rem;
  border-radius: 50%;
  background: #eaf4ef;
  color: #086447;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  box-shadow: 0 0 0 8px #f4f8f6;
}

.form-success__title {
  font-size: 1.75rem;
  font-weight: 800;
  color: #086447;
  margin-bottom: 0.75rem;
}

.form-success__body {
  font-size: 1.0625rem;
  color: #5c6560;
  max-width: 42ch;
  margin: 0 auto;
}

.join-closed {
  border-radius: 1.5rem;
  border: 1px solid #e7eae8;
  background: #ffffff;
  padding: 3.5rem 2rem;
  text-align: center;
  box-shadow: 0 20px 45px -10px rgba(0, 0, 0, 0.04);
}

.join-closed__icon {
  width: 4.5rem;
  height: 4.5rem;
  border-radius: 50%;
  background: #f4f6f5;
  color: #79837d;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
}

.join-closed__title {
  font-size: 1.75rem;
  font-weight: 800;
  color: #14392f;
  margin-bottom: 0.75rem;
}

.join-closed__body {
  font-size: 1.0625rem;
  color: #79837d;
  max-width: 42ch;
  margin: 0 auto 2rem;
}

.join-closed__cta {
  display: flex;
  justify-content: center;
}

@media (max-width: 767px) {
  .join-section {
    padding: 2.5rem 0 4rem;
  }

  .join-header {
    margin-bottom: 2rem;
  }

  .form--join {
    gap: 1.5rem;
  }

  .join-step-title {
    font-size: 1.125rem;
  }

  .form-success,
  .join-closed {
    padding: 2.5rem 1.25rem;
  }
}

@media (max-width: 639px) {
  .join-card {
    padding: 2rem 1.25rem;
    border-radius: 1.25rem;
  }

  .join-submit-wrap .join-submit-btn {
    width: 100%;
  }
}

/* ---- Gallery masonry + lightbox --------------------------------------------- */
.gallery-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  grid-auto-rows: 10px;
}

@media (min-width: 640px) {
  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .gallery-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 1280px) {
  .gallery-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--color-green-100);
  padding: 0;
  border: 0;
  cursor: pointer;
}

.gallery-item img {
  height: 100%;
  width: 100%;
  object-fit: cover;
  transition: transform var(--motion-slow);
}

.gallery-item:hover img {
  transform: scale(1.04);
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(6, 36, 24, .9);
  padding: 1rem;
  backdrop-filter: blur(4px);
}

/* Focused programmatically on open; keyboard focus still shows the global ring. */
.lightbox:focus:not(:focus-visible) {
  outline: none;
}

.lightbox[hidden] {
  display: none;
}

.lightbox__img {
  max-height: 85vh;
  max-height: 85svh;
  max-width: 90vw;
  border-radius: var(--radius-lg);
  object-fit: contain;
}

.lightbox__btn {
  position: absolute;
  display: grid;
  height: 2.75rem;
  width: 2.75rem;
  place-items: center;
  border-radius: 9999px;
  background: rgba(255, 255, 255, .1);
  color: #fff;
  transition: background-color var(--motion-base);
}

.lightbox__btn:hover {
  background: rgba(255, 255, 255, .2);
}

.lightbox__close {
  inset-block-start: 1rem;
  inset-inline-end: 1rem;
}

.lightbox__prev {
  inset-inline-start: 1rem;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox__next {
  inset-inline-end: 1rem;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox__counter {
  position: absolute;
  inset-block-end: 1rem;
  inset-inline: 0;
  margin-inline: auto;
  width: max-content;
  border-radius: 9999px;
  background: rgba(255, 255, 255, .1);
  padding: 0.375rem 1rem;
  font-size: var(--text-body-sm);
  color: #fff;
}

/* Phone: arrows in a bottom row a thumb can reach, counter between them. */
@media (max-width: 639px) {
  .lightbox {
    padding: 0.75rem;
  }

  .lightbox__img {
    max-width: 100%;
    max-height: 78vh;
    max-height: 78svh;
  }

  .lightbox__prev,
  .lightbox__next {
    top: auto;
    bottom: 1rem;
    transform: none;
  }

  .lightbox__counter {
    inset-block-end: 1.4rem;
  }
}

/* Direction-specific icon pairs (e.g. lightbox arrows) */
.rtl-hide {
  display: inline-flex;
}

[dir="rtl"] .rtl-hide {
  display: none;
}

.rtl-show {
  display: none;
}

[dir="rtl"] .rtl-show {
  display: inline-flex;
}

/* ---- Contact page ------------------------------------------------------------ */
.section--contact {
  padding-block: clamp(2rem, 4vw, 4rem);
  background: transparent;
}

.contact-container {
  max-width: 680px;
  margin-inline: auto;
}

.contact-card {
  background: #ffffff;
  border-radius: clamp(20px, 2.5vw, 28px);
  border: 1px solid rgba(8, 76, 54, 0.12);
  box-shadow: 0 12px 36px -8px rgba(8, 76, 54, 0.06),
    0 2px 6px rgba(0, 0, 0, 0.02);
  padding: clamp(2rem, 3.5vw, 3rem) clamp(1.5rem, 3vw, 2.75rem);
  position: relative;
  overflow: hidden;
}

.contact-card::before {
  content: '';
  position: absolute;
  top: 0;
  inset-inline: 0;
  height: 4px;
  background: linear-gradient(90deg, #084c36 0%, #17754c 100%);
}

.contact-card__header {
  margin-bottom: clamp(1.75rem, 2.5vw, 2.25rem);
  padding-bottom: 1.25rem;
  border-bottom: 1px solid rgba(8, 76, 54, 0.08);
}

.contact-title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 1.4rem + 1.2vw, 2.35rem);
  font-weight: 700;
  color: #141715;
  letter-spacing: -0.02em;
  line-height: 1.25;
  margin: 0 0 0.65rem 0;
}

.contact-intro {
  font-size: clamp(0.925rem, 0.88rem + 0.2vw, 1.025rem);
  line-height: 1.65;
  color: #525d57;
  margin: 0;
}

.contact-form__fields {
  display: flex;
  flex-direction: column;
  gap: 1.35rem;
}

.contact-form .field {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.contact-form .field__label {
  font-size: 0.925rem;
  font-weight: 600;
  color: #1f2622;
  letter-spacing: -0.01em;
}

.contact-form .field__req {
  color: #c0392b;
  font-weight: 700;
}

.contact-form .field-input {
  width: 100%;
  border-radius: 12px;
  border: 1.5px solid #d4ded9;
  background: #fbfdfc;
  padding: 0.8rem 1.1rem;
  font-size: 0.975rem;
  color: #141c18;
  font-family: inherit;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.02) inset;
}

.contact-form .field-input:hover {
  border-color: #9eb5aa;
  background: #ffffff;
}

.contact-form .field-input:focus {
  outline: none;
  border-color: #084c36;
  background: #ffffff;
  box-shadow: 0 0 0 3.5px rgba(8, 76, 54, 0.12);
}

/* 16px on phones, or iOS Safari zooms into every focused field. */
@media (max-width: 767px) {
  .contact-form .field-input {
    font-size: 1rem;
  }
}

/* Subject Selection: Modern Responsive Card Grid */
.subject-chips {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5rem;
  margin-top: 0.35rem;
  width: 100%;
}

@media (max-width: 639px) {
  .subject-chips {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
  }
}

.subject-chip {
  cursor: pointer;
  user-select: none;
  margin: 0;
  display: flex;
  width: 100%;
}

.subject-chip__input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

.subject-chip__pill {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 0.5rem;
  border-radius: 10px;
  background: #ffffff;
  border: 1.5px solid #d4ded9;
  font-size: 0.9rem;
  font-weight: 500;
  color: #2c3832;
  text-align: center;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.02);
}

.subject-chip:hover .subject-chip__pill {
  border-color: #084c36;
  background: #f6faf8;
  color: #084c36;
  transform: translateY(-1px);
}

.subject-chip__input:checked + .subject-chip__pill {
  background: #084c36;
  border-color: #084c36;
  color: #ffffff;
  font-weight: 600;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px -1px rgba(8, 76, 54, 0.25);
}

.subject-chip__input:focus-visible + .subject-chip__pill {
  outline: none;
  box-shadow: 0 0 0 3px rgba(8, 76, 54, 0.2);
  border-color: #084c36;
}

.contact-form .field-input--textarea {
  min-height: 8.5rem;
  line-height: 1.6;
  resize: vertical;
}

.contact-form__footer {
  margin-top: 1.75rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(8, 76, 54, 0.08);
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.contact-consent {
  background: #f8faf9;
  border: 1px solid rgba(8, 76, 54, 0.09);
  border-radius: 12px;
  padding: 0.85rem 1.15rem;
}

.contact-consent .form__note {
  font-size: 0.825rem;
  line-height: 1.6;
  color: #525f58;
  margin: 0;
}

.btn-contact-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: flex-start;
  min-width: 140px;
  padding: 0.85rem 2rem;
  background: #084c36;
  color: #ffffff;
  border-radius: 12px;
  font-size: 0.975rem;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.15);
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 14px -2px rgba(8, 76, 54, 0.25);
}

.btn-contact-submit:hover {
  background: #17754c;
  transform: translateY(-2px);
  box-shadow: 0 8px 22px -4px rgba(8, 76, 54, 0.35);
}

.btn-contact-submit:active {
  transform: translateY(0);
}

@media (max-width: 639px) {
  .btn-contact-submit {
    width: 100%;
  }
}

/* ==========================================================================
   Event Registration Modal Overlay
   ========================================================================== */
body.modal-open {
  overflow: hidden !important;
}

.event-reg-modal__backdrop {
  position: fixed;
  inset: 0;
  background: rgba(10, 25, 20, 0.65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 9998;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.event-reg-modal__backdrop.is-visible {
  opacity: 1;
}

.event-reg-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  border: none;
  background: transparent;
  width: 100%;
  max-width: 100vw;
  height: 100%;
  max-height: 100vh;
  margin: 0;
  overflow: hidden;
  box-sizing: border-box;
}

.event-reg-modal.is-open {
  display: flex;
}

.event-reg-modal__dialog {
  position: relative;
  width: 100%;
  max-width: 680px;
  max-height: min(90vh, 840px);
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border-radius: var(--radius-xl, 16px);
  border: 1px solid rgba(8, 76, 54, 0.12);
  box-shadow: 0 25px 50px -12px rgba(8, 76, 54, 0.25), 0 0 0 1px rgba(8, 76, 54, 0.08);
  overflow: hidden;
  animation: modalSlideIn 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.event-reg-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.75rem;
  border-bottom: 1px solid rgba(8, 76, 54, 0.08);
  background: #ffffff;
  flex-shrink: 0;
  gap: 1rem;
}

.event-reg-modal__header-text {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 0;
}

.event-reg-modal__badge {
  display: inline-block;
  align-self: flex-start;
  font-size: 0.75rem;
  font-weight: 700;
  color: #084c36;
  background: rgba(8, 76, 54, 0.08);
  border-radius: 9999px;
  padding: 0.2rem 0.65rem;
  letter-spacing: 0.02em;
}

.event-reg-modal__title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-ink, #1f2937);
  margin: 0;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.event-reg-modal__close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(8, 76, 54, 0.12);
  background: #f8faf9;
  color: #525f58;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
  padding: 0;
}

.event-reg-modal__close:hover {
  background: #eef3f0;
  color: #084c36;
  border-color: #084c36;
  transform: scale(1.05);
}

.event-reg-modal__close:focus-visible {
  outline: 2px solid #084c36;
  outline-offset: 2px;
}

.event-reg-modal__body {
  padding: 1.5rem 1.75rem 2rem;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  flex: 1 1 auto;
  min-height: 200px;
}

.event-reg-modal__loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3.5rem 1rem;
  gap: 1.25rem;
  color: #525f58;
  font-size: 0.95rem;
  font-weight: 500;
  text-align: center;
}

.event-reg-modal__spinner {
  width: 42px;
  height: 42px;
  border: 3.5px solid rgba(8, 76, 54, 0.15);
  border-top-color: #084c36;
  border-radius: 50%;
  animation: modalSpin 0.75s linear infinite;
}

@keyframes modalSpin {
  to {
    transform: rotate(360deg);
  }
}

.event-reg-modal__success-icon {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #d1fae5;
  color: #059669;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.85rem;
  font-weight: 700;
  margin-inline: auto;
  margin-bottom: 1rem;
  box-shadow: 0 4px 12px rgba(5, 150, 105, 0.2);
}

@media (max-width: 639px) {
  .event-reg-modal {
    padding: 0.5rem;
  }

  .event-reg-modal__dialog {
    max-height: 94vh;
    border-radius: 14px;
  }

  .event-reg-modal__header {
    padding: 1rem 1.25rem;
  }

  .event-reg-modal__body {
    padding: 1.25rem 1.25rem 1.5rem;
  }

  .event-reg-modal__title {
    font-size: 1.1rem;
  }
}