/* A rotated phone keeps the touch layout, with natural document height. */
@media (orientation: landscape) and (max-width: 1000px) and (max-height: 500px) and (pointer: coarse) and (hover: none) {
  html { scroll-snap-type: none !important; }
  body { overflow-x: clip; }
  body > main { min-width: 0; }
  .home-page .v6-hero, .home-page .v6-rsvp,
  .travel-compact-page .v6-travel-hero {
    height: auto; min-height: max(320px, var(--mobile-screen));
  }
  .home-page .v6-hero-title { padding-top: 26px; }
  .home-page .v6-hero-title h1 { font-size: 60px; }
  .home-page .v6-hero-meta { font-size: 16px; }
  .home-page .mobile-intro-directory {
    height: auto; min-height: 0; padding-block: 28px;
  }
  .home-page .mobile-intro-directory .home-featured-directory {
    grid-template-rows: 220px 180px 180px; gap: 18px;
  }
  .home-page .mobile-directory-intro h2 { font-size: 32px; }
  .travel-compact-page .travel-value,
  .travel-compact-page .travel-booking-compact {
    height: auto; min-height: 0; padding-block: 28px; gap: 22px;
  }
  .travel-compact-page .travel-benefit-grid { grid-template-rows: repeat(3, 130px); }
  .travel-compact-page .travel-booking-compact { grid-template-rows: 260px auto auto; }
  .note-page .note-opening-screen {
    height: 500px; min-height: 500px;
  }
  .note-page .note-reading-screen {
    height: auto; min-height: 0; padding-block: 28px;
  }
  .note-page .note-letter .note-body { gap: 20px; max-width: 620px; margin-inline: auto; }
  .note-page .note-letter .note-body p { line-height: 1.42 !important; }
  .weekend-story-page main {
    height: auto; min-height: 0; padding-bottom: 16px;
  }
  .weekend-story-page .ws-stage, .weekend-story-page .ws-panel.is-active {
    height: auto; min-height: 0; flex: 0 0 auto;
  }
  .weekend-story-page .ws-panel figure,
  .weekend-story-page .ws-panel[data-panel="2"] figure {
    height: 260px; min-height: 260px; flex: 0 0 260px;
  }
  .weekend-story-page .ws-copy { padding-inline: 24px; }
  .rsvp-form-page .rsvp-form-wrap, .rsvp-form-page .rsvp-form,
  .faq-page main, .registry-page main { height: auto; min-height: min-content; }
  .travel-benefit-reveal.is-inline-gallery {
    overflow-y: auto; overscroll-behavior: contain;
    height: calc(100dvh - 24px); max-height: calc(100dvh - 24px);
  }
  .travel-benefit-reveal.is-inline-gallery .travel-benefit-detail { flex: 0 0 auto; }
  .travel-benefit-reveal.is-inline-gallery .travel-inline-detail img { max-height: 200px; }
  .faq-directory .faq-topic-screen { height: auto; min-height: 0; }
  .travel-compact-page .travel-value > .travel-fineprint { top: 0; }
  .travel-benefit-reveal.is-inline-gallery.is-mobile-open {
    top: 12px; bottom: 12px; height: calc(100dvh - 24px); max-height: calc(100dvh - 24px);
  }
  .topbar nav, .topbar nav.open { padding-block: 64px 20px; }
  body > footer { flex: 0 0 auto; }
}

