@import url("https://fonts.googleapis.com/css2?family=Barlow+Condensed:wght@600;700&family=Hanken+Grotesk:wght@400;500;600;700;800&display=swap");
:root {
  /* neem green brand; plot states from the land: sprout, turmeric, laterite; chalk-white surfaces */
  --ink: #18231d; --muted: #5f6b64; --faint: #98a29c; --line: #dfe4e0; --bg: #eef1ee; --card: #fff; --soft: #eef2ef;
  --brand: #1d4a36; --brand-2: #2a6249; --brand-ink: #fff;
  --avail: #2f9e5b; --hold: #e0a526; --sold: #b4482d;
  --num: "Barlow Condensed", "Arial Narrow", sans-serif;
  --r: 14px; --r-sm: 10px; --shadow: 0 1px 2px rgba(16,24,20,.06), 0 8px 24px rgba(16,24,20,.10);
  font-family: "Hanken Grotesk", system-ui, sans-serif; color: var(--ink); -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); }
h1, h2, h3 { margin: 0; letter-spacing: -.02em; font-weight: 800; }
h1 { font-size: 26px; } h2 { font-size: 20px; } h3 { font-size: 16px; }
a { color: var(--brand-2); }
button, input, select, textarea { font: inherit; color: inherit; }
svg.i { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.btn { border: 1px solid var(--line); background: var(--card); color: var(--ink); padding: 10px 14px; border-radius: var(--r-sm); cursor: pointer; font-weight: 700; font-size: 14px; text-decoration: none; white-space: nowrap; display: inline-flex; align-items: center; gap: 8px; justify-content: center; transition: transform .08s, background .15s; }
.btn:hover { background: var(--soft); }
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); box-shadow: 0 4px 14px rgba(19,57,44,.25); }
.btn.primary:hover { background: var(--brand-2); }
.btn.wa { background: #1faa59; color: #fff; border-color: #1faa59; }
.btn.block { width: 100%; }
.btn.big { padding: 14px 18px; font-size: 15px; }
.btn.round { width: 42px; height: 42px; padding: 0; border-radius: 50%; }
.btn.ghost { border-color: transparent; background: transparent; }
.btn:disabled { opacity: .5; cursor: default; }

.chip { display: inline-flex; align-items: center; gap: 7px; padding: 7px 12px; border-radius: 99px; border: 1px solid var(--line); background: var(--card); font-size: 13px; font-weight: 700; cursor: pointer; white-space: nowrap; }
.chip b { color: var(--muted); font-weight: 700; }
.chip.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.chip.on b { color: rgba(255,255,255,.7); }
.dot { width: 9px; height: 9px; border-radius: 3px; display: inline-block; background: var(--c); }
.available { --c: var(--avail); } .hold { --c: var(--hold); } .sold { --c: var(--sold); }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 99px; font-size: 12px; font-weight: 800; color: #fff; background: var(--c); }
.tag { font-size: 12px; font-weight: 700; color: var(--c); text-transform: capitalize; }
.eyebrow { font-size: 13px; font-weight: 600; color: var(--muted); }
/* the one loud element: plot numbers, set like the painted numbers on boundary pegs */
.num, .stat b, .pl b, .cell, .phead .big, .headline big, .item .no { font-family: var(--num); font-weight: 700; letter-spacing: 0; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; }
.muted { color: var(--muted); }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.between { justify-content: space-between; }
.kv { display: grid; grid-template-columns: 1fr auto; gap: 8px 12px; font-size: 14px; }
.kv > :nth-child(odd) { color: var(--muted); }
.kv > :nth-child(even) { text-align: right; font-weight: 700; }
label { display: grid; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); }
input, select, textarea { padding: 11px 12px; border: 1px solid var(--line); border-radius: var(--r-sm); color: var(--ink); background: #fff; width: 100%; outline: none; transition: border-color .15s, box-shadow .15s; }
input:focus, select:focus, textarea:focus { border-color: var(--brand-2); box-shadow: 0 0 0 3px rgba(31,90,69,.15); }
input[type="checkbox"], input[type="range"] { width: auto; box-shadow: none; }
.check { display: flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 600; }
.err { color: var(--sold); min-height: 1.2em; font-size: 14px; font-weight: 600; }
.toast { position: fixed; left: 50%; bottom: 90px; transform: translate(-50%, 20px); background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 99px; font-weight: 700; font-size: 14px; opacity: 0; transition: .2s; pointer-events: none; z-index: 3000; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.stat { border-top: 2px solid var(--ink); padding: 8px 2px 4px; }
.stat b { display: block; font-size: 28px; line-height: 1.05; }
.stat span { font-size: 12px; color: var(--muted); font-weight: 600; }
.bar { display: flex; height: 8px; border-radius: 99px; overflow: hidden; background: var(--line); gap: 2px; }
.bar i { background: var(--c); }

/* map */
.leaflet-container { font-family: inherit; background: #dfe5df; }
.leaflet-tooltip.plot-label { background: none; border: 0; box-shadow: none; padding: 0; color: #fff; text-align: center; line-height: 1.1; text-shadow: 0 1px 2px rgba(0,0,0,.6); }
.leaflet-tooltip.plot-label b { font: 700 16px/1 var(--num); display: block; }
.leaflet-tooltip.plot-label small { font-size: 10px; font-weight: 700; opacity: .9; display: none; }
.near .leaflet-tooltip.plot-label small { display: block; }
.leaflet-tooltip.plot-label::before { display: none; }
.hide-labels .plot-label, .hide-labels .site-label { display: none; }
.site-label span { display: inline-block; transform: translate(-50%, -50%) rotate(var(--a, 0deg)); white-space: nowrap; color: #fff; font: 600 13px var(--num); letter-spacing: .08em; text-shadow: 0 1px 2px rgba(0,0,0,.6); pointer-events: none; }
.edge-label span { display: inline-block; transform: translate(-50%, -50%); white-space: nowrap; background: #fff; color: var(--ink); font-size: 11px; font-weight: 800; padding: 2px 6px; border-radius: 6px; box-shadow: 0 1px 4px rgba(0,0,0,.3); }
path.s-available { fill: url(#pAvail); }
path.s-hold { fill: url(#pHold); }
path.s-sold { fill: url(#pSold); }
path.lawn { fill: url(#pLawn); }
path.tree { fill: url(#gTree); filter: drop-shadow(0 1px 1.5px rgba(0,0,0,.45)); }
.hide-labels path.tree { display: none; }
.handle { box-sizing: border-box; border-radius: 50%; background: #fff; border: 3px solid var(--brand); box-shadow: 0 1px 4px rgba(0,0,0,.4); }
.handle.move { background: var(--brand); border-color: #fff; }

.glass { background: rgba(255,255,255,.88); backdrop-filter: blur(14px) saturate(1.4); -webkit-backdrop-filter: blur(14px) saturate(1.4); border: 1px solid rgba(255,255,255,.7); box-shadow: var(--shadow); }
.sheet { position: fixed; left: 0; right: 0; bottom: 0; max-width: 520px; margin: 0 auto; background: var(--card); border-radius: 22px 22px 0 0; box-shadow: 0 -10px 40px rgba(0,0,0,.2); padding: 10px 18px 22px; transform: translateY(110%); transition: transform .25s cubic-bezier(.2,.8,.2,1); z-index: 1000; max-height: 88vh; overflow: auto; }
.sheet.open { transform: none; }
.scrim { position: fixed; inset: 0; background: rgba(10,20,15,.35); z-index: 999; opacity: 0; pointer-events: none; transition: opacity .2s; }
.scrim.open { opacity: 1; pointer-events: auto; }
.grab { width: 40px; height: 5px; border-radius: 99px; background: var(--line); margin: 4px auto 12px; }
svg.shape { width: 100%; max-width: 260px; display: block; margin: 0 auto; }
svg.shape path { fill: #e8f1ec; stroke: var(--brand); stroke-width: 2.5; stroke-linejoin: round; }
svg.shape text { font-size: 11px; font-weight: 800; fill: var(--ink); text-anchor: middle; dominant-baseline: central; }

@media print { .noprint { display: none !important; } body { background: #fff; } }

/* map view modes: satellite (default), plan (survey sheet, no photo), 3D (tilted) */
.mode-plan .leaflet-tile-pane { display: none; }
.mode-plan.leaflet-container { background-color: #f3f5f1; background-image: linear-gradient(#dfe6df 1px, transparent 1px), linear-gradient(90deg, #dfe6df 1px, transparent 1px); background-size: 32px 32px; }
.mode-plan .site-label span { color: var(--ink); text-shadow: 0 0 3px #fff, 0 0 2px #fff; }
.mapwrap { position: relative; overflow: hidden; perspective: 1500px; }
.mapwrap > .leaflet-container { transition: transform .6s cubic-bezier(.2,.8,.2,1); transform-origin: 50% 70%; }
.mapwrap.tilt > .leaflet-container { transform: rotateX(42deg) scale(1.7); transform-origin: 50% 85%; }
.tilt path.s-available, .tilt path.s-hold, .tilt path.s-sold { filter: drop-shadow(0 6px 3px rgba(0,0,0,.45)); }
.tilt path.tree { filter: drop-shadow(0 8px 4px rgba(0,0,0,.5)); }
.modes { display: inline-grid; grid-auto-flow: column; padding: 4px; gap: 2px; border-radius: 12px; }
.modes button { border: 0; background: none; padding: 8px 12px; border-radius: 9px; font-weight: 700; font-size: 13px; cursor: pointer; color: var(--ink); }
.modes button[aria-pressed="true"] { background: var(--brand); color: #fff; }
:focus-visible { outline: 3px solid var(--hold); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
svg.i { width: auto; height: auto; flex: none; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; vertical-align: -3px; }
svg.i.solid { fill: currentColor; stroke: none; }
.ctl { display: grid; border-radius: 14px; overflow: hidden; }
.ctl button { width: 44px; height: 44px; border: 0; background: none; display: grid; place-items: center; cursor: pointer; color: var(--ink); }
.ctl button:hover { background: rgba(0,0,0,.05); }
.ctl button + button { border-top: 1px solid var(--line); }
.err:empty { min-height: 0; }
.pw { position: relative; }
.pw input { padding-right: 46px; }
.pw button { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); border: 0; background: none; width: 36px; height: 36px; display: grid; place-items: center; color: var(--muted); cursor: pointer; border-radius: 8px; }
.mode-plan .leaflet-tooltip.plot-label { color: var(--ink); text-shadow: 0 0 3px #fff, 0 0 2px #fff; }
/* road names sit on an asphalt patch, so the dashed centre line stops under the text */
.site-label.road span { background: #34383d; padding: 1px 7px; border-radius: 3px; text-shadow: none; }
.mode-plan .site-label.road span { color: #fff; text-shadow: none; }
