:root {
      --sun: #FFD77A;
      --orange: #F57A3E;
      --mauve: #A94768;
      --plum: #5A315B;

      --ink: #25283A;
      --ink-dark: #181725;

      --paper: #FFF9F0;
      --cream: #FFF4E1;
      --panel: #F7EDD9;
      --soft: #F2E5CE;

      --muted: #746874;
      --line: #D9CDBD;
      --line-dark: #40313F;
      --shadow: #A5A09A;
    }

    * {
      box-sizing: border-box;
    }

    html {
      scroll-behavior: smooth;
    }

    body {
      margin: 0;
      min-height: 100vh;
      background: var(--paper);
      color: var(--ink);
      font-family: "Space Grotesk", system-ui, sans-serif;
    }

    body.theme-dark {
      --ink: #F5EEE7;
      --ink-dark: #F5EEE7;
      --paper: #17151D;
      --cream: #24202B;
      --panel: #211D27;
      --soft: #2B2631;
      --muted: #B9ADB7;
      --line: #403946;
      --line-dark: #6C6170;
      --shadow: #09080C;
      --plum: #C88CC6;
      background: var(--paper);
      color: var(--ink);
    }

    button,
    input,
    select {
      font: inherit;
    }

    button,
    input,
    select {
      outline: none;
    }

    .page-shell {
      width: min(1480px, 94vw);
      margin: 0 auto;
      padding: 22px 0 64px;
    }

    /* ==========================================
       HEADER
       Mismo lenguaje visual que la landing principal
    ========================================== */

    .topbar {
      min-height: 58px;
      padding: 8px 0 10px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 24px;
    }

    .brand {
      display: flex;
      align-items: center;
      gap: 12px;
      color: var(--ink);
      text-decoration: none;
    }

    .brand-mark {
      width: 34px;
      height: 34px;
      display: grid;
      place-items: center;
      border: 2px solid var(--ink);
      background: rgba(245, 122, 62, .10);
      box-shadow: 4px 4px 0 rgba(37, 40, 58, .24);
      color: var(--ink);
      font-family: "Press Start 2P", monospace;
      font-size: 10px;
    }

    .brand-name {
      font-family: "Press Start 2P", monospace;
      font-size: 12px;
      line-height: 1;
      color: var(--ink);
      text-transform: uppercase;
    }

    .top-nav {
      display: flex;
      transform: translateX(18px);
      align-items: center;
      gap: 6px;
      padding: 6px;
      border: 1px solid rgba(255, 255, 255, .25);
      border-radius: 999px;
      background: rgba(72, 39, 64, .78);
      backdrop-filter: blur(10px);
      -webkit-backdrop-filter: blur(10px);
      box-shadow: 0 4px 0 rgba(37, 26, 43, .22);
    }

    .top-nav a {
      padding: 11px 15px;
      border-radius: 999px;
      color: white;
      text-decoration: none;
      font-family: "Press Start 2P", monospace;
      font-size: 9px;
      line-height: 1;
      font-weight: 400;
      white-space: nowrap;
      text-transform: uppercase;
      transition: background .16s ease, transform .16s ease;
    }

    .top-nav a:hover {
      background: rgba(255, 255, 255, .12);
    }

    .top-nav .nav-highlight {
      background: var(--sun);
      color: #181725;
      box-shadow: 0 3px 0 rgba(37, 40, 58, .28);
    }

    .top-nav .nav-highlight:hover {
      background: #FFE29A;
      transform: translateY(-1px);
    }

    .top-nav a.active:not(.nav-highlight) {
      background: rgba(255,255,255,.12);
      color: white;
    }

    body.theme-dark .brand,
    body.theme-dark .brand-name,
    body.theme-dark .brand-mark {
      color: var(--ink);
    }

    body.theme-dark .brand-mark {
      border-color: var(--line-dark);
      background: rgba(245, 122, 62, .14);
      box-shadow: 4px 4px 0 #09080C;
    }

    body.theme-dark .retro-input,
    body.theme-dark .choice-ui,
    body.theme-dark .checkbox-ui,
    body.theme-dark .retro-button,
    body.theme-dark .pager-btn,
    body.theme-dark .sort-select,
    body.theme-dark .theme-switch {
      background: #221E29;
      color: var(--ink);
      border-color: var(--line-dark);
    }

    body.theme-dark .choice-ui:hover,
    body.theme-dark .property-row:hover {
      background: #2A2430;
    }

    body.theme-dark .choice input:checked + .choice-ui,
    body.theme-dark .check-line input:checked + .checkbox-ui,
    body.theme-dark .retro-button.primary,
    body.theme-dark .pager-btn.active,
    body.theme-dark .theme-option.active {
      background: var(--sun);
      color: #181725;
    }

    body.theme-dark .mini-tag {
      color: var(--ink);
    }

    body.theme-dark .mini-tag.operation {
      color: #181725;
    }

    body.theme-dark .publication-link {
      background: #221E29;
      color: var(--ink);
      border-color: var(--line-dark);
    }

    body.theme-dark .results-table-head {
      background: #27222E;
    }


    body.theme-dark .filters-header {
      background: #4A2B4D;
      border-color: #7A6A7E;
    }

    body.theme-dark .results-table-head {
      background: #27222E;
      border-color: var(--line-dark);
    }


    /* Selector de tema: fuera de la navegación principal */
    .theme-control {
      margin-top: 18px;
      padding-top: 16px;
      border-top: 1px solid var(--line);
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
    }

    .theme-control-label {
      font-family: "Press Start 2P", monospace;
      font-size: 6px;
      color: var(--plum);
      text-transform: uppercase;
    }

    .theme-switch {
      display: inline-flex;
      align-items: center;
      border: 1px solid var(--line-dark);
      border-radius: 2px;
      background: white;
      box-shadow: 2px 2px 0 var(--shadow);
    }

    .theme-option {
      min-height: 27px;
      padding: 0 8px;
      border: 0;
      background: transparent;
      color: var(--ink);
      cursor: pointer;
      font-family: "Press Start 2P", monospace;
      font-size: 5px;
      text-transform: uppercase;
    }

    .theme-option + .theme-option {
      border-left: 1px solid var(--line-dark);
    }

    .theme-option.active {
      background: var(--sun);
      color: #181725;
    }

    /* ==========================================
       INTRO
    ========================================== */

    .dataset-intro {
      padding: 26px 0 22px;
      max-width: 780px;
    }

    .pixel-accent {
      display: flex;
      gap: 5px;
      margin-bottom: 11px;
    }

    .pixel-accent span {
      width: 8px;
      height: 8px;
      background: var(--orange);
    }

    .pixel-accent span:nth-child(2) { background: var(--mauve); }
    .pixel-accent span:nth-child(3) { background: var(--plum); }
    .pixel-accent span:nth-child(4) { background: var(--sun); }

    h1 {
      margin: 0;
      font-size: clamp(32px, 3.8vw, 50px);
      line-height: .98;
      letter-spacing: -.045em;
      font-weight: 700;
    }

    .intro-copy {
      margin: 12px 0 0;
      max-width: 680px;
      font-size: 15px;
      line-height: 1.55;
      color: var(--muted);
    }

    /* ==========================================
       MAIN LAYOUT
    ========================================== */

    .dataset-layout {
      display: grid;
      grid-template-columns: 286px minmax(0, 1fr);
      gap: 32px;
      align-items: start;
      margin-top: 34px;
    }

    /* ==========================================
       FILTERS
    ========================================== */

    .filters {
      position: sticky;
      top: 18px;
      padding-right: 24px;
      border-right: 1px solid var(--line);
      font-family: "Press Start 2P", monospace;
    }

    .filters-header {
      min-height: 31px;
      margin-bottom: 22px;
      padding: 0 9px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      border: 1px solid var(--line-dark);
      background: var(--plum);
      box-shadow: 3px 3px 0 var(--shadow);
    }

    .filters-title {
      margin: 0;
      font-family: "Press Start 2P", monospace;
      font-size: 7px;
      line-height: 1;
      text-transform: uppercase;
      color: var(--paper);
    }

    .filters-close-icon {
      position: relative;
      width: 12px;
      height: 12px;
      flex: 0 0 auto;
      border: 2px solid #382B3A;
      background: #8D8D8D;
      box-shadow:
        inset 1px 1px 0 #D8D8D8,
        inset -1px -1px 0 #555,
        1px 1px 0 rgba(0,0,0,.14);
    }

    .filters-close-icon::after {
      content: "";
      position: absolute;
      top: 2px;
      left: 2px;
      width: 4px;
      height: 4px;
      border: 1px solid #5B5B5B;
      background: #C7C7C7;
    }

    .filter-group {
      padding-bottom: 20px;
      margin-bottom: 20px;
      border-bottom: 1px solid var(--line);
    }

    .filter-group:last-of-type {
      margin-bottom: 14px;
    }

    .filter-label {
      display: block;
      margin-bottom: 10px;
      font-family: "Press Start 2P", monospace;
      font-size: 7px;
      line-height: 1.5;
      text-transform: uppercase;
      color: var(--ink);
    }

    .retro-input {
      width: 100%;
      height: 40px;
      padding: 0 11px;
      border: 1px solid var(--line-dark);
      border-radius: 2px;
      background: white;
      color: var(--ink);
      font-family: "Press Start 2P", monospace;
      font-size: 7px;
      line-height: 1.5;
    }

    .retro-input:focus {
      border-color: var(--orange);
      box-shadow: 0 0 0 2px rgba(245,122,62,.12);
    }

    .retro-input::placeholder {
      color: #A19499;
    }

    .choice-grid {
      display: flex;
      flex-wrap: wrap;
      gap: 7px;
    }

    .choice {
      position: relative;
      cursor: pointer;
      user-select: none;
    }

    .choice input {
      position: absolute;
      opacity: 0;
      pointer-events: none;
    }

    .choice-ui {
      min-height: 32px;
      padding: 0 10px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 7px;
      border: 1px solid var(--line-dark);
      border-radius: 2px;
      background: white;
      color: var(--ink);
      font-family: "Press Start 2P", monospace;
      font-size: 7px;
      line-height: 1.45;
      transition:
        transform .10s ease,
        box-shadow .10s ease,
        background .10s ease,
        border-color .10s ease;
    }

    .choice-ui:hover {
      transform: translateY(-1px);
      border-color: var(--plum);
      background: #FFF7EA;
    }

    .choice input:checked + .choice-ui {
      background: var(--sun);
      border-color: var(--ink-dark);
      box-shadow: 2px 2px 0 var(--shadow);
    }

    .choice input:checked + .choice-ui::before {
      content: "";
      width: 6px;
      height: 6px;
      flex: 0 0 auto;
      background: var(--plum);
    }

    .stable-choice-grid {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .stable-choice-grid .choice {
      min-width: 0;
    }

    .stable-choice-grid .choice-ui {
      width: 100%;
    }

    .bedroom-choice-grid {
      grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .price-grid {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 8px;
    }

    .price-no-value {
      margin-top: 12px;
    }

    .check-line {
      display: flex;
      align-items: center;
      gap: 9px;
      cursor: pointer;
      user-select: none;
    }

    .check-line input {
      position: absolute;
      opacity: 0;
      pointer-events: none;
    }

    .checkbox-ui {
      width: 16px;
      height: 16px;
      display: grid;
      place-items: center;
      flex: 0 0 auto;
      border: 1px solid var(--line-dark);
      background: white;
      box-shadow: 2px 2px 0 var(--shadow);
    }

    .check-line input:checked + .checkbox-ui {
      background: var(--sun);
    }

    .check-line input:checked + .checkbox-ui::after {
      content: "";
      width: 6px;
      height: 6px;
      background: var(--plum);
    }

    .check-line span:last-child {
      font-family: "Press Start 2P", monospace;
      font-size: 7px;
      line-height: 1.55;
      color: #5D525E;
    }

    .filters-actions {
      margin-bottom: 20px;
      padding-bottom: 18px;
      display: flex;
      gap: 8px;
      border-bottom: 1px solid var(--line);
    }

    .retro-button {
      min-height: 38px;
      padding: 0 12px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      border: 1px solid var(--ink-dark);
      border-radius: 2px;
      background: white;
      color: var(--ink-dark);
      box-shadow: 3px 3px 0 var(--shadow);
      cursor: pointer;
      font-family: "Press Start 2P", monospace;
      font-size: 7px;
      line-height: 1.35;
      text-align: center;
      text-decoration: none;
      text-transform: uppercase;
      transition: transform .1s ease, box-shadow .1s ease, background .1s ease;
    }

    .retro-button.primary {
      background: var(--sun);
    }

    .retro-button:hover {
      transform: translate(1px, 1px);
      box-shadow: 2px 2px 0 var(--shadow);
    }

    .retro-button:active {
      transform: translate(3px, 3px);
      box-shadow: none;
    }

    /* ==========================================
       RESULTS
    ========================================== */

    .results {
      min-width: 0;
    }

    .results-header {
      min-height: 52px;
      margin-bottom: 8px;
      padding: 8px 0 10px;
      display: flex;
      align-items: flex-end;
      justify-content: space-between;
      gap: 20px;
      border-bottom: 1px solid var(--line);
    }

    .results-header h2 {
      margin: 0;
      display: flex;
      align-items: center;
      gap: 7px;
      font-family: "Press Start 2P", monospace;
      font-size: 8px;
      line-height: 1.5;
      letter-spacing: 0;
      text-transform: uppercase;
      color: var(--plum);
    }

    .results-header h2 #resultsCount {
      color: var(--orange);
      font-size: 10px;
    }

    .results-tools {
      display: flex;
      flex-direction: column;
      align-items: flex-end;
      gap: 7px;
    }

    .results-theme-control {
      margin: 0;
      padding: 0;
      border-top: 0;
      justify-content: flex-end;
    }

    .sort-control {
      display: flex;
      align-items: center;
      justify-content: flex-end;
      gap: 9px;
      white-space: nowrap;
    }

    .sort-label {
      font-family: "Press Start 2P", monospace;
      font-size: 6px;
      color: var(--plum);
      text-transform: uppercase;
    }

    .sort-select {
      height: 32px;
      min-width: 142px;
      padding: 0 28px 0 9px;
      border: 1px solid var(--line-dark);
      border-radius: 2px;
      background: white;
      color: var(--ink);
      cursor: pointer;
      font-family: "Press Start 2P", monospace;
      font-size: 6px;
      box-shadow: 2px 2px 0 var(--shadow);
    }

    .sort-select:focus {
      border-color: var(--orange);
      box-shadow:
        2px 2px 0 var(--shadow),
        0 0 0 2px rgba(245,122,62,.12);
    }

    .results-table-wrap {
      width: 100%;
      overflow-x: auto;
    }

    .results-table-head,
    .property-row {
      min-width: 980px;
      display: grid;
      grid-template-columns:
        112px
        minmax(210px, 1.45fr)
        118px
        78px
        68px
        112px
        minmax(135px, .9fr)
        105px;
      gap: 13px;
      align-items: center;
    }

    .results-table-head {
      min-height: 32px;
      padding: 8px 10px;
      border-top: 1px solid var(--line);
      border-bottom: 1px solid var(--line-dark);
      background: rgba(242, 229, 206, .72);
      font-family: "Press Start 2P", monospace;
      font-size: 5.5px;
      line-height: 1.45;
      color: var(--plum);
      text-transform: uppercase;
    }

    .results-list {
      display: flex;
      flex-direction: column;
      min-width: 980px;
    }

    .property-row {
      position: relative;
      padding: 17px 10px;
      border-bottom: 1px solid var(--line);
      cursor: pointer;
      transition:
        background .12s ease,
        padding-left .12s ease;
    }

    .property-row:hover {
      padding-left: 28px;
      background: #FFF4E2;
    }

    .property-row::before {
      content: "▶";
      position: absolute;
      left: 9px;
      top: 50%;
      transform: translateY(-50%);
      opacity: 0;
      color: var(--orange);
      font-family: "Press Start 2P", monospace;
      font-size: 7px;
      line-height: 1;
      transition: opacity .12s ease;
    }

    .property-row:hover::before {
      opacity: 1;
    }

    .mini-tag {
      min-height: 19px;
      padding: 0 6px;
      display: inline-flex;
      align-items: center;
      border: 1px solid var(--line-dark);
      background: var(--cream);
      font-family: "Press Start 2P", monospace;
      font-size: 5.5px;
      line-height: 1;
      text-transform: uppercase;
    }

    .mini-tag.operation {
      background: var(--sun);
    }

    .address-title {
      margin: 0;
      font-size: 17px;
      line-height: 1.25;
      font-weight: 700;
    }

    .address-sub {
      margin: 4px 0 0;
      font-size: 13px;
      color: var(--muted);
    }

    .property-price {
      font-size: 18px;
      line-height: 1.2;
      font-weight: 700;
      color: var(--plum);
    }

    .property-price.no-price {
      font-size: 13px;
      font-weight: 600;
      color: var(--muted);
    }

    .table-value {
      min-width: 0;
      font-size: 13px;
      line-height: 1.35;
      color: #615762;
    }

    .table-value strong {
      color: var(--ink);
      font-weight: 700;
    }

    .type-value {
      font-weight: 600;
      color: var(--ink);
    }

    .agency {
      margin: 0;
      font-size: 13px;
      line-height: 1.35;
      font-weight: 700;
    }

    .source-line {
      display: flex;
      align-items: center;
      gap: 6px;
      font-size: 12px;
      color: var(--muted);
    }

    .source-pixel {
      width: 7px;
      height: 7px;
      background: var(--orange);
    }

    .publication-link {
      min-height: 25px;
      padding: 0 7px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 5px;
      border: 1px solid var(--line-dark);
      border-radius: 2px;
      background: var(--cream);
      box-shadow: 2px 2px 0 var(--shadow);
      color: var(--plum);
      font-family: "Press Start 2P", monospace;
      font-size: 4.8px;
      line-height: 1;
      text-decoration: none;
      text-transform: uppercase;
      white-space: nowrap;
      transition: transform .1s ease, box-shadow .1s ease, background .1s ease;
    }

    .publication-link::before {
      content: "";
      width: 6px;
      height: 6px;
      flex: 0 0 auto;
      border: 1px solid var(--line-dark);
      background: var(--sun);
    }

    .publication-link:hover {
      transform: translate(1px, 1px);
      box-shadow: 1px 1px 0 var(--shadow);
      background: #FFF0D4;
    }

    .publication-link:active {
      transform: translate(2px, 2px);
      box-shadow: none;
    }

    .empty-state {
      display: none;
      padding: 40px 0;
      text-align: center;
      color: var(--muted);
    }

    .empty-state strong {
      display: block;
      margin-bottom: 10px;
      font-family: "Press Start 2P", monospace;
      font-size: 8px;
      color: var(--plum);
    }

    .results-footer {
      padding-top: 22px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 20px;
    }

    .data-note {
      max-width: 600px;
      font-size: 12px;
      color: var(--muted);
    }

    .pager {
      display: flex;
      gap: 6px;
    }

    .pager-btn {
      width: 34px;
      height: 32px;
      border: 1px solid var(--ink-dark);
      border-radius: 2px;
      background: white;
      box-shadow: 2px 2px 0 var(--shadow);
      cursor: pointer;
      font-family: "Press Start 2P", monospace;
      font-size: 6px;
    }

    .pager-btn.active {
      background: var(--sun);
    }

    /* ==========================================
       RESPONSIVE
    ========================================== */

    @media (max-width: 1100px) {
      .dataset-layout {
        grid-template-columns: 250px minmax(0, 1fr);
        gap: 24px;
      }

      .results-table-head,
      .property-row,
      .results-list {
        min-width: 980px;
      }
    }

    @media (max-width: 820px) {
      .dataset-layout {
        grid-template-columns: 1fr;
      }

      .filters {
        position: static;
        padding-right: 0;
        padding-bottom: 22px;
        border-right: 0;
        border-bottom: 1px solid var(--line);
      }

      .results-table-wrap {
        padding-bottom: 6px;
      }
    }

    @media (max-width: 560px) {
      .page-shell {
        width: 92vw;
      }

      .top-nav {
        display: none;
      }

      .topbar-actions {
        gap: 0;
      }

      .dataset-intro {
        padding-top: 24px;
      }

      .intro-copy {
        font-size: 14px;
      }

      .choice-grid {
        gap: 6px;
      }

      .results-header {
        align-items: flex-start;
        flex-direction: column;
      }

      .results-tools {
        width: 100%;
        align-items: flex-start;
      }

      .results-theme-control,
      .sort-control {
        width: 100%;
        justify-content: space-between;
      }

      .sort-select {
        flex: 1;
        min-width: 0;
        max-width: 190px;
      }

      .results-footer {
        align-items: flex-start;
        flex-direction: column;
      }
    }

/* Real dataset states and card results */
.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 100;
  padding: 10px 14px;
  transform: translateY(-160%);
  border: 2px solid var(--ink-dark);
  background: var(--sun);
  color: #181725;
  font-weight: 700;
}
.skip-link:focus { transform: translateY(0); }
[hidden] { display: none !important; }

