/* Arttu & Tinya – sivuston tyylit.
   Järjestys: perusasetukset, kirjekuori ja salasana, sivun osiot ylhäältä alas,
   ja lopuksi näyttökoon mukaiset muutokset (1800px, 1000px, 700px, 360px, matala näyttö). */

/* ---------- Värit ja perusasetukset ---------- */

:root {
  --ink: #3d332a;
  --paper: #f2eee7;
  --sand: #e7e0d4;
  --linen: #e5ded2;
  --muted: #655b50;
  --button: #514131;
  --button-hover: #75604b;
  --light: #fffaf1;
  --error: #9b3434;
  --line: #b5a79444;
  --sans: Arial, sans-serif;
  --serif: Georgia, 'Times New Roman', serif;
  --display: 'Baskerville', 'Palatino Linotype', 'Book Antiqua', Georgia, serif;
}

* { box-sizing: border-box; }

html {
  scrollbar-color: #b9ac9b #eee9e1;
  scrollbar-width: thin;
}

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

body::-webkit-scrollbar { width: 10px; }
body::-webkit-scrollbar-track { background: #eee9e1; }
body::-webkit-scrollbar-thumb { background: #b9ac9b; border: 3px solid #eee9e1; border-radius: 8px; }

button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button, a, input, select, textarea { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid #8a6745;
  outline-offset: 5px;
}

[hidden] { display: none !important; }

h1, h2, h3, p { margin-top: 0; }
p { line-height: 1.85; }

h2, h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-style: normal;
  letter-spacing: -.045em;
}
h2 {
  font-size: clamp(32px, 3.6vw, 48px);
  line-height: 1.12;
  margin-bottom: 15px;
}
h3 { line-height: 1.2; }
h2 em, h3 em { font-weight: 400; font-style: italic; }

.eyebrow {
  font: 12px/1.6 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--muted);
}

.center { text-align: center; }

/* Vanhan ulkoasun koristeet ovat yhä HTML:ssä, mutta piilossa. */
.orn, .corner { display: none; }

.primary {
  display: inline-block;
  min-height: 46px;
  padding: 15px 23px;
  border: 1px solid var(--button);
  border-radius: 0;
  background: var(--button);
  color: #fffaf2;
  font: 12px/1.5 var(--sans);
  letter-spacing: .16em;
  text-transform: uppercase;
  text-decoration: none;
  transition: background .2s;
}
.primary:hover { background: var(--button-hover); }

.section {
  position: relative;
  margin: auto;
  padding: 70px 72px;
  scroll-margin-top: 24px;
}

/* ---------- Kirjekuori (aloitusnäkymä) ---------- */

