/* Amarea Villas Kea — styles (draft 02)
   Flow taken from the reference sites: quiet text-led pages, small photos in a lot of space,
   the villas shown like a catalogue, one grotesk in sentence case. No full-bleed banners.
   Palettes from the villas' own photos (../design/palette.html). */

@font-face {
  font-family: "Host Grotesk";
  src: url("fonts/host-grotesk-latin.woff2") format("woff2");
  font-weight: 300 600;
  font-style: normal;
  font-display: swap;
}

:root {
  --limewash: #F3EFE8;
  --linen: #E4D9C8;
  --hillside: #B49674;
  --schist: #6E604F;
  --shadow: #2A2C2A;
  --aegean: #2F4F66;
  --rule: rgba(42, 44, 42, 0.14);

  --bay-ground: #D8CBBB;
  --bay-accent: #5E472C;
  --breeze-ground: #D5C5B2;
  --breeze-accent: #3A5E79;

  --accent: var(--aegean);
  --ground: var(--linen);

  --font: "Host Grotesk", "Helvetica Neue", Arial, sans-serif;
  --small: 0.8125rem;          /* 13px */
  --body: 0.9375rem;           /* 15px */
  --mid: clamp(1.375rem, 1.1rem + 0.9vw, 1.875rem);
  --big: clamp(1.875rem, 1.1rem + 3vw, 3.75rem);

  --gutter: clamp(16px, 2.4vw, 32px);
  --edge: clamp(16px, 3vw, 40px);
  --section: clamp(96px, 13vw, 184px);
}

.house--bay { --accent: var(--bay-accent); --ground: var(--bay-ground); }
.house--breeze { --accent: var(--breeze-accent); --ground: var(--breeze-ground); }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  margin: 0;
  background: var(--limewash);
  color: var(--shadow);
  font: 400 var(--body)/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "tnum" 1;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.22em; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-weight: 400; }
:focus-visible { outline: 1.5px solid var(--accent); outline-offset: 3px; }

.skip { position: absolute; left: -999px; top: 8px; background: var(--shadow); color: var(--limewash); padding: 8px 12px; z-index: 100; }
.skip:focus { left: 8px; }

.page { padding: 0 var(--edge); }
.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); }
.muted { color: var(--schist); }
.small { font-size: var(--small); line-height: 1.45; }

/* ---------- header ----------
   After Rooster, LORE, Aman and Kalesma: links left, the name centred, booking right
   as a small outlined pill (Ett Hem, OEM). Hides while scrolling down, returns on the way up. */
.site-header {
  position: fixed; inset: 0 0 auto; z-index: 40;
  background: var(--limewash);
  padding: 0 var(--edge);
  border-bottom: 1px solid transparent;
  transition: border-color .3s ease, transform .45s cubic-bezier(.2,.6,.2,1);
}
.site-header.is-scrolled { border-bottom-color: var(--rule); }
.site-header.is-hidden { transform: translateY(-100%); }
.bar { height: 64px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px; }

.nav { display: flex; gap: 22px; }
.nav a { text-decoration: none; padding: 4px 0; }
.nav a:hover, .nav a[aria-current="true"] { text-decoration: underline; }

.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-size: 1.1875rem; font-weight: 500; letter-spacing: -0.02em; }

.header-end { justify-self: end; display: flex; align-items: center; gap: 20px; }
.clock { color: var(--schist); font-variant-numeric: tabular-nums; white-space: nowrap; }
.pill {
  display: inline-block; text-decoration: none; white-space: nowrap;
  border: 1px solid var(--shadow); border-radius: 999px; padding: 7px 15px;
  transition: background .25s ease, color .25s ease;
}
.pill:hover { background: var(--shadow); color: var(--limewash); }

.menu-toggle { display: none; font: inherit; color: var(--shadow); background: none; border: 0; padding: 4px 0; cursor: pointer; justify-self: start; }

/* full-screen menu for phones (after Aman and OEM) */
.menu {
  position: fixed; inset: 64px 0 0; z-index: 39; background: var(--limewash);
  padding: 32px var(--edge) 40px; display: flex; flex-direction: column; justify-content: space-between;
}
.menu[hidden] { display: none; }
.menu nav { display: flex; flex-direction: column; gap: 10px; }
.menu nav a { font: 300 var(--big)/1.1 var(--font); letter-spacing: -0.025em; text-decoration: none; }
.nav .bay, .menu .bay { color: var(--bay-accent); }
.nav .breeze, .menu .breeze { color: var(--breeze-accent); }
body.menu-open { overflow: hidden; }

/* ---------- opening ---------- */
.opening { padding-top: 80px; }
.opening-photo { margin: 0 0 clamp(40px, 5vw, 72px); }
.opening-photo img { width: 100%; height: calc(100svh - 80px - var(--edge)); min-height: 420px; object-fit: cover; object-position: 50% 30%; background: var(--linen); }
.statement {
  grid-column: 1 / span 10;
  font: 300 var(--big)/1.1 var(--font);
  letter-spacing: -0.025em;
}
.tint { color: var(--accent); }
.statement .tint, .stay .tint, .route .tint { color: var(--aegean); }

