/* UM 周边租房图鉴 */
:root {
  --bg: #FFFFFF;
  --bg-2: #F4F4F2;
  --ink: #1B1F24;
  --ink-2: #4B5560;
  --ink-3: #7B8590;
  --line: #DCDFDD;
  --r1: #C96A1B;   /* 区域 1 · PJ */
  --r2: #2F6BCC;   /* 区域 2 · Bangsar South */
  --lrt: #D6336C;  /* Kelana Jaya 线 */
  --campus: #3E8E5B;
  --ok: #2E7D4F;
  --focus: #1D5FD6;
  --serif: "Noto Serif SC", "Songti SC", "SimSun", "Source Han Serif SC", Georgia, serif;
  --sans: "Noto Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #15171B;
    --bg-2: #1E2126;
    --ink: #E9EBEE;
    --ink-2: #A9B1BA;
    --ink-3: #7F8891;
    --line: #2F343B;
    --r1: #D07B2E;
    --r2: #5B8FE0;
    --lrt: #E85D8E;
    --campus: #5DAF7C;
    --ok: #6CC493;
    --focus: #8FB5FF;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 64px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--sans); font-size: 15px; line-height: 1.75; -webkit-font-smoothing: antialiased; }
a { color: var(--r2); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 3px; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; margin: 0; line-height: 1.3; letter-spacing: .01em; }
strong { font-weight: 700; }

/* top bar */
.top { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px clamp(16px, 4vw, 40px); background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.brand { font-family: var(--serif); font-weight: 700; font-size: 17px; color: var(--ink); text-decoration: none; }
.nav { display: flex; gap: 20px; font-size: 14px; }
.nav a { color: var(--ink-2); text-decoration: none; }
.nav a:hover { color: var(--ink); }

main { max-width: 1120px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px) 64px; }
.section { padding-top: 56px; }
.section + .section { border-top: 1px solid var(--line); margin-top: 56px; }
.section-title { font-size: 26px; }
.section-lede { color: var(--ink-2); max-width: 66ch; margin: 8px 0 22px; }

/* intro */
.intro { max-width: 72ch; margin-bottom: 22px; }
.intro h1 { font-size: clamp(26px, 3.6vw, 36px); font-weight: 700; }
.intro p { color: var(--ink-2); margin: 12px 0 0; font-size: 16px; }

/* map */
.map-frame { position: relative; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; background: var(--bg-2); }
.map { height: 560px; width: 100%; }
.map-legend { position: absolute; right: 12px; bottom: 12px; z-index: 500; background: color-mix(in srgb, var(--bg) 94%, transparent); border: 1px solid var(--line); border-radius: 6px; padding: 10px 12px; font-size: 13px; max-width: 260px; }
.legend-row { display: flex; align-items: center; gap: 8px; margin: 3px 0; }
.swatch { width: 18px; height: 12px; border-radius: 2px; display: inline-block; flex: none; }
.swatch.campus { background: color-mix(in srgb, var(--campus) 30%, transparent); border: 1.5px solid var(--campus); }
.swatch.line { height: 4px; background: var(--lrt); border-radius: 2px; }
.pin-sample { width: 20px; height: 20px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; color: #fff; font-size: 11px; font-weight: 700; flex: none; }
.pin-sample.r1 { background: var(--r1); }
.pin-sample.r2 { background: var(--r2); }
.legend-note { margin: 6px 0 0; color: var(--ink-3); font-size: 12px; line-height: 1.5; }

/* leaflet overrides */
.leaflet-container { font-family: var(--sans); background: var(--bg-2); }
.condo-pin { width: 24px; height: 24px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 1px 3px rgba(0,0,0,.35); color: #fff; font-weight: 700; font-size: 12px; display: flex; align-items: center; justify-content: center; }
.condo-pin.r1 { background: var(--r1); }
.condo-pin.r2 { background: var(--r2); }
.station-label, .area-label, .campus-label { background: none; border: 0; box-shadow: none; }
.station-label { font-size: 11px; color: #7a2445; font-weight: 600; text-shadow: 0 0 3px #fff, 0 0 3px #fff, 0 0 3px #fff; white-space: nowrap; }
.station-label.major { font-size: 12px; }
.area-label { font-family: var(--serif); font-size: 15px; font-weight: 700; color: #333; white-space: nowrap; text-shadow: 0 0 4px #fff, 0 0 4px #fff, 0 0 6px #fff; }
.area-label.r1 { color: #8f4a10; }
.area-label.r2 { color: #1d4d99; }
.campus-label { font-family: var(--serif); font-size: 14px; font-weight: 700; color: #2b6b44; white-space: nowrap; text-shadow: 0 0 4px #fff, 0 0 4px #fff; }
.leaflet-popup-content-wrapper { border-radius: 6px; font-size: 13px; }
.leaflet-popup-content { margin: 12px 14px; line-height: 1.55; }
.leaflet-popup-content h4 { margin: 0 0 4px; font-family: var(--serif); font-size: 15px; }
.leaflet-popup-content p { margin: 2px 0; }
.leaflet-popup-content a { color: var(--r2); }

/* glossary */
.glossary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; margin-top: 28px; }
.gloss h2 { font-size: 17px; margin-bottom: 6px; }
.gloss p { margin: 0; color: var(--ink-2); font-size: 14px; }

/* picks */
.picks { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.pick { border: 1px solid var(--line); border-radius: 6px; padding: 18px 20px; background: var(--bg); }
.pick h3 { font-size: 16px; margin-bottom: 10px; }
.pick ol { margin: 0; padding-left: 20px; }
.pick li { margin: 6px 0; font-size: 14px; color: var(--ink-2); }
.pick li a { font-weight: 700; color: var(--ink); }

/* toolbar */
.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; padding: 12px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); position: sticky; top: 45px; z-index: 20; background: var(--bg); }
.tool-group { display: inline-flex; border: 1px solid var(--line); border-radius: 4px; overflow: hidden; }
.tab { background: transparent; border: 0; padding: 6px 12px; cursor: pointer; font-size: 14px; color: var(--ink-2); }
.tab + .tab { border-left: 1px solid var(--line); }
.tab.is-on { background: var(--ink); color: var(--bg); }
.tool-check { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; color: var(--ink-2); cursor: pointer; }
.tool-check input { width: 15px; height: 15px; accent-color: var(--ink); margin: 0; }
.tool-more { position: relative; font-size: 14px; color: var(--ink-2); }
.tool-more summary { cursor: pointer; list-style: none; padding: 6px 10px; border: 1px solid var(--line); border-radius: 4px; }
.tool-more summary::-webkit-details-marker { display: none; }
.tool-more summary::after { content: " ▾"; color: var(--ink-3); }
.tool-more[open] summary { background: var(--bg-2); }
.tool-flags { position: absolute; top: calc(100% + 6px); left: 0; z-index: 25; background: var(--bg); border: 1px solid var(--line); border-radius: 6px; padding: 10px 12px; display: grid; grid-template-columns: repeat(2, max-content); gap: 6px 18px; box-shadow: 0 8px 24px -10px rgba(0,0,0,.25); }
.tool-flags label { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; cursor: pointer; }
.tool-flags input { accent-color: var(--ink); margin: 0; }
.tool-sort { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--ink-2); margin-left: auto; }
.tool-sort select, .intent-form select, .intent-form input, .intent-form textarea { background: var(--bg); border: 1px solid var(--line); border-radius: 4px; padding: 6px 9px; color: var(--ink); }
.tool-reset { background: none; border: 0; color: var(--ink-3); text-decoration: underline; cursor: pointer; font-size: 13px; }
.count { font-size: 13px; color: var(--ink-3); margin: 10px 0 14px; }

/* list */
.list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.card { border: 1px solid var(--line); border-radius: 6px; padding: 18px 20px 16px; background: var(--bg); display: grid; grid-template-columns: 30px 1fr; gap: 6px 14px; position: relative; }
.card:target { outline: 3px solid var(--focus); outline-offset: 2px; }
.card > *:not(.no) { grid-column: 2; }
.card .no { grid-column: 1; grid-row: 1 / span 20; width: 28px; height: 28px; border-radius: 50%; color: #fff; font-weight: 700; font-size: 13px; display: flex; align-items: center; justify-content: center; margin-top: 2px; }
.card.r1 .no { background: var(--r1); }
.card.r2 .no { background: var(--r2); }
.card h3 { font-size: 20px; line-height: 1.25; }
.card h3 small { display: block; font-family: var(--sans); font-weight: 400; font-size: 12px; color: var(--ink-3); margin-top: 1px; }
.card .go { margin: 4px 0 0; font-size: 14px; }
.card .go b { font-weight: 700; }
.card .go.none b { color: var(--r1); }
.card .facts { margin: 0; font-size: 13px; color: var(--ink-3); }
.card .facs { margin: 4px 0 0; font-size: 13px; color: var(--ink-2); }
.card .price { margin: 8px 0 0; padding-top: 8px; border-top: 1px dashed var(--line); font-size: 13px; }
.card .price p { margin: 2px 0; }
.card .price .src { color: var(--ink-3); }
.card .price .big { font-family: var(--serif); font-size: 15px; font-weight: 700; color: var(--ink); }
.card .flags { margin: 6px 0 0; font-size: 12px; color: var(--ink-3); }
.card .flags .ok { color: var(--ok); }
.card .flags .no-lrt { color: var(--r1); }
.card .acts { margin-top: 10px; display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; font-size: 13px; }
.btn { display: inline-flex; align-items: center; padding: 6px 12px; border-radius: 4px; border: 1px solid var(--line); background: var(--bg); text-decoration: none; font-size: 13px; cursor: pointer; color: var(--ink); }
.btn.primary { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.btn.primary:hover { opacity: .88; color: var(--bg); }
.linkish { background: none; border: 0; padding: 0; color: var(--r2); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; font-size: 13px; }
.card .who { position: absolute; top: 12px; right: 14px; font-size: 12px; color: var(--ink-3); }
.empty { color: var(--ink-3); padding: 32px 0; text-align: center; }

/* detail dialog */
.detail { border: 0; border-radius: 8px; padding: 0; max-width: min(720px, 94vw); width: 100%; background: var(--bg); color: var(--ink); box-shadow: 0 30px 80px -20px rgba(0,0,0,.45); }
.detail::backdrop { background: rgba(10,12,16,.5); }
.detail-inner { padding: 24px 26px 26px; max-height: 88vh; overflow: auto; position: relative; }
.detail-inner h2 { font-size: 24px; padding-right: 60px; }
.detail-inner .sub { color: var(--ink-3); font-size: 13px; margin: 4px 0 16px; }
.detail-close { position: absolute; top: 14px; right: 14px; }
.kv { display: grid; grid-template-columns: 96px 1fr; gap: 5px 14px; font-size: 14px; margin: 0 0 16px; }
.kv dt { color: var(--ink-3); }
.kv dd { margin: 0; }
.detail-inner h3 { font-size: 16px; margin: 16px 0 6px; }
.detail-inner ul { margin: 0; padding-left: 18px; font-size: 14px; }
.detail-inner li { margin: 3px 0; }
.detail-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }

/* intents */
.intents-body { display: grid; grid-template-columns: minmax(300px, 360px) 1fr; gap: 24px; align-items: start; }
.intent-form { border: 1px solid var(--line); border-radius: 6px; padding: 18px; display: flex; flex-direction: column; gap: 12px; }
.field { display: flex; flex-direction: column; gap: 5px; margin: 0; padding: 0; border: 0; min-width: 0; }
.field.two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field.two > div { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.field label, .field legend { font-size: 13px; color: var(--ink-2); }
.field input, .field select, .field textarea { width: 100%; }
.req { color: var(--lrt); font-size: 11px; margin-left: 4px; }
.hint { color: var(--ink-3); font-size: 12px; }
.field-inline { justify-content: flex-end; }
.condo-picks { display: flex; flex-wrap: wrap; gap: 5px; }
.condo-picks label { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; padding: 3px 9px; border: 1px solid var(--line); border-radius: 999px; cursor: pointer; color: var(--ink-2); }
.condo-picks input { width: 12px; height: 12px; accent-color: var(--ink); margin: 0; }
.condo-picks label:has(input:checked) { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.form-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.form-msg { font-size: 13px; color: var(--ink-2); }
.form-msg.ok { color: var(--ok); }
.form-msg.err { color: var(--lrt); }
.intent-summary { display: flex; flex-wrap: wrap; gap: 6px 22px; margin-bottom: 10px; font-size: 14px; color: var(--ink-2); }
.intent-summary b { font-family: var(--serif); font-size: 18px; color: var(--ink); margin-right: 4px; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 6px; }
.intent-table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 760px; }
.intent-table th { text-align: left; font-weight: 500; font-size: 12px; color: var(--ink-3); padding: 9px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; background: var(--bg-2); }
.intent-table td { padding: 8px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.intent-table tr:last-child td { border-bottom: 0; }
.intent-table .pick-chip { display: inline-block; font-size: 12px; padding: 0 7px; border-radius: 4px; background: var(--bg-2); margin: 1px 3px 1px 0; }
.intent-empty, .intent-offline { color: var(--ink-3); font-size: 14px; padding: 16px 2px; }

/* about + footer */
.about-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.about h3 { font-size: 16px; margin-bottom: 4px; }
.about p { color: var(--ink-2); margin: 0; font-size: 14px; }
.foot { border-top: 1px solid var(--line); padding: 20px clamp(16px, 4vw, 40px) 36px; font-size: 13px; color: var(--ink-3); }
.foot p { margin: 0; max-width: 1120px; margin-inline: auto; }

/* responsive */
@media (max-width: 960px) {
  .glossary, .picks, .about-cols { grid-template-columns: 1fr; gap: 18px; }
  .intents-body { grid-template-columns: 1fr; }
  .tool-sort { margin-left: 0; }
}
@media (max-width: 720px) {
  .nav { display: none; }
  .map { height: 62vh; min-height: 380px; }
  .map-legend { position: static; max-width: none; border-left: 0; border-right: 0; border-bottom: 0; border-radius: 0; }
  .list { grid-template-columns: 1fr; }
  .field.two { grid-template-columns: 1fr; }
  .toolbar { position: static; }
  .detail-inner { padding: 18px 16px 22px; }
  .kv { grid-template-columns: 84px 1fr; }
}

/* ===== guide blocks ===== */
.lead { padding: 52px 0 8px; max-width: 76ch; }
.lead h1 { font-size: clamp(28px, 4vw, 40px); font-weight: 700; }
.lead-sub { color: var(--ink-2); font-size: 17px; margin: 12px 0 18px; }
.lead-steps { margin: 0; padding: 0; list-style: none; counter-reset: step; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 6px 24px; }
.lead-steps li { counter-increment: step; display: flex; gap: 10px; align-items: baseline; font-size: 14px; padding: 6px 0; border-bottom: 1px dashed var(--line); }
.lead-steps li::before { content: counter(step); font-family: var(--serif); font-weight: 700; font-size: 18px; color: var(--ink-3); min-width: 18px; }
.lead-steps a { color: var(--ink); text-decoration: none; }
.lead-steps a:hover { text-decoration: underline; }
.step-eyebrow { font-family: var(--serif); font-size: 13px; letter-spacing: .12em; color: var(--ink-3); margin: 0 0 6px; }
.section-title { margin-bottom: 6px; }
.nav a.is-active { color: var(--ink); font-weight: 700; }
.muted { color: var(--ink-3); font-size: 13px; }
h3 { font-size: 16px; }

.map-reset { position: absolute; top: 12px; right: 12px; z-index: 500; font-size: 12px; padding: 5px 10px; border: 1px solid var(--line); border-radius: 4px; background: var(--bg); cursor: pointer; }
.howto { margin-top: 22px; max-width: 78ch; }
.howto h3, .glossary h3, .two-col h3, .three-col h3 { margin-bottom: 8px; }
.howto ol { margin: 0; padding-left: 22px; }
.howto li { margin: 8px 0; color: var(--ink-2); font-size: 14px; }
.howto li strong { color: var(--ink); }
.gloss dl { margin: 0; font-size: 14px; }
.gloss dt { font-weight: 700; margin-top: 8px; }
.gloss dd { margin: 0; color: var(--ink-2); }
.gloss code { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 13px; background: var(--bg-2); padding: 1px 5px; border-radius: 3px; }

.price-table { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 640px; }
.price-table th { text-align: left; font-weight: 500; font-size: 12px; color: var(--ink-3); background: var(--bg-2); padding: 9px 12px; border-bottom: 1px solid var(--line); }
.price-table td { padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.price-table td:first-child { font-weight: 700; white-space: nowrap; }
.price-table tr:last-child td { border-bottom: 0; }

.two-col { display: grid; grid-template-columns: minmax(300px, 440px) 1fr; gap: 28px; margin-top: 26px; align-items: start; }
.three-col { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; margin-top: 8px; }
.three-col h3 + h3, .three-col ul + h3, .monthly ul + h3 { margin-top: 18px; }
.plain { margin: 0; padding-left: 18px; font-size: 14px; color: var(--ink-2); }
.plain li { margin: 6px 0; }
.plain strong { color: var(--ink); }
.plain.compact li { margin: 3px 0; }

.calc { border: 1px solid var(--line); border-radius: 6px; padding: 18px 20px; background: var(--bg); }
.calc-hint { font-size: 14px; color: var(--ink-2); margin: 0 0 12px; }
.calc-input { display: flex; align-items: center; gap: 8px; font-size: 14px; margin-bottom: 12px; }
.calc-input input { width: 120px; font-size: 16px; font-weight: 700; padding: 6px 10px; border: 1px solid var(--line); border-radius: 4px; background: var(--bg); color: var(--ink); }
.calc-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.calc-table td { padding: 7px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.calc-table td:last-child { text-align: right; white-space: nowrap; }
.calc-table tr.total td { font-weight: 700; border-bottom: 0; font-size: 16px; font-family: var(--serif); }
.calc .muted { margin: 10px 0 0; }

.pick-note { margin: 10px 0 0; font-size: 13px; color: var(--ink-3); }

.tpl { position: relative; border: 1px solid var(--line); border-radius: 6px; background: var(--bg-2); padding: 12px 14px; }
.tpl pre { margin: 0; white-space: pre-wrap; font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12.5px; line-height: 1.6; color: var(--ink-2); padding-right: 52px; }
.copy { position: absolute; top: 8px; right: 8px; font-size: 12px; padding: 4px 9px; border: 1px solid var(--line); border-radius: 4px; background: var(--bg); cursor: pointer; }

.checks { list-style: none; margin: 0; padding: 0; font-size: 14px; }
.checks li { padding: 6px 0; border-bottom: 1px dashed var(--line); }
.checks label { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; color: var(--ink-2); }
.checks input { margin: 4px 0 0; accent-color: var(--ok); flex: none; }
.checks input:checked + * , .checks label:has(input:checked) { color: var(--ink-3); text-decoration: line-through; }
.callout { margin-top: 16px; padding: 12px 14px; border-left: 3px solid var(--r1); background: var(--bg-2); font-size: 14px; color: var(--ink-2); border-radius: 0 6px 6px 0; }
.callout strong { color: var(--ink); }

.timeline { list-style: none; margin: 8px 0 0; padding: 0 0 0 22px; border-left: 2px solid var(--line); }
.timeline li { position: relative; padding: 0 0 22px 18px; }
.timeline li::before { content: ""; position: absolute; left: -29px; top: 6px; width: 12px; height: 12px; border-radius: 50%; background: var(--bg); border: 3px solid var(--r2); }
.timeline h3 { font-size: 16px; margin-bottom: 4px; }
.timeline p { margin: 0; color: var(--ink-2); font-size: 14px; max-width: 70ch; }

@media (max-width: 960px) {
  .two-col, .three-col { grid-template-columns: 1fr; }
}

/* ===== map + side panel ===== */
.map-layout { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 14px; align-items: stretch; }
.map-panel { height: 560px; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 6px; background: var(--bg); overflow: hidden; }
.panel-list { overflow: auto; flex: 1; }
.panel-group { position: sticky; top: 0; z-index: 1; margin: 0; padding: 8px 14px; font-family: var(--serif); font-size: 13px; letter-spacing: .06em; color: var(--ink-3); background: var(--bg-2); border-bottom: 1px solid var(--line); }
.mrow { display: grid; grid-template-columns: 26px 1fr auto; gap: 4px 10px; align-items: center; width: 100%; text-align: left; padding: 9px 14px; border: 0; border-bottom: 1px solid var(--line); background: var(--bg); cursor: pointer; color: var(--ink); }
.mrow:hover { background: var(--bg-2); }
.mrow.is-on { background: color-mix(in srgb, var(--r2) 10%, var(--bg)); box-shadow: inset 3px 0 0 var(--r2); }
.mrow.r1.is-on { background: color-mix(in srgb, var(--r1) 10%, var(--bg)); box-shadow: inset 3px 0 0 var(--r1); }
.mrow .mno { width: 22px; height: 22px; border-radius: 50%; color: #fff; font-size: 11px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; grid-row: 1 / span 2; }
.mrow.r1 .mno { background: var(--r1); }
.mrow.r2 .mno { background: var(--r2); }
.mrow .mname { font-weight: 700; font-size: 14px; line-height: 1.3; }
.mrow .mwalk { font-size: 12px; color: var(--ink-2); white-space: nowrap; text-align: right; line-height: 1.3; }
.mrow .mwalk b { font-family: var(--serif); font-size: 15px; color: var(--ink); }
.mrow .mwalk.none { color: var(--r1); }
.mrow .msub { grid-column: 2 / span 2; font-size: 12px; color: var(--ink-3); line-height: 1.4; }
.panel-detail { padding: 14px 14px 12px; border-bottom: 2px solid var(--ink); background: var(--bg); font-size: 13px; }
.panel-detail h3 { font-size: 17px; margin: 0 40px 4px 0; line-height: 1.3; }
.panel-detail .pd-close { position: absolute; right: 10px; top: 10px; }
.panel-detail { position: relative; }
.panel-detail p { margin: 4px 0; color: var(--ink-2); }
.panel-detail p b { color: var(--ink); }
.panel-detail .pd-acts { display: flex; flex-wrap: wrap; gap: 6px 12px; margin-top: 8px; align-items: center; }
.condo-pin.is-on { transform: scale(1.35); box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px currentColor; z-index: 1000 !important; }
.condo-pin.r1.is-on { color: var(--r1); }
.condo-pin.r2.is-on { color: var(--r2); }
@media (max-width: 960px) {
  .map-layout { grid-template-columns: 1fr; }
  .map-panel { height: auto; max-height: 420px; }
}

/* ===== layout v3: wider page, taller map ===== */
main { max-width: 1400px; }
.lead { padding: 34px 0 6px; max-width: none; }
.lead h1 { font-size: clamp(28px, 3.4vw, 38px); }
.lead-sub { margin: 10px 0 14px; }
.lead-steps { display: flex; flex-wrap: wrap; gap: 4px 20px; }
.lead-steps li { border: 0; padding: 2px 0; font-size: 13px; }
.lead-steps li::before { font-size: 15px; min-width: 14px; }
.section { padding-top: 44px; }
.section + .section { margin-top: 44px; }
.map-layout { grid-template-columns: minmax(0, 1fr) 400px; margin-top: 10px; }
.map, .map-panel { height: clamp(600px, calc(100vh - 170px), 880px); }
.list { grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); }
.section-lede { max-width: 80ch; }
@media (max-width: 960px) {
  .map-layout { grid-template-columns: 1fr; }
  .map { height: 62vh; min-height: 380px; }
  .map-panel { height: auto; max-height: 420px; }
}

/* ===== map annotations + tour ===== */
.map-tools { position: absolute; top: 12px; right: 12px; z-index: 500; display: flex; gap: 8px; }
.map-tour-btn { font-size: 13px; font-weight: 700; padding: 6px 12px; border: 0; border-radius: 4px; background: var(--ink); color: var(--bg); cursor: pointer; box-shadow: 0 2px 8px rgba(0,0,0,.2); }
.map-reset { position: static; }
.tour-box { position: absolute; left: 60px; top: 12px; z-index: 600; max-width: 380px; background: color-mix(in srgb, var(--bg) 96%, transparent); border: 1px solid var(--line); border-left: 4px solid var(--ink); border-radius: 6px; padding: 12px 14px; box-shadow: 0 8px 24px -10px rgba(0,0,0,.35); }
.tour-step { font-family: var(--serif); font-size: 12px; letter-spacing: .1em; color: var(--ink-3); }
.tour-text { margin: 4px 0 10px; font-size: 14px; line-height: 1.6; }
.tour-text b { color: var(--ink); }
.tour-acts { display: flex; gap: 8px; align-items: center; }
.lm-icon { background: none; border: 0; }
.lm-icon .lm { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; color: #222; background: rgba(255,255,255,.92); border: 1px solid rgba(0,0,0,.15); border-radius: 4px; padding: 2px 7px 2px 5px; white-space: nowrap; box-shadow: 0 1px 3px rgba(0,0,0,.2); }
.lm-icon .lm .ico { width: 14px; height: 14px; border-radius: 3px; display: inline-block; flex: none; }
.lm-icon .lm.gate .ico { background: #2b6b44; border-radius: 50%; }
.lm-icon .lm.mall .ico { background: #6b4fbb; }
.lm-icon .lm.hosp .ico { background: #c0392b; }
.lm-icon .lm.edu .ico { background: #2b6b44; }
.lm-icon .lm.gate { border-color: #2b6b44; color: #1f4f33; }
.walk-label { background: none; border: 0; box-shadow: none; font-size: 11px; font-weight: 700; color: #b0285a; text-shadow: 0 0 3px #fff, 0 0 3px #fff; white-space: nowrap; }
.area-label { font-size: 16px; }
@keyframes pinpulse { 0% { box-shadow: 0 0 0 0 rgba(0,0,0,.35); } 70% { box-shadow: 0 0 0 12px rgba(0,0,0,0); } 100% { box-shadow: 0 0 0 0 rgba(0,0,0,0); } }
.condo-pin.pulse { animation: pinpulse 1.2s ease-out infinite; }
.condo-pin.dim { opacity: .25; }
@media (prefers-reduced-motion: reduce) { .condo-pin.pulse { animation: none; box-shadow: 0 0 0 4px rgba(0,0,0,.25); } }
@media (max-width: 720px) {
  .tour-box { left: 12px; right: 12px; max-width: none; top: 56px; }
  .map-tools { top: 12px; right: 12px; }
}
.swatch.walk { height: 10px; border: 1.5px dashed var(--lrt); background: color-mix(in srgb, var(--lrt) 8%, transparent); border-radius: 50%; width: 16px; }
.leaflet-container.z-low .lm-icon .lm:not(.gate), .leaflet-container.z-low .walk-label { display: none; }

/* ===== step 1 text layout + common traits ===== */
.howto { max-width: none; }
.howto ol { display: grid; grid-template-columns: repeat(2, 1fr); gap: 4px 40px; padding-left: 22px; }
.glossary { grid-template-columns: repeat(2, 1fr); gap: 40px; margin-top: 30px; }
.gloss dl { display: grid; grid-template-columns: max-content 1fr; gap: 8px 16px; align-items: baseline; }
.gloss dt { margin: 0; white-space: nowrap; }
.gloss dd { margin: 0; }
.common { border: 1px solid var(--line); border-radius: 6px; padding: 18px 22px 14px; margin: 0 0 22px; background: var(--bg-2); }
.common h3 { font-size: 17px; margin-bottom: 10px; }
.common-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 4px 40px; padding-left: 18px; }
.about-cols { margin-top: 12px; grid-template-columns: 1fr 1fr; }
@media (max-width: 960px) {
  .howto ol, .glossary, .common-list, .about-cols { grid-template-columns: 1fr; }
  .gloss dl { grid-template-columns: 1fr; gap: 2px; }
  .gloss dt { margin-top: 8px; }
}
.intent-table .del { color: var(--lrt); font-size: 12px; }
.intent-table .mine { font-size: 11px; color: var(--ok); border: 1px solid var(--ok); border-radius: 3px; padding: 0 4px; margin-left: 4px; }
.intent-admin { font-size: 12px; color: var(--ink-3); margin: 10px 2px 0; }
.intent-admin .linkish { font-size: 12px; }

/* ===== lead v4: title + freshness badge, one-line steps ===== */
.lead-head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; }
.fresh { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; color: var(--ink-2); border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px 5px 10px; background: var(--bg-2); white-space: nowrap; }
.fresh-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 3px color-mix(in srgb, var(--ok) 20%, transparent); }
.fresh time { font-weight: 700; color: var(--ink); }
.lead-sub { margin: 10px 0 8px; }
.lead-steps-line { margin: 12px 0 0; display: flex; flex-wrap: wrap; gap: 6px 8px; font-size: 13px; }
.lead-steps-line a { color: var(--ink); text-decoration: none; border: 1px solid var(--line); border-radius: 999px; padding: 3px 11px; background: var(--bg); }
.lead-steps-line a:hover { border-color: var(--ink); }
.intent-form input[type="date"] { min-height: 34px; }

.map-style { font-size: 13px; padding: 5px 8px; border: 1px solid var(--line); border-radius: 4px; background: var(--bg); color: var(--ink); }
.leaflet-container .maplibregl-map { font-family: var(--sans); }

/* ===== mobile fixes ===== */
.list { grid-template-columns: repeat(auto-fill, minmax(min(380px, 100%), 1fr)); }
.two-col > *, .three-col > *, .intents-body > * { min-width: 0; }
.map-tools .short { display: none; }
@media (max-width: 720px) {
  .calc-table td:last-child { white-space: normal; }
  .map-tools { top: auto; bottom: 28px; left: 10px; right: 10px; justify-content: flex-end; flex-wrap: nowrap; gap: 6px; }
  .map-tools > * { font-size: 12px; padding: 5px 8px; white-space: nowrap; }
  .map-style { max-width: 96px; }
  .map-tools .long { display: none; }
  .map-tools .short { display: inline; }
  .tour-box { top: 10px; left: 10px; right: 10px; max-width: none; padding: 10px 12px; }
  .tour-text { font-size: 13px; }
  .section-title { font-size: 22px; }
  .lead h1 { font-size: 26px; }
  .fresh { font-size: 12px; }
  .price-table { min-width: 560px; }
}
@media (max-width: 720px) {
  .leaflet-control-zoom { display: none; } /* 手机上双指缩放，给导览框腾位置 */
}
