/* ==========================================================================
   Chali Resort & Conference Center
   Direction: The place carries it · Type: Archivo · Bayfront Limestone & Deep Bay
   ========================================================================== */

:root {
  /* Palette: Sampled directly from Chali logo (#3090A0, #60C090, #FFB040) */
  --bg: #f8fbfb;
  --surface: #e7f4f5;
  --surface-strong: #d0eaec;
  --ink: #0b2e36;
  --muted: #285a64;
  --accent: #ffb040;
  --accent-hover: #f09c24;
  --accent-ink: #0b2e36;
  --lagoon: #196e7c;
  --lagoon-ink: #ffffff;
  --palm: #60c090;
  --gold: #ffb040;
  --field-1: #0b3b45;
  --field-1-surface: #12505d;
  --field-1-ink: #ffffff;
  --field-1-muted: #bee5e9;

  /* Typography — 5 steps max, Archivo only */
  --font-sans: "Archivo", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --step-small: clamp(0.8125rem, 0.79rem + 0.1vw, 0.875rem);
  --step-body: clamp(1.0625rem, 1rem + 0.2vw, 1.15rem);
  --step-lead: clamp(1.25rem, 1.1rem + 0.55vw, 1.5rem);
  --step-head: clamp(1.85rem, 1.25rem + 2.5vw, 3.35rem);
  --step-display: clamp(2.2rem, 1.4rem + 3.8vw, 4.75rem);

  /* Layout */
  --margin: clamp(20px, 2.5vw, 32px);
  --max-w: 1440px;
  --section-gap: clamp(96px, 11vw, 168px);
  --radius-btn: 0px;
  --radius-card: 6px;

  /* Motion Tokens (Emil Kowalski + Awwwards study) */
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  --t-press: 140ms;
  --t-hover: 180ms;
  --t-ui: 240ms;
  --t-reveal: 820ms;
  --t-open: 1150ms;
}

/* Browser Surface Theming */
::selection {
  background-color: var(--accent);
  color: var(--accent-ink);
}

html {
  scroll-behavior: smooth;
  scrollbar-color: var(--accent) var(--bg);
  background-color: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-size: var(--step-body);
  line-height: 1.5;
  color: var(--ink);
  background-color: var(--bg);
  overflow-x: clip;
  caret-color: var(--accent);
  -webkit-tap-highlight-color: transparent;
}

body.menu-open {
  overflow: hidden;
}

img,
video {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-underline-offset: 0.22em;
  text-decoration-thickness: 1px;
}

button,
input {
  font: inherit;
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.tabular {
  font-variant-numeric: tabular-nums;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 999;
  padding: 12px 20px;
  background-color: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  text-decoration: none;
}

.skip-link:focus {
  left: var(--margin);
  top: 12px;
}

.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background-color: var(--accent);
  transform-origin: 0 50%;
  transform: scaleX(0);
  z-index: 80;
  pointer-events: none;
}

.text-link-light,
.text-link-accent {
  display: inline-flex;
  align-items: center;
  font-size: var(--step-small);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 0.3em;
  transition: opacity var(--t-hover) ease, color var(--t-hover) ease;
}

.text-link-light {
  color: var(--field-1-ink);
}

.text-link-accent {
  color: var(--lagoon);
}

@media (hover: hover) and (pointer: fine) {
  .text-link-light:hover,
  .text-link-accent:hover {
    opacity: 0.72;
  }
}

/* Understated editorial text tabs (replaces boxy button pills) */
.text-tab-row {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}

.text-tab {
  padding: 10px 0;
  min-height: 44px;
  border: 0;
  background-color: transparent;
  color: var(--muted);
  font-size: var(--step-small);
  font-weight: 600;
  cursor: pointer;
  position: relative;
  transition: color var(--t-hover) ease, transform var(--t-press) var(--ease-out);
}

.text-tab:active {
  transform: scale(0.97);
}

.text-tab::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background-color: var(--lagoon);
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform 260ms var(--ease-out);
}

.text-tab.is-active {
  color: var(--ink);
}

.text-tab.is-active::after {
  transform: scaleX(1);
}

