/* ============================================================
   TRACERY REALTY — Candlelit Stone
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;1,400;1,500&family=Nunito+Sans:wght@300;400;600;700&display=swap');

:root {
  /* -- Color tokens -- */
  --charcoal:      #1b191d;   /* deepest stone, primary dark bg */
  --stone:         #262229;   /* secondary dark panel */
  --stone-soft:    #322c34;   /* borders / hover on dark */
  --parchment:     #f6f0e4;   /* light bg */
  --parchment-dim: #ece3d2;   /* light panel */
  --ink:           #2a2420;   /* body text on light */
  --ink-soft:      #5c5248;   /* secondary text on light */
  --gold:          #c9a768;   /* candlelight gold, primary accent */
  --gold-bright:   #e3c98f;   /* lit gold, hover / highlight */
  --gold-dim:      #8b764a;   /* muted gold, hairlines on dark */
  --burgundy:      #5b2a35;   /* deep accent */

  /* -- Type -- */
  --display: 'Cormorant Garamond', Georgia, serif;
  --body:    'Nunito Sans', -apple-system, sans-serif;

  --container: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--body);
  color: var(--ink);
  background: var(--parchment);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  font-family: var(--display);
  font-weight: 500;
  margin: 0 0 0.5em;
  line-height: 1.1;
  letter-spacing: 0.01em;
}

p { line-height: 1.7; margin: 0 0 1em; }

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

/* Visible keyboard focus everywhere */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}

/* ============================================================
   HEADER
   ============================================================ */

.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(27, 25, 29, 0.72);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(201, 167, 104, 0.18);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 84px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.brand img { height: 40px; width: auto; }
.brand span {
  font-family: var(--display);
  font-size: 1.5rem;
  color: var(--parchment);
  letter-spacing: 0.02em;
}

.main-nav { display: flex; align-items: center; gap: 40px; }
.main-nav a {
  font-family: var(--body);
  font-size: 0.92rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--parchment-dim);
  position: relative;
  padding: 4px 0;
  transition: color 0.25s ease;
}
.main-nav a:hover, .main-nav a[aria-current="page"] { color: var(--gold-bright); }
.main-nav a[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -4px;
  height: 1px;
  background: var(--gold);
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--gold-dim);
  border-radius: 3px;
  width: 42px; height: 38px;
  color: var(--parchment);
  font-size: 1.3rem;
  cursor: pointer;
}

@media (max-width: 780px) {
  .nav-toggle { display: block; }
  .main-nav {
    position: absolute;
    top: 84px; left: 0; right: 0;
    background: var(--charcoal);
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    border-bottom: 1px solid rgba(201, 167, 104, 0.18);
  }
  .main-nav.open { max-height: 320px; }
  .main-nav a { width: 100%; padding: 16px 32px; border-bottom: 1px solid var(--stone-soft); }
}

/* ============================================================
   ARCH SIGNATURE MOTIF
   ============================================================ */

/* Repeating pointed-arch row divider, used between sections */
.arch-divider {
  width: 100%;
  height: 34px;
  display: block;
}
.arch-divider--flip { transform: scaleY(-1); }

/* Arch-topped frame used on cards / panels — echoes the logo window */
.arch-frame {
  position: relative;
  border-top-left-radius: 120px 60px;
  border-top-right-radius: 120px 60px;
  overflow: hidden;
  border: 1px solid var(--gold-dim);
}

/* subtle quatrefoil watermark, tileable */
.tracery-bg {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120' viewBox='0 0 120 120'%3E%3Cg fill='none' stroke='%23c9a768' stroke-width='1' opacity='0.07'%3E%3Ccircle cx='40' cy='30' r='14'/%3E%3Ccircle cx='60' cy='30' r='14'/%3E%3Ccircle cx='40' cy='50' r='14'/%3E%3Ccircle cx='60' cy='50' r='14'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 160px 160px;
}

/* ============================================================
   BUTTONS
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--body);
  font-size: 0.9rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 15px 34px;
  border-radius: 2px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.25s ease;
}
.btn-gold {
  background: var(--gold);
  color: var(--charcoal);
  font-weight: 700;
}
.btn-gold:hover { background: var(--gold-bright); transform: translateY(-1px); }

.btn-outline {
  border-color: var(--gold-dim);
  color: var(--parchment);
}
.btn-outline:hover { border-color: var(--gold); color: var(--gold-bright); }

.btn-outline-dark {
  border-color: var(--ink-soft);
  color: var(--ink);
}
.btn-outline-dark:hover { border-color: var(--burgundy); color: var(--burgundy); }

/* ============================================================
   HERO (index)
   ============================================================ */

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: radial-gradient(ellipse 60% 55% at 72% 42%, rgba(201,167,104,0.16), transparent 65%), var(--charcoal);
  color: var(--parchment);
  overflow: hidden;
  padding-top: 84px;
}

