:root {
  --bg: #f4fbf2;
  --bg-soft: #edf8e8;
  --surface: rgba(255, 255, 255, 0.78);
  --surface-strong: rgba(255, 255, 255, 0.96);
  --text: #173722;
  --muted: #51705c;
  --line: rgba(35, 111, 69, 0.14);
  --primary: #2e9d57;
  --primary-strong: #177442;
  --accent: #b7eb6f;
  --shadow: 0 24px 60px rgba(26, 76, 47, 0.12);
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 14px;
  --max-width: 1220px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(183, 235, 111, 0.48), transparent 30%),
    radial-gradient(circle at top right, rgba(46, 157, 87, 0.12), transparent 26%),
    linear-gradient(180deg, #f8fdf6 0%, #eef8ea 48%, #f6fbf5 100%);
  min-height: 100vh;
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: auto;
  pointer-events: none;
  z-index: -1;
  width: 32rem;
  height: 32rem;
  border-radius: 50%;
  filter: blur(20px);
}

body::before {
  top: -9rem;
  right: -11rem;
  background: rgba(183, 235, 111, 0.34);
}

body::after {
  bottom: -13rem;
  left: -12rem;
  background: rgba(46, 157, 87, 0.16);
}

img,
video {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea,
select {
  font: inherit;
}

.site-shell {
  min-height: 100vh;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(18px);
  background: rgba(244, 251, 242, 0.78);
  border-bottom: 1px solid rgba(35, 111, 69, 0.08);
}

.header-shell,
.footer-shell,
#page-root {
  width: min(calc(100% - 2rem), var(--max-width));
  margin: 0 auto;
}

.header-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
}

.brand,
.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.brand-mark {
  width: 2.9rem;
  height: 2.9rem;
  flex: 0 0 auto;
  border-radius: 1.2rem;
  background:
    radial-gradient(circle at 35% 35%, #dffd9a 0, #dffd9a 18%, transparent 20%),
    linear-gradient(145deg, #2fa85b, #1f7b46);
  box-shadow:
    inset 0 1px 1px rgba(255, 255, 255, 0.6),
    0 12px 24px rgba(23, 116, 66, 0.18);
  position: relative;
}

.brand-mark::before,
.brand-mark::after {
  content: "";
  position: absolute;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 999px;
}

.brand-mark::before {
  width: 0.8rem;
  height: 1.6rem;
  left: 1.2rem;
  top: 0.55rem;
  transform: rotate(28deg);
}

.brand-mark::after {
  width: 0.7rem;
  height: 1.25rem;
  left: 0.78rem;
  top: 1rem;
  transform: rotate(-26deg);
}

.brand-copy {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.brand-copy strong {
  font-family: "Palatino Linotype", "Book Antiqua", serif;
  font-size: 1.1rem;
  letter-spacing: 0.03em;
}

.brand-copy span:last-child {
  color: var(--muted);
  font-size: 0.85rem;
  max-width: 25rem;
}

.main-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.45rem;
}

.nav-link {
  padding: 0.72rem 0.9rem;
  border-radius: 999px;
  color: var(--muted);
  transition: 180ms ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: var(--primary-strong);
  background: rgba(46, 157, 87, 0.1);
}

.lang-toggle {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(46, 157, 87, 0.1);
  box-shadow: 0 8px 18px rgba(31, 123, 70, 0.08);
}

.lang-button {
  width: 2.55rem;
  height: 2.55rem;
  border: 0;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  transition: transform 180ms ease, background 180ms ease, box-shadow 180ms ease;
  font-size: 1.1rem;
}

.lang-button:hover,
.lang-button.is-active {
  transform: translateY(-1px);
  background: rgba(46, 157, 87, 0.13);
  box-shadow: inset 0 0 0 1px rgba(46, 157, 87, 0.15);
}

#page-root {
  padding: 2rem 0 4rem;
}

.hero,
.section,
.gallery-block {
  margin-bottom: 1.6rem;
}

.hero,
.feature-card,
.stat-card,
.stack-card,
.team-card,
.timeline-step,
.media-card,
.source-link,
.gallery-block,
.feature-card--resource {
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.hero {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1.35fr 0.95fr;
  gap: 2rem;
  padding: clamp(1.6rem, 3vw, 2.8rem);
  border-radius: var(--radius-xl);
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 1.2rem -4.8rem auto;
  width: 15rem;
  height: 15rem;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(183, 235, 111, 0.45), transparent 65%);
}

.hero-copy h1,
.section-head h2,
.product-copy h2,
.event-copy h2,
.team-copy h3,
.media-card h3,
.feature-card h3,
.feature-card h2 {
  font-family: "Palatino Linotype", "Book Antiqua", serif;
  margin: 0;
  line-height: 1.04;
}

.hero-copy h1 {
  font-size: clamp(2.2rem, 5vw, 4.5rem);
  max-width: 15ch;
}

.hero--page .hero-copy h1 {
  max-width: 17ch;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.36rem 0.75rem;
  border-radius: 999px;
  background: rgba(46, 157, 87, 0.1);
  color: var(--primary-strong);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.72rem;
  font-weight: 700;
}

.lead {
  margin: 1rem 0 0;
  max-width: 64ch;
  font-size: 1.08rem;
  line-height: 1.72;
  color: var(--muted);
}

.lead--compact {
  max-width: 70ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 1.3rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 3rem;
  padding: 0.85rem 1.2rem;
  border-radius: 999px;
  border: 1px solid transparent;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button--primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-strong));
  color: #fff;
  box-shadow: 0 18px 28px rgba(23, 116, 66, 0.2);
}

