/* 1:1 copy of the Canva site: a fixed 1440px-wide canvas, scaled to the
   window width by the script in index.html (same as Canva does). */
@font-face {
  font-family: "Agrandir";
  src: url("fonts/Agrandir-Regular.otf") format("opentype");
  font-display: swap;
}

:root {
  --cream: #eeede7;
  --ink: #020202;
  --serif: "Cinzel", serif;
  --sans: "Agrandir", system-ui, sans-serif;
  /* Every section is one page tall (Villa Anna is two). */
  --page: 767px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body { overflow-x: clip; }

body {
  width: 1440px;
  font-family: var(--sans);
  color: var(--ink);
  background: #fff;
  -webkit-font-smoothing: antialiased;
}

img { display: block; }

h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 53.4px;
  line-height: 62px;
  letter-spacing: -0.05em;
  text-transform: uppercase;
}

.cream { background: var(--cream); }

/* Hero */
.hero {
  position: relative;
  height: var(--page);
  background: url("images/upload-c681e13f7d5d3ade42e7552fc42d1ac401464b187dbab69c46b679d21e771391.jpg") 0 -410px / 1440px auto no-repeat;
  color: var(--cream);
}
.hero-date {
  position: absolute;
  top: 56px;
  left: 100px;
  font-family: var(--serif);
  font-size: 30.7px;
  color: #f5f6f5;
}
.hero-names {
  position: absolute;
  top: 476px;
  left: 0;
  right: 0;
  height: 106px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 125px;
  font-weight: 400;
  font-size: 106.7px;
  line-height: 106px;
  letter-spacing: -0.036em;
  text-transform: uppercase;
}
.name-jade { font-family: var(--serif); }
.name-antonio { font-family: var(--sans); }
.amp { width: 95px; }

/* Ceremony */
.ceremony {
  height: var(--page);
  padding-top: 58px;
  text-align: center;
}
/* The drawing's cream padding overlaps the heading and text, like in Canva. */
.ceremony h2, .ceremony p { position: relative; }
.villa-drawing {
  width: 752px;
  margin: -83px auto -30px;
}
.ceremony p {
  font-size: 20px;
  line-height: 28px;
}
.ceremony p + p { margin-top: 28px; }

/* Couple */
.couple {
  display: grid;
  grid-template-columns: 596px 348px 348px;
  column-gap: 31px;
  height: var(--page);
  padding-left: 37px;
}
.couple-photo-frame { width: 596px; height: var(--page); overflow: hidden; }
.couple-photo { width: 596px; height: var(--page); object-fit: cover; }
.couple-text { padding-top: 64px; }
.couple-text + .couple-text { margin-left: -11px; }
.couple-text h2 { margin-bottom: 56px; text-align: center; }
.couple-text p {
  font-size: 18.7px;
  line-height: 26px;
  text-align: justify;
}
.couple-text p + p { margin-top: 26px; }

/* Villa */
.villa {
  display: grid;
  grid-template-columns: 597px 598px;
  grid-template-rows: var(--page) var(--page);
  justify-content: space-between;
  padding: 0 37px;
}
.villa-text p {
  font-size: 20px;
  line-height: 34px;
  text-align: justify;
}
.villa > .villa-text:first-child { padding-top: 73px; }
.villa > .villa-text:first-child p + p { margin-top: 117px; }
.villa > .villa-text:last-child { padding-top: 73px; }
.villa > .villa-text:last-child p { line-height: 30px; letter-spacing: 0.3px; }
.villa > .villa-text:last-child p + p { margin-top: 104px; }
.villa-photo { position: relative; }
.villa-photo { height: var(--page); overflow: hidden; }
.villa-photo img { width: 599px; }
.villa-photo h2 {
  position: absolute;
  top: 177px;
  left: -30px;
  width: 672px;
  letter-spacing: 14.6px;
  text-align: center;
}
.tiles { position: relative; width: 597px; height: var(--page); overflow: hidden; }
.tiles img { width: 597px; }

/* RSVP + Timeline */
.info {
  display: grid;
  grid-template-columns: 597px 598px;
  justify-content: space-between;
  height: var(--page);
  padding: 41px 37px 0;
}
.rsvp h2 {
  text-align: center;
  border-bottom: 1px solid var(--ink);
}
.rsvp-groups { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; padding-top: 112px; }
.rsvp-group { min-width: 0; }
.links {
  list-style: none;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 82px 24px;
}
.links li {
  display: grid;
  grid-template-columns: 70px 1fr;
  column-gap: 16px;
  align-items: center;
}
.links img { justify-self: center; mix-blend-mode: multiply; }
.links a {
  color: var(--ink);
  font-size: 17.3px;
  line-height: 24px;
}
.timeline h2 {
  font-size: 40px;
  line-height: 46px;
  text-align: center;
  margin: 40px 0 87px;
}
.timeline dl > div {
  display: grid;
  grid-template-columns: 222px 1fr;
  padding-bottom: 23px;
  border-bottom: 1px solid var(--ink);
  font-size: 17.3px;
  line-height: 26px;
  letter-spacing: 0.26px;
}
.timeline dl > div + div { padding-top: 24px; }
.timeline dl > div:last-child { border-bottom: 0; }

/* Closing photo */
.closing {
  height: var(--page);
  position: relative;
  background: url("images/footer.jpg") -4px -140px / 1448px auto no-repeat;
  color: #f5f6f5;
  font-family: var(--serif);
  font-size: 48px;
  text-align: center;
}
.closing p { position: absolute; top: 523px; left: 0; right: 0; }

/* Fade-in on scroll, like Canva. Only hidden when JS is running. */
.js .fade { opacity: 0; transition: opacity 0.6s ease-out; }
.js .fade.in { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .js .fade { opacity: 1; transition: none; }
}

