@font-face {
  font-family: "DM Sans";
  src: url("/static/dm-sans.woff2") format("woff2");
  font-weight: 100 1000;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Cormorant Garamond";
  src: url("/static/cormorant-garamond.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #f8f6f0;
  --surface: #fffdf8;
  --ink: #292c24;
  --quiet: #5c6055;
  --green: #394a37;
  --green-bg: #e8eee3;
  --rule: #dcded2;
  --error: #8a2935;
  --accent: var(--green);
  --accent-ink: #fffdf8;
  --readable: "DM Sans", system-ui, sans-serif;
  --display: "Cormorant Garamond", Georgia, serif;
  font-family: var(--readable);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.5;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body { min-height: 100vh; margin: 0; }
h1, h2, p { margin: 0; }
a { color: inherit; }
a, button, input, textarea, select, summary { outline-offset: 3px; }
:focus-visible { outline: 2px solid var(--accent); }

h1 {
  font: 700 clamp(2.5rem, 6vw, 4rem) / 1 var(--display);
  letter-spacing: -.035em;
  overflow-wrap: anywhere;
}

h2 {
  font: 700 1.65rem/1.1 var(--display);
  letter-spacing: -.015em;
  overflow-wrap: anywhere;
}

button, input, select, textarea { font: inherit; }
button, summary { cursor: pointer; }
button:disabled { cursor: wait; opacity: .68; }

.skip-link {
  position: absolute;
  z-index: 10;
  top: .5rem;
  left: .5rem;
  transform: translateY(-160%);
  padding: .65rem 1rem;
  border-radius: .5rem;
  background: var(--accent);
  color: var(--accent-ink);
}
.skip-link:focus { transform: none; }

.site-header { border-bottom: 1px solid var(--rule); }
.header-content {
  width: min(calc(100% - 2.25rem), 69rem);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: .15rem 1rem;
  min-height: 4.25rem;
  margin: auto;
}
.brand {
  display: inline-flex;
  gap: .48rem;
  align-items: center;
  padding-block: .45rem;
  text-decoration: none;
  font: 700 1.45rem/1 var(--display);
  color: var(--green);
}
.brand-icon { font: 400 1rem/1 var(--readable); }
#site-nav { display: flex; align-items: center; flex-wrap: wrap; gap: .15rem .7rem; }
.nav-link {
  padding: .55rem .25rem;
  color: var(--green);
  background: none;
  border: 0;
  text-decoration: none;
  font-size: .9rem;
  font-weight: 650;
}
.nav-link:hover { text-decoration: underline; text-underline-offset: .22em; }

#app {
  width: min(calc(100% - 2.25rem), 60rem);
  margin: clamp(1.1rem, 4vw, 3rem) auto 3.5rem;
}
.loading, .muted { color: var(--quiet); }
.loading { text-align: center; }

.surface {
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: .8rem;
}

.home-panel {
  min-height: min(29rem, 70vh);
  padding: clamp(2rem, 9vw, 6rem) clamp(1rem, 4vw, 3rem);
  display: grid;
  gap: 1.05rem;
  align-content: center;
  justify-items: center;
  text-align: center;
}
.home-panel h1 { color: var(--green); }
.home-mark { color: var(--green); font-size: 1.6rem; }
.home-panel .button { margin-top: .35rem; }
.home-invite { color: var(--quiet); font-size: .9rem; }

.auth-panel {
  width: min(100%, 29rem);
  margin: clamp(1.6rem, 8vw, 4rem) auto;
  padding: clamp(1.1rem, 5vw, 2.65rem);
}
.auth-panel h1 { color: var(--green); }
.auth-panel > * + * { margin-top: 1.25rem; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: start;
  gap: .35rem;
  padding: .52rem .94rem;
  min-height: 2.65rem;
  border-radius: .52rem;
  border: 1px solid var(--rule);
  background: var(--surface);
  color: var(--green);
  text-decoration: none;
  text-align: center;
  line-height: 1.2;
  font-size: .925rem;
  font-weight: 650;
}
.button:hover { border-color: var(--green); }
.button-primary, .button-reserve {
  border-color: var(--accent);
  background: var(--accent);
  color: var(--accent-ink);
}
.button-primary:hover, .button-reserve:hover { filter: brightness(.88); }
.button-danger { color: var(--error); }
.button-danger:hover { border-color: var(--error); }
.text-link, .back-link, .product-link {
  color: var(--accent);
  font-weight: 650;
  text-decoration-thickness: 1px;
  text-underline-offset: .2em;
}

.form-stack, .field {
  display: grid;
  justify-items: stretch;
  gap: .42rem;
  min-width: 0;
}
.form-stack { gap: .95rem; }
.form-stack > .button { justify-self: start; }
.field-label { font-size: .93rem; font-weight: 650; }
.field-help { color: var(--quiet); font-size: .85rem; overflow-wrap: anywhere; }
.field input, .field select, .field textarea, .copy-fallback {
  width: 100%;
  min-width: 0;
  min-height: 2.7rem;
  padding: .55rem .66rem;
  border: 1px solid #bbc1b3;
  border-radius: .45rem;
  background: #fff;
  color: var(--ink);
  font-size: 1rem;
}
.field textarea { resize: vertical; }
.check-field { display: flex; align-items: start; gap: .55rem; font-size: .94rem; }
.check-field input { flex: none; width: 1rem; height: 1rem; margin: .24rem 0 0; accent-color: var(--green); }
.feedback { color: var(--green); font-size: .88rem; overflow-wrap: anywhere; }
.feedback.error { color: var(--error); }
.feedback:empty { position: absolute; }

.workspace { width: min(100%, 47rem); margin: auto; }
.workspace h1, .workspace h2 { color: var(--green); }
.workspace-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: .7rem 1rem;
  flex-wrap: wrap;
}
.workspace-heading .button { align-self: center; }
.editor-details { margin-top: 1rem; }
.editor-details summary {
  padding: .9rem 1rem;
  color: var(--green);
  font-weight: 650;
  overflow-wrap: anywhere;
}
.editor-details[open] summary { border-bottom: 1px solid var(--rule); }
.editor-details .form-stack { padding: 1rem; }
.editor-details > .button { margin: 0 1rem 1rem; }
.transfer-panel { display: grid; gap: .65rem; padding: 1rem; border-top: 1px solid var(--rule); }
.transfer-panel h2 { font-size: 1.3rem; }
.editor-details .transfer-panel .form-stack { padding: 0; }
.invite-result:empty { display: none; }
.invite-result {
  margin-top: .55rem;
  padding: .8rem 0;
  display: grid;
  gap: .55rem;
}
.invite-result > .muted { font-size: .9rem; }
.list-collection, .wish-list {
  list-style: none;
  display: grid;
  gap: .65rem;
  padding: 0;
  margin: 1rem 0 0;
}
.collection-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .55rem 1rem;
  flex-wrap: wrap;
  padding: .85rem 1rem;
}
.collection-link { text-decoration-color: var(--rule); text-underline-offset: .15em; }
.collection-link:hover { text-decoration-color: currentColor; }
.list-address { color: var(--quiet); overflow-wrap: anywhere; font-size: .92rem; }
.badge {
  width: fit-content;
  border-radius: 999px;
  padding: .14rem .55rem;
  background: #eeeae0;
  color: #61574c;
  font-size: .78rem;
  font-weight: 650;
}
.badge-live { color: var(--green); background: var(--green-bg); }
.empty-state { padding: 1.15rem 0; }
.back-link { display: inline-block; margin-bottom: .7rem; font-size: .9rem; }
.share-area {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .6rem .65rem;
  margin-block: .8rem .55rem;
}
.share-controls {
  display: flex;
  align-items: start;
  flex-wrap: wrap;
  gap: .45rem;
  flex: 1 1 100%;
}
.share-tool { display: grid; justify-items: start; gap: .24rem; min-width: 0; }
.copy-fallback { font-size: .875rem; }
.wish-editor { margin-top: 1.55rem; }
.wish-editor > .muted, .wish-editor > .feedback { margin-top: .65rem; }
.wish-details { margin-top: 0; }

