:root {
  color-scheme: light;
  --ink: #2e261f;
  --muted: #6f6258;
  --paper: #fffaf0;
  --paper-deep: #f8ecd8;
  --cream: #fffdf7;
  --pasta: #dcae3b;
  --poppy: #d94732;
  --cornflower: #426cae;
  --leaf: #788657;
  --sage: #6f7d68;
  --sage-dark: #4f6046;
  --rose: #c76f62;
  --line: rgba(151, 108, 60, 0.23);
  --line-soft: rgba(151, 108, 60, 0.16);
  --shadow: 0 22px 70px rgba(92, 67, 38, 0.12);
  --shadow-soft: 0 16px 48px rgba(92, 67, 38, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: linear-gradient(180deg, #fffaf0 0%, #fffdf7 42%, #f8ecd8 100%);
  color: var(--ink);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  content: "";
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.45), rgba(255, 255, 255, 0.2)),
    repeating-linear-gradient(90deg, rgba(80, 59, 34, 0.025) 0 1px, transparent 1px 5px);
  opacity: 0.5;
}

a {
  color: inherit;
}

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 72px;
  padding: 16px clamp(20px, 4vw, 56px);
  color: var(--ink);
}

.brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 253, 247, 0.78);
  box-shadow: 0 8px 24px rgba(92, 67, 38, 0.08);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
  text-decoration: none;
  backdrop-filter: blur(14px);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(12px, 2.5vw, 30px);
  padding: 10px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 253, 247, 0.82);
  box-shadow: 0 8px 24px rgba(92, 67, 38, 0.08);
  backdrop-filter: blur(14px);
}

.nav-links a {
  color: var(--ink);
  font-size: 0.84rem;
  font-weight: 700;
  text-decoration: none;
}

.hero {
  position: relative;
  display: grid;
  align-items: start;
  min-height: 92vh;
  overflow: hidden;
  padding: 112px clamp(20px, 5vw, 72px) 0;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 253, 247, 0.72), rgba(255, 250, 240, 0.2));
}

.hero::after {
  position: absolute;
  inset: 0;
  z-index: 1;
  content: "";
  pointer-events: none;
  background:
    radial-gradient(ellipse at 50% 27%, rgba(255, 253, 247, 0.94) 0 18%, rgba(255, 253, 247, 0.78) 34%, rgba(255, 250, 240, 0.36) 58%, transparent 82%),
    linear-gradient(180deg, rgba(255, 253, 247, 0.72) 0%, rgba(255, 253, 247, 0.28) 45%, rgba(255, 250, 240, 0.06) 100%);
}

.hero-card {
  position: relative;
  z-index: 2;
  width: min(820px, 100%);
  margin: 0 auto;
  padding: clamp(28px, 6vw, 72px) clamp(20px, 6vw, 82px) clamp(160px, 17vw, 220px);
  text-align: center;
}

.script-line {
  margin: 0;
  font-family: Parisienne, "Cormorant Garamond", cursive;
  font-size: clamp(2.2rem, 7vw, 4.9rem);
  line-height: 1.05;
}

.rule {
  width: min(360px, 72%);
  height: 1px;
  margin: clamp(18px, 3vw, 28px) auto;
  background: linear-gradient(90deg, transparent, rgba(197, 139, 69, 0.6), transparent);
}

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

h1 {
  font-size: clamp(4rem, 12vw, 9rem);
}

h2 {
  font-size: clamp(2.55rem, 6vw, 5.2rem);
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--poppy);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero-copy {
  max-width: 560px;
  margin: 22px auto 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(1.24rem, 2.4vw, 1.7rem);
  line-height: 1.34;
}

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

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
}

.button.primary {
  background: var(--sage-dark);
  color: #fffdf7;
}

.button.secondary {
  border-color: var(--line);
  background: rgba(255, 253, 247, 0.72);
  color: var(--ink);
}

.flower-banner {
  position: absolute;
  inset: auto 0 clamp(-118px, -8vw, -54px);
  z-index: 0;
  width: 100%;
  height: clamp(860px, 88vh, 980px);
  background-image: url("../images/watercolor-wildflowers-spaghetti-v2.png");
  background-position: center bottom;
  background-repeat: repeat-x;
  background-size: auto 100%;
  opacity: 0.68;
  mix-blend-mode: multiply;
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 16%, #000 88%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0%, #000 16%, #000 88%, transparent 100%);
  user-select: none;
}

.details-band,
.rsvp-section {
  padding: clamp(68px, 10vw, 128px) clamp(20px, 5vw, 72px);
}

.details-band {
  background: rgba(248, 236, 216, 0.68);
}

.centered {
  margin: 0 auto;
  text-align: center;
}

.section-heading {
  max-width: 880px;
}

.section-heading h2 {
  font-size: clamp(2.5rem, 5.6vw, 5rem);
}

.section-subtitle {
  margin: 12px 0 0;
  color: var(--muted);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(1.45rem, 2.6vw, 2rem);
  font-style: italic;
}

