/* ==========================================================================
   Zoella Stays — style.css
   Warm Rajasthani luxury: ivory + sand, deep green, terracotta accents.
   Mobile-first, dependency-free. Pairs with Fraunces + Inter (Google Fonts).
   ========================================================================== */

/* --- Tokens --------------------------------------------------------------- */
:root {
  --ivory: #FAF6EF;
  --sand: #F1E8DA;
  --green: #1E3D2F;
  --green-dark: #14291F;
  --terra: #C4633F;
  --terra-dark: #A94E2D;
  --ink: #2A2622;
  --muted: #6E6254;
  --line: #E5D9C6;
  --white: #FFFFFF;
  --terra-light: #E7A17C;
  --green-dark-rgb: 20, 41, 31;
  --white-85: rgba(255, 255, 255, 0.85);
  --white-78: rgba(255, 255, 255, 0.78);
  --white-16: rgba(255, 255, 255, 0.16);
  --radius: 18px;
  --shadow: 0 10px 30px rgba(var(--green-dark-rgb), 0.08);
  --shadow-lift: 0 18px 44px rgba(var(--green-dark-rgb), 0.16);
  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Inter", "Helvetica Neue", Arial, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--ivory);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.12;
  color: var(--green-dark);
  margin: 0 0 0.6em;
}
h1 { font-size: clamp(2.4rem, 6vw, 3.75rem); }
h2 { font-size: clamp(1.9rem, 4vw, 2.6rem); }
h3 { font-size: 1.3rem; }

p { margin: 0 0 1em; }
a { color: var(--green); }
strong { font-weight: 600; }
img { display: block; max-width: 100%; height: auto; }
ul { padding-left: 1.2em; }

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

.container {
  max-width: 1140px;
  margin-inline: auto;
  padding-inline: 20px;
}

/* --- Header (sticky ivory bar) ---------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: var(--ivory);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 72px;
}

.brand {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--green-dark);
  text-decoration: none;
  white-space: nowrap;
}
.brand:hover { color: var(--terra); }

.site-nav a {
  color: var(--ink);
  font-weight: 500;
  text-decoration: none;
}
.site-nav a:hover { color: var(--terra); }

/* Under 860px the nav collapses behind .nav-toggle (body.nav-open shows it) */
@media (max-width: 859.98px) {
  .site-nav { display: none; }
  body.nav-open .site-nav {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    padding: 10px 20px 26px;
    background: var(--ivory);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-lift);
  }
  .site-nav a {
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
    font-size: 1rem;
  }
  .site-nav .btn { margin-top: 16px; border-bottom: 0; }
  body.nav-open { overflow: hidden; }
}

.nav-toggle {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0 11px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 12px;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  border-radius: 2px;
  background: var(--green-dark);
  transition: transform 0.2s ease, opacity 0.2s ease;
}
body.nav-open .nav-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
body.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
body.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (min-width: 860px) {
  .site-nav {
    display: flex;
    align-items: center;
    gap: 26px;
  }
  .site-nav a { font-size: 0.93rem; }
  .site-nav .btn { margin-left: 6px; }
  .nav-toggle { display: none; }
}

/* --- Buttons ----------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 0.93rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease, color 0.15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: var(--terra-dark);
  color: var(--white);
  box-shadow: var(--shadow);
}
.btn-primary:hover { background: var(--terra); color: var(--white); }

.btn-whatsapp {
  background: var(--green);
  color: var(--white);
  box-shadow: var(--shadow);
}
.btn-whatsapp:hover { background: var(--green-dark); color: var(--white); }

.btn-outline {
  background: transparent;
  border-color: var(--green);
  color: var(--green);
}
.btn-outline:hover { background: var(--green); color: var(--white); }

/* --- Hero ---------------------------------------------------------------------- */
/* Full-bleed photo hero with dark green gradient overlay.
   Pages set their photo inline:
   <section class="hero" style="background-image:url('/images/soni-bagh/hero.jpg')"> */
