/* ===================================================================
   Homes in New Kent — shared stylesheet
   Recolor the whole site by editing the variables in :root below.
   To match Foundation Real Estate Group, change --brand and --accent
   to your brand colors.
   =================================================================== */

:root {
  /* ---- Brand colors (matched to the Foundation Real Estate Group logo) ---- */
  --brand:        #2f6ba4;   /* Foundation blue — primary brand color */
  --brand-dark:   #1d4a73;   /* darker blue for headers/footers       */
  --accent:       #d3a449;   /* Foundation gold — buttons / highlights*/
  --accent-dark:  #b1842f;
  --ink:          #1c2630;   /* body text                          */
  --muted:        #5b6b7a;   /* secondary text                     */
  --line:         #e3e8ee;   /* hairlines / borders                */
  --bg:           #ffffff;
  --bg-alt:       #f5f7fa;   /* soft section background            */
  --bg-tint:      #eef2f7;
  --white:        #ffffff;
  --shadow:       0 10px 30px rgba(20,41,63,.10);
  --shadow-sm:    0 4px 14px rgba(20,41,63,.08);
  --radius:       14px;
  --radius-sm:    9px;
  --maxw:         1160px;
  --font-head: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* ---------- Reset ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--accent-dark); }

h1, h2, h3, h4 { font-family: var(--font-head); color: var(--brand-dark); line-height: 1.2; margin: 0 0 .5em; font-weight: 700; }
h1 { font-size: clamp(2rem, 4.5vw, 3.25rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.3rem); }
h3 { font-size: 1.3rem; }
p  { margin: 0 0 1.1em; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 22px; }
.section { padding: 72px 0; }
.section--alt { background: var(--bg-alt); }
.center { text-align: center; }
.eyebrow {
  text-transform: uppercase; letter-spacing: .16em; font-size: .78rem;
  font-weight: 700; color: var(--accent-dark); font-family: var(--font-body);
  margin: 0 0 .8em;
}
.lead { font-size: 1.18rem; color: var(--muted); max-width: 720px; }
.center .lead { margin-left: auto; margin-right: auto; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; cursor: pointer; border: 0;
  font-family: var(--font-body); font-weight: 600; font-size: 1rem;
  padding: 14px 28px; border-radius: 50px; transition: .2s ease;
  text-align: center;
}
.btn--primary { background: var(--accent); color: #20140a; box-shadow: var(--shadow-sm); }
.btn--primary:hover { background: var(--accent-dark); color: #20140a; transform: translateY(-2px); }
.btn--ghost { background: transparent; color: var(--white); border: 1.5px solid rgba(255,255,255,.7); }
.btn--ghost:hover { background: rgba(255,255,255,.12); color: var(--white); }
.btn--dark { background: var(--brand); color: var(--white); }
.btn--dark:hover { background: var(--brand-dark); color: var(--white); transform: translateY(-2px); }
.btn--block { display: block; width: 100%; }
.btn--lg { padding: 16px 36px; font-size: 1.08rem; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.96); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: flex; align-items: center; gap: 12px; font-family: var(--font-head); font-weight: 700; font-size: 1.25rem; color: var(--brand-dark); }
.brand b { color: var(--accent-dark); }
.brand .mark {
  width: 34px; height: 34px; border-radius: 8px; background: var(--brand);
  color: #fff; display: grid; place-items: center; font-size: .95rem; font-family: var(--font-body); font-weight: 800;
}
.brand-logo { height: 46px; width: auto; display: block; }
.brand-txt { line-height: 1.05; }

/* ---------- Brokerage disclosure (eXp compliance) ---------- */
.broker-disclosure {
  border-top: 1px solid rgba(255,255,255,.15);
  margin-top: 36px; padding-top: 26px;
  display: flex; flex-wrap: wrap; align-items: center; gap: 22px;
}
.bd-logos { display: flex; align-items: center; gap: 18px; }
.bd-logos img { height: 38px; width: auto; opacity: .95; }
.bd-logos .bd-x { color: rgba(255,255,255,.55); font-size: .85rem; letter-spacing: .05em; }
.bd-text { color: rgba(255,255,255,.7); font-size: .82rem; margin: 0; max-width: 640px; line-height: 1.55; }
.bd-text strong { color: rgba(255,255,255,.9); }
@media (max-width: 600px){ .broker-disclosure { flex-direction: column; align-items: flex-start; } }
.nav-links { display: flex; align-items: center; gap: 26px; list-style: none; margin: 0; padding: 0; }
.nav-links a { color: var(--ink); font-weight: 500; font-size: .96rem; }
.nav-links a:hover { color: var(--accent-dark); }
.nav .btn { padding: 10px 20px; }
.nav-toggle { display: none; background: none; border: 0; font-size: 1.6rem; color: var(--brand-dark); cursor: pointer; }

.dropdown { position: relative; }
.dropdown > a::after { content: " \25BE"; font-size: .7em; color: var(--muted); }
.dropdown-menu {
  position: absolute; top: 130%; left: 50%; transform: translateX(-50%);
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm);
  box-shadow: var(--shadow); padding: 10px; min-width: 230px;
  display: none; grid-template-columns: 1fr; gap: 2px;
}
.dropdown:hover .dropdown-menu { display: grid; }
.dropdown-menu a { padding: 9px 14px; border-radius: 7px; font-size: .92rem; color: var(--ink); }
.dropdown-menu a:hover { background: var(--bg-tint); color: var(--brand-dark); }

