/*
Theme Name: Sennington Estate
Theme URI: https://example.test/sennington-estate
Author: Demo Studio
Description: A refined, image-led estate agency theme built for private property demonstrations.
Version: 1.1.0
Requires at least: 6.2
Requires PHP: 7.4
Text Domain: sennington-estate
*/

:root {
  --ink: #162326;
  --ink-soft: #435155;
  --cream: #f4f0e8;
  --paper: #fbfaf7;
  --gold: #b89b6a;
  --line: rgba(22, 35, 38, 0.16);
  --white: #fff;
  --serif: "Iowan Old Style", "Baskerville", "Times New Roman", serif;
  --sans: "Avenir Next", "Helvetica Neue", Arial, sans-serif;
  --page: min(1280px, calc(100% - 64px));
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
body.modal-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
img { display: block; width: 100%; height: auto; }
button, input { font: inherit; }
button { color: inherit; }

.screen-reader-text {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0);
  white-space: nowrap; border: 0;
}
.skip-link:focus {
  clip: auto; width: auto; height: auto; margin: 0;
  padding: 12px 18px; top: 8px; left: 8px; z-index: 999;
  background: var(--white);
}

.site-header {
  position: absolute;
  inset: 0 0 auto;
  z-index: 20;
  color: var(--white);
  border-bottom: 1px solid rgba(255,255,255,.28);
}
.header-inner {
  width: var(--page);
  min-height: 104px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 36px;
}
.brand { display: inline-flex; align-items: center; gap: 13px; letter-spacing: .12em; }
.brand-mark {
  width: 46px; height: 46px;
  border: 1px solid rgba(255,255,255,.8);
  border-radius: 50%;
  display: grid; place-items: center;
  font-family: var(--serif); font-size: 18px;
}
.brand-name { font-size: 13px; text-transform: uppercase; font-weight: 600; }
.main-nav { justify-self: end; }
.main-nav ul { display: flex; gap: 28px; margin: 0; padding: 0; list-style: none; }
.main-nav a { font-size: 12px; letter-spacing: .09em; text-transform: uppercase; }
.main-nav a:hover { color: #eadaba; }
.menu-toggle {
  display: none;
  width: 45px; height: 45px;
  border: 1px solid rgba(255,255,255,.5);
  border-radius: 50%; background: transparent;
  cursor: pointer;
}
.menu-toggle span, .menu-toggle::before, .menu-toggle::after {
  content: ""; display: block; width: 17px; height: 1px; margin: 5px auto; background: currentColor;
}

.property-hero {
  min-height: min(920px, 100vh);
  position: relative;
  display: flex;
  align-items: end;
  color: var(--white);
  background: #223033 center / cover no-repeat;
}
.property-hero::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(11,20,22,.34) 0%, rgba(11,20,22,.06) 36%, rgba(11,20,22,.76) 100%);
}
.hero-content {
  position: relative;
  width: var(--page);
  margin: 0 auto;
  padding: 210px 0 82px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  align-items: end;
  gap: 64px;
}
.eyebrow, .section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 18px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
}
.eyebrow::before, .section-kicker::before { content: ""; width: 34px; height: 1px; background: currentColor; }
.hero-player { margin-top: 22px; max-width: 800px; }
.entry-player { margin: 0 0 28px; }
.property-hero h1 {
  max-width: 800px;
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(54px, 7vw, 102px);
  font-weight: 400;
  line-height: .98;
  letter-spacing: -.035em;
}
.hero-summary { border-left: 1px solid rgba(255,255,255,.45); padding-left: 34px; }
.guide { margin: 0 0 2px; font-size: 11px; letter-spacing: .16em; text-transform: uppercase; opacity: .75; }
.price { margin: 0 0 26px; font-family: var(--serif); font-size: 36px; line-height: 1.2; }
.location { margin: 0 0 15px; font-size: 13px; letter-spacing: .1em; text-transform: uppercase; }
.facts { display: flex; flex-wrap: wrap; gap: 9px 16px; margin: 0; font-size: 13px; }
.facts span:not(:last-child)::after { content: ""; border-right: 1px solid rgba(255,255,255,.5); margin-left: 16px; }
.hero-scroll {
  position: absolute;
  right: 34px; bottom: 33px;
  writing-mode: vertical-rl;
  font-size: 9px; letter-spacing: .2em; text-transform: uppercase;
  opacity: .7;
}

.property-intro { background: var(--cream); padding: 100px 0; }
.intro-grid {
  width: var(--page); margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1.6fr; gap: 8vw;
}
.section-kicker { color: var(--gold); }
.intro-grid h2, .section-heading, .calculator-section h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(42px, 5vw, 72px);
  line-height: 1.06;
  font-weight: 400;
  letter-spacing: -.025em;
}
.intro-copy { max-width: 720px; }
.intro-copy .lead { margin: 0 0 24px; font-family: var(--serif); font-size: 27px; line-height: 1.45; }
.intro-copy p { color: var(--ink-soft); }
.text-link {
  display: inline-flex; align-items: center; gap: 14px;
  margin-top: 18px; padding-bottom: 7px;
  border-bottom: 1px solid var(--ink);
  font-size: 11px; font-weight: 700; letter-spacing: .15em; text-transform: uppercase;
}

