:root {
  --ink: #241f2a;
  --muted: #6d6575;
  --paper: #fff8f3;
  --rose: #d84d6b;
  --coral: #ff8f70;
  --gold: #e8b45c;
  --mint: #b6dec7;
  --night: #2b2340;
  --line: rgba(36, 31, 42, 0.14);
  --shadow: 0 22px 70px rgba(52, 34, 54, 0.18);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 8%, rgba(255, 143, 112, 0.25), transparent 28rem),
    radial-gradient(circle at 88% 14%, rgba(182, 222, 199, 0.34), transparent 24rem),
    var(--paper);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

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

button,
input,
textarea {
  font: inherit;
}

.hidden {
  display: none !important;
}

.gate {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.gate-panel {
  width: min(100%, 480px);
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.eyebrow,
.note-kicker {
  margin: 0 0 10px;
  color: var(--rose);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h1,
h2 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  line-height: 0.98;
  letter-spacing: 0;
}

.gate-panel h1 {
  font-size: clamp(2.2rem, 8vw, 4.35rem);
  max-width: 9ch;
}

.password-form {
  margin-top: 30px;
}

.gate-help {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.5;
}

.gate-options {
  display: grid;
  gap: 10px;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.gate-options span {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.wishes-entry-button,
.main-entry-button {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 13px 16px;
  color: var(--night);
  background: #fff;
  font-weight: 900;
  cursor: pointer;
}

.wishes-entry-button {
  color: #fff;
  background: var(--rose);
  border-color: var(--rose);
}

.password-form label,
.range-field span,
.wish-form label {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.password-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.password-row input,
.wish-form input,
.wish-form textarea {
  min-width: 0;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 13px 14px;
  color: var(--ink);
  background: #fff;
}

.wish-form textarea {
  resize: vertical;
  line-height: 1.55;
}

.password-row button,
.button {
  border: 0;
  border-radius: 8px;
  padding: 13px 18px;
  color: #fff;
  background: var(--night);
  font-weight: 800;
  cursor: pointer;
}

.error {
  min-height: 20px;
  margin: 10px 0 0;
  color: #b4233a;
  font-weight: 700;
}

.success {
  min-height: 20px;
  margin: 12px 0 0;
  color: #177245;
  font-weight: 800;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 16px;
  padding: 14px clamp(16px, 5vw, 52px);
  background: rgba(255, 248, 243, 0.82);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  aspect-ratio: 1;
  border-radius: 50%;
  color: #fff;
  background: var(--rose);
}

.nav {
  justify-self: center;
  display: flex;
  gap: clamp(10px, 3vw, 28px);
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 800;
}

.ghost-button,
.text-link {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 14px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.48);
  font-weight: 800;
  cursor: pointer;
}

.hero {
  min-height: calc(100vh - 68px);
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(320px, 0.96fr);
  gap: clamp(28px, 6vw, 74px);
  align-items: center;
  padding: clamp(34px, 6vw, 70px) clamp(16px, 5vw, 72px);
  overflow: hidden;
}

.hero-copy {
  position: relative;
  z-index: 1;
  max-width: 650px;
}

.hero-copy h1 {
  font-size: clamp(3.4rem, 9vw, 8.8rem);
}

.hero-copy p:not(.eyebrow) {
  max-width: 560px;
  margin: 22px 0 0;
  color: var(--muted);
  font-size: clamp(1rem, 2.4vw, 1.25rem);
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 30px;
}

.hero-media {
  position: relative;
  min-height: 520px;
}

.photo-strip {
  position: absolute;
  width: min(40vw, 330px);
  aspect-ratio: 3 / 4;
  border: 10px solid #fff;
  border-radius: 8px;
  box-shadow: var(--shadow);
  overflow: hidden;
  background: #fff;
}

.photo-strip img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.strip-one {
  top: 16px;
  left: 4%;
  transform: rotate(-7deg);
}

.strip-one img {
  object-position: center 35%;
}

.strip-two {
  right: 0;
  bottom: 10px;
  transform: rotate(8deg);
}

.strip-two img {
  object-position: center 28%;
}

.sparkle {
  position: absolute;
  width: 88px;
  aspect-ratio: 1;
  background: var(--gold);
  clip-path: polygon(50% 0, 60% 38%, 100% 50%, 60% 62%, 50% 100%, 40% 62%, 0 50%, 40% 38%);
  opacity: 0.88;
}

.s1 {
  right: 40%;
  top: 7%;
}

.s2 {
  left: 0;
  bottom: 8%;
  width: 58px;
  background: var(--mint);
}

.s3 {
  right: 16%;
  top: 48%;
  width: 42px;
  background: var(--rose);
}

.section {
  padding: clamp(50px, 8vw, 96px) clamp(16px, 5vw, 72px);
}

.section-heading {
  max-width: 780px;
  margin-bottom: 24px;
}

.section-heading h2 {
  font-size: clamp(2.4rem, 6vw, 5.8rem);
}

.note-card {
  max-width: 920px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: clamp(22px, 4vw, 44px);
  background: rgba(255, 255, 255, 0.68);
  box-shadow: 0 18px 45px rgba(52, 34, 54, 0.1);
}

.note-body {
  color: #3f3847;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.35rem, 3vw, 2.1rem);
  line-height: 1.35;
}

.note-body p {
  margin: 0;
}

.note-body p + p {
  margin-top: 18px;
}

.photos-section {
  background: #fff;
}

.wishes-section {
  background:
    linear-gradient(180deg, rgba(255, 248, 243, 0.85), rgba(255, 255, 255, 0.94)),
    var(--paper);
}

.wishes-only-page {
  min-height: calc(100vh - 68px);
}

.google-form-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 18px 45px rgba(52, 34, 54, 0.08);
}

.google-form-panel iframe {
  display: block;
  width: 100%;
  min-height: 780px;
  border: 0;
  background: #fff;
}

.form-link {
  display: block;
  padding: 14px 18px;
  border-top: 1px solid var(--line);
  color: var(--rose);
  background: #fffaf6;
  font-weight: 900;
  text-align: center;
}

.view-wishes-panel {
  margin-top: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 18px 45px rgba(52, 34, 54, 0.08);
}

.view-wishes-toggle {
  width: 100%;
}

.view-wishes-form {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.view-wishes-form label {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 800;
}

.view-wishes-form input {
  display: block;
  width: 100%;
  margin-top: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 13px 14px;
  color: var(--ink);
  background: #fff;
}

.wishes-results {
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  padding: 18px;
  background:
    linear-gradient(180deg, rgba(255, 250, 246, 0.95), rgba(255, 255, 255, 0.98)),
    #fff;
}

.wishes-results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
}

.wishes-results-header .note-kicker {
  margin: 0;
}

.custom-wishes-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
}

.custom-wish-card {
  border: 1px solid rgba(216, 77, 107, 0.18);
  border-radius: 8px;
  padding: 18px;
  background: #fff;
  box-shadow: 0 16px 34px rgba(52, 34, 54, 0.08);
}

.custom-wish-card strong {
  display: block;
  margin-bottom: 10px;
  color: var(--night);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.35rem;
  line-height: 1.1;
}

.custom-wish-card p {
  margin: 0;
  color: #4f4658;
  line-height: 1.55;
  white-space: pre-wrap;
}

.custom-wish-card time {
  display: block;
  margin-top: 14px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
}

.wishes-results-status {
  margin: 12px 0 0;
  color: var(--muted);
  font-weight: 700;
  line-height: 1.5;
}

.wishes-layout {
  display: grid;
  grid-template-columns: minmax(250px, 380px) minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}

.wish-form,
.wishes-board {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 18px 45px rgba(52, 34, 54, 0.08);
}

.wish-form {
  display: grid;
  gap: 14px;
  padding: 18px;
}

.wish-form .button {
  width: 100%;
}

.wishes-board {
  min-height: 380px;
  padding: 18px;
}

.board-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.board-heading .note-kicker {
  margin: 0;
}

.wish-list {
  display: grid;
  gap: 12px;
}

.wish-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: #fffaf6;
}

.wish-card strong {
  display: block;
  margin-bottom: 8px;
  color: var(--night);
}

.wish-card p {
  margin: 0;
  color: #4f4658;
  line-height: 1.55;
  white-space: pre-wrap;
}

.wish-card time {
  display: block;
  margin-top: 12px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.empty-wishes {
  margin: 18px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.photo-workspace {
  display: grid;
  grid-template-columns: minmax(250px, 340px) minmax(0, 1fr);
  gap: 20px;
  align-items: stretch;
}

.upload-panel,
.slideshow {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffaf6;
}

.upload-panel {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 18px;
}

.upload-box {
  display: grid;
  place-items: center;
  min-height: 164px;
  padding: 20px;
  border: 2px dashed rgba(216, 77, 107, 0.38);
  border-radius: 8px;
  text-align: center;
  cursor: pointer;
  background: rgba(216, 77, 107, 0.06);
}

.upload-box span {
  color: var(--night);
  font-weight: 900;
}

.upload-box small {
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.45;
}

.upload-box.is-dragging {
  border-color: var(--rose);
  background: rgba(216, 77, 107, 0.12);
}

#photo-input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.slideshow-controls {
  display: flex;
  justify-content: center;
  gap: 10px;
}

.icon-button {
  display: grid;
  place-items: center;
  width: 48px;
  aspect-ratio: 1;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--ink);
  background: #fff;
  font-size: 1.65rem;
  font-weight: 900;
  cursor: pointer;
}

.icon-button.play {
  color: #fff;
  background: var(--rose);
  border-color: var(--rose);
  font-size: 1rem;
}

.range-field input {
  width: 100%;
  accent-color: var(--rose);
}

.photo-count {
  margin: auto 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

.slideshow {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  display: grid;
  place-items: center;
  background:
    linear-gradient(135deg, rgba(36, 31, 42, 0.72), rgba(36, 31, 42, 0.32)),
    linear-gradient(160deg, #ffaf95, #e8c76f 46%, #94d8bd);
}

.slideshow img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: rgba(0, 0, 0, 0.2);
  opacity: 0;
  transition: opacity 280ms ease;
}

.slideshow img.is-visible {
  opacity: 1;
}

.empty-state {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  color: #fff;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2rem, 5vw, 4.5rem);
  text-align: center;
}

@media (max-width: 860px) {
  .site-header {
    grid-template-columns: 1fr auto;
  }

  .nav {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-self: start;
    overflow-x: auto;
    width: 100%;
    padding-bottom: 2px;
  }

  .hero,
  .photo-workspace,
  .wishes-layout {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
  }

  .hero-media {
    min-height: 380px;
    order: -1;
  }

  .photo-strip {
    width: min(68vw, 280px);
  }

  .slideshow {
    min-height: 420px;
  }
}

@media (max-width: 560px) {
  .password-row {
    grid-template-columns: 1fr;
  }

  .site-header {
    padding: 12px 14px;
  }

  .brand span:last-child {
    display: none;
  }

  .hero-copy h1 {
    font-size: clamp(3rem, 17vw, 4.9rem);
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .button,
  .text-link {
    text-align: center;
  }
}
