/* Chalets Ours & Ourson
   Palette taken from the photos: weathered larch, the tartan headboard, the stone wall, the alpine sky. */

:root {
  --snow: #f3f5f4;
  --paper: #ffffff;
  --spruce: #1c2824;
  --tartan: #2c4a3d;
  --tartan-ink: #ffffff;
  --larch: #9a6434;
  --slate: #5f6862;
  --rule: #d6dbd8;
  --booked: #e7dccf;
  --booked-ink: #6d4a28;
  --focus: #2e63a8;

  --serif: "Young Serif", Georgia, "Times New Roman", serif;
  --sans: "Hanken Grotesk", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --measure: 36rem;
  --wide: 72rem;
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --snow: #141b18;
    --paper: #1b2420;
    --spruce: #e8ece9;
    --tartan: #8fbfa6;
    --tartan-ink: #10201a;
    --larch: #d49a63;
    --slate: #a4aea8;
    --rule: #2f3a35;
    --booked: #3a2f24;
    --booked-ink: #e6c29c;
    --focus: #8cb4ea;
  }
}
:root[data-theme="dark"] {
  --snow: #141b18;
  --paper: #1b2420;
  --spruce: #e8ece9;
  --tartan: #8fbfa6;
  --tartan-ink: #10201a;
  --larch: #d49a63;
  --slate: #a4aea8;
  --rule: #2f3a35;
  --booked: #3a2f24;
  --booked-ink: #e6c29c;
  --focus: #8cb4ea;
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--snow);
  color: var(--spruce);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  overflow-x: hidden;
}

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

a { color: var(--tartan); text-underline-offset: 0.2em; }
a:hover { text-decoration-thickness: 2px; }

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

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 400;
  line-height: 1.12;
  margin: 0 0 0.6em;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2.4rem, 6vw, 4.25rem); }
h2 { font-size: clamp(1.75rem, 3.4vw, 2.5rem); }
h3 { font-size: 1.35rem; }

p { margin: 0 0 1em; }

.skip {
  position: absolute; left: -999px; top: 0;
  background: var(--paper); padding: 0.5rem 1rem; z-index: 10;
}
.skip:focus { left: 1rem; top: 1rem; }

/* ---------- Header ---------- */

.site-header {
  background: var(--snow);
  border-bottom: 1px solid var(--rule);
}
.site-header__inner {
  max-width: var(--wide);
  margin: 0 auto;
  padding: 0.9rem var(--gutter);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem 2rem;
}
.site-name {
  font-family: var(--serif);
  font-size: 1.3rem;
  color: var(--spruce);
  text-decoration: none;
}
.site-nav ul {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-wrap: wrap; gap: 0.25rem 1.5rem;
}
.site-nav a {
  color: var(--spruce);
  text-decoration: none;
  font-weight: 500;
  padding: 0.25rem 0;
  border-bottom: 2px solid transparent;
}
.site-nav a:hover { border-bottom-color: var(--rule); }
.site-nav a[aria-current="page"] { border-bottom-color: var(--larch); }

/* EN | FR language switch, last item in the menu */
.site-nav .lang-switch {
  display: inline-flex;
  align-self: center;
  border: 1px solid var(--spruce);
  border-radius: 999px;
  overflow: hidden;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  line-height: 1;
}
.site-nav .lang-switch > * { padding: 0.4rem 0.7rem; border: 0; }
.site-nav .lang-switch [aria-current] { background: var(--spruce); color: var(--snow); }
.site-nav .lang-switch a:hover { background: var(--rule); border: 0; }

/* ---------- Layout helpers ---------- */

.wrap { max-width: var(--wide); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: clamp(3.5rem, 8vw, 6rem) 0; }
.section + .section { padding-top: 0; }
.prose { max-width: var(--measure); }
.lede { font-size: 1.25rem; line-height: 1.55; color: var(--spruce); }
.muted { color: var(--slate); }
.small { font-size: 0.925rem; }

.button {
  display: inline-block;
  background: var(--tartan);
  color: var(--tartan-ink);
  text-decoration: none;
  font-weight: 600;
  padding: 0.8rem 1.35rem;
  border-radius: 3px;
  border: 2px solid var(--tartan);
  cursor: pointer;
  font: inherit;
  font-weight: 600;
}
.button:hover { filter: brightness(1.1); }
.button--quiet {
  background: transparent;
  color: var(--tartan);
}
.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 1.5rem; }