.guest-sheet {
  width: min(100%, 54rem);
  margin: auto;
  border: 1px solid var(--rule);
  border-radius: 1rem;
  background: #f1f3eb;
  padding-bottom: clamp(1.3rem, 5vw, 2.45rem);
  overflow: hidden;
}
.guest-heading {
  padding: clamp(1.2rem, 5vw, 3.1rem) clamp(1rem, 4vw, 2.1rem);
  text-align: center;
}
.guest-heading h1 { color: var(--accent); }
.guest-heading p {
  max-width: 36rem;
  margin: .9rem auto 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  color: var(--quiet);
}
.christmas {
  --surface: #fffcf6;
  --accent: #832b36;
  --green: #3b4d36;
  --quiet: #67594c;
  --rule: #ded1bf;
  --paper-art: #f3ede1;
  background: var(--paper-art);
  color: #332b22;
}
.christmas .guest-heading { padding-top: .15rem; padding-bottom: clamp(1.25rem, 4vw, 2rem); }
.jule-banner { position: relative; overflow: hidden; aspect-ratio: 3.15; }
.jule-banner img {
  position: absolute;
  top: 0;
  left: -1.1%;
  width: 102.2%;
  max-width: none;
  height: auto;
  transform: translateY(-48%);
}
.jule-banner::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 12%;
  background: linear-gradient(transparent, var(--paper-art));
}
.wish-list, .guest-empty {
  width: min(calc(100% - 1.6rem), 43rem);
  margin: auto;
}
.guest-empty { text-align: center; padding: .5rem 0; }
.wish-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: .8rem 1.1rem;
  padding: .85rem 1rem;
  min-height: 4.6rem;
  border: 1px solid var(--rule);
  border-radius: .7rem;
  background: var(--surface);
}
.wish-card.has-image { grid-template-columns: auto minmax(0, 1fr) auto; }
.wish-image {
  width: clamp(3.5rem, 11vw, 5rem);
  aspect-ratio: 1;
  display: block;
  object-fit: contain;
  border-radius: .38rem;
  background: var(--paper);
}
.wish-text { display: grid; gap: .2rem; overflow-wrap: anywhere; }
.wish-text h2 { font-size: clamp(1.35rem, 3.5vw, 1.75rem); }
.wish-description { white-space: pre-wrap; color: var(--quiet); }
.wish-price { font-size: .91rem; font-weight: 650; }
.product-link { width: fit-content; font-size: .92rem; }
.reservation { text-align: right; }
.reservation .feedback { margin-top: .3rem; max-width: 16rem; }
.reservation-actions { display: flex; justify-content: end; align-items: center; flex-wrap: wrap; gap: .45rem; }
.reservation-state { color: var(--quiet); font-size: .83rem; }
.reservation-state:empty { display: none; }
.reserved-by-me { background: var(--surface); color: var(--accent); }
.reserved-by-me:hover { background: var(--paper); filter: none; }

@media (max-width: 38rem) {
  #app { width: calc(100% - 1.25rem); }
  .header-content { width: calc(100% - 1.65rem); }
  .wish-card { grid-template-columns: minmax(0, 1fr); }
  .wish-card.has-image { grid-template-columns: auto minmax(0, 1fr); }
  .reservation { grid-column: 1 / -1; text-align: left; }
  .reservation-actions { justify-content: start; }
}

@media (pointer: coarse) {
  .button, .nav-link { min-height: 2.75rem; }
}
