:root {
  --coral: #e8474f;
  --coral-soft: #f7c9c4;
  --sun: #f4b545;
  --sand: #f7efe4;
  --sand-2: #efe3d2;
  --paper: #fffaf3;
  --sea: #1f5a73;
  --sea-deep: #143f52;
  --ink: #26221f;
  --muted: #7a6f66;
  --line: #e6dccd;
  --radius: 18px;
  --shadow: 0 10px 30px -12px rgba(60, 40, 20, .25);
  --serif: 'Fraunces', Georgia, serif;
  --sans: 'DM Sans', system-ui, -apple-system, sans-serif;
  --hand: 'Caveat', cursive;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 17px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
h1, h2, h3 { font-family: var(--serif); line-height: 1.1; margin: 0; }
h2 { font-size: clamp(2rem, 4.6vw, 3.3rem); font-weight: 800; letter-spacing: -.02em; margin-bottom: .6rem; }
h3 { font-size: 1.25rem; font-weight: 600; margin-bottom: 1rem; }
a { color: inherit; }

.wrap { max-width: 1160px; margin: 0 auto; padding: 0 20px; }
.section { padding: 110px 0; position: relative; }
.section.sand { background: var(--sand); }
.section.sea { background: var(--sea); color: #f4efe8; }
.kicker {
  font-family: var(--hand); font-size: 1.7rem; color: var(--coral);
  margin: 0 0 .2rem; transform: rotate(-2deg); display: inline-block;
}
.sea .kicker { color: var(--sun); }
.sub { color: var(--muted); max-width: 640px; margin: 0 0 2.2rem; font-size: 1.08rem; }
.note { color: var(--muted); font-size: .85rem; margin: .8rem 0 0; }
.sea .note { color: #a9c3cf; }

/* NAV */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 1000;
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 20px; transition: background .3s, box-shadow .3s;
}
.nav.scrolled { background: rgba(255, 250, 243, .92); backdrop-filter: blur(10px); box-shadow: 0 1px 0 var(--line); }
.nav-logo { display: flex; align-items: center; gap: 8px; text-decoration: none; color: var(--coral); }
.nav-logo svg { width: 40px; height: auto; }
.nav-logo span { font-family: var(--serif); font-weight: 800; letter-spacing: .12em; color: var(--ink); font-size: .95rem; }
.nav-links { display: flex; gap: 22px; font-weight: 500; font-size: .95rem; }
.nav-links a { text-decoration: none; opacity: .75; }
.nav-links a:hover { opacity: 1; color: var(--coral); }

/* HERO */
.hero {
  min-height: 100vh; min-height: 100svh;
  display: grid; place-items: center; text-align: center;
  position: relative; overflow: hidden;
  background: linear-gradient(180deg, #fde9d9 0%, #fbd9c6 45%, #f6c1ad 100%);
  padding: 90px 20px 140px;
}
.sun {
  position: absolute; width: 62vmin; height: 62vmin; border-radius: 50%;
  background: radial-gradient(circle, #ffd27a 0%, #f7a95e 55%, rgba(247, 169, 94, 0) 72%);
  left: 50%; top: 58%; transform: translate(-50%, -50%);
  opacity: .75; animation: rise 3.5s ease-out both;
}
@keyframes rise { from { top: 85%; opacity: 0; } }
.hero-inner { position: relative; z-index: 2; max-width: 820px; }
.hero-logo { width: 120px; color: var(--coral); margin: 0 auto 18px; }
.hero-logo path { stroke-dasharray: 420; stroke-dashoffset: 420; animation: draw 2.2s .2s ease forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.eyebrow { letter-spacing: .25em; text-transform: uppercase; font-size: .8rem; font-weight: 700; color: var(--coral); margin: 0 0 10px; }
.hero h1 { font-size: clamp(3.4rem, 12vw, 8.5rem); font-weight: 800; letter-spacing: -.04em; color: var(--ink); }
.hero h1 .dash { color: var(--coral); font-weight: 400; }
.lede { font-size: clamp(1.05rem, 2.2vw, 1.3rem); color: #5a4a40; margin: 18px auto 34px; max-width: 600px; }
.hero-counters { display: flex; justify-content: center; gap: clamp(18px, 5vw, 56px); flex-wrap: wrap; }
.hero-counters div { display: flex; flex-direction: column; }
.hero-counters b { font-family: var(--serif); font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; }
.hero-counters span { text-transform: uppercase; letter-spacing: .15em; font-size: .75rem; color: #7b5a4a; font-weight: 700; }
.scroll-cue { display: inline-block; margin-top: 46px; text-decoration: none; font-family: var(--hand); font-size: 1.5rem; color: #8a5a48; }
.scroll-cue span { display: inline-block; animation: bob 1.6s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(6px); } }
.waves { position: absolute; bottom: -1px; left: 0; width: 100%; height: 110px; z-index: 1; }
.waves path { fill: var(--paper); }

/* CHART */
.chart-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 12px 8px; position: relative; box-shadow: var(--shadow); }
.chart svg { width: 100%; height: auto; display: block; overflow: visible; }
.chart .grid line { stroke: #efe6da; }
.chart .axis text { fill: var(--muted); font-size: 12px; font-family: var(--sans); }
.chart .area { fill: url(#areaGrad); }
.chart .line { fill: none; stroke: var(--coral); stroke-width: 2.4; stroke-linejoin: round; }
.chart .mark circle { fill: #fff; stroke: var(--ink); stroke-width: 2; }
.chart .mark text { font-family: var(--hand); font-size: 19px; fill: var(--ink); paint-order: stroke; stroke: #fff; stroke-width: 5px; stroke-linejoin: round; }
.chart .mark line { stroke: var(--ink); stroke-dasharray: 2 3; opacity: .5; }
.chart .hover-dot { fill: var(--coral); stroke: #fff; stroke-width: 2; }
.chart-tip {
  position: absolute; pointer-events: none; background: var(--ink); color: #fff;
  padding: 6px 10px; border-radius: 8px; font-size: .85rem; white-space: nowrap; transform: translate(-50%, -120%);
}

/* TIMELINE */
.timeline { list-style: none; padding: 0; margin: 70px 0 0; position: relative; }
.timeline::before { content: ''; position: absolute; left: 50%; top: 0; bottom: 0; width: 2px; background: repeating-linear-gradient(var(--coral-soft) 0 8px, transparent 8px 14px); transform: translateX(-50%); }
.tl { position: relative; width: 50%; padding: 0 48px 56px; opacity: 0; transform: translateY(30px); transition: .7s ease; }
.tl.in { opacity: 1; transform: none; }
.tl:nth-child(odd) { margin-left: 0; text-align: right; }
.tl:nth-child(even) { margin-left: 50%; }
.tl::after {
  content: ''; position: absolute; top: 10px; width: 18px; height: 18px; border-radius: 50%;
  background: var(--paper); border: 4px solid var(--coral);
}
.tl:nth-child(odd)::after { right: -9px; }
.tl:nth-child(even)::after { left: -9px; }
.tl-date { font-family: var(--hand); font-size: 1.6rem; color: var(--coral); line-height: 1; }
.tl h3 { font-size: 1.6rem; margin: 6px 0 8px; }
.tl p { margin: 0 0 10px; color: #4d433c; }
.tl .tl-stat { display: inline-block; background: var(--sand); border-radius: 999px; padding: 4px 14px; font-weight: 700; font-size: .9rem; }
.tl blockquote { margin: 12px 0 0; font-family: var(--serif); font-style: italic; font-size: 1.05rem; color: var(--ink); }
.tl-photo { border-radius: 14px; overflow: hidden; margin-top: 14px; box-shadow: var(--shadow); aspect-ratio: 16/10; background: var(--sand-2); }
.tl-photo img { width: 100%; height: 100%; object-fit: cover; }
.tl:nth-child(odd) .tl-photo { margin-left: auto; }
.tl.dark h3 { color: var(--sea-deep); }

/* STATS */
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; margin: 30px 0 40px; }
.stat {
  background: var(--paper); border-radius: var(--radius); padding: 24px 22px; box-shadow: var(--shadow);
  position: relative; overflow: hidden; transition: transform .25s;
}
.stat:hover { transform: translateY(-4px) rotate(-.4deg); }
.stat .emoji { font-size: 1.7rem; }
.stat b { display: block; font-family: var(--serif); font-size: 2.5rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; margin: 6px 0 4px; color: var(--ink); }
.stat span { color: var(--muted); font-size: .95rem; }
.stat.accent { background: var(--coral); color: #fff; }
.stat.accent b, .stat.accent span { color: #fff; }
.stat.gold { background: var(--sun); }
.stat.sea { background: var(--sea); }
.stat.sea b, .stat.sea span { color: #fff; }

.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.panel { background: var(--paper); border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow); }
.panel.dark { background: var(--sea-deep); box-shadow: none; }
.years-panel { margin-top: 22px; }

.bars { display: grid; gap: 8px; }
.bar-row { display: grid; grid-template-columns: 92px 1fr 52px; align-items: center; gap: 10px; font-size: .92rem; }
.bar-track { height: 22px; background: var(--sand); border-radius: 6px; overflow: hidden; }
.bar-fill { height: 100%; background: var(--coral-soft); border-radius: 6px; width: 0; transition: width 1.2s cubic-bezier(.2, .8, .2, 1); }
.bar-row.top .bar-fill { background: var(--coral); }
.bar-row .num { text-align: right; font-variant-numeric: tabular-nums; color: var(--muted); }

.words { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: baseline; justify-content: center; padding: 6px 0; }
.words span { font-family: var(--serif); font-weight: 600; line-height: 1.1; color: var(--sea); }
.words span:nth-child(3n) { color: var(--coral); }
.words span:nth-child(4n) { color: #b2793a; }

.years { display: grid; grid-template-columns: repeat(9, 1fr); gap: 10px; align-items: end; height: 230px; }
.year { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; gap: 6px; }
.year .col { width: 100%; max-width: 70px; background: linear-gradient(var(--coral), #f08a6e); border-radius: 10px 10px 4px 4px; height: 0; transition: height 1.2s cubic-bezier(.2, .8, .2, 1); position: relative; }
.year .col.dim { background: var(--coral-soft); }
.year .v { font-weight: 700; font-size: .85rem; font-variant-numeric: tabular-nums; }
.year .y { font-size: .85rem; color: var(--muted); }

/* HOMES */
.map { height: 460px; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); border: 1px solid var(--line); z-index: 1; }
.pin {
  width: 30px; height: 30px; border-radius: 50% 50% 50% 0; background: var(--coral); transform: rotate(-45deg);
  border: 3px solid #fff; box-shadow: 0 4px 10px rgba(0, 0, 0, .3); display: grid; place-items: center;
}
.pin span { transform: rotate(45deg); color: #fff; font-weight: 700; font-size: 12px; font-family: var(--sans); }
.leaflet-popup-content { font-family: var(--sans); margin: 12px 14px; }
.leaflet-popup-content b { font-family: var(--serif); font-size: 1.05rem; }
.popup-list { margin: 6px 0 0; padding: 0; list-style: none; font-size: .85rem; }
.popup-list li { cursor: pointer; color: var(--coral); text-decoration: underline; margin: 2px 0; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 26px 0 22px; }
.chip { border: 1.5px solid var(--line); background: #fff; border-radius: 999px; padding: 6px 14px; font: 500 .9rem var(--sans); cursor: pointer; color: var(--ink); }
.chip.on { background: var(--ink); border-color: var(--ink); color: #fff; }

.homes { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; }
.home {
  background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
  cursor: pointer; transition: transform .25s, box-shadow .25s; border: 0; padding: 0; text-align: left; font: inherit; color: inherit;
}
.home:hover { transform: translateY(-5px); box-shadow: 0 18px 40px -16px rgba(60, 40, 20, .35); }
.home-img { aspect-ratio: 4/3; background: var(--sand-2); position: relative; overflow: hidden; }
.home-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s; }
.home:hover .home-img img { transform: scale(1.05); }
.home-img .badge { position: absolute; top: 10px; left: 10px; background: rgba(255, 255, 255, .92); border-radius: 999px; padding: 3px 10px; font-size: .78rem; font-weight: 700; }
.home-img.origin { display: grid; place-items: center; background: linear-gradient(135deg, var(--coral), #f39a70); color: #fff; font-family: var(--hand); font-size: 2rem; text-align: center; padding: 20px; }
.home-body { padding: 14px 16px 18px; }
.home-body .bld { font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; color: var(--coral); font-weight: 700; }
.home-body h4 { font-family: var(--serif); font-size: 1.12rem; margin: 4px 0 8px; line-height: 1.25; font-weight: 600; }
.home-meta { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: .85rem; color: var(--muted); }

/* GUESTS */
.countries { display: grid; gap: 7px; }
.country { display: grid; grid-template-columns: 28px 1fr 46px; align-items: center; gap: 10px; font-size: .95rem; }
.country .flag { font-size: 1.3rem; line-height: 1; }
.country .track { height: 8px; background: rgba(255, 255, 255, .1); border-radius: 4px; overflow: hidden; margin-top: 4px; }
.country .fill { height: 100%; background: var(--sun); width: 0; transition: width 1.2s cubic-bezier(.2, .8, .2, 1); border-radius: 4px; }
.country .n { text-align: right; color: #a9c3cf; font-variant-numeric: tabular-nums; font-size: .85rem; }
.flags-more { margin-top: 14px; font-size: 1.35rem; letter-spacing: 3px; line-height: 1.6; }

.sources { display: grid; gap: 12px; }
.source { display: grid; grid-template-columns: 1fr auto; font-size: .95rem; }
.source .track { grid-column: 1 / -1; height: 10px; background: rgba(255, 255, 255, .1); border-radius: 5px; overflow: hidden; margin-top: 4px; }
.source .fill { height: 100%; width: 0; background: var(--coral); border-radius: 5px; transition: width 1.2s cubic-bezier(.2, .8, .2, 1); }
.rating-big { margin-top: 30px; text-align: center; padding-top: 24px; border-top: 1px solid rgba(255, 255, 255, .12); }
.rating-big .stars { color: var(--sun); font-size: 1.6rem; letter-spacing: 4px; }
.rating-big b { display: block; font-family: var(--serif); font-size: 3.4rem; line-height: 1.1; }
.rating-big span { color: #a9c3cf; font-size: .9rem; }

.quotes-head { display: flex; align-items: center; justify-content: space-between; margin: 60px 0 20px; gap: 12px; }
.quotes-head h3 { margin: 0; font-size: 1.8rem; }
.btn { background: var(--sun); color: var(--ink); border: 0; border-radius: 999px; padding: 10px 18px; font: 700 .95rem var(--sans); cursor: pointer; }
.btn:hover { filter: brightness(1.06); }
.quotes { columns: 3 280px; column-gap: 18px; }
.quote {
  break-inside: avoid; background: var(--paper); color: var(--ink); border-radius: 16px; padding: 20px 20px 16px;
  margin-bottom: 18px; position: relative; animation: pop .5s ease both;
}
.quote:nth-child(3n+2) { transform: rotate(.6deg); }
.quote:nth-child(3n) { transform: rotate(-.5deg); }
@keyframes pop { from { opacity: 0; transform: translateY(14px); } }
.quote::before { content: '“'; font-family: var(--serif); font-size: 3.4rem; color: var(--coral); line-height: .7; display: block; height: 26px; }
.quote p { margin: 0 0 12px; font-size: .98rem; }
.quote .who { font-size: .82rem; color: var(--muted); }

/* US */
.polaroids { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 26px; padding-top: 20px; }
.polaroid { background: #fff; padding: 10px 10px 14px; box-shadow: var(--shadow); transition: transform .3s; }
.polaroid:nth-child(odd) { transform: rotate(-2deg); }
.polaroid:nth-child(even) { transform: rotate(1.6deg); }
.polaroid:hover { transform: rotate(0) scale(1.04); z-index: 2; }
.polaroid img { aspect-ratio: 1; object-fit: cover; width: 100%; }
.polaroid p { font-family: var(--hand); font-size: 1.35rem; text-align: center; margin: 8px 0 0; }

/* FINALE */
.finale {
  background: linear-gradient(180deg, var(--sea) 0%, var(--sea-deep) 60%, #0d2b38 100%);
  color: #f4efe8; text-align: center; padding: 120px 0 90px; position: relative; overflow: hidden;
}
.handwritten { font-family: var(--hand); font-size: clamp(2.4rem, 6.5vw, 4.4rem); line-height: 1.1; margin: 0; color: #fff; }
.finale-meta { color: #a9c3cf; margin: 18px 0 50px; font-size: .95rem; }
.thanks { min-height: 3em; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 28px; font-family: var(--serif); font-size: clamp(1.3rem, 3vw, 2rem); margin-bottom: 60px; }
.thanks span { opacity: 0; animation: fade 1s ease forwards; }
.thanks span:nth-child(odd) { color: var(--sun); }
@keyframes fade { to { opacity: .95; } }
.finale-logo { width: 90px; margin: 0 auto 16px; background: #fff; border-radius: 50%; padding: 12px; }
.finale-small { color: #a9c3cf; font-size: .9rem; }

/* MODAL */
.modal { border: 0; border-radius: 22px; padding: 0; width: min(920px, 94vw); max-height: 92vh; background: var(--paper); box-shadow: 0 30px 80px rgba(0, 0, 0, .4); }
.modal::backdrop { background: rgba(20, 15, 10, .6); backdrop-filter: blur(4px); }
.modal-close { position: absolute; top: 10px; right: 12px; z-index: 3; width: 40px; height: 40px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .92); font-size: 1.6rem; cursor: pointer; line-height: 1; }
.gallery { position: relative; background: #000; aspect-ratio: 16/10; }
.gallery img { width: 100%; height: 100%; object-fit: cover; }
.gallery button.nav-btn { position: absolute; top: 50%; transform: translateY(-50%); width: 42px; height: 42px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .9); font-size: 1.3rem; cursor: pointer; }
.gallery .prev { left: 12px; } .gallery .next { right: 12px; }
.gallery .count { position: absolute; bottom: 12px; right: 14px; color: #fff; background: rgba(0, 0, 0, .5); border-radius: 999px; padding: 2px 10px; font-size: .8rem; }
.modal-text { padding: 22px 26px 28px; }
.modal-text h3 { font-size: 1.7rem; margin: 4px 0 10px; }
.modal-stats { display: flex; flex-wrap: wrap; gap: 10px; margin: 14px 0; }
.modal-stats div { background: var(--sand); border-radius: 12px; padding: 8px 14px; font-size: .9rem; }
.modal-stats b { font-family: var(--serif); font-size: 1.2rem; display: block; }
.modal-text .summary { color: #4d433c; white-space: pre-line; font-size: .95rem; }
.modal-text .mq { margin-top: 16px; font-family: var(--serif); font-style: italic; border-left: 3px solid var(--coral); padding-left: 14px; }

/* RESPONSIVE */
@media (max-width: 820px) {
  .section { padding: 80px 0; }
  .two-col { grid-template-columns: 1fr; }
  .timeline::before { left: 10px; }
  .tl, .tl:nth-child(even) { width: 100%; margin-left: 0; padding: 0 0 46px 40px; text-align: left; }
  .tl:nth-child(odd) { text-align: left; }
  .tl:nth-child(odd)::after, .tl:nth-child(even)::after { left: 1px; right: auto; }
  .tl:nth-child(odd) .tl-photo { margin-left: 0; }
  .years { gap: 4px; height: 190px; }
  .year .v { font-size: .7rem; }
  .year .y { font-size: .7rem; }
  .nav-links { gap: 14px; font-size: .85rem; }
  .map { height: 360px; }
}
@media (max-width: 480px) {
  .nav-links a:nth-child(2) { display: none; }
  .stat b { font-size: 2.1rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .tl { opacity: 1; transform: none; }
  .hero-logo path { stroke-dashoffset: 0; }
  .thanks span { opacity: .95; }
  .chart .line { stroke-dashoffset: 0 !important; }
}
.map .leaflet-tile-pane { filter: grayscale(.55) sepia(.18) brightness(1.04) contrast(.95); }

/* team photos */
.tl-photo.snap { aspect-ratio: auto; background: #fff; padding: 10px 10px 8px; border-radius: 4px; transform: rotate(-1.2deg); max-width: 420px; }
.tl:nth-child(even) .tl-photo.snap { transform: rotate(1.2deg); }
.tl-photo.snap img { aspect-ratio: auto; height: auto; object-fit: contain; }
.tl-photo.snap span { display: block; font-family: var(--hand); font-size: 1.3rem; text-align: center; margin-top: 6px; color: var(--ink); }
.polaroids { grid-auto-flow: dense; }
.polaroid { cursor: zoom-in; margin: 0; }
.polaroid.featured { grid-column: span 2; grid-row: span 2; }
.polaroid.featured { display: flex; flex-direction: column; }
.polaroid.featured img { flex: 1; min-height: 0; aspect-ratio: auto; height: 100%; object-position: 40% 30%; }
.polaroid.featured p { font-size: 1.7rem; }
.polaroid p { line-height: 1.15; }
.gallery.photo-only { aspect-ratio: auto; background: #111; }
.gallery.photo-only img { max-height: 76vh; object-fit: contain; }
.handwritten-cap { font-family: var(--hand); font-size: 1.8rem; text-align: center; margin: 0; }
@media (max-width: 560px) { .polaroid.featured { grid-column: auto; grid-row: auto; } }