/* ---------- Hero ---------- */
.hero {
  position: relative; color: #fff; text-align: center;
  background:
    linear-gradient(180deg, rgba(21,41,63,.62), rgba(21,41,63,.78)),
    var(--hero-img, linear-gradient(135deg,#243b59,#3b6098));
  background-size: cover; background-position: center;
}
.hero-inner { padding: 110px 22px 96px; max-width: 860px; margin: 0 auto; }
.hero h1 { color: #fff; }
.hero p { font-size: 1.22rem; color: rgba(255,255,255,.92); margin-bottom: 1.6em; }
.hero .btn-row { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.hero--sm .hero-inner { padding: 78px 22px 64px; }

/* Hero search bar */
.hero-search {
  margin: 26px auto 0; max-width: 620px; background: #fff; border-radius: 50px;
  box-shadow: var(--shadow); display: flex; padding: 8px; gap: 8px;
}
.hero-search input {
  flex: 1; border: 0; outline: none; padding: 12px 20px; font-size: 1rem;
  border-radius: 50px; color: var(--ink); font-family: var(--font-body);
}
.hero-search .btn { white-space: nowrap; }

/* ---------- Stat strip ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.stat { text-align: center; }
.stat .num { font-family: var(--font-head); font-size: 2.4rem; color: var(--brand); font-weight: 700; }
.stat .lbl { color: var(--muted); font-size: .92rem; text-transform: uppercase; letter-spacing: .06em; }

/* ---------- Grid cards ---------- */
.grid { display: grid; gap: 26px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow-sm); transition: .2s ease;
  display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.card .thumb { height: 180px; background: var(--brand); background-size: cover; background-position: center; position: relative; }
.card .thumb .tag {
  position: absolute; bottom: 12px; left: 12px; background: rgba(21,41,63,.85);
  color: #fff; font-size: .76rem; padding: 5px 12px; border-radius: 50px; letter-spacing: .04em;
}
.card .body { padding: 22px; flex: 1; display: flex; flex-direction: column; }
.card .body h3 { margin-bottom: .35em; }
.card .body p { color: var(--muted); font-size: .96rem; flex: 1; }
.card .body .card-link { margin-top: 10px; font-weight: 600; color: var(--accent-dark); }
.card .body .card-link::after { content: " \2192"; }

/* ---------- Feature / icon list ---------- */
.features { display: grid; grid-template-columns: repeat(3,1fr); gap: 30px; }
.feature .ic { width: 48px; height: 48px; border-radius: 12px; background: var(--bg-tint); color: var(--brand); display: grid; place-items: center; font-size: 1.4rem; margin-bottom: 14px; }
.feature h3 { font-size: 1.15rem; }
.feature p { color: var(--muted); font-size: .96rem; margin: 0; }

/* ---------- Split content ---------- */
.split { display: grid; grid-template-columns: 1.1fr 1fr; gap: 50px; align-items: center; }
.split img, .split .media { border-radius: var(--radius); box-shadow: var(--shadow); width: 100%; height: 100%; min-height: 320px; object-fit: cover; background: var(--bg-tint); }

/* ---------- Prose ---------- */
.prose { max-width: 760px; }
.prose h2 { margin-top: 1.4em; }
.prose h3 { margin-top: 1.3em; color: var(--brand); }
.prose ul { padding-left: 1.2em; }
.prose li { margin-bottom: .5em; }
.callout {
  background: var(--bg-tint); border-left: 4px solid var(--accent);
  padding: 18px 22px; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; margin: 1.5em 0;
}

/* ---------- FAQ ---------- */
.faq details { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 4px 20px; margin-bottom: 12px; background: #fff; }
.faq summary { cursor: pointer; font-weight: 600; padding: 14px 0; color: var(--brand-dark); list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; float: right; color: var(--accent-dark); font-size: 1.3rem; line-height: 1; }
.faq details[open] summary::after { content: "\2013"; }
.faq details p { color: var(--muted); margin: 0 0 14px; }

/* ---------- CTA band ---------- */
.cta-band { background: var(--brand-dark); color: #fff; text-align: center; }
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,.85); max-width: 620px; margin: 0 auto 1.6em; }

/* ---------- Lead form ---------- */
.lead-form { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 30px; }
.lead-form h3 { margin-bottom: .2em; }
.lead-form .sub { color: var(--muted); margin-bottom: 18px; font-size: .96rem; }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: .85rem; font-weight: 600; color: var(--ink); margin-bottom: 5px; }
.field input, .field select, .field textarea {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm);
  font-family: var(--font-body); font-size: .98rem; color: var(--ink); background: #fff;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); }
.form-note { font-size: .8rem; color: var(--muted); margin-top: 10px; }

/* ---------- Breadcrumbs ---------- */
.crumbs { font-size: .85rem; color: var(--muted); padding: 16px 0 0; }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--accent-dark); }

/* ---------- Footer ---------- */
.site-footer { background: var(--brand-dark); color: rgba(255,255,255,.8); padding: 56px 0 26px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; }
.site-footer h4 { color: #fff; font-family: var(--font-body); font-size: .95rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 16px; }
.site-footer a { color: rgba(255,255,255,.8); font-size: .94rem; }
.site-footer a:hover { color: var(--accent); }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 9px; }
.footer-brand p { font-size: .94rem; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.15); margin-top: 40px; padding-top: 22px; font-size: .82rem; color: rgba(255,255,255,.6); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; }
.footer-bottom a { color: rgba(255,255,255,.7); }