/* Phones and small tablets: stacked layout instead of the scaled canvas. */
@media (max-width: 999px) {
  body { width: auto; }
  img { max-width: 100%; }
  h2 { font-size: 34px; line-height: 40px; }

  .hero { height: 640px; background-position: 44% 30%; background-size: max(180%, 768px) auto; }
  .hero-date { top: 28px; left: 24px; font-size: 22px; }
  .hero-names {
    top: auto; bottom: 14%; height: auto;
    flex-direction: column; gap: 4px;
    font-size: 64px; line-height: 64px;
  }
  .amp { width: 56px; }

  .ceremony { height: auto; padding: 56px 20px; }
  .villa-drawing { width: 100%; max-width: 480px; margin: 0 auto; }
  .ceremony p { font-size: 17px; line-height: 25px; }
  .ceremony p br { display: none; }
  .ceremony p + p { margin-top: 20px; }

  .couple { display: block; height: auto; padding: 0; }
  .couple-photo-frame { width: 100%; height: auto; aspect-ratio: 4 / 5; }
  .couple-photo { width: 100%; height: 100%; object-position: center 80%; transform: scale(1.15); transform-origin: center 70%; }
  .couple-text { padding: 48px 20px 0; }
  .couple-text + .couple-text { margin-left: 0; padding-bottom: 56px; }
  .couple-text h2 { margin-bottom: 20px; }
  .couple-text p { font-size: 17px; line-height: 25px; }
  .couple-text p + p { margin-top: 18px; }

  .villa { display: flex; flex-direction: column; gap: 40px; padding: 0 20px 56px; }
  .villa .villa-text { width: auto !important; padding: 0 !important; }
  .villa-text p { font-size: 17px !important; line-height: 27px !important; }
  .villa .villa-text p + p { margin-top: 28px; }
  .villa-photo { width: calc(100% + 40px); margin-inline: -20px; justify-self: auto; order: -1; }
  .villa-photo { height: auto; }
  .villa-photo img { width: 100%; }
  .villa-photo h2 { top: 18%; left: 0; width: 100%; letter-spacing: 8px; }
  .tiles { width: calc(100% + 40px); height: auto; margin-inline: -20px; }
  .tiles img { position: static; width: 100%; }

  .info { display: block; height: auto; padding: 48px 20px 64px; }
  .rsvp-groups { grid-template-columns: minmax(0, 1fr); gap: 48px; padding-top: 32px; }
  .links { row-gap: 24px; }
  .links li { grid-template-columns: 48px 1fr; column-gap: 16px; }
  .links img { width: 40px; }
  .timeline h2 { margin: 56px 0 28px; }
  .timeline dl > div { grid-template-columns: 72px 1fr; padding-bottom: 16px; }
  .timeline dl > div + div { padding-top: 16px; }

  .closing { height: 70svh; background-position: center 60%; background-size: auto max(120%, 80vw); }
  .closing p { top: 68%; font-size: 30px; }
}

/* ---------- Sicília page: curiosities, places to visit and map ---------- */
/* Same canvas, type and two-column grid as the home page. Cards use four
   sub-columns that line up with the Villa Anna columns (37px margins). */