.entry {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 100svh;
  overflow: hidden;
  background: #e4dccf;
  color: #493b2c;
  text-align: center;
}
.entry-inner {
  position: relative;
  width: 100%;
  padding: 44px 18px;
}
.entry .eyebrow { color: #6a5745; }
.entry h1 {
  font-size: clamp(42px, 6vw, 68px);
  font-style: normal;
  font-weight: 400;
  letter-spacing: -.04em;
  margin: 20px 0 30px;
}

.envelope-button {
  padding: 12px;
  border: 0;
  background: none;
  color: #5c4935;
}
.envelope {
  position: relative;
  width: min(290px, calc(100vw - 76px));
  aspect-ratio: 29 / 19;
  background: #d5c4aa;
  border: 1px solid #a48d6f;
  box-shadow: 0 18px 35px #6b4d2920;
  transition: transform .4s;
}
.envelope-button:hover .envelope { transform: translateY(-7px); }
.envelope::before,
.envelope::after {
  content: '';
  position: absolute;
  inset: 0;
}
.envelope::before {
  background: #f4eadb;
  clip-path: polygon(0 0, 100% 0, 50% 58%);
}
.envelope::after {
  background: #e5d5bd;
  clip-path: polygon(0 100%, 0 10%, 50% 65%, 100% 10%, 100% 100%);
}
.seal {
  position: absolute;
  z-index: 2;
  top: 40%;
  left: calc(50% - 29px);
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #6d5038;
  color: #f4e8d7;
  box-shadow: 0 3px 6px #4a2d3b33, inset 0 0 0 4px #d4b99133;
  font-style: italic;
}
.open-label {
  display: block;
  margin-top: 28px;
  font: 12px/1.6 var(--sans);
  letter-spacing: .2em;
  text-transform: uppercase;
}

/* ---------- Salasanaikkuna ---------- */

#password-dialog {
  width: min(440px, calc(100vw - 32px));
  max-width: calc(100vw - 32px);
  max-height: 90svh;
  padding: 30px 26px;
  border: 1px solid #aa967b;
  border-radius: 0;
  background: #f2ece2;
  color: #493b2c;
  text-align: center;
  box-shadow: 0 20px 80px #0004;
}
#password-dialog::backdrop {
  background: #2e2118a6;
  backdrop-filter: blur(5px);
}
#password-dialog h2 {
  font-size: 31px;
  letter-spacing: -.04em;
  margin: 15px 0;
}
#password-dialog p { font: 14px/1.8 var(--sans); }
#password-dialog .eyebrow { font-size: 12px; }
#password-dialog label {
  display: block;
  margin: 18px 0 6px;
  font: 13px/1.6 var(--sans);
  text-align: left;
}
#password-dialog input {
  width: 100%;
  min-height: 48px;
  padding: 13px;
  border: 1px solid #b6a58d;
  border-radius: 0;
  background: #fffaf2;
  color: #493a32;
  font: 16px/1.5 var(--sans);
}
#password-dialog .primary {
  width: 100%;
  margin: 16px 0 10px;
}
#password-dialog #password-cancel {
  display: block;
  min-height: 44px;
  margin: 6px auto 0;
  padding: 12px;
  border: 0;
  background: none;
  color: #6e5941;
}
#password-dialog #password-error {
  margin: 10px 0 0;
  color: var(--error);
  font-size: 13px;
}

/* ---------- Sivu ja yläpalkki ---------- */

#site {
  position: relative;
  background: var(--paper);
  overflow: clip;
}

#site > header {
  position: absolute;
  inset: 0 0 auto;
  z-index: 10;
  color: var(--light);
}
#site > header .nav {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 24px;
  min-height: 76px;
  padding: 22px 32px;
  border-bottom: 1px solid #fff3;
}
#site > header .header-meta { display: none; }
#site > header nav {
  display: flex;
  flex-wrap: nowrap;
  justify-content: center;
  gap: clamp(20px, 3.2vw, 48px);
}
#site > header nav a {
  padding: 10px 0;
  border-bottom: 1px solid transparent;
  font: 12px/1.5 var(--sans);
  letter-spacing: .18em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
}
#site > header nav a:hover { border-color: var(--light); }
.language-switch {
  position: absolute;
  top: 50%;
  right: 32px;
  display: flex;
  overflow: hidden;
  border: 1px solid #fff8;
  transform: translateY(-50%);
}
.language-switch button {
  min-width: 38px;
  min-height: 34px;
  padding: 7px 9px;
  border: 0;
  background: transparent;
  color: var(--light);
  font: 11px/1.5 var(--sans);
  letter-spacing: .08em;
}
.language-switch button[aria-pressed="true"] {
  background: var(--light);
  color: var(--ink);
}
.language-switch button:hover { background: #fff4; }
.language-switch button[aria-pressed="true"]:hover { background: #fff; }

/* ---------- Etusivun kuvanauha ---------- */

#home {
  position: relative;
  height: 96vh;
  height: 96svh;
  min-height: 600px;
  overflow: hidden;
  isolation: isolate;
}
#home::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, #1f1a176b 0%, #1f1a1714 25%, #1f1a1726 56%, #1f1a1766 100%);
  pointer-events: none;
}

.film-track {
  position: absolute;
  inset: 0 auto 0 0;
  display: flex;
  width: max-content;
  height: 100%;
  will-change: transform;
}
.film-track img {
  flex: none;
  width: 86vw;
  max-width: none;
  height: 100%;
  object-fit: cover;
  object-position: 50% 55%;
}