.results-actions-panel {
  margin: 16px 0 22px;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, .8fr);
  gap: 16px;
}
.dataset-action-card {
  position: relative;
  min-width: 0;
  padding: 38px 16px 16px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px 18px;
  align-items: end;
  overflow: hidden;
  border: 2px solid var(--line-dark);
  border-radius: 2px;
  background: #FFF7EA;
  box-shadow: 6px 6px 0 rgba(90, 49, 91, .18);
}
.dataset-action-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 7px;
  background: var(--sun);
}
.dataset-action-card::after {
  content: "";
  position: absolute;
  right: 13px;
  bottom: 13px;
  width: 8px;
  height: 8px;
  background: var(--orange);
  box-shadow:
    -12px 0 0 var(--sun),
    -24px 0 0 var(--plum);
}
.total-card::before {
  background: var(--orange);
}
.total-card::after {
  background: var(--plum);
  box-shadow:
    -12px 0 0 var(--orange),
    -24px 0 0 var(--sun);
}
.action-titlebar {
  position: absolute;
  top: 0;
  left: 7px;
  right: 0;
  min-height: 22px;
  padding: 0 8px;
  display: flex;
  align-items: center;
  gap: 5px;
  border-bottom: 1px solid var(--line-dark);
  background: var(--plum);
}
.action-titlebar span {
  width: 6px;
  height: 6px;
  background: var(--sun);
}
.action-titlebar span:nth-child(2) {
  background: var(--orange);
}
.action-titlebar span:nth-child(3) {
  background: var(--paper);
}
.dataset-action-card strong,
.dataset-action-card p {
  grid-column: 1;
  position: relative;
  z-index: 1;
}
.dataset-action-card strong {
  color: var(--plum);
  font-family: "Press Start 2P", monospace;
  font-size: 8.5px;
  line-height: 1.65;
  text-transform: uppercase;
}
.dataset-action-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}
.dataset-action-card .retro-button {
  position: relative;
  z-index: 1;
  grid-row: 1 / span 2;
  grid-column: 2;
  min-width: 150px;
  min-height: 40px;
  box-shadow: 4px 4px 0 var(--shadow);
}