.calendar-button {
  min-height: 42px;
  margin-top: 16px;
  padding: 0 18px;
  font-size: 0.86rem;
}

.details-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  width: min(1060px, 100%);
  margin: clamp(28px, 3.8vw, 40px) auto 0;
  border: 1px solid var(--line-soft);
  background: var(--line-soft);
}

.detail-item {
  display: grid;
  align-content: center;
  gap: 10px;
  min-height: 176px;
  padding: clamp(24px, 4vw, 38px);
  background: rgba(255, 253, 247, 0.62);
  text-align: center;
}

.detail-label {
  display: block;
  color: var(--sage-dark);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.detail-item strong {
  display: block;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(1.5rem, 2.7vw, 2.1rem);
  font-weight: 600;
  line-height: 1.08;
}

.detail-item p {
  max-width: 22rem;
  margin: 0 auto;
  font-size: 0.95rem;
}

.detail-item p,
.rsvp-intro p,
.admin-hero p:not(.eyebrow) {
  color: var(--muted);
}

.rsvp-section {
  display: grid;
  grid-template-columns: minmax(260px, 0.78fr) minmax(300px, 1fr);
  gap: clamp(36px, 7vw, 88px);
  align-items: start;
  background:
    linear-gradient(180deg, rgba(255, 253, 247, 0.66), rgba(255, 250, 240, 0.5)),
    var(--paper);
}

.rsvp-intro {
  position: sticky;
  top: 104px;
}

.rsvp-form,
.admin-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 253, 247, 0.88);
  box-shadow: var(--shadow-soft);
}

.rsvp-form {
  display: grid;
  gap: 22px;
  padding: clamp(24px, 4vw, 42px);
  background: rgba(255, 253, 247, 0.82);
}

.form-row {
  display: grid;
  gap: 8px;
}

label,
legend {
  color: var(--ink);
  font-weight: 850;
}

fieldset {
  margin: 0;
  padding: 0;
  border: 0;
}

.choice-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 10px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 250, 240, 0.52);
}

.choice-row label {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 16px;
  color: var(--ink);
  font-size: 0.92rem;
  font-weight: 800;
  text-align: center;
  cursor: pointer;
  transition:
    background-color 160ms ease,
    border-color 160ms ease,
    color 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
}

.choice-row label + label {
  border-left: 1px solid var(--line);
}

.choice-row input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.choice-row label:has(input:checked) {
  background: var(--sage-dark);
  color: #fffdf7;
  box-shadow: inset 0 0 0 1px rgba(79, 96, 70, 0.72);
}

.choice-row label:has(input:focus-visible) {
  outline: 3px solid rgba(211, 174, 75, 0.38);
  outline-offset: -3px;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 250, 240, 0.78);
  color: var(--ink);
  font: inherit;
}

input,
select {
  min-height: 50px;
  padding: 0 14px;
}

select {
  appearance: none;
  padding-right: 46px;
}

select:disabled {
  border-color: rgba(151, 108, 60, 0.16);
  background: rgba(239, 229, 211, 0.78);
  color: rgba(46, 38, 31, 0.42);
  cursor: not-allowed;
  opacity: 1;
}

.select-wrap {
  position: relative;
  display: block;
}

.select-wrap::after {
  position: absolute;
  top: 50%;
  right: 16px;
  width: 8px;
  height: 8px;
  border-right: 2px solid rgba(46, 38, 31, 0.62);
  border-bottom: 2px solid rgba(46, 38, 31, 0.62);
  content: "";
  pointer-events: none;
  transform: translateY(-65%) rotate(45deg);
}

.select-wrap:has(select:disabled)::after {
  border-color: rgba(46, 38, 31, 0.28);
}

textarea {
  resize: vertical;
  padding: 14px;
}

input:focus,
select:focus,
textarea:focus,
.button:focus-visible,
a:focus-visible {
  outline: 3px solid rgba(211, 174, 75, 0.38);
  outline-offset: 3px;
}

.submit-button {
  width: 100%;
  border: 0;
  font-size: 1rem;
}

.submit-button:disabled {
  cursor: wait;
  opacity: 0.72;
}

.form-status {
  display: grid;
  gap: 12px;
  min-height: 24px;
  margin: 0;
  color: var(--sage-dark);
  font-weight: 800;
}

.form-status:empty {
  display: block;
}

.form-status .calendar-button {
  width: 100%;
  margin-top: 0;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 28px clamp(20px, 5vw, 72px);
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.site-footer p {
  margin: 0;
  font-weight: 900;
}

.admin-page {
  background:
    linear-gradient(rgba(255, 253, 247, 0.78), rgba(255, 253, 247, 0.78)),
    var(--paper);
}

.admin-page .eyebrow {
  color: var(--cornflower);
}

.admin-page h1,
.admin-page h2 {
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.12;
}

.admin-page .button {
  min-height: 42px;
  border-radius: 8px;
}

.admin-page .button.primary {
  background: var(--sage-dark);
  color: #fffdf7;
}

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

.admin-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 18px 0 28px;
}

