/* bclanded.ca — Phase 0 foundation styles
   Brand: deep navy (#1b2a4a), burgundy/maroon (#7a1f2b), white (#ffffff).
   NO black anywhere (per brand rules). Text uses dark navy instead of #000. */

:root {
  --navy: #1b2a4a;
  --navy-dark: #12203a;
  --navy-light: #2c4066;
  --burgundy: #7a1f2b;
  --burgundy-dark: #5e1620;
  --burgundy-light: #9a2d3a;
  --white: #ffffff;
  --off-white: #f6f5f2;
  --grey: #5c6470;
  --grey-light: #e5e3de;
  --text: #232a35;
  --radius: 10px;
  --shadow: 0 2px 12px rgba(27, 42, 74, 0.10);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.6;
}
a { color: var(--burgundy); }
a:hover { color: var(--burgundy-dark); }

.container { max-width: 1140px; margin: 0 auto; padding: 0 1.25rem; }
.container.narrow { max-width: 720px; }
.skip-link { position: absolute; left: -9999px; }
.skip-link:focus { position: static; display: block; padding: .5rem; background: var(--navy); color: var(--white); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
.hidden { display: none; }

/* Header */
.site-header { background: var(--navy); color: var(--white); }
.header-inner { display: flex; align-items: center; gap: 1.5rem; padding: 1rem 1.25rem; flex-wrap: wrap; }
.logo { font-size: 1.6rem; font-weight: 800; letter-spacing: -0.02em; color: var(--white); text-decoration: none; }
.logo span { color: #d8a7ae; }
.main-nav { display: flex; gap: 1.25rem; margin-left: auto; flex-wrap: wrap; }
.main-nav a { color: var(--white); text-decoration: none; font-weight: 600; }
.main-nav a:hover { text-decoration: underline; }
.header-phone { color: var(--white); font-weight: 700; text-decoration: none; border: 1px solid rgba(255,255,255,.5); padding: .35rem .8rem; border-radius: 999px; }

/* Hero */
.hero { background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 60%, var(--burgundy) 130%); color: var(--white); padding: 3.5rem 0; }
.hero h1 { font-size: clamp(1.9rem, 4vw, 3rem); margin: 0 0 .75rem; line-height: 1.15; }
.hero-sub { font-size: 1.15rem; max-width: 640px; opacity: .95; }
.hero-note { font-size: .9rem; opacity: .8; }
.search-bar { display: flex; gap: .5rem; max-width: 640px; margin: 1.5rem 0 1rem; }
.search-bar input { flex: 1; padding: .8rem 1rem; border: none; border-radius: var(--radius); font-size: 1rem; }
.search-bar button { background: var(--burgundy); color: var(--white); border: none; padding: .8rem 1.5rem; border-radius: var(--radius); font-weight: 700; cursor: pointer; font-size: 1rem; }
.search-bar button:hover { background: var(--burgundy-dark); }

/* Sections */
.section { padding: 3rem 0; }
.section-alt { background: var(--off-white); }
.section h2 { font-size: 1.6rem; color: var(--navy); margin-top: 0; }

/* Cards */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1.25rem; }
.card { border: 1px solid var(--grey-light); border-radius: var(--radius); padding: 1.25rem; box-shadow: var(--shadow); background: var(--white); }
.card h2, .card h3 { margin: 0 0 .25rem; font-size: 1.17rem; }
.card h2 a, .card h3 a { color: var(--navy); text-decoration: none; }
.card-price { font-weight: 800; color: var(--burgundy); font-size: 1.1rem; margin: .5rem 0 0; }
.card-meta { color: var(--grey); font-size: .9rem; margin: .25rem 0 0; }
.empty-state { background: var(--off-white); border: 1px dashed var(--grey-light); border-radius: var(--radius); padding: 1.5rem; }

/* Lists */
.city-list { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: .6rem; }
.city-list a { display: inline-block; background: var(--white); border: 1px solid var(--grey-light); border-radius: 999px; padding: .4rem 1rem; text-decoration: none; color: var(--navy); font-weight: 600; }
.city-list a:hover { border-color: var(--burgundy); color: var(--burgundy); }

/* Forms */
form label { display: block; margin-bottom: .9rem; font-weight: 600; }
form input, form textarea, form select { display: block; width: 100%; margin-top: .3rem; padding: .65rem .8rem; border: 1px solid var(--grey-light); border-radius: var(--radius); font-size: 1rem; font-family: inherit; }
form button[type="submit"] { background: var(--burgundy); color: var(--white); border: none; padding: .8rem 1.6rem; border-radius: var(--radius); font-weight: 700; cursor: pointer; font-size: 1rem; }
form button[type="submit"]:hover { background: var(--burgundy-dark); }
.form-note { font-size: .85rem; color: var(--grey); }

