/* ============================================================
   Kaltasin Beachouse Farmstay — sea & farm, Sooke BC
   Palette from the aerial dusk photo of Sooke Basin:
   basin navy / steel water / fog / spit sand / garden moss
   ============================================================ */

:root {
  --basin: #1c3a52;      /* deep water ink */
  --basin-deep: #142c40;
  --water: #49708e;      /* steel blue */
  --water-soft: #7d9cb4;
  --fog: #f2f6f8;        /* pale sky */
  --sand: #e6dcc6;       /* the spit */
  --sand-deep: #cdbf9e;
  --moss: #6f7f52;       /* the farm */
  --moss-deep: #55633e;
  --ink: #24313c;
  --ink-soft: #56646f;
  --white: #ffffff;

  --script: "Pacifico", cursive;
  --heading: "Jost", "Avenir Next", sans-serif;
  --body: "Karla", "Helvetica Neue", sans-serif;

  --max: 1100px;
  --radius: 14px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

body {
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--white);
}

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

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 24px; }

/* ---------- type ---------- */

h1, h2, h3 { font-family: var(--heading); font-weight: 400; }

.script { font-family: var(--script); font-weight: 400; }

.eyebrow {
  font-family: var(--heading);
  font-size: 13px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--water);
  margin-bottom: 10px;
}

.section-title {
  font-size: clamp(30px, 4.5vw, 44px);
  letter-spacing: 0.02em;
  color: var(--basin);
  margin-bottom: 18px;
}

.section-title .script {
  color: var(--moss);
  font-size: 0.9em;
}

.lede { font-size: 19px; color: var(--ink-soft); max-width: 62ch; }

/* ---------- header ---------- */

.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 28px;
  transition: background 0.35s ease, box-shadow 0.35s ease;
}

.site-header.scrolled {
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 1px 14px rgba(20, 44, 64, 0.12);
}

.brand {
  font-family: var(--script);
  font-size: 24px;
  color: var(--white);
  text-decoration: none;
  transition: color 0.35s ease;
}
.site-header.scrolled .brand { color: var(--basin); }

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

.site-nav a {
  font-family: var(--heading);
  font-size: 13px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-decoration: none;
  color: rgba(255, 255, 255, 0.92);
  transition: color 0.35s ease;
}
.site-header.scrolled .site-nav a { color: var(--ink); }
.site-nav a:hover { color: var(--sand-deep); }
.site-header.scrolled .site-nav a:hover { color: var(--water); }

.site-nav .book-link {
  border: 1px solid currentColor;
  padding: 8px 18px;
  border-radius: 999px;
}

@media (max-width: 720px) {
  .site-nav a:not(.book-link) { display: none; }
}

/* ---------- hero ---------- */

.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  text-align: center;
  color: var(--white);
  /* aerial photo carries the baked-in wordmark; gradient scrim keeps the tag legible */
  background:
    linear-gradient(180deg, rgba(20, 44, 64, 0.12) 0%, rgba(20, 44, 64, 0) 55%, rgba(20, 44, 64, 0.4) 100%),
    url("images/hero.jpg") center / cover no-repeat,
    linear-gradient(180deg, #a8bfd0 0%, #49708e 38%, #2b4d6b 70%, #1c3a52 100%);
}