/* ---------- the houses ---------- */
.houses { padding-top: var(--section); }
.houses-head { align-items: baseline; padding-bottom: 16px; border-bottom: 1px solid var(--rule); }
.houses-head h2 { grid-column: 1 / span 3; font-size: var(--body); }
.houses-head nav { grid-column: 4 / span 5; display: flex; gap: 24px; }
.houses-note { grid-column: 9 / -1; text-align: right; }

.house { padding: 40px 0 clamp(72px, 9vw, 128px); align-items: start; }
.house + .house { border-top: 1px solid var(--rule); padding-top: 40px; }
.house-info { grid-column: 1 / span 3; position: sticky; top: 96px; }
.house-info h3 { font: 400 var(--mid)/1.15 var(--font); letter-spacing: -0.015em; margin-bottom: 16px; }
.house-info > p { margin-bottom: 24px; max-width: 34ch; }
.spec { margin: 0 0 28px; padding: 0; border-top: 1px solid var(--rule); }
.spec div { display: flex; justify-content: space-between; gap: 16px; padding: 9px 0; border-bottom: 1px solid var(--rule); }
.spec dt { color: var(--schist); }
.spec dd { margin: 0; text-align: right; }
.ask { color: var(--accent); text-decoration: underline; }
.ask:hover { text-decoration-thickness: 2px; }

.catalogue {
  grid-column: 5 / -1;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 40px var(--gutter);
  margin: 0;
}
.catalogue figure { margin: 0; }
.catalogue .frame { background: var(--ground); overflow: hidden; }
.catalogue img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; transition: opacity .4s ease; }
[data-gallery] img { cursor: zoom-in; }
[data-gallery] .frame:hover img { opacity: .9; }
.catalogue figcaption { display: flex; justify-content: space-between; gap: 12px; margin-top: 10px; font-size: var(--small); }
.catalogue figcaption span:last-child { color: var(--schist); }
.catalogue .wide { grid-column: span 2; }
.catalogue figure { display: flex; flex-direction: column; }
.catalogue .wide .frame { flex: 1 1 auto; position: relative; min-height: 0; }
.catalogue .wide img { position: absolute; inset: 0; height: 100%; aspect-ratio: auto; }

/* ---------- getting here ---------- */
.route-section { padding-top: var(--section); }
.route-section h2 { grid-column: 1 / span 3; font-size: var(--body); }
.route-body { grid-column: 4 / -1; }
.route { list-style: none; margin: 0 0 40px; padding: 0; display: flex; align-items: center; }
.route .stop { font: 300 var(--mid)/1.1 var(--font); letter-spacing: -0.015em; white-space: nowrap; }
.route .leg { flex: 1 1 auto; position: relative; margin: 0 16px; min-width: 64px; text-align: center; }
.route .leg::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; border-top: 1px solid var(--shadow); }
.route .leg span { position: relative; background: var(--limewash); padding: 0 10px; font-size: var(--small); color: var(--schist); }
.route-notes { list-style: none; margin: 0 0 20px; padding: 0; max-width: 58ch; color: var(--schist); }
.route-notes li + li { margin-top: 4px; }
.route-map { display: inline-block; font-size: var(--small); }