/* ---------- Home hero: two photos split by a slanted line ----------
   The line runs from 49.5% across at the top to 56% at the bottom. If you
   move it, change the four percentages marked * below to match. */

.split-hero {
  position: relative;
  height: min(calc(100vh - 4rem), 54rem);
  min-height: 32rem;
  overflow: hidden;
  background: #1c2824;
  color: #fff;
}
.split-hero__panel {
  position: absolute; top: 0; bottom: 0;
  display: block;
  color: inherit;
  text-decoration: none;
  overflow: hidden;
}
.split-hero__panel--ourson {
  left: 0; width: 56%;                                   /* * bottom of line */
  clip-path: polygon(0 0, 88.39% 0, 100% 100%, 0 100%);  /* * 49.5 / 56 */
}
.split-hero__panel--ours {
  left: 49.5%; right: 0;                                 /* * top of line */
  clip-path: polygon(0 0, 100% 0, 100% 100%, 12.87% 100%); /* * (56-49.5) / 50.5 */
}
.split-hero__panel img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.split-hero__panel--ourson img { object-position: 45% 50%; }
.split-hero__panel--ours img { object-position: 62% 50%; }
/* darken the bottom of each photo so the names read clearly */
.split-hero__panel::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(10, 20, 18, 0.62) 0%, rgba(10, 20, 18, 0.18) 32%, rgba(10, 20, 18, 0) 50%);
}
.split-hero__caption {
  position: absolute;
  z-index: 1;
  bottom: clamp(1.5rem, 5vh, 3.25rem);
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.45);
}
.split-hero__panel--ourson .split-hero__caption { left: clamp(1.25rem, 3.5vw, 4rem); }
.split-hero__panel--ours .split-hero__caption { right: clamp(1.25rem, 3.5vw, 4rem); text-align: right; }
.split-hero__name {
  display: block;
  font-family: var(--serif);
  font-size: clamp(2.3rem, 4.4vw, 4.6rem);
  line-height: 1.05;
}
.split-hero__tag {
  display: block;
  margin-top: 0.55rem;
  font-size: clamp(1rem, 1.5vw, 1.45rem);
  font-weight: 300;
  letter-spacing: 0.02em;
}
.split-hero__tag i { font-style: normal; margin: 0 0.55em; opacity: 0.85; }

