:root {
  color-scheme: light;
  --ink: #20201d;
  --muted: #68635c;
  --paper: #fffaf0;
  --panel: #ffffff;
  --line: #ded6c8;
  --green: #315f4a;
  --fire: #d4522a;
  --gold: #f2b84b;
  --blue: #276071;
  --shadow: 0 18px 42px rgba(41, 32, 21, 0.12);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
}

a {
  color: inherit;
}

.hero {
  min-height: 86svh;
  position: relative;
  display: grid;
  align-items: center;
  padding: 92px clamp(18px, 6vw, 84px) 64px;
  background: var(--green);
  color: #fffaf0;
  overflow: hidden;
}

.hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(18, 22, 18, 0.88) 0%, rgba(18, 22, 18, 0.64) 42%, rgba(18, 22, 18, 0.2) 100%),
    linear-gradient(0deg, rgba(18, 22, 18, 0.56), transparent 44%);
  pointer-events: none;
  z-index: 1;
}

.topbar,
.lang-switch {
  position: absolute;
  z-index: 2;
  top: 18px;
  display: flex;
  gap: 8px;
}

.topbar {
  left: clamp(18px, 6vw, 84px);
  flex-wrap: wrap;
}

.lang-switch {
  right: clamp(18px, 6vw, 84px);
}

.topbar a,
.lang-switch a {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(255, 250, 240, 0.36);
  border-radius: 6px;
  padding: 0 12px;
  background: rgba(19, 28, 24, 0.26);
  color: #fffaf0;
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 800;
}

.lang-switch .active {
  background: #fffaf0;
  color: var(--green);
}

.hero-copy {
  position: relative;
  z-index: 2;
}

.eyebrow,
.label {
  margin: 0 0 10px;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.82rem;
  font-weight: 900;
}

h1,
h2 {
  margin: 0;
  letter-spacing: 0;
  line-height: 0.98;
}

h1 {
  max-width: 10ch;
  font-size: clamp(4.1rem, 14vw, 9rem);
}

h2 {
  max-width: 13ch;
  font-size: clamp(2.2rem, 6vw, 4.8rem);
}

h3 {
  margin: 0 0 8px;
  font-size: 1.3rem;
}

p {
  line-height: 1.62;
}

.hero-copy p:not(.eyebrow) {
  max-width: 680px;
  font-size: clamp(1.05rem, 2vw, 1.28rem);
}

.date {
  margin: 22px 0 0;
  color: #ffe2a2;
  font-weight: 900;
}

.time-hero {
  margin: 8px 0 0;
  color: #fffaf0;
  font-weight: 900;
}

.deadline-hero {
  display: inline-flex;
  margin: 14px 0 0;
  border: 1px solid rgba(255, 226, 162, 0.52);
  border-radius: 6px;
  padding: 8px 11px;
  background: rgba(19, 28, 24, 0.34);
  color: #ffe2a2;
  font-weight: 900;
}

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

.button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 16px;
  background: var(--panel);
  color: var(--ink);
  font: inherit;
  font-weight: 900;
  text-decoration: none;
  cursor: pointer;
  overflow-wrap: anywhere;
}

.button.primary {
  border-color: var(--fire);
  background: var(--fire);
  color: white;
}

.button.small {
  min-height: 34px;
  padding: 0 10px;
  font-size: 0.88rem;
}

.details {
  margin: 0;
}

dt {
  font-weight: 950;
}