@media (hover: hover) and (pointer: fine) {
  .text-tab:hover {
    color: var(--ink);
  }
}

.container {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--margin);
}

/* ==========================================================================
   Buttons — Square-cornered, flat, single fill, tactile press feedback
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 22px;
  border: 0;
  border-radius: var(--radius-btn);
  font-size: var(--step-small);
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition:
    background-color var(--t-hover) ease,
    color var(--t-hover) ease,
    transform var(--t-press) var(--ease-out);
}

.btn:active {
  transform: scale(0.97);
}

.btn-large {
  padding: 15px 28px;
  font-size: var(--step-small);
}

.btn-tall {
  min-height: 52px;
  font-size: var(--step-body);
}

.btn-full {
  width: 100%;
}

.btn-primary {
  background-color: var(--accent);
  color: var(--accent-ink);
}

.btn-secondary {
  background-color: var(--surface);
  color: var(--ink);
}

.btn-ghost-light {
  background-color: rgba(10, 61, 76, 0.78);
  color: var(--field-1-ink);
}

.btn-light-solid {
  background-color: var(--bg);
  color: var(--ink);
}

@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover {
    background-color: var(--accent-hover);
  }

  .btn-secondary:hover {
    background-color: var(--surface-strong);
  }

  .btn-ghost-light:hover {
    background-color: var(--field-1);
  }

  .btn-light-solid:hover {
    background-color: var(--surface);
  }
}

/* ==========================================================================
   Header — Plain flat bar, no glass blur, color adapts on scroll
   ========================================================================== */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  color: var(--field-1-ink);
  background-color: transparent;
  transition:
    background-color 280ms ease,
    color 280ms ease;
}

.site-header.is-scrolled {
  background-color: var(--bg);
  color: var(--ink);
}

.site-header.is-dark-chapter {
  background-color: var(--field-1);
  color: var(--field-1-ink);
}

.site-header.is-dark-chapter .brand-logo {
  filter: brightness(0) invert(1);
}

.header-inner {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding: 16px var(--margin);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}

.brand-logo {
  height: 44px;
  width: auto;
  filter: brightness(0) invert(1);
  transition: filter 280ms ease;
}