.hero-arch {
  position: absolute;
  right: 4%;
  top: 50%;
  transform: translateY(-46%);
  width: min(38vw, 480px);
  opacity: 0.9;
}

.hero .wrap { position: relative; z-index: 2; }
.hero-eyebrow {
  font-size: 0.8rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold-bright);
  margin-bottom: 22px;
}
.hero h1 {
  font-size: clamp(2.6rem, 5.6vw, 4.6rem);
  max-width: 15ch;
  font-style: italic;
  font-weight: 500;
}
.hero h1 em { color: var(--gold-bright); font-style: italic; }
.hero-sub {
  max-width: 46ch;
  font-size: 1.12rem;
  color: var(--parchment-dim);
  margin-bottom: 36px;
}
.hero-ctas { display: flex; gap: 18px; flex-wrap: wrap; }

@media (max-width: 780px) {
  .hero-arch { opacity: 0.22; width: 70vw; right: 50%; transform: translate(50%, -46%); }
}

/* ============================================================
   SECTIONS — shared
   ============================================================ */

section { position: relative; }

.section-dark { background: var(--charcoal); color: var(--parchment); }
.section-light { background: var(--parchment); color: var(--ink); }
.section-pad { padding: 110px 0; }

.eyebrow {
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold-dim);
  margin-bottom: 16px;
  display: block;
}
.section-dark .eyebrow { color: var(--gold-bright); }

.section-heading { font-size: clamp(2rem, 3.6vw, 2.9rem); margin-bottom: 18px; }
.section-intro { max-width: 60ch; font-size: 1.06rem; color: var(--ink-soft); }
.section-dark .section-intro { color: var(--parchment-dim); }

/* -- About preview (two column) -- */
.about-preview { display: grid; grid-template-columns: 1fr 1fr; gap: 72px; align-items: center; }
.about-preview .art { aspect-ratio: 4/5; }
.value-list { list-style: none; padding: 0; margin: 32px 0; }
.value-list li {
  display: flex; gap: 18px;
  padding: 20px 0;
  border-top: 1px solid rgba(0,0,0,0.08);
}
.value-list li:last-child { border-bottom: 1px solid rgba(0,0,0,0.08); }
.value-list .arch-icon { flex-shrink: 0; width: 30px; height: 34px; margin-top: 2px; }
.value-list h3 { font-size: 1.2rem; margin-bottom: 4px; }
.value-list p { color: var(--ink-soft); margin: 0; font-size: 0.96rem; }

@media (max-width: 860px) {
  .about-preview { grid-template-columns: 1fr; gap: 40px; }
}

/* -- Neighborhoods -- */
.neighborhood-section { display: grid; grid-template-columns: 1fr 1fr; gap: 72px; align-items: center; }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.tag-cloud span {
  border: 1px solid var(--gold-dim);
  padding: 9px 20px;
  border-radius: 30px;
  font-size: 0.9rem;
  color: var(--ink-soft);
  transition: all 0.25s ease;
}
.section-dark .tag-cloud span { color: var(--parchment-dim); border-color: rgba(201,167,104,0.35); }
.tag-cloud span:hover { border-color: var(--gold); color: var(--burgundy); transform: translateY(-2px); }
.section-dark .tag-cloud span:hover { color: var(--gold-bright); }

@media (max-width: 860px) {
  .neighborhood-section { grid-template-columns: 1fr; gap: 40px; }
  .neighborhood-section .art { order: -1; }
}

/* -- CTA band -- */
.cta-band { text-align: center; padding: 130px 0; }
.cta-band h2 { font-size: clamp(2.1rem, 4vw, 3.2rem); max-width: 20ch; margin: 0 auto 26px; }
.cta-band .section-intro { margin: 0 auto 40px; }
.cta-band .hero-ctas { justify-content: center; }

