:root {
  --bg: #f5f1e8;
  --ink: #172018;
  --muted: #65705f;
  --leaf: #315c3a;
  --sun: #d49b3f;
  --paper: #fffaf0;
  --line: rgba(23, 32, 24, 0.14);
  --shadow: 0 20px 45px rgba(23, 32, 24, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font-family: Arial, Helvetica, sans-serif;
}

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

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

button {
  font: inherit;
  cursor: pointer;
}

.site-header {
  min-height: 72vh;
  color: white;
  background:
    linear-gradient(90deg, rgba(13, 24, 13, 0.82), rgba(13, 24, 13, 0.2)),
    url("wildlife_images/001.JPG") center / cover;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0;
}

.brand {
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.nav__links {
  display: flex;
  gap: 10px;
}

.nav__links a {
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.32);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.92rem;
}

.hero {
  display: grid;
  align-items: end;
  width: min(1120px, calc(100% - 32px));
  min-height: calc(72vh - 82px);
  margin: 0 auto;
  padding: 72px 0;
}

.hero__content {
  max-width: 760px;
}

.hero__signature {
  margin: 0 0 18px;
  color: #fff7df;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.5rem, 7vw, 6rem);
  font-weight: 600;
  line-height: 0.95;
  text-shadow: 0 5px 24px rgba(0, 0, 0, 0.48);
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--sun);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

h1,
h2 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 600;
  line-height: 1;
}

h1 {
  max-width: 680px;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(1.55rem, 3vw, 2.8rem);
  line-height: 1.12;
}

.hero p:last-child {
  max-width: 590px;
  margin: 22px 0 0;
  color: rgba(255, 255, 255, 0.84);
  font-size: clamp(1rem, 2vw, 1.25rem);
  line-height: 1.7;
}

.about {
  display: grid;
  grid-template-columns: minmax(260px, 0.85fr) minmax(0, 1.15fr);
  gap: 42px;
  align-items: center;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 78px 0 64px;
}

.about__media {
  overflow: hidden;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.about__media img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

.about__content h2 {
  max-width: 680px;
  font-size: clamp(2.2rem, 5vw, 4.6rem);
}

.about__content p:not(.eyebrow) {
  max-width: 680px;
  margin: 20px 0 0;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.8;
}

.gallery-block {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 72px 0;
}

.gallery-block--light {
  border-top: 1px solid var(--line);
}

.section-title {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 26px;
}

.section-title h2 {
  font-size: clamp(2.2rem, 5vw, 4.5rem);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

#illustrationGrid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.gallery-card {
  position: relative;
  min-height: 270px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: var(--shadow);
}

.gallery-card:nth-child(5n + 1) {
  grid-column: span 2;
}

#illustrationGrid .gallery-card {
  min-height: 210px;
}

#illustrationGrid .gallery-card:nth-child(5n + 1) {
  grid-column: span 1;
}

.gallery-card button {
  width: 100%;
  height: 100%;
  min-height: inherit;
  border: 0;
  padding: 0;
  background: transparent;
}

.gallery-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 250ms ease, filter 250ms ease;
}

.gallery-card:hover img {
  filter: saturate(1.06);
  transform: scale(1.04);
}

.gallery-card__label {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  padding: 9px 10px;
  border-radius: 6px;
  color: white;
  background: rgba(12, 18, 12, 0.72);
  font-size: 0.82rem;
  font-weight: 700;
  text-align: left;
}

.footer {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 42px;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.footer p {
  margin: 0;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: none;
  place-items: center;
  padding: 72px 18px 32px;
  background: rgba(0, 0, 0, 0.86);
}

.lightbox.is-open {
  display: grid;
}

.lightbox img {
  width: min(100%, 1050px);
  max-height: 78vh;
  object-fit: contain;
  border-radius: 8px;
  background: #111;
}

.lightbox p {
  margin: 14px 0 0;
  color: white;
  font-weight: 700;
}

.lightbox__close {
  position: absolute;
  top: 20px;
  right: 20px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
  padding: 10px 14px;
  color: white;
  background: rgba(255, 255, 255, 0.12);
}

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

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

@media (max-width: 640px) {
  .site-header {
    min-height: 82vh;
  }

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

  .hero {
    min-height: calc(82vh - 130px);
  }

  .section-title {
    align-items: flex-start;
    flex-direction: column;
  }

  .about {
    grid-template-columns: 1fr;
    gap: 28px;
    padding: 58px 0 42px;
  }

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

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

  .gallery-card,
  .gallery-card:nth-child(5n + 1) {
    grid-column: span 1;
  }

  #illustrationGrid .gallery-card {
    min-height: 170px;
  }
}
