:root {
  --green-950: #0e211c;
  --green-900: #1a3c34;
  --green-800: #244c42;
  --green-700: #2f5d51;
  --green-100: #e9f0ec;
  --gold-300: #efc57b;
  --gold-500: #c9a24b;
  --gold-600: #8a6a1e;
  --cream: #f7f3ea;
  --surface: #ffffff;
  --ink: #20302b;
  --muted: #5d6b65;
  --border: #e5e0d3;
  --price: #b03a2e;
  --ok: #1e7a46;
  --danger: #c0392b;
  --note-bg: #fff7d6;
  --note-border: #e7c948;
  --font-display: 'Playfair Display', 'Anuphan', serif;
  --font-body: 'Anuphan', 'Noto Sans Thai', system-ui, sans-serif;
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-pill: 999px;
  --shadow-1: 0 1px 3px rgb(20 40 34 / 0.08);
  --shadow-2: 0 8px 24px rgb(20 40 34 / 0.12);
  --shadow-3: 0 16px 40px rgb(14 33 28 / 0.18);
  --container: 1200px;
  /* semantic / brand tokens (added by the theming pass) */
  --surface-alt: #fafaf7;
  --track: #f0efec;
  --on-dark: #dfe9e4;
  --on-dark-muted: #cdd8d2;
  --gold-700: #8a6118;
  --gold-deep: #b8902e;
  --ok-700: #26744d;
  --info: #1d4ed8;
  --info-700: #1f5fae;
  --warn: #b45f06;
  --accent: #e8472b;
  --danger-600: #d32f2f;
  --danger-soft: #c4513d;
  --line-brand: #05843a;
  --line-brand-700: #046f31;
  --info-soft: #bfe0ff;
  --surface-alt-2: #f4f4f1;
  --admin-bg: #f2f4f3;
  --facebook: #1877f2;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.7;
  color: var(--ink);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--green-700); text-decoration: none; }
h1, h2, h3, h4 { line-height: 1.35; margin: 0 0 0.5em; }
:focus-visible { outline: 2px solid var(--gold-500); outline-offset: 2px; }

.skip-link {
  position: fixed;
  z-index: 1100;
  top: 8px;
  left: 8px;
  padding: 10px 16px;
  color: var(--green-900);
  border-radius: 6px;
  background: var(--surface);
  box-shadow: var(--shadow-2);
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

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

/* ============ Buttons / inputs ============ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 24px; border-radius: var(--r-md); border: 1px solid transparent;
  font-family: var(--font-body); font-size: 15px; font-weight: 600; cursor: pointer;
  transition: background 0.15s, transform 0.1s, box-shadow 0.15s;
  min-height: 44px;
}
.btn-primary { background: var(--green-900); color: var(--surface); }
.btn-primary:hover { background: var(--green-800); }
.btn-gold { background: var(--gold-500); color: var(--green-950); }
.btn-gold:hover { background: var(--gold-300); }
.btn-ghost { background: transparent; color: var(--green-800); border-color: var(--green-800); }
.btn-ghost:hover { background: var(--green-800); color: var(--surface); }
.btn-line { background: var(--line-brand); color: var(--surface); }
.btn-line:hover { filter: brightness(1.08); color: var(--surface); }
.btn-whatsapp { background: #25d366; color: var(--surface); }
.btn-whatsapp:hover { background: #1fb659; color: var(--surface); }
.btn-danger { background: var(--danger); color: var(--surface); }
.btn-sm { padding: 7px 14px; min-height: 36px; font-size: 13.5px; border-radius: var(--r-sm); }
.btn-block { width: 100%; }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; }

.input, .select, textarea.input {
  width: 100%; padding: 11px 14px; border: 1px solid var(--border); border-radius: var(--r-md);
  font-family: var(--font-body); font-size: 15px; color: var(--ink); background: var(--surface);
  min-height: 44px;
}
.input:focus, .select:focus, textarea.input:focus { border-color: var(--green-700); outline: none; box-shadow: 0 0 0 3px rgb(47 93 81 / 0.12); }
label.field-label { display: block; font-weight: 600; font-size: 13.5px; margin-bottom: 6px; color: var(--green-900); }
.field { margin-bottom: 14px; }
.req { color: var(--danger); }

/* ============ Navbar ============ */
.navbar {
  position: sticky; top: 0; z-index: 100;
  background: var(--green-900); border-bottom: 2px solid var(--gold-500);
}
/* comment rev.02 slide 2: the logo sits at the very corner of the page, so the bar spans the full width instead of the container */
.navbar-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 16px; max-width: none; padding-inline: 20px; }
@media (min-width: 1200px) { .navbar-inner { padding-inline: 28px; } }
.navbar-right { display: flex; align-items: center; gap: 6px; }
@media (min-width: 900px) { .navbar-right { display: none; } }
.brand img { height: 56px; width: auto; }
.nav-menu { display: none; gap: 4px; }
.nav-menu a {
  color: var(--on-dark); padding: 10px 16px; border-radius: var(--r-sm); font-weight: 500; font-size: 16px;
}
.nav-menu a:hover { color: var(--gold-300); background: rgb(255 255 255 / 0.07); }
.nav-menu a.active { color: var(--gold-300); box-shadow: inset 0 -2px 0 var(--gold-500); border-radius: 0; }
.nav-toggle { background: none; border: none; color: var(--gold-300); cursor: pointer; padding: 10px; }
@media (min-width: 900px) {
  .nav-menu { display: flex; }
  .nav-toggle { display: none; }
}
.nav-menu.open {
  display: flex; position: absolute; top: 68px; left: 0; right: 0;
  flex-direction: column; background: var(--green-900); padding: 12px 16px 20px;
  border-bottom: 2px solid var(--gold-500); box-shadow: var(--shadow-3);
}

/* ============ Hero ============ */
.hero {
  position: relative; min-height: 78svh; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(rgb(14 33 28 / 0.45), rgb(14 33 28 / 0.78)), url('/img/hero.jpg') center/cover no-repeat;
  padding: 72px 16px;
}
.hero-content { text-align: center; max-width: 760px; width: 100%; }
.hero-eyebrow {
  font-family: var(--font-display); color: var(--gold-300); letter-spacing: 0.22em;
  text-transform: uppercase; font-size: 14px; margin-bottom: 12px;
}
.hero h1 { color: var(--surface); font-size: clamp(1.75rem, 5vw, 3rem); font-weight: 700; margin-bottom: 8px; }
.hero-sub { color: #e7eeea; font-size: clamp(1rem, 2.5vw, 1.2rem); margin-bottom: 28px; }
.hero-tabs {
  display: inline-flex; background: rgb(255 255 255 / 0.16); backdrop-filter: blur(8px);
  border-radius: var(--r-pill); padding: 5px; margin-bottom: 16px;
}
.hero-tabs button {
  border: none; background: transparent; color: var(--surface); font-family: var(--font-body);
  font-size: 15px; font-weight: 600; padding: 9px 26px; border-radius: var(--r-pill); cursor: pointer;
}
.hero-tabs button[aria-selected='true'] { background: var(--surface); color: var(--green-900); }
.hero-search { display: flex; background: var(--surface); border-radius: var(--r-pill); padding: 6px; box-shadow: var(--shadow-3); }
.hero-search input {
  flex: 1; border: none; background: transparent; padding: 10px 18px; font-family: var(--font-body);
  font-size: 15px; min-width: 0;
}
.hero-search input:focus { outline: none; }
.hero-search button {
  background: var(--green-900); color: var(--gold-300); border: none; border-radius: var(--r-pill);
  width: 48px; height: 48px; display: grid; place-items: center; cursor: pointer; flex-shrink: 0;
}
.hero-search button:hover { background: var(--green-800); }

/* ============ Sections ============ */
.section { padding: 56px 0; }
.section-heading { text-align: center; margin-bottom: 36px; }
.eyebrow {
  font-family: var(--font-display); color: var(--gold-600); letter-spacing: 0.2em;
  text-transform: uppercase; font-size: 13px; margin-bottom: 6px;
}
.section-heading h2 { font-size: clamp(1.4rem, 3.5vw, 1.9rem); color: var(--green-900); }
.gold-rule { width: 44px; height: 3px; background: var(--gold-500); margin: 10px auto 0; border-radius: 2px; }

/* ============ Category carousel (spec slide 5) ============ */
.cat-carousel { position: relative; }
.cat-row {
  display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 4px 12px; margin: 0 -4px;
  -webkit-overflow-scrolling: touch; scrollbar-width: thin; scrollbar-color: var(--gold-500) transparent;
}
.cat-tile {
  position: relative; flex: 0 0 clamp(240px, 26vw, 330px); aspect-ratio: 4 / 3; border-radius: var(--r-lg); overflow: hidden;
  scroll-snap-align: start; background: linear-gradient(160deg, var(--green-800), var(--green-950)); color: var(--surface);
  box-shadow: 0 6px 20px rgb(21 45 38 / 0.11); transition: transform 0.2s, box-shadow 0.2s;
}
.cat-tile img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.35s, filter 0.25s; }
.cat-tile::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgb(14 33 28 / 0.05) 35%, rgb(14 33 28 / 0.88)); transition: opacity 0.25s; }
/* comment rev.03 slide 3 + rev.04 slide 2: the tile under the cursor "lights up" — picture brighter, label turns solid white, the rest dims */
.cat-tile:hover::after { opacity: 0.35; }
.cat-tile:hover { transform: translateY(-4px); box-shadow: 0 0 0 3px var(--gold-500), var(--shadow-3); }
.cat-tile:hover img { transform: scale(1.08); filter: brightness(1.2) saturate(1.1); }
.cat-tile-label { position: absolute; inset: auto 0 0 0; z-index: 1; display: grid; grid-template-columns: auto 1fr; gap: 2px 10px; align-items: center; padding: 16px; transition: background 0.2s, color 0.2s; }
.cat-tile-icon { grid-row: 1 / span 2; width: 42px; height: 42px; border-radius: 50%; background: rgb(255 255 255 / 0.16); backdrop-filter: blur(4px); display: grid; place-items: center; color: var(--gold-300); transition: background 0.2s, color 0.2s; }
.cat-en { font-weight: 700; font-size: 18px; letter-spacing: 0.08em; line-height: 1.2; text-shadow: 0 2px 8px rgb(0 0 0 / 0.5); transition: text-shadow 0.2s; }
.cat-tile:hover .cat-tile-label { background: rgb(255 255 255 / 0.94); color: var(--green-950); }
.cat-tile:hover .cat-en { text-shadow: none; }
.cat-tile:hover .cat-tile-icon { background: var(--gold-500); color: var(--green-950); }
.cat-th { font-size: 12.5px; opacity: 0.9; }
.carousel-btn {
  position: absolute; top: 50%; transform: translateY(-60%); z-index: 2; width: 48px; height: 48px; border-radius: 50%;
  border: 1px solid var(--border); background: var(--surface); color: var(--green-900); box-shadow: var(--shadow-2);
  display: grid; place-items: center; cursor: pointer; transition: opacity 0.15s, transform 0.15s;
}
.carousel-btn:hover { background: var(--green-100); }
.carousel-btn[disabled] { opacity: 0.35; cursor: default; }
.carousel-prev { left: -14px; }
.carousel-next { right: -14px; }
@media (max-width: 639px) { .carousel-btn { width: 40px; height: 40px; } .carousel-prev { left: -6px; } .carousel-next { right: -6px; } }

/* ============ Location cards ============ */
.loc-row {
  display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px;
  -webkit-overflow-scrolling: touch;
}
.loc-card {
  position: relative; flex: 0 0 232px; height: 296px; border-radius: var(--r-lg); overflow: hidden;
  scroll-snap-align: start; background: linear-gradient(160deg, var(--green-800), var(--green-950));
}
.loc-card img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.loc-card:hover img { transform: scale(1.05); }
.loc-card .loc-ph { position: absolute; inset: 0; display: grid; place-items: center; color: var(--gold-300); opacity: 0.8; }  /* comment rev.04 slide 5: area without a picture yet */
.loc-card .loc-name {
  position: absolute; inset: auto 0 0 0; padding: 40px 16px 16px; color: var(--surface); font-weight: 700; font-size: 17px;
  background: linear-gradient(transparent, rgb(14 33 28 / 0.9));
}