.site-header.is-scrolled .brand-logo {
  filter: none;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.site-nav a {
  text-decoration: none;
  font-size: var(--step-small);
  font-weight: 400;
  opacity: 0.92;
  transition: opacity var(--t-hover) ease;
}

@media (hover: hover) and (pointer: fine) {
  .site-nav a:hover {
    opacity: 1;
    text-decoration: underline;
  }
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 0;
  background-color: transparent;
  color: inherit;
  cursor: pointer;
  transition: transform var(--t-press) var(--ease-out);
}

.nav-toggle:active {
  transform: scale(0.95);
}

.mobile-menu {
  background-color: var(--field-1);
  color: var(--field-1-ink);
  padding: 24px var(--margin) 36px;
  transform-origin: top center;
  animation: drawerSlide 260ms cubic-bezier(0.32, 0.72, 0, 1) both;
}

.mobile-menu[hidden] {
  display: none;
}

@keyframes drawerSlide {
  from {
    opacity: 0;
    transform: translateY(-12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.mobile-menu nav {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mobile-menu a {
  display: flex;
  align-items: center;
  min-height: 48px;
  font-size: var(--step-lead);
  text-decoration: none;
  padding-block: 6px;
  transition: transform var(--t-press) var(--ease-out), opacity var(--t-hover) ease;
}

.mobile-menu a:active {
  transform: translateX(6px);
  opacity: 0.75;
}

/* ==========================================================================
   HERO — Full-bleed video background (chali-resort.mp4)
   ========================================================================== */
.curtain-group {
  position: relative;
}

.hero {
  position: sticky;
  top: 0;
  z-index: 1;
  width: 100%;
  min-height: 100svh;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  background-color: var(--field-1);
  color: var(--field-1-ink);
  transform-origin: center top;
  will-change: transform, opacity;
}

.hero-media {
  position: absolute;
  inset: -6% 0;
  width: 100%;
  height: 112%;
  will-change: transform;
}

.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* Localized bottom neutral scrim only - keeps focal bay/pool video unobstructed */
.hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient( /* taste-skill-ignore */
    to top,
    rgba(0, 0, 0, 0.78) 0%,
    rgba(0, 0, 0, 0.34) 40%,
    rgba(0, 0, 0, 0.16) 100%
  );
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding: 120px var(--margin) clamp(32px, 5vh, 56px);
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 32px;
}

.hero-copy {
  max-width: 780px;
}

.hero-title {
  margin: 0;
  font-size: var(--step-display);
  font-weight: 400;
  line-height: 0.98;
  letter-spacing: -0.025em;
  color: var(--field-1-ink);
}

.line-mask {
  display: block;
  overflow: hidden;
}

.line-inner {
  display: block;
}

.hero-lead {
  margin: 28px 0 0;
  max-width: 44ch;
  font-size: var(--step-lead);
  line-height: 1.38;
  color: var(--field-1-ink);
}

.hero-cta-row {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 24px;
}

.hero-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 16px;
  text-align: right;
}

.hero-facts {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: var(--step-small);
  color: var(--field-1-muted);
}

.video-audio-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border: 0;
  background-color: rgba(10, 61, 76, 0.82);
  color: var(--field-1-ink);
  font-size: var(--step-small);
  font-weight: 600;
  cursor: pointer;
  transition:
    background-color var(--t-hover) ease,
    transform var(--t-press) var(--ease-out);
}

.video-audio-btn:active {
  transform: scale(0.97);
}

.video-audio-btn .icon-unmuted {
  display: none;
}

.video-audio-btn[aria-pressed="true"] .icon-muted {
  display: none;
}

.video-audio-btn[aria-pressed="true"] .icon-unmuted {
  display: block;
}

/* ==========================================================================
   SECTION 1: INTRO — Heading captions a panorama + Shutter Image signature
   ========================================================================== */
.section-intro {
  position: relative;
  z-index: 2;
  padding-top: var(--section-gap);
  background-color: var(--bg);
}

.intro-header {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  align-items: end;
  gap: 40px;
  margin-bottom: 48px;
}

.display-head {
  margin: 0;
  font-size: var(--step-display);
  font-weight: 400;
  line-height: 0.98;
  letter-spacing: -0.025em;
}

.intro-captions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}

.caption-col {
  margin: 0;
  font-size: var(--step-small);
  line-height: 1.55;
  color: var(--ink);
}

.panorama-wrap {
  width: 100%;
  height: clamp(360px, 68svh, 720px);
  overflow: hidden;
  background-color: var(--surface);
}

/* Signature Move: Shutter image clip-path + inner scale settle */
.js-motion .panorama-wrap[data-shutter] {
  clip-path: inset(0 0 14% 0);
  transition: clip-path var(--t-open) var(--ease-expo);
}

.js-motion .panorama-wrap[data-shutter].is-open {
  clip-path: inset(0 0 0 0);
}

.panorama-inner {
  width: 100%;
  height: 114%;
  margin-top: -7%;
  will-change: transform;
}

.panorama-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1);
  transition: transform var(--t-open) var(--ease-expo);
}

.js-motion .panorama-wrap[data-shutter]:not(.is-open) .panorama-img {
  transform: scale(1.12);
}

/* ==========================================================================
   SECTION 2: SHOWCASE — Band of unequal panels + Interactive 10-Room Inspector
   ========================================================================== */
.section-showcase {
  position: relative;
  z-index: 3;
  padding-top: var(--section-gap);
  padding-bottom: var(--section-gap);
  background-color: var(--bg);
}

.showcase-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: end;
  gap: 32px;
  margin-bottom: 48px;
}

.section-head {
  margin: 0;
  font-size: var(--step-head);
  font-weight: 400;
  line-height: 1.02;
  letter-spacing: -0.02em;
}

.section-sub {
  margin: 0;
  max-width: 52ch;
  font-size: var(--step-body);
  color: var(--muted);
}

