/* Broadfield House — site styles */

:root {
  --bg: #fbf8f3;
  --bg-alt: #f1ece1;
  --ink: #1a2436;
  --ink-soft: #4a5468;
  --accent: #2c4358;
  --gold: #a98a3f;
  --rule: #d9d2c2;
  --max: 1100px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Cormorant Garamond", "EB Garamond", Georgia, "Times New Roman", serif;
  font-size: 19px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; border-bottom: 1px solid rgba(44,67,88,0.25); }
a:hover { color: var(--gold); border-bottom-color: var(--gold); }

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

/* Header */
.site-header {
  border-bottom: 1px solid var(--rule);
  background: var(--bg);
}
.header-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.6rem 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
}
.brand {
  font-family: "Playfair Display", "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  letter-spacing: 0.04em;
  color: var(--ink);
  border: none;
  text-align: center;
}
.brand-sub {
  font-size: 0.85rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
nav.primary {
  display: flex;
  flex-wrap: wrap;
  gap: 1.6rem;
  margin-top: 0.4rem;
}
nav.primary a {
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-soft);
  border: none;
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
}
nav.primary a:hover,
nav.primary a.active {
  color: var(--ink);
  border-bottom-color: var(--gold);
}

/* Hero */
.hero {
  position: relative;
  background: var(--ink);
  color: #fff;
  overflow: hidden;
}
.hero img {
  width: 100%;
  max-height: 78vh;
  object-fit: cover;
  opacity: 0.78;
}

/* Cross-fading rotation between two hero images */
.hero-rotate .hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  animation: heroFade 18s infinite ease-in-out;
}
.hero-rotate {
  position: relative;
  height: 78vh;
  min-height: 480px;
  max-height: 760px;
}
.hero-rotate .hero-img-a {
  animation-delay: 0s;
}
.hero-rotate .hero-img-b {
  animation-delay: 9s;
}
@keyframes heroFade {
  0%   { opacity: 0; }
  6%   { opacity: 0.85; }
  50%  { opacity: 0.85; }
  56%  { opacity: 0; }
  100% { opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-rotate .hero-img { animation: none; opacity: 0.85; }
  .hero-rotate .hero-img-b { display: none; }
}
.hero-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem;
  background: linear-gradient(to bottom, rgba(0,0,0,0.15), rgba(0,0,0,0.55));
}
.hero h1 {
  font-family: "Playfair Display", "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
  font-size: clamp(2rem, 5.5vw, 4rem);
  margin: 0 0 0.5rem;
  letter-spacing: 0.02em;
  text-shadow: 0 2px 18px rgba(0,0,0,0.4);
}
.hero p.tagline {
  font-style: italic;
  font-size: clamp(1rem, 1.6vw, 1.3rem);
  max-width: 38rem;
  margin: 0;
  letter-spacing: 0.04em;
  text-shadow: 0 1px 10px rgba(0,0,0,0.5);
}

/* Content */
main {
  max-width: var(--max);
  margin: 0 auto;
  padding: 4rem 1.5rem 5rem;
}
.lede {
  font-size: 1.35rem;
  line-height: 1.55;
  color: var(--ink-soft);
  font-style: italic;
  text-align: center;
  max-width: 38rem;
  margin: 0 auto 3rem;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 2rem;
}
section { margin-bottom: 3rem; }
h2 {
  font-family: "Playfair Display", "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
  font-size: clamp(1.5rem, 2.8vw, 2.2rem);
  letter-spacing: 0.02em;
  margin: 2.5rem 0 1rem;
  color: var(--ink);
}
h3 {
  font-family: "Playfair Display", "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
  font-size: 1.3rem;
  margin: 1.6rem 0 0.6rem;
  color: var(--accent);
}
p { margin: 0 0 1.1rem; }
.drop-cap::first-letter {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 3.6em;
  float: left;
  line-height: 0.85;
  padding: 0.1em 0.1em 0 0;
  color: var(--gold);
  font-weight: 600;
}
.ornament {
  text-align: center;
  margin: 3rem 0;
  color: var(--gold);
  letter-spacing: 1rem;
  font-size: 0.9rem;
}
.ornament::before { content: "\2756"; }
.signature {
  text-align: center;
  font-style: italic;
  color: var(--ink-soft);
  margin-top: 3rem;
  font-size: 0.95rem;
}