/* ============ Property cards ============ */
.prop-grid { display: grid; grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 640px) { .prop-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .prop-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1200px) { .prop-grid.cols-4 { grid-template-columns: repeat(4, 1fr); } }
.prop-card {
  display: block; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg);
  overflow: hidden; color: var(--ink); transition: transform 0.15s, box-shadow 0.15s; box-shadow: var(--shadow-1);
}
.prop-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); }
.prop-card-photo { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: var(--green-100); }
.prop-card-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.prop-card:hover .prop-card-photo img { transform: scale(1.04); }
.badge {
  position: absolute; top: 12px; left: 12px; padding: 4px 14px; border-radius: var(--r-pill);
  font-size: 13px; font-weight: 700; color: var(--surface);
}
.badge-ok { background: var(--ok); }
.badge-danger { background: var(--danger); }
.prop-card-body { padding: 16px; }
.prop-card-pricerow { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.prop-price { color: var(--price); font-size: 1.35rem; font-weight: 700; }
.prop-price small { font-size: 0.8rem; font-weight: 500; color: var(--muted); margin-left: 2px; }
.price-original { color: var(--muted); font-size: 0.85rem; font-weight: 500; margin-right: 8px; }
.promo-tag {
  padding: 3px 12px; border-radius: var(--r-pill); background: rgb(176 58 46 / 0.1); color: var(--price);
  font-size: 12.5px; font-weight: 700; flex-shrink: 0;
}
.deal-tag {
  padding: 3px 12px; border-radius: var(--r-pill); background: var(--green-100); color: var(--green-800);
  font-size: 12.5px; font-weight: 600; flex-shrink: 0;
}
.prop-name { font-size: 16.5px; font-weight: 700; margin: 0; color: var(--green-950); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* เช่าแล้ว / ขายแล้ว — whole card dimmed with a diagonal stamp (spec slide 6) */
.prop-card.is-taken { filter: grayscale(0.65); opacity: 0.78; }
.prop-card.is-taken:hover { opacity: 0.95; }
.prop-card.is-taken .prop-card-photo::after { content: ''; position: absolute; inset: 0; background: rgb(255 255 255 / 0.45); }
.taken-stamp {
  position: absolute; left: 50%; top: 50%; z-index: 2; transform: translate(-50%, -50%) rotate(-18deg);
  padding: 6px 22px; border: 3px solid var(--danger); border-radius: 8px; color: var(--danger); background: rgb(255 255 255 / 0.85);
  font-size: clamp(1.2rem, 2.4vw, 1.7rem); font-weight: 800; letter-spacing: 0.04em; white-space: nowrap; box-shadow: var(--shadow-2);
}
.prop-loc { display: flex; align-items: center; gap: 5px; color: var(--muted); font-size: 13.5px; margin: 0 0 12px; }
.prop-facts {
  display: flex; flex-wrap: wrap; gap: 6px 0; border-top: 1px solid var(--border); padding-top: 12px; color: var(--muted); font-size: 12.5px;
}
.prop-facts span { display: flex; align-items: center; gap: 5px; padding: 0 8px; border-left: 1px solid var(--border); white-space: nowrap; }
.prop-facts span:first-child { border-left: none; padding-left: 0; }

/* ============ Filter bar ============ */
.filterbar { position: sticky; top: 68px; z-index: 60; background: var(--surface); box-shadow: var(--shadow-1); padding: 12px 0; }
.filterbar form { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.filterbar .input, .filterbar .select { width: auto; min-height: 42px; }
.filterbar .f-q { flex: 1 1 200px; }
.filterbar .select { flex: 0 1 auto; }
@media (max-width: 899px) {
  .filterbar .collapsible { display: none; flex-basis: 100%; flex-wrap: wrap; gap: 10px; }
  .filterbar .collapsible.open { display: flex; }
}
@media (min-width: 900px) { .filterbar .collapsible { display: contents; } }

/* ============ Detail page ============ */
.breadcrumb { font-size: 13px; color: var(--muted); padding: 14px 0 6px; }
.breadcrumb a { color: var(--muted); display: inline-block; padding: 6px 2px; }
.breadcrumb a:hover { color: var(--green-700); }
.detail-title h1 { font-size: clamp(1.3rem, 3vw, 1.7rem); color: var(--green-950); margin-bottom: 2px; }
.detail-title .en-sub { font-family: var(--font-display); color: var(--gold-600); font-size: 15px; }
.detail-meta { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 8px 0; font-size: 13.5px; color: var(--muted); }
.pill { padding: 3px 12px; border-radius: var(--r-pill); font-weight: 600; font-size: 12.5px; }
.pill-ok { background: rgb(30 122 70 / 0.12); color: var(--ok); }
.pill-danger { background: rgb(192 57 43 / 0.12); color: var(--danger); }
.detail-head { display: grid; gap: 14px; margin: 4px 0 16px; }
@media (min-width: 1000px) { .detail-head { grid-template-columns: minmax(0, 1fr) auto; align-items: start; } }
.detail-address { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 13.5px; margin: 0; }
.detail-facts.facts-strip { margin-bottom: 0; grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (min-width: 640px) { .detail-facts.facts-strip { grid-template-columns: repeat(6, auto); } }
.detail-facts.facts-strip > div { padding: 10px 14px; min-width: 88px; }
.detail-facts .f-value { font-size: 14.5px; }
.detail-facts .f-label { font-size: 11px; }

.gallery { display: grid; gap: 10px; margin-bottom: 18px; }
@media (min-width: 900px) { .gallery { grid-template-columns: 2fr 1fr; align-items: stretch; } }
.gallery-left { display: grid; gap: 10px; align-content: start; }
.gallery-main { position: relative; border-radius: var(--r-lg); background: var(--green-100); }
.gallery-main-btn {
  display: block; width: 100%; padding: 0; border: none; border-radius: var(--r-lg); overflow: hidden; aspect-ratio: 4 / 3;
  background: var(--green-100); cursor: zoom-in;
}
.gallery-main-btn img { width: 100%; height: 100%; object-fit: cover; }
.gallery-deal {
  position: absolute; top: 14px; left: 14px; z-index: 2; display: inline-flex; align-items: center; gap: 0; border-radius: var(--r-md); overflow: hidden;
  box-shadow: var(--shadow-2); font-weight: 700; max-width: calc(100% - 28px); flex-wrap: wrap;
}
.gallery-deal-type { background: var(--price); color: var(--surface); padding: 8px 16px; font-size: 15px; }
.gallery-deal-price { background: var(--surface); color: var(--price); padding: 8px 16px; font-size: 18px; display: inline-flex; align-items: baseline; gap: 4px; }
.gallery-deal-price small { font-size: 12px; color: var(--muted); font-weight: 500; }
.gallery-deal-price .price-original { font-size: 12px; margin-right: 4px; }
.gallery-deal .promo-tag { border-radius: 0; background: var(--gold-300); color: var(--green-950); padding: 8px 12px; font-size: 12px; align-self: stretch; display: inline-flex; align-items: center; }
.gallery-actions { position: absolute; top: 14px; right: 14px; z-index: 3; display: flex; gap: 8px; }
.icon-btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; min-height: 38px; border-radius: var(--r-pill);
  background: rgb(255 255 255 / 0.94); color: var(--green-900); border: 1px solid rgb(255 255 255 / 0.6); font-family: var(--font-body);
  font-size: 13.5px; font-weight: 600; cursor: pointer; box-shadow: var(--shadow-1); backdrop-filter: blur(6px);
}
.icon-btn:hover { background: var(--surface); color: var(--green-700); }
.icon-btn.is-saved svg { fill: var(--danger); color: var(--danger); }
@media (max-width: 639px) { .icon-btn span { display: none; } .icon-btn { padding: 8px 11px; } }
.share-wrap { position: relative; }
.share-menu {
  position: absolute; top: calc(100% + 8px); right: 0; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--r-md); box-shadow: var(--shadow-3); padding: 12px; display: none; flex-direction: column; gap: 8px; min-width: 230px; z-index: 20;
}
.share-menu.open { display: flex; }
.share-menu-title { font-weight: 700; color: var(--green-900); font-size: 14px; padding: 0 2px 2px; }
.btn-facebook { background: var(--facebook); color: var(--surface); }
.btn-facebook:hover { filter: brightness(1.08); color: var(--surface); }
.btn-dark { background: var(--ink); color: var(--surface); }
.btn-dark:hover { background: #000; }
.gallery-thumbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
/* desktop: stacked column that matches the left column height exactly (images are absolutely positioned so rows never grow) */
@media (min-width: 900px) { .gallery-thumbs { grid-template-columns: 1fr; grid-auto-rows: minmax(0, 1fr); min-height: 0; } }
.gallery-thumb { position: relative; border-radius: var(--r-md); overflow: hidden; aspect-ratio: 4 / 3; background: var(--green-100); cursor: zoom-in; border: none; padding: 0; min-height: 0; }
@media (min-width: 900px) { .gallery-thumb { aspect-ratio: auto; height: 100%; } }
.gallery-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.gallery-thumb .more-overlay {
  position: absolute; inset: 0; display: grid; place-items: center; background: rgb(14 33 28 / 0.55);
  color: var(--surface); font-weight: 700; font-size: 15px;
}
dialog.lightbox { border: none; background: rgb(10 20 17 / 0.95); max-width: 100dvw; max-height: 100dvh; width: 100dvw; height: 100dvh; padding: 0; touch-action: none; overscroll-behavior: contain; }
dialog.lightbox::backdrop { background: rgb(10 20 17 / 0.9); }
.lightbox-inner { display: grid; place-items: center; width: 100%; height: 100%; position: relative; }
.lightbox-inner img { max-width: 92vw; max-height: 86vh; object-fit: contain; }
.lightbox-btn {
  position: absolute; background: rgb(255 255 255 / 0.12); color: var(--surface); border: none; border-radius: 50%;
  width: 46px; height: 46px; display: grid; place-items: center; cursor: pointer;
}
.lightbox-btn:hover { background: rgb(255 255 255 / 0.25); }
.lb-prev { left: 12px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 12px; top: 50%; transform: translateY(-50%); }
.lb-close { right: 12px; top: 12px; }
.lb-counter { position: absolute; bottom: 14px; left: 50%; transform: translateX(-50%); color: var(--surface); font-size: 13px; }

.facts-strip {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--border);
  border: 1px solid var(--border); border-radius: var(--r-lg); overflow: hidden; margin-bottom: 24px;
}
@media (min-width: 640px) { .facts-strip { grid-template-columns: repeat(4, 1fr); } }
.facts-strip > div { background: var(--cream); padding: 16px; text-align: center; }
.facts-strip .f-icon { color: var(--green-800); margin-bottom: 4px; display: flex; justify-content: center; }
.facts-strip .f-label { font-size: 12px; color: var(--muted); }
.facts-strip .f-value { font-weight: 700; color: var(--green-950); }

.amenity-group { margin-bottom: 20px; }
.amenity-group h3 { font-size: 15.5px; color: var(--green-900); margin-bottom: 10px; }
.chip-row { display: flex; flex-wrap: wrap; gap: 10px; }
.chip {
  display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border: 1px solid var(--green-800);
  color: var(--green-800); border-radius: var(--r-pill); font-size: 13.5px; font-weight: 500; background: var(--surface);
}
.chip:hover { background: var(--green-100); }

.price-table { width: 100%; border-collapse: collapse; margin-bottom: 24px; border: 1px solid var(--border); border-radius: var(--r-lg); overflow: hidden; }
.price-table th, .price-table td { padding: 12px 16px; border-bottom: 1px solid var(--border); text-align: left; }
.price-table td:last-child { text-align: right; }
.price-table .total-row { background: var(--cream); font-weight: 700; color: var(--green-900); font-size: 16px; }
.price-table caption { caption-side: top; text-align: left; font-weight: 700; color: var(--green-900); font-size: 16px; padding: 0 0 10px; display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.map-title { color: var(--green-900); scroll-margin-top: 90px; }

.map-embed { border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--border); aspect-ratio: 16 / 9; margin-bottom: 12px; }
.map-embed iframe { width: 100%; height: 100%; border: 0; }
.map-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 24px; }

.detail-layout { display: grid; gap: 28px; }
@media (min-width: 900px) { .detail-layout { grid-template-columns: 1fr 360px; align-items: start; } }

.related-row { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media (min-width: 640px) { .related-row { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .related-row { grid-template-columns: repeat(4, 1fr); } }

.form-grid { display: grid; grid-template-columns: 1fr; gap: 0 16px; }
@media (min-width: 640px) { .form-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 900px) { .form-grid.cols-3 { grid-template-columns: repeat(3, 1fr); } }

/* ============ Footer ============ */
.footer { background: var(--green-950); color: var(--on-dark-muted); border-top: 2px solid var(--gold-500); margin-top: 0; }
.footer-grid { display: grid; grid-template-columns: 1fr; gap: 28px; padding: 44px 16px; }
@media (min-width: 900px) { .footer-grid { grid-template-columns: 2fr 1fr 1.4fr; } }
.footer h4, .footer .footer-h { color: var(--gold-300); font-size: 15px; margin-bottom: 12px; font-weight: 700; }
.footer ul { list-style: none; margin: 0; padding: 0; }
.footer li { margin-bottom: 8px; }
.footer a { color: var(--on-dark-muted); }
.footer a:hover { color: var(--gold-300); }
.footer-tagline { font-family: var(--font-display); color: var(--gold-500); margin: 8px 0 4px; font-size: 14px; letter-spacing: 0.08em; }
.footer-desc { font-size: 13.5px; }
.footer-contact li { display: flex; align-items: center; gap: 8px; }
.footer-bottom { border-top: 1px solid rgb(255 255 255 / 0.1); padding: 16px 0; font-size: 12.5px; color: #8fa39a; }

/* ============ Toast ============ */
.toast {
  position: fixed; bottom: 84px; left: 50%; transform: translateX(-50%); z-index: 200;
  background: var(--green-950); color: var(--surface); padding: 10px 22px; border-radius: var(--r-pill);
  font-size: 14px; opacity: 0; pointer-events: none; transition: opacity 0.25s;
}
.toast.show { opacity: 1; }

/* ============ Pagination ============ */
.pagination { display: flex; gap: 8px; justify-content: center; margin: 32px 0; flex-wrap: wrap; }
.pagination a, .pagination span {
  min-width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--border); border-radius: var(--r-sm); color: var(--ink); padding: 0 10px;
}
.pagination .current { background: var(--green-900); color: var(--surface); border-color: var(--green-900); }

/* ============ Admin ============ */
.admin-body { background: var(--admin-bg); font-size: 14px; }
.admin-main { min-width: 0; padding: 24px 24px 60px; }
.admin-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-md); padding: 20px; margin-bottom: 18px; box-shadow: var(--shadow-1); }
.admin-card h2 { font-size: 17px; color: var(--green-900); margin-bottom: 14px; }
.admin-card h3 { font-size: 14.5px; color: var(--green-900); margin: 18px 0 8px; }

.stat-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-bottom: 20px; }
@media (min-width: 900px) { .stat-grid { grid-template-columns: repeat(4, 1fr); } .stat-grid-3 { grid-template-columns: repeat(3, 1fr) !important; } .stat-grid-2 { grid-template-columns: repeat(2, 1fr) !important; max-width: 720px; } }