.hero {
  position: relative;
  display: flex;
  align-items: center;
  background-color: var(--green-dark);
  background-size: cover;
  background-position: center;
  color: var(--white);
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(var(--green-dark-rgb), 0.55) 0%, rgba(var(--green-dark-rgb), 0.72) 55%, rgba(var(--green-dark-rgb), 0.88) 100%);
}
.hero-inner {
  position: relative;
  width: 100%;
  max-width: 780px;
  padding: 96px 0;
}
.hero h1,
.hero h2 { color: var(--white); }
.hero p { color: var(--white); font-size: 1.08rem; }
/* Over photos the terracotta accent is dropped for AA contrast (measured
   worst-case on the real heroes); eyebrows on page backgrounds stay terracotta. */
.hero .eyebrow { color: var(--white); }

@media (min-width: 860px) {
  .hero-inner { padding: 148px 0; }
}

/* --- Sections ------------------------------------------------------------------- */
.section { padding: 72px 0; }
.section-alt { background: var(--sand); }

@media (min-width: 860px) {
  .section { padding: 96px 0; }
}

.section-head {
  max-width: 660px;
  margin-bottom: 40px;
}
.section-head .lead { margin-bottom: 0; }

.eyebrow {
  display: inline-block;
  margin: 0 0 10px;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--terra-dark);
}

.lead {
  font-size: 1.12rem;
  color: var(--muted);
  max-width: 62ch;
}

/* --- Cards (3 -> 1 columns) ------------------------------------------------------- */
.cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
@media (min-width: 640px) { .cards-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .cards-grid { grid-template-columns: repeat(3, 1fr); } }

.property-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.property-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lift);
}
.property-card-media {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--sand);
}
.property-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.property-card-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
  padding: 22px;
}
.property-card-body h3 { margin: 0; }
.property-card-body p { margin: 0; color: var(--muted); font-size: 0.95rem; }
.property-card-body .price-chip { align-self: flex-start; margin-top: auto; }
.property-card-body .ratings-row { margin-top: 4px; }

/* --- Chips ------------------------------------------------------------------------- */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--sand);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 600;
}

.price-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--terra-dark);
  color: var(--white);
  font-size: 0.86rem;
  font-weight: 600;
  box-shadow: var(--shadow);
}

/* --- Ratings ------------------------------------------------------------------------ */
.ratings-row {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 0.9rem;
}
.stars {
  color: var(--terra);
  font-size: 0.95rem;
  letter-spacing: 2px;
}

/* --- Gallery ------------------------------------------------------------------------- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}
@media (min-width: 860px) {
  .gallery-grid { grid-template-columns: repeat(3, 1fr); gap: 18px; }
}
.gallery-grid > a,
.gallery-grid > figure {
  margin: 0;
  overflow: hidden;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.gallery-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.25s ease;
}
.gallery-grid > figure img {
  aspect-ratio: 4 / 3;
  height: auto;
}
.gallery-grid > a:hover img,
.gallery-grid > figure:hover img { transform: scale(1.04); }

/* --- Spec grid ------------------------------------------------------------------------ */
.spec-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}
@media (min-width: 860px) {
  .spec-grid { grid-template-columns: repeat(4, 1fr); }
}
.spec-grid .spec {
  padding: 20px 14px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-align: center;
}
.spec strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--green-dark);
  margin-bottom: 4px;
}
.spec span {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

/* --- Contact band ------------------------------------------------------------------------ */
.contact-band {
  padding: 52px 28px;
  background: var(--green);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lift);
  color: var(--white);
  text-align: center;
}
.contact-band h2 { color: var(--white); }
.contact-band p {
  max-width: 58ch;
  margin-inline: auto;
  color: var(--white-85);
}

/* --- Footer (dark green, three columns) ---------------------------------------------------- */
.site-footer {
  background: var(--green-dark);
  color: var(--white-78);
  padding: 60px 0 26px;
  font-size: 0.95rem;
}
.site-footer a {
  color: var(--white);
  text-decoration: none;
}
.site-footer a:hover { color: var(--terra-light); text-decoration: underline; }

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 34px;
}
@media (min-width: 860px) {
  .footer-grid { grid-template-columns: 1.5fr 1fr 1fr; }
}