.gallery-section { padding: 24px; background: var(--ink); }
.gallery-grid {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  grid-template-rows: 450px 450px 380px;
  gap: 24px;
}
.gallery-item { position: relative; overflow: hidden; border: 0; padding: 0; background: transparent; cursor: zoom-in; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s cubic-bezier(.2,.65,.25,1); }
.gallery-item:hover img { transform: scale(1.025); }
.gallery-item:nth-child(1) { grid-row: 1 / span 2; }
.gallery-item:nth-child(4) { grid-column: 1 / -1; }
.gallery-caption {
  position: absolute; left: 24px; bottom: 20px;
  color: var(--white); font-size: 9px; letter-spacing: .16em; text-transform: uppercase;
  text-shadow: 0 1px 8px rgba(0,0,0,.5);
}

.details-section { padding: 112px 0; }
.details-inner { width: var(--page); margin: 0 auto; }
.details-top { display: flex; justify-content: space-between; align-items: end; gap: 32px; margin-bottom: 62px; }
.details-top p { max-width: 440px; margin: 0; color: var(--ink-soft); }
.detail-list { border-top: 1px solid var(--line); }
.detail-row {
  display: grid; grid-template-columns: 48px 1fr auto;
  gap: 24px; align-items: center;
  padding: 27px 0; border-bottom: 1px solid var(--line);
}
.detail-number { color: var(--gold); font-family: var(--serif); font-style: italic; }
.detail-label { font-family: var(--serif); font-size: 24px; }
.detail-value { color: var(--ink-soft); font-size: 13px; letter-spacing: .06em; }

.contact-band {
  position: relative;
  min-height: 560px;
  display: grid; place-items: center;
  color: var(--white); text-align: center;
  background: var(--ink) center / cover no-repeat;
}
.contact-band::before { content: ""; position: absolute; inset: 0; background: rgba(15,29,31,.65); }
.contact-content { position: relative; max-width: 780px; padding: 90px 32px; }
.contact-content h2 { margin: 0 0 22px; font: 400 clamp(46px, 6vw, 80px)/1.05 var(--serif); }
.contact-content p { max-width: 560px; margin: 0 auto 34px; color: rgba(255,255,255,.78); }
.button {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 174px; min-height: 54px; padding: 13px 25px;
  border: 1px solid var(--ink); background: var(--ink); color: var(--white);
  font-size: 10px; font-weight: 700; letter-spacing: .17em; text-transform: uppercase;
  cursor: pointer; transition: .25s ease;
}
.button:hover { background: var(--gold); border-color: var(--gold); }
.button-light { border-color: var(--white); background: var(--white); color: var(--ink); }
.button-light:hover { color: var(--white); }
.button-outline { background: transparent; color: var(--ink); }