:root { --ease-out: cubic-bezier(0.16, 1, 0.3, 1); }
.sicilia ::selection { background: var(--ink); color: var(--cream); }
.sicilia a:focus-visible { outline: 1px solid var(--ink); outline-offset: 4px; }
.sicilia a { color: var(--ink); text-underline-offset: 3px; text-decoration-thickness: 1px; }
html:has(body.sicilia), html:has(body.home) { scroll-behavior: smooth; }
.sicilia :is(#lugares, #history-title, #sabores, #costumes, #dicas) { scroll-margin-top: 24px; }
.home :is(#cerimonia, #noivos, #villa-anna, #rsvp, #programacao) { scroll-margin-top: 24px; }
.home-menu[hidden] { display: none; }
.page-menu {
  position: fixed;
  top: 16px;
  right: 37px;
  z-index: 3;
  width: max-content;
  font-size: 13px;
  line-height: 20px;
}
.page-menu summary { display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 8px; background: rgb(238 237 231 / 0.94); cursor: pointer; list-style: none; }
.page-menu summary::-webkit-details-marker { display: none; }
.page-menu summary:hover span { text-decoration: underline; }
.page-menu summary:focus-visible { outline: 1px solid var(--ink); outline-offset: 2px; }
.menu-icon { width: 16px; height: 16px; }
.menu-chevron { width: 12px; height: 12px; }
.menu-icon path, .menu-chevron path { fill: none; stroke: currentColor; stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; }
.page-menu[open] .menu-chevron { transform: rotate(180deg); }
.page-menu-links { position: absolute; top: calc(100% + 4px); right: 0; width: 190px; max-height: calc(100svh - 80px); overflow-y: auto; padding: 8px 14px; border: 1px solid rgb(2 2 2 / 0.2); background: var(--cream); box-shadow: 0 6px 20px rgb(2 2 2 / 0.06); }
.page-menu a { display: block; padding: 8px 0; color: var(--ink); text-decoration: none; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.page-menu a.menu-featured { margin-top: 8px; padding: 12px 0 6px; border-top: 1px solid var(--ink); font-family: var(--serif); font-size: 14px; letter-spacing: 0.02em; text-decoration: none; }
.page-menu a.menu-featured:hover, .page-menu a.menu-featured:focus-visible { font-weight: 600; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 5px; }
.menu-translation { display: block; margin-top: 2px; font-size: 11px; line-height: 16px; opacity: 0.75; }
.menu-gifts { padding: 8px 0; }
.page-menu .menu-gifts a { padding: 0; }
.page-menu a:hover, .page-menu a:focus-visible { text-decoration: underline; }

.back {
  position: absolute;
  top: 28px;
  left: 37px;
  z-index: 2;
  font-size: 17.3px;
}

/* Map */
.map { position: relative; height: var(--page); overflow: hidden; background: #fff; }
.map-art-wrap, .map-art { position: absolute; inset: 0; width: 100%; height: 100%; }
.water use { fill: none; stroke-linejoin: round; }
.water .wl { stroke: var(--ink); opacity: 0.35; }
.water .wg { stroke: #fff; }
.land { fill: var(--cream); }
.coast { fill: none; stroke: var(--ink); stroke-width: 1.2; stroke-linejoin: round; }
.rings circle { fill: none; stroke: var(--ink); stroke-width: 0.8; stroke-dasharray: 2 5; }
.rings text { font-size: 12px; letter-spacing: 0.08em; text-anchor: middle; fill: var(--ink); }
.pin circle { fill: var(--ink); transition: r 0.3s var(--ease-out); }
.pin:hover circle, .pin:focus-visible circle, .pin:target circle { r: 14px; }
.pin-n { font-size: 12px; text-anchor: middle; fill: var(--cream); pointer-events: none; }
.pin-label {
  font-family: var(--serif);
  font-size: 16px;
  fill: var(--ink);
  paint-order: stroke;
  stroke: var(--cream);
  stroke-width: 4px;
  stroke-linejoin: round;
}
.pin:hover .pin-label, .pin:focus-visible .pin-label { text-decoration: underline; }
.leader { stroke: var(--ink); stroke-width: 1; }
.dot { fill: var(--ink); }
.villa-mark circle { fill: var(--cream); stroke: var(--ink); stroke-width: 0.8; }
.villa-mark text {
  font-family: var(--serif);
  font-size: 17px;
  letter-spacing: 0.2em;
  text-anchor: end;
  text-transform: uppercase;
  fill: var(--ink);
  paint-order: stroke;
  stroke: var(--cream);
  stroke-width: 4px;
}

.map-title { position: absolute; top: 72px; left: 37px; }
.map-title h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 54px;
  line-height: 58px;
  letter-spacing: -0.04em;
  text-transform: uppercase;
}
.map-title h2 { font-size: 54px; line-height: 58px; letter-spacing: -0.04em; }
.island .map-title h1 { font-size: 46px; line-height: 52px; }
.island .map-intro { top: 470px; left: 25px; width: 470px; }
.island .map-key { left: 37px; }
.cities circle { fill: var(--ink); }
.cities text, .etna text {
  font-family: var(--serif);
  font-size: 15px;
  fill: var(--ink);
  paint-order: stroke;
  stroke: var(--cream);
  stroke-width: 4px;
  stroke-linejoin: round;
}
.etna text { text-anchor: middle; }
.etna path { fill: var(--cream); stroke: var(--ink); stroke-width: 1.2; stroke-linejoin: round; }
.detail-frame rect { fill: none; stroke: var(--ink); stroke-width: 1; stroke-dasharray: 4 4; }
.detail-frame:hover rect, .detail-frame:focus-visible rect { stroke-width: 2; }
.island .villa-mark text { font-size: 15px; }
.map-title p { margin-top: 12px; font-family: var(--serif); font-size: 20px; }
.map-intro { position: absolute; top: 290px; left: 1063px; width: 352px; padding: 12px; background: #fff; }
.map-intro p { font-size: 17.3px; line-height: 26px; }
.map-intro p + p { margin-top: 20px; }
.map-key { position: absolute; left: 37px; bottom: 30px; font-size: 15px; }

/* Option A: whole island on the left, zoomed south-east with the numbers on the right. */
.map-zoom { display: grid; grid-template-columns: 560px 1fr; }
.map-zoom .map-art-wrap { position: relative; inset: auto; height: var(--page); }
.zoom-island { position: relative; z-index: 1; padding: 72px 37px 0; background: #fff; border-right: 1px solid var(--ink); }
.zoom-island h1 { font-family: var(--serif); font-weight: 400; font-size: 46px; line-height: 52px; letter-spacing: -0.04em; text-transform: uppercase; }
.zoom-island-art { margin: 20px -37px 0; height: 300px; }
.zoom-island-art .map-art { position: static; }
.zoom-island .map-intro { position: static; width: auto; padding: 0; margin-top: 16px; }
.zoom-frame { fill: none; stroke: var(--ink); stroke-width: 2; stroke-dasharray: 6 5; }
.map-zoom .map-key { left: 597px; }
.spots circle { fill: var(--ink); }

/* Temporary picker so the couple can compare map options. */
.map-picker {
  position: absolute;
  right: 16px;
  bottom: 16px;
  z-index: 10;
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 10px 14px;
  background: var(--cream);
  border: 1px solid var(--ink);
  font-size: 15px;
}
.map-picker select { font: inherit; padding: 4px 6px; border: 1px solid var(--ink); background: #fff; color: var(--ink); }

/* The map draws itself once: coastline first, then the rings open out from
   Villa Anna, then the pins land nearest first. */
@keyframes draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes appear { from { opacity: 0; } }
@keyframes ring-open { from { opacity: 0; transform: scale(0.2); } }
@keyframes pin-drop { from { opacity: 0; transform: translateY(-10px); } }
.js .coast { stroke-dasharray: 1; animation: draw 2.4s var(--ease-out) both; }
.js .water, .js .land { animation: appear 1.4s ease-out both; }
.js .rings > * { transform-box: fill-box; transform-origin: center; animation: ring-open 1.2s var(--ease-out) both; }
.js .rings > :nth-child(n+3) { animation-delay: 0.9s; }
.js .rings > :nth-child(n+5) { animation-delay: 1.1s; }
.js .rings > :nth-child(-n+2) { animation-delay: 0.7s; }
.js .villa-mark { animation: appear 0.8s ease-out 0.4s both; }
.js .pin { animation: pin-drop 0.7s var(--ease-out) both; animation-delay: calc(1.3s + var(--i) * 0.08s); }
.js .map-title, .js .map-intro, .js .map-key, .js .back { animation: appear 1s ease-out 0.2s both; }

/* Places */
.places { padding: 96px 37px 120px; text-align: center; }
.places-note { margin-top: 24px; font-size: 17.3px; line-height: 26px; }
.tier { margin-top: 88px; text-align: left; }
.tier-name {
  padding-bottom: 14px;
  border-bottom: 1px solid var(--ink);
  font-family: var(--serif);
  font-weight: 400;
  font-size: 28px;
  text-transform: uppercase;
  letter-spacing: -0.02em;
}
.tier-name span::before { content: "·"; margin: 0 14px; }
/* Evenly spaced cards: four places or three curiosities per desktop row. */
.tier-places, .curio-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: 24px;
  row-gap: 64px;
  margin-top: 40px;
}
.tier-places { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.place { scroll-margin-top: 24px; }
.place-photo { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: var(--cream); }
.place-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.9s var(--ease-out); }
.photo-fallback { display: grid; place-items: center; height: 100%; padding: 40px 20px; text-align: center; }
.place:hover .place-photo img { transform: scale(1.04); }
.place-n {
  position: absolute;
  top: 12px;
  left: 12px;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--cream) !important;
  font-size: 13px;
  text-decoration: none;
}
.place h3 {
  margin-top: 20px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: 23px;
  line-height: 28px;
  text-transform: uppercase;
  letter-spacing: -0.02em;
}
.place-time { margin-top: 4px; font-size: 15px; letter-spacing: 0.04em; }
.place p:not(.place-time) { margin-top: 14px; font-size: 15.5px; line-height: 23px; }
.place p[lang="it"] { margin-top: 10px; }
.place-link { display: inline-block; margin-top: 14px; font-size: 15px; }
.place:target h3 { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 1px; }

/* Curiosities */
.curiosities { padding: 96px 37px 120px; }
.curiosities > h2 { text-align: center; }
.curio-row { margin-top: 72px; padding-top: 32px; border-top: 1px solid var(--ink); }
.curio-row + .curio-row { margin-top: 56px; }
.curio-row > .curio-topic { grid-column: 1 / -1; }
.food-row, .customs-row { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.curio-topic {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 28px;
  line-height: 34px;
  text-transform: uppercase;
  letter-spacing: -0.02em;
}
.curio-topic span { display: block; }
.curio-photo { width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: cover; margin-bottom: 20px; }
.food-credit { display: block; margin: -12px 0 20px; font-size: 11px; line-height: 16px; }
.curio h4 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 22px;
  line-height: 28px;
  text-transform: uppercase;
  letter-spacing: -0.02em;
}
.curio p { margin-top: 14px; font-size: 15.5px; line-height: 23px; }
.curio p[lang="it"] { margin-top: 10px; }

/* A continuous illustrated history spanning the page width. */
.sicily-history {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  row-gap: 28px;
  margin-top: 72px;
  padding-top: 32px;
  border-top: 1px solid var(--ink);
}
.history-body { width: 100%; min-width: 0; }
.history-body > p { font-size: 17.3px; line-height: 29px; }
.history-body > p + p { margin-top: 24px; }
.history-photo { max-width: 820px; margin: 36px auto 40px; }
.history-photo img { display: block; width: 100%; height: auto; }
.history-photo figcaption { margin-top: 12px; max-width: 700px; font-size: 13px; line-height: 20px; }

/* Tips: same rows as the home page timeline. */
.tips { padding: 96px 37px 120px; }
.tips > h2 { text-align: center; }
.tips dl { max-width: 900px; margin: 72px auto 0; }
.tips dl > div {
  display: grid;
  grid-template-columns: 220px 1fr;
  column-gap: 24px;
  padding: 22px 0;
  border-bottom: 1px solid var(--ink);
  font-size: 17.3px;
  line-height: 26px;
}
.tips dl > div:first-child { border-top: 1px solid var(--ink); }
.tips dt { font-family: var(--serif); font-size: 20px; text-transform: uppercase; }

.sicilia .closing p { top: 470px; font-size: 44px; line-height: 60px; }
.sicilia .closing p, .closing-link { text-shadow: 0 1px 14px rgb(0 0 0 / 0.35); }
.sicilia .closing p span { display: block; font-size: 30px; }
.closing-link {
  position: absolute;
  top: 620px;
  left: 0;
  right: 0;
  font-family: var(--sans);
  font-size: 17.3px;
  color: #f5f6f5 !important;
}

@media (prefers-reduced-motion: reduce) {
  html:has(body.sicilia), html:has(body.home) { scroll-behavior: auto; }
  .js .coast, .js .water, .js .land, .js .rings > *, .js .villa-mark, .js .pin,
  .js .map-title, .js .map-intro, .js .map-key, .js .back { animation: none; }
  .place-photo img { transition: none; }
}

@media (max-width: 999px) {
  .back { top: 18px; left: 20px; font-size: 15px; }
  .map { display: flex; flex-direction: column; height: auto; padding: 64px 0 40px; background: var(--cream); }
  .map-title, .map-intro, .map-key { position: static; width: auto; padding: 0 20px; }
  .map-title h1 { font-size: 38px; line-height: 42px; }
  .page-menu { top: 8px; right: 12px; }
  .map-title p { font-size: 19px; margin-top: 8px; }
  /* Show the part of the map with the places, at a readable size. */
  .map-art-wrap { position: static; height: auto; order: 1; margin: 28px 0 0; overflow: hidden; background: #fff; }
  .map-art { position: static; display: block; width: 175%; height: auto; margin-left: -43%; }
  .island .map-art { width: 100%; margin-left: 0; }
  .map-zoom { display: flex; }
  .map-zoom .map-art-wrap { height: auto; }
  .zoom-island { order: 0; padding: 0 20px; border: 0; background: none; }
  .zoom-island h1 { font-size: 38px; line-height: 42px; }
  .zoom-island-art { margin: 20px -20px 0; height: auto; }
  .zoom-island-art .map-art { width: 100%; margin: 0; }
  .map-picker { position: static; order: 4; align-self: stretch; width: auto; margin: 24px 20px 0; flex-wrap: wrap; justify-content: space-between; }
  .map-picker select { min-width: 0; max-width: 100%; }
  .island .map-intro { width: auto; left: auto; }
  .pin .dot { r: 4px; }
  .island .pin circle:not(.dot) { r: 34px; }
  .island .pin-n { font-size: 34px; transform: translateY(8px); }
  .map-title h2 { font-size: 38px; line-height: 42px; }
  .island .cities text, .island .etna text { font-size: 40px; stroke-width: 8px; }
  .island .cities circle { r: 7px; }
  .island .villa-mark text { display: none; }
  .island-villa-mark { transform-box: fill-box; transform-origin: center; transform: scale(1.75); }
  .pin circle { r: 24px; }
  .pin:hover circle, .pin:focus-visible circle, .pin:target circle { r: 28px; }
  .pin-n { font-size: 22px; transform: translateY(4px); }
  .pin-label, .rings text { display: none; }
  .trip-pins .pin-label { display: block; font-size: 20px; stroke-width: 5px; }
  .trip-pins .pin circle:not(.dot) { r: 15px; }
  .trip-pins .pin-n { font-size: 15px; transform: none; }
  .unified-map .map-art { width: 100%; margin: 0; }
  .unified-map .pin circle:not(.dot) { r: 9px; }
  .unified-map .pin:hover circle:not(.dot), .unified-map .pin:focus-visible circle:not(.dot) { r: 11px; }
  .unified-map .pin .dot { r: 2px; }
  .unified-map .pin-n { font-size: 10px; transform: none; }
  .villa-mark text { display: none; }
  .map-intro { order: 2; margin-top: 28px; padding: 0 20px; background: none; }
  .map-intro p { font-size: 16px; line-height: 24px; }
  .map-key { order: 3; margin-top: 20px; font-size: 14px; }

  .places, .curiosities, .tips { padding: 64px 20px 72px; }
  .places-note { font-size: 15px; line-height: 22px; }
  .places-note br { display: none; }
  .tier { margin-top: 56px; }
  .tier-name { font-size: 22px; }
  .tier-name span { display: block; }
  .tier-name span::before { content: none; }
  .tier-places, .curio-row { grid-template-columns: 1fr 1fr; column-gap: 16px; row-gap: 40px; margin-top: 28px; }
  .tier-places > *, .curio-row > * { grid-column: auto !important; }
  .place h3 { font-size: 18px; line-height: 22px; margin-top: 12px; }
  .place-time, .place-link { font-size: 13px; }
  .place p:not(.place-time) { font-size: 14px; line-height: 20px; margin-top: 10px; }
  .place-n { width: 26px; height: 26px; top: 8px; left: 8px; font-size: 12px; }
  .curio-row { grid-template-columns: 1fr; margin-top: 48px; padding-top: 24px; }
  .food-row, .customs-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .food-row > .curio-topic, .customs-row > .curio-topic { grid-column: 1 / -1 !important; }
  .curio-row + .curio-row { margin-top: 40px; }
  .curio-topic { font-size: 24px; }
  .curio-topic span { display: inline; }
  .curio-topic span::before { content: "·"; margin: 0 10px; }
  .curio p { font-size: 15px; line-height: 22px; }
  .sicily-history { grid-template-columns: minmax(0, 1fr); row-gap: 28px; margin-top: 48px; padding-top: 24px; }
  .history-body > p { font-size: 16px; line-height: 26px; }
  .history-body > p + p { margin-top: 20px; }
  .history-photo { margin: 28px auto 32px; }
  .history-photo figcaption { font-size: 12px; line-height: 18px; }
  .tips dl { margin-top: 40px; }
  .tips dl > div { grid-template-columns: 1fr; row-gap: 8px; font-size: 15px; line-height: 22px; }
  .sicilia .closing p { top: 72%; font-size: 27px; line-height: 38px; }
  .sicilia .closing p span { font-size: 20px; line-height: 30px; }
  .closing-link { top: auto; bottom: 28px; padding: 0 20px; font-size: 14px; }
}

/* ---------- RSVP form and admin list (normal responsive pages, not the 1440px canvas) ---------- */
.form-page { width: auto; min-height: 100vh; background: var(--cream); font-size: 17px; line-height: 26px; }
.form-page a { color: var(--ink); text-underline-offset: 3px; text-decoration-thickness: 1px; }
.form-page ::selection { background: var(--ink); color: var(--cream); }
.form-page :focus-visible { outline: 1px solid var(--ink); outline-offset: 3px; }

/* Same photo and names as the home page hero. */
.rsvp-hero {
  position: relative;
  height: clamp(340px, 52vh, 520px);
  background: url("images/footer.jpg") center 42% / cover no-repeat;
  color: #f5f6f5;
}
.rsvp-hero::after { content: ""; position: absolute; inset: 55% 0 0; background: linear-gradient(transparent, rgb(0 0 0 / 0.28)); }
.rsvp-hero-date, .rsvp-back, .rsvp-hero-names { text-shadow: 0 1px 12px rgb(0 0 0 / 0.35); }
.rsvp-back { position: absolute; z-index: 1; top: 24px; right: 28px; font-size: 15px; color: #f5f6f5 !important; }
.form-page > .rsvp-back { color: var(--ink) !important; text-shadow: none; }
.rsvp-hero-date { position: absolute; z-index: 1; top: 22px; left: 28px; font-family: var(--serif); font-size: 22px; }
.rsvp-hero-names {
  position: absolute; z-index: 1; left: 0; right: 0; bottom: 34px;
  display: flex; justify-content: center; align-items: center; gap: clamp(24px, 6vw, 72px);
  font-size: clamp(44px, 9vw, 84px); line-height: 1; letter-spacing: -0.036em; text-transform: uppercase;
}
.rsvp-hero-names img { width: clamp(36px, 6.5vw, 64px); }

.form-wrap { max-width: 600px; margin: 0 auto; padding: 56px 24px 96px; }
.form-head { text-align: center; margin-bottom: 56px; }
.form-mono { display: block; width: 64px; height: auto; margin: 0 auto 22px; }
.form-head h1, .form-done h2, .admin-login h1, .admin-head h1 {
  font-family: var(--serif); font-weight: 400; text-transform: uppercase; letter-spacing: -0.04em;
  font-size: 46px; line-height: 52px; text-wrap: balance;
}
.form-venue { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--ink); display: inline-block; font-size: 16px; letter-spacing: 0.02em; }

.person { border: 0; padding: 0; margin: 0 0 44px; position: relative; }
.person legend { display: flex; align-items: baseline; gap: 14px; width: 100%; padding: 0 0 14px; margin-bottom: 26px; border-bottom: 1px solid var(--ink);
  font-family: var(--serif); font-size: 18px; text-transform: uppercase; letter-spacing: 0.06em; }
.person-n { font-size: 40px; line-height: 1; letter-spacing: -0.04em; }
.person-remove { position: absolute; top: 18px; right: 0; background: none; border: 0; font: inherit; font-size: 14px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; color: var(--ink); }
.form-field { display: grid; gap: 10px; margin-bottom: 26px; }
.form-field > span { font-size: 15px; letter-spacing: 0.02em; }
.form-field em { font-style: normal; color: #5a5953; }
.form-field input:not([type=radio]), .form-field textarea {
  font: inherit; color: var(--ink); width: 100%; padding: 14px 16px;
  border: 1px solid var(--ink); border-radius: 0; background: #fff; transition: box-shadow 0.2s ease-out;
}
.form-field input:not([type=radio]):focus, .form-field textarea:focus { outline: 0; box-shadow: inset 0 0 0 1px var(--ink); }
.form-field input::placeholder { color: #8a8984; }

/* Choices as large tap targets; the real radio stays in the DOM for keyboards and screen readers. */
.choices { display: grid; grid-template-columns: 1fr 1fr; }
.choices label { display: flex; align-items: center; justify-content: center; min-height: 54px; padding: 8px 12px; text-align: center;
  border: 1px solid var(--ink); background: #fff; cursor: pointer; transition: background-color 0.2s ease-out, color 0.2s ease-out; }
.choices label + label { border-left: 0; }
.choices input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.choices label:has(input:checked) { background: var(--ink); color: var(--cream); }
.choices label:has(input:focus-visible) { outline: 1px solid var(--ink); outline-offset: 3px; }
.when-going { padding-left: 18px; border-left: 1px solid var(--ink); }
.diet-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.diet-tags label { display: inline-flex; align-items: center; min-height: 40px; padding: 6px 14px; border: 1px solid var(--ink); background: #fff;
  font-size: 15px; cursor: pointer; transition: background-color 0.2s ease-out, color 0.2s ease-out; }
.diet-tags input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.diet-tags label:has(input:checked) { background: var(--ink); color: var(--cream); }
.diet-tags label:has(input:focus-visible) { outline: 1px solid var(--ink); outline-offset: 3px; }

.form-add { background: none; border: 1px dashed var(--ink); font: inherit; font-size: 15px; width: 100%; padding: 14px 16px; cursor: pointer; color: var(--ink); margin: -12px 0 44px; }
.form-add:hover { background: #fff; border-style: solid; }
.form-hp { position: absolute; left: -9999px; }
.form-error { color: #8a1c1c; min-height: 26px; margin-bottom: 12px; }
.form-submit { width: 100%; padding: 18px; border: 0; background: var(--ink); color: var(--cream); font-family: var(--serif); font-size: 18px; letter-spacing: 0.08em; text-transform: uppercase; cursor: pointer; }
.form-submit:hover { background: #262626; }
.form-submit:disabled { opacity: 0.6; cursor: default; }
.form-done { text-align: center; padding: 24px 0; }
.form-done:focus { outline: 0; }
.form-done p { margin-top: 18px; }
.form-done a { display: inline-block; margin-top: 36px; }

/* Admin */
.admin-login { max-width: 360px; margin: 18vh auto 0; padding: 0 24px; }
.admin-login h1 { font-size: 34px; line-height: 40px; margin-bottom: 32px; }
.admin { max-width: 1200px; margin: 0 auto; padding: 40px 24px 80px; }
.admin-head { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between; margin-bottom: 32px; }
.admin-head h1 { font-size: 36px; line-height: 42px; }
.admin-actions { display: flex; gap: 10px; }
.admin-actions .form-add { margin: 0; }
.admin-totals { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); border-top: 1px solid var(--ink); border-bottom: 1px solid var(--ink); margin-bottom: 32px; }
.admin-totals div { padding: 16px 0; }
.admin-totals dt { font-size: 14px; }
.admin-totals dd { font-family: var(--serif); font-size: 36px; line-height: 44px; font-variant-numeric: tabular-nums; }
.admin-search { max-width: 360px; }
.admin-table-wrap { overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 22px; background: #fff; }
.admin-table th, .admin-table td { text-align: left; vertical-align: top; padding: 12px 14px; border-bottom: 1px solid #d6d4cb; }
.admin-table th { font-weight: 400; font-family: var(--serif); text-transform: uppercase; font-size: 14px; border-bottom: 1px solid var(--ink); }
.admin-table tr.is-no td { color: #5a5953; }
.admin-del { background: none; border: 0; font: inherit; font-size: 14px; color: #8a1c1c; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.admin-empty { padding: 32px 0; color: #5a5953; }

/* Bank details share the RSVP page's type, hairlines and form controls. */
.admin-gift { max-width: 600px; margin-top: 56px; padding-top: 32px; border-top: 1px solid var(--ink); }
.admin-gift h2 { font-size: 26px; line-height: 34px; margin-bottom: 14px; }
.admin-gift > p { margin-bottom: 28px; }
.admin-gift fieldset { border: 0; padding: 0; min-width: 0; }
.gift-hint { margin: -14px 0 26px; font-size: 14px; line-height: 22px; }
.gift-status { margin-top: 16px; }
.gift-status:empty { display: none; }
.gift-retry { margin: 16px 0 0; }
.gift-intro { margin-bottom: 32px; }
.gift-bank { margin-bottom: 32px; border-top: 1px solid var(--ink); }
.gift-bank > div { padding: 20px 0; border-bottom: 1px solid var(--ink); }
.gift-bank dt { font-size: 14px; margin-bottom: 8px; }
.gift-bank dd { overflow-wrap: anywhere; }
.gift-bank .gift-iban { font-size: clamp(18px, 4.8vw, 24px); line-height: 1.5; font-variant-numeric: tabular-nums; }
@media (max-width: 360px) {
  .gift-page .rsvp-hero-names { font-size: 36px; gap: 16px; }
}

@media (max-width: 600px) {
  .form-head h1, .form-done h2 { font-size: 34px; line-height: 40px; }
  .rsvp-hero-date { font-size: 18px; top: 20px; left: 20px; }
  .rsvp-back { top: 22px; right: 20px; }
  .form-wrap { padding-top: 44px; }
  .admin-head h1 { font-size: 28px; line-height: 34px; }
}
@media (max-width: 600px) { .rsvp-hero { background: url("images/hero.jpg") center 32% / cover no-repeat; } }

/* Guest pages: the same restrained, editorial identity as the wedding invitation. */
.form-page > .rsvp-back { top: 24px; right: 32px; display: inline-flex; align-items: center; min-height: 44px; padding: 0 4px; font-size: 13px; }
.form-wrap { max-width: 840px; padding: 104px 48px 112px; }
.form-head { margin-bottom: 64px; }
.form-wrap .form-mono { width: 112px; margin-bottom: 26px; }
.form-date { margin-bottom: 20px; font-size: 11px; line-height: 18px; letter-spacing: 0.16em; text-transform: uppercase; }
.form-head h1 { max-width: 680px; margin: 0 auto; font-size: clamp(36px, 4.4vw, 58px); line-height: 1.12; letter-spacing: -0.035em; }
.form-page:not(.gift-page) .form-head { container-type: inline-size; }
.form-page:not(.gift-page) .form-head h1 { max-width: none; font-size: clamp(16px, 6cqi, 44px); white-space: nowrap; text-wrap: nowrap; }
.form-venue { display: block; margin-top: 26px; padding: 0; border: 0; font-size: 14px; line-height: 24px; letter-spacing: 0.01em; }
.form-venue::before { content: ""; display: block; width: 54px; height: 1px; margin: 0 auto 20px; background: var(--ink); }
.form-wrap > form, .form-wrap > .form-done, .form-wrap > .form-review { max-width: 640px; margin-inline: auto; }
.form-wrap [hidden] { display: none !important; }

.form-wrap .person { min-width: 0; margin-bottom: 48px; }
.form-wrap .person legend { align-items: center; gap: 14px; padding-bottom: 18px; margin-bottom: 30px; border-color: rgb(2 2 2 / 0.25); font-size: 15px; letter-spacing: 0.05em; }
.form-wrap .person-n { display: inline; font-size: 34px; }
.form-wrap .person-remove { top: 10px; padding: 4px 0; font-size: 12px; }
.form-wrap .form-field { gap: 10px; margin-bottom: 30px; }
.form-wrap .form-field > span { font-size: 13px; line-height: 20px; letter-spacing: 0.02em; }
.form-wrap .form-field em { font-size: 12px; }
.form-wrap .form-field input:not([type=radio]) { min-height: 50px; padding: 10px 0; border: 0; border-bottom: 1px solid rgb(2 2 2 / 0.4); background: transparent; box-shadow: none; }
.form-wrap .form-field input:not([type=radio]):focus { border-bottom-color: var(--ink); outline: 1px solid var(--ink); outline-offset: 4px; }
.form-wrap .form-field input[name="name"] { min-height: 54px; padding: 14px 16px; border: 1px solid rgb(2 2 2 / 0.35); background: rgb(255 255 255 / 0.5); }
.form-wrap .form-field input[aria-invalid="true"] { border-color: #8a1c1c; }
.form-wrap .name-error { color: #8a1c1c; font-size: 12px; line-height: 20px; }
.form-wrap .form-field textarea { min-height: 144px; padding: 16px; border-color: rgb(2 2 2 / 0.3); background: rgb(255 255 255 / 0.3); resize: vertical; }
.form-wrap .choices label { min-height: 54px; padding: 12px; border-color: rgb(2 2 2 / 0.3); background: transparent; font-size: 15px; line-height: 22px; }
.form-wrap .choices label:has(input:checked) { border-color: var(--ink); background: var(--ink); color: var(--cream); }
.form-wrap .meal-choices label { min-height: 78px; }
.meal-option { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.meal-option small { font-size: 11px; line-height: 16px; }
.meal-option small:empty { display: none; }
.form-wrap .when-going { margin-top: 12px; padding: 26px 0 0; border: 0; border-top: 1px solid rgb(2 2 2 / 0.15); }
.form-wrap .field-hint { margin-top: -4px; font-size: 12px; line-height: 20px; }
.form-wrap .diet-tags { display: grid; gap: 20px; }
.form-wrap .diet-group { min-width: 0; padding: 0; border: 0; }
.form-wrap .person .diet-group > legend { width: auto; margin-bottom: 10px; padding: 0; border: 0; font-family: var(--sans); font-size: 12px; line-height: 20px; letter-spacing: 0; text-transform: none; }
.form-wrap .diet-options { display: flex; flex-wrap: wrap; gap: 8px; }
.form-wrap .form-field .diet-tags input { width: 1px; height: 1px; min-height: 0; padding: 0; border: 0; }
.form-wrap .diet-tags label { min-height: 40px; padding: 8px 12px; border-color: rgb(2 2 2 / 0.25); background: transparent; font-size: 13px; line-height: 20px; }
.form-wrap .diet-tags label > span { display: inline-flex; align-items: center; gap: 8px; }
.form-wrap .diet-tags label > span::before { content: ""; width: 12px; height: 12px; flex-shrink: 0; border: 1px solid currentColor; }
.form-wrap .diet-tags label:has(input:checked) > span::before { content: "✓"; font-size: 11px; line-height: 12px; text-align: center; }
.form-wrap .diet-tags label:has(input:checked) { border-color: var(--ink); background: var(--ink); color: var(--cream); }
.form-wrap .form-add { display: block; width: auto; max-width: 100%; margin: 0 auto 44px; padding: 10px 0; border: 0; border-bottom: 1px solid rgb(2 2 2 / 0.4); font-size: 14px; line-height: 22px; }
.form-wrap .form-add:hover { border-color: var(--ink); background: transparent; }
.form-wrap .form-submit { min-height: 58px; padding: 18px 24px; font-size: 15px; line-height: 22px; letter-spacing: 0.08em; }
.form-wrap .form-done { padding: 32px 0; }

.form-review { scroll-margin-top: 32px; }
.form-review:focus { outline: 0; }
.form-review > h2 { font-size: 30px; line-height: 38px; font-weight: 400; text-transform: uppercase; }
.review-intro { margin: 16px 0 32px; font-size: 15px; line-height: 25px; }
.review-person { border-top: 1px solid rgb(2 2 2 / 0.3); padding: 24px 0; }
.review-person h3, .review-message h3 { margin-bottom: 14px; font-family: var(--serif); font-size: 16px; line-height: 24px; font-weight: 400; text-transform: uppercase; }
.review-details > div { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 16px; padding: 10px 0; border-bottom: 1px solid rgb(2 2 2 / 0.1); }
.review-details dt { font-size: 13px; line-height: 22px; }
.review-details dd { font-size: 16px; line-height: 25px; overflow-wrap: anywhere; }
.review-message { margin: 8px 0 28px; }
.review-message p { font-size: 15px; line-height: 25px; white-space: pre-wrap; overflow-wrap: anywhere; }
.review-actions { display: grid; gap: 12px; }
.review-actions .form-add { margin: 0 auto; padding: 12px 0; }

.gift-page .gift-intro { max-width: 520px; margin: 0 auto 48px; font-size: 17px; line-height: 29px; text-align: center; }
.gift-intro > p + p { margin-top: 20px; }
.gift-intro > .gift-signature { margin-top: 28px; font-family: var(--serif); font-size: 16px; line-height: 26px; }
.gift-page #giftDetails { max-width: 640px; margin-inline: auto; }
.gift-page .gift-bank { margin-bottom: 36px; }
.gift-page .gift-bank > div { display: grid; grid-template-columns: 120px minmax(0, 1fr); align-items: baseline; gap: 24px; padding: 24px 0; border-bottom-color: rgb(2 2 2 / 0.2); }
.gift-page .gift-bank dt { margin: 0; font-family: var(--serif); font-size: 17px; line-height: 28px; letter-spacing: 0.04em; }
.gift-page .gift-bank dd { font-size: 17px; line-height: 28px; }
.gift-page .gift-bank .gift-iban { font-size: 17px; line-height: 28px; letter-spacing: 0.02em; }
.gift-page #copy { display: block; width: min(100%, 300px); margin-inline: auto; }
.gift-page .gift-status { max-width: 560px; margin: 20px auto 0; font-size: 14px; line-height: 24px; text-align: center; }
.gift-page .form-add.gift-retry { margin-top: 16px; margin-bottom: 0; }

.form-page footer.rsvp-hero { height: clamp(320px, 52svh, 560px); background-image: url("images/upload-c153ac57b7eb76990cae7cacda3fae14e3cb810266e63cde6a42ff3bdf66a4fe.jpg"); }

@media (max-width: 600px) {
  .form-page > .rsvp-back { top: 14px; right: 20px; }
  .form-wrap { padding: 84px 22px 72px; }
  .form-head { margin-bottom: 48px; }
  .form-wrap .form-mono { width: 92px; margin-bottom: 22px; }
  .form-date { margin-bottom: 16px; font-size: 10px; letter-spacing: 0.12em; }
  .form-head h1 { font-size: clamp(32px, 8.5vw, 40px); line-height: 1.15; }
  .form-venue { margin-top: 22px; font-size: 13px; line-height: 23px; }
  .form-venue::before { margin-bottom: 18px; }
  .form-wrap .person { margin-bottom: 40px; }
  .form-wrap .person legend { font-size: 14px; }
  .form-wrap .person-n { font-size: 30px; }
  .form-wrap .person-remove { font-size: 11px; }
  .form-wrap .form-submit { font-size: 14px; padding-inline: 16px; }
  .form-review > h2 { font-size: 25px; line-height: 33px; }
  .review-details > div { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .gift-page .gift-intro { margin-bottom: 36px; font-size: 16px; line-height: 27px; }
  .gift-page .gift-bank > div { grid-template-columns: minmax(0, 1fr); gap: 8px; padding: 20px 0; }
  .gift-page .gift-bank .gift-iban { font-size: 17px; }
}