/* -- Illustrated panels (replace photography) -- */
.scene {
  position: relative;
  overflow: hidden;
  background: linear-gradient(160deg, #2a2530 0%, #1b191d 70%);
  border: 1px solid rgba(201,167,104,0.25);
}
.scene svg { width: 100%; height: 100%; display: block; }

/* ============================================================
   ABOUT PAGE
   ============================================================ */

.page-hero {
  background: var(--charcoal);
  color: var(--parchment);
  padding: 168px 0 90px;
  text-align: center;
}
.page-hero h1 { font-size: clamp(2.4rem, 5vw, 3.6rem); max-width: 18ch; margin: 0 auto 18px; }
.page-hero .section-intro { margin: 0 auto; color: var(--parchment-dim); }

.story-section { max-width: 720px; margin: 0 auto; text-align: left; }
.story-section .drop { font-size: 1.1rem; }
.story-section .drop:first-of-type::first-letter {
  font-family: var(--display);
  font-size: 3.6rem;
  float: left;
  line-height: 0.8;
  padding: 6px 10px 0 0;
  color: var(--gold);
}

.credential-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: rgba(0,0,0,0.1);
  margin-top: 56px;
  border: 1px solid rgba(0,0,0,0.1);
}
.credential-grid div {
  background: var(--parchment);
  padding: 30px 22px;
  text-align: center;
}
.credential-grid h4 {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-dim);
  font-family: var(--body);
  font-weight: 700;
  margin-bottom: 10px;
}
.credential-grid p { font-family: var(--display); font-size: 1.3rem; margin: 0; }

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

.philosophy {
  max-width: 780px;
  margin: 0 auto;
  text-align: center;
}
.philosophy blockquote {
  margin: 0 0 30px;
  font-family: var(--display);
  font-style: italic;
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  line-height: 1.4;
  border-left: 2px solid var(--gold);
  padding-left: 30px;
  text-align: left;
  color: var(--ink);
}
.philosophy .section-intro { margin: 0 auto; }

/* ============================================================
   CONTACT PAGE
   ============================================================ */

.contact-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 64px;
  align-items: start;
}

.contact-form { display: flex; flex-direction: column; gap: 22px; }
.field label {
  display: block;
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 8px;
}
.field input, .field select, .field textarea {
  width: 100%;
  font-family: var(--body);
  font-size: 1rem;
  padding: 13px 14px;
  border: 1px solid rgba(0,0,0,0.18);
  background: #fff;
  color: var(--ink);
  border-radius: 2px;
}
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--gold);
}
.field textarea { resize: vertical; min-height: 130px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
@media (max-width: 560px) { .field-row { grid-template-columns: 1fr; } }

.form-note { font-size: 0.85rem; color: var(--ink-soft); margin-top: -6px; }

.form-status {
  padding: 14px 18px;
  border-radius: 2px;
  font-size: 0.92rem;
  display: none;
}
.form-status.show { display: block; }
.form-status.ok { background: #eef4ea; color: #2f5230; border: 1px solid #b9d3ae; }
.form-status.err { background: #fbeceb; color: #7a2320; border: 1px solid #eab6b2; }

.contact-info {
  background: var(--charcoal);
  color: var(--parchment);
  padding: 46px 38px;
}
.contact-info h3 { color: var(--gold-bright); font-size: 1.5rem; }
.info-row { display: flex; gap: 16px; padding: 18px 0; border-top: 1px solid var(--stone-soft); }
.info-row:first-of-type { border-top: none; margin-top: 8px; }
.info-row .arch-icon { width: 22px; height: 26px; flex-shrink: 0; margin-top: 2px; }
.info-row span { color: var(--parchment-dim); font-size: 0.96rem; }
.contact-info .quote {
  margin-top: 30px;
  padding-top: 26px;
  border-top: 1px solid var(--stone-soft);
  font-family: var(--display);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--gold-bright);
  line-height: 1.5;
}

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

/* ============================================================
   FOOTER
   ============================================================ */

.site-footer {
  background: var(--charcoal);
  color: var(--parchment-dim);
  padding: 70px 0 30px;
}
.footer-top {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
  padding-bottom: 44px;
  border-bottom: 1px solid var(--stone-soft);
}
.footer-brand { display: flex; align-items: center; gap: 12px; }
.footer-brand img { height: 34px; }
.footer-brand span { font-family: var(--display); font-size: 1.3rem; color: var(--parchment); }
.footer-links { display: flex; gap: 46px; flex-wrap: wrap; }
.footer-links div h5 {
  font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--gold-dim); margin-bottom: 14px; font-family: var(--body);
}
.footer-links a, .footer-links p { display: block; font-size: 0.92rem; margin-bottom: 8px; color: var(--parchment-dim); }
.footer-links a:hover { color: var(--gold-bright); }
.footer-bottom {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  padding-top: 26px; font-size: 0.82rem; color: var(--gold-dim);
}

@media (max-width: 640px) {
  .footer-top, .footer-bottom { flex-direction: column; }
}