/* the site name across the top, over both photos */
.split-hero::before {
  content: "";
  position: absolute; inset: 0 0 auto 0;
  height: 30%;
  z-index: 1;
  background: linear-gradient(to bottom, rgba(10, 20, 18, 0.32), rgba(10, 20, 18, 0));
  pointer-events: none;
}
.split-hero__brand {
  position: absolute;
  z-index: 2;
  top: clamp(1.25rem, 4vh, 2.5rem);
  left: 0; right: 0;
  text-align: center;
  pointer-events: none;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.4);
}
.split-hero__title {
  margin: 0;
  font-family: inherit;
  font-weight: 600;
  font-size: clamp(1.3rem, 2.1vw, 2.1rem);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  line-height: 1.2;
}
.split-hero__where {
  margin: 0.35rem 0 0;
  font-weight: 300;
  font-size: clamp(0.95rem, 1.3vw, 1.3rem);
  letter-spacing: 0.04em;
}
.split-hero__where i { font-style: normal; margin: 0 0.6em; }
.split-hero__line {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  z-index: 2;
  pointer-events: none;
}
.split-hero__line line { stroke: #fff; stroke-width: 2; opacity: 0.9; vector-effect: non-scaling-stroke; }

.split-hero__panel:focus-visible { outline: 3px solid #fff; outline-offset: -6px; }
@media (prefers-reduced-motion: no-preference) {
  .split-hero__panel img { transition: transform 0.6s ease; }
  .split-hero__panel:hover img { transform: scale(1.03); }
}

/* phones: the two photos stacked, with a slanted join */
@media (max-width: 700px) {
  .split-hero { height: auto; min-height: 0; display: grid; background: #fff; }
  .split-hero__panel { position: relative; height: 24rem; width: auto; left: auto; right: auto; }
  .split-hero__panel--ourson { z-index: 1; clip-path: polygon(0 0, 100% 0, 100% calc(100% - 2.5rem), 0 100%); }
  .split-hero__panel--ours { margin-top: calc(-2.5rem + 3px); height: 22rem; clip-path: polygon(0 2.5rem, 100% 0, 100% 100%, 0 100%); }
  .split-hero__panel--ourson .split-hero__caption { bottom: 3.5rem; }
  .split-hero__line { display: none; }
  .split-hero::before { height: 9rem; }
}

/* ---------- Home: chalets ---------- */

.chalet-row {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: clamp(1.5rem, 4vw, 3.5rem);
  align-items: center;
  margin-top: 2.5rem;
}
.chalet-row + .chalet-row { margin-top: clamp(3rem, 7vw, 5rem); }
.chalet-row--flip { grid-template-columns: 1fr 1.3fr; }
.chalet-row--flip .chalet-row__media { order: 2; }
.chalet-row__media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 2px; }
.chalet-row__name { font-size: clamp(2rem, 4vw, 3rem); margin-bottom: 0.25rem; }
.chalet-row__meaning { color: var(--larch); font-style: italic; margin-bottom: 1rem; }

.photo-pending {
  aspect-ratio: 4 / 3;
  background:
    repeating-linear-gradient(135deg, transparent 0 14px, rgba(95, 104, 98, 0.08) 14px 15px),
    var(--paper);
  border: 1px solid var(--rule);
  display: grid; place-items: center;
  color: var(--slate);
  text-align: center;
  padding: 1rem;
}

@media (max-width: 760px) {
  .chalet-row, .chalet-row--flip { grid-template-columns: 1fr; }
  .chalet-row--flip .chalet-row__media { order: 0; }
}

/* ---------- Guest words ---------- */

.words {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 2rem 4rem;
  align-items: start;
}
.quote { margin: 0; }
.quote blockquote { margin: 0; }
.quote blockquote p { font-style: italic; }
.quote blockquote p::before { content: "\201C"; }
.quote blockquote p::after { content: "\201D"; }
.quote p { margin: 0 0 0.6rem; }
.quote--lead p { font-family: var(--serif); font-size: clamp(1.6rem, 3vw, 2.2rem); line-height: 1.25; }
.quote cite { font-style: normal; color: var(--slate); font-size: 0.95rem; }
.quote-stack { display: grid; gap: 2rem; }
.quote-stack .quote p { font-size: 1.1rem; }
.words__source { grid-column: 1 / -1; margin: 0; }

@media (max-width: 760px) { .words { grid-template-columns: 1fr; } }

/* ---------- Band ---------- */

.band { background: var(--tartan); color: var(--tartan-ink); }
.section.band { padding: clamp(2.5rem, 6vw, 4rem) 0; }
.band a { color: inherit; }
.band .button { background: var(--tartan-ink); color: var(--tartan); border-color: var(--tartan-ink); }
.band .button--quiet { background: transparent; color: var(--tartan-ink); border-color: var(--tartan-ink); }
.band__inner { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 1.5rem 3rem; }
.band h2 { margin-bottom: 0.3rem; }
.band p { margin: 0; max-width: 34rem; }
.band .actions { margin-top: 0; }

/* ---------- Chalet page ---------- */

.page-head { padding: clamp(2.5rem, 6vw, 4rem) 0 1.75rem; }
.page-head h1 { margin-bottom: 0.3rem; }
.page-head p { font-size: 1.2rem; color: var(--slate); margin: 0; }

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
  gap: 0.75rem;
}
.gallery__item {
  display: block;
  position: relative;
  border-radius: 2px;
  overflow: hidden;
  background: var(--paper);
}
.gallery__item:first-child { grid-column: 1 / -1; }
.gallery img { width: 100%; height: 100%; object-fit: cover; display: block; aspect-ratio: 4 / 3; }
.gallery__item:first-child img { aspect-ratio: 16 / 9; }
.gallery__item:hover img, .gallery__item:focus-visible img { opacity: 0.92; }

.lightbox {
  border: 0; padding: 0; max-width: 100vw; max-height: 100vh; width: 100%; height: 100%;
  background: rgba(16, 24, 28, 0.94); color: #fff;
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 0.5rem;
}
.lightbox::backdrop { background: rgba(16, 24, 28, 0.9); }
.lightbox[open] { display: grid; }
.lightbox img { grid-column: 2; max-width: 100%; max-height: 86vh; margin: 0 auto; object-fit: contain; }
.lightbox__nav, .lightbox__close {
  font: inherit; font-size: 2rem; line-height: 1; color: #fff; background: rgba(0,0,0,0.35);
  border: 0; border-radius: 999px; width: 3rem; height: 3rem; cursor: pointer;
}
.lightbox__close { position: absolute; top: 1rem; right: 1rem; font-size: 1.5rem; z-index: 2; }
.lightbox__caption { grid-column: 2; grid-row: 2; text-align: center; margin: 0.75rem 0 0; font-size: 0.9rem; opacity: 0.8; }
@media (max-width: 700px) {
  .lightbox__nav { width: 2.5rem; height: 2.5rem; font-size: 1.5rem; }
}
.map { position: relative; aspect-ratio: 16 / 9; max-height: 28rem; width: 100%; background: var(--paper); border: 1px solid var(--rule); margin-bottom: 0.75rem; }
.map iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
@media (max-width: 700px) {
  .map { aspect-ratio: 4 / 3; }
  .gallery { grid-template-columns: 1fr 1fr; }
}

.overview {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: 2rem 4rem;
}
@media (max-width: 800px) { .overview { grid-template-columns: 1fr; } }

.facts { margin: 0; border-top: 2px solid var(--spruce); }
.facts div {
  display: flex; justify-content: space-between; gap: 1rem;
  padding: 0.7rem 0;
  border-bottom: 1px solid var(--rule);
}
.facts dt { color: var(--slate); }
.facts dd { margin: 0; text-align: right; font-weight: 600; }

.amenities {
  columns: 3 14rem;
  column-gap: 3rem;
}
.amenities section { break-inside: avoid; margin-bottom: 1.75rem; }
.amenities h3 { font-family: var(--sans); font-size: 1rem; font-weight: 600; margin-bottom: 0.4rem; }
.amenities ul { list-style: none; margin: 0; padding: 0; }
.amenities li { padding: 0.15rem 0; }
.amenities li small { display: block; color: var(--slate); font-size: 0.875rem; line-height: 1.35; }

.review-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(22rem, 1fr));
  gap: 2rem 4rem;
  max-width: 60rem;
}
@media (max-width: 480px) { .review-grid { grid-template-columns: 1fr; } }
.review-grid .quote { border-top: 1px solid var(--rule); padding-top: 1rem; }