@media (max-width: 640px) {
  .hero {
    background:
      linear-gradient(180deg, rgba(20, 44, 64, 0.12) 0%, rgba(20, 44, 64, 0) 55%, rgba(20, 44, 64, 0.4) 100%),
      url("images/hero-mobile.png") center / cover no-repeat,
      linear-gradient(180deg, #a8bfd0 0%, #49708e 38%, #2b4d6b 70%, #1c3a52 100%);
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.facts-tag {
  font-family: var(--heading);
  font-size: 13px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  text-align: center;
  color: var(--moss-deep);
  margin: 0 24px 18px;
}

/* the tideline — sandbar curve closing the hero */
.tideline {
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 100%;
  height: 90px;
  pointer-events: none;
}

/* ---------- quick facts (the spit) ---------- */

.facts {
  background: var(--sand);
  padding: 26px 0 30px;
}

.facts .wrap {
  display: flex;
  justify-content: center;
  gap: clamp(26px, 6vw, 84px);
  flex-wrap: wrap;
  text-align: center;
}

.fact .n {
  font-family: var(--heading);
  font-size: 34px;
  color: var(--basin);
  line-height: 1.1;
}

.fact .l {
  font-family: var(--heading);
  font-size: 12px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--moss-deep);
}

/* ---------- sections ---------- */

section { padding: 84px 0; }

.divider {
  display: block;
  width: 100%;
  height: 46px;
  color: var(--sand);
}

/* two-column feature */
.feature {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(28px, 5vw, 72px);
  align-items: center;
}
.feature.flip .feature-media { order: 2; }

@media (max-width: 820px) {
  .feature { grid-template-columns: 1fr; }
  .feature.flip .feature-media { order: 0; }
}

.feature-media {
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: linear-gradient(160deg, var(--water-soft), var(--basin));
  position: relative;
}

.feature-media.farm { background: linear-gradient(160deg, #9aa77e, var(--moss-deep)); }

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

.feature-media .placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--script);
  font-size: 30px;
  color: rgba(255, 255, 255, 0.85);
}

.feature-body p + p { margin-top: 14px; }
.feature-body ul { margin: 16px 0 0 18px; color: var(--ink-soft); }

/* ---------- gallery ---------- */

.gallery-grid {
  margin-top: 36px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.shot {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: var(--fog);
}

.shot.wide { grid-column: span 2; aspect-ratio: auto; }

.shot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.shot:hover img { transform: scale(1.03); }

.shot figcaption {
  position: absolute;
  inset: auto 0 0 0;
  padding: 26px 16px 12px;
  font-family: var(--heading);
  font-size: 12.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--white);
  background: linear-gradient(180deg, transparent, rgba(20, 44, 64, 0.75));
}

@media (max-width: 720px) {
  .gallery-grid { grid-template-columns: 1fr 1fr; }
  .shot.wide { grid-column: span 2; }
}

/* ---------- map ---------- */

.map-frame {
  margin-top: 44px;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 8px 28px rgba(20, 44, 64, 0.14);
}

.map-frame iframe {
  display: block;
  width: 100%;
  height: 340px;
  border: 0;
}

/* ---------- amenities ---------- */

.amenities { background: var(--fog); }

.amenity-grid {
  margin-top: 36px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
}

.amenity {
  background: var(--white);
  border-radius: var(--radius);
  padding: 18px 20px;
  display: flex;
  gap: 14px;
  align-items: center;
  box-shadow: 0 1px 5px rgba(20, 44, 64, 0.06);
}

.amenity svg { flex: none; width: 26px; height: 26px; color: var(--water); }

.amenity span { font-size: 15.5px; color: var(--ink); }

/* ---------- area guide ---------- */

.area-grid {
  margin-top: 36px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}

.area-card {
  border: 1px solid #e2e8ec;
  border-radius: var(--radius);
  padding: 26px 24px;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.area-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 26px rgba(20, 44, 64, 0.1);
}

.area-card .dist {
  font-family: var(--heading);
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--moss);
}

.area-card h3 {
  font-size: 21px;
  color: var(--basin);
  margin: 6px 0 8px;
}

.area-card p { font-size: 15.5px; color: var(--ink-soft); }

/* ---------- reviews ---------- */

.reviews { background: var(--basin); color: var(--fog); }

.reviews .eyebrow { color: var(--sand-deep); }
.reviews .section-title { color: var(--white); }

.review-grid {
  margin-top: 36px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 22px;
}

.review {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  padding: 28px 26px;
}

.review .quote-mark {
  font-family: var(--script);
  font-size: 40px;
  color: var(--sand-deep);
  line-height: 1;
}

.review p { font-size: 16px; margin: 10px 0 16px; color: rgba(242, 246, 248, 0.92); }

.review cite {
  font-family: var(--heading);
  font-style: normal;
  font-size: 12.5px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--water-soft);
}

/* ---------- booking ---------- */

.booking { text-align: center; }

.booking .section-title .script { color: var(--water); }

.book-buttons {
  margin-top: 34px;
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  font-family: var(--heading);
  font-size: 14px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 16px 34px;
  border-radius: 999px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: var(--basin);
  color: var(--white);
  box-shadow: 0 6px 18px rgba(20, 44, 64, 0.25);
}

.btn-secondary {
  border: 1.5px solid var(--basin);
  color: var(--basin);
}

.booking .note { margin-top: 22px; font-size: 15px; color: var(--ink-soft); }

/* ---------- footer ---------- */

.site-footer {
  background: var(--basin-deep);
  color: var(--water-soft);
  padding: 54px 0 40px;
  text-align: center;
}

.site-footer .brand-foot {
  font-family: var(--script);
  font-size: 30px;
  color: var(--sand);
}

.site-footer .foot-sub {
  font-family: var(--heading);
  font-size: 12px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  margin-top: 4px;
  color: rgba(230, 220, 198, 0.6);
}

.site-footer p { font-size: 14px; margin-top: 22px; }

.site-footer a { color: var(--sand-deep); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }

/* ---------- reveal on scroll ---------- */

.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.in { opacity: 1; transform: none; }

/* accessibility */
a:focus-visible, .btn:focus-visible {
  outline: 3px solid var(--moss);
  outline-offset: 3px;
}