/* Featured cards on home page */
.feature-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
  margin: 3rem 0;
}
.feature {
  text-align: center;
}
.feature img {
  border-radius: 2px;
  margin-bottom: 1rem;
  aspect-ratio: 4/3;
  object-fit: cover;
  filter: sepia(0.05);
  transition: filter 0.4s, transform 0.4s;
}
.feature:hover img { filter: sepia(0); transform: scale(1.02); }
.feature h3 { margin: 0.5rem 0 0.4rem; }
.feature p { font-size: 1rem; color: var(--ink-soft); }
.feature a.more {
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  border: none;
  border-bottom: 1px solid var(--gold);
  padding-bottom: 2px;
}

/* Gallery section dividers */
.gallery-section {
  font-family: "Playfair Display", Georgia, serif;
  font-weight: 600;
  font-size: 1.4rem;
  text-align: center;
  letter-spacing: 0.04em;
  margin: 3rem 0 1.4rem;
  color: var(--accent);
  position: relative;
  padding-bottom: 0.8rem;
}
.gallery-section::after {
  content: "";
  display: block;
  width: 50px;
  height: 1px;
  background: var(--gold);
  margin: 0.6rem auto 0;
}
.gallery-section:first-of-type { margin-top: 1rem; }

/* Gallery */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.4rem;
}
.gallery figure {
  margin: 0;
  background: var(--bg-alt);
  border: 1px solid var(--rule);
  padding: 0.6rem;
  transition: transform 0.3s, box-shadow 0.3s;
}
.gallery figure:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(26,36,54,0.12);
}
.gallery img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
}
.gallery figcaption {
  font-size: 0.95rem;
  color: var(--ink-soft);
  text-align: center;
  padding: 0.7rem 0.4rem 0.4rem;
  font-style: italic;
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(20,28,42,0.92);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 2rem;
  cursor: zoom-out;
}
.lightbox.open { display: flex; }
.lightbox img {
  max-width: 92vw;
  max-height: 86vh;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}
.lightbox figcaption {
  position: absolute;
  bottom: 1.5rem;
  left: 0; right: 0;
  text-align: center;
  color: #f4eedd;
  font-style: italic;
  font-size: 1rem;
}

/* History page */
.history-body { max-width: 60rem; margin: 0 auto; }
.history-body p { font-size: 1.1rem; }
.inline-figure {
  margin: 2.5rem auto;
  text-align: center;
  max-width: 100%;
}
.inline-figure img {
  margin: 0 auto;
  border: 1px solid var(--rule);
}
.inline-figure figcaption {
  font-size: 0.9rem;
  color: var(--ink-soft);
  font-style: italic;
  margin-top: 0.6rem;
}

/* Section opener with year marker */
.section-opener {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin: 3rem 0 0.6rem;
  border-bottom: 1px solid var(--rule);
  padding-bottom: 0.4rem;
}
.section-opener h3 {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.7rem;
  margin: 0;
  color: var(--ink);
  flex: 1;
}
.section-opener .year {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-style: italic;
  font-size: 1rem;
  color: var(--gold);
  letter-spacing: 0.1em;
  white-space: nowrap;
}

/* Pull-quote */
.pullquote {
  font-family: "Playfair Display", Georgia, serif;
  font-style: italic;
  font-size: 1.5rem;
  line-height: 1.4;
  color: var(--accent);
  text-align: center;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding: 1.6rem 1rem;
  margin: 2rem 0;
}
.pullquote cite {
  display: block;
  font-size: 0.85rem;
  font-style: normal;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-top: 0.8rem;
}

/* Callout / parchment box */
.callout {
  background: var(--bg-alt);
  border: 1px solid var(--rule);
  padding: 1.8rem 1.8rem 1.4rem;
  margin: 2.5rem 0;
  position: relative;
}
.callout h4 {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.2rem;
  margin: 0 0 0.8rem;
  color: var(--accent);
  letter-spacing: 0.04em;
}
.callout ul {
  margin: 0;
  padding-left: 1.2rem;
  font-size: 1rem;
  line-height: 1.55;
}
.callout li {
  margin-bottom: 0.6rem;
}
.callout li b { color: var(--accent); }