.hero-caption {
  position: absolute;
  inset: 90px 24px 78px;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  color: var(--light);
  text-align: center;
  text-shadow: 0 2px 24px #21180f55;
  pointer-events: none;
}
.hero-caption h1 {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: .12em;
  margin: 0 0 28px;
  font-family: var(--display);
  font-size: clamp(70px, 9.2vw, 146px);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -.045em;
  white-space: nowrap;
  text-shadow: 0 2px 32px #17120d55;
}
.hero-amp {
  font-size: .64em;
  font-style: italic;
  letter-spacing: -.07em;
  opacity: .92;
}
.hero-location,
.hero-date {
  margin: 0;
  font: 14px/1.6 var(--sans);
  letter-spacing: .2em;
}
.hero-location {
  margin-bottom: 12px;
  font-size: 13px;
  letter-spacing: .34em;
  text-transform: uppercase;
}
.hero-location::before {
  content: '';
  display: block;
  width: 48px;
  height: 1px;
  margin: 0 auto 23px;
  background: #fff9;
}

.film-controls {
  position: absolute;
  z-index: 3;
  left: 0;
  right: 0;
  bottom: 27px;
  text-align: center;
}
.film-controls button {
  min-height: 44px;
  padding: 12px 18px;
  border: 1px solid #fff9;
  border-radius: 0;
  background: #34271d40;
  backdrop-filter: blur(8px);
  color: var(--light);
  font: 11px/1.5 var(--sans);
  letter-spacing: .12em;
  text-transform: uppercase;
}
.film-controls button:focus-visible {
  outline: 3px solid white;
  outline-offset: 3px;
}

/* Nuolet luodaan js/hero.js:ssä. */
.film-arrow {
  position: absolute;
  top: 50%;
  z-index: 5;
  display: grid;
  place-items: center;
  width: 52px;
  height: 64px;
  min-height: 44px;
  padding: 0;
  border: 1px solid #fff6;
  border-radius: 28px;
  background: #30251b44;
  backdrop-filter: blur(5px);
  color: #fffaf2;
  font: 300 38px/1 Georgia, serif;
  transform: translateY(-50%);
  transition: background .2s;
}
.film-arrow:hover { background: #30251b88; }
.film-arrow:focus-visible {
  outline: 3px solid #fffaf2;
  outline-offset: 4px;
}
.film-prev { left: 22px; }
.film-next { right: 22px; }

/* ---------- Laskuri ---------- */

.countdown-section {
  padding: 25px 24px 22px;
  background: #dcd3c4;
}
.countdown-section > .eyebrow {
  margin-bottom: 12px;
  color: #655849;
  font-size: 15px;
}
.countdown {
  display: flex;
  justify-content: center;
  gap: clamp(16px, 4vw, 44px);
  margin: 0 auto 13px;
}
.countdown > div { min-width: 60px; }
.countdown strong {
  display: block;
  color: #574735;
  font-family: Georgia, serif;
  font-size: clamp(30px, 4vw, 42px);
  font-weight: 400;
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}
.countdown span {
  display: block;
  margin-top: 5px;
  color: #5a4d3f;
  font: 12px/1.6 var(--sans);
  letter-spacing: .14em;
  text-transform: uppercase;
}
.countdown-note {
  margin: 0;
  color: #655849;
  font: 13px/1.6 var(--sans);
}

/* ---------- Meistä (kuva taustana) ---------- */

#story {
  isolation: isolate;
  display: grid;
  align-items: center;
  gap: 70px;
  min-height: 690px;
  margin: 0;
  padding: 90px clamp(32px, 7vw, 132px);
  overflow: hidden;
  background: #35352f;
  color: #fffaf2;
  text-align: left;
}
#story::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, #1d211cde 0%, #1d211cb8 29%, #1d211c73 57%, #1d211c0d 100%);
  pointer-events: none;
}
.aura-story-photo {
  position: absolute;
  inset: 0;
  z-index: -2;
  margin: 0;
}
.aura-story-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 56% 48%;
}
.aura-story-copy {
  position: relative;
  z-index: 1;
  width: min(100%, 570px);
  min-width: 0;
}
#story h2 {
  max-width: 570px;
  margin: 0 0 28px;
  color: #fffaf2;
  font-family: var(--display);
  font-size: clamp(38px, 4.1vw, 61px);
  letter-spacing: -.04em;
  text-wrap: balance;
}
#story p {
  max-width: 510px;
  margin: 0 0 20px;
  font: 16px/1.95 var(--sans);
  text-shadow: 0 1px 8px #0003;
}
#story .primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  margin-top: 10px;
  padding: 14px 23px;
  border-color: #f3ece0;
  background: #f3ece0;
  color: #44382c;
  letter-spacing: .14em;
}
#story .primary:hover {
  border-color: #fffaf2;
  background: #fffaf2;
}