.button--ghost {
  background: rgba(255, 255, 255, 0.72);
  border-color: rgba(46, 157, 87, 0.16);
  color: var(--primary-strong);
}

.hero-visual {
  display: grid;
  gap: 1rem;
  align-content: start;
}

.hero-stat-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.stat-card {
  padding: 1.15rem;
  border-radius: var(--radius-lg);
}

.stat-card strong {
  display: block;
  font-size: clamp(1.8rem, 5vw, 2.6rem);
  color: var(--primary-strong);
  margin-bottom: 0.35rem;
}

.stat-card span {
  color: var(--muted);
  line-height: 1.4;
}

.hero-logo-card {
  padding: 1.2rem;
  border-radius: var(--radius-lg);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.88), rgba(246, 255, 240, 0.7)),
    radial-gradient(circle at bottom right, rgba(183, 235, 111, 0.22), transparent 58%);
  border: 1px solid var(--line);
}

.hero-logo-card img {
  width: min(100%, 18rem);
  margin: 0 auto;
}

.section {
  padding: 1.6rem 0 0;
}

.section-head {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-bottom: 1rem;
}

.section-head h2 {
  font-size: clamp(1.7rem, 4vw, 3rem);
  max-width: 18ch;
}

.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.chip {
  padding: 0.9rem 1rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(46, 157, 87, 0.1);
  box-shadow: 0 10px 20px rgba(23, 116, 66, 0.06);
}

.grid {
  display: grid;
  gap: 1rem;
}

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

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

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

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

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

.feature-card,
.stack-card,
.media-card {
  padding: 1.3rem;
  border-radius: var(--radius-lg);
}

.feature-card p,
.team-copy p,
.event-copy p,
.product-copy p,
.stack-card p {
  margin: 0;
  line-height: 1.72;
  color: var(--muted);
}

.feature-card h3,
.feature-card h2,
.media-card h3 {
  margin-bottom: 0.55rem;
  font-size: 1.32rem;
}

.feature-card--tall {
  min-height: 100%;
}

.feature-card--resource,
.feature-card--list {
  height: 100%;
}

.text-link {
  display: inline-flex;
  margin-top: 1rem;
  color: var(--primary-strong);
  font-weight: 700;
}

