:root {
    --side-bg: #1B2E4F; --side-hover: color-mix(in srgb, #1B2E4F, white 8%); --side-line: color-mix(in srgb, #1B2E4F, white 12%); --side-text: #C3C4C7; --side-muted: #8C8F94;
    --accent: #2C5F8A; --bg: #F0F0F1; --card: #FFFFFF; --cap: #F6F7F7;
    --ink: #1D2327; --slate: #50575E; --line: #DCDCDE;
    --side: 220px;
  }
  * { box-sizing: border-box; }
  body {
    margin: 0; background: var(--bg); color: var(--ink);
    font: 15px/1.6 -apple-system, BlinkMacSystemFont, "PingFang HK", "Microsoft JhengHei", "Segoe UI", sans-serif;
  }
  a { color: inherit; text-decoration: none; }
  :focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

  /* sidebar */
  .side { position: fixed; inset: 0 auto 0 0; width: var(--side); background: var(--side-bg); color: var(--side-text);
    display: flex; flex-direction: column; overflow-y: auto; z-index: 20; }
  .brand { display: block; padding: 16px 18px; font-size: 17px; font-weight: 600; color: #fff; border-bottom: 1px solid var(--side-line); }
  .brand-logo { display: block; padding: 10px 14px; background: var(--side-bg); border-bottom: 1px solid var(--side-line); }
  .brand-logo img { display: block; width: 100%; height: auto; margin: 0 auto; }
  .nav { list-style: none; margin: 8px 0; padding: 0; }
  .nav a { display: block; padding: 9px 18px; font-size: 14px; }
  .nav a:hover { background: var(--side-hover); color: #fff; }
  .nav a[aria-current="page"] { background: color-mix(in srgb, var(--side-bg), white 14%); color: #fff; }

  .filters { padding: 14px 18px 20px; border-top: 1px solid var(--side-line); }
  .filters h2 { font-size: 13px; font-weight: 600; color: #fff; margin: 0 0 4px; }
  .filters label { display: block; font-size: 12px; color: var(--side-muted); margin: 12px 0 4px; }
  .filters select { width: 100%; font: inherit; font-size: 14px; min-height: 36px; padding: 0 8px;
    border: 1px solid #8C8F94; border-radius: 3px; background: #fff; color: var(--ink); }
  .rooms { display: flex; flex-wrap: wrap; gap: 4px; }
  .rooms button { font: inherit; font-size: 13px; min-height: 32px; padding: 0 10px; border: 1px solid #50575E;
    border-radius: 3px; background: transparent; color: var(--side-text); cursor: pointer; white-space: nowrap; }
  .rooms button[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: #fff; }
  .side-foot { margin-top: auto; padding: 14px 18px; font-size: 12px; color: var(--side-muted); border-top: 1px solid var(--side-line); }

  /* main */
  .main { margin-left: var(--side); padding: 20px 28px 40px; }

  .hero { position: relative; margin: -20px -28px 24px; height: 300px;
    background: #2a3a48 center 45% / cover no-repeat; display: flex; align-items: flex-end; }
  .hero::after { content: ""; position: absolute; inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,.68), rgba(0,0,0,0) 65%); }
  .hero-text { position: relative; z-index: 1; padding: 24px 28px; color: #fff; text-shadow: 0 2px 10px rgba(0,0,0,.45); }
  .hero-text h2 { margin: 0; font-size: 26px; font-weight: 600; }
  .hero-text p { margin: 6px 0 0; font-size: 15px; opacity: .92; }

  .hero-tag { margin: 0 0 6px; font-size: 16px; font-weight: 600; letter-spacing: .02em; opacity: .95; }
  .head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-bottom: 20px; }
  .head h1 { margin: 0; font-size: 23px; font-weight: 400; }
  .count { background: #646970; color: #fff; font-size: 12px; font-weight: 600; min-width: 22px; height: 22px;
    padding: 0 7px; border-radius: 11px; display: inline-grid; place-items: center; }
  .search { margin-left: auto; width: 260px; font: inherit; font-size: 14px; min-height: 34px; padding: 0 10px;
    border: 1px solid #8C8F94; border-radius: 3px; background: #fff; }

  .grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 24px; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
  .card a { display: block; background: var(--card); border: 1px solid var(--line); box-shadow: 0 1px 1px rgba(0,0,0,.04); }
  .card a:hover { border-color: #8C8F94; }
  .media { aspect-ratio: 4 / 3; background: #E5E5E5; position: relative; }
  .media img { width: 100%; height: 100%; object-fit: cover; display: block; }
  .noimg { position: absolute; inset: 0; display: grid; place-items: center; color: #8C8F94; font-size: 14px; }
  .cap { background: var(--cap); border-top: 1px solid var(--line); padding: 12px 15px; }
  .cap-row { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; }
  .estate { margin: 0; font-size: 16px; font-weight: 600; }
  .price { font-size: 16px; font-weight: 600; white-space: nowrap; }
  .meta { margin: 2px 0 0; color: var(--slate); font-size: 13px; }

  .empty { grid-column: 1 / -1; padding: 48px 20px; text-align: center; color: var(--slate); border: 2px dashed #C3C4C7; }
  .empty button { margin-top: 10px; font: inherit; font-size: 14px; min-height: 34px; padding: 0 14px;
    border: 1px solid var(--accent); color: var(--accent); background: #fff; border-radius: 3px; cursor: pointer; }

  /* mobile */
  .topbar, .scrim { display: none; }
  @media (max-width: 860px) {
    .side { transform: translateX(-100%); transition: transform .2s ease; }
    body.open .side { transform: none; }
    body.open .scrim { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 15; }
    .topbar { display: flex; justify-content: space-between; align-items: center; position: sticky; top: 0; z-index: 10;
      background: var(--side-bg); color: #fff; padding: 8px 16px; }
    .topbar .brand { padding: 0; border: 0; }
    .topbar-logo { display: block; height: 40px; width: auto; }
    .topbar button { font: inherit; font-size: 14px; min-height: 36px; padding: 0 12px; border: 1px solid #50575E;
      border-radius: 3px; background: none; color: #fff; cursor: pointer; }
    .main { margin-left: 0; padding: 16px; }
    .hero { margin: -16px -16px 16px; height: 220px; }
    .hero-text { padding: 16px; }
    .hero-text h2 { font-size: 21px; }
    .search { margin-left: 0; width: 100%; }
  }
  @media (prefers-reduced-motion: reduce) { .side { transition: none; } }
  .features { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; margin: 0 0 28px; }
  .feat { background: #fff; border: 1px solid #dcdcde; border-top: 3px solid var(--side-bg); padding: 16px 18px; }
  .feat-no { display: block; font-size: 12px; font-weight: 600; letter-spacing: .08em; color: #8c8f94; margin-bottom: 6px; }
  .feat h3 { margin: 0 0 6px; font-size: 16px; font-weight: 600; color: #1d2327; }
  .feat p { margin: 0; font-size: 14px; line-height: 1.6; color: #50575e; }
  @media (max-width: 860px) {
    .features { grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 20px; }
    .feat { padding: 10px 12px; border-top-width: 2px; }
    .feat-no { font-size: 11px; margin-bottom: 2px; }
    .feat h3 { font-size: 15px; margin: 0; }
    .feat p { margin-top: 4px; font-size: 12.5px; line-height: 1.5; }
    .feat:last-child { grid-column: 1 / -1; }
  }
  .features { padding-bottom: 24px; border-bottom: 1px solid #dcdcde; }
  @media (max-width: 860px) { .features { padding-bottom: 16px; } }
  /* hero-mobile-v2 */
  @media (max-width: 860px) {
    .hero { height: 150px; }
    .hero-bg { background-size: cover; background-position: center center; }
    .hero-text h2 { font-size: 20px; margin: 0 0 4px; }
    .hero-text p { font-size: 13px; margin: 0; }
  }
  .more { margin-top: 16px; border-top: 1px solid var(--side-line); }
  .more summary { cursor: pointer; padding: 12px 0 4px; font-size: 14px; font-weight: 600; color: #fff; list-style-position: inside; }
  .more summary span { font-weight: 400; color: #c3c4c7; }
  .pair { display: flex; gap: 6px; }
  .pair select { flex: 1; min-width: 0; }
  .filters input[type=number] { width: 100%; box-sizing: border-box; min-height: 36px; padding: 0 10px;
    font: inherit; font-size: 14px; color: #1d2327; background: #fff; border: 1px solid #8c8f94; border-radius: 4px; }
  .filters .check { display: flex; align-items: center; gap: 8px; margin-top: 10px; color: #fff; font-size: 14px; cursor: pointer; }
  .filters .check input { width: 16px; height: 16px; margin: 0; accent-color: #2271b1; }
  .filters .reset { margin-top: 14px; width: 100%; min-height: 34px; font: inherit; font-size: 13px; color: #c3c4c7;
    background: none; border: 1px solid var(--side-line); border-radius: 3px; cursor: pointer; }
  .filters .reset:hover { color: #fff; border-color: #c3c4c7; }
