:root {
  --paper: #f6efe6;
  --paper-strong: #efe2d2;
  --ink: #35261f;
  --muted: #715a4e;
  --rose: #d90a72;
  --rose-soft: #f2bfd8;
  --card: rgba(255, 250, 245, 0.78);
  --line: rgba(83, 49, 37, 0.14);
  --shadow: 0 24px 60px rgba(77, 39, 49, 0.14);
  --radius-lg: 32px;
  --radius-md: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: "Avenir Next", Avenir, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(217, 10, 114, 0.1), transparent 28%),
    radial-gradient(circle at right 20%, rgba(192, 143, 84, 0.14), transparent 24%),
    linear-gradient(180deg, #fbf5ee 0%, var(--paper) 100%);
}

body.lightbox-open {
  overflow: hidden;
}

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

a {
  color: inherit;
}

code {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 0.92em;
}

.page-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 80px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 12px 0 28px;
}

.brand,
.topbar-links a {
  text-decoration: none;
}

.brand {
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", serif;
  font-size: 1.25rem;
  letter-spacing: 0.04em;
}

.topbar-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  color: var(--muted);
}

.hero {
  position: relative;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.9fr;
  gap: 36px;
  align-items: center;
  padding: 36px 0 28px;
}

.hero-copy h1,
.section-heading h2,
.contact-card h2 {
  margin: 0;
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", serif;
  font-weight: 600;
  line-height: 0.98;
}

.hero-copy h1 {
  max-width: 10ch;
  font-size: clamp(3.6rem, 8vw, 6.8rem);
}

.lead,
.story-grid p,
.contact-card p,
.gallery-toolbar,
.mark-note {
  max-width: 65ch;
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.7;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--rose);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero-actions,
.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 22px;
  border-radius: 999px;
  text-decoration: none;
  transition: transform 180ms ease, box-shadow 180ms ease, background-color 180ms ease;
}

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

.button-primary {
  background: var(--rose);
  color: #fff7fb;
  box-shadow: 0 16px 36px rgba(217, 10, 114, 0.24);
}

.button-secondary {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.54);
}

.hero-mark {
  display: grid;
  gap: 18px;
}

.logo-frame,
.contact-card,
.gallery-grid a,
.story {
  border: 1px solid var(--line);
  background: var(--card);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

.logo-frame {
  justify-self: end;
  width: min(100%, 320px);
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

.logo-frame img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 50%;
}

.section {
  padding-top: 72px;
}

.section-heading {
  display: grid;
  gap: 8px;
  margin-bottom: 28px;
}

.section-heading h2 {
  font-size: clamp(2rem, 4vw, 3.4rem);
}

.story {
  padding: 28px;
  border-radius: var(--radius-lg);
}

.story-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px 32px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  align-items: start;
}

.gallery-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 22px;
}

.gallery-filter {
  min-height: 50px;
  padding: 0 22px;
  border: 1px solid rgba(83, 49, 37, 0.16);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.96);
  color: var(--ink);
  font: inherit;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(77, 39, 49, 0.08);
  transition:
    background-color 160ms ease,
    color 160ms ease,
    border-color 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
}

.gallery-filter:hover {
  transform: translateY(-1px);
  border-color: rgba(217, 10, 114, 0.22);
  box-shadow: 0 14px 28px rgba(77, 39, 49, 0.12);
}

.gallery-filter.is-active {
  border-color: var(--rose);
  background: var(--rose);
  color: #fff7fb;
  box-shadow: 0 16px 32px rgba(217, 10, 114, 0.24);
}

.gallery-filter:focus-visible {
  outline: 0;
  border-color: rgba(217, 10, 114, 0.38);
  box-shadow:
    0 0 0 4px rgba(242, 191, 216, 0.55),
    0 16px 32px rgba(77, 39, 49, 0.12);
}

.gallery-more-wrap {
  display: flex;
  justify-content: center;
  margin-top: 10px;
}

.gallery-more-wrap[hidden] {
  display: none;
}

.gallery-grid a {
  display: block;
  width: 100%;
  margin-bottom: 0;
  padding: 10px;
  border-radius: var(--radius-md);
  text-decoration: none;
  min-height: 100%;
}

.gallery-grid figure {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 0;
  margin: 0;
  min-height: 100%;
}

.gallery-grid img {
  width: 100%;
  aspect-ratio: 4 / 3;
  height: auto;
  border-radius: 16px;
  object-fit: cover;
}

.gallery-grid figcaption {
  padding: 12px 6px 4px;
  color: var(--muted);
  font-size: 0.92rem;
}

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

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(32, 17, 23, 0.78);
}

.lightbox-dialog {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  width: min(1100px, calc(100% - 28px));
  height: 100%;
  margin: 0 auto;
}

.lightbox-figure {
  margin: 0;
  display: grid;
  justify-items: center;
  gap: 14px;
}

.lightbox-figure img {
  max-width: 100%;
  max-height: min(78vh, 900px);
  border-radius: 24px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.28);
}

.lightbox-figure figcaption {
  color: #fff5fa;
  font-size: 1rem;
  text-align: center;
}

.lightbox-close,
.lightbox-nav {
  border: 0;
  cursor: pointer;
  color: #fff8fb;
  background: linear-gradient(180deg, #e1147a 0%, #c40663 100%);
  box-shadow: 0 18px 40px rgba(217, 10, 114, 0.28);
}

.lightbox-close {
  position: absolute;
  top: 22px;
  right: 8px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  font-size: 2rem;
  line-height: 1;
}

.lightbox-nav {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  font-size: 2.5rem;
  line-height: 1;
}

.lightbox-nav:hover,
.lightbox-close:hover {
  transform: translateY(-1px);
  filter: saturate(1.05);
}

.empty-gallery {
  display: grid;
  place-items: center;
  min-height: 280px;
  padding: 36px;
  border: 1px dashed rgba(83, 49, 37, 0.22);
  border-radius: var(--radius-lg);
  color: var(--muted);
  text-align: center;
  background: rgba(255, 255, 255, 0.36);
  grid-column: 1 / -1;
}

.empty-gallery p {
  max-width: 30ch;
  margin: 10px auto 18px;
}

.gallery-grid.is-empty {
  grid-template-columns: minmax(0, 1fr);
}

.contact-card {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  padding: 32px;
  border-radius: 36px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.7), rgba(242, 191, 216, 0.5)),
    var(--card);
}

@media (max-width: 900px) {
  .hero-grid,
  .story-grid,
  .contact-card {
    grid-template-columns: 1fr;
    display: grid;
  }

  .logo-frame {
    justify-self: start;
  }

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

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

@media (max-width: 640px) {
  .page-shell {
    width: min(100% - 20px, 1180px);
  }

  .hero-copy h1 {
    max-width: 12ch;
    font-size: clamp(2.8rem, 15vw, 4.3rem);
  }

  .story,
  .contact-card,
  .logo-frame {
    padding: 20px;
  }

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

  .lightbox-dialog {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 84px 0 24px;
  }

  .lightbox-nav {
    width: 54px;
    height: 54px;
    font-size: 2rem;
  }

  .lightbox-prev,
  .lightbox-next {
    justify-self: center;
  }
}