/* Landscape composition is independent of portrait's one-screen sizing. */
@media (orientation: landscape) and (max-width: 1000px) and (max-height: 500px) and (pointer: coarse) and (hover: none) {
  html:has(body.home-page), html:has(body.travel-compact-page) {
    scroll-snap-type: none !important;
  }
  .home-page main, .travel-compact-page main {
    display: block !important; height: auto !important; overflow: visible !important;
  }
  .home-page .v6-hero, .home-page .v6-rsvp {
    position: relative; display: grid !important; grid-template-columns: 48% 52%;
    height: auto !important; min-height: 360px !important; max-height: none !important;
    padding: 0 !important; overflow: hidden; background: #f3eee4;
  }
  .home-page .v6-hero-bg, .home-page .v6-rsvp > img {
    position: absolute !important; inset: 0 0 0 auto !important;
    width: 52% !important; height: 100% !important; max-height: none !important;
    object-fit: cover; object-position: center; transform: none !important;
    mask-image: none; -webkit-mask-image: none;
  }
  .home-page .v6-hero-vignette, .home-page .v6-rsvp-shade { display: none !important; }
  .home-page .v6-hero-title, .home-page .v6-rsvp > div:last-child {
    position: relative !important; inset: auto !important; transform: none !important;
    grid-column: 1; width: auto !important; max-width: none !important;
    display: flex; flex-direction: column; justify-content: center; align-items: center;
    padding: 36px 24px !important; margin: 0 !important; text-align: center !important;
    color: #183024;
  }
  .home-page .v6-hero-title > p {
    padding: 0; background: transparent; border: 0; backdrop-filter: none;
    text-shadow: none; font-size: 15px; letter-spacing: .06em; width: auto;
    margin: 0 0 20px;
  }
  .home-page .hero-invitation-detail { font-size: 16px; }
  .home-page .v6-hero-title h1 {
    font-size: clamp(37px, 5.3vw, 53px) !important; line-height: 1.05; gap: .06em;
    white-space: nowrap; margin: 0;
  }
  .home-page .v6-hero-title h1 i { font-size: .7em; }
  .home-page .v6-hero-meta { margin-top: 20px !important; font-size: 14px; line-height: 1.5; }
  .home-page .v6-scroll { display: none; }
  .home-page .v6-rsvp > div:last-child > p { display: none; }
  .home-page .v6-rsvp h2 {
    font-size: 43px !important; line-height: 1.1; margin: 0 0 24px;
    color: #183024; text-shadow: none;
  }
  .home-page .home-rsvp-action { margin: 0; width: auto; }
  .home-page .v6-rsvp .home-rsvp-simple { width: 150px; min-height: 44px; margin: 0; }

  .home-page .mobile-intro-directory {
    display: block !important; height: auto !important; min-height: 0 !important;
    max-height: none !important; overflow: visible !important; padding: 32px !important;
  }
  .home-page .mobile-intro-directory .v6-statement {
    display: block; flex: none; height: auto !important; min-height: 0;
    padding: 0 0 28px; margin: 0;
  }
  .home-page .mobile-directory-intro h2 { font-size: 30px; }
  .home-page .mobile-directory-intro h2 span { display: inline; }
  .home-page .mobile-directory-intro h2 span + span::before { content: ' '; }
  .home-page .mobile-intro-directory .home-featured-directory {
    display: grid !important; flex: none !important; height: auto !important;
    min-height: 0 !important; max-height: none !important; overflow: visible !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto !important; grid-auto-rows: 220px; gap: 24px 18px;
    margin: 0; padding: 0;
  }
  .home-page .mobile-intro-directory .home-featured-directory .v6-link-panel {
    display: grid !important; grid-template-rows: 180px 40px !important;
    height: 220px !important; min-height: 0 !important; max-height: none !important;
    margin: 0; padding: 0; overflow: hidden;
  }
  .home-page .mobile-intro-directory .home-featured-directory .v6-link-panel:first-child {
    grid-column: 1 / -1;
  }
  .home-page .mobile-intro-directory .home-featured-directory .directory-photo {
    display: block; position: relative; grid-row: 1;
    height: 180px !important; min-height: 0 !important; overflow: hidden;
  }
  .home-page .mobile-intro-directory .home-featured-directory .v6-link-panel .v8-tile-art {
    position: relative !important; inset: auto !important; grid-row: 1;
    height: 180px !important; min-height: 0 !important; max-height: none !important;
    width: 100% !important; object-fit: cover;
  }
  .home-page .mobile-intro-directory .home-featured-directory .v6-link-panel > div:last-child {
    grid-row: 2; height: 40px; min-height: 0; padding: 8px 0 0;
  }
  .home-page .mobile-intro-directory .home-featured-directory .v6-link-panel h3 {
    font-size: 21px !important; line-height: 1.2;
  }

  .travel-compact-page .v6-travel-hero {
    position: relative; display: flex !important; align-items: center;
    height: auto !important; min-height: 360px !important; max-height: none !important;
    padding: 28px 32px !important; box-sizing: border-box;
  }
  .travel-compact-page .v6-travel-title {
    position: relative !important; inset: auto !important; transform: none !important;
    width: min(100%, 540px); margin: 0 !important; padding: 0;
  }
  .travel-compact-page .v6-travel-title h1 { font-size: 46px; line-height: 1.05; margin: 12px 0; }
  .travel-compact-page .v6-travel-title p { font-size: 17px; line-height: 1.3; }
  .travel-compact-page .v6-travel-title .travel-hero-actions { margin-top: 22px; }
  .travel-compact-page .v6-travel-hero .v6-hero-vignette {
    background: linear-gradient(90deg, rgba(10,31,21,.8), rgba(10,31,21,.2));
  }
  .travel-compact-page .travel-value {
    display: block !important; position: relative; height: auto !important;
    min-height: 0 !important; max-height: none !important; overflow: visible !important;
    padding: 32px !important; background: #f3eee4;
  }
  .travel-compact-page .travel-benefits-group {
    display: block !important; position: static !important;
    height: auto !important; min-height: 0 !important; flex: none !important;
  }
  .travel-compact-page .travel-benefits-title-group { margin: 0 0 26px; }
  .travel-compact-page .travel-benefit-grid {
    display: grid !important; position: static !important; flex: none !important;
    height: auto !important; min-height: 0 !important; max-height: none !important;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-rows: repeat(2, 140px) !important; gap: 12px;
  }
  .travel-compact-page .travel-benefit-grid button:nth-child(n) {
    height: 140px !important; min-height: 0 !important;
    padding: 20px 14px; box-sizing: border-box;
  }
  .travel-compact-page .travel-benefit-grid button h3 { font-size: 23px; }
  .travel-compact-page .travel-value > .travel-fineprint {
    position: static !important; inset: auto !important; margin: 24px 0 0;
    font-size: 13px; line-height: 1.4;
  }
  .travel-compact-page .travel-booking-compact {
    display: flex !important; flex-direction: column; position: relative;
    height: auto !important; min-height: 0 !important; max-height: none !important;
    overflow: hidden; padding: 0 32px 32px !important; gap: 24px;
    clear: both; background: #183024;
  }
  .travel-compact-page .travel-booking-image {
    position: relative !important; flex: none !important;
    width: calc(100% + 64px); height: 260px !important; min-height: 260px !important;
    margin: 0 -32px !important;
  }
  .travel-compact-page .travel-booking-heading, .travel-compact-page .travel-booking-facts {
    position: relative !important; inset: auto !important;
    flex: none !important; width: 100%; height: auto !important; margin: 0;
  }
  .travel-compact-page .travel-booking-heading h2 { font-size: 38px; }
  .travel-compact-page .booking-mobile-payment { max-width: 600px; margin-inline: auto; }
}