/* ---------- Ohjelma (käännettävät päiväkortit) ---------- */

.weekend {
  position: relative;
  overflow: hidden;
  background: var(--paper);
}
.weekend h2 { margin-bottom: 28px; }

.cards-scroll {
  overflow: auto;
  padding: 2px 2px 14px;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: #a9977e var(--linen);
}
.days {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.flip-card {
  position: relative;
  min-height: 420px;
  perspective: 1200px;
  scroll-snap-align: start;
}
.flip-toggle {
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
}
/* Puolet ovat päällekkäin samassa ruudukon solussa, joten kortti kasvaa pidemmän puolen mittaiseksi. */
.flip-inner {
  position: relative;
  display: grid;
  width: 100%;
  height: 100%;
  min-height: 420px;
  transform-style: preserve-3d;
  transition: transform .65s;
}
.flip-toggle[aria-pressed="true"] .flip-inner { transform: rotateY(180deg); }

.flip-face {
  grid-area: 1 / 1;
  display: flex;
  flex-direction: column;
  padding: 24px 20px;
  border: 1px solid #b9ab9655;
  background: var(--linen);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}
.flip-front::before {
  content: attr(data-aura-day);
  margin: 0 0 25px;
  color: #a28d73;
  font: 42px/1 Georgia, serif;
}
.flip-back {
  background: #f8f5ef;
  transform: rotateY(180deg);
}
.flip-face small {
  color: #64543f;
  font: 12px/1.6 var(--sans);
  letter-spacing: .11em;
  text-transform: uppercase;
}
.flip-face strong {
  margin: 15px 0 18px;
  font-size: 25px;
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -.035em;
}
.flip-back strong {
  margin: 12px 0;
  font-size: 24px;
}
.day-description { font: 14px/1.75 var(--sans); }
.flip-hint {
  margin-top: auto;
  padding-top: 15px;
  color: #6e5b46;
  font: 12px/1.6 var(--sans);
  letter-spacing: .04em;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.flip-back small,
.flip-back .flip-hint,
.schedule-row b { color: #6d5841; }
.flip-back .flip-hint { flex-shrink: 0; }

.schedule { display: block; }
.schedule-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2.25fr);
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid var(--line);
  font: 13px/1.45 var(--sans);
}
.schedule-no-time { grid-template-columns: 1fr; }
.schedule-row b {
  font-weight: 400;
  font-variant-numeric: tabular-nums;
}
.schedule-row span { overflow-wrap: break-word; }

/* ---------- Matka ja majoitus ---------- */

.editorial-travel {
  background: var(--sand);
  text-align: left;
}
.travel-heading {
  margin-bottom: 40px;
  text-align: left;
}
.travel-heading h2 { margin: 10px 0 8px; }
.script-accent {
  margin: 0;
  color: #705b46;
  font-family: Georgia, serif;
  font-size: 20px;
  font-style: italic;
  line-height: 1.5;
}

.travel-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 64px;
  margin: 0 0 48px;
}
.travel-row figure {
  margin: 0;
  min-width: 0;
}
.travel-row img {
  display: block;
  width: 100%;
  height: 380px;
  object-fit: cover;
}
.travel-row img.villa-detail { height: 340px; }

.travel-copy h3 {
  margin: 12px 0 20px;
  font-size: 35px;
  line-height: 1.15;
}
.travel-copy p {
  max-width: 740px;
  margin: 0 0 17px;
  font: 15px/1.85 var(--sans);
}
.travel-copy .eyebrow {
  color: #6b5642;
  font: 12px/1.6 var(--sans);
  letter-spacing: .16em;
}
.travel-copy h4 {
  margin: 24px 0 10px;
  font-size: 19px;
  font-weight: 400;
}
.travel-copy .fine-note {
  color: #65553f;
  font: 13px/1.7 var(--sans);
}
.lodging-list {
  display: grid;
  gap: 9px;
  margin-top: -7px;
}
.lodging-option {
  padding: 12px 16px;
  border-left: 2px solid #b5a794;
  background: #ffffff55;
}
.lodging-option p { margin: 0; }
.lodging-option p:first-child {
  margin-bottom: 3px;
  color: #564632;
  font-style: italic;
}