.callout.signature-find img {
  max-width: 100%;
  margin: 0.4rem auto 1rem;
  border: 1px solid var(--rule);
  background: #fff;
}
.callout.signature-find p {
  font-size: 1.02rem;
  margin-bottom: 0.8rem;
}

/* Side-by-side figures (small inline) */
.figure-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin: 2rem 0;
}
@media (max-width: 600px) {
  .figure-row { grid-template-columns: 1fr; }
}
.figure-row figure { margin: 0; }
.figure-row img { width: 100%; aspect-ratio: 4/3; object-fit: cover; border: 1px solid var(--rule); }
.figure-row figcaption {
  font-size: 0.85rem;
  color: var(--ink-soft);
  font-style: italic;
  text-align: center;
  margin-top: 0.4rem;
}

/* Restoration journal timeline */
.journal-intro {
  max-width: 38rem;
  margin: 0 auto 3rem;
  text-align: center;
  font-style: italic;
  color: var(--ink-soft);
  font-size: 1.15rem;
  line-height: 1.5;
}
.journal {
  max-width: 68rem;
  margin: 0 auto;
  position: relative;
}
.journal::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0; bottom: 0;
  width: 1px;
  background: var(--rule);
  transform: translateX(-50%);
}
.journal-entry {
  margin-bottom: 3rem;
  position: relative;
}
.journal-entry::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 1.5rem;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--gold);
  transform: translateX(-50%);
  z-index: 1;
}
.journal-date {
  text-align: center;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-style: italic;
  color: var(--gold);
  font-size: 0.95rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin: 0 0 1.6rem;
  padding-top: 0.4rem;
}
.journal-content {
  background: var(--bg);
  border: 1px solid var(--rule);
  padding: 0;
  margin: 0 auto;
  max-width: 57rem;
  position: relative;
  z-index: 2;
}
.journal-content img {
  width: 100%;
  height: auto;
  display: block;
}
.journal-text {
  padding: 1.5rem 1.8rem 1.6rem;
}
.journal-text h4 {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--accent);
  margin: 0 0 0.7rem;
  letter-spacing: 0.02em;
}
.journal-text p {
  font-size: 1.02rem;
  line-height: 1.55;
  color: var(--ink);
  margin: 0 0 0.8rem;
}
.journal-text p:last-child { margin-bottom: 0; }
.journal-text .meta {
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-top: 0.8rem;
  font-style: normal;
}

@media (max-width: 600px) {
  .journal::before { left: 1.4rem; }
  .journal-entry::before { left: 1.4rem; top: 1rem; }
  .journal-date { text-align: left; padding-left: 3rem; margin-bottom: 0.8rem; }
  .journal-content { margin-left: 3rem; }
}

/* Sources list */
.sources {
  margin-top: 4rem;
  padding-top: 2rem;
  border-top: 1px solid var(--rule);
}
.sources h3 {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.5rem;
  text-align: center;
  margin-bottom: 1.5rem;
}
.sources ol {
  font-size: 0.92rem;
  line-height: 1.55;
  padding-left: 1.4rem;
  color: var(--ink-soft);
}
.sources ol li {
  margin-bottom: 0.9rem;
}
.sources ol li b { color: var(--ink); }
.sources ol li i { color: var(--ink-soft); }

/* Footer */
footer {
  border-top: 1px solid var(--rule);
  background: var(--bg-alt);
  padding: 2.5rem 1.5rem;
  text-align: center;
  color: var(--ink-soft);
  font-size: 0.9rem;
}
footer .small { font-size: 0.8rem; letter-spacing: 0.18em; text-transform: uppercase; margin-bottom: 0.4rem; }
footer p { margin: 0.3rem 0; }

@media (max-width: 600px) {
  body { font-size: 17px; }
  main { padding: 2.5rem 1.2rem 3rem; }
  nav.primary { gap: 1rem; }
}