/* ---------- stay ---------- */
.stay { padding: var(--section) 0; }
.stay-text { grid-column: 1 / span 5; }
.stay-text p.lede { font: 300 var(--mid)/1.25 var(--font); letter-spacing: -0.015em; margin-bottom: 28px; }
.stay-text .small + .small { margin-top: 6px; }
.stay-photo { margin: clamp(48px, 6vw, 88px) 0 0; width: 46%; }
.stay-photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.enquiry { grid-column: 7 / -1; display: grid; grid-template-columns: 1fr 1fr; gap: 28px var(--gutter); }
.enquiry .full { grid-column: 1 / -1; }
.enquiry fieldset { border: 0; margin: 0; padding: 0; }
.enquiry legend, .enquiry label > span { display: block; font-size: var(--small); color: var(--schist); margin-bottom: 8px; padding: 0; }
.choices { display: flex; gap: 8px; flex-wrap: wrap; }
.choices label { position: relative; }
.choices input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.choices label span {
  display: inline-block; padding: 9px 16px; border: 1px solid var(--rule); border-radius: 999px;
  color: var(--shadow); font-size: var(--body); margin: 0; transition: background .2s ease, border-color .2s ease;
}
.choices input:checked + span { background: var(--shadow); border-color: var(--shadow); color: var(--limewash); }
.choices input:focus-visible + span { outline: 1.5px solid var(--aegean); outline-offset: 3px; }
.enquiry input[type="date"], .enquiry input[type="number"], .enquiry input[type="text"], .enquiry textarea {
  width: 100%; font: inherit; color: var(--shadow); background: transparent;
  border: 0; border-bottom: 1px solid var(--shadow); border-radius: 0; padding: 6px 0 8px;
}
.enquiry textarea { resize: vertical; min-height: 72px; }
.enquiry input:focus, .enquiry textarea:focus { outline: none; border-bottom-color: var(--aegean); box-shadow: 0 1px 0 var(--aegean); }
.enquiry .send { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.enquiry button {
  font: inherit; cursor: pointer;
  background: var(--shadow); color: var(--limewash); border: 1px solid var(--shadow);
  padding: 12px 22px; transition: background .2s ease, border-color .2s ease;
}
.enquiry button:hover { background: var(--aegean); border-color: var(--aegean); }
.form-msg { font-size: var(--small); color: #8A3B2E; }
.enquiry .send { margin-top: -4px; }
.form-msg.ok { color: var(--schist); }

/* ---------- footer ----------
   Etthem's one-line sign-off, OEM's small labelled columns, the full-width wordmark
   of OEM / LORE, and a thin legal line like Rooster's. */
.site-footer { border-top: 1px solid var(--rule); padding: var(--section) var(--edge) 20px; overflow: hidden; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.foot-line { font-size: var(--big); line-height: 1.1; letter-spacing: -0.02em; margin-bottom: clamp(56px, 8vw, 112px); }
.foot-line .tint { color: var(--aegean); }
.foot-cols { row-gap: 32px; font-size: var(--small); }
.fc { grid-column: span 3; display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.fh { color: var(--schist); margin-bottom: 8px; }
.site-footer .bay { color: var(--bay-accent); }
.site-footer .breeze { color: var(--breeze-accent); }
.wordmark {
  margin: clamp(64px, 9vw, 128px) 0 0;
  font-weight: 500; font-size: calc((100vw - 2 * var(--edge)) * 0.31); line-height: 0.78; letter-spacing: -0.055em;
  margin-left: -0.05em; white-space: nowrap; color: var(--shadow); user-select: none;
}
.foot-base {
  display: flex; justify-content: space-between; gap: 8px 24px; flex-wrap: wrap;
  margin-top: 20px; padding-top: 14px; border-top: 1px solid var(--rule); color: var(--schist);
}

/* ---------- photo viewer ---------- */
.viewer {
  width: 100vw; height: 100vh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0;
  background: var(--limewash); color: var(--shadow);
}
.viewer::backdrop { background: var(--limewash); }
.viewer[open] { display: flex; flex-direction: column; animation: viewer-in .35s ease; }
@keyframes viewer-in { from { opacity: 0; } to { opacity: 1; } }
.viewer-figure { flex: 1 1 auto; margin: 0; padding: 72px var(--edge) 0; display: flex; flex-direction: column; min-height: 0; }
.viewer-img { flex: 1 1 auto; min-height: 0; width: 100%; height: 100%; object-fit: contain; }
.viewer-caption { display: flex; justify-content: space-between; gap: 16px; padding-top: 12px; }
.viewer-controls { display: flex; gap: 24px; justify-content: flex-end; padding: 16px var(--edge) 24px; }
.viewer-controls button, .viewer-close { font: inherit; background: none; border: 0; padding: 4px 0; color: var(--shadow); cursor: pointer; }
.viewer-controls button:hover { text-decoration: underline; text-underline-offset: 0.22em; }
.viewer-close { position: absolute; top: 18px; right: var(--edge); }

/* ---------- reveal ---------- */
.js .reveal { opacity: 0; transition: opacity 1.1s ease; }
.js .reveal.is-in { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transition: none; }
}

/* ---------- smaller screens ---------- */
@media (max-width: 1024px) {
  .nav { display: none; }
  .menu-toggle { display: inline-block; }
  .clock { display: none; }
  .statement { grid-column: 1 / -1; }
  .house-info { grid-column: 1 / -1; position: static; margin-bottom: 32px; }
  .catalogue { grid-column: 1 / -1; }
  .houses-head h2, .route-section h2 { grid-column: 1 / -1; margin-bottom: 12px; }
  .houses-head nav, .route-body { grid-column: 1 / -1; }
  .stay-text, .enquiry { grid-column: 1 / -1; }
  .stay-text { margin-bottom: 48px; }
  .fc { grid-column: span 6; }
  .houses-head nav, .houses-note { grid-column: 1 / -1; text-align: left; }
  .houses-note { margin-top: 10px; }
  .stay-photo { display: none; }
}
@media (max-width: 700px) {
  .opening-photo img { height: auto; min-height: 0; aspect-ratio: 4 / 5; }
  .catalogue { grid-template-columns: 1fr 1fr; gap: 28px 12px; }
  .catalogue .wide { grid-column: 1 / -1; }
  .catalogue .wide .frame { flex: none; }
  .catalogue .wide img { position: static; aspect-ratio: 3 / 2; height: auto; }
  .catalogue figure:last-child { grid-column: 1 / -1; }
  .catalogue figure:last-child img { aspect-ratio: 3 / 2; }
  .route { flex-direction: column; align-items: flex-start; }
  .route .leg { margin: 4px 0 4px 6px; padding: 14px 0 14px 18px; text-align: left; min-width: 0; }
  .route .leg::before { left: 0; right: auto; top: 0; bottom: 0; border-top: 0; border-left: 1px solid var(--shadow); }
  .route .leg span { background: none; padding: 0; }
  .enquiry { grid-template-columns: 1fr; }
  .foot-base { flex-direction: column; }
}