.results-grid {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.result-card {
  min-width: 0;
  padding: 19px;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-top: 4px solid var(--plum);
  background: white;
  box-shadow: 4px 4px 0 rgba(155, 148, 144, .5);
  transition: transform .15s ease, box-shadow .15s ease;
}
.result-card:hover {
  transform: translate(-1px, -1px);
  box-shadow: 6px 6px 0 rgba(155, 148, 144, .55);
}
.result-card-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 15px;
}
.result-title {
  margin: 0;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}
.result-location {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}
.result-price {
  min-width: 102px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.result-currency {
  display: block;
  margin-bottom: 3px;
  color: var(--orange);
  font-family: "Press Start 2P", monospace;
  font-size: 6px;
  text-transform: uppercase;
}
.result-value {
  display: block;
  color: var(--plum);
  font-size: 20px;
  line-height: 1.1;
  white-space: nowrap;
}
.result-tags {
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.result-tag {
  padding: 4px 7px;
  border: 1px solid var(--line);
  background: var(--soft);
  color: var(--plum);
  font-family: "Press Start 2P", monospace;
  font-size: 5px;
  line-height: 1.45;
  text-transform: uppercase;
}
.result-tag--operation {
  border-color: var(--ink-dark);
  background: var(--sun);
  color: #181725;
}
.result-facts {
  margin: 16px 0 0;
  padding: 13px 0;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  list-style: none;
}
.result-facts li { display: grid; gap: 3px; }
.result-fact-label { color: var(--muted); font-size: 10px; line-height: 1.3; }
.result-fact-value { color: var(--ink); font-size: 13px; line-height: 1.3; }
.result-description {
  margin: 14px 0 0;
  display: -webkit-box;
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
  overflow-wrap: anywhere;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}
.result-card-footer {
  margin-top: auto;
  padding-top: 18px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
}
.result-origin {
  min-width: 0;
  display: grid;
  gap: 3px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}
.result-origin strong {
  color: var(--ink);
  font-size: 12px;
  overflow-wrap: anywhere;
}
.status-card {
  min-height: 180px;
  margin-top: 12px;
  padding: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  border: 1px solid var(--line);
  background: var(--panel);
  text-align: center;
}
.status-card strong {
  color: var(--plum);
  font-family: "Press Start 2P", monospace;
  font-size: 8px;
  line-height: 1.6;
}
.status-card p { margin: 10px 0 0; color: var(--muted); }
.status-card .retro-button { margin-top: 18px; }
.loader {
  width: 22px;
  height: 22px;
  margin-bottom: 18px;
  border: 5px solid var(--line);
  border-top-color: var(--orange);
  animation: spin .8s steps(8) infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.empty-state:not([hidden]) { display: block; }
.results-footer[hidden] { display: none; }
.data-note { display: grid; gap: 3px; }
.page-status {
  min-width: 82px;
  align-self: center;
  color: var(--plum);
  font-family: "Press Start 2P", monospace;
  font-size: 6px;
  text-align: center;
}
.pager { align-items: center; }
.pager-btn:disabled { cursor: not-allowed; opacity: .45; }
.dataset-note {
  margin: 25px 0 0;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}
.noscript {
  margin: 20px;
  padding: 18px;
  border: 2px solid var(--orange);
  background: var(--cream);
  text-align: center;
}
body.theme-dark .result-card { background: #221e29; }
body.theme-dark .result-tag { border-color: var(--line-dark); background: #2b2631; }
body.theme-dark .result-tag--operation { background: var(--sun); color: #181725; }
body.theme-dark .status-card { background: var(--panel); }
body.theme-dark .dataset-action-card {
  background: #211d27;
  box-shadow: 6px 6px 0 #09080C;
}
body.theme-dark .action-titlebar {
  background: #4A2B4D;
  border-color: var(--line-dark);
}

@media (max-width: 1100px) {
  .results-actions-panel,
  .results-grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .filters-actions { flex-direction: column; }
  .filters-actions .retro-button { width: 100%; }
  .dataset-action-card {
    padding-right: 16px;
    grid-template-columns: 1fr;
  }
  .dataset-action-card .retro-button {
    grid-row: auto;
    grid-column: 1;
    width: 100%;
  }
  .result-card { padding: 16px; }
  .result-card-heading { grid-template-columns: 1fr; gap: 12px; }
  .result-price { text-align: left; }
  .result-currency { display: inline; margin-right: 7px; }
  .result-value { display: inline; }
  .result-card-footer { align-items: stretch; flex-direction: column; }
  .publication-link { align-self: stretch; min-height: 38px; }
}