.data-table { width: 100%; border-collapse: collapse; font-size: 13.5px; line-height: 1.55; }
.data-table th { text-align: left; padding: 10px 14px; background: var(--green-100); color: var(--green-900); white-space: nowrap; }
.data-table td { padding: 12px 14px; border-bottom: 1px solid var(--border); vertical-align: top; }
.data-table td.nowrap, .data-table .nowrap { white-space: nowrap; }
.data-table .cell-wide { min-width: 220px; }
.data-table .cell-main { font-weight: 600; color: var(--green-950); }
.data-table a.cell-main { color: var(--green-700); }
.data-table .cell-sub { color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.data-table .deal-tag { display: inline-block; }
.data-table .role-pill { display: inline-block; margin-left: 6px; padding: 1px 9px; border-radius: var(--r-pill); background: rgb(201 162 75 / 0.18); color: var(--gold-700); font-size: 11.5px; font-weight: 600; vertical-align: 1px; }
.data-table tr:hover td { background: var(--surface-alt); }
.data-table .thumb { width: 56px; height: 56px; max-width: none; flex: none; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 8px; background: var(--green-100); }
.data-table td:has(> .thumb) { width: 72px; min-width: 72px; }
.table-wrap { overflow-x: auto; }

.status-pill { display: inline-block; padding: 2px 12px; border-radius: var(--r-pill); font-size: 12px; font-weight: 600; }
.status-available { background: rgb(30 122 70 / 0.12); color: var(--ok); }
.status-rented, .status-sold { background: rgb(192 57 43 / 0.12); color: var(--danger); }
.status-hidden, .status-draft { background: rgb(107 122 116 / 0.15); color: var(--muted); }

/* Admin chip select (Livinginsider-style) */
.chip-select { display: flex; flex-wrap: wrap; gap: 10px; }
.chip-select label {
  display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border: 1px solid var(--border);
  border-radius: var(--r-pill); cursor: pointer; font-size: 13.5px; background: var(--surface); user-select: none;
  transition: all 0.12s; min-height: 40px;
}
.chip-select label:hover { border-color: var(--green-700); }
.chip-select input { position: absolute; opacity: 0; pointer-events: none; }
.chip-select label.is-checked { background: var(--green-900); color: var(--surface); border-color: var(--green-900); }
.chip-select label.is-checked svg { color: var(--gold-300); }

.note-field textarea {
  background: var(--note-bg); border-color: var(--note-border);
}
.note-hint { font-size: 12.5px; color: var(--gold-600); font-weight: 600; }

.upload-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; margin-top: 10px; }
.upload-item { position: relative; aspect-ratio: 4/3; border-radius: var(--r-sm); overflow: hidden; border: 1px solid var(--border); }
.upload-item img { width: 100%; height: 100%; object-fit: cover; }
.upload-item .cover-tag { position: absolute; top: 4px; left: 4px; background: var(--gold-500); color: var(--green-950); font-size: 10.5px; font-weight: 700; padding: 1px 8px; border-radius: var(--r-pill); }
.upload-item .del-btn {
  position: absolute; top: 4px; right: 4px; width: 24px; height: 24px; border-radius: 50%;
  background: rgb(192 57 43 / 0.9); color: var(--surface); border: none; cursor: pointer; display: grid; place-items: center; font-size: 13px;
}
.upload-item .crop-btn {
  position: absolute; bottom: 4px; left: 4px; border: none; border-radius: var(--r-pill); padding: 2px 9px; font-size: 11px; font-weight: 700;
  background: rgb(14 33 28 / 0.78); color: var(--surface); cursor: pointer;
}
.upload-item .crop-btn:hover { background: var(--gold-500); color: var(--green-950); }
.upload-progress { margin: 8px 0 0; font-size: 13px; color: var(--green-800); font-weight: 600; }
/* comment rev.04 slide 16: note log */
.note-compose textarea { margin-bottom: 8px; }
.note-actions { display: flex; gap: 8px; }
.note-log { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 8px; }
.note-item { padding: 10px 12px; border-radius: var(--r-sm); background: var(--note-bg, #fbf7ea); border: 1px solid var(--note-border, #ecdfb3); font-size: 14px; line-height: 1.5; white-space: pre-wrap; }
.note-stamp { color: var(--muted); font-size: 12.5px; white-space: nowrap; }
.note-empty { color: var(--muted); font-size: 13px; margin: 10px 0 0; }
/* comment rev.04 slide 14: collapsed geography line */
.geo-summary { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; min-height: 42px; padding: 6px 12px; border: 1px dashed var(--border); border-radius: var(--r-sm); background: var(--cream, #f7f4ec); font-size: 14px; }
.geo-summary svg { color: var(--green-700); flex: 0 0 auto; }
.geo-summary [data-geo-text]:empty::before { content: 'ยังไม่มีข้อมูล — เลือกโครงการ หรือกด แก้ไข'; color: var(--muted); }
.geo-summary .btn { margin-left: auto; }
.geo-fields { margin-top: 4px; }
[data-field-geo] { grid-column: 1 / -1; }
.field-hint-inline { font-weight: 500; color: var(--muted); font-size: 12px; }
.upload-drop {
  border: 2px dashed var(--border); border-radius: var(--r-md); padding: 26px; text-align: center; color: var(--muted);
  cursor: pointer; transition: border-color 0.15s;
}
.upload-drop:hover { border-color: var(--gold-500); color: var(--gold-600); }

.short-term-rows { display: grid; gap: 8px; margin-top: 10px; }
.short-term-row { display: grid; grid-template-columns: 110px 1fr; gap: 10px; align-items: center; }

.hashtag-warn {
  background: rgb(192 57 43 / 0.08); border: 1px solid rgb(192 57 43 / 0.25); color: var(--danger);
  border-radius: var(--r-md); padding: 10px 14px; font-size: 13px; margin-bottom: 12px;
}

/* Login */
.login-page { min-height: 100svh; display: grid; place-items: center; background: var(--green-950); padding: 20px; }
.login-card { width: 100%; max-width: 380px; background: var(--surface); border-radius: var(--r-lg); padding: 32px; box-shadow: var(--shadow-3); }
.login-card img { margin: 0 auto 8px; }
.login-error { color: var(--danger); font-size: 13.5px; text-align: center; margin-bottom: 10px; }

/* Empty state */
.empty-state { text-align: center; color: var(--muted); padding: 48px 16px; }
.empty-state svg { margin: 0 auto 10px; color: var(--border); }

@media print {
  .navbar, .footer, .chat-dock, .btn, dialog.lightbox { display: none !important; }
}

/* ============ Home — Modern Minimal Premium ============ */
.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.home-page {
  --home-green: #17382f;
  --home-green-dark: #132f28;
  --home-gold: #d0a24e;
  --home-coral: var(--danger-soft);
  --home-cream: #f8f5f1;
  --home-border: #e9e3dd;
  --home-control-border: #928d87;
  --home-muted: var(--muted);
  font-family: 'Kanit', 'Anuphan', sans-serif;
  color: #24342f;
  overflow-x: clip;
}

.home-page :focus-visible {
  outline: 3px solid var(--gold-700);
  outline-offset: 3px;
}

.home-page .navbar :focus-visible,
.home-page .footer :focus-visible {
  outline-color: #f0c66d;
}

.home-page .navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 72px;
  background: rgb(19 47 40 / 0.58);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgb(208 162 78 / 0.35);
  transition: background 0.3s, border-color 0.3s, box-shadow 0.3s;
}

/* comment rev.02 slide 1: the bar is see-through over the hero and turns solid once the page scrolls */
.home-page .navbar.is-scrolled {
  background: var(--home-green-dark);
  border-bottom-color: rgb(208 162 78 / 0.72);
  box-shadow: 0 6px 24px rgb(0 0 0 / 0.18);
}

.home-page .home-hero {
  padding-top: 126px;
}

.home-page .navbar-inner {
  max-width: none;
  height: 72px;
}

.home-page .brand img {
  width: auto;
  height: 58px;
}

.home-page .nav-menu a {
  padding: 11px 18px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  color: #f3f4ef;
  font-size: 17px;
  font-weight: 400;
}

.home-page .nav-menu a:hover,
.home-page .nav-menu a:focus-visible,
.home-page .nav-menu a.active {
  color: var(--home-gold);
}

.home-page .nav-menu a.active {
  box-shadow: inset 0 -2px 0 var(--home-gold);
}

.home-page .nav-toggle {
  color: var(--home-gold);
  min-width: 44px;
  min-height: 44px;
}

.home-page .nav-menu.open {
  top: 72px;
  background: var(--home-green-dark);
}

.home-main {
  background: var(--surface);
}

.home-container {
  width: 100%;
  max-width: 1294px;
  margin-inline: auto;
  padding-inline: 20px;
}

.home-hero {
  position: relative;
  min-height: 520px;
  display: grid;
  place-items: center;
  padding: 54px 20px;
  background-color: #edf0e8;
  /* --hero-image is set inline by the view from /admin/settings */
  background-image: var(--hero-image, url('/img/modern-premium/hero.jpg'));
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
}

.home-hero-content {
  width: min(100%, 800px);
  text-align: center;
}

.home-hero-eyebrow {
  /* comment rev.04 slide 1: clearly smaller than the headline (about 55% of it) — rev.03 had asked for headline size */
  margin: 0 0 10px;
  color: var(--gold-700);
  font-family: 'Lora', serif;
  font-size: clamp(1.05rem, 2.2vw, 1.5rem);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: 0.18em;
}

.home-hero h1 {
  margin: 0;
  color: var(--home-green-dark);
  font-size: clamp(1.95rem, 4vw, 2.72rem);
  font-weight: 600;
  line-height: 1.25;
  text-wrap: balance;
}

.home-hero-sub {
  margin: 8px 0 20px;
  color: var(--gold-700);
  font-family: 'Lora', serif;
  font-size: clamp(0.98rem, 2vw, 1.12rem);
  font-weight: 500;
}

.home-search-form {
  width: 100%;
  margin-inline: auto;
}

.home-page .hero-tabs {
  display: inline-grid;
  grid-template-columns: repeat(2, 1fr);
  width: min(100%, 280px);
  margin: 0 auto 18px;
  padding: 5px;
  background: var(--surface);
  border: 1px solid rgb(23 56 47 / 0.08);
  border-radius: 999px;
  box-shadow: 0 7px 24px rgb(29 51 44 / 0.1);
  backdrop-filter: none;
}

.home-page .hero-tabs button {
  min-height: 48px;
  padding: 8px 22px;
  border-radius: 999px;
  color: var(--home-green);
  font-family: 'Kanit', sans-serif;
  font-size: 15px;
  font-weight: 500;
}

/* sliding pill: the green background is one element that glides between the tabs */
.home-page .hero-tabs { position: relative; isolation: isolate; }
.home-page .hero-tabs::before {
  content: '';
  position: absolute;
  top: 5px; bottom: 5px; left: 5px;
  width: calc(50% - 5px);
  border-radius: 999px;
  background: var(--home-green);
  box-shadow: 0 6px 16px rgb(23 56 47 / 0.28);
  transition: transform .42s cubic-bezier(.22, 1, .36, 1);
  z-index: 0;
}
.home-page .hero-tabs[data-active='rent']::before { transform: translateX(100%); }
.home-page .hero-tabs button {
  position: relative;
  z-index: 1;
  background: transparent;
  transition: color .25s ease, transform .15s ease;
}
.home-page .hero-tabs button:active { transform: scale(.94); }
.home-page .hero-tabs button[aria-selected='true'] {
  color: var(--surface);
  background: transparent;
  animation: tab-pop .38s cubic-bezier(.22, 1, .36, 1);
}
@keyframes tab-pop {
  0% { transform: scale(.92); }
  60% { transform: scale(1.06); }
  100% { transform: scale(1); }
}
.home-page .hero-search.is-switching { animation: search-glow .7s ease-out; }
@keyframes search-glow {
  0% { box-shadow: 0 0 0 0 rgb(201 162 75 / 0.55), 0 12px 30px rgb(14 33 28 / 0.18); }
  100% { box-shadow: 0 0 0 14px rgb(201 162 75 / 0), 0 12px 30px rgb(14 33 28 / 0.18); }
}
@media (prefers-reduced-motion: reduce) {
  .home-page .hero-tabs::before, .home-page .hero-tabs button { transition: none; animation: none; }
  .home-page .hero-search.is-switching { animation: none; }
}

.home-page .hero-tabs button:focus-visible {
  outline-color: var(--gold-700);
  outline-offset: 3px;
}

.home-page .hero-search {
  width: min(100%, 760px);
  min-height: 72px;
  margin-inline: auto;
  padding: 7px;
  border: 1px solid rgb(23 56 47 / 0.12);
  border-radius: 999px;
  background: var(--surface);
  box-shadow: 0 12px 35px rgb(22 47 40 / 0.15);
}

.home-page .hero-search input {
  padding-inline: 22px;
  color: #33423e;
  font-family: 'Kanit', sans-serif;
  font-size: 15px;
}

.home-page .hero-search input:focus-visible { outline: none; }
/* focus ring on the whole pill (input + button) instead of the input alone */
.home-page .hero-search:focus-within {
  box-shadow: 0 0 0 3px rgb(201 162 75 / 0.85), 0 12px 30px rgb(14 33 28 / 0.18);
}

.home-page .hero-search input::placeholder {
  color: var(--muted);
  opacity: 1;
}

.home-page .hero-search button {
  width: 56px;
  height: 56px;
  color: var(--home-gold);
  background: var(--home-green-dark);
}

.home-page .hero-search button:hover {
  background: #244b40;
}

.home-section {
  padding-block: 48px;
}

.home-section-heading {
  margin-bottom: 30px;
  text-align: center;
}

.home-section-heading h2 {
  margin: 0;
  color: var(--home-green-dark);
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 600;
  line-height: 1.35;
}

.home-gold-rule {
  display: block;
  width: 46px;
  height: 3px;
  margin: 10px auto 0;
  border-radius: 999px;
  background: var(--home-gold);
}

.home-page .cat-tile { border-radius: 10px; }
.home-page .carousel-btn { color: var(--home-green-dark); border-color: var(--home-border); }

.home-locations {
  padding-top: 36px;
}

.home-page .loc-row {
  gap: 16px;
  margin-inline: -4px;
  padding: 4px 4px 12px;
  scrollbar-color: var(--home-gold) transparent;
}

.home-page .loc-card {
  flex-basis: 224px;
  height: 310px;
  border-radius: 10px;
  background: var(--home-green-dark);
  box-shadow: 0 6px 20px rgb(21 45 38 / 0.11);
}

.home-page .loc-card .loc-name {
  padding: 24px 16px 16px;
  background: transparent;
  font-size: 17px;
  font-weight: 500;
  text-shadow: 0 2px 8px rgb(0 0 0 / 0.55);
}

.home-properties {
  padding-top: 44px;
  padding-bottom: 54px;
}

.home-page .prop-grid {
  gap: 18px;
}

.home-page .home-prop-card {
  border-color: var(--home-border);
  border-radius: 9px;
  box-shadow: 0 4px 18px rgb(29 51 44 / 0.06);
}

.home-page .home-prop-card .prop-card-photo {
  aspect-ratio: 15 / 11;
}

.home-page .home-prop-card .badge {
  top: 10px;
  left: 10px;
  padding: 3px 13px;
  border-radius: 5px;
  background: #277351;
  font-size: 12px;
  font-weight: 500;
}

.home-page .home-prop-card .prop-card-body {
  padding: 14px 14px 15px;
}

.home-page .home-prop-card .prop-price {
  color: var(--home-coral);
  font-size: 1.23rem;
  font-weight: 600;
}

.home-page .home-prop-card .prop-price small {
  color: var(--home-coral);
  font-size: 0.7rem;
  font-weight: 400;
}

.home-page .home-prop-card .price-original {
  display: block;
  margin: 0;
  color: var(--home-muted);
  font-size: 0.72rem;
}
.home-page .home-prop-card .prop-name {
  min-height: 24px;
  margin: 0;
  color: #283a34;
  font-size: 15px;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.home-page .home-prop-card .prop-loc {
  min-height: 22px;
  margin-bottom: 9px;
  color: var(--home-muted);
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.home-page .home-prop-card .prop-loc svg {
  flex: 0 0 auto;
}

.home-page .home-prop-card .prop-facts {
  min-height: 32px;
  gap: 5px 0;
  padding-top: 9px;
  color: var(--muted);
  border-top-color: var(--home-border);
  font-size: 11px;
}

.home-page .home-prop-card .prop-facts span {
  gap: 4px;
  padding-inline: 6px;
}

.home-page .home-prop-card .prop-facts svg {
  width: 13px;
  height: 13px;
}

.home-all-listings {
  margin-top: 30px;
  text-align: center;
}

.home-page .home-outline-btn {
  min-height: 44px;
  padding: 8px 24px;
  color: var(--home-green);
  border-color: #8fa79e;
  border-radius: 7px;
  background: var(--surface);
  font-size: 14px;
  font-weight: 400;
}

.home-page .home-outline-btn:hover {
  color: var(--surface);
  background: var(--home-green);
}

.home-page fieldset.field {
  min-width: 0;
  margin: 0 0 14px;
  padding: 0;
  border: 0;
}

.home-page .field {
  min-width: 0;
  margin-bottom: 13px;
}

.home-page label.field-label,
.home-page legend.field-label {
  margin-bottom: 5px;
  color: #4f5d58;
  font-size: 12px;
  font-weight: 400;
}

.home-page .input,
.home-page .select {
  min-height: 42px;
  padding: 9px 12px;
  color: #38453f;
  border-color: var(--home-control-border);
  border-radius: 7px;
  font-family: 'Kanit', sans-serif;
  font-size: 13px;
}

.home-page .input::placeholder {
  color: var(--muted);
}

.home-page .input:focus,
.home-page .select:focus {
  border-color: #4b7869;
  box-shadow: 0 0 0 3px rgb(47 93 81 / 0.12);
}

.home-page .footer {
  color: #d7dfdc;
  border-top: 2px solid var(--home-gold);
  background: var(--home-green-dark);
}

.home-page .footer-grid {
  max-width: 1294px;
  gap: 24px;
  padding: 28px 20px 24px;
}

.home-page .footer-grid > div:first-child img {
  width: auto;
  height: 55px;
}

.home-page .footer h4, .home-page .footer .footer-h {
  margin-bottom: 8px;
  color: var(--home-gold);
  font-size: 14px;
  font-weight: 500;
}

.home-page .footer li {
  margin-bottom: 3px;
  font-size: 12px;
}

.home-page .footer-tagline {
  margin: 7px 0 4px;
  color: var(--home-gold);
  font-family: 'Lora', serif;
  font-size: 12px;
}

.home-page .footer-desc {
  max-width: 480px;
  margin: 0;
  font-size: 11px;
  line-height: 1.65;
}

.home-page .footer-bottom {
  padding: 20px 0;
  color: #8fa29b;
  font-size: 11px;
}

@media (min-width: 640px) {
  .home-page .prop-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 900px) {
  .home-page .navbar {
    height: 92px;
  }

  .home-page .navbar-inner {
    height: 92px;
  }

  .home-page .brand img {
    height: 70px;
  }

  .home-page .nav-menu {
    gap: 6px;
  }

  .home-hero {
    min-height: 556px;
    padding-block: 66px 58px;
  }

  .home-page .home-hero {
    padding-top: 158px;
  }

  .home-categories {
    padding-block: 48px 44px;
  }

  .home-locations {
    padding-block: 38px 50px;
  }

  .home-page .loc-row {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 20px;
    overflow: visible;
  }

  .home-page .loc-card {
    width: auto;
    height: 326px;
  }

  .home-properties {
    padding-block: 44px 24px;
  }

  .home-page .prop-grid,
  .home-page .prop-grid.cols-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
  }

  .home-page .footer-grid {
    grid-template-columns: 2fr 0.8fr 1.25fr;
  }
}

@media (max-width: 639px) {
  .home-hero {
    min-height: 500px;
    background-position: 58% center;
  }

  .home-page .hero-tabs button {
    min-height: 44px;
    padding-inline: 10px;
  }

  .home-page .hero-search {
    min-height: 62px;
  }

  .home-page .hero-search input {
    padding-inline: 14px 8px;
    font-size: 16px;
  }

  .home-page .hero-search button {
    width: 48px;
    height: 48px;
  }

  .home-section {
    padding-block: 40px;
  }
}

@media (max-width: 899px) {
  .home-page .input,
  .home-page .select {
    min-height: 44px;
    font-size: 16px;
  }

  .home-page .hero-search input {
    font-size: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .home-page *,
  .home-page *::before,
  .home-page *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}


/* ============ Admin: switches, pickers, toolbar (spec slides 13-14) ============ */
.switch-row { margin: 20px 0 8px; }
.switch-label { display: inline-flex; align-items: center; gap: 12px; cursor: pointer; font-weight: 700; color: var(--green-900); font-size: 15px; }
.switch { position: relative; display: inline-block; width: 46px; height: 26px; flex-shrink: 0; }
.switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
.switch-track { position: absolute; inset: 0; background: #cfd6d2; border-radius: 999px; transition: background 0.15s; }
.switch-track::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: var(--surface); box-shadow: var(--shadow-1); transition: transform 0.15s; }
.switch input:checked + .switch-track { background: #4cb780; }
.switch input:checked + .switch-track::after { transform: translateX(20px); }
.switch input:focus-visible + .switch-track { outline: 2px solid var(--gold-500); outline-offset: 2px; }
.hint-ok { display: flex; gap: 8px; align-items: flex-start; background: rgb(76 183 128 / 0.1); border: 1px solid rgb(76 183 128 / 0.3); color: #1f7a4a; border-radius: var(--r-md); padding: 10px 14px; font-size: 13px; margin: 6px 0 12px; }
.hint-ok svg { flex-shrink: 0; margin-top: 3px; }
.short-term-box { display: grid; gap: 10px; margin-top: 6px; }
.short-term-list { display: grid; gap: 8px; }
.short-term-row { display: grid; grid-template-columns: 92px 1fr auto; gap: 10px; align-items: center; }
.short-term-row[hidden] { display: none; }
.st-month { background: rgb(47 93 81 / 0.1); color: var(--green-900); border-radius: var(--r-sm); padding: 8px; text-align: center; font-size: 13px; }
.st-month b { display: block; font-size: 18px; line-height: 1.1; }
.st-unit { color: var(--muted); font-size: 13px; }
.st-add-btn { border-style: dashed; color: var(--ok-700); border-color: var(--ok-700); }
.st-picker { border: 1px solid var(--border); border-radius: var(--r-md); padding: 14px; background: var(--surface-alt); }
.st-picker[hidden] { display: none; }
.st-picker-title { margin: 0 0 10px; font-size: 13.5px; color: var(--muted); }
.chip-select label.is-disabled { opacity: 0.45; cursor: not-allowed; }
.chip-group { margin-bottom: 8px; }
.chip-group-title { font-size: 13px; color: var(--muted); margin: 8px 0 6px; font-weight: 600; }
.admin-card h3 svg, .admin-card h2 svg { vertical-align: -3px; margin-right: 4px; color: var(--green-700); }
.new-pill { display: inline-block; background: #c93b3b; color: var(--surface); font-size: 11px; padding: 1px 10px; border-radius: var(--r-pill); vertical-align: middle; margin-left: 6px; }
.hashtag-sub { margin: -6px 0 10px; font-size: 13.5px; color: var(--muted); }
.form-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
[hidden] { display: none !important; }

/* ============ Admin analytics dashboard ============ */
.dash-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.dash-sub { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.range-filter { display: inline-flex; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-pill); padding: 4px; gap: 2px; }
.range-filter a { display: inline-flex; align-items: center; gap: 4px; padding: 6px 14px; border-radius: var(--r-pill); font-size: 13.5px; color: var(--muted); font-weight: 500; }
.range-filter a:hover { background: var(--green-100); color: var(--green-900); }
.range-filter a.active { background: var(--green-900); color: var(--surface); font-weight: 700; }
.kpi-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-bottom: 16px; }
@media (min-width: 900px) { .kpi-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1200px) { .kpi-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
.stat-tile { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-md); padding: 14px 16px; min-width: 0; }
.stat-label { font-size: 12.5px; color: var(--muted); }
.stat-value-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 2px; }
.stat-value { font-size: 30px; font-weight: 700; color: var(--green-900); line-height: 1.15; }
.spark { flex-shrink: 0; overflow: visible; }
.stat-delta { font-size: 12.5px; font-weight: 700; margin-top: 4px; }
.stat-delta span { color: var(--muted); font-weight: 500; }
.stat-delta.is-up { color: #006300; }
.stat-delta.is-down { color: var(--danger); }
.stat-delta.is-flat { color: var(--muted); }
.stat-sub { font-size: 12px; color: var(--muted); margin-top: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dash-grid { display: grid; grid-template-columns: 1fr; gap: 14px; margin-bottom: 16px; }
@media (min-width: 900px) {
  .dash-grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dash-grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .dash-grid.cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dash-grid.cols-3-1 { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
}
@media (min-width: 1200px) { .dash-grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } .dash-grid.stat-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.chart-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-md); padding: 16px 18px; min-width: 0; box-shadow: var(--shadow-1); }
.chart-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 10px; }
.chart-head h2, .chart-head h3 { font-size: 14.5px; color: var(--green-900); margin: 0; font-weight: 700; }
.chart-total { font-size: 12.5px; color: var(--muted); white-space: nowrap; }
.chart-total strong { color: var(--green-950); }
.chart-link { font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.chart-empty { color: var(--muted); font-size: 13px; margin: 10px 0; text-align: center; padding: 18px 0; }
svg.chart { width: 100%; height: auto; display: block; font-family: var(--font-body); }
svg.chart .grid { stroke: #e1e0d9; stroke-width: 1; }
svg.chart .axis { stroke: #c3c2b7; stroke-width: 1; }
svg.chart .tick { fill: #898781; font-size: 10.5px; }
svg.chart .bar-label { fill: var(--ink); font-size: 11px; font-weight: 600; }
svg.chart .bar { transition: filter 0.1s; }
svg.chart .slot:hover .bar { filter: brightness(1.15); }
svg.chart .hit { fill: transparent; cursor: crosshair; }
svg.chart .slot:hover .hit { fill: rgb(26 60 52 / 0.05); }
.chart-table { margin-top: 8px; font-size: 12.5px; }
.chart-table summary { cursor: pointer; color: var(--muted); }
.chart-table table { width: 100%; border-collapse: collapse; margin-top: 6px; max-height: 200px; }
.chart-table td, .chart-table th { padding: 3px 6px; border-bottom: 1px solid var(--border); text-align: left; font-variant-numeric: tabular-nums; }
.chart-table td:last-child, .chart-table th:last-child { text-align: right; }
.hbars { display: grid; gap: 8px; }
.hbar-row { display: grid; grid-template-columns: minmax(90px, 38%) 1fr 40px; gap: 10px; align-items: center; font-size: 13px; border-radius: 6px; }
.hbar-row:hover { background: var(--surface-alt); }
.hbar-label { color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hbar-track { height: 14px; background: var(--track); border-radius: 4px; overflow: hidden; }
.hbar-fill { display: block; height: 100%; border-radius: 0 4px 4px 0; }
.hbar-val { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--green-950); }
.stack { display: flex; gap: 2px; height: 26px; border-radius: 6px; overflow: hidden; background: var(--track); }
.stack-seg { display: flex; align-items: center; justify-content: center; min-width: 4px; color: var(--surface); font-size: 12px; font-weight: 700; }
.legend { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 6px; font-size: 13px; }
.legend li { display: flex; align-items: center; gap: 8px; }
.legend strong { margin-left: auto; font-variant-numeric: tabular-nums; }
.legend-pct { color: var(--muted); font-size: 12px; min-width: 34px; text-align: right; }
.swatch { width: 12px; height: 12px; border-radius: 3px; flex-shrink: 0; }
.funnel { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; align-items: center; gap: 6px; margin-top: 6px; }
@media (max-width: 639px) { .funnel { grid-template-columns: 1fr; } .funnel-arrow { grid-auto-flow: column; justify-content: center; } .funnel-arrow svg { transform: rotate(90deg); } }
.top-table { min-width: 460px; }
.funnel-step { background: var(--cream); border: 1px solid var(--border); border-radius: var(--r-md); padding: 12px 8px; text-align: center; color: var(--green-800); min-width: 0; }
.funnel-value { font-size: 22px; font-weight: 700; color: var(--green-950); line-height: 1.2; margin-top: 4px; }
.funnel-label { font-size: 11.5px; color: var(--muted); }
.funnel-arrow { display: grid; justify-items: center; color: var(--muted); font-size: 12px; font-weight: 700; }
.top-table th.num, .top-table td.num { text-align: right; }
.top-table td.rank { color: var(--muted); font-weight: 700; width: 28px; }
.top-table .top-prop { display: flex; align-items: center; gap: 10px; }
.top-table .thumb { width: 44px; height: 44px; }
.top-table td { padding: 8px 10px; vertical-align: middle; }
.chart-tip {
  position: fixed; z-index: 300; pointer-events: none; background: var(--green-950); color: var(--surface); font-size: 12.5px; padding: 6px 10px;
  border-radius: 6px; box-shadow: var(--shadow-2); opacity: 0; transition: opacity 0.1s; white-space: nowrap; max-width: 320px;
}
.chart-tip.show { opacity: 1; }

/* ======================================================================
   Presentation-comment_Rev.01 — customer review round 1
   ====================================================================== */


/* ---- Footer per comment rev.04 slide 7: logo + tagline + blurb | "Property smart" + address | "Property smart.com" + social icons ---- */
.footer-grid.footer-grid-3 { grid-template-columns: 1fr; }
@media (min-width: 760px) { .footer-grid.footer-grid-3, .home-page .footer-grid.footer-grid-3 { grid-template-columns: 1.3fr 1fr 1fr; gap: 40px; } }
.footer-logo { display: block; height: 62px; width: auto; margin: 0 0 8px; }
.footer-tagline { margin: 0 0 10px; color: var(--gold-300); font-family: 'Lora', serif; font-size: 15px; }
.footer-col-h { margin: 0 0 10px; color: var(--surface); font-size: 18px; font-weight: 700; }
.footer-brand-name { margin: 0 0 10px; color: var(--surface); font-size: 22px; font-weight: 700; letter-spacing: 0.01em; }
.footer-brand .footer-desc { margin: 0 0 12px; max-width: 480px; }
.footer-address { display: flex; align-items: flex-start; gap: 6px; margin: 0 0 16px; font-style: normal; font-size: 13.5px; }
.footer-address svg { flex: 0 0 auto; margin-top: 3px; color: var(--gold-300); }
.footer-brand .social-row { flex-wrap: nowrap; }
.footer-contact li { align-items: baseline; }
.footer-contact .fc-k { color: var(--gold-300); font-weight: 600; margin-right: 6px; }
.social-row { display: flex; gap: 10px; }
.social-btn { width: 44px; height: 44px; border-radius: 50%; background: rgb(255 255 255 / 0.08); color: var(--surface); display: grid; place-items: center; transition: background 0.15s, color 0.15s; }
.social-btn:hover { background: var(--gold-500); color: var(--green-950); }
.footer-bottom-inner { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px 16px; }
.footer-legal { display: inline-flex; gap: 8px; }
.footer-legal a { color: #a8b8b1; }
.footer-legal a:hover { color: var(--gold-300); }


/* ---- Property cards (slide 2): type/deal chips + views/interest counters, yield badge (slide 4) ---- */
.prop-meta { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border); }
.prop-meta-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.mini-chip { font-size: 11.5px; font-weight: 600; padding: 2px 9px; border-radius: 6px; white-space: nowrap; }
.mini-chip-type { background: var(--green-900); color: var(--surface); }
.prop-meta-stats { display: flex; gap: 10px; color: var(--muted); font-size: 12.5px; flex-shrink: 0; }
.prop-meta-stats span { display: inline-flex; align-items: center; gap: 4px; font-variant-numeric: tabular-nums; }
.home-page .home-prop-card .prop-meta { margin-top: 8px; padding-top: 8px; border-top-color: var(--home-border); }
.home-page .home-prop-card .mini-chip { font-size: 10.5px; padding: 1px 8px; }
.home-page .home-prop-card .prop-meta-stats { font-size: 11.5px; }

/* ---- Home: Property Near Transit (slide 3) + area counts ---- */
.home-heading-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; text-align: left; }
.home-heading-row > div { text-align: left; }
.home-heading-row .home-gold-rule { margin-left: 0; }
.section-link { display: inline-flex; align-items: center; gap: 4px; min-height: 44px; padding: 0 4px; font-weight: 500; color: var(--green-800); font-size: 14px; text-decoration: underline; text-underline-offset: 4px; white-space: nowrap; }
.section-link:hover { color: var(--gold-600); }
.transit-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 14px; }
.transit-tile {
  display: grid; justify-items: center; gap: 6px; padding: 16px 8px 14px; border: 1.5px solid var(--line); border-radius: 12px;
  background: var(--surface); color: var(--ink); text-align: center; transition: transform 0.15s, box-shadow 0.15s;
}
.transit-tile:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); }
.transit-tile.is-empty { opacity: 0.6; }
.transit-logo {
  width: 56px; height: 56px; border-radius: 50%; background: var(--line); color: var(--line-ink, var(--surface)); display: grid; place-items: center;
  font-weight: 800; font-size: 15px; letter-spacing: 0.02em; box-shadow: inset 0 0 0 3px rgb(255 255 255 / 0.4); flex-shrink: 0;
}
.transit-name { font-weight: 500; font-size: 13.5px; line-height: 1.3; }
.home-page .loc-card .loc-name { display: block; }
.loc-counts { display: flex; gap: 6px; margin-top: 6px; }
.loc-count { font-size: 11px; font-weight: 600; padding: 2px 9px; border-radius: 6px; color: var(--surface); text-shadow: none; }
.loc-count-sale, .loc-count-rent { background: var(--ok); }

/* ---- Listings: active filter chips (line / station / area) ---- */
.listing-count { color: var(--muted); font-size: 13.5px; margin: 4px 0 24px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }

/* ---- /transit and /areas pages ---- */
.page-head { margin: 8px 0 22px; }
.page-head h1 { font-size: clamp(1.4rem, 3vw, 1.9rem); color: var(--green-950); margin-bottom: 4px; }
.page-head p { color: var(--muted); margin: 0; }
.transit-page, .areas-page, .legal-page, .contact-page { padding-bottom: 56px; }
.transit-line { border: 1px solid var(--border); border-radius: var(--r-lg); padding: 16px 18px; margin-bottom: 16px; background: var(--surface); }
.transit-line-head { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; flex-wrap: wrap; }
.transit-line-head h2 { font-size: 17px; margin: 0; }
.transit-line-head h2 a { color: var(--green-950); }
.transit-line-sub { margin: 0; color: var(--muted); font-size: 13px; }
.transit-line-all { margin-left: auto; }
.station-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.station-chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border: 1px solid var(--border); border-radius: var(--r-pill); font-size: 13px; color: var(--ink); background: var(--surface); }
.station-chip:hover { border-color: var(--line); background: var(--cream); }
.station-chip.is-empty { color: var(--muted); }
.station-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--line); }
.area-search { position: relative; max-width: 520px; margin-bottom: 20px; }
.area-search svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.area-search .input { padding-left: 42px; }
.area-group-title { font-size: 18px; color: #14614d; margin-bottom: 12px; }
.area-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.area-row { display: grid; grid-template-columns: 164px 1fr; gap: 18px; align-items: center; padding-bottom: 14px; border-bottom: 1px solid var(--border); }
@media (max-width: 639px) { .area-row { grid-template-columns: 110px 1fr; gap: 12px; } }
.area-thumb { display: block; border-radius: var(--r-md); overflow: hidden; aspect-ratio: 164 / 120; background: var(--green-100); }
.area-thumb img { width: 100%; height: 100%; object-fit: cover; }
.area-thumb-ph { width: 100%; height: 100%; display: grid; place-items: center; color: var(--green-700); }
.area-body h3 { font-size: 18px; margin: 0; }
.area-body h3 a { color: var(--green-950); }
.area-alt { color: var(--muted); font-size: 13.5px; margin: 2px 0 8px; min-height: 1em; }
.area-counts { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.count-pill { padding: 7px 12px; border-radius: 6px; display: inline-flex; align-items: center; min-height: 36px; color: var(--surface); font-size: 12.5px; font-weight: 600; }
.count-pill:hover { filter: brightness(0.92); color: var(--surface); }
.count-sale, .count-rent { background: var(--ok); }
.count-total { color: #1f7a4f; font-size: 12.5px; display: inline-flex; align-items: center; gap: 4px; }

/* ---- Detail: header extras, share, move-in cost (slide 4), loan (slide 5), price analysis (slide 6), minimal form (slide 8) ---- */
.detail-views { display: inline-flex; align-items: center; gap: 4px; }
.f-yield .f-value { color: var(--danger-600); }
.share-short { display: block; font-size: 11.5px; color: var(--muted); text-align: center; word-break: break-all; }
.cost-section { margin: 4px 0 24px; }
.cost-title { font-size: 17px; color: var(--green-950); margin-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.cost-box { border: 1px solid var(--border); border-radius: var(--r-lg); overflow: hidden; background: var(--surface); }
.cost-box > summary { list-style: none; display: flex; justify-content: space-between; align-items: center; padding: 12px 18px; font-weight: 700; font-size: 16px; background: var(--cream); cursor: pointer; color: var(--green-950); }
.cost-box > summary::-webkit-details-marker { display: none; }
.cost-box > summary svg { transition: transform 0.15s; }
.cost-box[open] > summary svg { transform: rotate(180deg); }
.cost-table { width: 100%; border-collapse: collapse; }
.cost-table td, .cost-table th { padding: 9px 18px; text-align: left; font-size: 14.5px; }
.cost-table td:last-child { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.cost-table td svg { vertical-align: -2px; }
.cost-group th { padding-top: 14px; font-size: 15px; color: var(--green-950); border-top: 1px solid var(--border); }
.cost-table tr:first-child th { border-top: none; }
.cost-sub td { color: var(--muted); font-size: 13.5px; border-bottom: 1px dashed var(--border); }
.cost-total td { background: var(--cream); font-weight: 700; font-size: 16px; color: var(--green-900); border-top: 2px solid var(--border); padding: 12px 18px; }
.cost-notes { margin: 0; padding: 12px 18px 14px; list-style: none; background: var(--surface-alt-2); color: var(--muted); font-size: 12.5px; line-height: 1.6; }
.cost-notes-inline { font-size: 12px; color: var(--muted); margin: 10px 0 0; }
.loan-section { margin: 0 0 26px; }
.loan-grid { display: grid; gap: 14px; }
@media (min-width: 760px) { .loan-grid { grid-template-columns: 1fr 1fr; } }
.loan-card { border: 1px solid var(--border); border-radius: var(--r-lg); overflow: hidden; background: var(--surface); box-shadow: var(--shadow-1); }
.loan-head { background: var(--green-900); color: var(--gold-300); font-weight: 700; padding: 10px 16px; text-align: center; font-size: 15px; }
.loan-body { padding: 14px 16px 16px; display: grid; gap: 10px; }
.loan-field { display: grid; gap: 4px; font-size: 13px; color: var(--muted); text-align: center; }
.loan-field .input { font-weight: 600; color: var(--green-950); }
.loan-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.loan-btn { justify-self: center; }
.loan-results { margin: 6px 0 0; display: grid; gap: 4px; }
.loan-results > div { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; padding: 5px 0; border-bottom: 1px dashed var(--border); }
.loan-results dt { color: var(--green-900); font-weight: 600; }
.loan-results dd { margin: 0; font-variant-numeric: tabular-nums; color: var(--price); font-weight: 600; white-space: nowrap; }
.loan-result-main dd b { font-size: 18px; }
.loan-price { margin: 0; text-align: center; font-size: 13.5px; color: var(--muted); }
.loan-price b { color: var(--price); }
.loan-verdict { display: flex; align-items: center; gap: 8px; font-weight: 700; margin: 4px 0 0; font-size: 14px; }
.loan-verdict.is-short, b.is-short { color: var(--danger); }
.loan-verdict.is-ok, b.is-ok { color: var(--ok); }
.loan-note { font-size: 12px; color: var(--muted); margin: 0; }
.compare-section { margin: 8px 0 32px; }
.compare-title { text-align: center; font-size: 1.3rem; color: var(--green-950); margin-bottom: 16px; }
.cmp-carousel { position: relative; margin-bottom: 22px; }
.cmp-row { display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 4px 12px; margin: 0 -4px; scrollbar-width: thin; scrollbar-color: var(--gold-500) transparent; }
.cmp-card { flex: 0 0 min(300px, 78vw); scroll-snap-align: start; border: 1px solid var(--border); border-radius: var(--r-md); overflow: hidden; background: var(--surface); color: var(--ink); box-shadow: var(--shadow-1); transition: transform 0.15s; }
.cmp-card:hover { transform: translateY(-3px); }
.cmp-photo { position: relative; aspect-ratio: 16 / 9; background: var(--green-100); }
.cmp-photo img { width: 100%; height: 100%; object-fit: cover; }
.cmp-code { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); background: var(--danger-600); color: var(--surface); font-size: 12.5px; font-weight: 700; padding: 6px 14px; border-radius: 6px; display: inline-flex; gap: 6px; align-items: center; box-shadow: var(--shadow-2); }
.cmp-body { padding: 10px 14px 12px; }
.cmp-pricerow { display: flex; align-items: center; gap: 10px; border-bottom: 1px solid var(--border); padding-bottom: 8px; margin-bottom: 8px; }
.cmp-deal { background: #7b2d8e; color: var(--surface); font-size: 11px; font-weight: 800; padding: 2px 10px; border-radius: 4px; }
.cmp-price { color: var(--info); font-weight: 700; font-size: 16px; }
.cmp-price small { font-size: 11px; color: var(--muted); font-weight: 500; margin-left: 2px; }
.cmp-facts { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 13px; }
.cmp-facts span { display: inline-flex; align-items: center; gap: 4px; }
.pa-box { border: 1px solid var(--border); border-radius: var(--r-lg); padding: 18px 20px 16px; background: var(--surface); }
.pa-box h3 { font-size: 18px; color: var(--green-950); display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.pa-sentence { margin: 0 0 12px; font-size: 15px; line-height: 1.75; }
.pa-range { margin: 34px 8px 6px; }
.pa-track { position: relative; height: 10px; border-radius: 999px; background: linear-gradient(90deg, #2e9e6a, var(--warn), var(--danger-600)); }
.pa-mark { position: absolute; top: 50%; transform: translate(-50%, -50%); display: grid; justify-items: center; }
.pa-mark i { display: block; width: 16px; height: 16px; border-radius: 50%; background: var(--surface); border: 3px solid var(--green-900); box-shadow: var(--shadow-1); }
.pa-mark b { position: absolute; top: 20px; white-space: nowrap; font-size: 11.5px; color: var(--muted); font-weight: 600; }
.pa-mark-this i { border-color: var(--price); width: 20px; height: 20px; }
.pa-mark-this b { top: -30px; color: var(--price); background: var(--surface); padding: 1px 8px; border-radius: 6px; border: 1px solid var(--border); box-shadow: var(--shadow-1); }
.pa-ends { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); margin-top: 28px; }
.pa-sqm { margin: 12px 0 0; color: var(--info); font-size: 13.5px; }
.contact-brand { display: block; font-family: var(--font-display); color: var(--gold-600); font-size: 0.55em; letter-spacing: 0.12em; margin-top: 2px; }
.contact-lead { font-size: 15.5px; line-height: 1.8; max-width: 560px; }
.contact-hours { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 13.5px; margin: 0; }
.qr-card { justify-self: center; background: var(--surface); border-radius: 18px; overflow: hidden; box-shadow: var(--shadow-2); width: 220px; margin-bottom: 8px; }
.qr-svg { padding: 14px; }
.qr-svg svg { width: 100%; height: auto; display: block; }
.contact-big-btn { display: grid; grid-template-columns: 48px 1fr; align-items: center; gap: 10px; padding: 12px 18px; border-radius: 12px; color: var(--surface); box-shadow: var(--shadow-1); transition: transform 0.12s, filter 0.12s; }
.contact-big-btn:hover { transform: translateY(-2px); filter: brightness(1.05); color: var(--surface); }
.cb-icon { width: 48px; height: 48px; border-radius: 50%; background: rgb(255 255 255 / 0.18); display: grid; place-items: center; }
.cb-text { display: grid; text-align: center; line-height: 1.3; }
.cb-text b { font-size: 19px; font-weight: 700; }
.cb-text span { font-size: 13.5px; opacity: 0.95; word-break: break-all; }
.contact-btn-line { background: var(--line-brand); }

/* ---- Legal pages (slide 9) ---- */
.legal-doc { max-width: 820px; }
.legal-doc h1 { font-size: clamp(1.5rem, 3vw, 2rem); color: var(--green-950); margin: 8px 0 4px; }
.legal-meta { color: var(--muted); font-size: 13px; margin-bottom: 24px; }
.legal-doc section { margin-bottom: 22px; }
.legal-doc h2 { font-size: 17px; color: var(--green-900); margin-bottom: 8px; }
.legal-doc p, .legal-doc li { font-size: 15px; line-height: 1.8; }
.legal-doc ul { padding-left: 22px; margin: 0; }
.legal-contact { background: var(--cream); border-radius: var(--r-md); padding: 14px 18px; }

/* ---- Admin: notifications bell, nav badges, users, image download ---- */
.admin-topbar-inner { position: relative; }
.role-pill { display: inline-block; padding: 1px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 600; background: rgb(107 122 116 / 0.15); color: var(--muted); }
.role-pill.role-owner { background: rgb(201 162 75 / 0.22); color: var(--gold-700); }
.role-pill.role-agent { background: rgb(42 120 214 / 0.14); color: var(--info-700); }
.upload-item .dl-btn { position: absolute; bottom: 4px; right: 4px; height: 24px; padding: 0 8px; border-radius: 6px; background: rgb(14 33 28 / 0.85); color: var(--surface); border: none; cursor: pointer; font-size: 11px; font-weight: 700; display: inline-flex; align-items: center; gap: 4px; }
.upload-item .dl-btn:hover { background: var(--gold-500); color: var(--green-950); }
.stats-matrix td.num, .stats-matrix th.num { text-align: right; font-variant-numeric: tabular-nums; }
.stats-matrix .total { font-weight: 700; background: var(--cream); }
.perm-note { display: flex; gap: 8px; align-items: flex-start; background: rgb(201 162 75 / 0.12); border: 1px solid rgb(201 162 75 / 0.4); color: var(--gold-600); border-radius: var(--r-md); padding: 10px 14px; font-size: 13px; margin-bottom: 14px; }
.perm-note svg { flex-shrink: 0; margin-top: 2px; }
.search-hint { font-size: 12px; color: var(--muted); margin: 6px 0 0; width: 100%; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12.5px; }
@media (min-width: 1100px) {
  .transit-row { grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 10px; }
  .transit-tile { padding: 14px 6px 12px; }
  .transit-logo { width: 50px; height: 50px; font-size: 14px; }
  .transit-name { font-size: 12.5px; }
}

/* ---- Google Sign-In (admin login) ---- */
.btn-google { background: var(--surface); color: #1f1f1f; border: 1px solid #dadce0; font-weight: 600; gap: 10px; box-shadow: 0 1px 2px rgba(0,0,0,.06); }
.btn-google:hover { background: #f8f9fa; border-color: #c6c8cb; }
.login-hint { color: var(--muted); font-size: 12.5px; text-align: center; margin: 10px 0 14px; }
.admin-avatar { border-radius: 50%; vertical-align: middle; margin-right: 6px; }
.field-hint { color: var(--muted); font-size: 12px; margin-top: 4px; }

/* ---- Admin tables: sortable headers + pager ---- */
.data-table th.sortable { padding: 0; }
.data-table th.sortable a { display: flex; align-items: center; gap: 5px; padding: 10px 14px; color: inherit; text-decoration: none; white-space: nowrap; }
.data-table th.sortable a:hover { background: rgb(21 58 45 / 0.08); }
.data-table th.sortable .sort-caret { font-size: 10px; opacity: 0.35; }
.data-table th.sorted .sort-caret { opacity: 1; color: var(--gold-700); }
.data-table th.sorted a { color: var(--green-950); }
.pager { display: flex; flex-wrap: wrap; gap: 10px 18px; align-items: center; padding: 12px 4px 2px; font-size: 13px; color: var(--muted); }
.pager-bottom { padding: 14px 4px 4px; border-top: 1px solid var(--border); margin-top: 4px; }
.pager-info b { color: var(--green-900); }
.pager-clear { margin-left: 4px; color: var(--danger); }
.pager-per { display: flex; gap: 4px; align-items: center; }
.pager-per a { padding: 6px 10px; min-height: 36px; display: inline-flex; align-items: center; border-radius: 6px; border: 1px solid transparent; color: var(--green-800); text-decoration: none; }
.pager-per a.current { border-color: var(--green-800); font-weight: 700; }
.pager-pages { display: flex; gap: 4px; margin-left: auto; align-items: center; }
.pager-btn { min-width: 40px; height: 40px; padding: 0 8px; display: inline-flex; align-items: center; justify-content: center; border-radius: 8px; border: 1px solid var(--border); background: var(--surface); color: var(--green-900); text-decoration: none; font-weight: 600; }
.pager-btn:hover { border-color: var(--green-800); }
.pager-btn.current { background: var(--green-900); color: var(--surface); border-color: var(--green-900); }
.pager-btn.disabled { pointer-events: none; opacity: 0.35; }
.pager-gap { padding: 0 4px; }
.table-tools { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 10px; }
.table-tools .input { max-width: 300px; min-height: 36px; padding: 6px 12px; font-size: 13px; }
table[data-sortable] th[data-sort-col] { cursor: pointer; user-select: none; }
table[data-sortable] th[data-sort-col]::after { content: ' ⇅'; font-size: 10px; opacity: 0.35; }
table[data-sortable] th[data-sort-col].sorted-asc::after { content: ' ▲'; opacity: 1; }
table[data-sortable] th[data-sort-col].sorted-desc::after { content: ' ▼'; opacity: 1; }

/* ---- Admin property filters (one box per field) ---- */
.filter-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 12px; }
@media (min-width: 760px) { .filter-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1200px) { .filter-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
.filter-field { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.filter-field > span { font-size: 12px; font-weight: 600; color: var(--green-800); }
.filter-field .input, .filter-field .select { min-height: 38px; padding: 6px 10px; font-size: 13.5px; width: 100%; }
.filter-field.span-2 { grid-column: span 2; }
.filter-range { display: flex; align-items: center; gap: 6px; }
.filter-range > span { color: var(--muted); }
.filter-range input { min-width: 0; }
.filter-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 12px; }

/* ---- Table row action buttons: always one horizontal row ---- */
.row-actions { display: flex; gap: 6px; flex-wrap: nowrap; align-items: center; white-space: nowrap; }
.row-actions form { display: inline; margin: 0; }
.row-actions details { position: relative; }
.row-actions details > form { position: absolute; right: 0; top: calc(100% + 4px); z-index: 5; background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 8px; box-shadow: var(--shadow-2); display: flex; gap: 6px; }

/* ---- Contact sheet (floating "Contact us" + property page): direct channels only ---- */
.contact-sheet { display: grid; gap: 10px; }
.contact-sheet .btn { justify-content: center; min-height: 46px; font-size: 15px; }

/* ---- Home search typeahead ---- */
.hero-search-wrap { position: relative; width: min(100%, 760px); margin: 0 auto; }
.hero-search-wrap .hero-search { width: 100%; }
.typeahead-panel {
  position: absolute; left: 12px; right: 12px; top: calc(100% + 8px); z-index: 30; text-align: left;
  background: var(--surface); border-radius: 18px; box-shadow: 0 18px 48px rgb(14 33 28 / 0.22), 0 2px 8px rgb(14 33 28 / 0.08);
  border: 1px solid rgb(23 56 47 / 0.08); padding: 8px; max-height: min(60vh, 440px); overflow-y: auto;
  animation: ta-in .14s ease-out;
}
@keyframes ta-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.typeahead-group { font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 10px 12px 4px; }
.typeahead-item {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; border: none; background: transparent;
  padding: 9px 12px; border-radius: 12px; cursor: pointer; font-family: var(--font-body); color: var(--ink);
}
.typeahead-item:hover, .typeahead-item.is-active { background: rgb(23 56 47 / 0.06); }
.typeahead-item.is-active { outline: 2px solid rgb(23 56 47 / 0.18); outline-offset: -2px; }
.ta-icon { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0; }
.ta-project { background: rgb(201 162 75 / 0.16); color: var(--gold-600); }
.ta-area { background: rgb(30 122 70 / 0.12); color: var(--green-800); }
.ta-station { background: rgb(42 120 214 / 0.12); color: var(--info-700); }
.ta-text { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.3; }
.ta-label { font-size: 15px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ta-label mark { background: transparent; color: var(--green-900); text-decoration: underline; text-decoration-color: var(--gold-500); text-underline-offset: 3px; text-decoration-thickness: 2px; }
.ta-sub { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ta-count { font-size: 12px; color: var(--muted); white-space: nowrap; background: rgb(23 56 47 / 0.05); padding: 3px 9px; border-radius: 999px; }
.typeahead-empty { padding: 14px 12px; font-size: 13.5px; color: var(--muted); }
.hero-search-wrap.is-open .hero-search { box-shadow: 0 0 0 3px rgb(201 162 75 / 0.85), 0 14px 36px rgb(14 33 28 / 0.22); }
@media (max-width: 600px) { .typeahead-panel { left: 0; right: 0; } .ta-count { display: none; } }

/* ---- select2-like dropdowns (public/js/select.js) ---- */
.ps-select { position: relative; display: inline-block; width: 100%; min-width: 0; vertical-align: middle; }
.ps-select-native { position: absolute !important; width: 1px !important; height: 1px !important; opacity: 0; pointer-events: none; margin: 0; padding: 0; border: 0; overflow: hidden; clip: rect(0 0 0 0); }
.ps-select-btn {
  display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; min-height: 42px;
  padding: 8px 12px 8px 14px; border: 1px solid var(--border); border-radius: var(--r-md); background: var(--surface);
  font-family: var(--font-body); font-size: 14.5px; color: var(--ink); text-align: left; cursor: pointer;
  transition: border-color .15s, box-shadow .15s;
}
.ps-select-btn:hover { border-color: rgb(23 56 47 / 0.35); }
.ps-select-btn:focus-visible, .ps-select.is-open .ps-select-btn { outline: none; border-color: var(--green-800); box-shadow: 0 0 0 3px rgb(30 122 70 / 0.16); }
.ps-select-btn.is-placeholder { color: var(--muted); }
.ps-select-text { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ps-select-caret { display: grid; place-items: center; color: var(--muted); transition: transform .2s; flex-shrink: 0; }
.ps-select.is-open .ps-select-caret { transform: rotate(180deg); color: var(--green-800); }
.ps-select.is-disabled .ps-select-btn { opacity: .55; cursor: not-allowed; }
.ps-select-panel {
  position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 60; min-width: 180px;
  background: var(--surface); border: 1px solid rgb(23 56 47 / 0.1); border-radius: 14px; padding: 6px;
  box-shadow: 0 16px 40px rgb(14 33 28 / 0.18), 0 2px 6px rgb(14 33 28 / 0.08);
  animation: ps-select-in .14s ease-out;
}
.ps-select.is-up .ps-select-panel { top: auto; bottom: calc(100% + 6px); }
@keyframes ps-select-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.ps-select-search {
  width: 100%; box-sizing: border-box; margin: 2px 0 6px; padding: 8px 12px; border: 1px solid var(--border); border-radius: 10px;
  font-family: var(--font-body); font-size: 14px; background: var(--surface-alt);
}
.ps-select-search:focus { outline: none; border-color: var(--green-800); background: var(--surface); }
.ps-select-list { max-height: 280px; overflow-y: auto; overscroll-behavior: contain; }
.ps-select-group { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 8px 12px 4px; }
.ps-select-opt { padding: 9px 12px; border-radius: 9px; font-size: 14.5px; cursor: pointer; display: flex; align-items: center; gap: 8px; }
.ps-select-opt.is-active { background: rgb(23 56 47 / 0.07); }
.ps-select-opt.is-selected { color: var(--green-900); font-weight: 600; }
.ps-select-opt.is-selected::after { content: '✓'; margin-left: auto; color: var(--gold-600, var(--gold-deep)); font-size: 13px; }
.ps-select-opt.is-disabled { opacity: .45; cursor: not-allowed; }
.ps-select-empty { padding: 12px; color: var(--muted); font-size: 13.5px; }
/* contexts that used to size the native select */
.filterbar .ps-select, .admin-toolbar .ps-select, .table-tools .ps-select, .row-actions .ps-select { width: auto; }
.filterbar .ps-select .ps-select-btn { min-height: 42px; }
.row-actions .ps-select .ps-select-btn, td .ps-select .ps-select-btn { min-height: 34px; padding: 4px 10px; font-size: 13px; }
.filter-field .ps-select-btn { min-height: 38px; padding: 6px 10px 6px 12px; font-size: 13.5px; }
.home-page .ps-select-btn { min-height: 42px; }
@media (prefers-reduced-motion: reduce) { .ps-select-panel { animation: none; } .ps-select-caret { transition: none; } }

/* comfortable tap targets for footer, list and inline action links */
.footer a:not(.social-row a):not(.footer-brand a), .footer .legal-links a { display: inline-block; padding: 8px 0; }
.transit-line-head a, .transit-stations a, .area-row a, .area-body a, .chart-link, .section-link { display: inline-flex; align-items: center; min-height: 36px; }
.del-btn, .dl-btn { min-width: 32px; min-height: 32px; }
@media (max-width: 639px) { .nav-menu a { min-height: 44px; display: inline-flex; align-items: center; } .btn-sm { min-height: 40px; } }

/* light line colours (BTS Sukhumvit, Gold, Yellow, BRT) need dark badge text */
[data-line='bts_sukhumvit'] .transit-logo, [data-line='bts_gold'] .transit-logo, [data-line='mrt_yellow'] .transit-logo, [data-line='brt'] .transit-logo { color: #12321f; }

/* section headings inside the property page (h2 semantics, sub-heading look) */
.detail-layout .sec-h { font-size: 17px; color: var(--green-900); margin: 0 0 10px; }

/* ============ Admin: home page tiles (/admin/home-categories) ============ */
.data-table .thumb.thumb-wide { width: 84px; height: 63px; aspect-ratio: 4 / 3; }
.data-table td:has(> .thumb-wide) { width: 100px; min-width: 100px; }
.row-muted td { opacity: 0.55; }
.row-muted td:last-child { opacity: 1; }
.order-num { display: inline-block; min-width: 22px; text-align: center; font-weight: 700; color: var(--green-900); }
.btn.btn-icon { padding: 6px 8px; min-width: 34px; }
.btn.btn-icon[disabled] { opacity: 0.35; cursor: default; }
.icon-chip { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--green-100); color: var(--green-800); }
.cat-en-cell { font-weight: 700; letter-spacing: 0.04em; color: var(--green-900); text-decoration: none; }
.cat-en-cell:hover { text-decoration: underline; }
.cat-preview {
  position: relative; width: min(100%, 320px); aspect-ratio: 4 / 3; border-radius: var(--r-lg); overflow: hidden;
  background: linear-gradient(160deg, var(--green-800), var(--green-950)); color: var(--surface); box-shadow: 0 6px 20px rgb(21 45 38 / 0.11); margin-bottom: 12px;
}
.cat-preview img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cat-preview::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgb(14 33 28 / 0.05) 35%, rgb(14 33 28 / 0.88)); }
.upload-drop-sm { padding: 16px; }
.upload-drop.is-over { border-color: var(--gold-500); background: var(--green-100); }
.icon-select label { gap: 6px; font-size: 13px; }
.chk { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; color: var(--green-900); cursor: pointer; }
.chk input { width: 18px; height: 18px; accent-color: var(--green-800); }
.sticky-actions { position: sticky; bottom: 0; background: var(--surface-alt, var(--bg)); padding: 12px 0; margin-top: 18px; border-top: 1px solid var(--border); z-index: 2; }
.admin-page-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.admin-page-head h1 { margin: 0; }

/* ============ Admin: crop + resize dialog (public/js/cropper.js) ============ */
dialog.crop-modal { border: none; border-radius: var(--r-lg); padding: 18px 20px 20px; width: min(780px, calc(100vw - 24px)); max-height: calc(100dvh - 24px); box-shadow: var(--shadow-3); background: var(--surface); color: var(--ink); }
dialog.crop-modal::backdrop { background: rgb(14 33 28 / 0.65); }
.crop-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.crop-head h2 { font-size: 17px; color: var(--green-900); margin: 0; }
.crop-meta { font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.crop-stage { display: grid; place-items: center; background: repeating-conic-gradient(var(--surface-alt) 0% 25%, var(--surface) 0% 50%) 0 0 / 20px 20px; border-radius: var(--r-md); padding: 10px; min-height: 240px; }
.crop-frame { position: relative; overflow: hidden; border-radius: 6px; box-shadow: 0 0 0 2px var(--gold-500), 0 8px 24px rgb(0 0 0 / 0.25); background: var(--green-100); }
.crop-frame canvas { display: block; cursor: grab; touch-action: none; user-select: none; }
.crop-frame canvas:active { cursor: grabbing; }
.crop-grid { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(to right, transparent calc(33.33% - 0.5px), rgb(255 255 255 / 0.45) calc(33.33% - 0.5px), rgb(255 255 255 / 0.45) calc(33.33% + 0.5px), transparent calc(33.33% + 0.5px), transparent calc(66.66% - 0.5px), rgb(255 255 255 / 0.45) calc(66.66% - 0.5px), rgb(255 255 255 / 0.45) calc(66.66% + 0.5px), transparent calc(66.66% + 0.5px)), linear-gradient(to bottom, transparent calc(33.33% - 0.5px), rgb(255 255 255 / 0.45) calc(33.33% - 0.5px), rgb(255 255 255 / 0.45) calc(33.33% + 0.5px), transparent calc(33.33% + 0.5px), transparent calc(66.66% - 0.5px), rgb(255 255 255 / 0.45) calc(66.66% - 0.5px), rgb(255 255 255 / 0.45) calc(66.66% + 0.5px), transparent calc(66.66% + 0.5px)); }
.crop-tools { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-top: 12px; }
.crop-ratios { display: flex; gap: 6px; flex-wrap: wrap; }
.crop-ratio { min-height: 34px; padding: 6px 12px; border-radius: var(--r-pill); border: 1px solid var(--border); background: var(--surface); font-size: 13px; cursor: pointer; color: var(--green-900); }
.crop-ratio.is-active { background: var(--green-900); color: var(--surface); border-color: var(--green-900); }
.crop-zoom { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--green-900); flex: 1 1 200px; }
.crop-zoom input { flex: 1; accent-color: var(--green-800); min-width: 120px; }
.crop-hint { font-size: 12.5px; color: var(--muted); margin: 10px 0 12px; }
.crop-actions { display: flex; gap: 10px; flex-wrap: wrap; }
@media (max-width: 639px) { dialog.crop-modal { padding: 14px; } .crop-actions .btn { flex: 1 1 100%; } }

/* ============ Admin: transit lines (/admin/transit-lines) ============ */
.transit-logo.transit-logo-sm { width: 40px; height: 40px; font-size: 11px; }
.station-preview { font-size: 12px; color: var(--muted); margin-top: 2px; max-width: 260px; }
.color-field { display: flex; gap: 8px; align-items: center; }
.color-field input[type="color"] { width: 48px; height: 44px; padding: 2px; border: 1px solid var(--border); border-radius: var(--r-sm); background: var(--surface); cursor: pointer; }
.color-field .input { max-width: 140px; }
.tl-preview { width: min(100%, 220px); pointer-events: none; }
.data-table .thumb.thumb-tall { width: 60px; height: 80px; aspect-ratio: 3 / 4; }
.data-table td:has(> .thumb-tall) { width: 76px; min-width: 76px; }
.loc-counts-admin { display: inline-flex; gap: 6px; }
.loc-preview { width: min(100%, 240px); margin-bottom: 12px; pointer-events: none; }
.loc-preview { display: block; flex: none; }

/* ============ Listings filter bar (v2) ============ */
.filterbar.lf-bar { padding: 10px 0 8px; border-bottom: 1px solid rgb(23 56 47 / 0.08); box-shadow: 0 8px 24px rgb(14 33 28 / 0.06); }
.filterbar form.lf { display: flex; flex-direction: column; flex-wrap: nowrap; align-items: stretch; gap: 8px; }
.lf-main { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; width: 100%; }

/* deal segment — three radios under one sliding pill */
.lf-deal { position: relative; isolation: isolate; display: grid; grid-template-columns: repeat(3, 1fr); background: rgb(23 56 47 / 0.07); border-radius: var(--r-pill); padding: 4px; flex: 0 0 auto; width: 250px; }
.lf-deal::before { content: ''; position: absolute; top: 4px; bottom: 4px; left: 4px; width: calc((100% - 8px) / 3); border-radius: 999px; background: var(--green-900); box-shadow: 0 4px 12px rgb(23 56 47 / 0.28); transition: transform .42s cubic-bezier(.22, 1, .36, 1); z-index: -1; }
.lf-deal[data-active='sale']::before { transform: translateX(100%); }
.lf-deal[data-active='rent']::before { transform: translateX(200%); }
.lf-deal-opt { position: relative; display: grid; place-items: center; min-height: 38px; padding: 0 10px; border-radius: 999px; font-weight: 600; font-size: 14px; color: var(--green-900); cursor: pointer; user-select: none; transition: color .25s; }
.lf-deal-opt input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.lf-deal-opt:has(input:checked), .lf-deal[data-active='all'] .lf-deal-opt[data-deal='all'], .lf-deal[data-active='sale'] .lf-deal-opt[data-deal='sale'], .lf-deal[data-active='rent'] .lf-deal-opt[data-deal='rent'] { color: var(--surface); }
.lf-deal-opt:has(input:focus-visible) { outline: 2px solid var(--gold-500); outline-offset: 2px; }

/* search box with icon + clear */
.lf-search.hero-search-wrap { flex: 1 1 280px; width: auto; margin: 0; min-width: 0; }
.lf-search-box { position: relative; display: flex; align-items: center; background: var(--surface); border: 1px solid rgb(23 56 47 / 0.18); border-radius: var(--r-pill); min-height: 46px; padding: 0 8px 0 14px; transition: border-color .15s, box-shadow .15s; }
.lf-search-box:hover { border-color: rgb(23 56 47 / 0.35); }
.lf-search-box:focus-within, .lf-search.is-open .lf-search-box { border-color: var(--green-800); box-shadow: 0 0 0 3px rgb(30 122 70 / 0.16); }
.lf-search-icon { display: grid; place-items: center; color: var(--green-800); margin-right: 8px; flex-shrink: 0; }
.lf-q { flex: 1; min-width: 0; border: none; background: transparent; font-family: var(--font-body); font-size: 15px; padding: 8px 0; color: var(--ink); }
.lf-q:focus { outline: none; }
.lf-q::-webkit-search-cancel-button { display: none; }
.lf-q::placeholder { color: var(--muted); }
.lf-clear { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; color: var(--muted); flex-shrink: 0; }
.lf-clear:hover { background: rgb(23 56 47 / 0.08); color: var(--danger); }
.lf-search .typeahead-panel { left: 0; right: 0; }
.lf-submit { min-height: 46px; padding: 0 22px; border-radius: var(--r-pill); gap: 6px; flex-shrink: 0; }
.lf-more { display: none; min-height: 46px; border-radius: var(--r-pill); gap: 6px; }
.lf-badge { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--gold-500); color: var(--green-950); font-size: 11.5px; font-weight: 700; }

/* secondary filters as pills */
.filterbar .collapsible.lf-filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.lf-filters .ps-select { width: auto; max-width: 100%; }
.lf-filters .ps-select-btn, .lf-filters .select.lf-pill { min-height: 38px; padding: 0 12px 0 14px; border-radius: var(--r-pill); font-size: 13.5px; font-weight: 500; background: var(--surface); border: 1px solid rgb(23 56 47 / 0.18); color: var(--green-900); width: auto; }
.lf-filters .ps-select-btn.is-placeholder { color: var(--green-900); }
.lf-filters .ps-select:has(> .is-set) .ps-select-btn, .lf-filters .select.lf-pill.is-set { background: rgb(23 56 47 / 0.08); border-color: var(--green-800); font-weight: 600; }
.lf-filters .ps-select:has(> .is-set) .ps-select-caret { color: var(--green-800); }
.lf-filters .ps-select-panel { min-width: 240px; }
.lf-spacer { flex: 1 1 8px; }
.lf-sort { display: inline-flex; align-items: center; gap: 4px; }
.lf-sort-label { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; color: var(--muted); white-space: nowrap; }
.lf-sort .ps-select-btn, .lf-sort .select { border-color: transparent; background: transparent; font-weight: 600; padding-left: 8px; }
.lf-sort .ps-select-btn:hover { background: rgb(23 56 47 / 0.06); }
.lf-reset { display: inline-flex; align-items: center; gap: 4px; min-height: 38px; padding: 0 10px; border-radius: var(--r-pill); font-size: 13.5px; color: var(--danger-600, var(--danger)); white-space: nowrap; }
.lf-reset:hover { background: var(--danger-soft, rgb(192 57 43 / 0.08)); }

/* active-filter chips */
.lf-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.lf-chip { display: inline-flex; align-items: center; gap: 4px; background: var(--green-900); color: var(--surface); padding: 5px 10px 5px 12px; border-radius: var(--r-pill); font-size: 12.5px; font-weight: 600; transition: background .15s; }
.lf-chip:hover { background: var(--danger); }

@media (max-width: 899px) {
  .lf-deal { width: 100%; }
  .lf-more { display: inline-flex; }
  .lf-submit span, .lf-submit { padding: 0 16px; }
  .filterbar .collapsible.lf-filters { display: none; }
  .filterbar .collapsible.lf-filters.open { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
  .lf-filters .ps-select, .lf-filters .select.lf-pill { width: 100%; }
  .lf-filters .ps-select-btn { width: 100%; }
  .lf-spacer { display: none; }
  .lf-sort { grid-column: 1 / -1; justify-content: space-between; }
  .lf-reset { grid-column: 1 / -1; justify-content: center; }
}
@media (max-width: 480px) {
  .lf-submit { flex: 1 1 auto; }
}
.listing-results { padding-top: 18px; }
.listing-results h1 { margin-bottom: 4px; }
.listing-results .listing-count { margin: 0 0 14px; }

/* ============ Admin: sidebar layout ============ */
.admin-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); min-height: 100dvh; }
.admin-sidebar { position: sticky; top: 0; height: 100dvh; display: flex; flex-direction: column; background: var(--green-900); color: var(--on-dark); border-right: 1px solid rgb(0 0 0 / 0.15); overflow-y: auto; overscroll-behavior: contain; }
.sb-brand { display: flex; align-items: center; gap: 10px; padding: 16px 18px 12px; border-bottom: 1px solid rgb(255 255 255 / 0.08); }
.sb-brand .brand-sm { display: flex; align-items: center; }
.sb-brand .brand-sm img { height: 42px; width: auto; }
.sb-brand-sub { font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--on-dark-muted); margin-left: auto; }
.sb-close { display: none; margin-left: auto; width: 36px; height: 36px; border-radius: 50%; border: none; background: rgb(255 255 255 / 0.08); color: var(--on-dark); cursor: pointer; place-items: center; }
.sb-nav { padding: 12px 12px 8px; display: flex; flex-direction: column; gap: 14px; flex: 1; }
.sb-group { display: flex; flex-direction: column; gap: 2px; }
.sb-group-title { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--on-dark-muted); padding: 6px 12px 6px; }
.sb-link { display: flex; align-items: center; gap: 10px; min-height: 40px; padding: 8px 12px; border-radius: var(--r-sm); color: var(--on-dark); font-size: 14px; font-weight: 500; text-decoration: none; transition: background .15s, color .15s; }
.sb-link:hover { background: rgb(255 255 255 / 0.07); color: var(--surface); }
.sb-link.is-active { background: var(--green-800); color: var(--gold-300); font-weight: 600; box-shadow: inset 3px 0 0 var(--gold-500); }
.sb-ico { display: grid; place-items: center; width: 20px; color: inherit; opacity: .9; flex-shrink: 0; }
.sb-link-muted { color: var(--on-dark-muted); }
.sb-foot { padding: 10px 12px 16px; border-top: 1px solid rgb(255 255 255 / 0.08); display: flex; flex-direction: column; gap: 6px; }
.sb-user { display: flex; align-items: center; gap: 10px; padding: 8px 12px; }
.sb-user .admin-avatar { width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0; }
.admin-avatar-ph { display: grid; place-items: center; background: var(--gold-500); color: var(--green-950); font-weight: 700; }
.sb-user-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; font-size: 13px; }
.sb-user-text b { color: var(--gold-300); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sb-user-text .role-pill { align-self: flex-start; }
.admin-sidebar .role-pill.role-owner { color: var(--gold-300); background: rgb(239 197 123 / 0.16); }
.admin-sidebar .role-pill.role-agent { color: var(--info-soft); background: rgb(191 224 255 / 0.14); }
.sb-logout { display: inline-flex; align-items: center; gap: 6px; width: 100%; min-height: 38px; padding: 6px 12px; border-radius: var(--r-sm); border: 1px solid rgb(255 255 255 / 0.18); background: transparent; color: var(--on-dark); font-family: inherit; font-size: 13px; cursor: pointer; }
.sb-logout:hover { background: rgb(255 255 255 / 0.08); color: var(--surface); }
.admin-mobilebar { display: none; }
.sb-backdrop { position: fixed; inset: 0; background: rgb(14 33 28 / 0.55); z-index: 140; }

@media (max-width: 1023px) {
  .admin-layout { grid-template-columns: 1fr; }
  .admin-mobilebar { display: flex; align-items: center; gap: 12px; position: sticky; top: 0; z-index: 100; height: 56px; padding: 0 12px; background: var(--green-900); border-bottom: 2px solid var(--gold-500); }
  .admin-mobilebar .brand-sm img { height: 34px; width: auto; }
  .admin-mobile-title { color: var(--on-dark); font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .sb-toggle { width: 40px; height: 40px; border-radius: var(--r-sm); border: none; background: rgb(255 255 255 / 0.08); color: var(--on-dark); display: grid; place-items: center; cursor: pointer; flex-shrink: 0; }
  .admin-sidebar { position: fixed; top: 0; left: 0; width: min(300px, 86vw); height: 100dvh; z-index: 150; transform: translateX(-100%); transition: transform .28s cubic-bezier(.22, 1, .36, 1); box-shadow: 0 20px 60px rgb(0 0 0 / 0.35); }
  .admin-sidebar.is-open { transform: none; }
  .sb-close { display: grid; }
  .sb-brand-sub { display: none; }
  .admin-main { padding: 18px 14px 60px; }
  body.sb-open { overflow: hidden; }
}

/* ============ Featured ("ทรัพย์แนะนำ") ============ */
.badge.badge-featured { left: auto; right: 12px; background: var(--gold-500); color: var(--green-950); box-shadow: 0 4px 12px rgb(0 0 0 / 0.18); }
.status-pill.status-featured { background: rgb(201 162 75 / 0.22); color: var(--gold-600); }
.btn.btn-gold { background: var(--gold-500); color: var(--green-950); border-color: var(--gold-500); }
.btn.btn-gold:hover { background: var(--gold-300); }
.home-featured { background: var(--cream, #f7f4ec); }
.home-page .home-prop-card .badge.badge-featured, .prop-card .badge.badge-featured { left: auto; right: 10px; width: auto; background: var(--gold-500); color: var(--green-950); font-weight: 700; padding: 3px 12px; border-radius: 999px; }

/* ============ Contact page (v2) ============ */
.contact-page { padding-bottom: 0; }
.contact-hero { position: relative; background: linear-gradient(135deg, var(--green-900) 0%, var(--green-950) 60%, var(--green-900) 100%); color: var(--surface); overflow: hidden; isolation: isolate; }
.contact-hero::before { content: ''; position: absolute; inset: 0; background: var(--hero-image, url('/img/modern-premium/hero.jpg')) center / cover no-repeat; opacity: .18; z-index: -1; }
.contact-hero::after { content: ''; position: absolute; inset: auto 0 0 0; height: 2px; background: linear-gradient(90deg, transparent, var(--gold-500), transparent); }
.contact-hero-inner { padding: 56px 16px 52px; }
.contact-hero-text { max-width: 640px; }
.contact-hero h1 { font-size: clamp(1.9rem, 4vw, 2.7rem); line-height: 1.15; margin: 0 0 14px; color: var(--surface); }
.contact-hero .contact-brand { display: block; font-family: var(--font-display); color: var(--gold-300); font-size: .5em; letter-spacing: .16em; margin-top: 8px; font-weight: 600; }
.contact-hero .contact-lead { color: rgb(255 255 255 / 0.82); font-size: 16px; line-height: 1.8; max-width: 58ch; margin: 0 0 16px; }
.contact-hero-meta { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-bottom: 22px; }
.contact-hero .contact-hours { color: rgb(255 255 255 / 0.78); font-size: 13.5px; }
.contact-hero .contact-hours svg { color: var(--gold-300); }
.contact-hero-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.contact-hero-line { background: var(--line-brand); color: var(--surface); border-color: var(--line-brand); gap: 8px; min-height: 48px; padding: 0 22px; border-radius: var(--r-pill); font-size: 15px; }
.contact-hero-line:hover { background: var(--line-brand-700); color: var(--surface); }
.contact-hero-call { background: rgb(255 255 255 / 0.1); color: var(--surface); border-color: rgb(255 255 255 / 0.3); gap: 8px; min-height: 48px; padding: 0 20px; border-radius: var(--r-pill); font-size: 15px; }
.contact-hero-call:hover { background: rgb(255 255 255 / 0.18); color: var(--surface); }

.contact-body { display: grid; gap: 32px; padding: 40px 16px 48px; }
@media (min-width: 960px) {
  .contact-body { grid-template-columns: minmax(0, 1fr) 360px; grid-template-areas: 'main qr' 'steps qr'; gap: 36px 48px; align-items: start; }
  .contact-channels { grid-area: main; }
  .contact-qr { grid-area: qr; }
  .contact-steps { grid-area: steps; }
}
.contact-h2 { font-size: 20px; color: var(--green-950); margin: 0 0 14px; display: flex; align-items: center; gap: 12px; }
.contact-h2::after { content: ''; flex: 1; height: 1px; background: var(--border); }

.channel-list { list-style: none; margin: 0 0 32px; padding: 0; display: grid; gap: 12px; }
.channel { display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: 4px 16px; align-items: center; padding: 18px 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: 0 2px 10px rgb(20 40 34 / 0.05); transition: box-shadow .18s, transform .18s; }
.channel:hover { box-shadow: var(--shadow-2); transform: translateY(-1px); }
@media (min-width: 640px) { .channel { grid-template-columns: 52px minmax(0, 1fr) auto; } }
.channel-ico { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; color: var(--surface); grid-row: 1 / span 2; }
@media (min-width: 640px) { .channel-ico { grid-row: auto; } }
.channel-line .channel-ico { background: var(--line-brand); }
.channel-phone .channel-ico { background: var(--green-800); }
.channel-mail .channel-ico { background: var(--gold-600); }
.channel-text { display: flex; flex-direction: column; min-width: 0; gap: 1px; }
.channel-label { font-size: 12.5px; color: var(--muted); font-weight: 600; letter-spacing: .02em; }
.channel-value { font-size: 20px; font-weight: 700; color: var(--green-950); font-variant-numeric: tabular-nums; word-break: break-word; }
.channel-value-email { font-size: 17px; }
.channel-note { font-size: 13px; color: var(--muted); }
.channel-actions { display: flex; gap: 8px; flex-wrap: wrap; grid-column: 2; margin-top: 6px; }
@media (min-width: 640px) { .channel-actions { grid-column: auto; margin-top: 0; justify-content: flex-end; } }
.channel-btn { color: var(--surface); border-radius: var(--r-pill); min-height: 38px; padding: 0 16px; }
.channel-btn-line { background: var(--line-brand); border-color: var(--line-brand); }
.channel-btn-line:hover { background: var(--line-brand-700); color: var(--surface); }
.channel-btn-call { background: var(--green-800); border-color: var(--green-800); }
.channel-btn-call:hover { background: var(--green-900); color: var(--surface); }
.channel-btn-mail { background: var(--gold-600); border-color: var(--gold-600); }
.channel-btn-mail:hover { background: var(--gold-700); color: var(--surface); }
.channel-copy { border-radius: var(--r-pill); min-height: 38px; gap: 5px; }

.contact-follow { margin-bottom: 0; }
.contact-social-row { display: flex; flex-wrap: wrap; gap: 10px; }
.contact-social { display: inline-flex; align-items: center; gap: 8px; min-height: 42px; padding: 0 16px 0 6px; border: 1px solid var(--border); border-radius: var(--r-pill); background: var(--surface); color: var(--green-900); font-weight: 600; font-size: 14px; transition: border-color .15s, box-shadow .15s; }
.contact-social:hover { border-color: var(--green-700); box-shadow: var(--shadow-1); }
.contact-social-ico { width: 32px; height: 32px; border-radius: 50%; background: var(--green-100); display: grid; place-items: center; color: var(--green-800); }
.contact-social-ext { color: var(--muted); }

.steps-row { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; counter-reset: step; }
@media (min-width: 640px) { .steps-row { grid-template-columns: repeat(3, 1fr); } }
.step { position: relative; display: grid; gap: 6px; padding: 18px 18px 18px 20px; background: var(--cream); border-radius: var(--r-lg); border: 1px solid rgb(201 162 75 / 0.25); }
.step-num { position: absolute; top: 14px; right: 16px; font-family: var(--font-display); font-size: 28px; font-weight: 700; color: var(--gold-600); opacity: .7; line-height: 1; }
.step-ico { width: 40px; height: 40px; border-radius: 12px; background: var(--surface); color: var(--green-800); display: grid; place-items: center; box-shadow: var(--shadow-1); }
.step-title { font-weight: 700; color: var(--green-950); font-size: 15.5px; margin-top: 4px; }
.step-text { font-size: 13.5px; color: var(--muted); line-height: 1.6; }

.contact-qr { display: grid; gap: 10px; }
@media (min-width: 960px) { .contact-qr { position: sticky; top: 92px; } }
.qr-card-v2 { background: var(--surface); border: 1px solid var(--border); border-radius: 22px; padding: 22px; box-shadow: var(--shadow-3); display: grid; gap: 14px; }
.qr-head { display: flex; align-items: center; gap: 12px; color: var(--line-brand); }
.qr-head span { display: flex; flex-direction: column; line-height: 1.25; }
.qr-head b { color: var(--green-950); font-size: 16px; }
.qr-head small { color: var(--muted); font-size: 12.5px; }
.qr-card-v2 .qr-svg { padding: 10px; border: 1px dashed rgb(23 56 47 / 0.25); border-radius: 16px; background: var(--surface); }
.qr-id { text-align: center; font-size: 13.5px; color: var(--muted); }
.qr-id b { color: var(--green-950); font-size: 15px; margin-left: 4px; }
.qr-card-v2 .contact-big-btn { box-shadow: none; }
.contact-qr-foot { display: flex; align-items: center; gap: 6px; justify-content: center; font-size: 12.5px; color: var(--muted); margin: 0; }
.contact-qr-foot svg { color: var(--ok); }

.contact-cta { background: var(--green-950); color: var(--surface); border-top: 2px solid var(--gold-500); }
.contact-cta-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 24px; padding: 34px 16px; }
.contact-cta h2 { font-size: 22px; margin: 0 0 4px; color: var(--surface); }
.contact-cta p { margin: 0; color: rgb(255 255 255 / 0.75); font-size: 14.5px; }
.contact-cta-btn { background: var(--gold-500); color: var(--green-950); border-color: var(--gold-500); border-radius: var(--r-pill); min-height: 48px; padding: 0 22px; gap: 8px; font-weight: 700; }
.contact-cta-btn:hover { background: var(--gold-300); color: var(--green-950); }

/* ============ Property detail (v2) ============ */
.detail-head { margin: 6px 0 18px; }
.detail-deal { display: inline-block; background: var(--price); color: var(--surface); font-size: 12.5px; font-weight: 700; padding: 3px 12px; border-radius: var(--r-pill); margin-bottom: 10px; letter-spacing: .02em; }
.detail-title h1 { font-size: clamp(1.45rem, 3.2vw, 2rem); line-height: 1.3; margin-bottom: 4px; max-width: 30ch; }
.detail-title .en-sub { font-size: 16px; margin-bottom: 8px; }
.detail-address { font-size: 14px; flex-wrap: wrap; gap: 4px 8px; }
.detail-map-link { display: inline-flex; align-items: center; min-height: 36px; padding: 0 6px; color: var(--green-700); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--gold-500); margin-left: 2px; }
.detail-meta { margin: 10px 0 0; gap: 8px 14px; }

@media (min-width: 900px) {
  .gallery { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 12px; }
  .gallery-thumbs { display: grid; grid-auto-rows: 1fr; gap: 12px; height: 100%; }
  .gallery-thumb { min-height: 0; }
}
.detail-facts.facts-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; margin: 0 0 32px; box-shadow: var(--shadow-1); }
@media (min-width: 640px) { .detail-facts.facts-strip { grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); } }
.detail-facts.facts-strip > div { padding: 14px 12px; min-width: 0; background: var(--surface); }
.detail-facts .f-icon { color: var(--gold-600); margin-bottom: 6px; }
.detail-facts .f-value { font-size: 15.5px; }
.detail-facts .f-label { font-size: 11.5px; letter-spacing: .02em; }
.detail-facts .f-yield .f-value { color: var(--danger-600); }

.detail-layout { gap: 32px; }
@media (min-width: 900px) { .detail-layout { grid-template-columns: minmax(0, 1fr) 340px; gap: 44px; } }
.detail-block { padding: 26px 0; border-top: 1px solid var(--border); margin: 0; }
.detail-block:first-child { border-top: 0; padding-top: 0; }
.detail-layout .sec-h, .detail-layout .cost-title { position: relative; font-size: 18.5px; color: var(--green-950); margin: 0 0 16px; padding-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.detail-layout .sec-h::after, .detail-layout .cost-title::after { content: ''; position: absolute; left: 0; bottom: 0; width: 36px; height: 3px; border-radius: 2px; background: var(--gold-500); }
.detail-desc { margin: 0; font-size: 15.5px; line-height: 1.85; white-space: pre-line; max-width: 70ch; color: var(--ink); }
.detail-layout .amenity-group { margin-bottom: 0; }
.detail-layout .cost-section, .detail-layout .loan-section { margin: 0; }
.detail-layout .price-table { margin-bottom: 0; }
.detail-layout .map-embed { box-shadow: var(--shadow-1); }
.detail-layout .map-actions { margin-bottom: 0; }
.detail-layout .map-title { scroll-margin-top: 90px; }
#location-map { scroll-margin-top: 84px; }

.detail-side { display: grid; gap: 12px; }
@media (min-width: 900px) { .detail-side { position: sticky; top: 92px; } }
.side-card { background: var(--surface); border: 1px solid var(--border); border-radius: 20px; box-shadow: var(--shadow-3); padding: 22px 22px 18px; }
.side-price-head { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.side-deal { display: inline-block; background: var(--price); color: var(--surface); font-size: 12.5px; font-weight: 700; padding: 3px 12px; border-radius: var(--r-pill); }
.side-card .promo-tag { background: var(--gold-300); color: var(--green-950); font-size: 11.5px; font-weight: 700; padding: 3px 10px; border-radius: var(--r-pill); }
.side-price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px; color: var(--price); }
.side-price-main { font-size: 32px; font-weight: 800; letter-spacing: -.01em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.side-price small { font-size: 14px; color: var(--muted); font-weight: 500; }
.side-price .price-original { font-size: 14px; color: var(--muted); }
.side-share { display: flex; align-items: center; gap: 8px; padding: 0 6px; font-size: 13px; color: var(--muted); }
.side-share span { margin-right: auto; }
.side-share-btn { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--border); background: var(--surface); color: var(--green-900); display: grid; place-items: center; cursor: pointer; transition: background .15s, border-color .15s; }
.side-share-btn:hover { background: var(--green-100); border-color: var(--green-700); }

.related-title { font-size: 20px !important; }
.related-title::after { display: none; }

/* mobile sticky action bar */
.detail-mobile-bar { display: none; }
@media (max-width: 899px) {
  body[data-page='property'] { padding-bottom: 78px; }
  .detail-mobile-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 90; display: flex; align-items: center; gap: 10px; padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); background: var(--surface); border-top: 1px solid var(--border); box-shadow: 0 -8px 24px rgb(14 33 28 / 0.12); }
  .dmb-price { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.15; }
  .dmb-deal { font-size: 11px; color: var(--muted); font-weight: 600; }
  .dmb-price b { font-size: 19px; color: var(--price); font-variant-numeric: tabular-nums; }
  .dmb-price small { font-size: 11px; color: var(--muted); }
  .dmb-line { min-height: 44px; padding: 0 18px; border-radius: var(--r-pill); gap: 6px; }
  .dmb-call { width: 44px; min-height: 44px; padding: 0; border-radius: 50%; display: grid; place-items: center; }
}
@media (max-width: 899px) { body[data-page='property'] .chat-dock { bottom: calc(84px + env(safe-area-inset-bottom)); } }

/* ============ Property card (v2) — one design for home + listings ============ */
.prop-card, .home-page .home-prop-card { border-radius: 18px; border: 1px solid rgb(23 56 47 / 0.1); box-shadow: 0 2px 10px rgb(20 40 34 / 0.05); transition: transform .22s cubic-bezier(.22,1,.36,1), box-shadow .22s; }
.prop-card:hover, .home-page .home-prop-card:hover { transform: translateY(-4px); box-shadow: 0 16px 36px rgb(14 33 28 / 0.14); }
.prop-card-photo, .home-page .home-prop-card .prop-card-photo { aspect-ratio: 4 / 3; }
.prop-card-photo::before { content: ''; position: absolute; inset: auto 0 0 0; height: 46%; background: linear-gradient(180deg, transparent, rgb(14 33 28 / 0.45)); z-index: 1; pointer-events: none; }
.prop-card-photo img { transition: transform .5s cubic-bezier(.22,1,.36,1); }
.prop-card:hover .prop-card-photo img { transform: scale(1.05); }
.prop-card .badge, .home-page .home-prop-card .badge { z-index: 2; top: 12px; left: 12px; padding: 4px 12px; border-radius: 999px; font-size: 12px; font-weight: 700; letter-spacing: .01em; background: rgb(14 33 28 / 0.72); color: var(--surface); backdrop-filter: blur(6px); box-shadow: 0 2px 8px rgb(0 0 0 / 0.2); }
.prop-card .badge.badge-ok, .home-page .home-prop-card .badge.badge-ok { background: rgb(14 33 28 / 0.72); }
.prop-card .badge.badge-danger { background: var(--danger); }
.prop-card .badge.badge-featured, .home-page .home-prop-card .badge.badge-featured { left: auto; right: 12px; background: var(--gold-500); color: var(--green-950); }
.prop-card-body, .home-page .home-prop-card .prop-card-body { padding: 14px 14px 14px; }
.prop-card-pricerow { align-items: center; flex-wrap: wrap; gap: 4px 8px; margin-bottom: 4px; }
.prop-price, .home-page .home-prop-card .prop-price { display: flex; align-items: baseline; flex-wrap: nowrap; gap: 0 6px; white-space: nowrap; color: var(--price); font-size: 20px; font-weight: 800; letter-spacing: -.01em; font-variant-numeric: tabular-nums; min-width: 0; }
.prop-price-main { white-space: nowrap; }
.prop-price small, .home-page .home-prop-card .prop-price small { font-size: 12px; font-weight: 500; color: var(--muted); margin: 0; }
.prop-price .price-original, .home-page .home-prop-card .price-original { display: inline; font-size: 12.5px; color: var(--muted); font-weight: 500; margin: 0; }
.promo-tag { flex-shrink: 0; }
.yield-chip { position: absolute; right: 12px; bottom: 12px; z-index: 2; display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 999px; background: rgb(255 255 255 / 0.94); color: var(--danger-600); font-size: 11.5px; font-weight: 700; white-space: nowrap; box-shadow: 0 2px 8px rgb(0 0 0 / 0.18); }
.prop-name, .home-page .home-prop-card .prop-name { font-size: 15.5px; font-weight: 700; color: var(--green-950); margin: 0 0 2px; min-height: 0; line-height: 1.35; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.prop-loc, .home-page .home-prop-card .prop-loc { display: flex; align-items: center; gap: 5px; min-height: 0; margin: 0 0 12px; color: var(--muted); font-size: 13px; }
.prop-loc svg { flex: 0 0 auto; color: var(--green-700); }
.prop-loc span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.prop-facts, .home-page .home-prop-card .prop-facts { list-style: none; margin: 0; padding: 10px 0 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-content: start; gap: 7px 10px; min-height: 0; border-top: 1px solid var(--border); font-size: 13px; color: var(--ink); height: 62px; overflow: hidden; }
.prop-facts li, .home-page .home-prop-card .prop-facts li { display: flex; align-items: center; gap: 6px; padding: 0; white-space: nowrap; min-width: 0; }
.prop-facts li span { overflow: hidden; text-overflow: ellipsis; }
.prop-facts li span { font-weight: 600; font-size: 12.5px; color: var(--green-950); }
.prop-facts li svg, .home-page .home-prop-card .prop-facts svg { width: 15px; height: 15px; flex: 0 0 auto; color: var(--green-700); }
.prop-meta, .home-page .home-prop-card .prop-meta { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border); }
.mini-chip-type { background: var(--green-100); color: var(--green-900); border: 1px solid rgb(23 56 47 / 0.12); border-radius: 999px; padding: 2px 10px; font-size: 11.5px; }
.prop-meta-stats, .home-page .home-prop-card .prop-meta-stats { font-size: 12px; }
/* comment rev.03 slide 9: Duplex / Penthouse chip next to the type */
.mini-chip-unit { background: var(--gold-300); color: var(--green-950); border: 1px solid rgb(201 162 75 / 0.5); border-radius: 999px; padding: 2px 10px; font-size: 11.5px; }
/* comment rev.03 slide 10: average price per sqm beside the price */
.price-psqm { font-size: 11.5px; font-weight: 500; color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.prop-card-pricerow .price-psqm { flex-basis: 100%; margin-top: -2px; }
.home-page .home-prop-card .price-psqm { font-size: 10.5px; }
.gallery-deal-psqm { font-size: 12px; font-weight: 500; opacity: 0.9; white-space: nowrap; }
.cost-table .price-psqm { display: block; font-size: 11.5px; }

.st-picker input[type='checkbox'], [data-st-month] { width: 18px; height: 18px; accent-color: var(--green-800); }
.data-table .ps-select-btn { min-height: 36px; }


/* ======================================================================
   comment_Rev.02.pptx — customer review round 2 (2026-09-05)
   ====================================================================== */

/* ---- Slide 1: language switch as a flag dropdown ---- */
.lang-dd { position: relative; margin-left: 6px; }
.lang-dd summary {
  list-style: none; display: inline-flex; align-items: center; gap: 8px; padding: 6px 10px; min-height: 40px; border-radius: 8px; cursor: pointer;
  color: var(--on-dark); font-size: 12.5px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; line-height: 1; user-select: none;
}
.lang-dd summary::-webkit-details-marker { display: none; }
.lang-dd summary:hover, .lang-dd[open] summary { background: rgb(255 255 255 / 0.08); color: var(--gold-300); }
.lang-dd summary > svg:last-child { transition: transform 0.2s; }
.lang-dd[open] summary > svg:last-child { transform: rotate(180deg); }
.lang-dd .flag { border-radius: 2px; box-shadow: 0 0 0 1px rgb(255 255 255 / 0.4); flex-shrink: 0; }
.lang-dd-list {
  position: absolute; right: 0; top: calc(100% + 6px); min-width: 176px; margin: 0; padding: 6px; list-style: none; z-index: 130;
  background: var(--surface); border-radius: 10px; box-shadow: var(--shadow-3); animation: chat-in 0.18s ease-out;
}
.nav-menu .lang-dd-list a, .navbar .lang-dd-list a, .home-page .nav-menu .lang-dd-list a {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; min-height: 42px; border-radius: 8px;
  color: var(--green-950); font-weight: 600; font-size: 13.5px; box-shadow: none; text-transform: none; letter-spacing: 0;
}
.navbar .lang-dd-list a:hover, .home-page .nav-menu .lang-dd-list a:hover { background: var(--green-100); color: var(--green-950); }
.navbar .lang-dd-list a.active, .home-page .nav-menu .lang-dd-list a.active { color: var(--green-800); box-shadow: none; }
.lang-dd-list a > svg:last-child:not(.flag) { margin-left: auto; color: var(--ok); }
.lang-dd-list .flag { box-shadow: 0 0 0 1px rgb(0 0 0 / 0.12); }
.nav-menu .lang-dd { display: none; }
@media (min-width: 900px) { .nav-menu .lang-dd { display: block; } }
.navbar-right .lang-dd summary { padding: 6px 8px; }
.navbar-right .lang-dd-name { display: none; }

/* ---- Slide 6: whatever the cursor is about to click gets clearer ---- */
.btn { transition: background 0.15s, color 0.15s, transform 0.12s, box-shadow 0.15s, filter 0.15s; }
.btn:not([disabled]):hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgb(14 33 28 / 0.16); }
.btn:not([disabled]):active { transform: translateY(0); box-shadow: none; }
/* comment rev.03 slide 4: listing cards never fade (a faded card looks "already rented") — only category / location / transit tiles do */
.loc-row:hover .loc-card:not(:hover), .transit-row:hover .transit-tile:not(:hover) { opacity: 0.72; }
.cat-row:hover .cat-tile:not(:hover) { opacity: 0.55; filter: saturate(0.7); }
.prop-card, .loc-card, .cat-tile, .transit-tile { transition: transform 0.2s, box-shadow 0.2s, opacity 0.2s; }
.prop-card:hover, .loc-card:hover, .cat-tile:hover, .transit-tile:hover { opacity: 1; }
.transit-tile.is-empty:hover { opacity: 1; }
.transit-tile:hover { border-width: 1.5px; box-shadow: 0 10px 26px rgb(14 33 28 / 0.14), 0 0 0 2px var(--line); }
.loc-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-3); }
.section-link:hover { color: var(--gold-700); text-decoration-thickness: 2px; }
.station-chip:hover { box-shadow: 0 0 0 2px var(--line); color: var(--green-950); }
.count-pill:hover { filter: none; transform: translateY(-1px); box-shadow: var(--shadow-2); }
.social-btn:hover { transform: translateY(-2px); box-shadow: 0 8px 18px rgb(0 0 0 / 0.25); }
.side-share-btn:hover { background: var(--green-900); color: var(--surface); border-color: var(--green-900); }
.icon-btn:hover { box-shadow: var(--shadow-2); }
.footer a:hover { text-decoration: underline; text-underline-offset: 3px; }
.home-page .home-outline-btn:hover { box-shadow: 0 8px 20px rgb(23 56 47 / 0.22); }
@media (prefers-reduced-motion: reduce) { .loc-row:hover .loc-card:not(:hover), .cat-row:hover .cat-tile:not(:hover), .transit-row:hover .transit-tile:not(:hover) { opacity: 1; filter: none; } }

/* ---- Slide 5 + 11: property code on the card (the "Updated" stamp was removed) ---- */
.prop-card .code-pill {
  position: absolute; left: 12px; bottom: 12px; z-index: 2; padding: 3px 10px; border-radius: 999px;
  background: rgb(255 255 255 / 0.94); color: var(--green-900); font-size: 11.5px; font-weight: 700; letter-spacing: 0.03em;
  font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace; box-shadow: 0 2px 8px rgb(0 0 0 / 0.18);
}
.prop-card .yield-chip + .code-pill { left: 12px; }

/* ---- Slide 7 + 19: floating contact dock — gold like the logo, faded until approached, opens LINE + WhatsApp ---- */
.chat-dock { position: fixed; right: 18px; bottom: 18px; z-index: 95; display: flex; flex-direction: column; align-items: flex-end; gap: 12px; }
.chat-fab {
  width: 58px; height: 58px; padding: 0; border: none; border-radius: 50%; display: grid; place-items: center; cursor: pointer;
  background: var(--gold-500); color: var(--green-950); box-shadow: 0 8px 24px rgb(0 0 0 / 0.22);
  opacity: 0.42; transition: opacity 0.25s, transform 0.2s, box-shadow 0.2s, background 0.2s;
}
.chat-dock:hover .chat-fab, .chat-fab:focus-visible, .chat-dock.is-open .chat-fab { opacity: 1; transform: scale(1.06); box-shadow: 0 12px 30px rgb(201 162 75 / 0.55); }
.chat-dock.is-open .chat-fab { background: var(--green-900); color: var(--gold-300); }
.chat-fab:focus-visible { outline: 3px solid var(--gold-300); outline-offset: 3px; }
.chat-fab-icon { grid-area: 1 / 1; display: grid; transition: opacity 0.2s, transform 0.2s; }
.chat-fab-close { opacity: 0; transform: rotate(-90deg) scale(0.6); }
.chat-dock.is-open .chat-fab-open { opacity: 0; transform: rotate(90deg) scale(0.6); }
.chat-dock.is-open .chat-fab-close { opacity: 1; transform: none; }
.chat-dock-menu { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.chat-dock-menu[hidden] { display: none; }
.chat-option { display: inline-flex; align-items: center; gap: 10px; padding: 0; border: none; background: transparent; cursor: pointer; text-decoration: none; animation: chat-in 0.22s ease-out both; }
.chat-dock-menu > .chat-option:nth-child(2), .chat-dock-menu > .chat-wa:nth-child(2) .chat-option { animation-delay: 0.05s; }
.chat-option-label {
  padding: 6px 12px; border-radius: 999px; background: var(--surface); color: var(--green-950); font-size: 13px; font-weight: 600; white-space: nowrap;
  box-shadow: var(--shadow-2); opacity: 0; transform: translateX(6px); transition: opacity 0.15s, transform 0.15s; pointer-events: none;
}
.chat-option:hover .chat-option-label, .chat-option:focus-visible .chat-option-label, .chat-option[aria-expanded='true'] .chat-option-label { opacity: 1; transform: none; }
.chat-option-icon { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; color: var(--surface); box-shadow: 0 8px 22px rgb(0 0 0 / 0.22); transition: transform 0.15s, box-shadow 0.15s; }
.chat-option:hover .chat-option-icon, .chat-option:focus-visible .chat-option-icon { transform: scale(1.08); box-shadow: 0 12px 26px rgb(0 0 0 / 0.28); }
.chat-option-line .chat-option-icon { background: #06c755; }
.chat-option-wa .chat-option-icon { background: #25d366; }
.chat-wa { position: relative; display: flex; justify-content: flex-end; }
.chat-wa-list {
  position: absolute; right: 64px; bottom: 0; min-width: 236px; padding: 10px; display: grid; gap: 4px;
  background: var(--surface); border-radius: 14px; box-shadow: var(--shadow-3); animation: chat-in 0.18s ease-out;
}
.chat-wa-list[hidden] { display: none; }
.chat-wa-title { padding: 2px 8px 6px; font-size: 12px; font-weight: 600; color: var(--muted); }
.chat-wa-item { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 10px; color: var(--green-950); font-size: 14px; font-weight: 600; font-variant-numeric: tabular-nums; }
.chat-wa-item:hover { background: #e8f8ee; color: var(--green-950); }
.chat-wa-item > svg { color: #25d366; flex-shrink: 0; }
/* the LINE card floats above the whole icon stack so it never covers the WhatsApp button */
.chat-dock-menu { position: relative; }
.chat-line { position: static; }
.chat-line-card { position: absolute; right: 0; bottom: calc(100% + 10px); left: auto; min-width: 236px; justify-items: center; text-align: center; }
.chat-line-card .chat-wa-title { padding-bottom: 8px; max-width: 220px; font-weight: 500; }
.chat-line-qr { width: 200px; height: 200px; border-radius: 12px; border: 1px solid var(--border); background: #fff; }
.chat-line-add { display: inline-flex; align-items: center; justify-content: center; gap: 8px; width: 100%; margin-top: 6px; padding: 10px 14px; border-radius: 10px; background: #06c755; color: var(--surface); font-size: 14px; font-weight: 700; }
.chat-line-add:hover { background: #05b34c; color: var(--surface); }
@media (max-width: 639px) {
  .chat-dock { right: 12px; bottom: 12px; }
  .chat-fab { width: 54px; height: 54px; opacity: 0.55; }
  .chat-option-label { display: none; }
  .detail-page .chat-dock, body[data-page='property'] .chat-dock { bottom: 82px; }
}

/* ---- Slide 9: "คอนโด / บ้าน / อาคารพาณิชย์ ใกล้รถไฟฟ้า" tabs + line badge (logo upload or neutral disc) ---- */
.transit-types { display: inline-flex; flex-wrap: wrap; gap: 4px; margin: 0 0 16px; padding: 4px; background: var(--cream); border-radius: 24px; }
.transit-types button {
  min-height: 40px; padding: 8px 18px; border: none; border-radius: 999px; background: transparent; cursor: pointer;
  font-family: var(--font-body); font-size: 14px; font-weight: 600; color: var(--green-800); transition: background 0.15s, color 0.15s;
}
.transit-types button:hover { background: rgb(255 255 255 / 0.75); color: var(--green-950); }
.transit-types button[aria-selected='true'] { background: var(--green-900); color: var(--surface); }
.transit-logo { box-shadow: inset 0 0 0 3px rgb(255 255 255 / 0.55), 0 0 0 2px var(--line); background: var(--line); }
.transit-logo-text { display: block; line-height: 1; }
.transit-logo.has-logo { background: var(--surface); overflow: hidden; box-shadow: 0 0 0 2px var(--line); }
.transit-logo.has-logo img { width: 100%; height: 100%; object-fit: contain; padding: 5px; }
.transit-logo.transit-logo-sm.has-logo img { padding: 3px; }
/* built-in BTS / MRT marks (src/components/transit-marks.tsx): the SVG paints itself in --line, so no disc behind it */
.transit-logo.has-mark { background: transparent; box-shadow: none; overflow: visible; }
.transit-logo.has-mark svg { display: block; width: 100%; height: 100%; filter: drop-shadow(0 1px 2px rgb(0 0 0 / 0.12)); }
.transit-logo .transit-mark { display: block; width: 100%; height: 100%; }
.tl-badge-cell { display: inline-block; }
@media (max-width: 639px) { .transit-types { display: flex; width: 100%; } .transit-types button { flex: 1 1 30%; padding-inline: 8px; font-size: 13px; } }

/* ---- Slides 14–23: contact page rows (Facebook page · WhatsApp · WeChat QR · Email) + footer phones/socials ---- */
.channel-facebook .channel-ico { background: var(--facebook); }
.channel-whatsapp .channel-ico { background: #25d366; }
.channel-wechat .channel-ico { background: #07c160; }
.channel-btn-facebook { background: var(--facebook); border-color: var(--facebook); gap: 6px; }
.channel-btn-facebook:hover { background: #145dc0; color: var(--surface); }
.channel-btn-wa { background: #25d366; border-color: #25d366; gap: 6px; }
.channel-btn-wa:hover { background: #1fb659; color: var(--surface); }
.channel-phone .channel-ico { background: var(--green-800); }
.channel-btn-phone { background: var(--green-800); border-color: var(--green-800); gap: 6px; }
.channel-btn-phone:hover { background: var(--green-900); color: var(--surface); }
.channel-phone-list { flex-direction: column; gap: 6px; }  /* comment rev.04 slide 3: one line per agent */
.channel-phone-num { display: inline-flex; align-items: baseline; gap: 6px; color: var(--green-950); font-size: 17px; font-variant-numeric: tabular-nums; }
.channel-phone-num:hover { color: var(--green-700); }
.channel-phone-num small { font-size: 12px; color: var(--muted); }
.channel-phone-num a { color: inherit; }
.channel-phone-num a:hover { color: var(--green-700); }
.qr-img img { display: block; width: 100%; height: auto; max-width: 300px; margin: 0 auto; border-radius: 12px; background: #fff; }
.channel-btn-wechat { background: #07c160; border-color: #07c160; gap: 6px; }
.channel-btn-wechat:hover { background: #06a852; color: var(--surface); }
.channel-value-list { display: flex; flex-wrap: wrap; gap: 6px 14px; }
.channel-wa-num { display: inline-flex; align-items: baseline; gap: 6px; color: var(--green-950); font-size: 18px; }
.channel-wa-num:hover { color: #1fb659; }
.channel-wa-num small { font-size: 11px; font-weight: 700; color: var(--surface); background: #25d366; padding: 1px 8px; border-radius: 999px; }
.channel-qr { grid-column: 1 / -1; display: none; flex-direction: column; align-items: center; gap: 8px; margin-top: 12px; padding: 16px; border-top: 1px dashed var(--border); font-size: 13px; color: var(--muted); }
.channel-qr:not([hidden]) { display: flex; }
.channel-qr img { width: 240px; height: 240px; border-radius: 12px; border: 1px solid var(--border); }
.contact-hero-wa { background: #25d366; color: var(--surface); border-color: #25d366; gap: 8px; min-height: 48px; padding: 0 20px; border-radius: var(--r-pill); font-size: 15px; }
.contact-hero-wa:hover { background: #1fb659; color: var(--surface); }
.footer-contact .fc-phones { align-items: flex-start; }
.fc-phone-list { display: flex; flex-direction: column; gap: 2px; }
.fc-phone-list a small { font-size: 12px; opacity: 0.8; }
.social-row { flex-wrap: nowrap; }
@media (max-width: 379px) { .footer-brand .social-btn { width: 40px; height: 40px; } .social-row { gap: 6px; } }
.social-facebook:hover { background: var(--facebook); color: var(--surface); }
.social-line:hover { background: #06c755; color: var(--surface); }
.social-instagram:hover { background: #e1306c; color: var(--surface); }
.social-whatsapp:hover { background: #25d366; color: var(--surface); }
.social-tiktok:hover { background: #111; color: var(--surface); }
.social-wechat:hover { background: #07c160; color: var(--surface); }

/* ============ Admin: property list fits the viewport (no horizontal scroll) ============ */
.props-wrap { overflow: visible; }
.props-table { table-layout: auto; }
.props-table th, .props-table td { padding: 10px 10px; }
.props-table th.sortable a { padding: 10px 10px; }
.props-table thead th { position: sticky; top: 0; z-index: 2; box-shadow: 0 1px 0 var(--border); }
.props-table td { white-space: normal; }
.props-table .col-thumb { width: 66px; min-width: 66px; }
.props-table .col-listing { width: 40%; min-width: 180px; }
.props-table .col-price { width: 1%; white-space: nowrap; font-variant-numeric: tabular-nums; }
.props-table .col-detail { width: 32%; min-width: 150px; }
.props-table .col-status { width: 1%; min-width: 120px; }
.props-table .col-actions { width: 1%; white-space: nowrap; }
.props-table .num { white-space: nowrap; font-variant-numeric: tabular-nums; }
.props-table .cell-code { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; margin-bottom: 2px; }
.props-table .cell-code strong { font-variant-numeric: tabular-nums; letter-spacing: 0.01em; }
.props-table .mini-chip-deal { background: rgb(201 162 75 / 0.18); color: var(--gold-700); border: 1px solid rgb(201 162 75 / 0.35); border-radius: 999px; padding: 2px 10px; font-size: 11.5px; }
.props-table .cell-main { overflow-wrap: anywhere; }
.props-table .cell-facts span { white-space: nowrap; }
.props-table .cell-sub svg { vertical-align: -2px; color: var(--green-700); }
.props-table .cell-phone { font-variant-numeric: tabular-nums; white-space: nowrap; }
.props-table .cell-pills { display: flex; flex-wrap: wrap; gap: 4px; }
.props-table .cell-meta { display: flex; flex-wrap: wrap; gap: 2px 10px; white-space: nowrap; }
.props-table .row-actions { gap: 5px; }
.props-table .btn-edit { padding: 0 11px; min-height: 34px; gap: 5px; }
.btn.btn-icon { width: 34px; min-width: 34px; height: 34px; min-height: 34px; padding: 0; display: inline-grid; place-items: center; border-radius: var(--r-sm); }
.btn.btn-icon svg { display: block; }
.props-tools { justify-content: flex-start; gap: 8px 12px; margin: -4px 0 12px; }
.props-sort { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); white-space: nowrap; }
.props-sort .select { min-height: 36px; padding: 4px 30px 4px 10px; font-size: 13.5px; font-weight: 600; color: var(--green-900); width: auto; }
.props-dir { min-height: 36px; padding: 0 12px; white-space: nowrap; }
.props-tools-hint { font-size: 12.5px; color: var(--muted); margin-left: auto; }
@media (max-width: 1023px) { .props-table thead th { top: 56px; } }
@media (max-width: 899px) { .props-tools-hint { display: none; } }
@media (max-width: 759px) {
  /* stack each row as a card: thumbnail left, everything else below each other */
  .props-table, .props-table tbody { display: block; }
  .props-table thead { display: none; }
  .props-table tr { display: grid; grid-template-columns: 66px minmax(0, 1fr); gap: 0 8px; padding: 12px 0; border-bottom: 1px solid var(--border); }
  .props-table td, .props-table td.col-price, .props-table td.col-status, .props-table td.col-actions, .props-table td.col-listing, .props-table td.col-detail { display: block; border: none; padding: 0 0 6px; width: auto; min-width: 0; white-space: normal; }
  .props-table tr:hover td { background: transparent; }
  .props-table .col-thumb { grid-row: 1 / span 5; padding: 0; }
  .props-table .col-thumb .thumb { width: 66px; height: 66px; }
  .props-table .col-price { white-space: normal; }
  .props-table .col-price > div { display: inline-block; margin-right: 12px; white-space: nowrap; }
  .props-table .col-actions { grid-column: 2; padding-top: 4px; }
  .props-table .row-actions { flex-wrap: wrap; }
}

/* ============ Admin: users page — add / edit in one modal ============ */
.users-tools { justify-content: space-between; margin-bottom: 12px; }
.users-search { display: flex; gap: 8px; align-items: center; flex: 1 1 auto; flex-wrap: nowrap; min-width: 0; }
.users-search .input { flex: 0 1 300px; width: auto; min-width: 0; }
.users-table .col-actions { width: 1%; white-space: nowrap; }
.users-table .row-actions { gap: 5px; }
.users-table .btn-edit { padding: 0 11px; min-height: 34px; gap: 5px; }
.users-table td .cell-sub { font-weight: 400; }
dialog.form-modal { border: none; border-radius: var(--r-lg); padding: 20px 22px 22px; width: min(480px, calc(100vw - 24px)); max-height: calc(100dvh - 24px); box-shadow: var(--shadow-3); background: var(--surface); color: var(--ink); }
dialog.form-modal::backdrop { background: rgb(14 33 28 / 0.65); }
.form-modal-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.form-modal-head h2 { font-size: 17px; color: var(--green-900); margin: 0; }
.form-modal .hashtag-warn { margin: 0 0 14px; }
.form-modal .field:last-of-type { margin-bottom: 0; }
.form-modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; }
@media (max-width: 639px) { dialog.form-modal { padding: 16px; } .form-modal-actions .btn { flex: 1 1 auto; } .users-add { width: 100%; justify-content: center; } }

/* ============ Admin: settings split into sub-pages (sidebar sub-menu + tabs) ============ */
.sb-link.is-open { color: var(--gold-300); }
.sb-sub { display: flex; flex-direction: column; gap: 1px; margin: 0 0 4px; padding-left: 18px; position: relative; }
.sb-sub::before { content: ''; position: absolute; left: 21px; top: 2px; bottom: 2px; width: 1px; background: rgb(255 255 255 / 0.14); }
.sb-sublink { display: flex; align-items: center; gap: 8px; min-height: 34px; padding: 6px 10px 6px 14px; border-radius: var(--r-sm); color: var(--on-dark-muted); font-size: 13px; font-weight: 500; text-decoration: none; transition: background .15s, color .15s; }
.sb-sublink:hover { background: rgb(255 255 255 / 0.07); color: var(--surface); }
.sb-sublink.is-active { background: var(--green-800); color: var(--gold-300); font-weight: 600; box-shadow: inset 3px 0 0 var(--gold-500); }
.sb-sublink .sb-ico { width: 16px; }
.seg-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 14px; }
.seg-tab { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 6px 14px; border-radius: var(--r-pill); border: 1px solid var(--border); background: var(--surface); color: var(--green-900); font-size: 13.5px; font-weight: 500; text-decoration: none; }
.seg-tab:hover { border-color: var(--green-800); }
.seg-tab.is-active { background: var(--green-900); color: var(--surface); border-color: var(--green-900); font-weight: 600; }

/* ============ Admin: property form — side menu, collapsible extras, fields hidden by type ============ */
.prop-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0 22px; align-items: start; }
.prop-main { min-width: 0; }
.form-nav { display: flex; gap: 6px; overflow-x: auto; position: sticky; top: 0; z-index: 3; margin: -8px -4px 12px; padding: 8px 4px; background: var(--admin-bg); scrollbar-width: none; }
.form-nav::-webkit-scrollbar { display: none; }
.form-nav a { display: inline-flex; align-items: center; gap: 7px; min-height: 36px; padding: 6px 12px; border-radius: var(--r-pill); border: 1px solid var(--border); background: var(--surface); color: var(--green-900); font-size: 13.5px; font-weight: 500; text-decoration: none; white-space: nowrap; position: relative; }
.form-nav a:hover { border-color: var(--green-800); }
.form-nav a.is-active { background: var(--green-900); color: var(--surface); border-color: var(--green-900); font-weight: 600; }
.form-nav a.is-invalid::after { content: ''; position: absolute; top: -3px; right: -3px; width: 10px; height: 10px; border-radius: 50%; background: var(--danger); border: 2px solid var(--surface); }
@media (max-width: 1023px) { .form-nav { top: 56px; } }
@media (min-width: 1100px) {
  .prop-layout { grid-template-columns: minmax(0, 1fr) 210px; }
  .form-nav { grid-column: 2; grid-row: 1; flex-direction: column; gap: 3px; overflow: visible; top: 20px; margin: 0; padding: 8px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-md); box-shadow: var(--shadow-1); }
  .prop-main { grid-column: 1; grid-row: 1; }
  .form-nav a { border: none; border-radius: var(--r-sm); background: transparent; min-height: 38px; padding: 8px 10px; }
  .form-nav a:hover { background: var(--green-100); }
  .form-nav a.is-active { background: var(--green-900); color: var(--surface); }
  .form-nav a.is-invalid::after { top: 50%; right: 8px; transform: translateY(-50%); width: 8px; height: 8px; border: none; }
}
.admin-card[id^="sec-"] { scroll-margin-top: 64px; }
@media (min-width: 1100px) { .admin-card[id^="sec-"] { scroll-margin-top: 16px; } }
details.adv { margin: 10px 0 4px; border: 1px dashed var(--border); border-radius: var(--r-md); padding: 0 14px; background: var(--surface-alt, #fafaf7); }
details.adv > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 10px 0; font-size: 13.5px; font-weight: 600; color: var(--green-800); user-select: none; }
details.adv > summary::-webkit-details-marker { display: none; }
details.adv > summary::before { content: '▸'; font-size: 12px; color: var(--gold-600); width: 12px; transition: transform .15s; }
details.adv[open] > summary::before { transform: rotate(90deg); }
details.adv[open] > summary { border-bottom: 1px dashed var(--border); margin-bottom: 12px; }
details.adv > summary svg { color: var(--green-700); flex-shrink: 0; }
details.adv > .form-grid, details.adv > .field { padding-bottom: 6px; }
[data-field][hidden] { display: none !important; }
.prop-main .sticky-actions { background: var(--admin-bg); }
@media (max-width: 639px) { .prop-main .sticky-actions { gap: 8px; } .prop-main .sticky-actions .btn { flex: 1 1 auto; min-width: 0 !important; padding-inline: 12px; justify-content: center; } }

/* ============ Admin: master data (/admin/master/<kind>) ============ */
.master-wrap { overflow-x: auto; }
.master-table th, .master-table td { padding: 8px 8px; }
.master-table th.sortable a { padding: 8px; }
.master-table .cell-sub { max-width: 260px; }
.master-table .col-order { width: 1%; white-space: nowrap; }
.master-table .col-actions { width: 1%; white-space: nowrap; }
.master-table .row-actions { gap: 4px; }
.master-table .btn-edit { padding: 0 11px; min-height: 34px; gap: 5px; }
.master-table .order-num { display: inline-block; min-width: 22px; text-align: right; color: var(--muted); font-variant-numeric: tabular-nums; margin-right: 2px; }
.master-table .btn-icon[disabled] { opacity: .3; }
.master-table td.num { text-align: right; font-variant-numeric: tabular-nums; }
.master-table td.num a { font-weight: 600; color: var(--green-800); }
.master-ico { display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; background: var(--green-100); color: var(--green-900); }
.master-table tr.row-muted td { color: var(--muted); }
dialog.master-modal { width: min(720px, calc(100vw - 24px)); }
.icon-pick label { min-height: 36px; padding: 6px 9px; }
.icon-pick label svg { display: block; }
.icon-pick input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.icon-pick label:has(input:checked) { background: var(--green-900); color: var(--surface); border-color: var(--green-900); }
/* project picker in the listing form */
.project-pick { position: relative; }
.project-panel { position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 20; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-md); box-shadow: var(--shadow-2); max-height: 280px; overflow-y: auto; }
.project-item { display: flex; flex-direction: column; gap: 2px; width: 100%; text-align: left; padding: 9px 12px; border: none; border-bottom: 1px solid var(--border); background: transparent; font: inherit; color: var(--ink); cursor: pointer; }
.project-item:last-child { border-bottom: none; }
.project-item:hover, .project-item:focus { background: var(--green-100); outline: none; }
.project-item b { font-weight: 600; color: var(--green-950); }
.project-item small { color: var(--muted); font-size: 12.5px; }

.geo-filter .select { min-width: 210px !important; }
@media (max-width: 639px) { .geo-filter .select { width: 100% !important; } }

/* ============ Admin: project pictures + CSV import ============ */
.master-table .col-thumb { width: 72px; }
.proj-thumb { position: relative; display: block; width: 64px; height: 48px; border-radius: 6px; overflow: hidden; background: var(--green-100); }
.proj-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.proj-thumb small { position: absolute; left: 0; right: 0; bottom: 0; font-size: 9.5px; line-height: 1.3; text-align: center; background: rgb(14 33 28 / 0.65); color: #fff; }
.proj-thumb-empty { display: grid; place-items: center; color: var(--muted); }
.proj-image-row { display: flex; gap: 14px; align-items: flex-start; flex-wrap: wrap; }
.proj-image-preview { width: 200px; aspect-ratio: 4 / 3; border-radius: var(--r-md); background: var(--green-100); border: 1px dashed var(--border); display: grid; place-items: center; overflow: hidden; color: var(--muted); font-size: 13px; }
.proj-image-preview img { width: 100%; height: 100%; object-fit: cover; }
.proj-image-preview span { display: inline-flex; align-items: center; gap: 6px; }
.proj-image-actions { display: grid; gap: 8px; align-content: start; }
.import-card { padding: 0 18px; margin-bottom: 18px; }
.import-card > summary { min-height: 48px; font-size: 14.5px; }
.import-form { padding-bottom: 14px; }
.import-row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.import-row .input[type=file] { max-width: 360px; padding: 8px 10px; }
.project-item { flex-direction: row; align-items: center; gap: 10px; }
.project-item .project-item-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.project-item img, .project-item .project-item-ph { width: 44px; height: 33px; border-radius: 5px; object-fit: cover; background: var(--green-100); flex-shrink: 0; }
.project-item .project-item-ph { display: grid; place-items: center; color: var(--muted); }
.footer-osm { font-size: 11.5px; color: var(--muted); }

/* ============ Rev.05 (Comment_rev.05.pdf, 2026-09-08) ============ */
/* page 9: personal favourite heart in the back-office list — red when on */
.btn.btn-fav.is-on { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn.btn-fav.is-on svg { fill: currentColor; }
.filter-check .chk { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; font-size: 14px; }
.filter-check .chk svg { color: var(--danger); }
/* page 10: compact table when the list is sorted by project name (Room / Room Type / Size / Price / End Contract / Room Status) */
.props-compact-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.props-table-compact { min-width: 720px; }
.props-table-compact th, .props-table-compact td { padding: 9px 10px; vertical-align: middle; }
.props-table-compact .col-room { min-width: 180px; }
.props-table-compact .col-roomtype, .props-table-compact .col-size, .props-table-compact .col-contract { white-space: nowrap; }
.props-table-compact .col-contract { font-variant-numeric: tabular-nums; }
.props-table-compact .col-status { white-space: nowrap; }
.props-table-compact .cell-code { margin-top: 2px; }
.props-table .cell-contract svg { color: var(--danger); }
@media (max-width: 759px) {
  /* the compact table keeps its columns (the wrap scrolls); undo the card-style rules of .props-table */
  .props-table-compact, .props-table-compact tbody { display: table; width: 100%; }
  .props-table-compact tbody { display: table-row-group; }
  .props-table-compact thead { display: table-header-group; }
  .props-table-compact tr { display: table-row; padding: 0; border-bottom: none; }
  .props-table-compact td, .props-table-compact td.col-price, .props-table-compact td.col-status, .props-table-compact td.col-actions { display: table-cell; padding: 8px 8px; border-bottom: 1px solid var(--border); width: auto; }
  .props-table-compact td.col-price > div { display: block; margin: 0; }
  .props-table-compact .col-actions { grid-column: auto; }
}
/* page 11: contract end date card */
#sec-contract input[type="date"] { min-height: 44px; }
/* the compact table scrolls inside its own wrap → the 56 px mobile top offset of the sticky header would ride over the first row
   (Chromium also counts a static th of the overflowing table into the page scroll width, so it stays sticky at top 0) */
.props-compact-wrap .props-table thead th { top: 0; }
@media (max-width: 1023px) { .props-compact-wrap .props-table thead th { top: 0; } }