.stack-list {
  display: grid;
  gap: 0.9rem;
}

.stack-card {
  border-radius: var(--radius-md);
}

.clean-list {
  margin: 0;
  padding-left: 1.15rem;
  color: var(--muted);
  line-height: 1.68;
}

.clean-list li + li {
  margin-top: 0.38rem;
}

.timeline-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.timeline-step {
  padding: 1.2rem;
  border-radius: var(--radius-lg);
}

.timeline-step strong {
  display: block;
  margin-bottom: 0.65rem;
  color: var(--primary);
  font-size: 1.25rem;
}

.product-layout,
.event-layout {
  display: grid;
  gap: 1.2rem;
  align-items: start;
}

.product-layout {
  grid-template-columns: minmax(0, 0.94fr) minmax(0, 1.06fr);
}

.event-layout {
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
}

.product-copy,
.event-copy {
  display: grid;
  gap: 1rem;
}

.info-block {
  padding: 1rem 1.05rem;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(46, 157, 87, 0.08);
}

.info-block h3 {
  margin: 0 0 0.45rem;
  font-size: 1rem;
}

.contact-inline {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  color: var(--muted);
}

.event-topline {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-bottom: 0.9rem;
  color: var(--primary-strong);
  font-size: 0.9rem;
}

.carousel {
  position: relative;
  padding: 0 3rem;
}

.carousel-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(16rem, 28vw);
  gap: 0.9rem;
  overflow-x: auto;
  padding: 0.2rem 0 0.2rem;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.carousel-track::-webkit-scrollbar {
  display: none;
}

.carousel-slide {
  padding: 0;
  border: 0;
  background: transparent;
  cursor: zoom-in;
  scroll-snap-align: start;
  border-radius: calc(var(--radius-lg) - 2px);
  overflow: hidden;
  box-shadow: 0 18px 24px rgba(23, 116, 66, 0.08);
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  min-height: 15rem;
  object-fit: cover;
  transition: transform 220ms ease;
}

.carousel-slide:hover img {
  transform: scale(1.03);
}

.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 2.65rem;
  height: 2.65rem;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  color: var(--primary-strong);
  box-shadow: 0 14px 24px rgba(23, 116, 66, 0.16);
  cursor: pointer;
  z-index: 1;
}

.carousel-arrow--prev {
  left: 0.1rem;
}

.carousel-arrow--next {
  right: 0.1rem;
}

.carousel--hero .carousel-track {
  grid-auto-columns: minmax(18rem, 32vw);
}

.carousel--product .carousel-track {
  grid-auto-columns: minmax(14rem, 22rem);
}

.carousel--science .carousel-track {
  grid-auto-columns: minmax(18rem, 34vw);
}

.carousel--event .carousel-track,
.carousel--gallery .carousel-track {
  grid-auto-columns: minmax(17rem, 26vw);
}

.team-card {
  display: grid;
  grid-template-columns: 10rem 1fr;
  gap: 1rem;
  padding: 1.1rem;
  border-radius: var(--radius-lg);
}

.team-photo {
  padding: 0;
  border: 0;
  background: transparent;
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: zoom-in;
}

.team-photo img {
  width: 100%;
  height: 100%;
  min-height: 12rem;
  object-fit: cover;
}

.team-copy {
  display: grid;
  gap: 0.55rem;
  align-content: start;
}

.team-role {
  color: var(--primary-strong);
  font-weight: 700;
}

.team-meta {
  color: var(--muted);
  font-size: 0.94rem;
}

.gallery-block {
  padding: 1.2rem;
  border-radius: var(--radius-lg);
}

.gallery-copy {
  margin-bottom: 1rem;
}

.gallery-copy h3 {
  margin: 0 0 0.45rem;
  font-family: "Palatino Linotype", "Book Antiqua", serif;
  font-size: 1.4rem;
}

.gallery-copy p {
  margin: 0;
  color: var(--muted);
  line-height: 1.68;
}