/* Dealt Blueprint: flex-grow 5, 2, 3, 2; expands on hover/focus */
.unequal-band {
  width: 100%;
  height: clamp(380px, 64svh, 660px);
  display: flex;
  gap: 0;
  overflow: hidden;
  background-color: var(--field-1);
}

.band-panel {
  position: relative;
  padding: 0;
  border: 0;
  background-color: var(--field-1);
  overflow: hidden;
  cursor: pointer;
  text-align: left;
  min-width: 0;
  transition: flex-grow 500ms var(--ease-out);
}

.band-panel:nth-child(1) { flex: 5 1 0%; }
.band-panel:nth-child(2) { flex: 2 1 0%; }
.band-panel:nth-child(3) { flex: 3 1 0%; }
.band-panel:nth-child(4) { flex: 2 1 0%; }

@media (hover: hover) and (pointer: fine) {
  .unequal-band:hover .band-panel {
    flex-grow: 2;
  }

  .unequal-band .band-panel:hover {
    flex-grow: 6;
  }
}

.band-panel img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 600ms var(--ease-out);
}

@media (hover: hover) and (pointer: fine) {
  .band-panel:hover img {
    transform: scale(1.04);
  }
}

.panel-corner-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient( /* taste-skill-ignore */
    135deg,
    rgba(0, 0, 0, 0.72) 0%,
    rgba(0, 0, 0, 0.14) 48%,
    transparent 75%
  );
  pointer-events: none;
}

.panel-title {
  position: absolute;
  top: 24px;
  left: 24px;
  font-size: var(--step-lead);
  font-weight: 400;
  line-height: 1.1;
  color: var(--field-1-ink);
  z-index: 2;
}

.band-caption {
  margin: 24px 0 0;
  max-width: 68ch;
  font-size: var(--step-small);
  color: var(--muted);
}

/* Scroll-Driven Sticky Room Stage (replaces accordion & filter button list) */
.room-scroll-layout {
  margin-top: clamp(56px, 7vw, 96px);
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}

.room-sticky-frame {
  position: sticky;
  top: 96px;
}

.room-visual-stack {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background-color: var(--field-1);
  touch-action: pan-y;
}

.room-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.06);
  transition:
    opacity 620ms var(--ease-expo),
    transform 820ms var(--ease-expo);
}

.room-layer.is-active {
  opacity: 1;
  transform: scale(1);
}

.room-visual-caption {
  margin-top: 16px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

.room-caption-title {
  font-size: var(--step-body);
  font-weight: 600;
  color: var(--ink);
}

.room-caption-meta {
  font-size: var(--step-small);
  color: var(--muted);
}

.room-chapters {
  display: flex;
  flex-direction: column;
  gap: clamp(32px, 5vw, 56px);
  padding-block: 0 32px;
}

.room-chapter {
  padding: 28px;
  background-color: transparent;
  transition:
    background-color 360ms var(--ease-out),
    transform 360ms var(--ease-out);
}

.room-chapter.is-active {
  background-color: var(--surface);
  transform: translateX(0);
}

.room-chapter-title {
  margin: 0;
  font-size: clamp(1.5rem, 1.15rem + 1.4vw, 2.25rem);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.room-chapter-types {
  margin: 10px 0 0;
  font-size: var(--step-small);
  font-weight: 600;
  color: var(--lagoon);
}

.room-chapter-desc {
  margin: 14px 0 0;
  color: var(--ink);
  max-width: 52ch;
}

.room-chapter .text-link-accent {
  margin-top: 22px;
}

.amenity-list {
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 24px;
  font-size: var(--step-small);
  color: var(--muted);
}

.amenity-list li {
  padding-left: 16px;
  position: relative;
}

.amenity-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 6px;
  height: 6px;
  background-color: var(--lagoon);
}

/* ==========================================================================
   SECTION 3: HOW IT WORKS — Interactive Day Itinerary (One verb at a time)
   ========================================================================== */
.section-itinerary {
  position: relative;
  z-index: 4;
  background-color: var(--bg);
}

.itinerary-intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 32px;
  padding-bottom: 48px;
}