/* ---------- Contact ---------- */

.contact-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 3rem 5rem; }
@media (max-width: 820px) { .contact-grid { grid-template-columns: 1fr; } }

.form { display: grid; gap: 1.1rem; }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem; }
@media (max-width: 520px) { .form__row { grid-template-columns: 1fr; } }
.field label { display: block; font-weight: 600; margin-bottom: 0.3rem; }
.field input, .field select, .field textarea {
  width: 100%;
  font: inherit;
  color: var(--spruce);
  background: var(--paper);
  border: 1px solid #a9b1ac;
  border-radius: 3px;
  padding: 0.65rem 0.75rem;
}
.field textarea { min-height: 8rem; resize: vertical; }
.form__note {
  margin: 0; padding: 0.7rem 0.9rem; border-left: 3px solid var(--larch);
  background: var(--paper); font-size: 0.95rem;
}
.form__done { border-top: 2px solid var(--spruce); padding-top: 1.25rem; max-width: var(--measure); }
.form__done h2 { font-size: 1.8rem; }
.field__hint { display: block; color: var(--slate); font-size: 0.875rem; margin-top: 0.3rem; }
.chalet-row__for { font-weight: 600; margin-bottom: 0.5rem; }
.form__error { color: #a3361f; font-weight: 600; margin: 0; min-height: 1.5em; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .form__note {
  margin: 0; padding: 0.7rem 0.9rem; border-left: 3px solid var(--larch);
  background: var(--paper); font-size: 0.95rem;
}
.form__done { border-top: 2px solid var(--spruce); padding-top: 1.25rem; max-width: var(--measure); }
.form__done h2 { font-size: 1.8rem; }
.field__hint { display: block; color: var(--slate); font-size: 0.875rem; margin-top: 0.3rem; }
.chalet-row__for { font-weight: 600; margin-bottom: 0.5rem; }
.form__error { color: #f0a08a; } }
:root[data-theme="dark"] .form__note {
  margin: 0; padding: 0.7rem 0.9rem; border-left: 3px solid var(--larch);
  background: var(--paper); font-size: 0.95rem;
}
.form__done { border-top: 2px solid var(--spruce); padding-top: 1.25rem; max-width: var(--measure); }
.form__done h2 { font-size: 1.8rem; }
.field__hint { display: block; color: var(--slate); font-size: 0.875rem; margin-top: 0.3rem; }
.chalet-row__for { font-weight: 600; margin-bottom: 0.5rem; }
.form__error { color: #f0a08a; }

.contact-list { margin: 0; padding: 0; list-style: none; border-top: 2px solid var(--spruce); }
.contact-list li { padding: 0.8rem 0; border-bottom: 1px solid var(--rule); }
.contact-list span { display: block; color: var(--slate); font-size: 0.9rem; }

/* ---------- Verchaix page ---------- */

.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 2.5rem 5rem; }
@media (max-width: 800px) { .split { grid-template-columns: 1fr; } }

.season { border-top: 2px solid var(--spruce); padding-top: 1.25rem; }
.season h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); }