.media-card h3 {
  margin-top: 0.8rem;
}

.video-frame {
  overflow: hidden;
  border-radius: var(--radius-md);
  box-shadow: inset 0 0 0 1px rgba(46, 157, 87, 0.08);
}

.video-frame video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #dfeedd;
}

.source-list {
  display: grid;
  gap: 0.65rem;
  margin-top: 0.65rem;
}

.source-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1rem;
  border-radius: var(--radius-md);
  transition: transform 180ms ease, background 180ms ease;
}

.source-link:hover {
  transform: translateX(4px);
  background: rgba(255, 255, 255, 0.94);
}

.icon-dot {
  width: 0.8rem;
  height: 0.8rem;
  border-radius: 50%;
  background: linear-gradient(180deg, var(--accent), var(--primary));
  display: inline-block;
  margin-bottom: 0.9rem;
}

.site-footer {
  padding: 0 0 2.5rem;
}

.footer-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.2rem 1.2rem 0;
  color: var(--muted);
}

.footer-brand p {
  margin: 0.2rem 0 0;
  max-width: 46rem;
  line-height: 1.6;
}

.footer-meta {
  display: grid;
  justify-items: end;
  gap: 0.3rem;
}

.image-modal {
  position: fixed;
  inset: 0;
  z-index: 50;
}

.image-modal[hidden] {
  display: none;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 23, 14, 0.66);
  backdrop-filter: blur(14px);
}

.modal-dialog {
  position: relative;
  z-index: 1;
  width: min(calc(100% - 2rem), 1100px);
  margin: 2rem auto;
  background: rgba(255, 255, 255, 0.92);
  border-radius: var(--radius-xl);
  padding: 1rem;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.28);
}

.modal-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.85rem;
}

.modal-caption {
  color: var(--muted);
}

.modal-close {
  border: 0;
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 50%;
  background: rgba(46, 157, 87, 0.12);
  color: var(--primary-strong);
  cursor: pointer;
}

.modal-dialog img {
  width: 100%;
  max-height: calc(100vh - 10rem);
  object-fit: contain;
  border-radius: var(--radius-lg);
}

.modal-open {
  overflow: hidden;
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 600ms ease, transform 600ms ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1100px) {
  .header-shell {
    flex-wrap: wrap;
  }

  .main-nav {
    order: 3;
    width: 100%;
    justify-content: flex-start;
  }

  .hero,
  .product-layout,
  .event-layout,
  .grid--team,
  .grid--cards,
  .grid--triptych,
  .grid--media,
  .grid--split,
  .timeline-strip {
    grid-template-columns: 1fr 1fr;
  }

  .hero {
    grid-template-columns: 1fr;
  }

  .carousel-track {
    grid-auto-columns: minmax(15rem, 70vw);
  }
}

@media (max-width: 760px) {
  .header-shell,
  .footer-shell,
  #page-root {
    width: min(calc(100% - 1.25rem), var(--max-width));
  }

  .brand {
    width: 100%;
  }

  .brand-copy span:last-child {
    max-width: none;
  }

  .hero,
  .team-card,
  .product-layout,
  .event-layout,
  .grid--cards,
  .grid--triptych,
  .grid--team,
  .grid--media,
  .grid--split,
  .timeline-strip {
    grid-template-columns: 1fr;
  }

  .hero-copy h1 {
    max-width: 100%;
    font-size: clamp(2rem, 10vw, 3.1rem);
  }

  .hero-stat-grid {
    grid-template-columns: 1fr 1fr;
  }

  .team-card {
    grid-template-columns: 1fr;
  }

  .team-photo img {
    min-height: 18rem;
  }

  .carousel {
    padding: 0;
  }

  .carousel-arrow {
    display: none;
  }

  .carousel-track {
    grid-auto-columns: minmax(15rem, 82vw);
  }

  .footer-shell {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-meta {
    justify-items: start;
  }
}