.admin-hero h1 {
  max-width: none;
  color: var(--ink);
  font-size: clamp(2.4rem, 5vw, 4rem);
}

.admin-home-link.button.secondary,
.admin-actions .button.secondary {
  border-color: var(--line);
  background: var(--cream);
  color: var(--ink);
}

.admin-card {
  margin-top: 16px;
  padding: clamp(18px, 3vw, 28px);
}

.admin-card h2 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
}

.admin-login-form {
  display: grid;
  max-width: 440px;
  gap: 12px;
  margin-top: 24px;
}

.is-hidden {
  display: none !important;
}

.admin-toolbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 22px;
}

.admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  margin: 28px 0 18px;
  border: 1px solid var(--line);
  background: var(--line);
}

.summary-grid div {
  display: grid;
  gap: 8px;
  min-height: 92px;
  padding: 16px;
  background: var(--paper);
}

.summary-grid span {
  color: var(--muted);
  font-weight: 800;
}

.summary-grid strong {
  font-size: 2rem;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.rsvp-table {
  width: 100%;
  min-width: 780px;
  border-collapse: collapse;
}

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

.rsvp-table th {
  background: var(--paper-deep);
  font-size: 0.78rem;
  text-transform: uppercase;
}

.rsvp-table tr:last-child td {
  border-bottom: 0;
}

.delete-rsvp-button {
  border: 0;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.86rem;
  font-weight: 800;
  cursor: pointer;
}

.delete-rsvp-button:hover,
.delete-rsvp-button:focus-visible {
  color: var(--poppy);
}

.delete-rsvp-button:disabled {
  cursor: wait;
  opacity: 0.5;
}

@media (max-width: 900px) {
  .details-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .rsvp-section {
    grid-template-columns: 1fr;
  }

  .rsvp-intro {
    position: static;
  }
}

@media (max-width: 720px) {
  .site-header {
    min-height: 64px;
    padding: 12px 16px;
  }

  .brand {
    width: 48px;
    height: 48px;
  }

  .nav-links {
    gap: 10px;
    padding: 9px 11px;
  }

  .nav-links a {
    font-size: 0.78rem;
  }

  .hero {
    min-height: 88vh;
    padding: 86px 16px 0;
  }

  .hero-card {
    padding: clamp(28px, 9vw, 44px) 4px 190px;
  }

  .script-line {
    font-size: clamp(2.3rem, 12vw, 3.7rem);
  }

  h1 {
    font-size: clamp(4.4rem, 20vw, 6.4rem);
  }

  h2 {
    font-size: clamp(2.55rem, 12vw, 4rem);
  }

  .hero-copy {
    max-width: 19rem;
    font-size: 1.18rem;
  }

  .flower-banner {
    bottom: -108px;
    height: 760px;
    background-position: center bottom;
    background-size: auto 100%;
    opacity: 0.76;
  }

  .hero-actions,
  .site-footer,
  .admin-hero,
  .admin-toolbar {
    display: grid;
  }

  .button {
    width: 100%;
  }

  .summary-grid {
    grid-template-columns: 1fr;
  }

  .details-grid {
    grid-template-columns: 1fr;
    width: min(460px, 100%);
    border-color: var(--line);
    background: var(--line);
  }

  .detail-item {
    gap: 8px;
    min-height: auto;
    padding: 24px 18px;
    background: rgba(255, 253, 247, 0.88);
  }

  .detail-item p {
    margin-right: auto;
    margin-left: auto;
  }

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

  .choice-row label {
    min-height: 54px;
    padding: 0 10px;
    font-size: 0.82rem;
    line-height: 1.2;
  }

  .choice-row label + label {
    border-left: 1px solid var(--line);
  }

}

@media (max-width: 480px) {
  .site-header {
    gap: 10px;
    padding: 10px 12px;
  }

  .brand {
    width: 44px;
    height: 44px;
  }

  .nav-links {
    gap: 8px;
    padding: 8px 10px;
  }

  .nav-links a {
    font-size: 0.72rem;
  }

  .hero {
    min-height: 86vh;
    padding-top: 78px;
  }

  .hero-card {
    padding-bottom: 205px;
  }

  .hero-actions {
    gap: 10px;
    margin-top: 24px;
  }

  .flower-banner {
    bottom: -118px;
    height: 740px;
    opacity: 0.78;
  }

  .details-band,
  .rsvp-section {
    padding: 58px 16px;
  }

  .detail-item {
    min-height: auto;
    padding: 24px 18px;
  }

  .rsvp-form,
  .admin-card {
    box-shadow: 0 16px 48px rgba(92, 67, 38, 0.1);
  }

  .rsvp-form {
    gap: 18px;
    padding: 20px 16px;
  }

  .site-footer {
    padding: 22px 16px;
  }
}