.itinerary-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.mode-switcher {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.verb-stack {
  display: flex;
  flex-direction: column;
}

.verb-panel {
  position: relative;
  width: 100%;
  min-height: 70svh;
  overflow: clip;
  display: flex;
  align-items: flex-end;
  background-color: var(--field-1);
  color: var(--field-1-ink);
}

.verb-media {
  position: absolute;
  inset: -6% 0;
  width: 100%;
  height: 112%;
  will-change: transform;
}

.verb-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.verb-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient( /* taste-skill-ignore */
    to top,
    rgba(0, 0, 0, 0.74) 0%,
    rgba(0, 0, 0, 0.26) 55%,
    rgba(0, 0, 0, 0.28) 100%
  );
}

.verb-inner {
  position: relative;
  z-index: 2;
  padding-block: clamp(40px, 6vw, 72px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 460px);
  align-items: end;
  gap: 32px;
}

.verb-word {
  font-size: clamp(3.5rem, 9.5vw, 8.5rem);
  font-weight: 400;
  line-height: 0.92;
  letter-spacing: -0.03em;
  color: var(--field-1-ink);
}

.verb-caption-box {
  padding: 24px 28px;
  background-color: rgba(11, 59, 69, 0.92);
  color: var(--field-1-ink);
  transform: translateY(12px);
  transition: transform 540ms var(--ease-expo);
}

.verb-panel.is-active .verb-caption-box {
  transform: translateY(0);
}

.verb-time {
  margin: 0;
  font-size: var(--step-small);
  font-weight: 600;
  color: var(--gold);
}

.verb-title {
  margin: 8px 0 0;
  font-size: var(--step-lead);
  font-weight: 600;
  line-height: 1.15;
}

.verb-desc {
  margin: 10px 0 0;
  font-size: var(--step-small);
  line-height: 1.5;
  color: var(--field-1-ink);
}

/* Editorial Day Summary Band */
.itinerary-planner-band {
  background-color: var(--surface);
  padding-block: clamp(56px, 7vw, 96px);
}

.planner-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.9fr);
  gap: 48px;
  align-items: start;
}

.planner-heading {
  margin: 0;
  font-size: var(--step-head);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.02em;
}

.planner-copy {
  margin: 16px 0 24px;
  max-width: 48ch;
  color: var(--muted);
}

.planner-cta-wrap {
  margin-top: 24px;
}

.planner-card {
  background-color: var(--bg);
  padding: clamp(24px, 3vw, 36px);
}

.planner-card-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}

.planner-card-head h4 {
  margin: 0;
  font-size: var(--step-lead);
  font-weight: 600;
}

.planner-card-head span {
  font-size: var(--step-small);
  color: var(--lagoon);
  font-weight: 600;
}

.planner-timeline {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.planner-timeline li {
  display: grid;
  grid-template-columns: 128px 1fr;
  align-items: baseline;
  gap: 12px;
  padding: 12px 14px;
  background-color: var(--surface);
  font-size: var(--step-small);
}

.timeline-time {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.timeline-name {
  font-weight: 600;
}

.shuttle-toggle {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: var(--step-small);
  color: var(--ink);
  cursor: pointer;
}

.shuttle-toggle input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: var(--accent);
}

/* ==========================================================================
   SECTION 4: FEATURES — Rows with margin photographs (Dark Bay Field: Dining)
   ========================================================================== */
.section-dining {
  position: relative;
  z-index: 5;
  background-color: var(--field-1);
  color: var(--field-1-ink);
  padding-block: var(--section-gap);
}

.dining-axis-head {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  align-items: end;
  gap: 40px;
  margin-bottom: clamp(64px, 8vw, 112px);
}

.dining-lead {
  margin: 0;
  color: var(--field-1-muted);
  max-width: 48ch;
}

.dining-rows {
  display: flex;
  flex-direction: column;
  gap: clamp(64px, 8vw, 108px);
}

.dining-row {
  display: grid;
  grid-template-columns: minmax(0, 0.35fr) minmax(0, 0.4fr) minmax(0, 0.25fr);
  align-items: start;
  gap: 32px;
}

.dining-text {
  grid-column: 1 / 3;
  max-width: 46ch;
}

.dining-title {
  margin: 0;
  font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.6rem);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.02em;
}

