:root {
  --bg: #e7e1cf;
  --paper: rgba(249, 244, 235, 0.82);
  --ink: #223028;
  --muted: #5b6758;
  --accent: #78824a;
  --accent-deep: #2f4a34;
  --warm-brown: #bc9561;
  --warm-brown-soft: #ead7ba;
  --line: rgba(34, 48, 40, 0.12);
  --shadow: 0 24px 60px rgba(34, 48, 40, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Outfit", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.42), transparent 30%),
    radial-gradient(circle at 82% 16%, rgba(188, 149, 97, 0.46), transparent 28%),
    linear-gradient(135deg, #dde1cd 0%, #f4efe4 42%, #ead7ba 70%, #c8cfb0 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.12) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.12) 1px, transparent 1px);
  background-size: 36px 36px;
  opacity: 0.26;
  pointer-events: none;
}

.page-shell {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 20px 72px;
}

.hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 28px;
  align-items: center;
}

.hero-copy,
.hero-visual,
.panel,
.section-nav {
  backdrop-filter: blur(16px);
}

.hero-copy,
.hero-visual,
.panel {
  background: var(--paper);
  border: 1px solid rgba(255, 248, 237, 0.72);
  border-radius: 32px;
  box-shadow: var(--shadow);
}

.hero-copy {
  padding: 48px;
}

.eyebrow,
.card-label,
.time {
  margin: 0 0 12px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent-deep);
}

h1,
h2 {
  margin: 0;
  font-family: "Cormorant Garamond", serif;
  font-weight: 600;
  line-height: 0.95;
}

h1 {
  font-size: clamp(4rem, 8vw, 7rem);
  max-width: 9ch;
}

h1 span {
  color: var(--accent);
}

.hero-meta,
.hero-location {
  margin: 16px 0 0;
  font-size: 1.1rem;
  color: var(--muted);
}

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

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 20px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 500;
  text-decoration: none;
  transition: transform 160ms ease, background-color 160ms ease, border-color 160ms ease;
}

.button:hover,
.tab:hover {
  transform: translateY(-1px);
}

.button-primary {
  color: #fffaf4;
  background: var(--accent-deep);
}

.button-secondary {
  color: var(--ink);
  border-color: var(--line);
  background: rgba(234, 215, 186, 0.72);
}

.hero-visual {
  position: relative;
  min-height: 560px;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(24, 32, 26, 0.18), rgba(24, 32, 26, 0.02)),
    linear-gradient(0deg, rgba(47, 74, 52, 0.18), rgba(188, 149, 97, 0.24)),
    url("./assets/hero.jpg") center 38% / cover no-repeat;
}

.hero-visual::before,
.hero-visual::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 243, 214, 0.22);
  filter: blur(16px);
}

.hero-visual::before {
  width: 240px;
  height: 240px;
  top: -40px;
  right: -60px;
}

.hero-visual::after {
  width: 180px;
  height: 180px;
  bottom: 80px;
  left: -50px;
}

.photo-card {
  position: absolute;
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(2px);
}

.photo-card-large {
  inset: 34px 42px 106px 52px;
}

.photo-card-small {
  width: 180px;
  height: 220px;
  right: 40px;
  bottom: 44px;
  background: rgba(234, 220, 196, 0.16);
}

.hero-note {
  position: absolute;
  left: 40px;
  bottom: 32px;
  max-width: 260px;
  padding: 18px 20px;
  border-radius: 20px;
  background: rgba(250, 244, 232, 0.84);
  border: 1px solid rgba(255, 255, 255, 0.48);
}

.hero-note p,
.card p,
.faq-item p,
.timeline-item p {
  margin: 0;
  line-height: 1.65;
  color: var(--muted);
}

.section-nav {
  position: sticky;
  top: 14px;
  z-index: 10;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  width: fit-content;
  max-width: 100%;
  margin: 28px auto 24px;
  padding: 12px;
  border-radius: 999px;
  background: rgba(255, 249, 243, 0.76);
  border: 1px solid rgba(255, 255, 255, 0.68);
  box-shadow: var(--shadow);
}

.tab {
  border: 0;
  border-radius: 999px;
  padding: 12px 18px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  cursor: pointer;
  transition: transform 160ms ease, color 160ms ease, background-color 160ms ease;
}

.tab.is-active {
  color: #fffaf4;
  background: var(--accent);
}

.panel {
  display: none;
  padding: 28px;
  animation: rise 280ms ease;
}

.panel.is-active {
  display: block;
}

.panel-grid,
.split-panel,
.gallery-grid,
.timeline,
.form-grid {
  display: grid;
  gap: 20px;
}

.details-layout,
.details-highlights {
  display: grid;
  gap: 20px;
}

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

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

.card,
.faq-item,
.timeline-item {
  padding: 28px;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid var(--line);
}