.footer-wordmark {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--white);
  margin: 0 0 12px;
}

.site-footer h3 {
  color: var(--white);
  font-size: 1.02rem;
  margin: 0 0 14px;
}

.site-footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.footer-tiny {
  margin-top: 46px;
  padding-top: 18px;
  border-top: 1px solid var(--white-16);
  font-size: 0.8rem;
  color: var(--white-78);
}
.footer-tiny p { margin: 0; }

/* --- Small helpers --------------------------------------------------------------------------- */
.text-center { text-align: center; }

/* ==========================================================================
   page: soni-bagh, rivaan, kuber-vatika (shared property-page styles)
   Appended only; no rules above were modified.
   ========================================================================== */

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.ratings-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
@media (min-width: 640px) { .ratings-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .ratings-grid { grid-template-columns: repeat(3, 1fr); } }

.rating-item {
  margin: 0;
  padding: 18px 20px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  font-size: 0.95rem;
  color: var(--muted);
}
.rating-item .stars {
  display: block;
  margin-bottom: 6px;
}

/* White outline variant for buttons on dark green surfaces — merged from the
   former .hero-only rule and the former .contact-band-only rule so future
   heroes and bands share one declaration block. */
.hero .btn-outline,
.contact-band .btn-outline {
  border-color: var(--white);
  color: var(--white);
}
.hero .btn-outline:hover,
.contact-band .btn-outline:hover {
  background: var(--white);
  color: var(--green-dark);
}

/* band-actions is a <div> in the markup (buttons are invalid inside <p>),
   so it no longer matches .contact-band p and needs no counter-declarations. */
.contact-band .band-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 12px 14px;
  margin: 20px 0 0;
}

/* ==========================================================================
   improvement: 2026-10-07 accessibility + UX pass
   Appended block; existing rules above were only touched where the approved
   plan named them (contrast swaps, hero overlay, gallery caption fix, dedup).
   ========================================================================== */

/* Gallery captions: figures are no longer aspect-ratio locked, so the caption
   flows under the image inside the rounded, overflow-hidden tile. */
.gallery-grid figcaption {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--muted);
  padding: 9px 14px 11px;
  border-top: 1px solid var(--line);
}

/* Skip-to-content link: hidden off-canvas until focused. */
.skip-link {
  position: absolute;
  top: -60px;
  left: 16px;
  z-index: 70; /* above the sticky header (z-index: 60) */
  padding: 10px 18px;
  background: var(--ivory);
  color: var(--green-dark);
  font-weight: 600;
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: 0 0 10px 10px;
  box-shadow: var(--shadow);
}
.skip-link:focus,
.skip-link:focus-visible { top: 0; }

/* Focus ring on the dark green contact band: brighter terra for 3:1+ (WCAG
   1.4.11 non-text contrast) against var(--green). */
.contact-band :focus-visible { outline-color: var(--terra-light); }

/* 404 page footer columns use h2 (no h2 precedes the footer there); keep the
   footer heading sizing identical to .site-footer h3. */
.site-footer h2 {
  color: var(--white);
  font-size: 1.02rem;
  margin: 0 0 14px;
}

/* Honor prefers-reduced-motion: kill smooth scroll and hover motion. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn,
  .property-card,
  .gallery-grid img,
  .nav-toggle span { transition: none; }
  .btn:hover,
  .btn:active,
  .property-card:hover,
  .gallery-grid > a:hover img,
  .gallery-grid > figure:hover img { transform: none; }
}

/* repair: contact page overflowed the 390px viewport — grid cells must be
   allowed to shrink and long values (the email) must wrap, not force width */
.spec-grid .spec { min-width: 0; }
.spec span { overflow-wrap: anywhere; }

/* improvement: 404 auto-redirect note */
.redirect-note { color: var(--muted); font-size: 0.9rem; margin-top: 14px; }