/* Community detail (Phase 1 template) */
.community-header { background: var(--off-white); padding: 2rem 0; }
.community-header h1 { color: var(--navy); margin: 0 0 .25rem; }
.price-range { font-size: 1.4rem; font-weight: 800; color: var(--burgundy); margin: .5rem 0; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 1rem; margin: 1.5rem 0; }
.stat { background: var(--white); border: 1px solid var(--grey-light); border-radius: var(--radius); padding: .9rem; }
.stat dt { font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; color: var(--grey); }
.stat dd { margin: .2rem 0 0; font-weight: 700; color: var(--navy); }
.details-table { width: 100%; border-collapse: collapse; margin: 1rem 0; }
.details-table th, .details-table td { text-align: left; padding: .6rem .8rem; border-bottom: 1px solid var(--grey-light); }
.details-table th { width: 32%; color: var(--navy); }
.plans-table { width: 100%; border-collapse: collapse; margin: 1rem 0; font-size: .95rem; }
.plans-table th, .plans-table td { text-align: left; padding: .6rem; border-bottom: 1px solid var(--grey-light); }
.plans-table th { background: var(--navy); color: var(--white); }
.last-updated { font-size: .85rem; color: var(--grey); }
.badge { display: inline-block; background: var(--burgundy); color: var(--white); font-size: .75rem; font-weight: 700; padding: .2rem .6rem; border-radius: 999px; text-transform: uppercase; letter-spacing: .04em; }

/* Filters (Phase 2 — /communities/) */
.filters { background: var(--off-white); border: 1px solid var(--grey-light); border-radius: var(--radius); padding: 1.25rem; margin: 1.5rem 0 1rem; }
.filter-row { display: flex; flex-wrap: wrap; gap: 1rem; margin-bottom: .9rem; }
.filter-row:last-child { margin-bottom: 0; }
.filter-group { flex: 1 1 180px; }
.filter-group label, .filter-group legend { display: block; font-weight: 700; font-size: .9rem; color: var(--navy); margin-bottom: .3rem; }
.filter-group input[type="search"], .filter-group select { width: 100%; padding: .6rem .75rem; border: 1px solid var(--grey-light); border-radius: var(--radius); font-size: 1rem; font-family: inherit; background: var(--white); }
.filter-search { flex: 2 1 260px; }
.filter-types { border: none; padding: 0; margin: 0; }
.filter-types .checkbox-label { display: inline-flex; align-items: center; gap: .4rem; font-weight: 600; margin-right: 1rem; margin-bottom: 0; }
.filter-types input[type="checkbox"] { width: auto; }
.filter-actions { display: flex; align-items: flex-end; flex: 0 0 auto; }
.btn-secondary { background: var(--white); color: var(--navy); border: 1px solid var(--grey-light); padding: .6rem 1.1rem; border-radius: var(--radius); font-weight: 700; cursor: pointer; font-size: .95rem; }
.btn-secondary:hover { border-color: var(--burgundy); color: var(--burgundy); }
.filter-note { font-size: .85rem; color: var(--grey); margin: .9rem 0 0; }

/* Footer */
.site-footer { background: var(--navy); color: var(--white); padding: 2.5rem 0 1.5rem; margin-top: 2rem; }
.site-footer a { color: #e8cdd1; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 2rem; }
.footer-grid h3, .footer-grid .footer-heading { margin-top: 0; font-size: 1rem; }
.footer-grid .footer-heading { font-weight: 700; margin-bottom: 1rem; }
.footer-grid ul { list-style: none; padding: 0; }
.footer-grid li { margin-bottom: .4rem; }
.footer-brand { font-size: 1.5rem; font-weight: 800; margin: 0 0 .5rem; }
.footer-brand span { color: #d8a7ae; }
.footer-disclaimer { font-size: .8rem; opacity: .75; border-top: 1px solid rgba(255,255,255,.25); padding-top: 1rem; margin-top: 2rem; }
.footer-copy { font-size: .8rem; opacity: .75; }

@media (max-width: 640px) {
  .header-inner { gap: .75rem; }
  .main-nav { margin-left: 0; }
  .search-bar { flex-direction: column; }
  .details-table th { width: 42%; }
}

/* Presale map (/map/) */
#community-map { height: 560px; border-radius: var(--radius); box-shadow: var(--shadow); margin: 1.25rem 0 0.75rem; background: var(--off-white); }
.map-legend { color: var(--grey); font-size: 0.9rem; margin: 0 0 2rem; }
.legend-dot { display: inline-block; width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--white); vertical-align: -1px; }
.legend-project { background: var(--navy); }
.legend-sales { background: var(--burgundy); }
.legend-approx { background: var(--burgundy-light); }
.unmapped-list { line-height: 1.9; }
.leaflet-popup-content hr { border: none; border-top: 1px solid var(--grey-light); margin: 0.5rem 0; }
@media (max-width: 640px) { #community-map { height: 420px; } }