.card h2,
.faq-item h2,
.timeline-item h2 {
  margin-bottom: 12px;
  font-size: clamp(2rem, 4vw, 3rem);
}

.detail-card {
  min-height: 100%;
}

.detail-card h2 {
  font-size: clamp(1.85rem, 3vw, 2.7rem);
}

.detail-directions {
  padding-top: 24px;
}

.detail-directions .card-label {
  margin-bottom: 8px;
}

.detail-directions h2 {
  font-size: clamp(2.2rem, 4vw, 3.2rem);
}

.card-wide {
  grid-column: 1 / -1;
}

.split-panel {
  grid-template-columns: 1.2fr 0.8fr;
}

.story-panel {
  display: grid;
  gap: 20px;
}

.photos-panel {
  max-width: 820px;
  margin: 0 auto;
}

#story.panel {
  padding-block: 20px;
}

.story-card {
  max-width: 920px;
  min-height: 320px;
  margin: 0 auto;
}

.story-card p + p {
  margin-top: 16px;
}

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

.gallery-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-auto-rows: 180px;
}

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

.gallery-tile {
  position: relative;
  overflow: hidden;
  border-radius: 26px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0), rgba(41, 27, 18, 0.22)),
    linear-gradient(140deg, #e7ead8, #9da870 48%, #415439 100%);
  box-shadow: var(--shadow);
}

.gallery-tile span {
  position: absolute;
  left: 18px;
  bottom: 16px;
  color: #fff8f1;
  font-family: "Cormorant Garamond", serif;
  font-size: 1.8rem;
}

.gallery-tile-tall {
  grid-row: span 2;
}

.gallery-tile-wide {
  grid-column: span 2;
}

.timeline-item {
  min-height: 240px;
}

.form-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
  margin-top: 24px;
}

.field {
  display: grid;
  gap: 8px;
}

.field span {
  display: block;
  min-height: 1.2em;
  font-size: 0.9rem;
  color: var(--muted);
}

.field-full {
  grid-column: 1 / -1;
}

.field-hidden {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.78);
  color: var(--ink);
  font: inherit;
}

.field input:disabled,
.field select:disabled,
.field textarea:disabled,
.button:disabled {
  cursor: not-allowed;
  opacity: 0.6;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: 2px solid rgba(175, 93, 66, 0.25);
  outline-offset: 1px;
}

.status-line,
.helper-text {
  margin: 16px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

.status-line.is-error {
  color: #8f2d1f;
}

.selected-photo-list {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 0.92rem;
}

.selected-photo-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.52);
}

.selected-photo-item span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.selected-photo-item button {
  border: 0;
  border-radius: 999px;
  padding: 8px 12px;
  color: #fffaf4;
  background: var(--accent-deep);
  font: inherit;
  cursor: pointer;
}

.upload-qr-shell {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: center;
  margin-top: 18px;
}

.upload-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.upload-qr {
  width: 220px;
  height: 220px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--line);
  padding: 14px;
}

.upload-qr-copy {
  flex: 1 1 220px;
}

.inline-link {
  color: var(--accent-deep);
  word-break: break-word;
}

.page-shell-narrow {
  max-width: 760px;
}

.upload-layout {
  padding-top: 32px;
}

.upload-layout .panel {
  padding: 28px;
}

.upload-layout .card {
  padding: 32px;
}

.upload-title {
  margin-bottom: 24px;
  font-size: clamp(3rem, 7vw, 5rem);
}

.upload-copy {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.upload-layout .form-grid {
  margin-top: 28px;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 960px) {
  .hero,
  .split-panel,
  .faq-list,
  .timeline,
  .panel-grid,
  .gallery-grid,
  .details-highlights,
  .form-grid {
    grid-template-columns: 1fr;
  }

  .hero-visual {
    min-height: 420px;
  }

  .photo-card-large {
    inset: 26px 24px 110px 24px;
  }

  .photo-card-small {
    width: 140px;
    height: 170px;
  }

  .gallery-tile-wide,
  .card-wide {
    grid-column: auto;
  }
}

@media (max-width: 640px) {
  .page-shell {
    padding-inline: 14px;
  }

  .hero-copy,
  .panel {
    padding: 22px;
  }

  .upload-layout {
    padding-top: 18px;
  }

  .upload-layout .panel {
    padding: 18px;
  }

  .upload-layout .card {
    padding: 24px;
  }

  .hero {
    gap: 18px;
  }

  .hero-visual {
    min-height: 360px;
  }

  .hero-note {
    left: 18px;
    right: 18px;
    bottom: 18px;
    max-width: none;
  }

  .section-nav {
    justify-content: center;
    border-radius: 28px;
  }

  .tab {
    flex: 1 1 calc(50% - 12px);
    text-align: center;
  }
}
