/**
 * NANDA VENTURES — satellite plot availability page
 * Styling for the imported folder-based plot viewer. The main design system
 * stays in assets/css/style.css; this file only styles the map workspace.
 */

body.satellite-page { background: var(--cream); }
body.satellite-page .site-header { background: var(--green-950); border-bottom-color: rgba(244,214,120,.2); }

.satellite-main { padding: calc(var(--header-h) + 46px) 0 92px; }
.satellite-intro { max-width: 780px; margin-bottom: 26px; }
.satellite-intro .kicker { margin-bottom: 12px; }
.satellite-intro h1 { font-family: var(--font-display); font-size: clamp(2.2rem, 4vw, 3.5rem); line-height: 1.08; color: var(--green-900); margin: 0 0 14px; }
.satellite-intro h1 em { font-style: italic; color: var(--green-600); }
.satellite-intro p { color: var(--muted); font-size: 15px; line-height: 1.7; }
.satellite-intro__badges { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 18px; }

/* Blinking NEW label — reused in navigation and layout tabs */
.nav-new, .layout-tab, .satellite-link { position: relative; }
.nav-new__badge, .nv-new-badge {
  display: inline-block;
  color: #10271c;
  background: var(--gold);
  border: 1px solid var(--gold-soft);
  border-radius: 999px;
  font: 800 9px/1 var(--font-body, 'Manrope', sans-serif);
  letter-spacing: .08em;
  padding: 4px 7px 3px;
  margin-left: 7px;
  vertical-align: 1px;
  animation: nvNewPulse 1.15s steps(2, end) infinite;
}
.main-nav .nav-new__badge { font-size: 9px; padding: 4px 7px 3px; }
.mobile-nav .nav-new__badge { margin-left: auto; }
@keyframes nvNewPulse { 0%, 49% { opacity: 1; box-shadow: 0 0 0 0 rgba(217,168,47,.65); } 50%, 100% { opacity: .32; box-shadow: 0 0 0 5px rgba(217,168,47,0); } }