.dining-copy {
  margin: 14px 0 0;
  color: var(--field-1-muted);
  max-width: 38ch;
}

.dining-photo {
  margin: 0;
  justify-self: end;
  overflow: hidden;
  background-color: var(--field-1-surface);
  will-change: transform;
}

.dining-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-tall {
  width: 260px;
  aspect-ratio: 4 / 5;
}

.photo-wide {
  width: 340px;
  aspect-ratio: 3 / 2;
}

.photo-square {
  width: 230px;
  aspect-ratio: 1 / 1;
}

/* ==========================================================================
   SECTION 5: WORK — Full panels, one midline row (Conferences & Celebrations)
   ========================================================================== */
.section-events {
  position: relative;
  z-index: 6;
  background-color: var(--bg);
  padding-top: var(--section-gap);
}

.events-header-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 40px;
}

.plate-stack {
  position: relative;
}

.plate-panel {
  position: sticky;
  top: 0;
  width: 100%;
  height: 92svh;
  overflow: hidden;
  background-color: var(--field-1);
  color: var(--field-1-ink);
  transform-origin: center top;
  will-change: transform;
}

.plate-panel:nth-child(1) { z-index: 1; }
.plate-panel:nth-child(2) { z-index: 2; }
.plate-panel:nth-child(3) { z-index: 3; }

.plate-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.06);
  will-change: transform, opacity;
}

.plate-midline {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  min-height: 92px;
  padding: 20px var(--margin);
  background-color: rgba(11, 59, 69, 0.9);
  display: grid;
  grid-template-columns: 140px 1fr auto;
  align-items: center;
  gap: 24px;
  will-change: opacity, transform;
}

.plate-left,
.plate-right {
  font-size: var(--step-small);
  font-weight: 600;
  color: var(--gold);
}

.plate-title {
  margin: 0;
  font-size: var(--step-lead);
  font-weight: 400;
  line-height: 1.15;
  color: var(--field-1-ink);
}

/* ==========================================================================
   SECTION 6: GALLERY: Interactive Asymmetric Photo Archive + Lightbox
   ========================================================================== */
.section-gallery {
  position: relative;
  z-index: 7;
  background-color: var(--bg);
  padding-block: var(--section-gap);
}

.gallery-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: end;
  gap: 28px;
  margin-bottom: 36px;
}

.gallery-controls-col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
}

.gallery-filters {
  margin-top: 0;
  margin-bottom: 0;
}

.gallery-count {
  margin: 0;
  font-size: var(--step-small);
  color: var(--muted);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-rows: 220px;
  grid-auto-flow: dense;
  gap: 12px;
}

.gallery-tile {
  padding: 0;
  border: 0;
  background-color: var(--surface);
  overflow: hidden;
  cursor: pointer;
}

.gallery-tile.tile-tall {
  grid-row: span 2;
}

.gallery-tile.tile-wide {
  grid-column: span 2;
}

.gallery-tile.is-hidden {
  display: none;
}

.gallery-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 520ms var(--ease-out);
}

@media (hover: hover) and (pointer: fine) {
  .gallery-tile:hover > img {
    transform: scale(1.04);
  }
}

/* ==========================================================================
   SECTION 7: CONTACT — Visit card on a photograph (Full-bleed beachfront)
   ========================================================================== */
.section-contact {
  position: sticky;
  top: 0;
  z-index: 8;
  min-height: 100svh;
  overflow: clip;
  background-color: var(--field-1);
}

.contact-bg {
  position: absolute;
  inset: -6% 0;
  width: 100%;
  height: 112%;
  will-change: transform;
}

.contact-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.contact-stage {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding: 64px var(--margin);
  display: flex;
  justify-content: flex-end;
  align-items: flex-start;
  min-height: 100svh;
}

.visit-card {
  position: sticky;
  top: 88px;
  width: 100%;
  max-width: 420px;
  background-color: var(--bg);
  color: var(--ink);
  border-radius: var(--radius-card);
  padding: 32px;
}

.visit-title {
  margin: 0;
  font-size: var(--step-lead);
  font-weight: 400;
  line-height: 1.1;
}