/* ---------- Utilities ---------- */
.mt-0 { margin-top: 0; } .mb-0 { margin-bottom: 0; }
.tag-pill { display: inline-block; background: var(--bg-tint); color: var(--brand); font-size: .8rem; padding: 5px 12px; border-radius: 50px; margin: 0 6px 8px 0; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .grid-3, .grid-4, .features, .stats { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .nav-links {
    position: absolute; top: 72px; left: 0; right: 0; background: #fff;
    flex-direction: column; align-items: flex-start; gap: 0; padding: 10px 22px 20px;
    border-bottom: 1px solid var(--line); box-shadow: var(--shadow); display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links li { width: 100%; padding: 8px 0; border-bottom: 1px solid var(--line); }
  .dropdown-menu { position: static; transform: none; display: grid; box-shadow: none; border: 0; padding: 6px 0 6px 14px; min-width: 0; }
  .nav-toggle { display: block; }
}
@media (max-width: 560px) {
  .grid-3, .grid-4, .features, .stats, .grid-2 { grid-template-columns: 1fr; }
  .hero-search { flex-direction: column; border-radius: var(--radius); }
  .hero-search .btn { border-radius: var(--radius-sm); }
  .footer-grid { grid-template-columns: 1fr; }
}

/* ===================================================================
   Town → neighborhood structure
   =================================================================== */
.town-list { display: flex; flex-direction: column; gap: 16px; }
.town-block { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); }
.town-head { display: flex; justify-content: space-between; align-items: center; gap: 14px; background: var(--brand-dark); padding: 16px 22px; }
.town-head .town-name { display: flex; align-items: center; gap: 8px; }
.town-head h3 { color: #fff; margin: 0; font-size: 1.35rem; }
.town-head .town-sub { color: #cfe0f0; font-size: .9rem; margin: 2px 0 0; }
.town-head .pin { color: var(--accent); }
.town-head .btn { white-space: nowrap; padding: 9px 18px; }
.nbhd-row { display: flex; flex-wrap: wrap; gap: 10px; padding: 18px 22px; align-items: center; }
.nbhd-pill { font-size: .95rem; color: var(--brand-dark); background: var(--bg-tint); padding: 8px 16px; border-radius: 50px; transition: .15s ease; }
.nbhd-pill:hover { background: var(--accent); color: #20140a; }
.nbhd-row .soon { color: var(--muted); font-size: .9rem; font-style: italic; }

/* Neighborhoods-in-town section (on town hub pages) */
.nbhd-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.nbhd-card { display: block; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow-sm); transition: .2s ease; }
.nbhd-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.nbhd-card h3 { margin: 0 0 .3em; font-size: 1.12rem; }
.nbhd-card p { color: var(--muted); font-size: .92rem; margin: 0; }
.nbhd-card .builder { display: inline-block; margin-top: 12px; font-size: .76rem; color: var(--accent-dark); text-transform: uppercase; letter-spacing: .05em; font-weight: 600; }
.nbhd-card .builder::after { content: " →"; }

/* Builder callout on neighborhood pages */
.builder-box { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; background: var(--bg-tint); border-radius: var(--radius-sm); padding: 16px 20px; margin: 1.6em 0; }
.builder-box .bb-label { font-size: .76rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); width: 100%; }
.builder-box a { font-weight: 600; }
.builder-box .sep { color: var(--line); }

@media (max-width: 900px) { .nbhd-cards { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) {
  .nbhd-cards { grid-template-columns: 1fr; }
  .town-head { flex-direction: column; align-items: flex-start; }
}