.pending {
  border: 1px dashed var(--slate);
  padding: 1.25rem 1.5rem;
  border-radius: 3px;
  color: var(--slate);
  max-width: var(--measure);
}
.pending strong { color: var(--spruce); }

/* ---------- Footer ---------- */

.site-footer {
  border-top: 1px solid var(--rule);
  padding: 2.5rem 0 3rem;
  color: var(--slate);
  font-size: 0.925rem;
}
.site-footer__inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem 3rem; }
.site-footer a { color: inherit; }


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

/* ---------- About page banner ---------- */
.page-banner { margin: 0 0 clamp(1rem, 3vw, 2rem); }
.page-banner img {
  width: 100%;
  height: clamp(11rem, 34vw, 22rem);
  object-fit: cover;
  object-position: 50% 58%;
  border-radius: 3px;
  display: block;
}
.page-banner figcaption { margin-top: 0.5rem; }

/* ---------- Mobile typography adjustments ---------- */
@media (max-width: 700px) {
  .site-name { font-size: 1.85rem; line-height: 1.1; }
  .quote--lead p { font-family: inherit; font-size: 1.1rem; line-height: 1.55; }
  [data-route="/verchaix/"] .lede { font-size: 1rem; line-height: 1.6; }
}

.page-banner--tight { margin-top: 0.75rem; }
.page-banner--tight img { height: clamp(10rem, 28vw, 18rem); }
.address { font-weight: 600; margin: 0; }

/* room headings, per Chrystele: set apart from the list */
.amenities h3 {
  font-style: italic;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 0.3rem;
}


/* ---------- Availability calendar (chalet pages) ---------- */
.availability__bar {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  margin-bottom: 1.25rem;
}
.availability__legend { margin: 0; display: flex; align-items: center; flex-wrap: wrap; gap: 0.4rem; font-size: 0.925rem; color: var(--slate); }
.availability__key {
  display: inline-block; width: 1rem; height: 1rem; border-radius: 3px;
  background: var(--paper); border: 1px solid var(--rule);
}
.availability__key--booked { background: var(--booked); border-color: var(--booked); margin-left: 0.9rem; }
.availability__nav {
  width: 2.5rem; height: 2.5rem; flex: none;
  border: 1px solid var(--rule); border-radius: 999px;
  background: var(--paper); color: var(--spruce);
  font-size: 1.5rem; line-height: 1; cursor: pointer;
}
.availability__nav:hover:not(:disabled) { border-color: var(--spruce); }
.availability__nav:disabled { opacity: 0.35; cursor: default; }
.availability__months {
  display: grid;
  grid-template-columns: repeat(var(--months, 1), minmax(0, 1fr));
  gap: clamp(1.25rem, 3vw, 2.5rem);
}
.month__name { font-size: 1.15rem; margin: 0 0 0.75rem; text-transform: capitalize; }
.month__grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; }
.month__head { display: contents; }
.month__head span { font-size: 0.75rem; text-align: center; color: var(--slate); padding-bottom: 0.35rem; text-transform: capitalize; }
.day {
  aspect-ratio: 1; display: grid; place-items: center;
  font-size: 0.9rem; border-radius: 3px;
  background: var(--paper); color: var(--spruce);
  font-variant-numeric: tabular-nums;
}
.day--past { background: transparent; color: var(--rule); }
.day--booked { background: var(--booked); color: var(--booked-ink); text-decoration: line-through; }
.day--today { box-shadow: inset 0 0 0 2px var(--larch); font-weight: 600; }
.availability__note { margin-top: 1.25rem; max-width: var(--measure); }