.venue-map {
  margin-top: 8px;
  padding-top: 28px;
  border-top: 1px solid #aa967b66;
}
.venue-map h3 {
  margin: 22px 0 8px;
  font-size: 28px;
}
.venue-map p {
  color: #65553f;
  font: 14px/1.8 var(--sans);
}
.venue-map .map-note { font-size: 13px; }
.venue-map iframe {
  display: block;
  width: 100%;
  height: 280px;
  margin: 22px 0 16px;
  border: 0;
}

/* ---------- Kuvagalleria ---------- */

.gallery-band { background: var(--paper); }
.gallery-band .section { padding: 64px 72px; }
.photos {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: start;
  gap: 18px;
}
.photo-button {
  margin: 0;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: #d7cdbd;
}
.photo-button img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ---------- Muistaminen ---------- */

.section.gift-section {
  padding: 42px 24px;
  border-top: 1px solid var(--line);
  background: var(--paper);
  text-align: center;
}
.gift-section h2 {
  margin: 0 0 18px;
  font-family: Georgia, serif;
  font-size: clamp(30px, 3.4vw, 42px);
  letter-spacing: -.035em;
}
.gift-section p {
  max-width: 680px;
  margin: 0 auto;
  font: 16px/1.9 var(--sans);
}

/* ---------- Ilmoittautuminen ---------- */

.rsvp {
  display: grid;
  grid-template-columns: .85fr 1.15fr;
  align-items: start;
  gap: 65px;
  padding: 66px 72px;
  background: var(--sand);
}
.rsvp h2 { margin: 14px 0 22px; }

.form-card { position: relative; }
.form-card label {
  display: block;
  margin-bottom: 20px;
  color: #675744;
  font: 14px/1.6 var(--sans);
}
.form-card input,
.form-card select,
.form-card textarea {
  display: block;
  width: 100%;
  min-height: 48px;
  margin-top: 7px;
  padding: 12px 13px;
  border: 1px solid #b6a58d66;
  border-radius: 0;
  background: #f4efe5;
  color: var(--ink);
  font: 16px/1.5 var(--sans);
}
.form-card textarea {
  min-height: 110px;
  resize: vertical;
}
.form-card button { width: 100%; }

/* Roskapostiansa: piilotettu kenttä, jonka vain botit täyttävät. */
.form-card .hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

#rsvp-error {
  margin: 16px 0 0;
  color: var(--error);
  font: 14px/1.6 var(--sans);
}

.thanks {
  padding: 24px 0;
  text-align: center;
}
.thanks p { font: 15px/1.8 var(--sans); }
.thanks .primary { min-height: 44px; }

/* ---------- Alatunniste ---------- */

footer {
  padding: 31px 24px;
  background: #3d3024;
  color: #f0e6d5;
  text-align: center;
}
footer p {
  margin: 0;
  font: 12px/1.7 var(--sans);
  letter-spacing: .13em;
}
footer button {
  min-height: 44px;
  margin: 8px 0 0;
  border: 0;
  background: none;
  color: #d4c1a6;
  font: 13px/1.6 var(--sans);
}

/* ---------- Näyttökoon mukaan ---------- */

@media (min-width: 1800px) {
  #story { min-height: 760px; }
  .hero-caption h1 { font-size: 156px; }
}

@media (max-width: 1000px) {
  .section { padding: 54px 38px; }
  .gallery-band .section { padding: 48px 38px; }

  #home {
    height: 95svh;
    min-height: 570px;
  }

  #story {
    gap: 38px;
    min-height: 660px;
    padding: 70px 48px;
  }
  .aura-story-copy { width: min(100%, 520px); }

  .days {
    grid-template-columns: repeat(4, minmax(220px, 1fr));
    width: max-content;
    min-width: 100%;
  }
  .flip-card { width: 220px; }

  .travel-row { gap: 38px; }
  .rsvp { gap: 38px; }
}