/* One continuous photograph, with an ivory fade behind the invitation. */
@media (orientation: landscape) and (max-width: 1000px) and (max-height: 500px) and (pointer: coarse) and (hover: none) {
  .home-page .v6-hero {
    display: flex !important; align-items: stretch;
    min-height: max(360px, var(--mobile-screen)) !important;
  }
  .home-page .v6-hero-bg {
    inset: 0 auto 0 0 !important; width: 125% !important; height: 100% !important;
    object-fit: cover; object-position: center 38%;
  }
  .home-page .v6-hero .v6-hero-vignette {
    display: block !important; position: absolute; inset: 0;
    background: linear-gradient(90deg,
      rgba(243,238,228,.97) 0%, rgba(243,238,228,.93) 28%,
      rgba(243,238,228,.80) 39%, rgba(243,238,228,.35) 49%,
      rgba(243,238,228,0) 60%);
  }
  .home-page .v6-hero .v6-hero-title {
    z-index: 2; flex: 0 0 46%; box-sizing: border-box;
    width: 46% !important; padding: 32px 24px !important;
    background: transparent;
  }
}

/* Match the landscape invitation's seamless photo treatment at the closing RSVP. */
@media (orientation: landscape) and (max-width: 1000px) and (max-height: 500px) and (pointer: coarse) and (hover: none) {
  .home-page .v6-rsvp {
    display: flex !important; align-items: stretch;
    min-height: max(360px, var(--mobile-screen)) !important;
  }
  .home-page .v6-rsvp > img {
    inset: 0 auto 0 0 !important; width: 125% !important; height: 100% !important;
    object-fit: cover; object-position: center bottom;
  }
  .home-page .v6-rsvp .v6-rsvp-shade {
    display: block !important; position: absolute; inset: 0;
    background: linear-gradient(90deg,
      rgba(243,238,228,.97) 0%, rgba(243,238,228,.93) 28%,
      rgba(243,238,228,.80) 39%, rgba(243,238,228,.35) 49%,
      rgba(243,238,228,0) 60%);
  }
  .home-page .v6-rsvp > div:last-child {
    z-index: 2; flex: 0 0 46%; box-sizing: border-box;
    width: 46% !important; padding: 32px 24px !important;
    background: transparent;
  }
}
