:root {
  color-scheme: light;
  --forest: #14211d;
  --forest-soft: #26362f;
  --ivory: #f7f3eb;
  --paper: #fffcf6;
  --sand: #d8c9b1;
  --gold: #a8895c;
  --ink: #171b19;
  --muted: #67706b;
  --line: rgba(20, 33, 29, 0.15);
  --serif: Iowan Old Style, Baskerville, "Times New Roman", serif;
  --sans: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --shadow: 0 1.5rem 4rem rgba(20, 33, 29, 0.12);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--ivory); color: var(--ink); font-family: var(--sans); }
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
img { display: block; max-width: 100%; }

.skip-link {
  position: fixed;
  z-index: 100;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.7rem 1rem;
  color: var(--paper);
  background: var(--forest);
  transform: translateY(-180%);
}
.skip-link:focus { transform: translateY(0); }

.hero {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  min-height: 100svh;
  overflow: hidden;
  color: var(--paper);
  background: var(--forest);
}

.hero__picture,
.hero__picture img,
.hero__veil,
.hero__grain { position: absolute; inset: 0; width: 100%; height: 100%; }

.hero__picture { z-index: -3; }
.hero__picture img {
  object-fit: cover;
  object-position: 52% 41%;
  filter: saturate(0.86) contrast(1.03) brightness(0.91);
  transform: scale(1.01);
}
.hero__veil {
  z-index: -2;
  background:
    radial-gradient(circle at 72% 18%, rgba(42, 94, 113, 0.06), transparent 36%),
    linear-gradient(180deg, rgba(8, 15, 13, 0.28) 0%, rgba(8, 15, 13, 0.02) 36%, rgba(8, 15, 13, 0.88) 100%),
    linear-gradient(90deg, rgba(8, 15, 13, 0.42), transparent 62%);
}
.hero__grain {
  z-index: -1;
  opacity: 0.12;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.2'/%3E%3C/svg%3E");
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(100% - 3rem, 84rem);
  margin-inline: auto;
  padding-top: max(1.5rem, env(safe-area-inset-top));
}
.topbar p { margin: 0; font-size: 0.69rem; font-weight: 700; letter-spacing: 0.24em; }
.monogram {
  color: inherit;
  font-family: var(--serif);
  font-size: 1.55rem;
  font-weight: 600;
  letter-spacing: -0.08em;
  text-decoration: none;
}
.monogram span, .footer__mark span { color: #d8c39d; font-style: italic; font-weight: 400; }

.hero__content {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  width: min(100%, 84rem);
  margin-inline: auto;
  padding: 4rem clamp(1.5rem, 6vw, 5rem) max(5.75rem, calc(2.5rem + env(safe-area-inset-bottom)));
}
.eyebrow, .kicker {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin: 0 0 1rem;
  font-size: 0.68rem;
  font-weight: 760;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}
.eyebrow::before, .kicker::before { width: 2.6rem; height: 1px; background: currentColor; content: ""; }
.hero h1 {
  margin: 0;
  max-width: 8.3ch;
  font-family: var(--serif);
  font-size: clamp(3.7rem, 10vw, 8.5rem);
  font-weight: 400;
  line-height: 0.82;
  letter-spacing: -0.062em;
  text-wrap: balance;
}
.hero h1 em { color: #e2ceb0; font-weight: 400; }
.hero__intro {
  max-width: 36rem;
  margin: clamp(1.5rem, 3vw, 2.25rem) 0 0;
  font-family: var(--serif);
  font-size: clamp(1.07rem, 2vw, 1.35rem);
  line-height: 1.5;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2.1rem; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 2.5rem;
  min-width: 17rem;
  min-height: 4rem;
  padding: 0.9rem 1rem 0.9rem 1.3rem;
  border: 1px solid rgba(255,255,255,.46);
  border-radius: 999px;
  color: var(--paper);
  font-size: 0.75rem;
  font-weight: 760;
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
  transition: transform 180ms ease, background 180ms ease, color 180ms ease;
}
.button--light { border-color: var(--paper); color: var(--forest); background: var(--paper); }
.button--glass { background: rgba(16, 25, 22, 0.3); backdrop-filter: blur(14px); }
.button svg, .submit-button svg, .download-button svg {
  width: 1.45rem;
  height: 1.45rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.button:hover, .button:focus-visible { color: var(--forest); background: #fff; transform: translateY(-2px); outline: none; }
.button:focus-visible, button:focus-visible, a:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
.scroll-cue {
  position: absolute;
  right: clamp(1.5rem, 4vw, 3rem);
  bottom: max(1.45rem, env(safe-area-inset-bottom));
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: inherit;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-decoration: none;
  text-transform: uppercase;
}
.scroll-cue span { width: 2rem; height: 1px; background: currentColor; }

.section { padding: clamp(5rem, 10vw, 9rem) max(1.25rem, calc((100vw - 78rem) / 2)); }
.section-heading { margin-bottom: clamp(2.25rem, 5vw, 4rem); }
.section-heading h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(2.5rem, 6vw, 5.5rem);
  font-weight: 400;
  line-height: 0.98;
  letter-spacing: -0.045em;
}
.section-heading > p:last-child { margin: 1.25rem 0 0; color: var(--muted); font-family: var(--serif); font-size: 1.1rem; line-height: 1.65; }
.section-heading--center { max-width: 50rem; margin-inline: auto; text-align: center; }
.section-heading--center .kicker { justify-content: center; }
.section-heading--split { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(17rem, .7fr); align-items: end; gap: 3rem; }
.section-heading--split > p:last-child { margin: 0; }
.kicker { color: var(--gold); }

.upload-section { background: linear-gradient(180deg, #f7f3eb 0%, #f1eadf 100%); }
.upload-card {
  width: min(100%, 58rem);
  margin-inline: auto;
  padding: clamp(1rem, 3vw, 1.6rem);
  border: 1px solid rgba(168, 137, 92, 0.3);
  border-radius: 1.8rem;
  background: rgba(255, 252, 246, 0.9);
  box-shadow: var(--shadow);
}
.dropzone {
  display: flex;
  min-height: 20rem;
  padding: 2rem;
  border: 1px dashed rgba(20, 33, 29, 0.3);
  border-radius: 1.25rem;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  text-align: center;
  cursor: pointer;
  background:
    radial-gradient(circle at 50% 0%, rgba(216, 201, 177, 0.26), transparent 44%),
    var(--paper);
  transition: border-color 180ms ease, transform 180ms ease, background 180ms ease;
}
.dropzone:hover, .dropzone.is-dragging { border-color: var(--gold); background-color: #fff; transform: translateY(-2px); }
.dropzone input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.dropzone__icon {
  display: grid;
  width: 4rem;
  height: 4rem;
  margin-bottom: 1.3rem;
  border: 1px solid var(--line);
  border-radius: 50%;
  place-items: center;
  color: var(--forest);
  background: #fff;
}
.dropzone__icon svg { width: 1.7rem; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.dropzone strong { font-family: var(--serif); font-size: 1.65rem; font-weight: 500; }
.dropzone > span:not(.dropzone__icon) { margin-top: .35rem; color: var(--muted); }
.dropzone small { margin-top: 1.3rem; color: #858b87; font-size: .72rem; line-height: 1.5; }
.selection { padding: 1.25rem 0 0; }
.selection__head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0 .25rem .8rem; }
.selection__head p { margin: 0; font-size: .82rem; }
.text-button { padding: .4rem; border: 0; color: var(--muted); background: transparent; font-size: .76rem; cursor: pointer; text-decoration: underline; text-underline-offset: .2rem; }
.upload-list { display: grid; gap: .55rem; max-height: 19rem; overflow: auto; }
.upload-item { display: grid; grid-template-columns: 3rem minmax(0, 1fr) auto; align-items: center; gap: .9rem; padding: .65rem; border-radius: .8rem; background: #f4efe6; }
.upload-item img { width: 3rem; height: 3rem; border-radius: .55rem; object-fit: cover; background: #ddd5c8; }
.upload-item__copy { min-width: 0; }
.upload-item__copy strong { display: block; overflow: hidden; font-size: .76rem; text-overflow: ellipsis; white-space: nowrap; }
.upload-item__copy span { color: var(--muted); font-size: .68rem; }
.progress { height: .22rem; margin-top: .45rem; overflow: hidden; border-radius: 99px; background: rgba(20,33,29,.12); }
.progress span { display: block; width: 0; height: 100%; background: var(--gold); transition: width 120ms linear; }
.upload-item__state { color: var(--muted); font-size: .68rem; }
.upload-item.is-done .upload-item__state { color: #47735e; }
.upload-item.is-error .upload-item__state { color: #a24137; }
.verification { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; margin-top: 1rem; padding: 1.15rem 1rem; border: 1px solid var(--line); border-radius: 1rem; background: #fff; }
.verification strong { display: block; font-family: var(--serif); font-size: 1.05rem; font-weight: 600; }
.verification p { margin: .2rem 0 0; color: var(--muted); font-size: .72rem; }
.submit-button {
  display: flex;
  width: 100%;
  min-height: 4.25rem;
  margin-top: .9rem;
  padding: 1rem 1.25rem;
  border: 0;
  border-radius: 999px;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  color: #fff;
  background: var(--forest);
  cursor: pointer;
  font-size: .76rem;
  font-weight: 780;
  letter-spacing: .08em;
  text-transform: uppercase;
  transition: transform 180ms ease, opacity 180ms ease;
}
.submit-button:hover:not(:disabled) { transform: translateY(-2px); }
.submit-button:disabled { cursor: not-allowed; opacity: .42; }
.form-status { min-height: 1.25rem; margin: .75rem 0 0; color: var(--forest-soft); text-align: center; font-size: .78rem; }
.privacy-note { display: flex; align-items: center; justify-content: center; gap: .45rem; margin: .25rem 0 .2rem; color: var(--muted); text-align: center; font-size: .68rem; }
.privacy-note svg { flex: 0 0 auto; width: 1rem; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }

.gallery-section { background: var(--paper); }
.gallery-status { display: flex; min-height: 9rem; align-items: center; justify-content: center; gap: .75rem; color: var(--muted); font-family: var(--serif); }
.spinner { width: 1.1rem; height: 1.1rem; border: 1px solid var(--sand); border-top-color: var(--forest); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.gallery { columns: 4 15rem; column-gap: .75rem; }
.gallery-card { position: relative; display: block; width: 100%; margin: 0 0 .75rem; padding: 0; overflow: hidden; border: 0; border-radius: .8rem; break-inside: avoid; cursor: zoom-in; background: #e8e0d4; }
.gallery-card img { width: 100%; min-height: 10rem; object-fit: cover; transition: transform 450ms cubic-bezier(.2,.8,.2,1), filter 250ms ease; }
.gallery-card::after { position: absolute; inset: auto 0 0; height: 38%; content: ""; opacity: 0; background: linear-gradient(transparent, rgba(8,15,13,.58)); transition: opacity 220ms ease; }
.gallery-card:hover img, .gallery-card:focus-visible img { transform: scale(1.025); }
.gallery-card:hover::after, .gallery-card:focus-visible::after { opacity: 1; }
.gallery-card__hint { position: absolute; z-index: 1; right: .75rem; bottom: .65rem; color: #fff; opacity: 0; font-size: .65rem; letter-spacing: .08em; text-transform: uppercase; transform: translateY(.3rem); transition: opacity 220ms ease, transform 220ms ease; }
.gallery-card:hover .gallery-card__hint, .gallery-card:focus-visible .gallery-card__hint { opacity: 1; transform: none; }
.empty-gallery { grid-column: 1 / -1; padding: 5rem 1rem; border: 1px solid var(--line); border-radius: 1rem; color: var(--muted); text-align: center; font-family: var(--serif); font-size: 1.15rem; }
.load-more { display: block; min-width: 15rem; margin: 2rem auto 0; padding: 1rem 1.4rem; border: 1px solid var(--forest); border-radius: 999px; color: var(--forest); background: transparent; cursor: pointer; font-size: .72rem; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; }

footer { padding: 5rem 1.5rem max(3.5rem, env(safe-area-inset-bottom)); color: var(--paper); background: var(--forest); text-align: center; }
.footer__mark { margin: 0; font-family: var(--serif); font-size: 3rem; letter-spacing: -.08em; }
footer > p:nth-child(2) { margin: 1rem 0; font-family: var(--serif); font-size: 1.15rem; }
.footer__date { margin: 0; color: #c8b99e; font-size: .65rem; font-weight: 700; letter-spacing: .22em; }

.app-nav { display: none; }

.lightbox { width: 100%; max-width: none; height: 100%; max-height: none; margin: 0; padding: 0; border: 0; color: #fff; background: rgba(8, 14, 12, .96); }
.lightbox::backdrop { background: rgba(8,14,12,.76); backdrop-filter: blur(12px); }
.lightbox[open] { display: grid; grid-template-rows: minmax(0, 1fr) auto; }
.lightbox__stage { display: grid; min-height: 0; padding: 3.5rem 1.5rem 1rem; place-items: center; }
.lightbox__stage img { max-width: 100%; max-height: 100%; object-fit: contain; }
.lightbox__close { position: fixed; z-index: 2; top: max(1rem, env(safe-area-inset-top)); right: 1rem; display: grid; width: 2.75rem; height: 2.75rem; padding: 0 0 .2rem; border: 1px solid rgba(255,255,255,.3); border-radius: 50%; place-items: center; color: #fff; background: rgba(0,0,0,.24); cursor: pointer; font-family: var(--serif); font-size: 2rem; }
.lightbox__bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1rem max(1.25rem, calc((100vw - 70rem) / 2)) max(1rem, env(safe-area-inset-bottom)); border-top: 1px solid rgba(255,255,255,.12); }
.lightbox__bar strong { display: block; max-width: 55vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: var(--serif); font-weight: 500; }
.lightbox__bar span { display: block; margin-top: .2rem; color: rgba(255,255,255,.62); font-size: .68rem; }
.download-button { display: inline-flex; align-items: center; gap: .65rem; padding: .8rem 1rem; border: 1px solid rgba(255,255,255,.35); border-radius: 999px; color: #fff; text-decoration: none; font-size: .68rem; font-weight: 720; letter-spacing: .06em; text-transform: uppercase; }

@media (max-width: 720px) {
  .topbar { width: calc(100% - 2rem); }
  .hero__picture img { object-position: 55% 42%; }
  .hero__veil { background: linear-gradient(180deg, rgba(8,15,13,.18) 0%, rgba(8,15,13,.04) 38%, rgba(8,15,13,.9) 100%); }
  .hero__content { padding-inline: 1.25rem; padding-bottom: max(7.2rem, calc(6.4rem + env(safe-area-inset-bottom))); }
  .hero h1 { font-size: clamp(3.7rem, 19vw, 6.4rem); }
  .hero__actions { display: grid; }
  .button { min-width: 0; width: 100%; }
  .scroll-cue { display: none; }
  .section-heading--split { grid-template-columns: 1fr; gap: .5rem; }
  .verification { align-items: flex-start; flex-direction: column; }
  #upload-turnstile { max-width: 100%; overflow: hidden; }
  .lightbox__bar { align-items: stretch; flex-direction: column; }
  .lightbox__bar strong { max-width: calc(100vw - 2.5rem); }
  .download-button { justify-content: center; }
  footer { padding-bottom: max(8rem, calc(6rem + env(safe-area-inset-bottom))); }
  .app-nav {
    position: fixed;
    z-index: 45;
    right: 0;
    bottom: max(.7rem, env(safe-area-inset-bottom));
    left: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    width: min(calc(100% - 1.4rem), 25rem);
    margin-inline: auto;
    padding: .38rem;
    border: 1px solid rgba(20, 33, 29, .13);
    border-radius: 1.35rem;
    background: rgba(255, 252, 246, .9);
    box-shadow: 0 .8rem 2.7rem rgba(10, 18, 15, .23);
    backdrop-filter: blur(20px) saturate(1.25);
  }
  .app-nav a {
    display: flex;
    min-height: 3.55rem;
    border-radius: 1rem;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: .18rem;
    color: #68716c;
    font-size: .59rem;
    font-weight: 760;
    letter-spacing: .08em;
    text-decoration: none;
    text-transform: uppercase;
    transition: color 180ms ease, background 180ms ease, transform 180ms ease;
  }
  .app-nav a:active { transform: scale(.97); }
  .app-nav a.is-active { color: var(--paper); background: var(--forest); }
  .app-nav svg {
    width: 1.25rem;
    height: 1.25rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.55;
    stroke-linecap: round;
    stroke-linejoin: round;
  }
}

@media (max-width: 460px) {
  .section { padding-inline: 1rem; }
  .upload-card { padding: .7rem; border-radius: 1.35rem; }
  .dropzone { min-height: 17rem; padding: 1.2rem; }
  .selection__head { align-items: flex-start; }
  .privacy-note { align-items: flex-start; text-align: left; }
  .gallery { columns: 2 8.5rem; gap: .5rem; }
  .gallery-card { margin-bottom: .5rem; border-radius: .55rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