dd {
  margin: 3px 0 0;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.section {
  padding: clamp(54px, 8vw, 86px) 0;
}

.section.soft,
.form-section {
  background: #f2eadc;
}

.gifts-section {
  padding: clamp(38px, 6vw, 64px) 0;
  background:
    linear-gradient(90deg, rgba(49, 95, 74, 0.08), rgba(242, 184, 75, 0.14)),
    #fff7e8;
}

.wrap {
  width: min(1060px, calc(100% - 32px));
  margin: 0 auto;
}

.narrow {
  max-width: 760px;
}

.two-col {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(320px, 1fr);
  gap: clamp(24px, 5vw, 64px);
  align-items: start;
}

.details,
.notice,
.rsvp-form,
.simple-card,
.admin-panel,
.stats article,
.table-scroll {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.details div {
  display: grid;
  grid-template-columns: 118px 1fr;
  gap: 16px;
  padding: 17px 20px;
  border-bottom: 1px solid var(--line);
}

.details div:last-child {
  border-bottom: 0;
}

.deadline-row {
  background: #fff7e8;
}

.deadline-row dt,
.deadline-row dd,
.deadline-note {
  color: #9d3f24;
}

.deadline-note {
  display: inline-flex;
  margin: 14px 0 0;
  border: 1px solid rgba(212, 82, 42, 0.28);
  border-radius: 6px;
  padding: 9px 12px;
  background: #fff7e8;
  font-weight: 900;
}

.notice {
  padding: 24px;
}

.parking-options {
  display: grid;
  gap: 10px;
}

.parking-option {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 14px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.parking-option strong {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  background: var(--green);
  color: white;
  font-size: 0.82rem;
  font-weight: 950;
}

.parking-option span {
  font-weight: 850;
  overflow-wrap: anywhere;
}

.parking-note {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.gift-layout {
  display: grid;
  grid-template-columns: minmax(240px, 0.62fr) minmax(320px, 1fr);
  gap: clamp(22px, 5vw, 54px);
  align-items: center;
  border: 1px solid rgba(222, 214, 200, 0.9);
  border-radius: 8px;
  padding: clamp(22px, 4vw, 38px);
  background: rgba(255, 253, 247, 0.88);
  box-shadow: 0 18px 46px rgba(41, 32, 21, 0.1);
}

.wishlist-cta {
  max-width: 360px;
}

.wishlist-cta p {
  margin-top: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.gift-note {
  justify-self: end;
  max-width: 600px;
  text-align: left;
}

.gift-note h2 {
  max-width: none;
  font-size: clamp(2.25rem, 6vw, 4.2rem);
}

.gift-note p:last-child {
  max-width: 620px;
  margin-bottom: 0;
  font-size: 1.05rem;
}

.rsvp-form {
  display: grid;
  gap: 18px;
  padding: clamp(18px, 4vw, 30px);
}

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

.additional-names {
  display: grid;
  gap: 14px;
}

.planning-fields {
  display: grid;
  gap: 18px;
}

.planning-fields[hidden] {
  display: none;
}

.optional-details {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: #fffaf0;
}

.optional-details summary {
  cursor: pointer;
  font-weight: 900;
}

.optional-details .field-grid {
  margin-top: 14px;
}

.privacy-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

label span,
legend {
  display: block;
  margin-bottom: 7px;
  color: var(--ink);
  font-weight: 900;
}

input,
select,
textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid #beb5a6;
  border-radius: 6px;
  padding: 10px 12px;
  background: white;
  color: var(--ink);
  font: inherit;
}

textarea {
  resize: vertical;
}

fieldset {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
}

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

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

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

.single-field {
  grid-template-columns: 1fr;
}

.choices label {
  min-width: 0;
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px 10px;
  background: #fffaf0;
  overflow-wrap: anywhere;
}

input[type="checkbox"],
input[type="radio"] {
  width: 18px;
  min-height: 18px;
  accent-color: var(--fire);
}

.hidden {
  position: absolute;
  left: -9999px;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 24px clamp(18px, 6vw, 84px);
  background: var(--ink);
  color: white;
}

.footer-links {
  display: inline-flex;
  gap: 14px;
  align-items: center;
}

.simple-page,
.admin-page {
  min-height: 100svh;
  background: #f2eadc;
}

.wishlist-page {
  display: grid;
  align-items: center;
  background:
    linear-gradient(135deg, rgba(49, 95, 74, 0.14), rgba(212, 82, 42, 0.1)),
    #f2eadc;
}

.not-found-page {
  display: grid;
  align-items: center;
  background:
    linear-gradient(135deg, rgba(49, 95, 74, 0.12), rgba(242, 184, 75, 0.16)),
    #f2eadc;
}

.closed-page {
  display: grid;
  align-items: center;
  background:
    linear-gradient(135deg, rgba(49, 95, 74, 0.14), rgba(212, 82, 42, 0.1)),
    #f2eadc;
}

.closed-card {
  position: relative;
}

.simple-lang-switch {
  position: static;
  justify-content: flex-start;
  margin-bottom: 24px;
}

.simple-lang-switch a {
  border-color: var(--line);
  background: #fffaf0;
  color: var(--green);
}

.simple-lang-switch .active {
  border-color: var(--green);
  background: var(--green);
  color: white;
}

.simple-card {
  width: min(720px, calc(100% - 32px));
  margin: 9vh auto;
  padding: clamp(24px, 5vw, 44px);
}

.wishlist-card {
  width: min(980px, calc(100% - 32px));
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.95fr);
  gap: clamp(20px, 4vw, 36px);
  align-items: start;
}

.simple-card h1 {
  max-width: none;
  font-size: clamp(3.2rem, 10vw, 6rem);
}

.wishlist-intro,
.wishlist {
  min-width: 0;
}

.wishlist-intro h2 {
  max-width: 100%;
  font-size: clamp(2.5rem, 5vw, 3.65rem);
  overflow-wrap: anywhere;
  hyphens: auto;
}

.wishlist {
  display: grid;
  gap: 10px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
}

.wishlist li {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 12px;
  background: #fffaf0;
  font-weight: 750;
  overflow-wrap: anywhere;
}

.wishlist li span {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  background: var(--green);
  color: white;
  font-size: 0.82rem;
  font-weight: 950;
}

.wishlist-warning {
  border-color: rgba(212, 82, 42, 0.4);
}

.wishlist-warning span {
  background: var(--fire);
}

.amazon-wishlist {
  grid-column: 1 / -1;
  border: 1px solid rgba(49, 95, 74, 0.22);
  border-radius: 8px;
  padding: clamp(18px, 4vw, 26px);
  background:
    linear-gradient(90deg, rgba(49, 95, 74, 0.08), rgba(242, 184, 75, 0.14)),
    #fffaf0;
}

.amazon-wishlist h3 {
  margin-bottom: 6px;
}

.amazon-wishlist p:not(.label) {
  max-width: 680px;
  margin: 0 0 16px;
  color: var(--muted);
}

.admin-header,
.admin-wrap {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.admin-header {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: end;
  padding: 42px 0 22px;
}

.admin-header h1 {
  font-size: clamp(3rem, 8vw, 5.8rem);
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.stats article {
  padding: 22px;
}

.stats span {
  display: block;
  color: var(--fire);
  font-size: 3rem;
  font-weight: 950;
}

.admin-panel {
  margin-bottom: 18px;
  padding: clamp(18px, 3vw, 28px);
}

.admin-edit-form textarea {
  min-height: 92px;
}

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

.summary-block,
.guest-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: #fffaf0;
}

.summary-block h3,
.guest-card h3 {
  margin: 0 0 12px;
}

.summary-detail {
  border-top: 1px solid var(--line);
  padding: 9px 0;
}

.summary-detail:first-of-type {
  border-top: 0;
}

.summary-detail summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  cursor: pointer;
  font-weight: 800;
}

.summary-detail summary span {
  overflow-wrap: anywhere;
}

.summary-detail summary strong {
  color: var(--green);
  white-space: nowrap;
}

.summary-detail ul {
  margin: 10px 0 0;
  padding-left: 20px;
  color: var(--muted);
}

.muted {
  color: var(--muted);
}

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

.guest-card {
  display: grid;
  gap: 12px;
}

.guest-card p {
  margin: 0;
  color: var(--muted);
}

.guest-card dl {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
}

.guest-card dl div {
  border-top: 1px solid var(--line);
  padding-top: 9px;
}

.guest-card dt {
  font-size: 0.82rem;
  color: var(--muted);
}

.guest-card dd {
  margin-top: 2px;
  color: var(--ink);
  font-weight: 750;
}

.panel-heading {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: start;
  margin-bottom: 18px;
}

.panel-heading h2 {
  max-width: none;
  font-size: clamp(2rem, 5vw, 3.8rem);
}

.panel-heading p:last-child {
  margin-bottom: 0;
}

.panel-heading strong {
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 12px;
  background: #fffaf0;
  color: var(--green);
}

.checklist-add {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  margin-bottom: 16px;
}

.checklist-items {
  display: grid;
  gap: 8px;
}

.checklist-item {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 9px;
  background: #fffaf0;
}

.checklist-item span {
  font-weight: 750;
}

.checklist-item.is-done span {
  color: var(--muted);
  text-decoration: line-through;
}

.check-toggle {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid #beb5a6;
  border-radius: 6px;
  background: white;
  color: var(--green);
  font: inherit;
  font-weight: 950;
  cursor: pointer;
}

.delete-button {
  border: 0;
  background: transparent;
  color: var(--fire);
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}

.answer-actions {
  min-width: 82px;
  white-space: nowrap;
}

.answer-actions form {
  margin: 8px 0 0;
}

.table-scroll {
  overflow: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 1180px;
  font-size: 0.92rem;
}

th,
td {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  background: #fffaf0;
}

.error {
  color: #9d2f24;
  font-weight: 900;
}

.empty {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

@media (max-width: 840px) {
  .hero,
  .two-col {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-top: 132px;
  }

  .topbar,
  .lang-switch {
    left: 16px;
    right: 16px;
  }

  .lang-switch {
    top: 66px;
    justify-content: flex-start;
  }

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

  .panel-heading {
    display: grid;
  }

  .dashboard-grid,
  .guest-card dl {
    grid-template-columns: 1fr;
  }

  .checklist-add {
    grid-template-columns: 1fr;
  }

  .wishlist-card {
    grid-template-columns: 1fr;
  }

  .gift-layout {
    grid-template-columns: 1fr;
  }

  .gift-note {
    justify-self: start;
  }
}

@media (max-width: 580px) {
  .topbar {
    overflow-x: auto;
    padding-bottom: 4px;
  }

  h1 {
    font-size: clamp(4rem, 22vw, 6.2rem);
  }

  .field-grid,
  .choices,
  .choices.compact,
  .details div,
  .stats {
    grid-template-columns: 1fr;
  }

  .details div {
    gap: 4px;
  }

  .actions,
  .button {
    width: 100%;
  }

  .button {
    text-align: center;
  }

  .checklist-item {
    grid-template-columns: 34px minmax(0, 1fr);
  }

  .checklist-item form:last-child {
    grid-column: 2;
  }
}