.calculator-section { padding: 108px 0; background: var(--cream); }
.calculator-inner { width: var(--page); margin: 0 auto; }
.calculator-section h2 { max-width: 700px; margin-bottom: 55px; }
.calculator-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.calculator-card { padding: 38px; background: var(--paper); border: 1px solid rgba(22,35,38,.09); }
.calculator-card h3 { margin: 0 0 25px; font: 400 30px/1.2 var(--serif); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field { display: grid; gap: 7px; }
.field-full { grid-column: 1 / -1; }
.field label { font-size: 10px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.field input {
  width: 100%; min-height: 52px; padding: 12px 14px;
  border: 1px solid var(--line); background: transparent; border-radius: 0;
}
.calculator-actions { display: flex; align-items: center; gap: 20px; margin-top: 22px; }
.calculator-result { margin: 0; font-family: var(--serif); font-size: 22px; }
.fine-print { margin: 22px 0 0; color: var(--ink-soft); font-size: 11px; }

.site-footer { padding: 72px 0 30px; background: var(--ink); color: rgba(255,255,255,.72); }
.footer-inner { width: var(--page); margin: 0 auto; }
.footer-top { display: grid; grid-template-columns: 1.1fr .7fr .7fr; gap: 70px; padding-bottom: 60px; }
.footer-brand { color: var(--white); }
.footer-brand .brand-mark { margin-bottom: 20px; }
.footer-brand p { max-width: 360px; }
.footer-column h3 { margin: 0 0 18px; color: var(--white); font-size: 10px; letter-spacing: .16em; text-transform: uppercase; }
.footer-column ul { margin: 0; padding: 0; list-style: none; }
.footer-column li { margin: 8px 0; }
.footer-bottom { display: flex; justify-content: space-between; gap: 24px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,.14); font-size: 10px; letter-spacing: .08em; text-transform: uppercase; }

.sticky-actions {
  position: fixed; right: 22px; bottom: 22px; z-index: 30;
  display: flex; gap: 9px;
}
.sticky-actions .button { min-width: auto; min-height: 48px; box-shadow: 0 8px 25px rgba(0,0,0,.15); }
.sticky-actions .share { width: 48px; padding: 0; background: var(--paper); border-color: var(--paper); color: var(--ink); }

.modal {
  position: fixed; inset: 0; z-index: 100;
  display: none; place-items: center;
  padding: 24px; background: rgba(9,18,20,.76);
}
.modal.is-open { display: grid; }
.modal-panel { position: relative; width: min(640px, 100%); max-height: calc(100vh - 48px); overflow: auto; padding: 50px; background: var(--paper); }
.modal-panel h2 { margin: 0 0 8px; font: 400 46px/1.1 var(--serif); }
.modal-panel > p { margin: 0 0 30px; color: var(--ink-soft); }
.modal-close {
  position: absolute; top: 18px; right: 18px; width: 38px; height: 38px;
  border: 0; background: transparent; font-size: 24px; cursor: pointer;
}
.lightbox-panel { width: min(1200px, 100%); padding: 0; background: #0a0e0f; touch-action: pan-y; }
.lightbox-stage { position: relative; display: grid; }
.lightbox-panel img { max-height: calc(100vh - 48px); object-fit: contain; -webkit-user-drag: none; user-select: none; }
.lightbox-panel:has(.lightbox-player) img { max-height: calc(100vh - 170px); }
.lightbox-player { position: relative; z-index: 2; padding: 16px 20px; color: var(--white); }
.lightbox-panel .modal-close { z-index: 2; color: white; background: rgba(0,0,0,.35); }
.lightbox-nav {
  position: absolute; top: 50%; z-index: 2; transform: translateY(-50%);
  display: grid; place-items: center; width: 48px; height: 48px;
  border: 0; border-radius: 50%; padding: 0 0 4px;
  font: 400 34px/1 var(--serif); color: white; background: rgba(0,0,0,.35);
  cursor: pointer; transition: background .3s ease;
}
.lightbox-nav:hover { background: rgba(0,0,0,.65); }
.lightbox-prev { left: 18px; }
.lightbox-next { right: 18px; }
.lightbox-counter {
  position: absolute; left: 50%; bottom: 18px; z-index: 2;
  margin: 0; transform: translateX(-50%); padding: 6px 14px;
  font-size: 12px; letter-spacing: .12em; color: white; background: rgba(0,0,0,.35);
}

@media (max-width: 980px) {
  :root { --page: min(100% - 40px, 760px); }
  .header-inner { min-height: 84px; }
  .main-nav {
    display: none; position: absolute; top: 84px; left: 0; right: 0;
    padding: 24px 20px 32px; background: var(--ink);
  }
  .main-nav.is-open { display: block; }
  .main-nav ul { display: grid; gap: 16px; }
  .menu-toggle { display: block; justify-self: end; }
  .hero-content { grid-template-columns: 1fr; gap: 40px; }
  .hero-summary { max-width: 520px; }
  .intro-grid { grid-template-columns: 1fr; gap: 38px; }
  .gallery-grid { grid-template-rows: 400px 300px 300px; }
  .calculator-grid { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 640px) {
  :root { --page: calc(100% - 32px); }
  .brand-name { display: none; }
  .property-hero { min-height: 780px; }
  .hero-content { padding: 160px 0 54px; }
  .property-hero h1 { font-size: 53px; }
  .hero-summary { padding-left: 22px; }
  .hero-scroll { display: none; }
  .property-intro, .details-section, .calculator-section { padding: 75px 0; }
  .intro-copy .lead { font-size: 23px; }
  .gallery-section { padding: 10px; }
  .gallery-grid { display: grid; grid-template-columns: 1fr; grid-template-rows: repeat(4, 300px); gap: 10px; }
  .gallery-item:nth-child(n) { grid-column: auto; grid-row: auto; }
  .details-top { display: grid; margin-bottom: 40px; }
  .detail-row { grid-template-columns: 28px 1fr; gap: 12px; }
  .detail-value { grid-column: 2; }
  .form-grid { grid-template-columns: 1fr; }
  .field-full { grid-column: auto; }
  .calculator-card { padding: 26px 20px; }
  .footer-top { grid-template-columns: 1fr; gap: 42px; }
  .footer-brand { grid-column: auto; }
  .footer-bottom { display: grid; }
  .sticky-actions { right: 12px; bottom: 12px; }
  .sticky-actions .button { min-height: 44px; }
  .modal-panel { padding: 42px 24px 28px; }
  .lightbox-panel { padding: 0; }
  .lightbox-nav { width: 40px; height: 40px; font-size: 28px; }
  .lightbox-prev { left: 8px; }
  .lightbox-next { right: 8px; }
}

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