.visit-address {
  margin: 14px 0 0;
  font-size: var(--step-body);
  line-height: 1.45;
  color: var(--ink);
}

.visit-hours {
  margin: 24px 0 0;
  padding: 18px 0 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: var(--step-small);
}

.hours-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.hours-row dt {
  color: var(--muted);
}

.hours-row dd {
  margin: 0;
  font-weight: 600;
  text-align: right;
}

.visit-landmarks {
  margin-top: 22px;
  padding: 14px 16px;
  background-color: var(--surface);
  font-size: var(--step-small);
  color: var(--ink);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.visit-landmarks p {
  margin: 0;
}

.visit-phones {
  margin-top: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  font-size: var(--step-small);
  font-weight: 600;
}

.visit-actions {
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.visit-map-link {
  font-size: var(--step-small);
  color: var(--muted);
  text-align: center;
}

/* ==========================================================================
   SECTION 8: FOOTER — Photograph half, menu half (split)
   ========================================================================== */
.site-footer {
  position: relative;
  z-index: 9;
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 86svh;
  background-color: var(--field-1);
  color: var(--field-1-ink);
}

.footer-photo {
  overflow: hidden;
  background-color: var(--field-1-surface);
}

.footer-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.footer-panel {
  padding: clamp(40px, 5vw, 72px) clamp(24px, 4vw, 64px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 48px;
}

.footer-logo {
  height: 44px;
  width: auto;
  filter: brightness(0) invert(1);
}

.footer-menu {
  margin-top: 40px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.footer-menu a {
  font-size: clamp(1.5rem, 2.4vw, 2.4rem);
  font-weight: 600;
  line-height: 1.1;
  text-decoration: none;
  color: var(--field-1-ink);
  transition:
    transform var(--t-ui) var(--ease-out),
    opacity var(--t-hover) ease;
}

@media (hover: hover) and (pointer: fine) {
  .footer-menu:hover a {
    opacity: 0.45;
  }

  .footer-menu a:hover {
    opacity: 1;
    transform: translateX(12px);
  }
}

.footer-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  font-size: var(--step-small);
  color: var(--field-1-muted);
}

.footer-info-grid p {
  margin: 0 0 6px;
}

.footer-label {
  font-weight: 600;
  color: var(--gold);
  margin-bottom: 10px;
}

.footer-legal {
  margin: 28px 0 0;
  font-size: var(--step-small);
  color: var(--field-1-muted);
}

/* ==========================================================================
   Interactive Lightbox Dialog (Emil: enter from scale(0.95), centered modal)
   ========================================================================== */
.lightbox {
  width: min(92vw, 1180px);
  max-height: 92svh;
  padding: 0;
  border: 0;
  background-color: var(--field-1);
  color: var(--field-1-ink);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45); /* taste-skill-ignore */
}

.lightbox::backdrop {
  background-color: rgba(10, 18, 19, 0.88);
}

.lightbox[open] {
  animation: lightboxIn 260ms var(--ease-out) both;
}

@keyframes lightboxIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.lightbox-frame {
  padding: 20px 24px 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.lightbox-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: var(--step-small);
  color: var(--field-1-muted);
}

.lightbox-close {
  border: 0;
  padding: 8px 14px;
  background-color: var(--field-1-surface);
  color: var(--field-1-ink);
  font-weight: 600;
  cursor: pointer;
  transition: transform var(--t-press) var(--ease-out);
}

.lightbox-close:active {
  transform: scale(0.97);
}

.lightbox-stage {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #081011;
  min-height: 54svh;
  max-height: 70svh;
  overflow: hidden;
  touch-action: none;
}

.lightbox-stage img {
  max-height: 70svh;
  width: auto;
  object-fit: contain;
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border: 0;
  background-color: rgba(14, 26, 28, 0.85);
  color: var(--field-1-ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.lightbox-prev { left: 16px; }
.lightbox-next { right: 16px; }

.lightbox-caption {
  margin: 0;
  font-size: var(--step-body);
  color: var(--field-1-ink);
  text-align: center;
}

/* ==========================================================================
   Scroll-triggered Section Entrances (Safe progressive enhancement)
   ========================================================================== */
.js-motion [data-reveal="up"] {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity var(--t-reveal) var(--ease-expo),
    transform var(--t-reveal) var(--ease-expo);
}

.js-motion [data-reveal="up"].is-visible {
  opacity: 1;
  transform: translateY(0);
}

.js-motion [data-reveal="line"] .line-inner {
  transform: translateY(108%);
  transition: transform 900ms var(--ease-expo);
}

.js-motion [data-reveal="line"].is-visible .line-inner {
  transform: translateY(0);
}

.js-motion [data-reveal="line"].is-visible .line-mask:nth-child(2) .line-inner {
  transition-delay: 110ms;
}

/* ==========================================================================
   Responsive — Tablet (<= 960px) & Phone (<= 640px)
   ========================================================================== */
@media (max-width: 960px) {
  .site-nav {
    display: none;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .hero-content {
    grid-template-columns: 1fr;
    align-items: end;
  }

  .hero-meta {
    align-items: flex-start;
    text-align: left;
  }

  .intro-header,
  .showcase-head,
  .itinerary-intro,
  .dining-axis-head,
  .planner-grid,
  .room-scroll-layout,
  .verb-inner,
  .gallery-header {
    grid-template-columns: 1fr;
  }

  .room-sticky-frame {
    position: relative;
    top: 0;
    z-index: 1;
    background-color: transparent;
    padding-bottom: 0;
    margin-bottom: 36px;
  }

  .room-visual-stack {
    aspect-ratio: 16 / 9;
  }

  .room-chapters {
    gap: 56px;
    padding-bottom: 24px;
  }

  .room-chapter {
    padding: 24px;
    transform: none;
  }

  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-rows: 200px;
  }

  .dining-row {
    grid-template-columns: 1fr;
  }

  .dining-text {
    grid-column: 1;
  }

  .dining-photo {
    justify-self: start;
    width: min(100%, 420px);
  }

  .site-footer {
    grid-template-columns: 1fr;
  }

  .footer-photo {
    height: 46svh;
  }
}

@media (max-width: 640px) {
  .intro-captions,
  .amenity-list,
  .footer-info-grid {
    grid-template-columns: 1fr;
  }

  /* Phone blueprint for unequal band: 2x2 unequal rows 64/36 and 36/64 */
  .unequal-band {
    display: grid;
    grid-template-columns: 1fr 1fr;
    height: 76svh;
  }

  .band-panel:nth-child(1),
  .band-panel:nth-child(2),
  .band-panel:nth-child(3),
  .band-panel:nth-child(4) {
    flex: initial;
  }

  .verb-panel {
    min-height: 54svh;
  }

  .plate-panel {
    position: relative;
    height: 58svh;
  }

  .plate-midline {
    top: auto;
    bottom: 20px;
    transform: none;
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .gallery-grid {
    grid-template-columns: 1fr;
    grid-auto-rows: 240px;
  }

  .gallery-tile.tile-tall,
  .gallery-tile.tile-wide {
    grid-column: span 1;
    grid-row: span 1;
  }

  .section-contact {
    position: relative;
  }

  .section-contact,
  .contact-stage {
    min-height: auto;
  }

  .contact-stage {
    padding: 48px var(--margin);
    align-items: flex-end;
  }

  .visit-card {
    position: static;
    max-width: 100%;
    padding: 24px;
  }

  .planner-timeline li {
    grid-template-columns: 1fr auto;
  }

  .timeline-time {
    grid-column: 1 / -1;
  }
}

/* ==========================================================================
   Accessibility — Reduced Motion keeps content & gentle fades, drops travel
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .hero,
  .plate-panel,
  .section-contact {
    position: relative;
  }

  .js-motion [data-reveal="up"],
  .js-motion [data-reveal="line"] .line-inner,
  .js-motion .panorama-wrap[data-shutter],
  .js-motion .panorama-wrap[data-shutter] .panorama-img {
    opacity: 1;
    transform: none;
    clip-path: none;
    transition: opacity 200ms ease;
  }

  .lightbox[open] {
    animation: none;
  }
}