.satellite-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 0 0 18px; }
.summary-card { display: flex; align-items: center; gap: 14px; background: var(--white); border: 1px solid var(--line); padding: 15px 18px; box-shadow: var(--shadow-sm, 0 10px 30px rgba(8,53,37,.1)); }
.summary-card i { width: 42px; height: 42px; flex: none; display: grid; place-items: center; border-radius: 50%; background: rgba(32,180,111,.14); color: var(--green-700); font-style: normal; }
.summary-card.is-ok i { background: rgba(32,180,111,.18); color: #128a55; }
.summary-card.is-sold i { background: rgba(223,84,72,.16); color: var(--status-sold); }
.summary-card .ic { width: 20px; height: 20px; }
.summary-card span { display: block; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.summary-card strong { display: block; font-family: var(--font-display); font-size: 28px; line-height: 1.1; color: var(--green-900); margin-top: 4px; font-variant-numeric: tabular-nums; }

.layout-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; }
.layout-tab {
  appearance: none; border: 1px solid var(--line); background: var(--white); color: var(--green-900);
  font: 700 12.5px/1 var(--font-body, 'Manrope', sans-serif); letter-spacing: .02em;
  padding: 11px 15px; cursor: pointer; display: inline-flex; align-items: center; gap: 7px;
  transition: background-color .25s var(--ease), border-color .25s var(--ease), color .25s var(--ease), transform .25s var(--ease);
}
.layout-tab:hover { border-color: var(--gold); transform: translateY(-2px); }
.layout-tab.is-active, .layout-tab.active { background: var(--green-900); border-color: var(--green-900); color: #fff; }
.layout-tab .ic { width: 16px; height: 16px; color: var(--gold); }
.layout-tab small { font-size: 10.5px; opacity: .68; margin-left: 2px; }
.layout-tab .nv-new-badge { margin-left: 0; }

.satellite-toolbar {
  display: flex; align-items: center; flex-wrap: wrap; gap: 12px;
  background: var(--white); border: 1px solid var(--line); padding: 13px 16px; margin-bottom: 14px;
}
.satellite-toolbar label { font-size: 12px; font-weight: 700; color: var(--green-800); }
.search-box { position: relative; display: inline-flex; align-items: center; }
.search-box .ic { position: absolute; left: 11px; width: 16px; height: 16px; color: var(--muted); pointer-events: none; }
.satellite-toolbar input, .satellite-toolbar select {
  height: 42px; border: 1px solid var(--line); background: var(--white); color: var(--green-900);
  font: inherit; padding: 0 12px;
}
.satellite-toolbar input { width: 190px; padding-left: 36px; }
.satellite-toolbar input:focus, .satellite-toolbar select:focus { outline: 2px solid var(--gold); outline-offset: 1px; }
.plot-legend { display: flex; flex-wrap: wrap; gap: 6px; margin-left: auto; align-items: center; }
.plot-legend button {
  appearance: none; border: 1px solid transparent; border-radius: 999px; background: transparent;
  color: var(--muted); font: 600 11px/1 var(--font-body, 'Manrope', sans-serif);
  padding: 7px 9px; display: inline-flex; align-items: center; gap: 6px; cursor: pointer;
}
.plot-legend button:hover, .plot-legend button.on { border-color: var(--gold); color: var(--green-900); background: rgba(217,168,47,.12); }
.legend-dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.legend-dot.available { background: var(--status-available); }
.legend-dot.sold { background: var(--status-sold); }
.legend-dot.booked { background: var(--status-booked); }
.legend-dot.hold { background: var(--status-hold); }
.legend-dot.reserved { background: var(--status-reserved); }
.legend-dot.unavailable { background: var(--status-unavailable); }
.legend-note { font-size: 11px; color: var(--muted); font-weight: 700; }

.plot-workspace { display: grid; grid-template-columns: minmax(0, 1fr) 370px; gap: 16px; align-items: stretch; }
.map-wrap { position: relative; min-height: 620px; background: #0b1a12; border: 1px solid var(--line); overflow: hidden; box-shadow: 0 18px 40px -26px rgba(8,53,37,.7); }
#plotMap { position: absolute; inset: 0; }
.map-message {
  position: absolute; z-index: 6; inset: auto 16px 16px 16px; padding: 11px 14px;
  background: rgba(6,21,14,.9); color: #f4ead1; border: 1px solid rgba(217,168,47,.5);
  font-size: 12px; letter-spacing: .02em;
}
.map-message.hidden { display: none; }
.map-hint {
  position: absolute; z-index: 5; left: 12px; bottom: 48px; background: rgba(6,21,14,.86);
  color: #f6efd9; font: 600 11px var(--font-body, 'Manrope', sans-serif); padding: 7px 11px;
  border-radius: 999px; pointer-events: none; border: 1px solid rgba(217,168,47,.45);
}
.maplibregl-ctrl-attrib { font-size: 10px; }
.maplibregl-ctrl-group { background: rgba(255,255,255,.92); }
.title-layer { position: absolute; inset: 0; z-index: 1; pointer-events: none; overflow: hidden; }
.lt-pill {
  position: absolute; left: 0; top: 0; font: 700 10.5px/1 var(--font-body, 'Manrope', sans-serif);
  letter-spacing: .09em; padding: 5px 10px; border-radius: 999px; background: var(--gold);
  color: var(--green-950); white-space: nowrap; box-shadow: 0 3px 10px rgba(0,0,0,.35);
  border: 1px solid var(--gold-soft); will-change: transform; transition: transform .12s linear;
}

/* Map labels */
.plot-tag, .edge-tag, .road-tag { pointer-events: none; display: none; width: 0; height: 0; overflow: visible; }
.plot-tag.on, .edge-tag.on, .road-tag.on { display: block; }
.plot-tag .pt-in { display: flex; flex-direction: column; align-items: center; text-align: center; transform: translate(-50%,-50%); white-space: nowrap; width: max-content; line-height: 1.15; color: #fff; text-shadow: 0 1px 3px #000c, 0 0 6px #000a; font-family: var(--font-body, 'Manrope', sans-serif); }
.plot-tag b { font-weight: 800; letter-spacing: .05em; font-size: var(--fs, 9px); padding: .18em .55em; border-radius: 5px; background: rgba(6,21,14,.9); border: 1px solid var(--c, var(--gold)); }
.plot-tag span { display: none; font-size: calc(var(--fs, 9px) * .86); margin-top: 3px; color: #f6efd9; font-weight: 700; }
.plot-tag.sa .pt-area, .plot-tag.sa .pt-dim { display: block; }
.plot-tag.sel b { background: var(--gold); color: var(--green-950); text-shadow: none; }
.plot-tag.cp b em { display: none; }
.edge-tag i { display: block; font-style: normal; transform: translate(-50%,-50%) rotate(var(--a,0deg)) translateY(var(--o,0px)); white-space: nowrap; font: 700 calc(var(--es, 9px) * .82)/1 var(--font-body, 'Manrope', sans-serif); color: #fff; background: rgba(6,21,14,.86); border: 1px solid rgba(217,168,47,.65); padding: .12em .35em; border-radius: 4px; box-shadow: 0 1px 4px #0008; }
.rd-in { transform: translate(-50%,-50%); width: max-content; font: 800 11px var(--font-display, Georgia, serif); letter-spacing: .28em; color: #fff; background: rgba(43,49,53,.9); border: 1px solid rgba(255,255,255,.4); padding: 3px 9px 3px 13px; border-radius: 4px; white-space: nowrap; text-shadow: 0 1px 2px #000; }

/* Plot detail panel */
.plot-detail { background: var(--white); border: 1px solid var(--line); padding: 26px; min-height: 620px; }
.detail-empty { min-height: 520px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; color: var(--muted); }
.detail-icon { width: 72px; height: 72px; border-radius: 50%; display: grid; place-items: center; background: rgba(32,180,111,.14); animation: detailPulse 2.8s ease-in-out infinite; }
.detail-icon .ic { width: 32px; height: 32px; color: var(--green-600); }
@keyframes detailPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(32,180,111,.3); } 50% { box-shadow: 0 0 0 14px rgba(32,180,111,0); } }
.detail-empty h2 { font-family: var(--font-display); font-size: 24px; color: var(--green-900); margin: 18px 0 6px; }
.detail-empty p { font-size: 13px; line-height: 1.6; max-width: 250px; }
.detail-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.detail-kicker { font-size: 10px; font-weight: 800; letter-spacing: .14em; color: var(--muted); }
.status-pill { font-size: 10px; font-weight: 800; letter-spacing: .1em; padding: 6px 10px; border-radius: 999px; }
.status-pill.available { background: rgba(32,180,111,.16); color: #0e7347; }
.status-pill.sold { background: rgba(223,84,72,.15); color: #a12f26; }
.status-pill.booked { background: rgba(155,93,229,.16); color: #7431b5; }
.status-pill.hold { background: rgba(245,158,11,.18); color: #9a5c00; }
.status-pill.reserved { background: rgba(227,178,58,.22); color: #7d5a06; }
.status-pill.unavailable { background: rgba(132,149,140,.2); color: #4d5f56; }
.detail-number { font-family: var(--font-display); font-size: 34px; color: var(--green-900); margin: 0 0 4px; }
.detail-area { font-family: var(--font-display); font-size: 27px; color: var(--green-700); }
.detail-area span { font-family: var(--font-body, 'Manrope', sans-serif); font-size: 13px !important; }
.detail-sub { font-size: 12px; color: var(--muted); margin-top: 3px; }
.detail-section { border-top: 1px solid var(--line); margin-top: 22px; padding-top: 18px; }
.detail-section h3 { font-family: var(--font-display); font-size: 18px; color: var(--green-900); margin: 0 0 12px; }
.measure-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
.measure { background: var(--cream); border: 1px solid var(--line); padding: 11px 12px; }
.measure span { display: block; font-size: 9px; font-weight: 800; letter-spacing: .14em; color: var(--muted); }
.measure strong { display: inline-block; font-family: var(--font-display); font-size: 18px; color: var(--green-900); margin-top: 3px; }
.measure small { font-size: 11px; color: var(--muted); }
.detail-note { font-size: 10.5px; color: var(--muted); margin: 9px 0 0; }
.boundary-list { display: grid; gap: 0; }
.boundary-item { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 12px; }
.boundary-item span { color: var(--muted); }
.boundary-item b { color: var(--green-900); text-align: right; }
.detail-remarks { font-size: 12px; color: var(--muted); line-height: 1.6; margin-top: 12px; }
.detail-enquire {
  width: 100%; margin-top: 22px; border: 1px solid var(--green-800); background: var(--green-900);
  color: #fff; padding: 13px 16px; font: 700 12px var(--font-body, 'Manrope', sans-serif);
  display: flex; align-items: center; justify-content: center; gap: 9px; cursor: pointer;
  transition: transform .25s var(--ease), background-color .25s var(--ease);
}
.detail-enquire:hover { transform: translateY(-2px); background: var(--green-800); }
.detail-enquire .ic { width: 17px; height: 17px; color: var(--gold-soft); }

.satellite-disclaimer { margin: 16px 0 0; font-size: 11.5px; line-height: 1.65; color: var(--muted); max-width: 900px; }

@media (max-width: 1080px) {
  .plot-workspace { grid-template-columns: 1fr; }
  .map-wrap { min-height: 480px; }
  .plot-detail { min-height: 0; }
  .detail-empty { min-height: 260px; }
}
@media (max-width: 900px) {
  .satellite-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .plot-legend { margin-left: 0; width: 100%; }
}
@media (max-width: 640px) {
  .satellite-main { padding-top: calc(var(--header-h) + 30px); }
  .satellite-toolbar input { width: 100%; }
  .search-box { width: 100%; }
  .search-box input { width: 100%; }
  .layout-tabs { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding-bottom: 4px; }
  .layout-tabs::-webkit-scrollbar { display: none; }
  .layout-tab { flex: none; }
  .map-wrap { min-height: 420px; }
  .summary-card { padding: 13px; gap: 10px; }
  .summary-card i { width: 36px; height: 36px; }
  .summary-card strong { font-size: 23px; }
  .plot-detail { padding: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  .detail-icon { animation: none !important; }
  .nav-new__badge, .nv-new-badge { animation: nvNewPulse 1.15s steps(2, end) infinite !important; }
  .layout-tab, .detail-enquire, .lt-pill { transition: none !important; }
}

/* ---------- v5 fixes: shared icon base + project actions ---------- */
.ic { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.55; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.satellite-toolbar input { min-width: 0; }
.search-box { min-width: 190px; }
.satellite-intro__actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.satellite-intro__actions[hidden] { display: none; }
.satellite-toolbar input[type="search"] { width: 200px; }