@media (max-width: 700px) {
  .section { padding: 38px 23px; }
  .section.gift-section { padding: 32px 24px; }
  .gallery-band .section { padding: 32px 23px; }

  #site > header .nav {
    gap: 0;
    min-height: 0;
    padding: 17px 16px;
  }
  #site > header nav {
    width: calc(100% - 82px);
    margin-right: 82px;
    gap: clamp(15px, 4.5vw, 26px);
  }
  .language-switch { right: 12px; }
  #site > header nav a {
    display: flex;
    align-items: center;
    min-height: 44px;
    padding: 0;
    font-size: 11px;
    letter-spacing: .08em;
  }

  .entry h1 { font-size: 45px; }

  #home {
    height: 94vh;
    height: 94svh;
    min-height: 520px;
  }
  .film-track img {
    width: 90vw;
    object-position: 50% 54%;
  }
  .hero-caption { inset: 76px 14px 78px; }
  .hero-caption h1 {
    gap: .1em;
    margin-bottom: 24px;
    font-size: clamp(43px, 13.6vw, 86px);
    letter-spacing: -.05em;
  }
  .hero-location {
    font-size: 12px;
    letter-spacing: .28em;
  }
  .hero-location::before {
    width: 38px;
    margin-bottom: 20px;
  }
  .hero-date {
    font-size: 13px;
    letter-spacing: .15em;
  }
  .film-controls { bottom: 23px; }
  .film-arrow {
    width: 44px;
    height: 52px;
    font-size: 32px;
  }
  .film-prev { left: 10px; }
  .film-next { right: 10px; }

  .countdown-section { padding: 22px 12px; }
  .countdown-section > .eyebrow { font-size: 14px; }
  .countdown { gap: 18px; }
  .countdown > div { min-width: 48px; }
  .countdown strong { font-size: 32px; }
  .countdown span { letter-spacing: .03em; }
  .countdown-note { font-size: 12px; }

  #story {
    align-items: end;
    gap: 0;
    min-height: 780px;
    padding: 46px 25px;
  }
  #story::after {
    background: linear-gradient(180deg, #1d211c12 0%, #1d211c26 22%, #1d211cb3 43%, #1d211ced 73%, #1d211cf2 100%);
  }
  .aura-story-photo img { object-position: 55% 35%; }
  .aura-story-copy {
    width: 100%;
    max-width: 540px;
    margin: 0 auto;
  }
  #story h2 {
    max-width: 480px;
    margin-bottom: 22px;
    font-size: clamp(36px, 8.7vw, 49px);
  }
  #story p {
    margin-bottom: 17px;
    font-size: 15px;
    line-height: 1.9;
  }
  #story .primary { margin-top: 7px; }

  /* Päiväkortit vieritetään sivusuunnassa reunasta reunaan. */
  .weekend .section { padding-right: 0; }
  .cards-scroll {
    margin: 0;
    padding: 2px 23px 16px 2px;
    scroll-padding-left: 2px;
  }
  .days {
    grid-template-columns: repeat(4, minmax(240px, 77vw));
    gap: 12px;
    min-width: 0;
  }
  .flip-card { width: auto; }
  .flip-face { padding: 25px 23px; }
  .flip-face strong { font-size: 29px; }
  .day-description { font-size: 15px; }

  .travel-heading { margin-bottom: 28px; }
  .travel-heading h2 { font-size: 35px; }
  .script-accent { font-size: 19px; }
  .travel-row {
    grid-template-columns: 1fr;
    gap: 24px;
    margin-bottom: 36px;
  }
  .travel-row.reverse figure { order: 1; }
  .travel-row.reverse .travel-copy { order: 2; }
  .travel-row img,
  .travel-row img.villa-detail { height: 285px; }
  .travel-copy h3 { font-size: 31px; }
  .venue-map iframe { height: 260px; }

  .photos { gap: 9px; }

  .gift-section p { font-size: 15px; }

  .rsvp {
    grid-template-columns: 1fr;
    gap: 22px;
  }
  .rsvp h2 { font-size: 36px; }

  footer { padding: 28px 20px; }
  footer p { letter-spacing: .08em; }
}

@media (max-width: 360px) {
  #site > header nav { gap: 12px; }
  .hero-caption h1 { font-size: 43px; }
  #story {
    min-height: 810px;
    padding: 40px 22px;
  }
}

@media (max-height: 560px) and (min-width: 701px) {
  #home {
    height: 100svh;
    min-height: 430px;
  }
  .hero-caption h1 {
    margin-bottom: 12px;
    font-size: 76px;
  }
  .hero-location::before { margin-bottom: 12px; }
}

/* ---------- Liikkeen vähentäminen ---------- */

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
