/* ============================================================
   RETRODEX — style.css (components + pages)
   Core tokens/base in css/core.css — load that first.
   CRT effects in css/effects.css — load that last.
   ============================================================ */

.page-header { max-width: var(--content-max, 1180px); margin: 0 auto 20px; padding-bottom: 12px; border-bottom: 1px solid var(--accent-dim); }
.page-header h1 { font-size: 18px; color: var(--text-value); letter-spacing: 0.05em; margin-bottom: 4px; }
.page-title, h1.title, .section-title { text-align: left; }
.nav-links { margin-top: 10px; display: flex; gap: 8px; flex-wrap: wrap; }
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.72rem;
  color: var(--text-secondary);
  margin-bottom: 1.25rem;
  letter-spacing: 0.05em;
}
.breadcrumb a {
  color: var(--text-secondary);
  text-decoration: none;
}
.breadcrumb a:hover { color: var(--text-primary); }
.breadcrumb .sep { color: var(--text-muted); }
.breadcrumb .current { color: var(--text-primary); font-weight: bold; }
.breadcrumb-back {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.65rem;
  cursor: pointer;
  margin-left: 0.5rem;
}
.breadcrumb-back:hover { color: var(--text-secondary); }
.btn { display: inline-block; padding: 6px 14px; border: 1px solid var(--accent-dim); border-radius: 3px; font-size: 0.7rem; font-family: inherit; background: transparent; color: var(--text-primary); cursor: pointer; text-decoration: none; }
.btn:hover { border-color: var(--text-secondary); background: color-mix(in srgb, var(--accent) 8%, transparent); }
.card { background: var(--bg-card); border: 1px solid var(--accent-dim); border-radius: 4px; padding: 14px 16px; }
.grid-2 { max-width: var(--content-max, 1180px); margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px,1fr)); gap: 12px; }
.page-shell { max-width: var(--content-max, 1180px); margin: 0 auto; display: flex; flex-direction: column; gap: 14px; }
.empty-state { max-width: var(--content-max, 1180px); margin: 40px auto; text-align: center; font-size: 12px; color: var(--accent-dim); }
.status-bar { max-width: var(--content-max, 1180px); margin: 0 auto 14px; font-size: 0.7rem; color: var(--text-secondary); min-height: 16px; }
.pill { display: inline-block; padding: 2px 8px; border: 1px solid var(--accent-dim); border-radius: 999px; background: var(--accent-dim); color: var(--text-primary); font-size: 0.7rem; margin-right: 8px; margin-bottom: 8px; }
.rarity-badge {
  padding: 0.15rem 0.5rem;
  font-size: 0.7rem;
  font-weight: bold;
  border: 1px solid currentColor;
  border-radius: 2px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.rarity-legendary { color: var(--text-alert); border-color: var(--text-alert); }
.rarity-epic { color: var(--rarity-epic); border-color: var(--rarity-epic); }
.rarity-rare { color: var(--confidence-mid); border-color: var(--confidence-mid); }
.rarity-uncommon { color: var(--rarity-uncommon); border-color: var(--rarity-uncommon); }
.rarity-common { color: var(--text-secondary); border-color: var(--text-secondary); }
/* =============================================
   game-detail ? Sprint 5 additions
   price-history + price-compare sections
   ============================================= */

      /* === TYPOGRAPHIC SCALE === */
      .page-title {
        font-size: 1.6rem;
        font-weight: bold;
        letter-spacing: 0.12em;
        color: var(--text-primary);
        text-transform: uppercase;
        text-align: left;
        margin-bottom: 0.25rem;
      }

      .page-subtitle {
        font-size: 0.75rem;
        color: var(--text-secondary);
        letter-spacing: 0.05em;
        margin-bottom: 1.5rem;
      }

      .section-title {
        font-size: 0.75rem;
        font-weight: bold;
        letter-spacing: 0.1em;
        color: var(--text-primary);
        text-transform: uppercase;
        margin-bottom: 0.75rem;
      }

      .card-title {
        font-size: 0.9rem;
        font-weight: bold;
        color: var(--text-primary);
      }

      .card-meta {
        font-size: 0.72rem;
        color: var(--text-secondary);
      }

      .label-key {
        font-size: 0.65rem;
        letter-spacing: 0.08em;
        text-transform: uppercase;
        color: var(--text-secondary);
      }

      .value-large {
        font-size: 1.4rem;
        font-weight: bold;
        color: var(--text-primary);
      }

      .value-medium {
        font-size: 1rem;
        color: var(--text-primary);
      }

      .detail-shell {
        max-width: 1100px;
        margin: 0 auto;
        display: flex;
        flex-direction: column;
        gap: 16px;
      }

      .top-nav {
        display: flex;
        gap: 8px;
        flex-wrap: wrap;
      }

      .hero-card,
      .summary-card,
      .collection-card,
      .contribute-section,
      .similar-card,
      .stats-card {
        background: var(--bg-surface);
        border: 1px solid var(--border);
        border-radius: 6px;
        padding: 18px;
      }

      .hero-grid {
        display: grid;
        grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
        gap: 16px;
        align-items: start;
      }

      .hero-title {
        font-size: 30px;
        color: var(--text-value);
        margin-bottom: 10px;
      }

      .hero-meta {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        margin-bottom: 12px;
      }

      .pill {
        display: inline-flex;
        align-items: center;
        padding: 4px 10px;
        border-radius: 999px;
        font-size: 10px;
        letter-spacing: 0.06em;
      }

      .pill {
        border: 1px solid var(--accent-dim);
        background: color-mix(in srgb, var(--accent) 8%, transparent);
        color: var(--accent);
      }

      .developer-line {
        font-size: 12px;
        color: var(--text-secondary);
      }

      .game-header-main {
        display: flex;
        gap: 16px;
        align-items: flex-start;
      }

      .game-header-copy {
        min-width: 0;
        flex: 1;
      }

      .game-hero-canvas {
        width: 100%;
        height: 180px;
        display: block;
        margin: 1rem 0;
        border: 1px solid var(--border);
      }

      .price-panel {
        background: rgba(10, 10, 10, 0.38);
        border: 1px solid var(--border);
        border-radius: 6px;
        padding: 16px;
      }

      .r?trodex-index {
        border: 1px solid var(--border);
        padding: 16px;
        margin-bottom: 16px;
        background: rgba(10, 10, 10, 0.24);
        border-radius: var(--radius);
      }

      .index-header {
        display: flex;
        justify-content: space-between;
        gap: 12px;
        margin-bottom: 12px;
        font-family: var(--font-mono);
        font-size: 11px;
        color: var(--text-secondary);
        flex-wrap: wrap;
      }

      .confidence-high { color: var(--confidence-high); }
      .confidence-mid { color: var(--confidence-mid); }
      .confidence-low { color: var(--confidence-low); }

      .index-prices {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
      }

      .index-condition .label {
        display: block;
        font-size: 10px;
        color: var(--text-muted);
      }

      .index-condition .value {
        display: block;
        font-size: 1.2rem;
        color: var(--text-alert);
        font-family: var(--font-mono);
        margin: 4px 0;
      }

      .index-condition .range {
        display: block;
        font-size: 10px;
        color: var(--text-secondary);
      }

      .index-sources {
        margin-top: 8px;
        font-size: 11px;
        color: var(--text-muted);
        font-family: var(--font-mono);
      }

      .trust-header {
        display: flex;
        align-items: center;
        gap: 12px;
        margin-bottom: 10px;
        padding-bottom: 8px;
        border-bottom: 1px solid var(--border);
        flex-wrap: wrap;
      }

      .trust-badge {
        font-family: var(--font-mono);
        font-size: 10px;
        padding: 2px 8px;
        border: 1px solid currentColor;
        letter-spacing: 0.08em;
      }

      .trust-T1 { color: var(--confidence-high); }
      .trust-T2 { color: var(--confidence-high); }
      .trust-T3 { color: var(--confidence-mid); }
      .trust-T4 { color: var(--text-muted); border-color: var(--text-muted); }
      .trust-T0 { color: var(--text-muted); border-color: var(--text-muted); }

      .trust-source {
        font-size: 10px;
        color: var(--text-muted);
        font-family: var(--font-mono);
      }

      .index-insufficient {
        border: 1px dashed var(--border);
        padding: 16px;
        color: var(--text-secondary);
        font-family: var(--font-mono);
        border-radius: var(--radius);
      }

      .price-top {
        display: flex;
        justify-content: space-between;
        gap: 16px;
        align-items: center;
        margin-bottom: 16px;
      }

      .metascore-circle {
        width: 74px;
        height: 74px;
        border-radius: 50%;
        border: 2px solid var(--accent-dim);
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        color: var(--text-value);
      }

      .metascore-circle strong {
        font-size: 20px;
        line-height: 1;
      }

      .metascore-circle span {
        font-size: 10px;
        color: var(--text-muted);
        letter-spacing: 0.08em;
      }

      .price-table {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 10px;
      }

      .price-cell {
        border: 1px solid var(--accent-dim);
        border-radius: 4px;
        padding: 12px;
        background: color-mix(in srgb, var(--bg-surface) 18%, transparent);
      }

      .price-cell .label {
        display: block;
        font-size: 10px;
        color: var(--text-muted);
        margin-bottom: 6px;
        text-transform: uppercase;
      }

      .price-cell .value {
        font-size: 18px;
        color: var(--text-value);
      }

      .summary-card h2,
      .collection-card h2,
      .stats-card h2,
      .similar-card h2 {
        font-size: 12px;
        color: var(--text-muted);
        text-transform: uppercase;
        letter-spacing: 0.08em;
        margin-bottom: 12px;
      }

      .summary-text {
        font-size: 13px;
        line-height: 1.7;
        color: var(--text-secondary);
      }

      .stats-grid {
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 10px;
      }

      .stat-cell {
        border: 1px solid var(--accent-dim);
        border-radius: 4px;
        padding: 12px;
        background: color-mix(in srgb, var(--bg-surface) 14%, transparent);
      }

      .stat-cell .label {
        display: block;
        font-size: 10px;
        color: var(--text-muted);
        margin-bottom: 6px;
        text-transform: uppercase;
      }

      .stat-cell .value {
        font-size: 14px;
        color: var(--text-value);
      }

      .collection-row {
        display: flex;
        justify-content: space-between;
        gap: 12px;
        align-items: center;
        flex-wrap: wrap;
      }

      .collection-state {
        font-size: 12px;
        color: var(--text-secondary);
      }

      .similar-grid {
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 12px;
      }

      .mini-card {
        border: 1px solid var(--accent-dim);
        border-radius: 5px;
        background: color-mix(in srgb, var(--bg-surface) 14%, transparent);
        padding: 12px;
        text-decoration: none;
        color: inherit;
      }

      .mini-card:hover {
        border-color: var(--accent-dim);
      }

      .mini-card h3 {
        font-size: 12px;
        color: var(--text-value);
        margin-bottom: 8px;
      }

      .mini-card p {
        font-size: 11px;
        color: var(--text-secondary);
      }

      .status-text {
        font-size: 11px;
        color: var(--text-muted);
        min-height: 16px;
      }

      .price-history {
        margin-top: 2rem;
        padding: 1rem;
        border: 1px solid var(--accent-dim);
      }

      .price-history h3 {
        color: var(--text-primary);
        font-size: 0.7rem;
        letter-spacing: 0.1em;
        margin-bottom: 1rem;
      }

      .trend-row {
        display: flex;
        gap: 0.5rem;
        margin-bottom: 1rem;
        flex-wrap: wrap;
      }

      .trend-badge {
        padding: 0.2rem 0.6rem;
        font-size: 0.65rem;
        border: 1px solid var(--accent-dim);
        color: var(--text-primary);
      }

      .trend-badge.up {
        border-color: var(--text-primary);
        color: var(--text-primary);
      }

      .trend-badge.up::before {
        content: "\2191 ";
      }

      .trend-badge.down {
        border-color: var(--confidence-low);
        color: var(--confidence-low);
      }

      .trend-badge.down::before {
        content: "\2193 ";
      }

      .trend-badge.stable {
        border-color: var(--accent);
      }

      .trend-badge.stable::before {
        content: "= ";
      }

      .chart-toggle {
        display: flex;
        gap: 0.5rem;
        margin-bottom: 0.75rem;
        flex-wrap: wrap;
      }

      .period-selector {
        display: flex;
        gap: 6px;
        margin-bottom: 12px;
        flex-wrap: wrap;
      }

      .period-btn {
        padding: 4px 12px;
        font-family: var(--font-mono);
        font-size: 11px;
        border: 1px solid var(--border);
        background: transparent;
        color: var(--text-secondary);
        cursor: pointer;
        border-radius: var(--radius);
      }

      .period-btn.active {
        background: var(--accent);
        color: var(--bg);
        border-color: var(--accent);
        font-weight: bold;
      }

      .chart-btn {
        background: none;
        border: 1px solid var(--accent-dim);
        color: var(--accent-dim);
        padding: 0.2rem 0.75rem;
        font-size: 0.65rem;
        cursor: pointer;
      }

      .chart-btn.active {
        border-color: var(--text-primary);
        color: var(--text-primary);
        background: var(--bg-surface);
      }

      .chart-container {
        position: relative;
        background: var(--bg-surface);
        border: 1px solid var(--border);
      }

      #price-chart {
        width: 100%;
        height: 160px;
      }

      .chart-labels {
        display: flex;
        justify-content: space-between;
        padding: 0.25rem 0.5rem;
        gap: 8px;
      }

      .chart-label {
        font-size: 0.62rem;
        color: var(--accent-dim);
      }

      .price-stats-row {
        display: flex;
        gap: 1rem;
        margin-top: 0.75rem;
      }

      .price-stat {
        flex: 1;
        text-align: center;
        padding: 0.5rem;
        border: 1px solid var(--border);
      }

      .stat-label {
        display: block;
        font-size: 0.62rem;
        color: var(--accent-dim);
        margin-bottom: 0.25rem;
      }

      .stat-value {
        font-size: 0.9rem;
        color: var(--text-primary);
        font-weight: bold;
      }

      .price-compare {
        margin-top: 2rem;
        padding: 1rem;
        border: 1px solid var(--accent-dim);
        background: rgba(10, 10, 10, 0.24);
      }

      .price-compare h3 {
        color: var(--text-primary);
        font-size: 0.7rem;
        letter-spacing: 0.1em;
        margin-bottom: 1rem;
      }

      .compare-table {
        width: 100%;
      }

      .compare-row {
        display: grid;
        grid-template-columns: 2fr 0.7fr 1fr 0.7fr 0.9fr;
        gap: 0.5rem;
        padding: 0.4rem 0;
        border-bottom: 1px solid var(--border);
        font-size: 0.7rem;
        align-items: center;
      }

      .compare-row span {
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
      }

      .compare-header {
        color: var(--accent-dim);
        font-size: 0.6rem;
        letter-spacing: 0.05em;
      }

      .compare-row.current {
        background: var(--bg-surface);
        color: var(--text-primary);
      }

      .compare-row.clickable:hover {
        background: var(--bg-surface);
      }

      .collection-form {
        display: flex;
        flex-direction: column;
        gap: 0.75rem;
        margin-top: 0.75rem;
      }

      .collection-controls {
        display: flex;
        gap: 0.75rem;
        flex-wrap: wrap;
        align-items: center;
      }

      .collection-condition-select,
      .collection-note-input {
        border: 1px solid var(--accent-dim);
        background: rgba(10, 10, 10, 0.5);
        color: var(--text-value);
        font-family: inherit;
        font-size: 0.7rem;
        padding: 0.45rem 0.65rem;
        border-radius: 4px;
      }

      .collection-condition-select {
        min-width: 120px;
      }

      .collection-note-input {
        width: 100%;
      }

      .collection-current-meta {
        display: flex;
        flex-wrap: wrap;
        gap: 0.5rem;
        margin-top: 0.5rem;
        align-items: center;
      }

      .condition-badge {
        display: inline-flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.15rem 0.5rem;
        border: 1px solid currentColor;
        border-radius: 999px;
        font-size: 0.7rem;
        font-weight: bold;
        letter-spacing: 0.05em;
        text-transform: uppercase;
      }

      .condition-loose {
        color: var(--condition-loose);
        border-color: var(--condition-loose);
      }

      .condition-cib {
        color: var(--condition-cib);
        border-color: var(--condition-cib);
      }

      .condition-mint {
        color: var(--condition-mint);
        border-color: var(--condition-mint);
      }

      .collection-note-text {
        font-size: 0.72rem;
        color: var(--text-secondary);
        line-height: 1.5;
      }

      .contribute-section h3 {
        font-size: 12px;
        color: var(--text-muted);
        text-transform: uppercase;
        letter-spacing: 0.08em;
        margin-bottom: 12px;
      }

      .contribute-desc {
        color: var(--text-secondary);
        margin-bottom: 12px;
        font-size: 12px;
      }

      .contribute-form {
        display: grid;
        gap: 10px;
      }

      .contribute-form select,
      .contribute-form input,
      .contribute-form textarea {
        width: 100%;
        border: 1px solid var(--border);
        background: var(--bg-card);
        color: var(--text-primary);
        font-family: var(--font-mono);
        padding: 10px 12px;
        border-radius: var(--radius);
      }

      .contribute-form textarea {
        resize: vertical;
        min-height: 64px;
      }

      #contrib-submit {
        border: 1px solid var(--accent);
        background: var(--accent);
        color: var(--bg);
        font-family: var(--font-mono);
        padding: 10px 12px;
        border-radius: var(--radius);
        cursor: pointer;
      }

      #contrib-submit:disabled {
        opacity: 0.7;
        cursor: default;
      }

      #contrib-feedback {
        margin-top: 12px;
        font-family: var(--font-mono);
        font-size: 12px;
      }

      #contrib-feedback.is-success {
        color: var(--confidence-high);
      }

      #contrib-feedback.is-error {
        color: var(--confidence-low);
      }

      .hidden {
        display: none;
      }

      .loading-card {
        padding: 32px 20px;
        text-align: center;
        color: var(--text-muted);
        border: 1px dashed var(--accent-dim);
        border-radius: 6px;
      }

      @media (max-width: 900px) {
        .hero-grid {
          grid-template-columns: 1fr;
        }

        .stats-grid,
        .similar-grid {
          grid-template-columns: repeat(2, minmax(0, 1fr));
        }
      }

      @media (max-width: 640px) {
        .price-table,
        .stats-grid,
        .similar-grid,
        .price-stats-row {
          grid-template-columns: 1fr;
        }

        .price-stats-row {
          display: grid;
        }

        .compare-row {
          grid-template-columns: 1.5fr 0.7fr 1fr 0.7fr 0.9fr;
          font-size: 0.65rem;
        }
      }

      /* === RESPONSIVE ? mobile 768px === */
      @media (max-width: 768px) {

        /* Grid: 2 columns ? 1 column */
        .games-grid,
        .cards-grid,
        .console-grid,
        .stats-grid,
        [class*="grid-2"],
        [class*="two-col"] {
          grid-template-columns: 1fr;
        }

        /* Filter bar: stack vertically */
        .filter-bar,
        .filter-row,
        [class*="filter"] {
          flex-direction: column;
          gap: 0.5rem;
        }

        /* Inputs full width */
        .filter-bar input,
        .filter-bar select,
        .filter-row input,
        .filter-row select {
          width: 100%;
          box-sizing: border-box;
        }

        /* Min font-size for readability */
        body { font-size: 16px; }
        input, select, button { font-size: 16px; }

        /* Price cards: stack vertically */
        .price-cards,
        .prices-row,
        [class*="price-col"] {
          flex-direction: column;
        }

        /* Stats cards: 1 column */
        .stat-card,
        .stats-row {
          grid-template-columns: 1fr;
        }

        /* Breadcrumb: smaller */
        .breadcrumb { font-size: 0.6rem; }

        /* Page title: smaller */
        .page-title { font-size: 1.2rem; }

        /* Pagination: wrap */
        #page-numbers { gap: 0.15rem; }
        #page-numbers button { min-width: 24px; padding: 0.15rem 0.3rem; }

      }

      .item-visual {
        height: 120px;
        background: var(--bg-card);
        display: flex;
        align-items: center;
        justify-content: center;
      }

      .item-initial {
        font-size: 2rem;
        color: var(--text-primary);
        font-family: var(--font-mono);
      }

      /* =============================================
         games-list ? Bloomberg 3-column layout
         ============================================= */
      .bloomberg-layout {
        display: grid;
        grid-template-columns: 220px minmax(0, 1fr) 320px;
        gap: 16px;
        align-items: start;
      }

      .bloomberg-sidebar,
      .bloomberg-center,
      .bloomberg-detail {
        min-width: 0;
      }

      .bloomberg-sidebar,
      .bloomberg-detail {
        position: sticky;
        top: 16px;
        align-self: start;
      }

      .filters-mobile-toggle {
        display: none;
        width: 100%;
        align-items: center;
        justify-content: space-between;
        padding: 10px 12px;
        border: 1px solid var(--border);
        border-radius: 4px;
        background: var(--bg-surface);
        color: var(--text-primary);
        font: inherit;
        cursor: pointer;
        margin-bottom: 10px;
      }

      .filters-sidebar-content {
        display: block;
      }

      .filters-sidebar-title {
        margin-bottom: 12px;
      }

      .results-list {
        display: flex;
        flex-direction: column;
        border: 1px solid var(--border);
        border-radius: 6px;
        background: var(--bg-surface);
        overflow: hidden;
      }

      .result-row {
        display: flex;
        align-items: center;
        height: 56px;
        padding: 0 12px;
        cursor: pointer;
        border-bottom: 1px solid var(--border);
        background: transparent;
        color: inherit;
      }

      .result-row:last-child {
        border-bottom: 0;
      }

      .result-row:hover,
      .result-row:focus-visible {
        background: var(--bg-card);
      }

      .result-initial {
        width: 36px;
        height: 36px;
        background: var(--bg-card);
        display: flex;
        align-items: center;
        justify-content: center;
        font-family: var(--font-mono);
        color: var(--text-primary);
        flex-shrink: 0;
        border: 1px solid var(--border);
        border-radius: var(--radius);
      }

      .result-info {
        flex: 1;
        min-width: 0;
        padding: 0 12px;
        overflow: hidden;
      }

      .result-title {
        display: block;
        color: var(--text-value);
        font-family: var(--font-mono);
        font-size: 0.82rem;
        font-weight: bold;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
      }

      .result-meta {
        display: block;
        font-size: 11px;
        color: var(--text-secondary);
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
      }

      .result-price {
        color: var(--text-alert);
        font-family: var(--font-mono);
        min-width: 60px;
        text-align: right;
        white-space: nowrap;
      }

      .result-badge {
        font-size: 10px;
        padding: 2px 6px;
        margin-left: 8px;
        font-family: var(--font-mono);
        flex-shrink: 0;
      }

      .quick-detail-panel {
        min-height: 360px;
        border: 1px solid var(--border);
        border-radius: 6px;
        background: var(--bg-surface);
        padding: 16px;
      }

      .quick-detail-head {
        font-size: 0.7rem;
        color: var(--text-secondary);
        letter-spacing: 0.08em;
        text-transform: uppercase;
        margin-bottom: 12px;
      }

      .quick-detail-placeholder,
      .quick-detail-loading {
        color: var(--text-secondary);
        font-size: 0.8rem;
      }

      .detail-content {
        display: flex;
        flex-direction: column;
      }

      .detail-title {
        font-size: 1.1rem;
        color: var(--text-value);
        font-family: var(--font-mono);
        margin-bottom: 10px;
      }

      .detail-badges {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
        margin-bottom: 12px;
      }

      .badge-platform,
      .badge-year {
        display: inline-flex;
        align-items: center;
        font-size: 10px;
        padding: 2px 6px;
        border: 1px solid var(--border);
        color: var(--text-secondary);
        font-family: var(--font-mono);
        border-radius: var(--radius);
        background: var(--bg-card);
      }

      .detail-prices {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
        margin-bottom: 12px;
        border: 1px solid var(--border);
        padding: 10px;
        border-radius: var(--radius);
        background: var(--bg-card);
      }

      .detail-price-col {
        min-width: 0;
      }

      .price-label {
        font-size: 10px;
        color: var(--text-muted);
        font-family: var(--font-mono);
        margin-bottom: 4px;
      }

      .price-value {
        font-size: 1rem;
        color: var(--text-alert);
        font-family: var(--font-mono);
      }

      .price-value.empty {
        color: var(--text-muted);
      }

      .detail-description {
        font-size: 12px;
        color: var(--text-secondary);
        line-height: 1.6;
        margin-bottom: 12px;
        display: -webkit-box;
        -webkit-line-clamp: 3;
        -webkit-box-orient: vertical;
        overflow: hidden;
      }

      .detail-link {
        color: var(--accent);
        font-family: var(--font-mono);
        font-size: 12px;
        text-decoration: none;
      }

      .detail-link:hover {
        text-decoration: underline;
      }

      .tabs {
        display: flex;
        gap: 0;
        border-bottom: 1px solid var(--border);
        margin-bottom: 16px;
      }

      .tab-btn {
        padding: 8px 16px;
        font-family: var(--font-mono);
        font-size: 12px;
        border: none;
        background: transparent;
        color: var(--text-secondary);
        cursor: pointer;
      }

      .tab-btn.active {
        color: var(--text-primary);
        border-bottom: 2px solid var(--accent);
      }

      .collection-market-line,
      .collection-paid-line {
        font-size: 11px;
        color: var(--text-secondary);
        line-height: 1.6;
      }

.collection-paid-line strong {
  color: var(--text-alert);
}

.collection-value {
  border: 1px solid var(--border);
  padding: 16px;
  margin-bottom: 16px;
}

.value-header {
  font-size: 10px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  letter-spacing: 0.1em;
  margin-bottom: 12px;
}

.value-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.value-col {
  text-align: center;
}

.value-label {
  font-size: 10px;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.value-amount {
  font-size: 1.4rem;
  color: var(--text-alert);
  font-family: var(--font-mono);
}

.value-count {
  font-size: 11px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  margin-top: 8px;
  text-align: center;
}

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

        .bloomberg-sidebar,
        .bloomberg-detail {
          position: static;
        }

        .filters-mobile-toggle {
          display: flex;
        }

        .filters-sidebar-content {
          display: none;
        }

        .filters-sidebar-content.is-open {
          display: block;
        }

        .result-row {
          height: auto;
          min-height: 56px;
          flex-wrap: wrap;
          row-gap: 6px;
          padding: 10px 12px;
        }

        .result-price {
          min-width: 52px;
          margin-left: auto;
        }

        .result-badge {
          margin-left: 6px;
        }

        .detail-prices {
          grid-template-columns: 1fr;
        }
      }

/* Phosphore ? valeurs importantes uniquement */
.text-value, .index-value, .result-price,
.price-value, .detail-price-value {
  text-shadow: 0 0 6px currentColor;
}
/* Bordures : coins droits partout */
*, *::before, *::after {
  border-radius: 0;
}
/* Titre principal ? accent phosphore */
h1, .page-title {
  letter-spacing: 0.15em;
  text-transform: uppercase;
}
/* Lignes r?sultats ? plus compactes */
.result-row {
  height: 44px;
}
/* Liens navigation ? style terminal */
a {
  color: var(--text-primary);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.game-console-link {
  font-size: 11px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  margin-top: 6px;
  margin-bottom: 4px;
}

.game-tagline {
  font-size: 12px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  line-height: 1.6;
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
  font-style: italic;
}

.game-cover-container {
  width: 160px;
  height: 160px;
  flex-shrink: 0;
  border: 1px solid var(--border);
  overflow: hidden;
}

#game-cover-img {
  width: 160px;
  height: 160px;
  display: block;
  image-rendering: pixelated;
}

.console-link {
  color: var(--accent);
  text-decoration: none;
}

.console-link:hover {
  text-decoration: underline;
}

.console-accessories {
  margin-top: 16px;
  border-top: 1px solid var(--border);
  padding-top: 12px;
}

.section-label {
  font-size: 10px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  letter-spacing: 0.1em;
  margin-bottom: 8px;
}

.accessory-line {
  font-size: 11px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  padding: 3px 0;
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.accessory-type {
  color: var(--text-muted);
  font-size: 10px;
  text-transform: uppercase;
}

.encyclo-section {
  border: 1px solid var(--border);
  margin-top: 16px;
  padding: 16px;
}

.encyclo-header {
  border-bottom: 1px solid var(--border);
  padding-bottom: 8px;
  margin-bottom: 16px;
}

.encyclo-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.15em;
  color: var(--text-muted);
}

.encyclo-block {
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.encyclo-block:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.encyclo-text {
  font-size: 11px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  line-height: 1.7;
}

.encyclo-team-row {
  display: flex;
  gap: 16px;
  padding: 3px 0;
  font-size: 11px;
  font-family: var(--font-mono);
  border-bottom: 1px solid var(--border);
}

.team-role {
  color: var(--text-muted);
  width: 160px;
  flex-shrink: 0;
}

.team-name {
  color: var(--text-primary);
}

.encyclo-anecdote {
  margin-bottom: 12px;
}

.anecdote-title {
  font-size: 11px;
  color: var(--accent);
  font-family: var(--font-mono);
  margin-bottom: 4px;
}

.anecdote-text {
  font-size: 11px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  line-height: 1.6;
}

.encyclo-cheat-row {
  display: grid;
  grid-template-columns: 160px 200px 1fr;
  gap: 12px;
  padding: 4px 0;
  font-size: 11px;
  font-family: var(--font-mono);
  border-bottom: 1px solid var(--border);
}

.cheat-name {
  color: var(--text-alert);
}

.cheat-code {
  color: var(--accent);
}

.cheat-effect {
  color: var(--text-secondary);
}

.franchises-page {
  max-width: 1180px;
  margin: 0 auto;
  padding: 24px 16px 48px;
}

.franchises-layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 0;
  border: 1px solid var(--border);
  background: var(--bg-surface);
}

.franchises-sidebar {
  border-right: 1px solid var(--border);
  background: var(--bg-surface);
}

.franchise-list {
  display: flex;
  flex-direction: column;
}

.franchises-detail {
  padding: 16px;
  min-height: 640px;
  background: var(--bg-surface);
}

.franchise-detail-empty {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 12px;
}

.franchise-section {
  border: 1px solid var(--border);
  padding: 16px;
  margin-bottom: 16px;
  background: var(--bg-card);
}

.franchise-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 12px;
}

.franchise-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.franchise-years-line,
.franchise-platforms,
.franchise-list-developer,
.timeline-platform,
.timeline-description {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
}

.franchise-description {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.7;
  margin-bottom: 12px;
}

.franchise-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.franchise-list-item {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-secondary);
  background: transparent;
  text-align: left;
  width: 100%;
  border-left: 0;
  border-right: 0;
  border-top: 0;
}

.franchise-list-item:hover,
.franchise-list-item.selected {
  background: var(--bg-card);
  color: var(--text-primary);
  border-left: 2px solid var(--accent);
  padding-left: 10px;
}

.franchise-name {
  color: var(--text-primary);
  font-size: 12px;
}

.franchise-years {
  color: var(--text-muted);
  font-size: 10px;
  margin-top: 2px;
  margin-bottom: 4px;
}

.timeline-list {
  display: flex;
  flex-direction: column;
}

.timeline-row {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 11px;
  font-family: var(--font-mono);
}

.timeline-year {
  color: var(--text-muted);
}

.timeline-main {
  min-width: 0;
}

.timeline-title {
  color: var(--text-primary);
}

.timeline-badge {
  font-size: 10px;
  padding: 2px 6px;
  border: 1px solid currentColor;
  letter-spacing: 0.06em;
  white-space: nowrap;
  align-self: start;
}

.timeline-badge-release { color: var(--text-secondary); }
.timeline-badge-pivot_majeur { color: var(--text-alert); }
.timeline-badge-reboot { color: var(--accent); }
.timeline-badge-catastrophe { color: var(--confidence-low); }
.timeline-badge-renaissance { color: var(--confidence-high); }
.timeline-badge-nouvelle_serie { color: var(--confidence-mid); }

.team-table {
  border-top: 1px solid var(--border);
}

.team-row {
  display: grid;
  grid-template-columns: 56px 1fr 1fr 116px 2fr;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 11px;
  font-family: var(--font-mono);
  align-items: start;
}

.team-row-head .team-cell {
  color: var(--text-muted);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.team-cell {
  color: var(--text-secondary);
  min-width: 0;
}

.team-event {
  display: inline-block;
  font-size: 10px;
  padding: 2px 6px;
  border: 1px solid currentColor;
  white-space: nowrap;
}

.team-event-joined { color: var(--confidence-high); }
.team-event-left { color: var(--confidence-low); }
.team-event-changed { color: var(--text-alert); }

.franchise-legacy {
  font-size: 11px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  line-height: 1.7;
  padding: 12px;
  border: 1px solid var(--border);
  margin-top: 8px;
}

.franchise-games-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.franchise-game-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 11px;
}

.franchise-game-title {
  color: var(--text-primary);
}

.franchise-game-meta {
  color: var(--text-muted);
  white-space: nowrap;
}

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

  .franchises-sidebar {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .franchise-header {
    flex-direction: column;
  }

  .franchise-meta {
    justify-content: flex-start;
  }

  .team-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .timeline-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .franchise-game-row {
    flex-direction: column;
    gap: 4px;
  }
}

@media (max-width: 768px) {
  .game-header-main {
    flex-direction: column;
  }
}

.search-page {
  max-width: 1080px;
  margin: 0 auto;
}

.search-panel-shell {
  border: 1px solid var(--border);
  background: var(--bg-surface);
  padding: 16px;
}

.search-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}

#search-results {
  border: 1px solid var(--border);
  background: var(--bg-card);
  min-height: 72px;
}

#search-input {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 16px;
  padding: 14px 16px;
  outline: none;
  box-sizing: border-box;
  margin-bottom: 12px;
}

#search-input:focus { border-color: var(--accent); }
#search-input::placeholder { color: var(--text-muted); }

.filter-btn {
  background: none;
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 4px 12px;
  cursor: pointer;
  letter-spacing: 0.08em;
  margin-right: 6px;
}

.filter-btn.active {
  border-color: var(--accent);
  color: var(--accent);
}

.filter-btn:hover { color: var(--text-primary); }

.result-row {
  display: grid;
  grid-template-columns: 80px 1fr 140px 70px 90px;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 11px;
}

.result-row:hover { background: var(--bg-card); }

.result-franchise {
  grid-template-columns: 80px 1fr 140px 1fr;
}

.result-type-badge {
  font-size: 10px;
  padding: 2px 6px;
  border: 1px solid currentColor;
  letter-spacing: 0.06em;
  text-align: center;
}

.badge-franchise { color: var(--text-alert); }
.badge-game { color: var(--text-secondary); }

.result-title { color: var(--text-primary); }
.result-meta { color: var(--text-muted); font-size: 10px; }
.result-sub { color: var(--text-muted); font-size: 10px; }
.result-price { color: var(--text-alert); text-align: right; }

.result-rarity { font-size: 10px; text-align: right; }
.result-rarity.rarity-legendary { color: var(--text-alert); border-color: var(--text-alert); }
.result-rarity.rarity-epic { color: var(--text-alert); }
.result-rarity.rarity-rare { color: var(--confidence-mid); border-color: var(--confidence-mid); }
.result-rarity.rarity-uncommon { color: var(--text-muted); }
.result-rarity.rarity-common { color: var(--text-muted); }

#search-count {
  font-size: 10px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  display: block;
  margin-bottom: 8px;
}

.search-empty {
  padding: 24px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 11px;
  text-align: center;
}

.global-search-bar {
  margin-bottom: 12px;
}

.catalog-search-jump {
  border-color: var(--text-secondary);
  background: linear-gradient(180deg, var(--bg), var(--bg));
  box-shadow:
    inset 0 0 0 1px color-mix(in srgb, var(--accent) 10%, transparent),
    inset 0 1px 0 color-mix(in srgb, var(--accent) 4%, transparent);
}

.catalog-search-jump-copy {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.6;
  margin-bottom: 12px;
}

#global-search {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 13px;
  padding: 10px 12px;
  cursor: pointer;
  box-sizing: border-box;
}

#global-search:hover { border-color: var(--accent); }

@media (max-width: 768px) {
  .result-row,
  .result-franchise {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .result-price,
  .result-rarity {
    text-align: left;
  }
}

.similar-section {
  border: 1px solid var(--border);
  margin-top: 16px;
  padding: 16px;
}

#similar-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 12px;
}

.similar-item {
  border: 1px solid var(--border);
  padding: 10px;
  cursor: pointer;
  font-family: var(--font-mono);
}

.similar-item:hover {
  background: var(--bg-card);
  border-color: var(--accent);
}

.similar-title {
  font-size: 11px;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.similar-meta {
  font-size: 10px;
  color: var(--text-muted);
}

.similar-price {
  font-size: 11px;
  color: var(--text-alert);
  margin-top: 4px;
}

.game-franchise-link {
  font-size: 11px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  margin-top: 6px;
  margin-bottom: 4px;
}

.franchise-link {
  color: var(--text-alert);
  text-decoration: none;
}

.franchise-link:hover { text-decoration: underline; }

/* ========================================
   RESPONSIVE ? MOBILE BREAKPOINTS
   ======================================== */

@media (max-width: 768px) {

  /* Layouts 2-3 colonnes ? 1 colonne */
  .results-layout,
  .consoles-layout,
  .franchise-layout,
  .detail-layout {
    grid-template-columns: 1fr;
  }

  /* Panneau détail visible seulement si sélection active */
  .detail-panel {
    border-left: none;
    border-top: 1px solid var(--border);
  }

  /* Grille jeux similaires ? 2 colonnes */
  #similar-grid {
    grid-template-columns: 1fr 1fr;
  }

  /* Cheats ? 1 colonne */
  .encyclo-cheat-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  /* Cover art ? centr? */
  .game-cover-container {
    margin: 0 auto 12px auto;
  }

  /* Recherche plein ?cran */
  #search-input {
    font-size: 14px;
  }

  /* R?sultats search ? moins de colonnes */
  .result-row {
    grid-template-columns: 60px 1fr 80px;
  }

  /* Team row ? 1 colonne */
  .encyclo-team-row {
    flex-direction: column;
    gap: 4px;
  }
  .team-role { width: auto; }

  /* Timeline ? simplifi?e */
  .timeline-row {
    grid-template-columns: 40px 1fr;
  }
  .timeline-badge { display: none; }
}

@media (max-width: 480px) {
  :root { --font-size-base: 11px; }

  #similar-grid { grid-template-columns: 1fr; }

  .value-grid { grid-template-columns: 1fr 1fr; }
}

/* ========================================
   SKELETON LOADING
   ======================================== */
.skeleton {
  background: linear-gradient(90deg, var(--bg-card) 25%, var(--border) 50%, var(--bg-card) 75%);
  background-size: 200% 100%;
  animation: skeleton-pulse 1.5s infinite;
  height: 12px;
  margin-bottom: 8px;
  border-radius: 0;
}

@keyframes skeleton-pulse {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.skeleton-line-short { width: 40%; }
.skeleton-line-medium { width: 70%; }
.skeleton-line-full { width: 100%; }
.skeleton-title { height: 20px; width: 60%; margin-bottom: 12px; }

/* ========================================
   ENCYCLOP?DIE ? Page + Onglets
   ======================================== */
.page-wrapper {
  max-width: 1180px;
  margin: 0 auto;
}

.page-nav-inline {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
  font-size: 10px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  letter-spacing: 0.05em;
}

.page-nav-inline a {
  color: var(--text-alert);
  text-decoration: none;
}

.page-nav-inline a:hover {
  text-decoration: underline;
}

/* LAYOUT */
.encyclo-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 0;
  border: 1px solid var(--border);
  min-height: 600px;
}

.encyclo-list {
  border-right: 1px solid var(--border);
  overflow-y: auto;
  max-height: 75vh;
  padding: 12px 0;
}

.encyclo-detail-panel {
  padding: 16px;
  overflow-y: auto;
  max-height: 75vh;
}

/* FILTRES */
.encyclo-filters {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

/* LISTE ITEMS */
.encyclo-list-row {
  padding: 10px 16px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: background 0.1s;
}

.encyclo-list-row:hover { background: var(--bg-card); }

.encyclo-list-row.active {
  background: var(--bg-card);
  border-left: 2px solid var(--accent);
}

.encyclo-row-title {
  font-size: 11px;
  color: var(--text-primary);
  font-family: var(--font-mono);
  margin-bottom: 3px;
}

.encyclo-row-meta {
  font-size: 10px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  margin-bottom: 4px;
}

.encyclo-row-badges {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

/* BADGES CONTENU */
.encyclo-badge {
  font-size: 10px;
  padding: 1px 5px;
  border: 1px solid var(--text-muted);
  color: var(--text-muted);
  font-family: var(--font-mono);
  letter-spacing: 0.05em;
}

.encyclo-badge-franchise {
  border-color: var(--text-alert);
  color: var(--text-alert);
}

/* PANNEAU D?TAIL ? EN-TÃŠTE */
.encyclo-panel-header {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.encyclo-panel-cover {
  width: 80px;
  height: 80px;
  flex-shrink: 0;
}

.encyclo-panel-cover img {
  border: 1px solid var(--border);
  object-fit: cover;
}

.encyclo-cover-placeholder {
  width: 80px;
  height: 80px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-family: var(--font-mono);
  color: var(--text-secondary);
  flex-shrink: 0;
}

.encyclo-panel-info {
  min-width: 0;
}

.encyclo-panel-title {
  font-size: 16px;
  font-family: var(--font-mono);
  color: var(--text-primary);
  font-weight: bold;
  margin-bottom: 4px;
  letter-spacing: 0.06em;
}

.encyclo-panel-meta {
  font-size: 11px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  margin-bottom: 6px;
}

.encyclo-panel-rarity {
  display: inline-block;
  font-size: 10px;
  font-family: var(--font-mono);
  margin-bottom: 4px;
}

.encyclo-panel-tagline {
  font-size: 11px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-style: italic;
  margin-top: 6px;
  line-height: 1.5;
}

.encyclo-panel-link {
  display: inline-block;
  margin-top: 8px;
  font-size: 10px;
  color: var(--text-alert);
  font-family: var(--font-mono);
  text-decoration: none;
}

.encyclo-panel-link:hover { text-decoration: underline; }

/* ONGLETS */
.encyclo-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 16px;
}

.encyclo-tab {
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 8px 16px;
  cursor: pointer;
  letter-spacing: 0.08em;
  transition: all 0.1s;
}

.encyclo-tab:hover { color: var(--text-primary); }

.encyclo-tab.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

/* CONTENU ONGLETS */
.encyclo-synopsis-text {
  font-size: 12px;
  color: var(--text-primary);
  font-family: var(--font-mono);
  line-height: 1.8;
  margin: 0;
}

.encyclo-anecdote-block {
  border: 1px solid var(--border);
  padding: 12px 16px;
  margin-bottom: 10px;
}

.encyclo-anecdote-title {
  font-size: 11px;
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-weight: bold;
  margin-bottom: 8px;
  letter-spacing: 0.05em;
}

.encyclo-anecdote-text {
  font-size: 11px;
  color: var(--text-primary);
  font-family: var(--font-mono);
  line-height: 1.7;
}

.encyclo-code-block {
  border: 1px solid var(--border);
  padding: 10px 14px;
  margin-bottom: 8px;
}

.encyclo-code-label {
  font-size: 10px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 4px;
}

.encyclo-code-value {
  font-size: 13px;
  color: var(--confidence-high);
  font-family: var(--font-mono);
  letter-spacing: 0.1em;
  font-weight: bold;
}

.encyclo-code-effect {
  font-size: 10px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  margin-top: 4px;
  font-style: italic;
}

.team-note,
.timeline-desc {
  color: var(--text-secondary);
}

.encyclo-empty {
  font-size: 11px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  padding: 24px;
  text-align: center;
}

.encyclo-placeholder {
  font-size: 11px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  padding: 48px 24px;
  text-align: center;
}

.encyclo-loading {
  font-size: 11px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  padding: 24px;
  text-align: center;
}

.hub-section {
  border: 1px solid var(--border);
  padding: 16px;
  margin-bottom: 16px;
}

.hub-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.hub-section-link {
  font-size: 10px;
  color: var(--text-alert);
  font-family: var(--font-mono);
  text-decoration: none;
  letter-spacing: 0.05em;
}

.hub-section-link:hover { text-decoration: underline; }

.hub-section-desc {
  font-size: 10px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  margin-bottom: 12px;
}

.hub-encyclo-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}

.hub-encyclo-card {
  border: 1px solid var(--border);
  padding: 8px 10px;
  cursor: pointer;
  font-family: var(--font-mono);
}

.hub-encyclo-card:hover { background: var(--bg-card); border-color: var(--accent); }

.hub-encyclo-card-title {
  font-size: 10px;
  color: var(--text-primary);
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hub-encyclo-card-meta {
  font-size: 10px;
  color: var(--text-muted);
}

/* RESPONSIVE */
@media (max-width: 768px) {
  .encyclo-layout { grid-template-columns: 1fr; }
  .encyclo-list { max-height: 240px; border-right: none; border-bottom: 1px solid var(--border); }
  .hub-encyclo-grid { grid-template-columns: 1fr; }
}

/* ========================================
   TERMINAL LAYOUT ? Shared
   ======================================== */

.terminal-context {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  padding: 8px 0 4px 0;
  letter-spacing: 0.06em;
  border-bottom: 1px solid var(--border);
  margin-bottom: 0;
}

.terminal-context .ctx-active { color: var(--text-primary); }

.terminal-summary-bar {
  display: flex;
  gap: 0;
  border: 1px solid var(--border);
  border-bottom: none;
  font-family: var(--font-mono);
}

.terminal-summary-cell {
  flex: 1;
  min-width: 0;
  padding: 8px 14px;
  border-right: 1px solid var(--border);
  font-size: 10px;
  overflow: hidden;
}

.terminal-summary-cell:last-child { border-right: none; }

.terminal-summary-label {
  color: var(--text-muted);
  font-size: 10px;
  letter-spacing: 0.08em;
  margin-bottom: 4px;
  text-transform: uppercase;
}

.terminal-summary-value {
  font-size: 16px;
  color: var(--text-primary);
  font-weight: bold;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.terminal-summary-value.positive,
.positive { color: var(--confidence-high); }

.terminal-summary-value.negative,
.negative { color: var(--confidence-low, #e05252); }

.terminal-summary-value.neutral,
.neutral { color: var(--text-alert); }

.terminal-table-header {
  display: grid;
  padding: 6px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-bottom: none;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.terminal-row {
  display: grid;
  padding: 7px 12px;
  border: 1px solid var(--border);
  border-top: none;
  font-family: var(--font-mono);
  font-size: 11px;
  cursor: pointer;
  align-items: center;
}

.terminal-row:hover { background: var(--bg-card); }

.terminal-row.selected {
  background: var(--bg-card);
  border-left: 2px solid var(--accent);
}

.terminal-row.row-franchise {
  background: rgba(0,255,102,0.03);
}

.terminal-row-indicator {
  color: var(--text-muted);
  width: 12px;
  flex-shrink: 0;
}

.terminal-row.selected .terminal-row-indicator {
  color: var(--accent);
}

.trend-up { color: var(--confidence-high); }
.trend-down { color: var(--confidence-low, #e05252); }
.trend-flat { color: var(--text-muted); }

.terminal-preview-panel {
  border: 1px solid var(--border);
  border-top: none;
  padding: 12px 16px;
  font-family: var(--font-mono);
  background: var(--bg-card);
  min-height: 64px;
}

.terminal-preview-label {
  font-size: 10px;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 4px;
}

.terminal-preview-title {
  font-size: 13px;
  color: var(--text-primary);
  font-weight: bold;
  margin-bottom: 6px;
}

.terminal-preview-row {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 10px;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.terminal-preview-row span { white-space: nowrap; }
.terminal-preview-row .pv-label { color: var(--text-muted); }
.terminal-preview-row .pv-val { color: var(--text-primary); }

.terminal-footer {
  border: 1px solid var(--border);
  border-top: none;
  padding: 6px 12px;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-muted);
  display: flex;
  gap: 20px;
  letter-spacing: 0.04em;
}

.terminal-footer kbd {
  color: var(--text-primary);
  background: none;
  border: none;
  padding: 0;
  font-family: inherit;
  font-size: inherit;
}

.terminal-query-line {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 11px;
  background: var(--bg-surface);
}

.terminal-query-label {
  color: var(--text-muted);
  white-space: nowrap;
  font-size: 10px;
  letter-spacing: 0.06em;
}

.terminal-query-input {
  flex: 1;
  background: none;
  border: none;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 13px;
  outline: none;
  caret-color: var(--accent);
}

.terminal-query-count {
  color: var(--text-muted);
  font-size: 10px;
  white-space: nowrap;
}

.terminal-filter-bar {
  display: flex;
  gap: 0;
  border: 1px solid var(--border);
  border-top: none;
  overflow-x: auto;
}

.terminal-filter-group {
  display: flex;
  border-right: 1px solid var(--border);
  padding: 0;
}

.terminal-filter-group:last-child { border-right: none; }

.terminal-filter-btn {
  background: none;
  border: none;
  border-right: 1px solid var(--border);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 6px 14px;
  cursor: pointer;
  letter-spacing: 0.06em;
  white-space: nowrap;
}

.terminal-filter-btn:last-child { border-right: none; }
.terminal-filter-btn:hover { color: var(--text-primary); background: var(--bg-card); }

.terminal-filter-btn.active {
  color: var(--accent);
  background: var(--bg-card);
}

.terminal-status-line {
  padding: 6px 12px;
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
  border-bottom: none;
}

.footer-igdb {
  margin-top: 8px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
}

.footer-igdb a {
  color: var(--text-alert);
  text-decoration: none;
}

.footer-igdb a:hover {
  text-decoration: underline;
}

.terminal-action-link {
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  text-decoration: none;
}

.terminal-action-link:hover {
  text-decoration: underline;
}

.terminal-inline-btn {
  background: none;
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 2px 8px;
  cursor: pointer;
  margin-left: 8px;
}

.terminal-inline-btn:hover {
  color: var(--text-primary);
  border-color: var(--accent);
}

/* ========================================
   HUB PAGE
   ======================================== */

body { padding-bottom: 24px; }

.hub-hero {
  max-width: 900px;
  margin: 0 auto 32px;
  text-align: center;
  padding: 32px 0 24px;
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 15%, transparent);
}

.hub-hero h1 {
  font-size: 28px;
  color: var(--text-value);
  letter-spacing: 0.12em;
  margin-bottom: 8px;
}

.hub-hero .tagline {
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.hub-stats {
  display: flex;
  gap: 24px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 16px;
}

.hub-stat {
  text-align: center;
}

.hub-stat .val {
  font-size: 22px;
  color: var(--text-value);
  display: block;
}

.hub-stat .lbl {
  font-size: 10px;
  color: var(--text-muted);
  letter-spacing: 0.06em;
}

.hub-search {
  max-width: 900px;
  margin: 0 auto 32px;
  text-align: center;
}

.hub-search-form {
  display: flex;
  gap: 10px;
  align-items: center;
  margin: 0 auto 12px;
}

.hub-search-input {
  flex: 1;
  min-width: 0;
  height: 52px;
  padding: 0 16px;
  border: 1px solid var(--accent, #00ff66);
  background: var(--bg-surface, #050805);
  color: var(--text-primary, #00ff66);
  font-family: var(--font-ui);
  font-size: 16px;
}

.hub-search-input::placeholder {
  color: var(--text-muted, #4a8a54);
}

.hub-search-button {
  height: 52px;
  padding: 0 18px;
  border: 1px solid var(--accent, #00ff66);
  background: var(--bg-surface, #050805);
  color: var(--text-primary, #00ff66);
  font-family: var(--font-ui);
  font-size: 14px;
  cursor: pointer;
}

.hub-search-button:hover {
  background: color-mix(in srgb, var(--accent) 8%, transparent);
}

.hub-random-button {
  display: block;
  margin-top: 0.6rem;
  padding: 0 14px;
  height: 36px;
  border: 1px solid var(--accent-dim);
  background: transparent;
  color: var(--text-secondary);
  font: 12px monospace;
  cursor: pointer;
  letter-spacing: 0.08em;
  transition: color 0.15s, border-color 0.15s;
}

.hub-random-button:hover {
  color: var(--text-primary);
  border-color: var(--text-primary);
  background: color-mix(in srgb, var(--accent) 5%, transparent);
}

.hub-quick-links {
  font-size: 12px;
  color: var(--text-secondary);
}

.hub-quick-links a {
  color: var(--text-primary);
  text-decoration: none;
}

.hub-quick-links a:hover {
  color: var(--text-value);
}

.section-title {
  max-width: 900px;
  margin: 0 auto 14px;
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.collection-preview {
  max-width: 900px;
  margin: 0 auto 32px;
  background: color-mix(in srgb, var(--accent) 4%, var(--bg));
  border: 1px solid color-mix(in srgb, var(--accent) 15%, transparent);
  border-radius: 6px;
  padding: 16px 20px;
}

.collection-preview h3 {
  font-size: 12px;
  color: var(--text-value);
  margin-bottom: 12px;
}

.coll-items {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.coll-pill {
  font-size: 11px;
  padding: 4px 10px;
  border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent);
  border-radius: 3px;
  color: var(--text-secondary);
  text-decoration: none;
}

.coll-empty {
  font-size: 11px;
  color: var(--text-muted);
}

.legendary-section {
  max-width: 900px;
  margin: 2rem auto 32px;
}

.legendary-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

.legendary-card {
  border: 1px solid var(--text-alert);
  background: var(--bg-surface);
  padding: 0;
  overflow: hidden;
  cursor: pointer;
  border-radius: 6px;
}

.legendary-card:hover {
  border-color: var(--text-primary);
}

.legendary-card canvas {
  width: 100%;
  height: 80px;
  display: block;
}

.legendary-card-info {
  padding: 0.4rem 0.5rem;
}

.legendary-card-title {
  font-size: 0.7rem;
  color: var(--text-alert);
  font-weight: bold;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.legendary-card-meta {
  font-size: 0.6rem;
  color: var(--text-secondary);
  margin-top: 0.15rem;
}

.legendary-card-price {
  font-size: 0.75rem;
  color: var(--text-primary);
  margin-top: 0.15rem;
}

.hub-footer-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 4px 16px;
  background: var(--bg-surface);
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.65rem;
  color: var(--accent-dim);
  z-index: 100;
}

.hub-footer-attribution {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 0.65rem;
}

/* ========================================
   EXPERIENCE LAYER - COLLECTOR TERMINAL
   ======================================== */

.experience-status {
  position: fixed;
  left: 16px;
  bottom: 16px;
  z-index: 240;
  max-width: 340px;
  padding: 8px 12px;
  border: 1px solid var(--accent-dim);
  background: rgba(5, 10, 5, 0.94);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.18s ease, transform 0.18s ease;
  pointer-events: none;
  box-shadow: 0 0 18px rgba(0, 255, 102, 0.08);
}

.experience-status::before {
  content: "SYS";
  display: inline-block;
  margin-right: 8px;
  color: var(--text-muted);
}

.experience-status.visible {
  opacity: 1;
  transform: translateY(0);
}

.experience-collector-flag {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 235;
  padding: 5px 9px;
  border: 1px solid var(--accent-dim);
  background: rgba(5, 10, 5, 0.92);
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.experience-tooltip {
  position: fixed;
  z-index: 245;
  padding: 5px 8px;
  border: 1px solid var(--accent-dim);
  background: rgba(5, 10, 5, 0.96);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.12s ease, transform 0.12s ease;
  pointer-events: none;
}

.experience-tooltip.visible {
  opacity: 1;
  transform: translateY(0);
}

.experience-micro-tag {
  display: inline-flex;
  align-items: center;
  margin-top: 6px;
  padding: 2px 7px;
  border: 1px solid var(--accent-dim);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.experience-row-monochrome {
  background-image: linear-gradient(90deg, rgba(139, 172, 15, 0.05), transparent 38%);
}

.experience-row-archive {
  box-shadow: inset 1px 0 0 rgba(221, 196, 32, 0.24);
}

.experience-row-canon .result-title,
.experience-row-canon .franchise-game-title,
.experience-row-canon .encyclo-row-title {
  color: var(--text-primary);
  text-shadow: 0 0 8px color-mix(in srgb, var(--accent) 8%, transparent);
}

.experience-empty {
  color: var(--text-muted);
}

body.collector-mode::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 120;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(0, 255, 102, 0.02), transparent 42%),
    repeating-linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.025) 0,
      rgba(255, 255, 255, 0.025) 1px,
      transparent 1px,
      transparent 4px
    );
  opacity: 0.14;
}

body.collector-mode .page-title,
body.collector-mode .hero-title,
body.collector-mode .terminal-preview-title {
  text-shadow: 0 0 7px rgba(0, 255, 102, 0.16);
}

body.collector-mode .terminal-row:hover,
body.collector-mode .legendary-card:hover,
body.collector-mode .encyclo-list-row:hover {
  box-shadow: inset 0 0 0 1px rgba(0, 255, 102, 0.1);
}

body.experience-gameboy .experience-micro-tag,
body.experience-gameboy .terminal-preview-label {
  color: var(--accent);
  border-color: rgba(139, 172, 15, 0.26);
}

body.experience-archive .experience-micro-tag,
body.experience-archive .terminal-preview-label {
  color: var(--text-alert);
  border-color: color-mix(in srgb, var(--confidence-mid) 8%, transparent);
}

body.experience-canon .experience-micro-tag,
body.experience-canon .terminal-preview-label {
  color: var(--confidence-high);
  border-color: rgba(0, 255, 102, 0.2);
}

@media (max-width: 768px) {
  .legendary-grid {
    grid-template-columns: 1fr;
  }

  .hub-search-form {
    flex-direction: column;
  }

  .hub-search-button {
    width: 100%;
  }

  .experience-status {
    left: 12px;
    right: 12px;
    bottom: 12px;
    max-width: none;
  }

  .experience-collector-flag {
    right: 12px;
    bottom: 56px;
  }
}

/* ========================================
   FRANCHISES - HIERARCHY REFINEMENT
   ======================================== */

.franchises-page {
  width: min(1360px, calc(100% - 48px));
  margin: 0 auto 40px;
}

.franchises-header-shell {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 18px;
}

.franchises-system-nav {
  display: flex;
  gap: 18px;
  align-items: center;
  padding: 6px 0 10px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.55);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.franchises-system-nav a,
.franchises-system-nav .is-current {
  color: var(--text-muted);
  text-decoration: none;
}

.franchises-system-nav a:hover {
  color: var(--text-secondary);
}

.franchises-system-nav .is-current {
  color: var(--text-primary);
}

.franchises-title-block {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.franchises-title-block .page-title {
  margin-bottom: 0;
}

.franchises-title-block .page-subtitle {
  margin: 0;
}

.franchises-search-shell {
  display: grid;
  grid-template-columns: 112px 1fr auto;
  gap: 0;
  align-items: center;
  border: 1px solid rgba(67, 95, 60, 0.72);
  background: rgba(8, 12, 8, 0.92);
  min-height: 48px;
}

.franchises-search-label {
  padding: 0 14px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.franchises-search-input {
  width: 100%;
  min-width: 0;
  padding: 0 14px;
  border: 0;
  background: transparent;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 13px;
  outline: none;
  caret-color: var(--accent);
}

.franchises-search-input::placeholder {
  color: rgba(116, 142, 110, 0.82);
}

.franchises-search-shell:focus-within {
  border-color: var(--text-secondary);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 15%, transparent);
}

.franchises-search-link {
  align-self: stretch;
  display: inline-flex;
  align-items: center;
  padding: 0 16px;
  border-left: 1px solid rgba(67, 95, 60, 0.72);
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
}

.franchises-search-link:hover {
  background: rgba(17, 24, 17, 0.98);
  color: var(--text-alert);
}

.franchises-layout {
  display: grid;
  grid-template-columns: 312px minmax(0, 1fr);
  gap: 0;
  min-height: 700px;
  border: 1px solid rgba(67, 95, 60, 0.68);
  background: rgba(5, 8, 5, 0.94);
}

.franchises-sidebar {
  display: flex;
  flex-direction: column;
  min-height: 0;
  border-right: 1px solid rgba(67, 95, 60, 0.55);
  background: linear-gradient(180deg, rgba(8, 11, 8, 0.98), rgba(6, 9, 6, 0.98));
}

.franchises-sidebar-head {
  padding: 12px 14px 10px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.52);
}

.franchises-sidebar-kicker,
.franchises-sidebar-meta {
  font-family: var(--font-mono);
  text-transform: uppercase;
}

.franchises-sidebar-kicker {
  color: var(--text-secondary);
  font-size: 10px;
  letter-spacing: 0.1em;
  margin-bottom: 4px;
}

.franchises-sidebar-meta {
  color: var(--text-muted);
  font-size: 10px;
  letter-spacing: 0.08em;
}

.franchise-list {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 4px 0;
}

.franchise-list-item {
  position: relative;
  width: 100%;
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 9px 14px 10px;
  border: 0;
  border-left: 2px solid transparent;
  border-bottom: 1px solid rgba(45, 61, 41, 0.46);
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.franchise-list-item:hover {
  background: rgba(17, 24, 17, 0.92);
}

.franchise-list-item.selected {
  background: linear-gradient(90deg, color-mix(in srgb, var(--accent) 8%, transparent), var(--bg) 72%);
  border-left-color: var(--accent);
}

.franchise-list-item.selected .franchise-name {
  color: var(--text-primary);
}

.franchise-item-marker {
  color: rgba(110, 141, 103, 0.7);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.4;
}

.franchise-list-item.selected .franchise-item-marker {
  color: var(--text-alert);
}

.franchise-item-copy {
  min-width: 0;
}

.franchise-name {
  margin-bottom: 2px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  line-height: 1.45;
}

.franchise-years,
.franchise-list-developer {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.45;
}

.franchise-list-empty {
  padding: 20px 16px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.franchises-detail {
  overflow-y: auto;
  background:
    linear-gradient(180deg, rgba(9, 12, 9, 0.98), rgba(5, 8, 5, 0.98)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 30%);
}

.franchise-panel {
  min-height: 100%;
  padding: 18px 20px 22px;
}

.franchise-panel-header {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  margin-bottom: 18px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.58);
}

.franchise-archive-slot {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 108px;
  padding: 14px 12px;
  border: 1px solid rgba(72, 90, 69, 0.72);
  background:
    linear-gradient(180deg, var(--bg), var(--bg)),
    repeating-linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.018) 0,
      rgba(255, 255, 255, 0.018) 1px,
      transparent 1px,
      transparent 4px
    );
  box-shadow: inset 0 0 0 1px rgba(8, 12, 8, 0.92);
}

.franchise-archive-code {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 29px;
  letter-spacing: 0.14em;
  line-height: 1;
}

.franchise-archive-caption {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.franchise-panel-main {
  min-width: 0;
}

.franchise-panel-kicker {
  margin-bottom: 6px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.detail-title {
  margin: 0 0 6px;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: clamp(20px, 2.4vw, 29px);
  line-height: 1.1;
  letter-spacing: 0.04em;
}

.franchise-years-line {
  margin-bottom: 10px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.07em;
}

.franchise-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.detail-pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border: 1px solid rgba(67, 95, 60, 0.65);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.detail-pill-quiet {
  color: var(--text-muted);
}

.detail-pill-accent {
  border-color: color-mix(in srgb, var(--confidence-mid) 8%, transparent);
  color: var(--text-alert);
}

.franchise-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.franchise-action-link {
  display: inline-flex;
  align-items: center;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
  cursor: pointer;
}

.franchise-action-link:hover {
  color: var(--text-alert);
  text-decoration: underline;
}

.franchise-action-link.button-link {
  appearance: none;
}

.franchise-detail-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  margin-bottom: 16px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.55);
}

.franchise-detail-tab {
  padding: 9px 14px 8px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}

.franchise-detail-tab:hover {
  color: var(--text-secondary);
}

.franchise-detail-tab.active {
  color: var(--text-alert);
  border-bottom-color: var(--text-alert);
}

.franchise-detail-body {
  min-height: 360px;
}

.franchise-tab-panel[hidden] {
  display: none !important;
}

.franchise-section {
  margin-bottom: 18px;
  padding: 0;
  border: 0;
}

.franchise-section:last-child {
  margin-bottom: 0;
}

.franchise-description,
.franchise-legacy,
.anecdote-text {
  max-width: 78ch;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.85;
}

.franchise-description-lead {
  color: var(--text-primary);
}

.franchise-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 12px 0 10px;
}

.franchise-platforms {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
  letter-spacing: 0.04em;
}

.timeline-list,
.team-table,
.franchise-games-list {
  width: 100%;
}

.timeline-row {
  display: grid;
  grid-template-columns: 80px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: start;
  padding: 10px 0;
  border-top: 1px solid rgba(45, 61, 41, 0.42);
}

.timeline-row:first-child {
  border-top: 0;
}

.timeline-year {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
}

.timeline-main {
  min-width: 0;
}

.timeline-title {
  margin-bottom: 2px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
}

.timeline-platform,
.timeline-description {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.timeline-badge {
  display: inline-flex;
  align-items: center;
  align-self: start;
  padding: 2px 8px;
  border: 1px solid rgba(67, 95, 60, 0.62);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.timeline-badge-release,
.timeline-badge-launch,
.timeline-badge-debut {
  border-color: var(--accent-dim);
  color: var(--text-primary);
}

.timeline-badge-acquisition,
.timeline-badge-revival,
.timeline-badge-milestone {
  border-color: color-mix(in srgb, var(--confidence-mid) 8%, transparent);
  color: var(--text-alert);
}

.team-table {
  border-top: 1px solid rgba(45, 61, 41, 0.42);
}

.team-row {
  display: grid;
  grid-template-columns: 80px 1.1fr 1fr 110px 1.4fr;
  gap: 12px;
  align-items: start;
  padding: 9px 0;
  border-bottom: 1px solid rgba(45, 61, 41, 0.42);
}

.team-row-head {
  padding-top: 0;
}

.team-row-head .team-cell {
  color: var(--text-muted);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.team-cell {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.team-name {
  color: var(--text-primary);
}

.team-event {
  color: var(--text-muted);
}

.team-event-joined {
  color: var(--confidence-high);
}

.team-event-left {
  color: var(--status-negative);
}

.team-event-changed {
  color: var(--text-alert);
}

.encyclo-anecdote {
  padding: 12px 0;
  border-top: 1px solid rgba(45, 61, 41, 0.42);
}

.encyclo-anecdote:first-of-type {
  padding-top: 0;
  border-top: 0;
}

.anecdote-title {
  margin-bottom: 6px;
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.franchise-games-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.franchise-game-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 9px 0;
  border-top: 1px solid rgba(45, 61, 41, 0.42);
  color: inherit;
  text-decoration: none;
}

.franchise-game-row:first-child {
  border-top: 0;
}

.franchise-game-row:hover .franchise-game-title {
  color: var(--text-primary);
}

.franchise-game-title {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
}

.franchise-game-meta {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  text-align: right;
  white-space: nowrap;
}

.franchise-detail-empty {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 14px;
  min-height: 100%;
  padding: 26px 22px;
}

.franchise-empty-copy {
  max-width: 52ch;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.8;
}

.franchise-list::-webkit-scrollbar,
.franchises-detail::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

.franchise-list::-webkit-scrollbar-track,
.franchises-detail::-webkit-scrollbar-track {
  background: rgba(8, 11, 8, 0.96);
}

.franchise-list::-webkit-scrollbar-thumb,
.franchises-detail::-webkit-scrollbar-thumb {
  border: 2px solid rgba(8, 11, 8, 0.96);
  background: rgba(80, 111, 74, 0.9);
}

.franchise-list,
.franchises-detail {
  scrollbar-color: rgba(80, 111, 74, 0.9) rgba(8, 11, 8, 0.96);
  scrollbar-width: thin;
}

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

  .franchises-sidebar {
    border-right: 0;
    border-bottom: 1px solid rgba(67, 95, 60, 0.55);
    max-height: 320px;
  }

  .franchise-panel-header {
    grid-template-columns: 88px minmax(0, 1fr);
  }
}

@media (max-width: 720px) {
  .franchises-page {
    width: min(100%, calc(100% - 24px));
  }

  .franchises-system-nav {
    flex-wrap: wrap;
    gap: 10px 14px;
  }

  .franchises-search-shell {
    grid-template-columns: 1fr;
  }

  .franchises-search-label,
  .franchises-search-input,
  .franchises-search-link {
    padding: 10px 12px;
  }

  .franchises-search-link {
    border-left: 0;
    border-top: 1px solid rgba(67, 95, 60, 0.72);
  }

  .franchise-panel {
    padding: 16px 14px 18px;
  }

  .franchise-panel-header {
    grid-template-columns: 1fr;
  }

  .franchise-archive-slot {
    min-height: 90px;
  }

  .timeline-row,
  .franchise-game-row,
  .team-row {
    grid-template-columns: 1fr;
  }

  .franchise-game-meta {
    text-align: left;
    white-space: normal;
  }
}

/* ========================================
   HUB - COCKPIT REFINEMENT
   ======================================== */

body {
  padding-bottom: 46px;
}

.hub-breadcrumb {
  width: min(1320px, calc(100% - 48px));
  margin: 0 auto 16px;
}

.hub-page {
  width: min(1320px, calc(100% - 48px));
  margin: 0 auto 40px;
}

.hub-cockpit {
  margin-bottom: 18px;
  border: 1px solid rgba(67, 95, 60, 0.7);
  background:
    linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 28%);
}

.hub-cockpit-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(380px, 0.9fr);
  gap: 0;
  border-bottom: 1px solid rgba(67, 95, 60, 0.52);
}

.hub-identity-panel,
.hub-actions-panel {
  padding: 20px 22px;
}

.hub-actions-panel {
  border-left: 1px solid rgba(67, 95, 60, 0.52);
}

.hub-kicker,
.hub-panel-label,
.hub-module-kicker,
.hub-system-key,
.hub-system-label {
  font-family: var(--font-mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.hub-kicker,
.hub-panel-label {
  color: var(--text-muted);
  font-size: 10px;
  margin-bottom: 8px;
}

.hub-page-title {
  margin-bottom: 8px;
  font-size: clamp(28px, 5vw, 42px);
  letter-spacing: 0.12em;
}

.hub-intro {
  max-width: 52ch;
  margin: 0 0 14px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.8;
}

/* .hub-system-line — canonical definition in unified section (below) */

.hub-system-label {
  color: var(--text-muted);
  font-size: 10px;
}

.hub-search-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0;
  align-items: stretch;
  margin: 0 0 12px;
  border: 1px solid rgba(67, 95, 60, 0.72);
  background: rgba(8, 12, 8, 0.92);
}

.hub-search-input {
  min-width: 0;
  height: 48px;
  padding: 0 14px;
  border: 0;
  background: transparent;
  color: var(--text-primary);
  font: 13px var(--font-mono);
  outline: none;
  caret-color: var(--accent);
}

.hub-search-input::placeholder {
  color: rgba(116, 142, 110, 0.82);
}

.hub-search-form:focus-within {
  border-color: var(--text-secondary);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 15%, transparent);
}

.hub-search-button {
  min-width: 136px;
  height: 48px;
  padding: 0 16px;
  border: 0;
  border-left: 1px solid rgba(67, 95, 60, 0.72);
  background: rgba(17, 24, 17, 0.98);
  color: var(--text-alert);
  font: 10px var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}

.hub-search-button:hover {
  color: var(--text-alert);
  background: rgba(28, 36, 28, 0.98);
}

.hub-action-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.hub-action-card {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-height: 92px;
  padding: 11px 12px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: rgba(8, 12, 8, 0.72);
  color: inherit;
  text-decoration: none;
}

.hub-action-card:hover {
  border-color: var(--accent-dim);
  background: var(--bg);
}

.hub-action-card.is-primary {
  border-color: var(--accent-dim);
  background: linear-gradient(180deg, rgba(13, 20, 13, 0.96), rgba(8, 12, 8, 0.92));
}

.hub-action-code {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.hub-action-title {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.05em;
}

.hub-action-copy {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.6;
}

.hub-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  margin-top: 0;
}

.hub-stat {
  padding: 14px 18px;
  border-right: 1px solid rgba(67, 95, 60, 0.52);
  text-align: left;
}

.hub-stat:last-child {
  border-right: 0;
}

.hub-stat .val {
  display: block;
  margin-bottom: 4px;
  font-size: 21px;
  color: var(--text-secondary);
}

.hub-stat .lbl {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
}

.hub-stat.is-primary .val {
  color: var(--text-primary);
  font-size: 25px;
}

.hub-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) 340px;
  gap: 18px;
  align-items: start;
}

.hub-content-main,
.hub-content-side {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.hub-module,
.legendary-section,
.collection-preview,
.hub-section {
  max-width: none;
  margin: 0;
  padding: 16px 18px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: var(--bg);
}

.hub-module-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 10px;
}

.hub-module-kicker {
  color: var(--text-muted);
  font-size: 10px;
  margin-bottom: 4px;
}

.hub-module-title {
  margin: 0;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 16px;
  letter-spacing: 0.05em;
}

.hub-module-title-hint {
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.04em;
  cursor: help;
}

.hub-module-link {
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
}

.hub-module-link:hover {
  color: var(--text-alert);
  text-decoration: underline;
}

.hub-module-copy {
  margin: 0 0 14px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.legendary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.legendary-card {
  border: 1px solid color-mix(in srgb, var(--confidence-mid) 8%, transparent);
  background: rgba(9, 12, 9, 0.92);
  border-radius: 0;
}

.legendary-card:hover {
  border-color: color-mix(in srgb, var(--confidence-mid) 8%, transparent);
  background: rgba(14, 18, 14, 0.96);
}

.legendary-card canvas {
  height: 86px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.42);
}

.legendary-card-info {
  padding: 8px 10px 10px;
}

.legendary-card-title {
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.04em;
}

.legendary-card-meta {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
}

.legendary-card-price {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 10px;
}

.collection-preview {
  background:
    linear-gradient(180deg, var(--bg), var(--bg)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 34%);
}

.coll-items {
  gap: 8px;
}

.coll-pill {
  padding: 5px 9px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  border-radius: 0;
  background: rgba(8, 12, 8, 0.78);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
}

.coll-pill:hover {
  color: var(--text-primary);
  border-color: var(--accent-dim);
}

.coll-empty {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.hub-system-module {
  background: var(--bg);
}

.hub-system-grid {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-bottom: 14px;
  border-top: 1px solid rgba(67, 95, 60, 0.42);
}

.hub-system-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid rgba(67, 95, 60, 0.42);
  font-family: var(--font-mono);
  font-size: 10px;
}

.hub-system-key {
  color: var(--text-muted);
  font-size: 10px;
}

.hub-system-value {
  color: var(--text-secondary);
  text-align: right;
  line-height: 1.6;
}

.hub-system-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hub-action-inline {
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
}

.hub-action-inline:hover {
  color: var(--text-alert);
  text-decoration: underline;
}

.hub-footer-bar {
  padding: 5px 14px;
  border-top-color: rgba(67, 95, 60, 0.65);
  background: rgba(5, 8, 5, 0.98);
  font-family: var(--font-mono);
}

.hub-footer-bar span {
  white-space: nowrap;
}

html::-webkit-scrollbar,
body::-webkit-scrollbar {
  width: 10px;
}

html::-webkit-scrollbar-track,
body::-webkit-scrollbar-track {
  background: rgba(5, 8, 5, 0.98);
}

html::-webkit-scrollbar-thumb,
body::-webkit-scrollbar-thumb {
  border: 2px solid rgba(5, 8, 5, 0.98);
  background: rgba(80, 111, 74, 0.9);
}

html,
body {
  scrollbar-color: rgba(80, 111, 74, 0.9) rgba(5, 8, 5, 0.98);
  scrollbar-width: thin;
}

@media (max-width: 1100px) {
  .hub-cockpit-grid,
  .hub-content-grid {
    grid-template-columns: 1fr;
  }

  .hub-actions-panel {
    border-left: 0;
    border-top: 1px solid rgba(67, 95, 60, 0.52);
  }
}

@media (max-width: 780px) {
  .hub-breadcrumb,
  .hub-page {
    width: min(100%, calc(100% - 24px));
  }

  .hub-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hub-search-form,
  .hub-action-grid,
  .legendary-grid,
  .hub-encyclo-grid {
    grid-template-columns: 1fr;
  }

  .hub-search-button {
    border-left: 0;
    border-top: 1px solid rgba(67, 95, 60, 0.72);
  }

  .hub-module-head,
  .hub-system-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .hub-system-value {
    text-align: left;
  }
}

/* ========================================
   HUB - 4 ENTRY POINT REFRAME
   ======================================== */

.hub-page.hub-orientation-page {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.catalog-operating-strip {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(360px, 0.85fr);
  gap: 14px;
  margin-bottom: 18px;
}

.catalog-operating-card {
  padding: 16px 18px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: var(--bg);
}

.catalog-operating-card-primary {
  background:
    linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 28%);
}

.catalog-operating-kicker,
.catalog-operating-label {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.catalog-operating-title {
  margin: 4px 0 8px;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 16px;
  letter-spacing: 0.04em;
}

.catalog-operating-copy {
  margin: 0;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.catalog-operating-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  margin-top: 10px;
  border-top: 1px solid rgba(67, 95, 60, 0.42);
}

.catalog-operating-stat {
  padding: 12px 10px 0 0;
  border-right: 1px solid rgba(67, 95, 60, 0.42);
}

.catalog-operating-stat:last-child {
  border-right: 0;
}

.catalog-operating-value {
  display: block;
  margin-bottom: 4px;
  color: var(--text-primary);
  font-size: 21px;
}

.hub-orientation-head {
  border: 1px solid rgba(67, 95, 60, 0.7);
  background:
    linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 28%);
}

.hub-orientation-head .hub-identity-panel {
  padding: 22px 24px;
}

.hub-universe-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.hub-universe-card {
  display: flex;
  flex-direction: column;
  min-height: 280px;
  padding: 18px 20px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background:
    linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 30%);
}

.hub-universe-card:hover {
  border-color: var(--accent-dim);
  background:
    linear-gradient(180deg, var(--bg), var(--bg)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 6%, transparent), transparent 34%);
}

.hub-universe-market {
  border-top: 2px solid color-mix(in srgb, var(--confidence-mid) 8%, transparent);
}

.hub-universe-dex,
.hub-universe-collections,
.hub-universe-search {
  border-top: 2px solid rgba(67, 95, 60, 0.72);
}

.hub-universe-search {
  border-top-color: var(--text-secondary);
}

.hub-universe-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 12px;
}

.hub-universe-kicker {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.hub-universe-title {
  margin: 0;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 22px;
  letter-spacing: 0.06em;
}

.hub-universe-signal {
  min-width: 126px;
  padding: 4px 8px;
  border: 1px solid rgba(67, 95, 60, 0.52);
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-align: right;
}

.hub-universe-copy {
  margin: 0 0 12px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.8;
}

.hub-universe-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin: 0 0 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(67, 95, 60, 0.42);
}

.hub-universe-list span {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.6;
}

.hub-universe-list.is-search {
  margin-top: 2px;
}

.hub-universe-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid rgba(67, 95, 60, 0.42);
}

.hub-inline-link {
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-decoration: none;
  text-transform: uppercase;
}

.hub-inline-link:hover {
  color: var(--text-alert);
  text-decoration: underline;
}

.hub-intent-panel {
  padding: 16px 18px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: var(--bg);
}

.hub-intent-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 14px;
}

.hub-intent-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.hub-intent-grid-two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-width: 680px;
}

.hub-intent-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
  min-height: 176px;
  padding: 11px 12px;
  border: 1px solid rgba(67, 95, 60, 0.42);
  background: rgba(8, 12, 8, 0.78);
}

.hub-intent-label {
  display: block;
  margin-bottom: 6px;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
}

.hub-intent-copy {
  margin: 0 0 10px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.hub-intent-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hub-intent-links a {
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-decoration: none;
}

.hub-intent-links a:hover {
  color: var(--text-alert);
  text-decoration: underline;
}

.hub-secondary-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) 340px;
  gap: 18px;
  align-items: start;
}

.hub-secondary-main,
.hub-secondary-side {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.hub-signals-panel .hub-stats.hub-stats-secondary {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 14px;
  border: 1px solid rgba(67, 95, 60, 0.42);
}

.hub-signals-panel .hub-stat {
  min-height: 84px;
}

.hub-signals-panel .hub-system-grid {
  margin-top: 2px;
}

.hub-signals-panel .hub-module-head,
.hub-intent-head,
.hub-module-head {
  align-items: flex-start;
}

@media (max-width: 1100px) {
  .hub-universe-grid,
  .hub-secondary-grid,
  .hub-intent-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 780px) {
  .catalog-operating-strip {
    grid-template-columns: 1fr;
  }

  .catalog-operating-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .catalog-operating-stat:nth-child(2n) {
    border-right: 0;
  }

  .hub-universe-head,
  .hub-intent-head,
  .hub-module-head,
  .hub-system-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .hub-universe-signal {
    min-width: 0;
    text-align: left;
  }

  .hub-search-form {
    grid-template-columns: 1fr;
  }

  .hub-search-button {
    border-left: 0;
    border-top: 1px solid rgba(67, 95, 60, 0.72);
  }

  .hub-signals-panel .hub-stats.hub-stats-secondary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ========================================
   GAME DETAIL - HIERARCHY REFINEMENT
   ======================================== */

.detail-shell {
  max-width: var(--content-max, 1180px);
  gap: 18px;
}

.hero-card,
.summary-card,
.collection-card,
.contribute-section,
.stats-card,
.editorial-card,
.related-card {
  padding: 18px 20px;
  border-radius: 0;
  background:
    linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 26%);
}

.detail-accordion {
  margin-top: 14px;
  padding: 0;
  overflow: hidden;
}

.detail-accordion-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px;
  border: 0;
  background: transparent;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: left;
  cursor: pointer;
}

.detail-accordion.is-open .detail-accordion-toggle {
  background: var(--bg-surface);
  box-shadow: inset 0 -1px 0 rgba(67, 95, 60, 0.42);
}

.detail-accordion-toggle:hover {
  background: var(--bg-card);
}

.detail-accordion-indicator {
  color: rgba(241, 196, 92, 0.92);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  flex-shrink: 0;
  min-width: 14px;
  text-align: center;
  line-height: 1;
  opacity: 0.92;
}

.detail-accordion-indicator::before {
  content: '+';
}

.detail-accordion.is-open .detail-accordion-indicator::before,
[aria-expanded="true"] .detail-accordion-indicator::before {
  content: '-';
}

.detail-accordion-content {
  padding: 12px 18px 18px;
  border-top: 1px solid rgba(67, 95, 60, 0.42);
}

.detail-hero-shell {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.detail-hero-status,
.detail-section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
}

.detail-section-head.compact {
  margin-bottom: 14px;
}

.detail-kicker,
.detail-inline-label {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.breadcrumb .section {
  color: var(--text-secondary);
  letter-spacing: 0.08em;
}

/* ========================================
   PRODUCT UNIVERSE FRAMING
   ======================================== */

.product-universe-frame {
  margin: 0 0 18px;
  padding: 14px 16px 15px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  border-top: 2px solid rgba(67, 95, 60, 0.72);
  background:
    linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 30%);
}

.product-universe-frame.is-market {
  border-top-color: color-mix(in srgb, var(--confidence-mid) 8%, transparent);
}

.product-universe-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 10px;
}

.product-universe-title {
  margin: 2px 0 0;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 18px;
  letter-spacing: 0.05em;
}

.product-universe-chip {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border: 1px solid rgba(67, 95, 60, 0.52);
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.product-universe-copy {
  max-width: 76ch;
  margin: 0 0 12px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.8;
}

.product-universe-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(67, 95, 60, 0.4);
}

.product-universe-links a {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-decoration: none;
}

.product-universe-links a:hover {
  color: var(--text-primary);
}

.product-universe-links a.is-active {
  color: var(--text-alert);
}

.product-universe-overlap {
  margin-top: 10px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.detail-inline-label {
  margin-bottom: 6px;
}

.detail-status-copy,
.detail-section-copy,
.market-panel-copy {
  margin: 0;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.detail-section-copy {
  max-width: 42ch;
}

.detail-hero-grid {
  grid-template-columns: minmax(0, 1.65fr) minmax(320px, 0.95fr);
  gap: 18px;
}

.detail-identity-panel,
.detail-market-panel {
  min-width: 0;
}

.game-header-main {
  gap: 20px;
  align-items: stretch;
}

.game-cover-slot {
  width: 220px;
  flex-shrink: 0;
}

.game-cover-container {
  width: 220px;
  height: 290px;
  border: 2px solid var(--text-secondary);
  background:
    linear-gradient(180deg, rgba(5, 8, 5, 0.98), rgba(9, 12, 9, 0.98)),
    radial-gradient(circle at center, color-mix(in srgb, var(--accent) 8%, transparent), transparent 52%);
  box-shadow:
    0 0 28px var(--accent-dim),
    inset 0 0 0 1px color-mix(in srgb, var(--accent) 6%, transparent);
}

#game-cover-img {
  width: 220px;
  height: 290px;
  object-fit: cover;
  image-rendering: auto;
  display: block;
}

.game-cover-caption {
  margin-top: 8px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.game-header-copy {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.hero-title {
  margin: 0;
  font-size: clamp(30px, 4vw, 40px);
  line-height: 1.05;
  letter-spacing: 0.06em;
}

.detail-hero-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 8px 12px;
}

.detail-hero-title {
  margin: 0 0 0.5rem;
  font-family: var(--font-display);
  font-size: clamp(0.9rem, 2vw, 1.1rem);
  color: var(--text-primary);
  font-weight: 700;
  line-height: 1.3;
}

.detail-hero-rarity {
  align-self: flex-start;
  margin-top: 0.08rem;
}

.detail-hero-meta-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  align-items: center;
  margin-top: 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-muted);
}

.detail-hero-meta-value {
  color: inherit;
}

.detail-hero-developer {
  margin-top: 0.25rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-disabled);
}

.detail-studio-link {
  color: var(--text-secondary);
  text-decoration: none;
  border-bottom: 1px dotted var(--text-muted);
  font-size: inherit;
}
.detail-studio-link:hover {
  color: var(--text-primary);
  border-bottom-color: var(--text-primary);
}

.detail-hero-reference {
  display: block;
  margin-top: 0.35rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.8rem;
}

.detail-hero-reference.is-empty {
  color: var(--text-disabled);
  font-style: italic;
}

/* Three-condition price panel in hero — visual hierarchy */
.detail-hero-price-panel {
  margin-bottom: 12px;
}

.detail-hero-price-row {
  display: flex;
  align-items: baseline;
  gap: 16px;
  margin-bottom: 4px;
}

.detail-hero-price-cell {
  display: flex;
  flex-direction: column;
  min-width: 52px;
}

/* First cell (Loose) = primary, large */
.detail-hero-price-cell:first-child .detail-hero-price-value {
  font-size: 1.6rem;
  color: var(--text-value);
}

/* Other cells (CIB, Mint) = secondary, smaller */
.detail-hero-price-cell:not(:first-child) .detail-hero-price-value {
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.detail-hero-price-label {
  font-family: var(--font-mono);
  font-size: 0.58rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.detail-hero-price-value {
  font-family: var(--font-mono);
  font-weight: 700;
  line-height: 1.2;
}

/* Context section = secondary */
.detail-hero-price-context {
  font-size: 0.68rem;
}

/* Decision strip = compact */
.detail-kicker-small {
  font-size: 0.58rem;
  margin-top: 14px;
  margin-bottom: 4px;
  color: var(--text-muted);
  letter-spacing: 0.12em;
}

.detail-decision-grid {
  gap: 6px;
}

.detail-decision-strip .detail-reading-note {
  font-size: 0.68rem;
  margin-top: 6px;
}

.detail-hero-sources {
  margin-top: 0.35rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-muted);
  font-style: italic;
}

/* CIB/Mint price labels in list */
.result-price-group {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.1rem;
}

.result-price-secondary {
  display: flex;
  gap: 0.35rem;
  opacity: 0.6;
}

.result-price-cib {
  font-size: 0.7rem;
  color: var(--condition-cib, #4ecdc4);
}

.result-price-mint {
  font-size: 0.7rem;
  color: var(--condition-mint, #ffd700);
}

/* Region chips in hero */
.hero-region-chips {
  display: flex;
  gap: 0.3rem;
  flex-wrap: wrap;
  margin-top: 0.4rem;
}

.region-chip {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  padding: 1px 6px;
  border: 1px solid var(--accent-dim);
  color: var(--text-secondary);
  letter-spacing: 0.06em;
}

.region-chip.region-JP { border-color: rgba(255, 80, 80, 0.4); color: rgba(255, 120, 120, 0.8); }
.region-chip.region-US { border-color: rgba(80, 140, 255, 0.4); color: rgba(120, 170, 255, 0.8); }
.region-chip.region-EU { border-color: rgba(80, 200, 150, 0.4); color: rgba(120, 220, 170, 0.8); }

/* Price date and accordion price hint */
.detail-hero-price-date {
  margin-top: 0.25rem;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--text-disabled);
}

.detail-hero-price-help {
  margin-top: 8px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  line-height: 1.45;
}

.accordion-price-hint {
  font-size: 0.68rem;
  color: var(--text-secondary);
  font-weight: 400;
  margin-left: 0.5rem;
}

/* Retrodex index loading state */
.retrodex-index-shell .index-loading {
  padding: 0.5rem 0;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}

.game-tagline-shell {
  padding: 10px 12px;
  border-left: 2px solid var(--text-secondary);
  background: var(--bg-card);
}

.hero-summary-shell {
  margin: 0;
  padding: 10px 12px;
  border-left: 2px solid rgba(67, 95, 60, 0.58);
  background: var(--bg-card);
}

.hero-summary {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.75;
}

.game-tagline {
  margin: 0;
  padding: 0;
  border: 0;
  color: var(--text-secondary);
  font-size: 11px;
  line-height: 1.8;
  font-style: italic;
}

.hero-meta {
  margin-bottom: 0;
}

.detail-hero-chip-row {
  margin-top: 2px;
}

.detail-hero-summary-bar,
.detail-stats-bar {
  margin-top: 2px;
  border-bottom: 1px solid var(--border);
  background: rgba(8, 12, 8, 0.78);
}

.detail-hero-summary-bar .terminal-summary-cell,
.detail-stats-bar .terminal-summary-cell {
  min-width: 0;
}

.detail-hero-summary-bar .terminal-summary-value,
.detail-stats-bar .terminal-summary-value {
  min-width: 0;
  font-size: 13px;
  line-height: 1.45;
  word-break: break-word;
}

.detail-market-bridge {
  margin-top: 2px;
  padding: 12px 14px;
  border: 1px solid rgba(67, 95, 60, 0.58);
}

.detail-hero-aside {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid rgba(67, 95, 60, 0.48);
  background:
    linear-gradient(180deg, rgba(9, 13, 9, 0.9), var(--bg)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 6%, transparent), transparent 42%);
}

.detail-hero-aside-copy {
  margin: 0;
  max-width: 34ch;
}

.detail-console-support-wrap {
  display: inline-flex;
  align-items: center;
  margin-right: 2px;
  color: inherit;
}

.detail-console-support-icon {
  display: block;
  flex-shrink: 0;
}

.detail-market-bridge .terminal-preview-label {
  margin-bottom: 6px;
}

.pill {
  border-radius: 0;
  font-size: 10px;
  letter-spacing: 0.08em;
}

.game-meta-cluster {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(67, 95, 60, 0.42);
}

.game-meta-row {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.meta-key {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.meta-value,
.meta-value-link {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.6;
}

.meta-value-link {
  text-decoration: none;
}

.game-relations {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  min-height: 0;
}

.game-relation-link {
  display: inline-flex;
  flex-direction: column;
  gap: 3px;
  min-width: 120px;
  padding: 8px 10px;
  border: 1px solid rgba(67, 95, 60, 0.55);
  background: rgba(9, 14, 9, 0.9);
  color: var(--text-secondary);
  text-decoration: none;
}

.game-relation-link:hover {
  border-color: var(--text-secondary);
  color: var(--text-primary);
}

.game-relation-link.is-accent {
  border-color: rgba(189, 159, 84, 0.55);
  color: var(--text-alert);
}

.game-relation-label {
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.game-relation-value {
  font-size: 13px;
  line-height: 1.35;
  color: inherit;
}

.price-panel {
  padding: 18px;
  border-radius: 0;
  background: rgba(9, 13, 9, 0.96);
}

.market-panel-copy {
  margin-top: 8px;
  margin-bottom: 14px;
}

.r?trodex-index {
  padding: 14px;
  margin-bottom: 0;
  border-radius: 0;
  background: rgba(5, 8, 5, 0.88);
}

.index-header {
  align-items: flex-start;
  margin-bottom: 14px;
}

.index-title,
.index-subtitle,
.index-primary-label,
.trust-freshness {
  display: block;
  font-family: var(--font-mono);
  text-transform: uppercase;
}

.index-title {
  color: var(--text-primary);
  font-size: 10px;
  letter-spacing: 0.12em;
}

.index-subtitle {
  margin-top: 5px;
  color: var(--text-muted);
  font-size: 10px;
  letter-spacing: 0.08em;
}

.index-primary {
  margin-bottom: 14px;
  padding: 14px 16px;
  border: 1px solid rgba(67, 95, 60, 0.56);
  background: var(--bg-surface);
}

.index-primary-label {
  color: var(--text-muted);
  font-size: 10px;
  letter-spacing: 0.12em;
  margin-bottom: 6px;
}

.index-primary-value {
  display: block;
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 30px;
  line-height: 1;
  margin-bottom: 6px;
}

.index-primary-meta {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
}

.trust-header {
  margin-bottom: 8px;
  padding-bottom: 10px;
}

.trust-badge {
  padding: 3px 9px;
  border-radius: 0;
  font-size: 10px;
  font-family: var(--font-display);
}
.trust-badge.trust-T1 { background: color-mix(in srgb, var(--accent) 15%, transparent); border: 1px solid var(--accent); color: var(--accent); }
.trust-badge.trust-T2 { background: color-mix(in srgb, var(--accent) 8%, transparent); border: 1px solid var(--accent); color: var(--accent); }
.trust-badge.trust-T3 { background: rgba(241,196,92,0.08); border: 1px solid var(--text-alert); color: var(--text-alert); }
.trust-badge.trust-T0 { background: rgba(74,138,84,0.08); border: 1px solid var(--text-muted); color: var(--text-muted); }

.trust-source {
  font-size: 10px;
  line-height: 1.6;
}

.trust-support-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.trust-freshness {
  color: var(--text-alert);
  font-size: 10px;
  letter-spacing: 0.1em;
}

.index-prices {
  gap: 10px;
}

.index-condition {
  padding: 10px 10px 9px;
  border: 1px solid rgba(67, 95, 60, 0.42);
  background: rgba(9, 13, 9, 0.72);
}

.index-condition.is-primary {
  border-color: var(--accent-dim);
  background: rgba(13, 20, 13, 0.82);
}

.index-condition .value {
  font-size: 18px;
}

.summary-card h2,
.collection-card h2,
.stats-card h2,
.editorial-card h2,
.related-card h2,
.contribute-section h3,
.price-history h3,
.related-module h3 {
  margin: 0;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 15px;
  letter-spacing: 0.05em;
  text-transform: none;
}

.summary-card,
.stats-card,
.collection-card,
.editorial-card,
.related-card,
.contribute-section,
.price-history {
  border-color: rgba(67, 95, 60, 0.58);
}

.summary-text {
  font-size: 12px;
  line-height: 1.9;
  color: var(--text-secondary);
  max-width: 78ch;
}

.stats-grid {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

.detail-stats-chip-row {
  margin-top: 12px;
}

.detail-stats-chip-row .surface-chip {
  font-size: 10px;
  line-height: 1.5;
}

.detail-stats-chip-row .surface-chip strong {
  font-weight: normal;
  color: var(--text-primary);
}

.stat-cell {
  border-radius: 0;
  background: var(--bg-surface);
}

.collection-row {
  margin-bottom: 6px;
}

.detail-editorial-tabs {
  display: flex;
  flex-wrap: nowrap;
  gap: 0;
  margin: 10px 0 12px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.42);
  overflow-x: auto;
  white-space: nowrap;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.detail-editorial-tabs::-webkit-scrollbar {
  display: none;
}

.detail-editorial-tab {
  display: inline-flex;
  padding: 9px 14px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
}

.detail-editorial-tab:hover {
  color: var(--text-primary);
  background: var(--bg-card);
}

.detail-editorial-tab.active {
  color: var(--text-alert);
  border-bottom-color: var(--text-alert);
}

.detail-editorial-panel {
  padding-top: 4px;
}

.detail-production-panel,
.detail-domain-block {
  border: 1px solid rgba(67, 95, 60, 0.42);
  background: var(--bg-surface);
}

.detail-production-panel {
  margin-bottom: 14px;
  padding: 14px 16px;
}

.detail-production-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 12px;
}

.detail-domain-eyebrow {
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.detail-domain-subcopy {
  margin-top: 6px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
}

.detail-production-role-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

.detail-production-role-chip,
.detail-compliance-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border: 1px solid rgba(67, 95, 60, 0.42);
  padding: 4px 7px;
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
}

.detail-production-role-chip {
  color: var(--text-alert);
  background: color-mix(in srgb, var(--confidence-mid) 8%, transparent);
}

.detail-production-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.detail-production-block {
  padding: 12px 14px;
}

.detail-production-block-wide {
  margin-top: 10px;
}

.detail-production-block-label,
.detail-domain-heading {
  margin-bottom: 10px;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.detail-production-list,
.detail-media-list,
.detail-ost-release-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.detail-production-item,
.detail-media-row,
.detail-ost-release-row {
  padding-top: 10px;
  border-top: 1px solid rgba(45, 61, 41, 0.42);
}

.detail-production-item:first-child,
.detail-media-row:first-child,
.detail-ost-release-row:first-child {
  padding-top: 0;
  border-top: 0;
}

.detail-production-item-name,
.detail-ost-release-title {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 11px;
}

.detail-production-item-meta,
.detail-media-row-meta,
.detail-ost-release-meta {
  display: block;
  margin-top: 4px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.6;
}

.detail-production-team,
.detail-domain-block + .detail-domain-block {
  margin-top: 10px;
}

.detail-production-team-row {
  display: grid;
  grid-template-columns: 140px minmax(0, 1fr);
  gap: 12px;
  padding-top: 8px;
  border-top: 1px solid rgba(45, 61, 41, 0.42);
}

.detail-production-team-row:first-child {
  padding-top: 0;
  border-top: 0;
}

.detail-domain-block {
  padding: 12px 14px;
}

.detail-domain-subblock {
  margin-top: 12px;
}

.detail-empty-state {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.6;
}

.detail-media-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
}

.detail-media-row-head {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.detail-media-kind {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
}

.detail-media-link {
  margin-top: 6px;
  display: inline-flex;
}

.detail-editorial-head {
  display: grid;
  gap: 0.35rem;
  margin-bottom: 1rem;
}

.detail-overview-cover {
  margin-bottom: 0.9rem;
}

.detail-overview-cover-img {
  width: min(220px, 100%);
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border: 1px solid var(--border);
  background: var(--bg-surface);
}

.detail-overview-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 0.65rem;
  margin-top: 1rem;
}

.detail-overview-fact,
.detail-fact-row,
.detail-record-row,
.detail-media-card {
  border: 1px solid var(--border);
  background: rgba(9, 20, 9, 0.72);
  padding: 0.7rem;
}

.detail-overview-fact-label,
.detail-fact-label,
.detail-record-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-secondary);
  margin-bottom: 0.3rem;
  text-transform: uppercase;
}

.detail-overview-fact-value,
.detail-fact-value,
.detail-record-value {
  color: var(--text-primary);
}

.detail-record-meta {
  display: inline-block;
  margin-left: 0.5rem;
  color: var(--text-secondary);
  font-size: 10px;
}

.detail-fact-list,
.detail-media-gallery {
  display: grid;
  gap: 0.8rem;
}

.detail-media-gallery {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.detail-media-card-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.45rem;
  margin-bottom: 0.6rem;
}

.detail-media-card .detail-media-preview {
  width: 100%;
  max-height: 260px;
  object-fit: contain;
  border: 1px solid var(--border);
  background: var(--bg-card);
}

.detail-media-embed-shell {
  border: 1px solid var(--border);
  background: var(--bg-card);
  margin-bottom: 0.7rem;
}

.detail-media-embed {
  width: 100%;
  min-height: 320px;
  border: 0;
  background: var(--bg-card);
}

@media (max-width: 760px) {
  .detail-media-gallery {
    grid-template-columns: 1fr;
  }

  .detail-media-embed {
    min-height: 240px;
  }
}

.detail-compliance-badge.is-approved {
  color: var(--text-primary);
  border-color: var(--text-secondary);
  background: color-mix(in srgb, var(--accent) 8%, transparent);
}

.detail-compliance-badge.is-review {
  color: var(--text-alert);
  border-color: rgba(241, 196, 92, 0.45);
  background: rgba(241, 196, 92, 0.08);
}

.detail-compliance-badge.is-reference {
  color: var(--status-info);
  border-color: rgba(127, 176, 255, 0.45);
  background: rgba(127, 176, 255, 0.08);
}

.detail-compliance-badge.is-blocked {
  color: var(--status-negative);
  border-color: rgba(255, 123, 123, 0.45);
  background: rgba(255, 123, 123, 0.08);
}

.detail-compliance-badge.is-unknown {
  color: var(--text-muted);
  border-color: rgba(67, 95, 60, 0.42);
  background: var(--bg-surface);
}

.editorial-prose,
.encyclo-text,
.anecdote-text {
  max-width: 80ch;
  font-size: 11px;
  line-height: 1.85;
}

.encyclo-team-row,
.encyclo-cheat-row {
  align-items: start;
  padding: 8px 0;
}

.team-note {
  color: var(--text-secondary);
  font-size: 10px;
  line-height: 1.6;
}

#related-content {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.related-module {
  padding: 14px 16px;
  border: 1px solid rgba(67, 95, 60, 0.42);
  background: rgba(8, 12, 8, 0.72);
}

.related-module:first-child {
  padding-top: 14px;
}

.related-module-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  margin-bottom: 10px;
}

.related-module-copy {
  margin: 4px 0 0;
  font-size: 10px;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

.compare-table {
  width: 100%;
}

.compare-row {
  padding: 10px 0;
  border-bottom: 1px solid rgba(67, 95, 60, 0.42);
}

.compare-row.current {
  background: rgba(10, 18, 10, 0.85);
}

.compare-row.clickable:hover {
  background: rgba(13, 18, 13, 0.88);
}

.compare-score-cell {
  display: flex;
  align-items: center;
}

.similar-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  background: rgba(8, 12, 8, 0.78);
  border-radius: 0;
}

.similar-item-main {
  min-width: 0;
}

.similar-side {
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

.price-history {
  margin-top: 0;
  padding: 18px 20px;
}

.trend-badge {
  border-radius: 0;
  letter-spacing: 0.08em;
}

.trend-badge.up::before {
  content: "\2191 ";
}

.trend-badge.down::before {
  content: "\2193 ";
}

.trend-badge.stable::before {
  content: "= ";
}

.chart-container {
  background: rgba(5, 8, 5, 0.98);
}

.contribute-desc {
  margin: 10px 0 14px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

@media (max-width: 980px) {
  .detail-hero-grid {
    grid-template-columns: 1fr;
  }

  .detail-section-head,
  .related-module-head {
    flex-direction: column;
  }

  .product-universe-head {
    flex-direction: column;
  }
}

@media (max-width: 768px) {
  .game-header-main {
    flex-direction: column;
  }

  .game-cover-slot {
    width: 100%;
    max-width: 220px;
  }

  .game-meta-cluster {
    grid-template-columns: 1fr;
  }

  .index-prices {
    grid-template-columns: 1fr;
  }

  .compare-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }
}

/* ========================================
   GAMES LIST - CATALOG HARMONIZATION
   ======================================== */

.catalog-page {
  width: min(1440px, calc(100% - 40px));
  margin: 0 auto 40px;
}

.catalog-page-head {
  align-items: flex-start;
  padding: 6px 0 18px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.5);
}

.catalog-page-titlezone {
  min-width: 0;
}

.catalog-head-tools {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: min(360px, 100%);
}

.catalog-intro {
  max-width: 60ch;
  margin: 10px 0 0;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.8;
}

.catalog-layout {
  gap: 18px;
}

.catalog-sidebar,
.catalog-detail {
  top: 18px;
}

.catalog-filter-panel {
  padding: 16px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background:
    linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 30%);
}

.catalog-panel-head {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
}

.catalog-panel-copy {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.field-helper {
  margin-top: 6px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.5;
}

.catalog-filter-panel .field label {
  color: var(--text-muted);
}

.catalog-filter-panel .field-query-primary {
  grid-column: 1 / -1;
}

.catalog-filter-panel .field-query-primary label {
  color: var(--text-alert);
  letter-spacing: 0.08em;
}

.catalog-filter-panel .field input,
.catalog-filter-panel .field select {
  border-radius: 0;
  border-color: rgba(67, 95, 60, 0.58);
  background: rgba(8, 12, 8, 0.88);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 11px;
}

.catalog-filter-panel .field-query-primary input {
  min-height: 42px;
  font-size: 14px;
  border-color: var(--text-secondary);
  background: linear-gradient(180deg, var(--bg), var(--bg));
  box-shadow:
    inset 0 0 0 1px color-mix(in srgb, var(--accent) 10%, transparent),
    inset 0 1px 0 color-mix(in srgb, var(--accent) 4%, transparent);
}

.catalog-filter-panel .field-query-primary input::placeholder {
  color: var(--text-secondary);
}

.catalog-filter-panel .field input:focus,
.catalog-filter-panel .field select:focus {
  border-color: var(--text-secondary);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 12%, transparent);
}

.catalog-filter-panel .field-query-primary input:focus {
  border-color: var(--text-secondary);
  box-shadow:
    inset 0 0 0 1px var(--accent-dim),
    inset 0 1px 0 color-mix(in srgb, var(--accent) 4%, transparent);
}

.catalog-advanced-toggle {
  align-self: flex-start;
  padding: 0;
  border: 0;
  background: none;
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  cursor: pointer;
}

.catalog-advanced-toggle:hover {
  color: var(--text-alert);
  text-decoration: underline;
}

.catalog-advanced-filters {
  margin-top: 2px;
}

.catalog-sort-shortcuts {
  display: flex;
  gap: 6px;
  margin-top: 8px;
}

.catalog-search-actions {
  margin-top: 6px;
  align-items: stretch;
}

.catalog-search-actions .btn {
  order: 1;
}

.catalog-search-actions .reset-link {
  order: 2;
  align-self: flex-start;
}

.catalog-results-bar {
  padding: 12px 14px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: var(--bg);
}

.catalog-results-bar .detail-kicker {
  margin-bottom: 6px;
}

.results-summary-line {
  gap: 6px;
}

.summary-pill {
  border-radius: 0;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
}

.results-list {
  border-radius: 0;
  border-color: rgba(67, 95, 60, 0.58);
  background: var(--bg);
}

.result-row.result-row-catalog {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  min-height: 52px;
  height: auto;
  padding: 10px 14px;
}

.result-cover {
  width: 72px;
  height: 96px;
  object-fit: contain;
  image-rendering: auto;
  background: transparent;
  flex-shrink: 0;
}

.result-cover-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 96px;
  border: 1px solid rgba(67, 95, 60, 0.3);
  background: var(--bg-surface);
  font-family: var(--font-display);
  font-size: 1.2rem;
  color: var(--accent-dim);
}

.result-row-indicator {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 11px;
}

.result-row.result-row-catalog .result-info {
  padding: 0;
  min-width: 0;
}

.result-row.result-row-catalog .result-title {
  color: var(--text-primary);
  font-size: 11px;
  letter-spacing: 0.04em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.result-row.result-row-catalog .result-meta {
  margin-top: 3px;
  color: var(--text-muted);
  font-size: 10px;
  line-height: 1.5;
}

.result-meta-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  margin-top: 3px;
}

/* games-list — console link relational */
.game-row-console-link {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px dotted var(--text-muted);
}
.game-row-console-link:hover {
  color: var(--color-accent, #4ade80);
  border-bottom-color: var(--color-accent, #4ade80);
}

.result-presence-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.presence-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 6px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: rgba(8, 12, 8, 0.82);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.presence-badge.is-curated {
  color: var(--text-primary);
  border-color: var(--accent-dim);
}

.presence-badge.is-richness {
  color: var(--text-primary);
  border-color: var(--accent-dim);
}

.presence-badge.is-richness.is-dense {
  color: var(--text-alert);
  border-color: rgba(241, 196, 92, 0.4);
}

.presence-badge.is-state {
  color: var(--text-muted);
}

.result-support-icon {
  flex: 0 0 auto;
  margin: 0;
}

.result-signal {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-content: flex-end;
}

.result-metascore {
  min-width: 24px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
}

.result-metascore-empty {
  color: var(--bg);
  font-family: var(--font-mono);
  font-size: 10px;
}

.result-row.result-row-catalog .result-price {
  min-width: 58px;
  margin: 0;
  font-size: 11px;
  color: var(--text-alert);
}

.result-row.result-row-catalog .result-rarity {
  min-width: 74px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-align: right;
}

.result-row.result-row-catalog:hover,
.result-row.result-row-catalog:focus-visible {
  background: var(--bg);
}

.result-row.result-row-catalog.is-selected {
  border-left: 2px solid var(--accent);
  background: rgba(12, 18, 12, 0.95);
}

.result-row.result-row-catalog.is-selected .result-row-indicator {
  color: var(--accent);
}

.quick-detail-panel {
  min-height: 420px;
  border-radius: 0;
  border-color: rgba(67, 95, 60, 0.58);
  background:
    linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 28%);
}

.detail-link-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 12px;
}

.quick-detail-head {
  margin-bottom: 14px;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 14px;
  letter-spacing: 0.04em;
  text-transform: none;
}

.quick-detail-placeholder,
.quick-detail-loading {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.8;
}

.detail-content {
  gap: 0;
}

.detail-title {
  margin-bottom: 12px;
  color: var(--text-primary);
  font-size: 16px;
  letter-spacing: 0.04em;
}

.detail-badges {
  margin-bottom: 14px;
}

.badge-platform,
.badge-year {
  border-radius: 0;
  border-color: rgba(67, 95, 60, 0.58);
  background: rgba(8, 12, 8, 0.72);
}

.detail-prices {
  border-radius: 0;
  border-color: rgba(67, 95, 60, 0.58);
  background: rgba(8, 12, 8, 0.74);
}

.preview-metascore {
  margin-bottom: 12px;
}

.market-metascore {
  margin: 10px 0 12px;
}

.detail-link {
  display: inline-flex;
  margin-top: 10px;
}

.catalog-page-numbers {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin: 12px 0 4px;
}

.catalog-page-btn,
.catalog-page-ellipsis {
  min-width: 28px;
  padding: 4px 8px;
  font-family: var(--font-mono);
  font-size: 10px;
}

.catalog-page-btn {
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
}

.catalog-page-btn:hover {
  color: var(--text-primary);
  background: var(--bg);
}

.catalog-page-btn.is-active {
  border-color: var(--text-secondary);
  background: rgba(12, 18, 12, 0.94);
  color: var(--text-primary);
}

.catalog-page-ellipsis {
  color: var(--text-muted);
  text-align: center;
}

.catalog-pagination-bar {
  padding-bottom: 6px;
}

@media (max-width: 768px) {
  .catalog-page {
    width: min(100%, calc(100% - 24px));
  }

  .catalog-head-tools {
    width: 100%;
  }

  .result-row.result-row-catalog {
    grid-template-columns: 56px minmax(0, 1fr) auto;
    gap: 8px;
  }
  .result-cover,
  .result-cover-placeholder {
    width: 56px;
    height: 75px;
  }

  .result-signal {
    grid-column: 2;
    justify-content: flex-start;
    gap: 10px;
  }
}

/* ========================================
   ENCYCLOPEDIA - HARMONIZATION
   ======================================== */

.encyclo-shell {
  width: min(1320px, calc(100% - 40px));
  margin: 0 auto 40px;
}

.encyclo-page-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  padding: 6px 0 18px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.5);
  margin-bottom: 16px;
}

.encyclo-head-copy {
  min-width: 0;
}

.encyclo-head-tools {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: min(360px, 100%);
}

.encyclo-intro {
  max-width: 60ch;
  margin: 10px 0 0;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.8;
}

.encyclo-control-bar {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}

.encyclo-context-copy {
  margin-left: 10px;
  color: var(--text-secondary);
}

.encyclo-filters {
  display: flex;
  gap: 0;
  flex-wrap: wrap;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: var(--bg);
}

.encyclo-filters .filter-btn {
  border: 0;
  border-right: 1px solid rgba(67, 95, 60, 0.42);
  background: transparent;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  padding: 9px 14px;
  cursor: pointer;
}

.encyclo-filters .filter-btn:last-child {
  border-right: 0;
}

.encyclo-filters .filter-btn:hover {
  color: var(--text-primary);
  background: var(--bg);
}

.encyclo-filters .filter-btn.active {
  color: var(--text-alert);
  background: rgba(14, 18, 14, 0.95);
}

.encyclo-layout.encyclo-layout-refined {
  display: grid;
  grid-template-columns: minmax(280px, 320px) minmax(0, 1fr);
  gap: 18px;
  border: 0;
  min-height: 680px;
}

.encyclo-index-panel,
.encyclo-reading-shell {
  border: 1px solid rgba(67, 95, 60, 0.58);
  background:
    linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 30%);
}

.encyclo-index-head,
.encyclo-reading-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  padding: 14px 16px 12px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.42);
}

.encyclo-index-copy,
.encyclo-reading-copy {
  max-width: 30ch;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.encyclo-reading-title {
  margin: 2px 0 0;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 15px;
  letter-spacing: 0.04em;
}

.encyclo-list {
  border-right: 0;
  max-height: 76vh;
  padding: 8px 0 10px;
}

.encyclo-list::-webkit-scrollbar,
.encyclo-detail-panel::-webkit-scrollbar {
  width: 9px;
}

.encyclo-list::-webkit-scrollbar-track,
.encyclo-detail-panel::-webkit-scrollbar-track {
  background: rgba(5, 8, 5, 0.98);
}

.encyclo-list::-webkit-scrollbar-thumb,
.encyclo-detail-panel::-webkit-scrollbar-thumb {
  border: 2px solid rgba(5, 8, 5, 0.98);
  background: rgba(80, 111, 74, 0.9);
}

.encyclo-list,
.encyclo-detail-panel {
  scrollbar-color: rgba(80, 111, 74, 0.9) rgba(5, 8, 5, 0.98);
  scrollbar-width: thin;
}

.encyclo-list .section-label {
  padding: 10px 16px 8px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
}

.encyclo-franchises-heading[hidden] {
  display: none;
}

.encyclo-list-row {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 9px 16px;
  border: 0;
  border-left: 2px solid transparent;
  border-bottom: 1px solid rgba(45, 61, 41, 0.42);
  background: transparent;
  cursor: pointer;
  text-align: left;
}

.encyclo-list-row:hover {
  background: var(--bg);
}

.encyclo-list-row.active {
  border-left-color: var(--accent);
  background: rgba(12, 18, 12, 0.95);
}

.encyclo-list-row.is-franchise .encyclo-row-title {
  color: var(--text-alert);
}

.encyclo-row-title {
  margin: 0;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
}

.encyclo-row-meta {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.5;
}

.encyclo-row-summary {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.encyclo-row-badges,
.encyclo-row-signals {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.encyclo-badge {
  border-radius: 0;
  padding: 2px 5px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.encyclo-badge-franchise {
  border-color: color-mix(in srgb, var(--confidence-mid) 8%, transparent);
  color: var(--text-alert);
}

.encyclo-reading-shell {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.encyclo-detail-panel {
  flex: 1;
  padding: 18px 20px;
  max-height: 76vh;
}

.encyclo-placeholder,
.encyclo-loading,
.encyclo-empty {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.8;
  text-align: left;
}

.encyclo-placeholder {
  padding: 8px 0;
}

.encyclo-panel-header {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.42);
}

.encyclo-panel-cover {
  width: 96px;
  flex-shrink: 0;
}

.encyclo-panel-cover img,
.encyclo-cover-placeholder {
  width: 96px;
  height: 96px;
}

.encyclo-panel-cover img {
  display: block;
  border: 1px solid rgba(67, 95, 60, 0.62);
  object-fit: cover;
  background: rgba(5, 8, 5, 0.98);
}

.encyclo-panel-cover svg {
  display: block;
  max-width: 100%;
  height: auto;
}

.encyclo-cover-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(67, 95, 60, 0.62);
  background:
    linear-gradient(180deg, rgba(5, 8, 5, 0.98), rgba(9, 12, 9, 0.98)),
    radial-gradient(circle at center, color-mix(in srgb, var(--accent) 6%, transparent), transparent 52%);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 26px;
  letter-spacing: 0.1em;
}

.encyclo-cover-caption {
  margin-top: 8px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.encyclo-panel-info {
  min-width: 0;
}

.encyclo-panel-header.is-console {
  align-items: flex-start;
}

.encyclo-panel-cover--console {
  width: 184px;
  flex: 0 0 184px;
  height: 176px;
  overflow: visible;
}

.encyclo-panel-cover--console svg {
  width: 156px;
  margin: 4px auto 0;
}

.encyclo-panel-info--console {
  flex: 1 1 auto;
  min-width: 0;
}

.encyclo-panel-title {
  margin-bottom: 6px;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 26px;
  line-height: 1.08;
  letter-spacing: 0.05em;
}

.encyclo-panel-meta {
  margin-bottom: 10px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
}

.encyclo-panel-signals {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.encyclo-panel-rarity,
.encyclo-panel-signal {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.encyclo-panel-tagline {
  max-width: 70ch;
  margin-bottom: 10px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.8;
  font-style: italic;
}

.encyclo-panel-link {
  display: inline-flex;
}

.encyclo-reading-transition {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  padding: 0 0 12px;
  margin-bottom: 4px;
}

.encyclo-reading-transition-copy {
  max-width: 42ch;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.encyclo-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  margin-bottom: 16px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.42);
}

.encyclo-tab {
  padding: 9px 14px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  cursor: pointer;
}

.encyclo-tab:hover {
  color: var(--text-primary);
  background: var(--bg-card);
}

.encyclo-tab.active {
  color: var(--text-alert);
  border-bottom-color: var(--text-alert);
}

.encyclo-tab-content {
  padding-top: 2px;
}

.encyclo-synopsis-text,
.encyclo-anecdote-text,
.timeline-desc {
  max-width: 80ch;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.9;
}

.encyclo-synopsis-text.is-secondary {
  margin-top: 14px;
  color: var(--text-secondary);
}

.encyclo-team-row,
.timeline-row,
.encyclo-code-block,
.encyclo-anecdote-block {
  padding: 10px 0;
  border-top: 1px solid rgba(45, 61, 41, 0.42);
}

.encyclo-team-row:first-child,
.timeline-row:first-child,
.encyclo-code-block:first-child,
.encyclo-anecdote-block:first-child {
  padding-top: 0;
  border-top: 0;
}

.encyclo-team-row {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 8px 14px;
  align-items: start;
}

.team-role,
.encyclo-code-label,
.timeline-year {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.team-name,
.timeline-title,
.encyclo-code-value,
.encyclo-anecdote-title {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 11px;
}

.team-note,
.encyclo-code-effect {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.encyclo-code-value {
  margin-top: 6px;
  color: var(--text-alert);
  font-size: 13px;
  letter-spacing: 0.08em;
}

.timeline-row {
  display: grid;
  grid-template-columns: 84px minmax(0, 160px) minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}

@media (max-width: 980px) {
  .encyclo-page-head,
  .encyclo-index-head,
  .encyclo-reading-head,
  .encyclo-reading-transition {
    flex-direction: column;
  }

  .encyclo-layout.encyclo-layout-refined {
    grid-template-columns: 1fr;
  }

  .encyclo-list,
  .encyclo-detail-panel {
    max-height: none;
  }
}

@media (max-width: 768px) {
  .encyclo-shell {
    width: min(100%, calc(100% - 24px));
  }

  .encyclo-team-row,
  .timeline-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .encyclo-panel-header {
    flex-direction: column;
  }
}

/* ========================================
   CONSOLES - HARMONIZATION
   ======================================== */

.console-shell {
  width: min(1280px, calc(100% - 40px));
  margin: 0 auto 40px;
}

.console-page-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  padding: 6px 0 18px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.5);
  margin-bottom: 16px;
}

.console-head-copy {
  min-width: 0;
}

.console-head-tools {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: min(360px, 100%);
}

.console-intro {
  max-width: 60ch;
  margin: 10px 0 0;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.8;
}

.console-layout {
  display: grid;
  grid-template-columns: minmax(280px, 340px) minmax(0, 1fr);
  gap: 18px;
}

.console-index-panel,
.console-reading-shell {
  border: 1px solid rgba(67, 95, 60, 0.58);
  background:
    linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 30%);
}

.console-index-head,
.console-reading-head,
.console-section-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
}

.console-index-head,
.console-reading-head {
  padding: 14px 16px 12px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.42);
}

.console-index-copy,
.console-reading-copy,
.console-section-copy {
  max-width: 30ch;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.console-reading-title,
.console-section-title {
  margin: 2px 0 0;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 15px;
  letter-spacing: 0.04em;
}

.console-index-list {
  max-height: 76vh;
  overflow-y: auto;
  scrollbar-color: rgba(80, 111, 74, 0.9) rgba(5, 8, 5, 0.98);
  scrollbar-width: thin;
}

.console-index-list::-webkit-scrollbar,
.console-detail-panel::-webkit-scrollbar {
  width: 9px;
}

.console-index-list::-webkit-scrollbar-track,
.console-detail-panel::-webkit-scrollbar-track {
  background: rgba(5, 8, 5, 0.98);
}

.console-index-list::-webkit-scrollbar-thumb,
.console-detail-panel::-webkit-scrollbar-thumb {
  border: 2px solid rgba(5, 8, 5, 0.98);
  background: rgba(80, 111, 74, 0.9);
}

.console-row {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 10px 16px;
  border: 0;
  border-left: 2px solid transparent;
  border-bottom: 1px solid rgba(45, 61, 41, 0.42);
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.console-row:hover {
  background: var(--bg);
}

.console-row.active {
  border-left-color: var(--accent);
  background: rgba(12, 18, 12, 0.95);
}

.console-row-title {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
}

.console-row-meta {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.5;
}

.console-row-signal,
.console-detail-badge,
.console-accessory-type {
  display: inline-flex;
  align-items: center;
  padding: 2px 6px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.console-reading-shell {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.console-detail-panel {
  flex: 1;
  max-height: 76vh;
  overflow-y: auto;
  padding: 18px 20px;
}

.console-detail-empty {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.8;
}

.console-detail-hero {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  padding-bottom: 16px;
  margin-bottom: 16px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.42);
}

.console-detail-visuals {
  width: 256px;
  flex-shrink: 0;
  display: grid;
  gap: 12px;
}

.console-detail-slot {
  width: 96px;
  flex-shrink: 0;
}

.console-detail-placeholder {
  width: 96px;
  height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(67, 95, 60, 0.62);
  background:
    linear-gradient(180deg, rgba(5, 8, 5, 0.98), rgba(9, 12, 9, 0.98)),
    radial-gradient(circle at center, color-mix(in srgb, var(--accent) 6%, transparent), transparent 52%);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 26px;
  letter-spacing: 0.1em;
}

.console-detail-slot-caption {
  margin-top: 8px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.console-detail-copy {
  min-width: 0;
}

.console-detail-title {
  margin-bottom: 6px;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 26px;
  line-height: 1.08;
  letter-spacing: 0.05em;
}

.console-detail-meta {
  margin-bottom: 10px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
}

.console-detail-signals,
.console-detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.console-detail-actions {
  margin-top: 10px;
}

.console-detail-page-root,
.console-detail-page-shell {
  width: min(1180px, calc(100vw - 40px));
  margin: 24px auto 40px;
}

.console-detail-panel-shell {
  min-height: 480px;
}

.console-market-quick-grid {
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.console-accordion-stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.console-section {
  padding-top: 16px;
  border-top: 1px solid rgba(45, 61, 41, 0.42);
}

.console-section + .console-section {
  margin-top: 16px;
}

.console-games-list,
.console-accessory-list {
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.console-game-row,
.console-accessory-row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid rgba(67, 95, 60, 0.42);
  background: rgba(8, 12, 8, 0.78);
  text-decoration: none;
}

.console-game-row:hover,
.console-inline-link:hover {
  border-color: var(--accent-dim);
}

.console-game-title,
.console-inline-link {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 11px;
  text-decoration: none;
}

.console-game-meta {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  text-align: right;
}

@media (max-width: 980px) {
  .console-page-head,
  .console-index-head,
  .console-reading-head,
  .console-section-head {
    flex-direction: column;
  }

  .console-layout {
    grid-template-columns: 1fr;
  }

  .console-index-list,
  .console-detail-panel {
    max-height: none;
  }

  .console-market-quick-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .console-shell {
    width: min(100%, calc(100% - 24px));
  }

  .console-detail-hero,
  .console-game-row,
  .console-accessory-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .console-game-meta {
    text-align: left;
  }

  .console-market-quick-grid {
    grid-template-columns: 1fr;
  }
}

/* ========================================
   STATS - HARMONIZATION
   ======================================== */

.stats-shell.stats-shell-refined {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto 40px;
  gap: 18px;
}

.stats-page-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  padding: 6px 0 18px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.5);
}

.stats-head-copy {
  min-width: 0;
}

.stats-head-tools {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: min(340px, 100%);
}

.stats-intro {
  max-width: 60ch;
  margin: 10px 0 0;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.8;
}

.stats-panel {
  border: 1px solid rgba(67, 95, 60, 0.58);
  background:
    linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 30%);
  padding: 18px 20px;
}

.stats-panel + .stats-panel {
  margin-top: 0;
}

.stats-section-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  margin-bottom: 16px;
}

.stats-section-title {
  margin: 2px 0 0;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 16px;
  letter-spacing: 0.04em;
}

.stats-section-copy {
  max-width: 34ch;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.stats-cards {
  gap: 10px;
  margin-bottom: 16px;
}

.stats-cards-primary {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.stats-cards-secondary {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.stats-card {
  border-radius: 0;
  border: 1px solid rgba(67, 95, 60, 0.48);
  background: rgba(8, 12, 8, 0.78);
  padding: 13px 14px;
}

.stats-card-label,
.subsection-title {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.stats-card-value {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 28px;
  line-height: 1.1;
}

.stats-card-sub,
.section-note {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.stats-subsection + .stats-subsection {
  margin-top: 18px;
}

.rarity-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.rarity-item {
  padding: 12px 12px 10px;
  background: rgba(8, 12, 8, 0.74);
}

.rarity-name,
.rarity-pct,
.platform-name,
.platform-count,
.game-spot-meta {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
}

.rarity-count {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 22px;
}

.platform-bars {
  display: grid;
  gap: 8px;
}

.platform-row {
  grid-template-columns: 180px minmax(0, 1fr) 56px;
  gap: 12px;
  padding: 8px 0;
  border-top: 1px solid rgba(45, 61, 41, 0.42);
}

.platform-row:first-child {
  border-top: 0;
  padding-top: 0;
}

.platform-ascii {
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  white-space: nowrap;
}

.market-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.game-spot {
  border-radius: 0;
  border: 1px solid rgba(67, 95, 60, 0.48);
  background: rgba(8, 12, 8, 0.78);
  padding: 14px;
}

.game-spot:hover,
.encyclopedia-link:hover {
  border-color: var(--accent-dim);
  background: var(--bg);
}

.game-spot-title {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 13px;
}

.game-spot-price {
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 11px;
}

.encyclopedia-link {
  display: inline-flex;
}

.stats-error {
  border: 1px solid var(--confidence-low);
  background: rgba(224, 82, 82, 0.08);
  color: var(--confidence-low);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.7;
  padding: 12px 14px;
}

@media (max-width: 980px) {
  .stats-page-head,
  .stats-section-head {
    flex-direction: column;
  }

  .rarity-grid,
  .stats-cards-primary,
  .stats-cards-secondary,
  .market-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .platform-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }
}

@media (max-width: 768px) {
  .stats-shell.stats-shell-refined {
    width: min(100%, calc(100% - 24px));
  }

  .rarity-grid,
  .stats-cards-primary,
  .stats-cards-secondary,
  .market-grid {
    grid-template-columns: 1fr;
  }
}

/* ========================================
   FINAL NAVIGATION FREEZE + OUTLIER PAGES
   ======================================== */

.global-product-nav {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto 16px;
  padding: 10px 12px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background:
    linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 32%);
  display: flex;
  flex-wrap: wrap;
  gap: 10px 12px;
  align-items: center;
  justify-content: space-between;
}

.global-product-home {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid rgba(67, 95, 60, 0.48);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
}

.global-product-home:hover,
.global-product-home.is-active {
  border-color: var(--accent-dim);
  color: var(--text-primary);
  background: color-mix(in srgb, var(--accent) 6%, transparent);
}

.global-product-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.global-product-link {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 34px;
  min-width: 150px;
  padding: 7px 10px;
  border: 1px solid rgba(45, 61, 41, 0.56);
  text-decoration: none;
  background: var(--bg-surface);
}

.global-product-link:hover {
  border-color: var(--accent-dim);
  background: var(--bg);
}

.global-product-link.is-active {
  border-color: var(--accent-dim);
  background: color-mix(in srgb, var(--accent) 8%, transparent);
}

.global-product-link .nav-label {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.global-product-link .nav-copy {
  margin-top: 2px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.global-product-link.is-market .nav-label {
  color: var(--text-alert);
}

.secondary-page-shell {
  width: min(var(--content-max, 1180px), calc(100% - var(--content-gutter, 24px) * 2));
  margin: 0 auto 40px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.secondary-page-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  padding: 4px 0 18px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.5);
}

.secondary-page-titlezone {
  min-width: 0;
}

.secondary-page-kicker {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.secondary-page-intro {
  max-width: 64ch;
  margin: 10px 0 0;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.8;
}

.page-status-line {
  width: min(340px, 100%);
  padding: 10px 12px;
  border: 1px solid rgba(45, 61, 41, 0.56);
  background: var(--bg-surface);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.page-status-line strong {
  color: var(--text-primary);
  font-weight: normal;
}

.page-status-line.is-wide {
  width: 100%;
  margin-bottom: 12px;
}

.secondary-grid {
  display: grid;
  gap: 16px;
}

.secondary-grid-two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.secondary-panel {
  border: 1px solid rgba(67, 95, 60, 0.58);
  background:
    linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 32%);
  padding: 18px 20px;
}

.secondary-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 14px;
}

.secondary-panel-kicker {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.secondary-panel-title {
  margin: 2px 0 0;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 16px;
  letter-spacing: 0.04em;
}

.secondary-panel-copy {
  max-width: 38ch;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.page-copy-stack {
  display: grid;
  gap: 10px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.9;
}

.outlier-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.outlier-stat {
  padding: 12px 13px;
  border: 1px solid rgba(45, 61, 41, 0.56);
  background: rgba(8, 12, 8, 0.78);
}

.outlier-stat-value {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 24px;
  line-height: 1.1;
}

.outlier-stat-label {
  margin-top: 4px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.stack-grid-clean {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.stack-item-clean {
  padding: 12px 13px;
  border: 1px solid rgba(45, 61, 41, 0.56);
  background: rgba(8, 12, 8, 0.78);
}

.stack-item-clean .role {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.stack-item-clean .tech {
  margin-top: 5px;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.7;
}

.secondary-link-list {
  display: grid;
  gap: 8px;
}

.secondary-link-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  padding: 12px 14px;
  border: 1px solid rgba(45, 61, 41, 0.56);
  background: rgba(8, 12, 8, 0.78);
  text-decoration: none;
}

.secondary-link-row:hover {
  border-color: var(--accent-dim);
  background: var(--bg);
}

.secondary-link-main {
  min-width: 0;
}

.secondary-link-title {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
}

.secondary-link-copy {
  margin-top: 4px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.secondary-link-meta {
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.product-universe-frame.is-shell {
  border-top-color: var(--text-secondary);
}

.product-universe-frame.is-utility {
  border-top-color: rgba(88, 112, 98, 0.62);
}

.product-universe-chip.is-utility {
  color: var(--text-muted);
  border-color: rgba(88, 112, 98, 0.48);
  background: rgba(88, 112, 98, 0.08);
}

.accessories-shell-refined {
  padding: 18px 20px;
}

.accessories-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.accessories-filter {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.accessories-filter label {
  color: var(--text-muted);
}

.accessories-filter select,
.utility-input {
  min-width: 180px;
  padding: 8px 10px;
  border: 1px solid rgba(45, 61, 41, 0.56);
  background: rgba(8, 12, 8, 0.86);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 11px;
  outline: none;
}

.accessories-filter select:focus,
.utility-input:focus {
  border-color: var(--accent-dim);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent) 10%, transparent);
}

.accessories-list {
  display: grid;
  gap: 8px;
}

.accessory-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid rgba(45, 61, 41, 0.56);
  background: rgba(8, 12, 8, 0.78);
}

.accessory-main {
  min-width: 0;
}

.accessory-title {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 12px;
}

.accessory-meta {
  margin-top: 4px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.accessory-type-chip {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border: 1px solid rgba(67, 95, 60, 0.52);
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.empty-state.outlier-empty {
  max-width: none;
  margin: 0;
  padding: 16px;
  border: 1px dashed rgba(67, 95, 60, 0.52);
  background: rgba(8, 12, 8, 0.68);
  color: var(--text-secondary);
  text-align: left;
}

.shell-actions,
.random-card-shell .actions,
.home-shell .actions,
.debug-shell .card-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.panel-action-strip {
  margin-bottom: 12px;
}

.shell-primary-link,
.shell-secondary-link,
.home-shell .button-link,
.debug-shell .card-button,
.debug-shell .back-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid rgba(45, 61, 41, 0.56);
  background: rgba(8, 12, 8, 0.78);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-decoration: none;
  cursor: pointer;
}

.shell-primary-link,
.home-shell .button-link.is-primary {
  border-color: var(--accent-dim);
  color: var(--text-primary);
  background: color-mix(in srgb, var(--accent) 8%, transparent);
}

.shell-primary-link:hover,
.shell-secondary-link:hover,
.home-shell .button-link:hover,
.debug-shell .card-button:hover,
.debug-shell .back-link:hover {
  border-color: var(--accent-dim);
  color: var(--text-primary);
}

.home-shell .status {
  min-height: 20px;
  color: var(--text-primary);
}

.home-shell .meta,
.debug-shell .meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.home-shell .meta > div,
.debug-shell .meta > div {
  padding: 10px 12px;
  border: 1px solid rgba(45, 61, 41, 0.56);
  background: rgba(8, 12, 8, 0.78);
}

.sample-list-clean {
  padding-left: 18px;
  display: grid;
  gap: 6px;
}

.sample-list-clean li {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11px;
}

.sample-list-clean a {
  color: var(--text-alert);
  text-decoration: none;
}

.sample-list-clean a:hover {
  text-decoration: underline;
}

.random-card-shell {
  min-height: 72px;
  padding: 14px;
  border: 1px solid rgba(45, 61, 41, 0.56);
  background: rgba(8, 12, 8, 0.78);
}

.random-card-shell h3 {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 14px;
  margin-bottom: 8px;
}

.random-card-shell .meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.random-card-shell .meta > div {
  padding: 10px 12px;
  border: 1px solid rgba(45, 61, 41, 0.56);
  background: rgba(8, 12, 8, 0.68);
}

.random-card-shell .muted,
.home-shell .muted,
.debug-shell .muted {
  color: var(--text-secondary);
}

.utility-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.utility-field {
  flex: 1 1 220px;
  min-width: 0;
}

.utility-field label {
  display: block;
  margin-bottom: 6px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.utility-grid {
  display: grid;
  gap: 12px;
}

.debug-shell .status {
  min-height: 20px;
  color: var(--text-primary);
}

.debug-shell .card {
  padding: 14px;
  border: 1px solid rgba(45, 61, 41, 0.56);
  background: rgba(8, 12, 8, 0.78);
}

.debug-shell .summary {
  margin-top: 10px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.8;
}

.debug-shell .prices {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.debug-shell .price-card {
  padding: 10px;
  border: 1px solid rgba(45, 61, 41, 0.56);
  background: rgba(8, 12, 8, 0.68);
}

.debug-shell .detail-stack {
  display: grid;
  gap: 12px;
}

.debug-shell .detail-section {
  border-top: 1px solid rgba(45, 61, 41, 0.56);
  padding-top: 10px;
}

.debug-shell .detail-section strong {
  display: block;
  margin-bottom: 8px;
}

.completion-shell .completion-card {
  display: grid;
  gap: 12px;
}

.completion-card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.completion-table {
  display: grid;
  gap: 6px;
}

.completion-row {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) repeat(3, minmax(0, 1fr));
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid rgba(45, 61, 41, 0.42);
  background: rgba(8, 12, 8, 0.62);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.6;
}

.completion-row.is-head {
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.completion-family-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.6;
}

.completion-family-metrics > div,
.completion-card-footer {
  padding: 8px 10px;
  border: 1px solid rgba(45, 61, 41, 0.42);
  background: rgba(8, 12, 8, 0.62);
}

.completion-status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 4px 8px;
  border: 1px solid rgba(67, 95, 60, 0.52);
  background: rgba(8, 12, 8, 0.82);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.completion-status-badge.is-strong {
  color: var(--terminal-accent);
}

.completion-status-badge.is-close {
  color: var(--nav-label);
}

.completion-status-badge.is-weak {
  color: var(--confidence-mid);
}

.completion-status-badge.is-blocked-by-source {
  color: var(--status-negative);
}

.debug-shell pre {
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.8;
}

@media (max-width: 980px) {
  .secondary-page-head,
  .secondary-panel-head {
    flex-direction: column;
  }

  .secondary-grid-two,
  .outlier-stats-grid,
  .stack-grid-clean,
  .home-shell .meta,
  .debug-shell .meta,
  .random-card-shell .meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .completion-family-metrics,
  .completion-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .accessory-row {
    grid-template-columns: 1fr;
    align-items: flex-start;
  }

  .debug-shell .prices {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 780px) {
  .global-product-nav,
  .secondary-page-shell {
    width: min(100%, calc(100% - 24px));
  }

  .global-product-nav {
    justify-content: flex-start;
  }

  .global-product-home,
  .global-product-link {
    width: 100%;
  }

  .global-product-links {
    width: 100%;
  }

  .outlier-stats-grid,
  .stack-grid-clean,
  .secondary-grid-two,
  .home-shell .meta,
  .debug-shell .meta,
  .random-card-shell .meta {
    grid-template-columns: 1fr;
  }

  .completion-family-metrics,
  .completion-row {
    grid-template-columns: 1fr;
  }
}

/* ========================================
   TYPOGRAPHY SYSTEM - BIGBLUETERMINAL / DEPARTUREMONO
   ======================================== */

body,
p,
li,
input,
select,
textarea,
button,
label,
small,
code,
pre,
table,
th,
td {
  font-family: var(--font-ui);
}

.wordmark,
.page-title,
.page-title-display,
.hub-page-title,
.hub-universe-title,
.product-universe-title,
.universe-hero {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: 0.08em;
}

.page-title {
  font-weight: 400;
}

.page-subtitle,
.detail-kicker,
.secondary-page-kicker,
.secondary-panel-kicker,
.terminal-query-label,
.terminal-summary-label,
.terminal-preview-label,
.breadcrumb,
.product-universe-copy,
.product-universe-overlap {
  font-family: var(--font-ui);
}

.detail-shell .hero-title,
.detail-shell .hero-title.page-title,
.debug-shell h1,
.debug-shell h2,
.debug-shell .page-title,
.debug-shell .product-universe-title,
.debug-shell .secondary-panel-title {
  font-family: var(--font-ui);
  letter-spacing: 0.02em;
  line-height: 1.18;
}

/* ========================================
   FINAL SURFACE POLISH
   ======================================== */

html {
  scrollbar-gutter: stable both-edges;
}

body,
.franchise-list,
.franchises-detail,
.encyclo-list,
.encyclo-detail-panel,
.console-index-list,
.console-detail-panel {
  scrollbar-color: rgba(80, 111, 74, 0.92) rgba(5, 8, 5, 0.98);
  scrollbar-width: thin;
}

body::-webkit-scrollbar,
.franchise-list::-webkit-scrollbar,
.franchises-detail::-webkit-scrollbar,
.encyclo-list::-webkit-scrollbar,
.encyclo-detail-panel::-webkit-scrollbar,
.console-index-list::-webkit-scrollbar,
.console-detail-panel::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

body::-webkit-scrollbar-track,
.franchise-list::-webkit-scrollbar-track,
.franchises-detail::-webkit-scrollbar-track,
.encyclo-list::-webkit-scrollbar-track,
.encyclo-detail-panel::-webkit-scrollbar-track,
.console-index-list::-webkit-scrollbar-track,
.console-detail-panel::-webkit-scrollbar-track {
  background: rgba(5, 8, 5, 0.98);
}

body::-webkit-scrollbar-thumb,
.franchise-list::-webkit-scrollbar-thumb,
.franchises-detail::-webkit-scrollbar-thumb,
.encyclo-list::-webkit-scrollbar-thumb,
.encyclo-detail-panel::-webkit-scrollbar-thumb,
.console-index-list::-webkit-scrollbar-thumb,
.console-detail-panel::-webkit-scrollbar-thumb {
  border: 2px solid rgba(5, 8, 5, 0.98);
  background: linear-gradient(180deg, rgba(96, 132, 88, 0.96), rgba(56, 78, 52, 0.96));
}

.global-product-home,
.global-product-link,
.terminal-filter-btn,
.terminal-action-link,
.terminal-inline-btn,
.hub-search-button,
.hub-inline-link,
.hub-action-inline,
.page-nav-inline a,
.product-universe-links a,
.franchise-search-link,
.franchise-action-link,
.console-inline-link,
.console-game-row,
.franchise-game-row,
.coll-pill,
.btn,
#collection-button,
#contrib-submit,
.chart-btn,
.period-btn,
.detail-editorial-tab,
.franchise-detail-tab,
.encyclo-tab {
  transition:
    color 140ms ease,
    background-color 140ms ease,
    border-color 140ms ease,
    box-shadow 140ms ease;
}

.global-product-home:hover,
.global-product-link:hover,
.global-product-home:focus-visible,
.global-product-link:focus-visible {
  border-color: var(--accent-dim);
  background: var(--bg);
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--accent) 6%, transparent);
}

.global-product-link.is-active {
  border-color: var(--accent-dim);
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--accent) 4%, transparent);
}

.global-product-home:focus-visible,
.global-product-link:focus-visible,
.terminal-filter-btn:focus-visible,
.hub-search-button:focus-visible,
.terminal-action-link:focus-visible,
.terminal-inline-btn:focus-visible,
.hub-inline-link:focus-visible,
.hub-action-inline:focus-visible,
.page-nav-inline a:focus-visible,
.product-universe-links a:focus-visible,
.franchise-search-link:focus-visible,
.franchise-action-link:focus-visible,
.console-inline-link:focus-visible,
.console-game-row:focus-visible,
.franchise-game-row:focus-visible,
.coll-pill:focus-visible,
.btn:focus-visible,
#collection-button:focus-visible,
#contrib-submit:focus-visible,
.chart-btn:focus-visible,
.period-btn:focus-visible,
.detail-editorial-tab:focus-visible,
.franchise-detail-tab:focus-visible,
.encyclo-tab:focus-visible,
.hub-search-input:focus-visible,
.terminal-query-input:focus-visible,
.franchises-search-input:focus-visible,
#global-search:focus-visible,
#type-filter:focus-visible,
.collection-condition-select:focus-visible,
.collection-note-input:focus-visible,
.contribute-form select:focus-visible,
.contribute-form input:focus-visible,
.contribute-form textarea:focus-visible {
  outline: 1px solid var(--text-secondary);
  outline-offset: 2px;
}

.terminal-query-line,
.terminal-filter-group,
.terminal-summary-bar,
.terminal-preview-panel,
.terminal-status-line,
.hub-search-form,
.franchises-search-shell,
.global-search-bar,
.accessories-filter {
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--accent) 4%, transparent);
}

.terminal-query-line {
  background: linear-gradient(180deg, rgba(8, 12, 8, 0.97), rgba(5, 8, 5, 0.97));
  transition: border-color 140ms ease, box-shadow 140ms ease, background-color 140ms ease;
}

.terminal-query-line:focus-within,
.franchises-search-shell:focus-within,
.global-search-bar:focus-within,
.accessories-filter:focus-within,
.hub-search-form:focus-within {
  border-color: var(--text-secondary);
  box-shadow:
    inset 0 0 0 1px color-mix(in srgb, var(--accent) 15%, transparent),
    inset 0 1px 0 color-mix(in srgb, var(--accent) 4%, transparent);
}

.terminal-query-input::placeholder,
.hub-search-input::placeholder,
.franchises-search-input::placeholder,
.collection-note-input::placeholder,
.contribute-form input::placeholder,
.contribute-form textarea::placeholder {
  color: rgba(110, 141, 103, 0.86);
}

.terminal-query-count {
  min-width: 88px;
  text-align: right;
}

.market-search-shell {
  border-color: var(--text-secondary);
  background: linear-gradient(180deg, var(--bg), var(--bg));
  box-shadow:
    inset 0 0 0 1px color-mix(in srgb, var(--accent) 10%, transparent),
    inset 0 1px 0 color-mix(in srgb, var(--accent) 4%, transparent);
}

.market-search-shell .terminal-query-label {
  color: var(--text-alert);
  letter-spacing: 0.16em;
}

.market-search-shell .terminal-query-input {
  font-size: 15px;
  color: var(--text-primary);
}

.market-search-shell .terminal-query-input::placeholder {
  color: var(--text-secondary);
}

.market-search-shell .terminal-query-count {
  min-width: 118px;
  color: var(--text-alert);
  font-size: 11px;
}

.market-search-helper {
  margin: 8px 0 12px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.04em;
}

.terminal-filter-group {
  background: var(--bg);
}

.terminal-filter-btn {
  min-height: 30px;
}

.terminal-filter-btn:hover {
  color: var(--text-primary);
  background: var(--bg);
}

.terminal-filter-btn.active {
  color: var(--text-primary);
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 8%, transparent), var(--bg));
  box-shadow: inset 0 -1px 0 var(--accent-dim);
}

.terminal-filter-btn:disabled {
  cursor: default;
  opacity: 0.42;
  background: transparent;
}

.terminal-summary-bar {
  background: linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98));
}

.terminal-summary-cell {
  padding: 10px 14px 12px;
}

.terminal-summary-value {
  line-height: 1.15;
}

.terminal-status-line {
  min-height: 31px;
  display: flex;
  align-items: center;
  background: rgba(7, 10, 7, 0.9);
}

.terminal-preview-panel {
  background: linear-gradient(180deg, rgba(9, 13, 9, 0.98), var(--bg));
  min-height: 78px;
}

.terminal-preview-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin-top: 6px;
}

.market-preview-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}

.market-preview-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid rgba(45, 61, 41, 0.82);
  background: rgba(0, 0, 0, 0.22);
}

.market-preview-stat.is-empty {
  grid-column: 1 / -1;
}

.market-preview-stat-label {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.market-preview-stat-value {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 12px;
}

.market-preview-inline-score {
  display: inline-flex;
  align-items: center;
}

#market-preview-links {
  margin-top: 10px;
  gap: 12px 18px;
}

@media (max-width: 920px) {
  .market-preview-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .market-preview-stats {
    grid-template-columns: 1fr;
  }
}

.terminal-row {
  position: relative;
  border-left: 1px solid rgba(45, 61, 41, 0.62);
  background: rgba(7, 10, 7, 0.88);
  transition: background-color 140ms ease, border-color 140ms ease, box-shadow 140ms ease, color 140ms ease;
}

.terminal-row:hover {
  background: linear-gradient(90deg, color-mix(in srgb, var(--accent) 6%, transparent), var(--bg) 66%);
}

.terminal-row.selected {
  border-left-color: var(--accent);
  background: linear-gradient(90deg, color-mix(in srgb, var(--accent) 8%, transparent), var(--bg) 70%);
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--accent) 6%, transparent);
}

.terminal-row.selected .terminal-row-indicator {
  color: var(--text-alert);
}

.terminal-row.selected .result-title {
  color: var(--text-primary);
}

.franchise-list-item,
.encyclo-list-row,
.console-row {
  transition: background-color 140ms ease, border-color 140ms ease, box-shadow 140ms ease, color 140ms ease;
}

.franchise-list-item:hover,
.franchise-list-item:focus-visible,
.encyclo-list-row:hover,
.encyclo-list-row:focus-visible,
.console-row:hover,
.console-row:focus-visible {
  background: linear-gradient(90deg, color-mix(in srgb, var(--accent) 6%, transparent), var(--bg) 72%);
}

.franchise-list-item.selected,
.encyclo-list-row.active,
.console-row.active {
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--accent) 6%, transparent);
}

.hub-universe-card,
.hub-intent-card,
.hub-module,
.product-universe-frame,
.stats-panel,
.summary-card,
.collection-card,
.editorial-card,
.related-card,
.contribute-section,
.price-history {
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--accent) 4%, transparent);
}

.hub-universe-card,
.hub-intent-card,
.legendary-card,
.hub-encyclo-card,
.game-spot {
  transition:
    border-color 140ms ease,
    background-color 140ms ease,
    box-shadow 140ms ease;
}

.hub-universe-card:hover,
.hub-universe-card:focus-within,
.hub-intent-card:hover,
.hub-intent-card:focus-within {
  border-color: var(--accent-dim);
  box-shadow:
    inset 0 1px 0 color-mix(in srgb, var(--accent) 6%, transparent),
    0 0 0 1px color-mix(in srgb, var(--accent) 8%, transparent);
}

.legendary-card:hover,
.legendary-card:focus-within,
.hub-encyclo-card:hover,
.hub-encyclo-card:focus-within,
.game-spot:hover,
.game-spot:focus-visible {
  border-color: var(--accent-dim);
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--accent) 6%, transparent);
}

.hub-system-row:last-child {
  border-bottom: 0;
}

.hub-intent-links a {
  color: var(--text-alert);
  text-decoration: none;
  transition: color 140ms ease, text-decoration-color 140ms ease;
}

.hub-intent-links a:hover,
.hub-intent-links a:focus-visible {
  color: var(--text-alert);
}

.hub-search-form:hover {
  border-color: rgba(96, 130, 88, 0.82);
}

.hub-search-button:hover,
.hub-search-button:focus-visible {
  background: rgba(19, 24, 19, 0.98);
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--accent) 6%, transparent);
}

.product-universe-links a,
.page-nav-inline a,
.terminal-action-link,
.hub-inline-link,
.hub-action-inline,
.franchise-search-link,
.franchise-action-link,
.console-inline-link,
.console-game-row,
.franchise-game-row,
.coll-pill {
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

.product-universe-links a.is-active {
  color: var(--text-alert);
  text-shadow: 0 0 10px color-mix(in srgb, var(--confidence-mid) 8%, transparent);
}

.chart-btn:hover,
.period-btn:hover,
.detail-editorial-tab:hover,
.franchise-detail-tab:hover,
.encyclo-tab:hover {
  color: var(--text-primary);
  background: var(--bg-surface);
}

.chart-btn.active,
.period-btn.active,
.detail-editorial-tab.active,
.franchise-detail-tab.active,
.encyclo-tab.active {
  background: linear-gradient(180deg, color-mix(in srgb, var(--confidence-mid) 8%, transparent), var(--bg));
  box-shadow: inset 0 -1px 0 color-mix(in srgb, var(--confidence-mid) 8%, transparent);
}

.collection-form {
  gap: 10px;
  margin-top: 8px;
}

.collection-controls {
  gap: 10px;
}

.collection-current-meta {
  gap: 8px;
}

.status-text {
  min-height: 18px;
  line-height: 1.6;
}

.collection-state {
  min-height: 0;
}

.collection-current-meta:empty,
.collection-state:empty,
.status-text:empty {
  display: none;
}

.collection-condition-select,
.collection-note-input,
.contribute-form select,
.contribute-form input,
.contribute-form textarea,
#type-filter {
  transition:
    border-color 140ms ease,
    background-color 140ms ease,
    box-shadow 140ms ease,
    color 140ms ease;
}

.collection-condition-select:focus,
.collection-note-input:focus,
.contribute-form select:focus,
.contribute-form input:focus,
.contribute-form textarea:focus,
#type-filter:focus {
  outline: none;
  border-color: var(--text-secondary);
  background: var(--bg);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 12%, transparent);
}

.btn:hover,
#collection-button:hover,
#contrib-submit:hover {
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--accent) 6%, transparent);
}

.btn:disabled,
#collection-button:disabled,
#contrib-submit:disabled {
  cursor: not-allowed;
  opacity: 0.45;
  box-shadow: none;
}

.stats-card {
  min-height: 110px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  justify-content: space-between;
}

.section-note {
  margin-top: 8px;
  padding-top: 10px;
  border-top: 1px solid rgba(67, 95, 60, 0.48);
}

.terminal-empty-state,
.search-empty,
.franchise-list-empty,
.franchise-detail-empty,
.encyclo-placeholder,
.encyclo-loading,
.encyclo-empty,
.console-detail-empty,
.index-insufficient,
.stats-error {
  border: 1px dashed rgba(67, 95, 60, 0.58);
  background: rgba(8, 12, 8, 0.68);
}

.terminal-empty-state {
  display: grid;
  gap: 4px;
  padding: 14px 16px;
}

.terminal-empty-title {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.terminal-empty-copy {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.8;
}

.terminal-quiet-note {
  padding: 10px 14px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.8;
  text-align: center;
}

.search-empty,
.franchise-list-empty,
.encyclo-placeholder,
.encyclo-loading,
.encyclo-empty,
.console-detail-empty,
.index-insufficient,
.stats-error {
  padding: 14px 16px;
  color: var(--text-secondary);
  line-height: 1.8;
}

.franchise-detail-empty {
  padding: 18px 20px;
}

@media (max-width: 900px) {
  .terminal-summary-bar {
    flex-wrap: wrap;
    border-bottom: 1px solid var(--border);
  }

  .terminal-summary-cell {
    min-width: 50%;
    border-bottom: 1px solid rgba(45, 61, 41, 0.52);
  }

  .terminal-summary-cell:nth-child(2n) {
    border-right: 0;
  }
}

/* ========================================
   GAME DETAIL - STATE COMPARISON
======================================== */

.price-history .chart-toggle,
.price-history .period-selector {
  align-items: center;
}

.compare-history-chart {
  overflow: hidden;
  min-height: 214px;
}

.compare-history-chart #price-chart {
  height: 180px;
}

.history-legend-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.history-legend-btn.is-disabled {
  opacity: 0.42;
  cursor: default;
}

.history-legend-swatch {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--state-color, var(--text-primary));
  box-shadow: 0 0 0 1px rgba(8, 12, 8, 0.96);
  flex: 0 0 9px;
}

.price-history-note {
  min-height: 20px;
  margin-top: 10px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.price-history-tooltip {
  position: absolute;
  z-index: 2;
  min-width: 150px;
  max-width: 220px;
  padding: 9px 10px;
  border: 1px solid var(--accent-dim);
  background: rgba(8, 12, 8, 0.98);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.6;
  pointer-events: none;
  transform: translate(-50%, calc(-100% - 10px));
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.28);
}

.price-history-tooltip-title {
  margin-bottom: 4px;
  color: var(--text-alert);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.price-history-tooltip-copy {
  color: var(--text-secondary);
}

.trend-badge.is-muted {
  border-color: rgba(65, 91, 58, 0.66);
  color: var(--text-muted);
}

.price-history .price-stats-row.history-state-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.history-state-card {
  padding: 12px;
  border: 1px solid rgba(56, 79, 51, 0.7);
  background: rgba(8, 12, 8, 0.78);
}

.history-state-card.is-visible {
  border-color: var(--accent-dim);
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--accent) 6%, transparent);
}

.history-state-card.is-muted {
  background: rgba(7, 10, 7, 0.66);
}

.history-state-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  margin-bottom: 10px;
}

.history-state-name {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.history-state-status {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.history-state-metric-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 12px;
}

.history-state-metric {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.history-state-metric-wide {
  grid-column: 1 / -1;
}

.history-state-note {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.6;
}

.history-state-footer {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid rgba(48, 68, 44, 0.62);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.6;
}

.history-variation.is-up {
  color: var(--text-primary);
}

.history-variation.is-down {
  color: var(--confidence-low);
}

.history-variation.is-neutral {
  color: var(--text-muted);
}

.price-history .detail-section-head.compact {
  align-items: flex-start;
  margin-bottom: 12px;
}

.price-history-copy {
  margin-top: 6px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.6;
  max-width: 72ch;
}

.price-history .trend-row {
  gap: 10px;
  margin-bottom: 12px;
}

.price-history .chart-toggle,
.price-history .period-selector {
  padding: 8px 10px;
  border: 1px solid rgba(56, 79, 51, 0.7);
  background: rgba(7, 10, 7, 0.88);
}

.price-history .chart-btn,
.price-history .period-btn {
  min-width: 56px;
  min-height: 28px;
  border-radius: 0;
  border: 1px solid rgba(56, 79, 51, 0.7);
  background: var(--bg);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.price-history .chart-btn.active,
.price-history .period-btn.active {
  color: var(--text-alert);
  border-color: color-mix(in srgb, var(--confidence-mid) 8%, transparent);
}

.price-history .chart-container {
  min-height: 212px;
  padding: 12px 12px 6px;
  border: 1px solid rgba(56, 79, 51, 0.7);
  background:
    linear-gradient(180deg, rgba(8, 12, 8, 0.98), var(--bg)),
    linear-gradient(90deg, color-mix(in srgb, var(--accent) 4%, transparent), transparent 30%);
}

.price-history .price-stats-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.price-history .price-stat {
  min-height: 82px;
  padding: 10px 12px;
  border: 1px solid rgba(56, 79, 51, 0.7);
  background: rgba(7, 10, 7, 0.88);
}

.price-history .price-stat .stat-label {
  display: block;
  margin-bottom: 8px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.price-history .price-stat .stat-value {
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 18px;
}

.price-history-point {
  cursor: pointer;
}

.price-history-point:hover,
.price-history-point:focus {
  stroke: rgba(241, 196, 92, 0.9);
  stroke-width: 2.4;
  outline: none;
}

@media (max-width: 900px) {
  .price-history .price-stats-row.history-state-grid {
    grid-template-columns: 1fr;
  }
}

.collection-state-block {
  flex: 1 1 260px;
  min-width: 240px;
}

.collection-action-group,
.collection-edit-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.collection-form textarea.collection-note-input {
  min-height: 70px;
  resize: vertical;
}

.collection-edit-form {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(67, 95, 60, 0.58);
}

.btn-danger {
  border-color: rgba(232, 85, 85, 0.42);
  color: var(--status-negative);
}

.btn-danger:hover {
  border-color: rgba(232, 85, 85, 0.72);
  background: rgba(232, 85, 85, 0.08);
}

.result-owned-badge {
  display: inline-flex;
  align-items: center;
  margin-left: 8px;
  padding: 2px 6px;
  border: 1px solid var(--accent-dim);
  color: var(--text-primary);
  background: color-mix(in srgb, var(--accent) 8%, transparent);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  vertical-align: middle;
}

.result-collection-badge {
  display: inline-block;
  font-size: 10px;
  font-family: var(--font-ui);
  padding: 1px 4px;
  margin-left: 6px;
  vertical-align: middle;
  letter-spacing: 0.06em;
  border: 1px solid currentColor;
  border-radius: 0;
  text-transform: uppercase;
  font-weight: normal;
}
.result-collection-badge.is-wanted {
  color: var(--text-secondary);
  border-color: var(--text-secondary);
}
.result-collection-badge.is-sale {
  color: var(--text-alert);
  border-color: var(--text-alert);
}

.collection-toolbar {
  margin-top: 0;
}

.collection-toolbar-group {
  gap: 8px;
  flex-wrap: wrap;
}

.collection-toolbar-input,
.collection-toolbar-select {
  min-height: 30px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: rgba(9, 13, 9, 0.96);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 6px 8px;
}

.collection-toolbar-input {
  min-width: 220px;
}

.result-row.result-row-catalog .result-title {
  white-space: normal;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  line-height: 1.35;
}

.legendary-card-media {
  width: 100%;
  height: 112px;
  overflow: hidden;
  background: var(--bg-surface);
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 12%, transparent);
}

.legendary-card-media img,
.legendary-card-media canvas {
  width: 100%;
  height: 100%;
  display: block;
}

.legendary-card-media img {
  object-fit: cover;
  image-rendering: pixelated;
}

.hub-encyclo-card-media {
  width: 100%;
  aspect-ratio: 16 / 9;
  margin-bottom: 8px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--accent) 12%, transparent);
  background: var(--bg-surface);
}

.hub-encyclo-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  image-rendering: pixelated;
}

.console-detail-slot--hardware {
  width: 100%;
  align-items: center;
  justify-items: center;
  min-height: 272px;
  overflow: hidden;
}

.console-detail-slot--hardware svg {
  width: min(100%, 288px);
  height: auto;
  display: block;
}

.console-overview-copy {
  color: var(--terminal-green-soft);
  font-size: 15px;
  line-height: 1.7;
}

.console-media-card {
  border: 1px solid rgba(0, 255, 102, 0.12);
  background: rgba(5, 12, 5, 0.92);
  padding: 12px;
  display: grid;
  gap: 10px;
}

.console-media-asset {
  width: 72px;
  height: 72px;
}

.console-media-asset svg {
  width: 100%;
  height: 100%;
  display: block;
}

.console-encyclopedia-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin: 18px 0 0;
}

.console-encyclopedia-block {
  border: 1px solid var(--terminal-border);
  background: rgba(5, 12, 5, 0.92);
}

.console-encyclopedia-block summary {
  list-style: none;
  cursor: pointer;
  padding: 14px 16px;
  display: grid;
  gap: 4px;
}

.console-encyclopedia-block summary::-webkit-details-marker {
  display: none;
}

.console-encyclopedia-block[open] summary {
  border-bottom: 1px solid rgba(0, 255, 102, 0.12);
}

.console-encyclopedia-title {
  color: var(--terminal-green-bright);
  font-size: 20px;
  letter-spacing: 0.04em;
}

.console-encyclopedia-body {
  padding: 14px 16px 18px;
}

.console-copy-stack {
  display: grid;
  gap: 10px;
}

.console-copy-stack p {
  margin: 0;
  color: var(--terminal-green-soft);
  line-height: 1.7;
}

.console-copy-stack strong {
  color: var(--terminal-green-bright);
}

.console-team-list {
  display: grid;
  gap: 12px;
}

.console-team-card,
.console-spec-card {
  border: 1px solid rgba(0, 255, 102, 0.12);
  background: rgba(3, 10, 3, 0.96);
  padding: 12px;
}

.console-team-name,
.console-subsection-label {
  color: var(--terminal-green-bright);
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.console-team-role {
  color: var(--terminal-green-mid);
  margin-top: 4px;
  font-size: 12px;
}

.console-team-card p {
  margin: 8px 0 0;
  color: var(--terminal-green-soft);
  line-height: 1.6;
}

.console-spec-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.console-spec-card {
  display: grid;
  gap: 6px;
}

.console-spec-card span {
  color: var(--terminal-green-mid);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.console-spec-card strong {
  color: var(--terminal-green-bright);
  line-height: 1.5;
}

.console-bullet-list {
  margin: 0;
  padding-left: 18px;
  color: var(--terminal-green-soft);
  display: grid;
  gap: 8px;
  line-height: 1.6;
}

.console-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.console-chip-link {
  display: inline-grid;
  gap: 2px;
  padding: 10px 12px;
  border: 1px solid rgba(0, 255, 102, 0.16);
  background: rgba(5, 15, 5, 0.96);
  color: var(--terminal-green-bright);
  text-decoration: none;
  min-width: 148px;
}

.console-chip-link[data-console-jump] {
  font: inherit;
  cursor: pointer;
  text-align: left;
}

.console-chip-link small {
  color: var(--terminal-green-mid);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.console-chip-link.is-static {
  cursor: default;
}

.console-section-footnote {
  margin-top: 12px;
  color: var(--terminal-green-mid);
  font-size: 12px;
}

.console-demo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
}

.console-demo-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px 12px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: rgba(8, 12, 8, 0.82);
  color: inherit;
  text-decoration: none;
}

.console-demo-card:hover,
.console-demo-card:focus-visible {
  background: var(--bg);
  border-color: var(--accent-dim);
}

.console-demo-title {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.4;
}

.console-demo-meta {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
}

.console-demo-signal-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.console-demo-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 6px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: rgba(5, 15, 5, 0.96);
  color: var(--terminal-green-mid);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.console-game-head {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.console-game-media {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.console-game-media svg {
  width: 24px;
  height: 24px;
  display: block;
}

.encyclo-mode-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

@media (max-width: 980px) {
  .console-encyclopedia-grid,
  .console-spec-grid {
    grid-template-columns: 1fr;
  }

  .console-detail-visuals {
    width: 100%;
  }

  .console-detail-slot--hardware {
    min-height: 220px;
  }
}

/* Masquer les blocs d'orientation sur les pages internes */
.product-universe-frame {
  display: none;
}

/* Les reafficher uniquement sur hub.html */
body.hub-page .product-universe-frame {
  display: block;
}

/* ========================================
   SC-6 - RM-1 visual standard
======================================== */

.surface-query-shell {
  border-color: var(--text-secondary);
  background: linear-gradient(180deg, var(--bg), var(--bg));
  box-shadow:
    inset 0 0 0 1px color-mix(in srgb, var(--accent) 10%, transparent),
    inset 0 1px 0 color-mix(in srgb, var(--accent) 4%, transparent);
}

.surface-query-shell .terminal-query-label,
.surface-query-shell input::placeholder {
  color: var(--text-secondary);
}

.surface-query-shell .terminal-query-input,
.surface-query-shell input {
  font-size: 15px;
  color: var(--text-primary);
}

.surface-query-shell .terminal-query-count {
  min-width: 118px;
  color: var(--text-alert);
  font-size: 11px;
}

.surface-query-helper {
  margin: 8px 0 12px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.6;
}

.surface-preview-panel {
  border-color: rgba(67, 95, 60, 0.58);
  background:
    linear-gradient(180deg, rgba(9, 13, 9, 0.98), var(--bg)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 4%, transparent), transparent 28%);
}

.surface-summary-copy {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.surface-signal-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.surface-signal-grid.is-compact {
  gap: 8px;
}

.surface-signal-card {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: rgba(8, 12, 8, 0.78);
}

.surface-signal-card.is-wide {
  grid-column: span 2;
}

.surface-signal-card--action {
  border-color: var(--text-muted);
}
.surface-signal-card--action.is-hot {
  border-color: var(--text-alert);
  background: rgba(255, 204, 0, 0.06);
}
.surface-signal-card--action.is-primary {
  border-color: var(--accent);
  background: rgba(0, 255, 102, 0.06);
}
.surface-signal-action-value {
  font-size: 11px;
  font-weight: bold;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.surface-signal-card--action.is-hot .surface-signal-action-value {
  color: var(--text-alert);
}
.surface-signal-card--action.is-primary .surface-signal-action-value {
  color: var(--accent);
}

.surface-signal-label {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.surface-signal-value {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.4;
}

.surface-signal-value.is-alert {
  color: var(--text-alert);
}

.surface-signal-value.is-muted {
  color: var(--text-secondary);
}

.surface-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.surface-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  color: var(--text-secondary);
  background: rgba(8, 12, 8, 0.78);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.surface-chip.is-hot {
  color: var(--text-alert);
  border-color: color-mix(in srgb, var(--confidence-mid) 8%, transparent);
}

.surface-chip.is-primary {
  color: var(--text-primary);
  border-color: var(--accent-dim);
}

.surface-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-top: 12px;
}

.surface-action-row a,
.surface-action-row button {
  color: var(--text-alert);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-decoration: none;
}

.surface-action-row a:hover,
.surface-action-row button:hover {
  color: var(--text-alert);
  text-decoration: underline;
}

.surface-action-row.is-inline {
  margin-top: 8px;
}

.surface-identity-meta {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.search-surface-copy,
.encyclo-search-helper {
  margin-top: 8px;
}

.sc-row {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 8%, transparent);
  text-decoration: none;
  color: inherit;
  font-family: var(--font-mono);
  background: rgba(7, 10, 7, 0.88);
}

.sc-row:hover {
  background: linear-gradient(90deg, color-mix(in srgb, var(--accent) 6%, transparent), var(--bg) 66%);
}

.sc-row .asset-support {
  margin: 2px 0 0;
}

.sc-main {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.sc-identity {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.sc-subline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.sc-title {
  color: var(--text-primary);
  font-size: 13px;
  line-height: 1.4;
}

.sc-sub {
  color: var(--text-secondary);
  font-size: 10px;
  line-height: 1.6;
  min-width: 0;
}

.sc-support-icon {
  flex: 0 0 auto;
  margin: 0;
}

.sc-secondary {
  color: var(--text-muted);
  font-size: 10px;
  line-height: 1.6;
}

.sc-summary {
  color: var(--text-secondary);
  font-size: 10px;
  line-height: 1.7;
}

.sc-signal-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  min-width: 0;
}

.sc-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.sc-chip {
  display: inline-flex;
  align-items: center;
  padding: 3px 7px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  color: var(--text-secondary);
  background: rgba(8, 12, 8, 0.78);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.sc-chip.is-primary {
  color: var(--text-primary);
  border-color: var(--accent-dim);
}

.sc-chip.is-hot {
  color: var(--text-alert);
  border-color: color-mix(in srgb, var(--confidence-mid) 8%, transparent);
}

.sc-chip.is-richness.is-dense {
  color: var(--text-alert);
  border-color: color-mix(in srgb, var(--confidence-mid) 8%, transparent);
}

.sc-chip.is-richness.is-solid {
  color: var(--text-primary);
  border-color: var(--accent-dim);
}

.sc-chip.is-richness.is-growing {
  color: var(--confidence-mid);
  border-color: rgba(224, 179, 82, 0.42);
}

.sc-chip.is-richness.is-light,
.sc-chip.is-completion,
.sc-chip.is-confidence {
  color: var(--text-secondary);
}

.sc-reading-note {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.6;
}

.pass1-surface-banner {
  margin: 10px 0 0;
  padding: 8px 10px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: rgba(8, 12, 8, 0.82);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.sc-action {
  align-self: center;
  color: var(--text-alert);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.detail-market-price-grid {
  margin-top: 12px;
}

.detail-market-summary-grid {
  margin-top: 12px;
}

.detail-market-summary-grid .surface-signal-card {
  min-height: 78px;
}

.detail-market-summary-grid .surface-signal-value {
  font-size: 12px;
  line-height: 1.5;
}

.detail-market-actions {
  margin-top: 10px;
}

.detail-identity-signal-grid {
  margin-top: 12px;
}

.detail-identity-signal-grid .surface-signal-card {
  min-height: 72px;
}

.detail-hero-actions {
  margin-top: 12px;
}

.detail-market-panel .surface-chip-row {
  margin-top: 12px;
}

.preview-metascore .metascore-block,
.market-metascore .metascore-block {
  margin-bottom: 0;
}

.quick-detail-panel .surface-signal-grid,
.terminal-preview-panel .surface-signal-grid,
.encyclo-panel-info .surface-signal-grid {
  margin-top: 12px;
}

.quick-detail-panel .surface-chip-row,
.terminal-preview-panel .surface-chip-row,
.encyclo-panel-info .surface-chip-row {
  margin-top: 12px;
}

.market-preview-stats.surface-signal-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.surface-signal-grid.is-five {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.collection-toolbar.surface-query-shell {
  margin-top: 0;
  padding: 10px 12px;
}

.collection-preview-summary {
  margin-top: 12px;
}

.collection-preview-summary:empty {
  display: none;
}

.collection-row-main {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.detail-empty-inline { color: var(--text-muted); font-style: italic; font-size: 0.72rem; font-family: var(--font-mono); }
.collection-cell-console { color: var(--text-muted); font-size: 10px; }
.collection-cell-condition { font-size: 10px; border: 1px solid var(--border); padding: 1px 4px; text-align: center; }
.collection-cell-price { text-align: right; color: var(--text-muted); }
.collection-cell-price.is-alert { color: var(--text-alert); }

.collection-row-title {
  color: var(--text-primary);
  line-height: 1.25;
}

.collection-row-cue {
  color: var(--text-muted);
  font-size: 10px;
  line-height: 1.25;
}

.collection-row-cue.is-hot {
  color: var(--text-alert);
}

.collection-row-cue.is-primary {
  color: var(--text-primary);
}

.collection-row-status {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.collection-status-chip {
  font-size: 10px;
  line-height: 1.4;
}

.franchises-search-helper,
.hub-search-helper,
.console-head-tools .surface-query-helper {
  margin-top: 10px;
}

.franchise-overview-grid {
  margin-top: 12px;
}

.franchise-game-main {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.rm1-franchise-game-row {
  align-items: center;
}

.console-detail-signals.surface-signal-grid {
  margin-top: 12px;
}

.console-detail-actions.surface-action-row {
  margin-top: 12px;
}

.hub-search-form.surface-query-shell {
  margin-bottom: 0;
}

.hub-empty-state,
.coll-items .terminal-empty-state {
  width: 100%;
  min-height: 96px;
}

.result-archive-row {
  margin-top: 8px;
}

.detail-reading-chip-row,
.hub-rich-chip-row {
  margin-top: 8px;
}

.detail-reading-note {
  margin: 8px 0 0;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.detail-reading-state {
  margin-top: 12px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.7;
}

.detail-hero-price-context {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0 0 12px;
}

.detail-price-context-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.detail-decision-strip {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(45, 61, 41, 0.42);
}

.detail-decision-grid {
  margin-top: 8px;
}

.detail-decision-grid .surface-signal-card {
  min-height: 48px;
  overflow: hidden;
}
.detail-decision-grid .surface-signal-value {
  font-size: 10px;
  line-height: 1.3;
  word-break: break-word;
  overflow-wrap: break-word;
}
.detail-decision-grid .surface-signal-action-value {
  font-size: 10px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.hub-rich-card {
  min-height: 0;
}

.encyclo-list-row .asset-support {
  margin-right: 8px;
}

.encyclo-list-row-head {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.encyclo-panel-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
}

.search-empty.is-error .terminal-empty-title {
  color: var(--text-danger);
}

.search-count-label {
  font-size: 10px;
  color: var(--text-muted);
  letter-spacing: 0.16em;
  margin: 10px 0 4px;
  font-family: var(--font-mono);
  text-transform: uppercase;
}

@media (max-width: 1040px) {
  .sc-row {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .sc-signal-grid,
  .sc-action {
    grid-column: 2;
  }

  .surface-signal-grid,
  .market-preview-stats.surface-signal-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .search-ctx-tabs {
    flex-wrap: wrap;
  }

  .ctx-tab {
    flex: 1 1 auto;
    padding: 6px 12px;
  }

  .sc-row {
    grid-template-columns: auto minmax(0, 1fr);
    gap: 10px;
  }

  .sc-action {
    white-space: normal;
    justify-self: start;
  }

  .surface-query-shell .terminal-query-count {
    min-width: 0;
  }

  .sc-signal-grid,
  .surface-signal-grid,
  .market-preview-stats.surface-signal-grid {
    grid-template-columns: 1fr;
  }

  .surface-signal-card.is-wide {
    grid-column: auto;
  }

  .encyclo-list-row-head {
    align-items: flex-start;
  }

  .encyclo-panel-links {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .encyclo-row-summary,
  .terminal-empty-copy {
    line-height: 1.6;
  }

  .collection-toolbar.surface-query-shell {
    padding: 10px;
  }

  .collection-toolbar-group {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  .collection-toolbar-input,
  .collection-toolbar-select {
    width: 100%;
    min-width: 0;
  }

  .surface-action-row {
    flex-direction: column;
    align-items: stretch;
  }

  .surface-action-row a,
  .surface-action-row button {
    width: 100%;
  }

  .hub-universe-actions,
  .hub-system-actions {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .hub-module-link,
  .hub-inline-link,
  .hub-action-inline {
    white-space: normal;
  }
}

/* ============================================
   ARCHIVE RETRODEX — Onglets LORE/PERSO/OST
   ============================================ */

.archive-panel {
  padding: 1.5rem 0;
}

/* LORE section */
.archive-lore {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  line-height: 1.8;
  color: var(--text-muted);
  border-left: 2px solid var(--accent);
  padding-left: 1rem;
  margin-bottom: 1rem;
  letter-spacing: 0.02em;
}

.archive-gameplay {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.75rem;
  padding: 0.75rem;
  background: color-mix(in srgb, var(--accent) 6%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 15%, transparent);
}

.archive-label {
  font-family: var(--font-display);
  font-size: 0.72rem;
  color: var(--text-primary);
  letter-spacing: 0.1em;
  display: block;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
}

/* PERSO section */
.archive-character-row {
  display: grid;
  grid-template-columns: 1fr 80px 2fr;
  gap: 1rem;
  padding: 0.6rem 0;
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 8%, transparent);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  align-items: start;
}

.archive-character-row:last-child {
  border-bottom: none;
}

.archive-char-name {
  color: var(--accent);
  font-weight: bold;
  letter-spacing: 0.05em;
}

.archive-char-role {
  color: var(--text-primary);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding-top: 0.1rem;
}

.archive-char-desc {
  color: var(--text-muted);
  line-height: 1.6;
}

/* OST section */
.archive-ost-composers {
  margin-bottom: 1rem;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-muted);
}

.archive-ost-tracks ul {
  list-style: none;
  padding: 0;
  margin: 0.5rem 0;
}

.archive-ost-tracks ul li {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
  padding: 0.3rem 0;
  padding-left: 1rem;
  border-left: 1px solid var(--accent-dim);
  margin-bottom: 0.25rem;
  transition: border-color 0.2s, color 0.2s;
}

.archive-ost-tracks ul li:hover {
  color: var(--text-primary);
  border-left-color: var(--text-primary);
}

.archive-duration {
  margin-top: 0.75rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
  padding: 0.5rem 0.75rem;
  background: color-mix(in srgb, var(--accent) 4%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 10%, transparent);
  display: inline-block;
}

.archive-speedrun {
  margin-top: 0.5rem;
  font-family: var(--font-display);
  font-size: 0.72rem;
  color: var(--text-alert);
  letter-spacing: 0.05em;
  padding: 0.4rem 0.75rem;
  border: 1px solid rgba(241, 196, 92, 0.2);
  background: rgba(241, 196, 92, 0.03);
  display: inline-block;
}

/* NOTICE section */
.archive-manual {
  padding: 1rem;
  border: 1px solid var(--accent-dim);
  background: color-mix(in srgb, var(--accent) 4%, transparent);
}

.archive-manual-note {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-disabled);
  margin-top: 0.5rem;
  font-style: italic;
}

@media (max-width: 980px) {
  .detail-production-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .detail-production-head {
    flex-direction: column;
  }

  .detail-production-role-row {
    justify-content: flex-start;
  }

  .detail-production-team-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}

/* Archive section header */
.archive-r?trodex-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.sc-result-cover {
  width: 80px;
  height: 80px;
  min-width: 80px;
  object-fit: cover;
  border: 1px solid var(--accent-dim);
  flex-shrink: 0;
  image-rendering: auto;
}

.sc-result-cover-placeholder {
  width: 80px;
  height: 80px;
  min-width: 80px;
  background: color-mix(in srgb, var(--accent) 8%, transparent);
  border: 1px solid var(--accent-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 0.9rem;
  color: var(--text-primary);
  flex-shrink: 0;
}

.detail-section-separator {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.5rem 0 0.5rem 0;
  border-top: 1px solid color-mix(in srgb, var(--accent) 12%, transparent);
  margin-top: 1rem;
}

.detail-section-label {
  font-family: var(--font-display);
  font-size: 0.72rem;
  color: var(--text-primary);
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.detail-section-hint {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-disabled);
  letter-spacing: 0.04em;
}

.market-detail-shell {
  padding-bottom: 3rem;
}

.market-hero-card {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.market-empty-card {
  padding: 1rem;
  border: 1px solid color-mix(in srgb, var(--accent) 15%, transparent);
  background: color-mix(in srgb, var(--accent) 4%, transparent);
}

.market-empty-title {
  font-family: var(--font-display);
  font-size: 0.72rem;
  color: var(--text-primary);
  letter-spacing: 0.08em;
}

.market-empty-copy {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: var(--text-muted);
}

.market-search-header {
  margin-top: 0.25rem;
}

.market-search-results {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.market-search-row {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 90px 90px 90px 90px 80px;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  border: 1px solid color-mix(in srgb, var(--accent) 10%, transparent);
  background: color-mix(in srgb, var(--accent) 4%, transparent);
  color: inherit;
  text-align: left;
}

.market-search-row:hover,
.market-search-row.is-selected {
  border-color: var(--accent-dim);
  background: color-mix(in srgb, var(--accent) 6%, transparent);
}

.market-result-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.market-result-title {
  font-family: var(--font-display);
  font-size: 11px;
  color: var(--text-primary);
  line-height: 1.5;
}

.market-result-meta,
.market-result-year {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
}

.market-result-link {
  width: fit-content;
}

.market-signal-chip-row {
  margin-top: 4px;
}

.market-result-price {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-secondary);
  text-align: right;
}

.market-result-price.is-alert {
  color: var(--text-alert);
}

.market-result-score {
  display: flex;
  justify-content: center;
}

.market-hero-summary {
  display: flex;
  flex-direction: column;
}

.market-hero-layout {
  display: grid;
  grid-template-columns: 144px minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
}

.market-cover-slot {
  width: 144px;
  min-width: 144px;
  height: 144px;
}

.market-cover {
  width: 144px;
  height: 144px;
  object-fit: cover;
  border: 1px solid var(--accent-dim);
  display: block;
}

.market-cover-placeholder {
  width: 144px;
  height: 144px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--accent-dim);
  background: color-mix(in srgb, var(--accent) 4%, transparent);
  font-family: var(--font-display);
  font-size: 1rem;
  color: var(--text-primary);
}

.market-hero-copy {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.market-hero-title {
  margin: 0;
}

.market-hero-chips {
  gap: 0.45rem;
}

.market-hero-copy-note {
  margin: 0;
}

.market-reading-note {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.6;
}

.market-score-chip {
  display: inline-flex;
  align-items: center;
}

.market-price-summary {
  margin-top: 0.1rem;
}

.market-hero-actions {
  padding-top: 0.15rem;
}

.market-trend-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-mono);
  font-size: 11px;
  white-space: nowrap;
}

.market-trend-badge.is-up {
  color: var(--status-negative);
}

.market-trend-badge.is-down {
  color: var(--text-alert);
}

.market-trend-badge.is-stable {
  color: var(--text-primary);
}

.market-trend-symbol {
  font-family: var(--font-display);
  font-size: 10px;
}

.market-trend-delta {
  color: var(--text-muted);
}

.market-graph-list,
.market-condition-table,
.market-buy-list {
  display: flex;
  flex-direction: column;
  margin-top: 1rem;
}

.market-graph-row {
  display: grid;
  grid-template-columns: 90px 70px 1fr 90px;
  gap: 0.75rem;
  align-items: center;
  padding: 0.45rem 0;
  border-top: 1px solid color-mix(in srgb, var(--accent) 8%, transparent);
}

.market-graph-date,
.market-graph-condition,
.market-graph-price {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
}

.market-graph-price {
  color: var(--text-muted);
  text-align: right;
}

.market-graph-bar {
  display: block;
  height: 8px;
  border: 1px solid color-mix(in srgb, var(--accent) 12%, transparent);
  background: color-mix(in srgb, var(--accent) 4%, transparent);
}

.market-graph-fill {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--text-secondary), rgba(241, 196, 92, 0.75));
}

.market-condition-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.75rem;
  padding: 0.55rem 0;
  border-top: 1px solid color-mix(in srgb, var(--accent) 8%, transparent);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: var(--text-muted);
}

.market-condition-header {
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.market-compare-search {
  margin-bottom: 0.75rem;
}

.market-compare-results {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-bottom: 0.9rem;
}

.market-compare-result {
  width: 100%;
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.55rem 0.75rem;
  border: 1px solid color-mix(in srgb, var(--accent) 10%, transparent);
  background: color-mix(in srgb, var(--accent) 4%, transparent);
  color: inherit;
  text-align: left;
  font-family: var(--font-mono);
  font-size: 0.74rem;
}

.market-compare-result:hover {
  border-color: var(--accent-dim);
}

.market-compare-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin-bottom: 0.9rem;
}

.market-compare-card {
  padding: 0.8rem;
  border: 1px solid color-mix(in srgb, var(--accent) 12%, transparent);
  background: color-mix(in srgb, var(--accent) 4%, transparent);
}

.market-compare-card-title {
  font-family: var(--font-display);
  font-size: 0.72rem;
  color: var(--text-primary);
  line-height: 1.6;
}

.market-compare-card-meta {
  margin-top: 0.35rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
}

.market-compare-table {
  display: flex;
  flex-direction: column;
}

.market-compare-row {
  display: grid;
  grid-template-columns: 150px 1fr 1fr;
  gap: 0.75rem;
  padding: 0.55rem 0;
  border-top: 1px solid color-mix(in srgb, var(--accent) 8%, transparent);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: var(--text-muted);
}

.market-compare-header {
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.market-buy-row {
  display: grid;
  grid-template-columns: 1fr 90px 80px 100px;
  gap: 0.75rem;
  padding: 0.55rem 0;
  border-top: 1px solid color-mix(in srgb, var(--accent) 8%, transparent);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: var(--text-muted);
}

.market-buy-price {
  color: var(--text-alert);
  text-align: right;
}

.market-buy-status {
  color: var(--text-primary);
  text-align: right;
}

.market-meta-fallback {
  font-family: var(--font-display);
  font-size: 0.72rem;
  color: var(--text-primary);
}

@media (max-width: 960px) {
  .market-hero-layout {
    grid-template-columns: 1fr;
  }

  .market-cover-slot,
  .market-cover,
  .market-cover-placeholder {
    width: 112px;
    min-width: 112px;
    height: 112px;
  }

  .market-search-header {
    display: none;
  }

  .market-search-row,
  .market-graph-row,
  .market-condition-row,
  .market-compare-row,
  .market-buy-row {
    grid-template-columns: 1fr;
  }

  .market-result-price,
  .market-buy-price,
  .market-buy-status,
  .market-result-score {
    text-align: left;
    justify-content: flex-start;
  }

.market-compare-grid {
  grid-template-columns: 1fr;
  }
}

.result-row.game-card,
.result-row.result-row-catalog.game-card,
.console-game-row.game-card,
.similar-item.game-card {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.4rem 0;
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 6%, transparent);
  text-decoration: none;
  color: inherit;
  border-left: 2px solid transparent;
  transition: background 0.12s ease, border-left 0.12s ease;
  background: transparent;
  border-top: 0;
  border-right: 0;
  min-height: 0;
  height: auto;
}

.result-row.game-card:hover,
.result-row.result-row-catalog.game-card:hover,
.result-row.game-card:focus-visible,
.result-row.result-row-catalog.game-card:focus-visible,
.console-game-row.game-card:hover,
.similar-item.game-card:hover,
.game-card:hover {
  border-left: 2px solid var(--text-secondary);
  background: color-mix(in srgb, var(--accent) 4%, transparent);
  cursor: pointer;
}

.game-card {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.4rem 0;
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 6%, transparent);
  text-decoration: none;
  color: inherit;
  border-left: 2px solid transparent;
  transition: background 0.12s ease, border-left 0.12s ease;
}

.game-card-cover {
  width: 48px;
  height: 48px;
  min-width: 48px;
  object-fit: cover;
  border: 1px solid var(--accent-dim);
  flex-shrink: 0;
}

.game-card-placeholder {
  width: 48px;
  height: 48px;
  min-width: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: color-mix(in srgb, var(--accent) 6%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 15%, transparent);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-disabled);
  flex-shrink: 0;
}

.game-card-body {
  min-width: 0;
  flex: 1 1 auto;
}

.game-card-title {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.game-card-meta {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
}

.result-row.game-card .result-row-indicator {
  display: none;
}

.result-row.game-card .result-info,
.result-row.result-row-catalog.game-card .result-info {
  padding: 0;
}

.result-row.game-card .result-signal,
.result-row.result-row-catalog.game-card .result-signal {
  margin-left: auto;
  justify-content: flex-end;
  flex-shrink: 0;
}

.btn-r?tromarket-cta {
  display: inline-block;
  background: rgba(241, 196, 92, 0.12);
  border: 2px solid var(--text-alert);
  color: var(--text-alert);
  font-family: var(--font-display);
  font-size: 0.72rem;
  padding: 0.75rem 1.5rem;
  letter-spacing: 0.06em;
  text-decoration: none;
  margin-top: 0.75rem;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.btn-r?tromarket-cta:hover {
  background: rgba(241, 196, 92, 0.22);
  border-color: var(--text-alert);
}

.sc-row {
  min-height: 80px;
  align-items: flex-start;
  border-left: 2px solid transparent;
  transition: background 0.12s ease, border-left 0.12s ease;
}

.sc-row:hover {
  border-left: 2px solid var(--text-secondary);
  background: color-mix(in srgb, var(--accent) 4%, transparent);
  cursor: pointer;
}

.market-search-row {
  border-left: 2px solid transparent;
  transition: background 0.12s ease, border-left 0.12s ease;
}

.market-search-row:hover,
.market-search-row.is-selected {
  border-left: 2px solid var(--text-secondary);
  background: color-mix(in srgb, var(--accent) 4%, transparent);
  cursor: pointer;
}

.compare-row.clickable {
  border-left: 2px solid transparent;
  transition: background 0.12s ease, border-left 0.12s ease;
}

.compare-row.clickable:hover {
  border-left: 2px solid var(--text-secondary);
  background: color-mix(in srgb, var(--accent) 4%, transparent);
  cursor: pointer;
}

.detail-section-toggle:hover {
  background: color-mix(in srgb, var(--accent) 4%, transparent);
  cursor: pointer;
}

.detail-section-chevron {
  margin-right: 0.5rem;
  color: var(--text-muted);
  font-size: 0.8rem;
}

.detail-section-hint {
  margin-left: 0.5rem;
  color: var(--text-disabled);
  font-family: var(--font-mono);
  font-size: 0.72rem;
}

.catalog-filter-panel {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--bg, #0a0f0a);
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 8%, transparent);
}

.console-filter-bar {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 8%, transparent);
}

.console-filter-btn {
  font-family: var(--font-display);
  font-size: 0.72rem;
  padding: 0.3rem 0.6rem;
  border: 1px solid var(--accent-dim);
  background: transparent;
  color: var(--text-disabled);
  cursor: pointer;
  transition: all 0.12s;
}

.console-filter-btn.active,
.console-filter-btn:hover {
  border-color: var(--text-primary);
  color: var(--text-primary);
  background: color-mix(in srgb, var(--accent) 6%, transparent);
}

.console-load-more {
  display: block;
  width: 100%;
  padding: 0.6rem;
  margin-top: 0.75rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  border: 1px solid var(--accent-dim);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.12s;
}

.console-load-more:hover {
  border-color: var(--text-primary);
  color: var(--text-primary);
}

/* ── Hub page ── */
.hub-intent-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin: 2rem 0;
}

.hub-intent-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.5rem 1rem;
  border: 1px solid var(--accent-dim);
  background: color-mix(in srgb, var(--accent) 4%, transparent);
  text-decoration: none;
  color: inherit;
  transition: background 0.15s, border-color 0.15s;
  gap: 0.4rem;
}

.hub-intent-btn:hover {
  background: color-mix(in srgb, var(--accent) 8%, transparent);
  border-color: var(--text-secondary);
  cursor: pointer;
}

.hub-intent-icon {
  font-size: 1.5rem;
  color: var(--text-primary);
}

.hub-intent-label {
  font-family: var(--font-display);
  font-size: 0.72rem;
  color: var(--text-primary);
  text-align: center;
  letter-spacing: 0.05em;
}

.hub-intent-sub {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
  text-align: center;
}

.hub-section-label {
  font-family: var(--font-display);
  font-size: 0.72rem;
  color: var(--text-alert);
  letter-spacing: 0.08em;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(241,196,92,0.2);
}

.hub-legendary-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

.hub-legendary-card {
  display: flex;
  gap: 0.65rem;
  padding: 0.6rem;
  border: 1px solid rgba(241,196,92,0.15);
  background: rgba(241,196,92,0.02);
  text-decoration: none;
  color: inherit;
  transition: background 0.12s, border-color 0.12s;
  overflow: hidden;
}

.hub-legendary-card:hover {
  background: rgba(241,196,92,0.06);
  border-color: rgba(241,196,92,0.35);
  cursor: pointer;
}

.hub-legendary-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hub-stats-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 0;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
  border-top: 1px solid color-mix(in srgb, var(--accent) 8%, transparent);
  margin-top: 1.5rem;
}

.hub-stat {
  display: flex;
  gap: 0.4rem;
  align-items: baseline;
}

.hub-stat-value {
  color: var(--text-primary);
  font-size: 0.9rem;
}

.hub-stat-label {
  color: var(--text-disabled);
  font-size: 0.72rem;
}

.hub-stat-sep {
  color: var(--text-disabled);
}

@media (max-width: 768px) {
  .hub-intent-grid {
    grid-template-columns: 1fr;
  }

  .hub-legendary-grid {
    grid-template-columns: 1fr;
  }
}

/* ========================================
   GAME-PAGE FIRST RECENTER
======================================== */

body.collection-cockpit-page .product-universe-frame,
body .product-universe-frame.is-collection,
body .product-universe-frame.is-market,
body .product-universe-frame.is-dex {
  display: block;
}

.hub-intent-grid-three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.hub-stats-compact {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.hub-stats-compact .hub-stat {
  min-width: 0;
}

.hub-secondary-grid-main {
  align-items: start;
}

.hub-system-actions-stack {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

.explorer-alias-shell,
.collection-cockpit-page,
.market-detail-shell {
  width: min(1320px, calc(100% - 48px));
  margin: 0 auto 40px;
}

.collection-cockpit-shell {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.collection-summary-hero {
  border-bottom: 1px solid var(--border);
}

.collection-cockpit-topline {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  padding: 10px 12px;
  border: 1px solid rgba(67, 95, 60, 0.52);
  background: var(--bg);
}

.collection-toolbar {
  justify-content: space-between;
}

/* ── Cockpit signal cards ── */
.cockpit-signals-bar {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
}

.cockpit-signal-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 10px 8px;
  background: var(--bg);
  border: 1px solid rgba(67, 95, 60, 0.52);
  cursor: pointer;
  transition: border-color 0.12s, background 0.12s;
  font-family: inherit;
  text-align: center;
}

.cockpit-signal-card:hover {
  border-color: var(--accent);
  background: rgba(15, 25, 15, 0.95);
}

.cockpit-signal-card[aria-pressed="true"] {
  border-color: var(--accent);
  background: rgba(20, 40, 20, 0.95);
}

.cockpit-signal-card[aria-pressed="true"] .cockpit-signal-count {
  color: var(--accent);
}

.cockpit-signal-count {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-alert);
  line-height: 1;
}

.cockpit-signal-count.is-zero {
  color: var(--text-muted);
  font-size: 18px;
}

.cockpit-signal-label {
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-transform: uppercase;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}

@media (max-width: 600px) {
  .cockpit-signals-bar {
    grid-template-columns: repeat(3, 1fr);
  }
}

.collection-toolbar-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.collection-toolbar-input,
.collection-toolbar-select {
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: var(--bg);
  color: var(--text-primary);
  font: 10px var(--font-mono);
}

.collection-status-line {
  margin: 0;
}

#collection-cockpit-lead {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid rgba(67, 95, 60, 0.52);
  background: var(--bg);
}

.collection-cockpit-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.collection-cockpit-grid:has(> [hidden]) {
  grid-template-columns: 1fr;
}

.collection-cockpit-main,
.collection-cockpit-side {
  min-width: 0;
}

.collection-table-header {
  border-bottom: 0;
}

.collection-preview-shell {
  border: 1px solid rgba(67, 95, 60, 0.58);
  background: linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98));
}

#detail-focus-state,
#detail-next-step {
  margin-top: 8px;
}

.collection-preview-summary {
  max-width: 42ch;
}

.surface-preview-panel .surface-action-row {
  margin-top: 10px;
}

.market-detail-shell .product-universe-frame,
.explorer-alias-shell .product-universe-frame,
.collection-cockpit-page .product-universe-frame {
  margin-bottom: 18px;
}

.detail-hero-actions {
  margin-top: 14px;
}

.detail-hero-actions a {
  white-space: nowrap;
}

.detail-accordion-toggle {
  align-items: center;
}

.detail-accordion-indicator {
  font-size: 12px;
}

@media (max-width: 1100px) {
  .hub-stats-compact,
  .hub-intent-grid-three {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 780px) {
  .explorer-alias-shell,
  .collection-cockpit-page,
  .market-detail-shell,
  .hub-page {
    width: min(100%, calc(100% - 24px));
  }

  .collection-cockpit-topline,
  .collection-toolbar-group {
    flex-direction: column;
    align-items: stretch;
  }

  .hub-stats-compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}



/* ========================================
   GAME-PAGE FIRST STABILITY OVERRIDES
======================================== */
.global-product-nav {
  align-items: stretch;
}

.global-product-home {
  align-self: stretch;
}

.global-product-links {
  flex: 1 1 520px;
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.global-product-link {
  min-width: 0;
  min-height: 52px;
  gap: 3px;
  padding: 9px 12px;
  justify-content: flex-start;
  align-items: flex-start;
}

.global-product-link .nav-label,
.global-product-link .nav-copy {
  display: block;
  width: 100%;
}

.global-product-link .nav-copy {
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.global-product-home,
.hub-page-title,
.page-title,
.product-universe-title,
.hub-module-title,
.filters-sidebar-title {
  overflow-wrap: anywhere;
}

.catalog-page-head,
.secondary-page-head {
  align-items: start;
  gap: 22px;
}

.catalog-head-tools {
  min-width: 0;
}

.hub-intent-grid-three {
  gap: 12px;
}

.hub-intent-card {
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

.hub-intent-copy,
.hub-intro,
.catalog-intro,
.catalog-search-jump-copy,
.product-universe-copy {
  max-width: 52ch;
}

.hub-intent-links {
  margin-top: auto;
}

.product-universe-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
}

.product-universe-links a {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid rgba(45, 61, 41, 0.56);
  background: rgba(8, 12, 8, 0.78);
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.product-universe-overlap {
  max-width: 60ch;
}

.collection-toolbar-group > * {
  min-width: 0;
}

.collection-preview-summary {
  max-width: none;
}

.surface-action-row,
.detail-hero-actions {
  align-items: flex-start;
  row-gap: 10px;
  column-gap: 12px;
}

.detail-hero-actions a {
  white-space: normal;
}

.terminal-query-line {
  align-items: center;
}

.terminal-query-input {
  min-width: 0;
  width: 100%;
}

.terminal-query-count {
  flex: 0 0 auto;
}

.hub-module-copy,
.hub-intro,
.catalog-search-jump-copy,
.catalog-panel-copy,
.product-universe-copy,
.collection-preview-summary {
  overflow-wrap: anywhere;
}

.terminal-summary-bar {
  align-items: stretch;
}

.terminal-summary-cell,
.hub-intent-card,
.hub-module,
.catalog-head-tools,
.collection-cockpit-main,
.collection-cockpit-side {
  min-width: 0;
}

.collection-cockpit-main {
  overflow: hidden;
}

.collection-table-header {
  overflow-x: auto;
}

@media (max-width: 780px) {
  .global-product-links,
  .product-universe-links {
    grid-template-columns: 1fr;
  }
}

/* ========================================
   RETRODEX 7/10 RECENTER OVERRIDES
======================================== */

body {
  padding: 18px 14px 28px;
}

.global-product-nav.global-product-nav-unified {
  width: min(var(--content-max, 1180px), calc(100% - var(--content-gutter, 24px) * 2));
  margin: 0 auto 28px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  align-items: stretch;
}

.global-product-nav.global-product-nav-unified .global-product-link {
  min-width: 0;
  min-height: 62px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  padding: 12px 14px;
  border: 1px solid rgba(56, 82, 50, 0.72);
  background: rgba(7, 10, 7, 0.94);
}

.global-product-nav.global-product-nav-unified .global-product-link.is-active {
  border-color: var(--text-secondary);
  background: var(--bg);
}

.global-product-nav.global-product-nav-unified .nav-label {
  font-family: var(--font-display);
  font-size: 0.8rem;
  color: var(--nav-label);
  letter-spacing: 0.08em;
}

.global-product-nav.global-product-nav-unified .nav-copy {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.hub-focused-page,
.retrodex-index-page,
.retrodex-search-page,
.collection-cockpit-page,
.market-detail-shell,
.detail-shell {
  width: min(var(--content-max, 1180px), calc(100% - var(--content-gutter, 24px) * 2));
  margin: 0 auto;
}

.secondary-page-head,
.retrodex-index-head,
.hub-focus-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 18px;
}

.secondary-page-head .page-subtitle,
.retrodex-index-head .catalog-intro,
.hub-focus-head .hub-intro {
  max-width: 34ch;
  margin: 0;
  color: var(--text-muted);
  line-height: 1.55;
}

.page-subtitle,
.catalog-intro,
.hub-intro,
.hub-intent-copy,
.hub-card-copy,
.surface-summary-copy,
.collection-preview-summary,
.detail-status-copy,
.detail-reading-note {
  font-size: 0.73rem;
}

.hub-focus-shell,
.hub-feature-shell,
.collection-cockpit-shell,
.market-hero-card,
.detail-shell > section,
.retrodex-index-page .catalog-layout,
.retrodex-search-page > *:not(script),
.collection-cockpit-page > *:not(script) {
  border-color: rgba(33, 47, 32, 0.88);
}

.hub-focus-shell,
.hub-intent-panel-compact,
.hub-feature-shell,
.retrodex-index-page .catalog-header,
.collection-page-head,
.market-page-head {
  margin-bottom: 18px;
}

.hub-focus-shell {
  display: grid;
  gap: 16px;
  padding: 22px 24px 20px;
  border: 1px solid rgba(39, 56, 36, 0.84);
  background: linear-gradient(180deg, rgba(7, 10, 7, 0.98), rgba(5, 8, 5, 0.98));
}

.hub-system-line,
.pass1-surface-banner {
  min-height: 0;
  font-size: 0.64rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

.hub-search-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 168px;
  gap: 0;
}

.hub-search-input {
  min-width: 0;
  min-height: 64px;
  padding: 0 18px;
  font-size: 0.9rem;
}

.hub-search-button {
  min-height: 64px;
}

.hub-stats-compact {
  gap: 0;
  border-top: 1px solid rgba(36, 52, 35, 0.85);
}

.hub-stats-compact .hub-stat {
  padding: 16px 18px 0 0;
  border-right: 1px solid rgba(28, 42, 28, 0.88);
}

.hub-stats-compact .hub-stat:last-child {
  border-right: 0;
}

.hub-intent-panel-compact {
  background: transparent;
  border: 0;
  padding: 0;
}

.hub-intent-grid-three {
  gap: 12px;
}

.hub-intent-card,
.hub-rich-card,
.collection-preview-shell,
.market-hero-card,
.search-panel,
.catalog-results-bar,
.stats-card,
.collection-summary-hero,
.collection-toolbar,
.collection-mode-bar,
.collection-cockpit-topline {
  background: rgba(6, 9, 6, 0.95);
}

.hub-intent-card {
  padding: 16px 16px 14px;
  border: 1px solid rgba(38, 54, 36, 0.82);
}

a.hub-rich-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border: 1px solid rgba(67, 95, 60, 0.52);
  background: var(--bg);
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}

a.hub-rich-card:hover,
a.hub-rich-card:focus-visible {
  border-color: var(--accent);
  background: rgba(15, 56, 15, 0.12);
  outline: none;
}

.hub-card-cover {
  flex-shrink: 0;
  width: auto;
  max-width: 120px;
  height: 140px;
  object-fit: contain;
  image-rendering: auto;
  background: transparent;
}

.hub-card-cover-placeholder {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 96px;
  height: 140px;
  border: 1px solid rgba(67, 95, 60, 0.4);
  background: var(--bg-surface);
  font-family: var(--font-display);
  font-size: 2.4rem;
  color: var(--accent-dim);
}

.hub-card-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  overflow: hidden;
  justify-content: center;
  min-width: 0;
}

.hub-intent-label,
.hub-module-title,
.filters-sidebar-title,
.terminal-preview-title,
.detail-domain-heading {
  line-height: 1.2;
}

.hub-intent-card .hub-intent-copy,
.hub-rich-card .hub-card-copy {
  color: var(--text-muted);
  margin-top: 10px;
}

.hub-card-proof {
  margin-bottom: 8px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hub-rich-card .hub-universe-actions {
  margin-top: 12px;
}

.hub-feature-shell {
  padding: 18px 20px 20px;
  border: 1px solid rgba(39, 56, 36, 0.84);
  background: rgba(6, 9, 6, 0.96);
}

.hub-module-head {
  align-items: baseline;
  gap: 12px;
}

.hub-signal-line {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(30, 45, 30, 0.88);
  color: var(--text-muted);
  font-size: 0.67rem;
}

.retrodex-index-head {
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(33, 47, 32, 0.88);
}

.retrodex-index-page .catalog-head-tools {
  width: min(340px, 100%);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.retrodex-index-page .catalog-search-jump input {
  min-height: 52px;
}

.catalog-layout-lean {
  grid-template-columns: minmax(250px, 300px) minmax(0, 1fr);
  gap: 20px;
}

.catalog-main-wide {
  min-width: 0;
}

.catalog-filter-panel {
  top: 12px;
  padding: 16px;
  border: 1px solid rgba(38, 54, 36, 0.82);
  background: rgba(6, 9, 6, 0.96);
}

.catalog-panel-head,
.catalog-results-bar {
  margin-bottom: 14px;
}

.catalog-panel-copy,
.field-helper,
.catalog-search-jump-copy,
.product-universe-overlap,
.market-search-helper {
  display: none !important;
}

.results-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.result-row.result-row-catalog,
.sc-row.sc-row-lean {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 14px;
  align-items: start;
  padding: 16px 0;
  border-bottom: 1px solid rgba(26, 39, 26, 0.88);
  background: transparent;
}

.result-row.result-row-catalog:hover,
.sc-row.sc-row-lean:hover {
  background: color-mix(in srgb, var(--accent) 4%, transparent);
  border-left: 0;
}

.result-row-indicator {
  display: none;
}

.result-title,
.sc-title {
  font-family: var(--font-display);
  font-size: 0.94rem;
  color: var(--nav-label);
  line-height: 1.2;
}

.result-meta,
.sc-sub {
  color: var(--text-muted);
  font-size: 0.69rem;
}

.result-presence-row,
.result-archive-row,
.sc-chip-row {
  margin-top: 8px;
  gap: 6px;
}

.result-signal,
.sc-signal-grid-lean {
  display: flex;
  gap: 8px;
  align-items: flex-start;
}

.sc-summary {
  margin-top: 8px;
  color: var(--text-secondary);
  max-width: 46ch;
}

.sc-action {
  align-self: center;
  color: var(--text-alert);
  font-size: 0.68rem;
  letter-spacing: 0.04em;
}

.retrodex-search-page .secondary-page-head,
.collection-page-head,
.market-page-head {
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(33, 47, 32, 0.88);
}

.explorer-query-shell,
.market-search-shell,
.collection-toolbar,
.collection-mode-bar {
  margin-bottom: 14px;
}

.detail-hero-shell {
  padding: 20px 22px;
  border: 1px solid rgba(39, 56, 36, 0.84);
  background: linear-gradient(180deg, rgba(7, 10, 7, 0.98), rgba(5, 8, 5, 0.98));
}

.detail-hero-grid-tight {
  grid-template-columns: minmax(0, 1.55fr) minmax(260px, 0.9fr);
  gap: 18px;
}

.detail-identity-panel,
.detail-hero-aside {
  padding: 0;
  border: 0;
  background: transparent;
}

.detail-hero-title-row {
  align-items: baseline;
  gap: 10px;
}

.detail-hero-title {
  font-size: clamp(1.7rem, 3.3vw, 2.5rem);
  margin: 0;
}

.detail-hero-meta-strip,
.detail-hero-developer,
.detail-status-copy,
.detail-reading-note {
  color: var(--text-secondary);
}

.detail-hero-chip-row,
.detail-hero-actions,
.detail-hero-reference {
  margin-top: 12px;
}

.detail-hero-actions {
  padding-top: 4px;
}

.detail-hero-actions .terminal-action-link.is-primary {
  color: var(--text-alert);
  border-color: rgba(241, 196, 92, 0.42);
}

.detail-hero-aside {
  padding: 14px 0 0 16px;
  border-left: 1px solid rgba(31, 46, 31, 0.92);
}

.detail-hero-actions {
  gap: 10px;
}

.detail-hero-actions .terminal-action-link {
  flex: 0 0 auto;
}

.detail-hero-aside .detail-domain-heading {
  margin-bottom: 10px;
}

.game-relations {
  margin-top: 14px;
}

.detail-accordion {
  border: 1px solid rgba(39, 56, 36, 0.84);
  background: rgba(6, 9, 6, 0.96);
}

.detail-accordion-toggle {
  min-height: 58px;
  padding: 0 18px;
}

.detail-accordion-content {
  padding: 0 18px 18px;
}

.collection-summary-hero {
  border: 1px solid rgba(39, 56, 36, 0.84);
}

.collection-cockpit-topline {
  padding: 12px 14px;
  border: 1px solid rgba(39, 56, 36, 0.84);
}


.collection-preview-shell {
  border: 1px solid rgba(39, 56, 36, 0.84);
  padding: 16px;
}

.collection-preview-summary {
  max-width: 40ch;
  color: var(--text-secondary);
}

.market-hero-card {
  border: 1px solid rgba(39, 56, 36, 0.84);
  padding: 18px 20px;
}

.market-search-results {
  margin-top: 14px;
}

.market-search-row {
  border-left: 0;
  padding: 14px 0;
}

.market-search-row:hover,
.market-search-row.is-selected {
  border-left: 0;
  background: color-mix(in srgb, var(--accent) 4%, transparent);
}

@media (max-width: 980px) {
  .global-product-nav.global-product-nav-unified,
  .hub-focused-page,
  .retrodex-index-page,
  .retrodex-search-page,
  .collection-cockpit-page,
  .market-detail-shell,
  .detail-shell {
    width: min(100%, calc(100% - 16px));
  }

  .catalog-layout-lean,
  .collection-cockpit-grid,
  .detail-hero-grid-tight,
  .secondary-page-head,
  .retrodex-index-head,
  .hub-focus-head {
    grid-template-columns: 1fr;
    flex-direction: column;
    align-items: start;
  }

  .detail-hero-aside {
    padding: 14px 0 0;
    border-left: 0;
    border-top: 1px solid rgba(31, 46, 31, 0.92);
  }
}

@media (max-width: 760px) {
  .global-product-nav.global-product-nav-unified {
    gap: 6px;
  }
  .global-product-nav.global-product-nav-unified .global-product-link {
    min-height: 48px;
    padding: 8px 10px;
  }

  .hub-search-form {
    grid-template-columns: 1fr;
  }

  .hub-stats-compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hub-stats-compact .hub-stat {
    border-right: 0;
    border-bottom: 1px solid rgba(28, 42, 28, 0.88);
    padding-bottom: 12px;
  }

  .result-row.result-row-catalog,
  .sc-row.sc-row-lean {
    grid-template-columns: 1fr;
  }

  .result-signal,
  .sc-signal-grid-lean {
    margin-top: 8px;
  }
}

/* ========================================
   PERSONA EXECUTION TIGHTENING
======================================== */
.global-product-nav.global-product-nav-unified {
  gap: 10px;
}

.global-product-nav.global-product-nav-unified .global-product-link {
  padding: 12px 14px;
  justify-content: flex-start;
  align-items: flex-start;
}

.global-product-nav.global-product-nav-unified .nav-copy {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.hub-focused-page {
  width: min(var(--content-max, 1180px), calc(100% - var(--content-gutter, 24px) * 2));
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.hub-focus-shell {
  padding: 22px 24px;
}

.hub-intro {
  max-width: 34ch;
  margin: 6px 0 0;
}

.hub-intent-panel {
  padding: 0;
  border: 0;
  background: transparent;
}

.hub-intent-card {
  min-height: 0;
  padding: 14px 16px;
}

.hub-intent-copy,
.hub-card-copy,
.collection-preview-summary,
.result-summary,
.sc-summary,
.detail-reading-note,
.detail-status-copy {
  line-height: 1.45;
}

.hub-card-copy {
  max-width: 34ch;
  color: var(--text-muted);
  font-size: 0.73rem;
}

.hub-signal-line {
  gap: 12px;
  margin-top: 12px;
  padding-top: 12px;
  font-size: 0.62rem;
}

.retrodex-index-page .catalog-header,
.retrodex-search-page .secondary-page-head,
.collection-page-head,
.market-page-head {
  align-items: end;
  gap: 20px;
}

.retrodex-index-page .catalog-page-titlezone {
  max-width: 38rem;
}

.retrodex-index-page .page-subtitle,
.retrodex-search-page .page-subtitle,
.collection-page-head .page-subtitle,
.market-page-head .page-subtitle {
  max-width: 30ch;
}

.retrodex-index-page .pass1-surface-banner,
.retrodex-search-page .pass1-surface-banner {
  margin-top: 6px;
  font-size: 0.62rem;
  color: var(--text-muted);
}

.retrodex-search-page #search-curation-banner {
  display: none;
}

.retrodex-index-page .catalog-sidebar {
  position: sticky;
  top: 12px;
  align-self: start;
}

.results-summary-line {
  color: var(--text-muted);
  font-size: 0.79rem;
}

.results-summary-main {
  color: var(--text-muted);
  letter-spacing: 0.02em;
}

.result-row.result-row-catalog,
.sc-row.sc-row-lean {
  padding: 18px 0 16px;
}

.result-info {
  min-width: 0;
}

.result-summary {
  display: block;
  margin-top: 8px;
  max-width: 58ch;
  color: var(--text-muted);
  font-size: 0.74rem;
}

/* games-list — snippet relationnel */
.game-row-synopsis {
  display: block;
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 2px;
  line-height: 1.4;
  max-width: 480px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* kicker accumulation — adoucissement dans les lignes résultat */
.result-info .detail-kicker {
  letter-spacing: 0.08em;
  color: var(--color-secondary, var(--text-muted));
}

.result-signal {
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.result-price {
  font-size: 0.8rem;
}

.detail-shell {
  width: min(1040px, calc(100% - 24px));
}

.detail-hero-shell {
  padding: 24px 26px;
}

.detail-hero-grid-tight {
  grid-template-columns: minmax(0, 1.7fr) minmax(240px, 0.85fr);
}

.hero-summary {
  max-width: 58ch;
  font-size: 0.85rem;
  line-height: 1.58;
}

.synopsis-band {
  padding: 18px 26px;
  border-left: 3px solid var(--text-secondary);
  background: var(--bg-card);
  color: var(--text-secondary);
  font-size: 0.88rem;
  line-height: 1.65;
  max-width: 72ch;
}

.provenance-line {
  padding: 7px 26px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 0 16px;
}

.detail-hero-reference {
  margin-top: 14px;
}

.detail-accordion + .detail-accordion {
  margin-top: 12px;
}

.collection-cockpit-topline {
  justify-content: flex-start;
  gap: 12px;
}

.collection-preview-shell {
  position: sticky;
  top: 12px;
}

.surface-action-row,
.terminal-preview-row.surface-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

@media (max-width: 760px) {
  .global-product-nav.global-product-nav-unified .nav-copy {
    display: none;
  }
}

/* ── Ingest Data Viz ─────────────────────────────────────────────────────── */

.hub-ingest-wrap {
  display: flex;
  gap: 18px;
  align-items: flex-start;
}

.hub-ingest-board {
  flex-shrink: 0;
  border: 1px solid rgba(67, 95, 60, 0.4);
  line-height: 0;
  box-shadow: 0 0 24px color-mix(in srgb, var(--accent) 6%, transparent);
}

.hub-ingest-board canvas {
  display: block;
  image-rendering: pixelated;
}

.hub-ingest-panel {
  flex: 1;
  min-width: 130px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  opacity: 0.07;
  transition: opacity .45s ease;
}

.hub-ingest-panel.is-revealed {
  opacity: 1;
}

.hub-ingest-block {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.hub-ingest-kicker {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .12em;
  color: var(--text-muted);
  text-transform: uppercase;
}

.hub-ingest-game-title {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.35;
  word-break: break-word;
}

.hub-ingest-game-meta {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-muted);
}

.hub-ingest-score-val {
  font-family: var(--font-mono);
  font-size: 26px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.hub-ingest-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.hub-ingest-atom {
  font-size: 15px;
  opacity: 0.2;
  transition: opacity .25s;
  cursor: default;
}

.hub-ingest-atom.has {
  opacity: 1;
}

.hub-ingest-combo {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  color: var(--text-primary);
  min-height: 16px;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity .2s, transform .2s;
  letter-spacing: .05em;
}

.hub-ingest-combo.is-active {
  opacity: 1;
  transform: translateY(0);
}

.hub-ingest-feed {
  display: flex;
  flex-direction: column;
  gap: 3px;
  max-height: 160px;
  overflow: hidden;
}

.hub-ingest-feed-row {
  display: flex;
  align-items: baseline;
  gap: 6px;
  transform: translateY(-6px);
  transition: transform 0.25s ease, max-height 0.35s ease;
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.4;
  max-height: 20px;
  overflow: hidden;
}

.hub-ingest-feed-row.is-visible {
  transform: translateY(0);
}

.hub-ingest-feed-row.is-consumed {
  transform: translateY(10px);
  max-height: 0;
  margin: 0;
  transition: transform 0.3s ease, max-height 0.35s ease 0.05s;
}

.hub-ingest-feed-row.is-match {
  transform: translateY(0);
}

.hub-ingest-feed-row.is-match .feed-value {
  font-weight: 700;
  letter-spacing: 0.03em;
}

.feed-emoji {
  font-size: 11px;
  flex-shrink: 0;
}

.feed-value {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 160px;
}

.hub-ingest-quality-badge {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: .08em;
  align-self: center;
}

@media (max-width: 540px) {
  .hub-ingest-wrap {
    flex-direction: column;
  }

  .hub-ingest-board canvas {
    width: 100%;
    height: auto;
    max-width: 288px;
  }
}

/* ── Hub Discovery Cover Grid (A4 — Le Curieux) ─────────────────────────── */

.hub-discover-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
}

.hub-discover-card {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  border: 1px solid var(--border);
  overflow: hidden;
  transition: border-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.hub-discover-card:hover {
  border-color: var(--text-secondary);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px color-mix(in srgb, var(--accent) 15%, transparent);
}

.hub-discover-cover {
  width: 100%;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: var(--bg-surface);
}

.hub-discover-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hub-discover-info {
  padding: 6px 8px;
  background: rgba(8, 12, 8, 0.92);
}

.hub-discover-title {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.04em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hub-discover-meta {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 10px;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 900px) {
  .hub-discover-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 520px) {
  .hub-discover-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ── B3: Price confidence tooltip (result list) ──────────────────────────── */
.result-price[title] {
  cursor: help;
  text-decoration: underline dotted var(--accent-dim);
  text-underline-offset: 2px;
}

/* ── A5: Price timestamp on game detail hero ─────────────────────────────── */
.price-timestamp {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-top: 6px;
  opacity: 0.7;
}

/* ── Collection Evolution Panel ─────────────────────────────────────────── */
.collection-evolution-panel {
  margin: 8px 0 0;
  padding: 8px;
  border: 1px solid var(--border);
  background: var(--bg-card);
}
.collection-evolution-panel .detail-kicker {
  font-size: 10px;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  margin-bottom: 6px;
}
.collection-evolution-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}
.evolution-cell {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.evolution-label {
  font-size: 10px;
  color: var(--text-muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.evolution-value {
  font-size: 13px;
  color: var(--text-primary);
  font-family: var(--font-display);
}

/* ── Cockpit signal description ──────────────────────────────────────────── */
.cockpit-signal-desc {
  font-size: 7px;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  text-transform: none;
  line-height: 1.2;
  margin-top: 2px;
  display: none;
}
.cockpit-signal-card[aria-pressed="false"] .cockpit-signal-count.is-zero ~ .cockpit-signal-label ~ .cockpit-signal-desc {
  display: block;
}

/* Signal cards: dim when count=0, accent when count>0 */
.cockpit-signal-card:has(.cockpit-signal-count.is-zero) {
  opacity: 0.45;
  border-color: rgba(67, 95, 60, 0.25);
}

.cockpit-signal-card:has(.cockpit-signal-count.is-zero):hover {
  opacity: 0.7;
}

.cockpit-signal-card:has(.cockpit-signal-count:not(.is-zero)) {
  border-color: var(--accent-dim);
}

.cockpit-signal-card:has(.cockpit-signal-count:not(.is-zero)) .cockpit-signal-count {
  color: var(--text-primary);
}

/* ── Price freshness alert ───────────────────────────────────────────────── */
.price-freshness-alert {
  margin-top: 4px;
  padding: 3px 6px;
  font-size: 10px;
  font-family: var(--font-ui);
  letter-spacing: 0.05em;
  color: var(--text-alert);
  border: 1px solid rgba(255, 204, 0, 0.3);
  background: rgba(255, 204, 0, 0.05);
}

/* ── Decision action button ──────────────────────────────────────────────── */
.decision-action-btn {
  margin-top: 4px;
  width: 100%;
  padding: 3px 4px;
  font-size: 10px;
  font-family: var(--font-ui);
  letter-spacing: 0.05em;
  background: rgba(255, 204, 0, 0.1);
  border: 1px solid var(--text-alert);
  color: var(--text-alert);
  cursor: pointer;
  text-transform: uppercase;
}
.decision-action-btn:hover {
  background: rgba(255, 204, 0, 0.2);
}
.decision-action-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Collection review-first refresh */
.collection-page-head .page-subtitle {
  max-width: 54ch;
}

.collection-summary-hero {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  border: 1px solid rgba(39, 56, 36, 0.84);
  border-bottom: 0;
  overflow: hidden;
}

.collection-summary-hero .terminal-summary-cell {
  padding: 11px 14px 13px;
  background: linear-gradient(180deg, rgba(8, 12, 8, 0.98), rgba(5, 8, 5, 0.98));
}

.collection-summary-hero .terminal-summary-cell:nth-child(-n + 4) {
  background: linear-gradient(180deg, rgba(9, 13, 9, 0.99), var(--bg));
}

.collection-summary-hero .terminal-summary-cell:nth-last-child(-n + 2) {
  background: var(--bg);
}

.collection-summary-hero .terminal-summary-label {
  margin-bottom: 6px;
  color: var(--text-muted);
  letter-spacing: 0.14em;
}

.collection-summary-hero .terminal-summary-value {
  font-size: clamp(14px, 1.5vw, 18px);
}

.collection-summary-hero .terminal-summary-cell:nth-child(2) .terminal-summary-value {
  font-size: clamp(18px, 2.2vw, 26px);
  color: var(--text-value);
}

.collection-summary-hero .terminal-summary-value.positive {
  color: var(--confidence-high);
}

.collection-summary-hero .terminal-summary-value.negative {
  color: var(--confidence-low);
}

#collection-cockpit-lead {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  padding: 12px 14px;
  border: 1px solid rgba(39, 56, 36, 0.84);
  border-top: 1px solid rgba(58, 80, 51, 0.84);
  background: linear-gradient(180deg, rgba(8, 12, 8, 0.98), var(--bg));
}

#collection-cockpit-lead strong {
  color: var(--text-primary);
  letter-spacing: 0.14em;
}

#collection-cockpit-lead span {
  max-width: 64ch;
  color: var(--text-secondary);
  overflow-wrap: break-word;
  word-break: break-word;
}

.collection-cockpit-topline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
  padding: 8px 2px 0;
  border: 0;
  background: transparent;
}

.collection-cockpit-topline .terminal-action-link {
  color: var(--text-muted);
}

.collection-cockpit-topline .terminal-action-link:hover {
  color: var(--text-primary);
}

.collection-mode-bar,
.collection-toolbar {
  margin-bottom: 12px;
}

.collection-mode-bar {
  border-color: rgba(39, 56, 36, 0.84);
  background: rgba(6, 9, 6, 0.95);
}

.collection-toolbar.surface-query-shell {
  padding: 9px 12px;
  border-color: rgba(39, 56, 36, 0.84);
}

.collection-status-line {
  line-height: 1.55;
}

#status-text {
  padding: 10px 12px;
  border: 1px solid rgba(39, 56, 36, 0.84);
  background: var(--bg);
  color: var(--text-secondary);
}

.collection-cockpit-main {
  min-width: 0;
}

.collection-table-header {
  padding: 8px 12px;
  border-color: rgba(39, 56, 36, 0.84);
  background: rgba(8, 11, 8, 0.92);
  color: var(--text-muted);
  font-size: 10px;
  letter-spacing: 0.12em;
}

#collection-list-container {
  border: 1px solid rgba(39, 56, 36, 0.84);
  border-top: 0;
  background: rgba(6, 9, 6, 0.92);
}

.collection-preview-shell {
  padding: 18px 18px 16px;
  border-color: rgba(51, 71, 45, 0.9);
  background:
    linear-gradient(180deg, var(--bg), var(--bg)),
    radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 6%, transparent), transparent 34%);
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--accent) 4%, transparent), 0 0 0 1px color-mix(in srgb, var(--bg) 45%, transparent);
}

.collection-preview-shell .terminal-preview-label {
  color: var(--text-muted);
  letter-spacing: 0.16em;
}

.collection-preview-shell .terminal-preview-title {
  margin-top: 6px;
  font-size: clamp(21px, 2.4vw, 28px);
  line-height: 1.06;
}

.collection-preview-shell .surface-identity-meta,
.collection-preview-shell .surface-chip-row,
.collection-preview-shell #detail-next-step,
.collection-preview-shell .surface-action-row {
  margin-top: 12px;
}

.collection-preview-shell #detail-focus-state {
  margin-top: 10px;
}

.collection-preview-shell .surface-signal-grid.is-five {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.collection-preview-shell .surface-signal-card {
  min-height: 72px;
  align-content: start;
}

.collection-preview-summary {
  max-width: none;
  margin-top: 14px;
  color: var(--text-muted);
  line-height: 1.72;
}

.collection-preview-shell #detail-next-step {
  padding-top: 10px;
  border-top: 1px solid rgba(39, 56, 36, 0.84);
  color: var(--text-primary);
}

.collection-next-step-label {
  display: block;
  margin-bottom: 6px;
  color: var(--text-muted);
  font-size: 10px;
  letter-spacing: 0.14em;
}

.collection-next-step-copy {
  display: block;
  color: var(--text-primary);
  line-height: 1.6;
}

@media (max-width: 1100px) {
  .collection-summary-hero {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .collection-cockpit-grid {
    grid-template-columns: 1fr;
  }

  .collection-preview-shell {
    position: static;
  }
}

@media (max-width: 720px) {
  .collection-summary-hero {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .collection-cockpit-topline {
    padding-top: 2px;
  }

  .collection-preview-shell .surface-signal-grid.is-five {
    grid-template-columns: 1fr;
  }
}

/* UX structure tightening lot */

.hub-card-proof-secondary {
  margin-top: 8px;
  margin-bottom: 0;
  color: var(--text-secondary);
}

.retrodex-index-page .catalog-operating-strip {
  grid-template-columns: 1fr;
}

.retrodex-index-page .catalog-operating-card-primary {
  max-width: none;
}

.retrodex-index-page .catalog-operating-stats {
  margin-top: 14px;
}

.retrodex-index-page .catalog-head-tools {
  width: min(300px, 100%);
}

.retrodex-index-page .catalog-results-bar {
  align-items: center;
}

.result-archive-row {
  margin-top: 8px;
}

.result-context-row {
  display: block;
  margin-top: 8px;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.detail-shell .detail-accordion-toggle {
  letter-spacing: 0.08em;
}

.collection-evolution-panel {
  margin-top: 18px;
}

#collection-evolution {
  border-top: 1px solid var(--color-border, #222);
  padding-top: 12px;
  margin-top: 16px;
  opacity: 0.85;
}

.collection-preview-shell .terminal-preview-label {
  color: var(--text-muted);
}

.collection-preview-shell .surface-signal-grid.is-four {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.collection-preview-shell .surface-signal-grid.is-four .surface-signal-card {
  min-height: 72px;
  align-content: start;
}

.market-page-head .page-subtitle {
  max-width: 40ch;
}

@media (max-width: 720px) {
  .collection-preview-shell .surface-signal-grid.is-four {
    grid-template-columns: 1fr;
  }
}

/* Hub OS tagline */
.hub-system-tagline {
  font-size: 10px;
  letter-spacing: 0.15em;
  color: var(--color-secondary);
  margin-top: 4px;
  margin-bottom: 0;
  text-transform: uppercase;
}

/* Collection cockpit affordance */
.cockpit-signal-card {
  cursor: pointer;
}
.cockpit-signal-card:hover:not(.is-active) {
  border-color: var(--color-accent, #4ade80);
  transition: border-color 0.15s ease;
}

/* Collection labels */
.collection-inventory-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--color-secondary);
  text-transform: uppercase;
  padding: 8px 0 4px 0;
  border-top: 1px solid var(--color-border, #333);
  margin-top: 8px;
}

.collection-section-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--color-secondary);
  text-transform: uppercase;
  margin: 0 0 8px 0;
}

/* Possession chip — hero game-detail */
.possession-chip {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  padding: 2px 7px;
  border-radius: 2px;
  text-transform: uppercase;
  margin-top: 6px;
}
.possession-chip.is-owned {
  background: var(--border);
  color: var(--text-value);
  border: 1px solid var(--accent);
}
.possession-chip.is-sale {
  background: #3a2a00;
  color: var(--text-alert);
  border: 1px solid var(--text-alert);
}
.possession-chip.is-wanted {
  background: var(--bg-card);
  color: var(--status-info);
  border: 1px solid var(--status-info);
}
.possession-chip.is-untracked {
  background: var(--bg);
  color: var(--text-muted);
  border: 1px solid var(--text-disabled);
}

/* Game detail — add to collection CTA */
.detail-add-cta {
  display: inline-block;
  font-size: 10px;
  color: var(--text-muted);
  text-decoration: none;
  margin-top: 4px;
  letter-spacing: 0.05em;
}
.detail-add-cta:hover {
  color: var(--color-accent, #4ade80);
}

/* Focus panel — primary CTA */
.terminal-action-link.is-primary-action {
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--color-accent, #4ade80);
  text-decoration: none;
}
.terminal-action-link.is-primary-action:hover {
  text-decoration: underline;
}

/* Focus panel — next action label */
.focus-next-label {
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  text-transform: uppercase;
  display: block;
  margin-bottom: 3px;
}

/* OS expression lot */
.hub-os-shell {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.hub-os-shell .hub-intent-grid {
  margin: 0;
}

#hub-movers:empty {
  display: none;
}

.hub-focus-head-os {
  align-items: start;
}

.hub-intro-os {
  max-width: 44ch;
}

.baz-anecdote-next {
  min-height: 44px;
  padding: 10px 16px;
  display: inline-flex;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-primary);
  background: none;
  border: 1px solid rgba(67, 95, 60, 0.5);
  cursor: pointer;
  transition: opacity 0.2s, border-color 0.2s;
}

.baz-anecdote-next:hover {
  border-color: var(--accent);
}

.baz-anecdote-next:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.baz-anecdote-next[hidden] {
  display: none;
}

.detail-archive-link {
  color: var(--text-muted);
  font-size: 0.68rem;
}
.detail-archive-link:hover {
  color: var(--text-primary);
}

.stats-movers-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

@media (max-width: 760px) {
  .stats-movers-grid {
    grid-template-columns: 1fr;
  }
}

/* ─── Consoles Layout ─── */

.consoles-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 18px;
  align-items: start;
}

.consoles-sidebar {
  border: 1px solid rgba(67, 95, 60, 0.52);
  background: var(--bg);
  max-height: 70vh;
  overflow-y: auto;
}

.consoles-list {
  display: flex;
  flex-direction: column;
}

.consoles-list .console-row {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 12px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.25);
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: background 0.12s, border-color 0.12s;
}

.consoles-list .console-row:hover {
  background: rgba(15, 56, 15, 0.12);
}

.consoles-list .console-row.active {
  border-left: 2px solid var(--accent);
  background: rgba(15, 56, 15, 0.18);
}

.consoles-list .console-row-title {
  font-size: 0.78rem;
  color: var(--text-primary);
}

.consoles-list .console-row-meta {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text-muted);
}

.consoles-list .console-row-signal {
  font-family: var(--font-mono);
  font-size: 0.58rem;
  color: var(--text-muted);
  letter-spacing: 0.06em;
}

.consoles-detail {
  min-width: 0;
}

.consoles-detail-panel {
  border: 1px solid rgba(67, 95, 60, 0.52);
  background: var(--bg);
  padding: 18px;
}

@media (max-width: 760px) {
  .consoles-layout {
    grid-template-columns: 1fr;
  }
  .consoles-sidebar {
    max-height: 40vh;
  }
}

/* ─── Stats Dashboard ─── */

.stats-overview-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.stats-counter {
  padding: 14px 12px;
  border: 1px solid rgba(67, 95, 60, 0.52);
  background: var(--bg);
  text-align: center;
}

.stats-counter-value {
  display: block;
  font-family: var(--font-mono);
  font-size: 1.4rem;
  color: var(--text-primary);
  line-height: 1.2;
}

.stats-counter-label {
  display: block;
  margin-top: 4px;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.stats-section {
  margin-top: 18px;
}

.stats-section-label {
  margin-bottom: 10px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-muted);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.stats-tier-bar {
  display: flex;
  height: 10px;
  border-radius: 1px;
  overflow: hidden;
  gap: 1px;
}

.stats-tier-segment {
  min-width: 2px;
}

.stats-tier-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 8px;
}

.stats-tier-legend-item {
  display: flex;
  align-items: center;
  gap: 4px;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text-secondary);
}

.stats-tier-dot {
  width: 8px;
  height: 8px;
  border-radius: 1px;
}

.stats-top-list {
  display: flex;
  flex-direction: column;
}

.stats-top-row {
  display: grid;
  grid-template-columns: 24px 1fr 120px 80px;
  gap: 8px;
  align-items: center;
  padding: 8px 10px;
  border-bottom: 1px solid rgba(67, 95, 60, 0.25);
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: background 0.12s;
}

.stats-top-row:hover {
  background: rgba(15, 56, 15, 0.12);
}

.stats-top-rank {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
  text-align: center;
}

.stats-top-title {
  font-size: 0.78rem;
  color: var(--text-primary);
}

.stats-top-platform {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text-muted);
}

.stats-top-price {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-value);
  text-align: right;
}

.stats-bar-row {
  display: grid;
  grid-template-columns: 140px 1fr 50px;
  gap: 10px;
  align-items: center;
  padding: 4px 0;
}

.stats-bar-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stats-bar-track {
  height: 8px;
  background: rgba(67, 95, 60, 0.15);
  border-radius: 1px;
  overflow: hidden;
}

.stats-bar-fill {
  height: 100%;
  border-radius: 1px;
  transition: width 0.3s ease-out;
}

.stats-bar-value {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-muted);
  text-align: right;
}

.stats-empty {
  padding: 16px;
  color: var(--text-muted);
  text-align: center;
  font-size: 0.72rem;
}

@media (max-width: 760px) {
  .stats-overview-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .stats-top-row {
    grid-template-columns: 24px 1fr 60px;
  }
  .stats-top-platform {
    display: none;
  }
  .stats-bar-row {
    grid-template-columns: 100px 1fr 40px;
  }
}

/* ─── Hub Boot Screen ─── */

.boot-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: #0F180F;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.boot-log {
  font-family: var(--font-ui);
  font-size: 14px;
  color: #00ff66;
  line-height: 1.8;
  letter-spacing: 0.06em;
  white-space: pre;
  text-shadow: 0 0 6px rgba(0, 255, 102, 0.4);
  max-width: 420px;
  padding: 20px;
}

.boot-fade-out {
  animation: boot-dismiss 300ms ease-out forwards;
}

@keyframes boot-dismiss {
  to { opacity: 0; }
}

/* ─── Hub Stagger Entrance ─── */

.hub-nav-card,
a.hub-rich-card {
  opacity: 0;
  transform: translateY(10px);
  animation: hub-card-enter 0.4s ease-out forwards;
}

.hub-nav-card:nth-child(1) { animation-delay: 0.05s; }
.hub-nav-card:nth-child(2) { animation-delay: 0.12s; }
.hub-nav-card:nth-child(3) { animation-delay: 0.19s; }

a.hub-rich-card:nth-child(1) { animation-delay: 0.25s; }
a.hub-rich-card:nth-child(2) { animation-delay: 0.32s; }
a.hub-rich-card:nth-child(3) { animation-delay: 0.39s; }

@keyframes hub-card-enter {
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .hub-nav-card,
  a.hub-rich-card {
    opacity: 1;
    transform: none;
    animation: none;
  }
}

.hub-card-tags {
  display: flex;
  gap: 6px;
  margin-top: 4px;
}

.hub-card-tag {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
}

.hub-card-tag-ms::before {
  content: 'MS ';
  opacity: 0.6;
}

/* ─── Hub Nav Cards ─── */

.hub-nav-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.hub-nav-card {
  display: grid;
  gap: 4px;
  padding: 16px;
  border: 1px solid rgba(67, 95, 60, 0.52);
  background: var(--bg);
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
  min-width: 0;
  overflow: hidden;
}

.hub-nav-card:hover,
.hub-nav-card:focus-visible {
  border-color: var(--accent);
  background: rgba(15, 56, 15, 0.12);
  outline: none;
}

.hub-nav-label {
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hub-nav-counter {
  display: block;
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 1.6rem;
  line-height: 1.1;
}

.hub-nav-unit {
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.05em;
}

.hub-nav-copy {
  margin-top: 4px;
  color: var(--text-muted);
  font-size: 0.73rem;
  line-height: 1.5;
}

@media (max-width: 760px) {
  .hub-nav-grid {
    grid-template-columns: 1fr;
  }
}

#hub-rich-grid {
  align-items: stretch;
}

.hub-rich-card {
  min-height: 0;
}

@media (max-width: 760px) {
  a.hub-rich-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 12px;
  }
  .hub-card-cover {
    height: 120px;
  }
  .hub-card-cover-placeholder {
    width: 80px;
    height: 120px;
  }
}

.cockpit-active-filter {
  color: var(--text-primary);
  font-size: 0.72rem;
  letter-spacing: 0.05em;
}

.cockpit-signal-desc {
  color: var(--text-secondary);
  font-size: 0.68rem;
  line-height: 1.3;
}

.collection-row-cue.is-primary,
.surface-signal-value.is-primary {
  color: var(--color-accent, #4ade80);
}

.collection-row-cue.is-hot,
.surface-signal-value.is-hot {
  color: var(--text-alert, #f1c45c);
}

.result-action-row {
  display: block;
  margin-top: 4px;
  color: var(--text-secondary);
  font-size: 0.71rem;
  line-height: 1.45;
}

.stats-return-line {
  margin-bottom: 12px;
  padding: 10px 12px;
}

.detail-hero-price-help.is-warning {
  color: var(--text-alert);
}

/* ─── Collection row: region + confidence inline meta ─── */

.collection-row-meta {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
}

.collection-row-region {
  font-size: 10px;
  font-family: var(--font-mono);
  padding: 1px 5px;
  border: 1px solid currentColor;
  letter-spacing: 0.04em;
  line-height: 1.4;
  opacity: 0.85;
  cursor: default;
}

.collection-row-region.region--pal   { color: var(--region-pal);    border-color: var(--region-pal-dim); }
.collection-row-region.region--ntscu { color: var(--region-ntsc-u); border-color: var(--region-ntsc-u-dim); }
.collection-row-region.region--ntscj { color: var(--region-ntsc-j); border-color: var(--region-ntsc-j-dim); }
.collection-row-region.region--ntscb { color: var(--region-ntsc-b); border-color: var(--region-ntsc-b-dim); }
.collection-row-region.region--multi { color: var(--region-multi);  border-color: var(--region-multi-dim); }
.collection-row-region.region--unknown {
  color: var(--text-muted);
  border-color: var(--border);
  opacity: 0.7;
}

.collection-row-confidence {
  font-size: 10px;
  font-family: var(--font-mono);
  padding: 1px 5px;
  letter-spacing: 0.04em;
  line-height: 1.4;
  cursor: default;
}

.collection-row-confidence.confidence--high    { color: var(--confidence-high); }
.collection-row-confidence.confidence--medium  { color: var(--confidence-mid);  }
.collection-row-confidence.confidence--low     { color: var(--confidence-low);  }
.collection-row-confidence.confidence--unknown { color: var(--text-muted);      }

/* ─── Edit form helper text ─── */

.collection-form-help {
  font-size: 10px;
  color: var(--text-muted);
  padding: 4px 0 6px;
  letter-spacing: 0.03em;
  line-height: 1.4;
  border-bottom: 1px solid var(--border);
  margin-bottom: 6px;
}

/* ─── Shared freshness color classes (collection rows + catalog rows) ─── */

.freshness--fresh { color: var(--confidence-high); }
.freshness--mid   { color: var(--confidence-mid);  }
.freshness--stale { color: var(--confidence-low);  }
.freshness--none  { color: var(--text-muted);      }

/* ─── Catalog row: price age chip (renderGameRow) ─── */

.result-price-age {
  font-size: 10px;
  font-family: var(--font-mono);
  letter-spacing: 0.04em;
  line-height: 1.4;
  cursor: default;
  opacity: 0.75;
  margin-top: 1px;
}

/* ─── Collection row: price freshness chip ─── */

.collection-row-freshness {
  font-size: 10px;
  font-family: var(--font-mono);
  padding: 1px 4px;
  letter-spacing: 0.04em;
  line-height: 1.4;
  cursor: default;
  opacity: 0.8;
}

/* freshness colors inherited from shared .freshness--* classes above */

/* ─── Detail panel: inline region in identity row ─── */

.detail-identity-region {
  font-family: var(--font-mono);
  font-size: inherit;
  cursor: default;
}

.detail-identity-region.region--pal   { color: rgba(120, 220, 170, 0.9); }
.detail-identity-region.region--ntscu { color: rgba(120, 170, 255, 0.9); }
.detail-identity-region.region--ntscj { color: rgba(255, 140, 120, 0.9); }
.detail-identity-region.region--ntscb { color: rgba(255, 210, 100, 0.9); }
.detail-identity-region.region--multi { color: rgba(200, 160, 255, 0.9); }
.detail-identity-region.region--unknown {
  color: var(--text-alert);
  opacity: 0.8;
}

/* ─── Detail panel: region chip with color coding ─── */

.detail-region-chip.region--pal   { border-color: rgba(80, 200, 150, 0.5); color: rgba(120, 220, 170, 1); }
.detail-region-chip.region--ntscu { border-color: rgba(80, 140, 255, 0.5); color: rgba(120, 170, 255, 1); }
.detail-region-chip.region--ntscj { border-color: rgba(255, 80,  80,  0.5); color: rgba(255, 140, 120, 1); }
.detail-region-chip.region--ntscb { border-color: rgba(220, 170, 50,  0.5); color: rgba(255, 210, 100, 1); }
.detail-region-chip.region--multi { border-color: rgba(160, 100, 220, 0.5); color: rgba(200, 160, 255, 1); }
.detail-region-chip.region--unknown {
  border-color: var(--text-alert);
  color: var(--text-alert);
  opacity: 0.85;
}

/* Mobile touch targets (WCAG 2.5.5) */
@media (max-width: 768px) {
  button, select, .terminal-filter-btn, .cockpit-signal-card, .tab-btn {
    min-height: 44px;
  }
  .terminal-filter-btn, .tab-btn {
    padding-left: 12px;
    padding-right: 12px;
  }
}

/* ─── Mobile 375px fixes ─── */

@media (max-width: 480px) {
  /* Nav: keep 3 tabs on 1 row, compact */
  .global-product-nav.global-product-nav-unified {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 4px;
    margin-bottom: 16px;
  }
  .global-product-nav.global-product-nav-unified .global-product-link {
    min-height: 44px;
    padding: 10px 6px;
    justify-content: center;
  }
  .global-product-nav.global-product-nav-unified .nav-label {
    font-size: 0.68rem;
  }
  .global-product-nav.global-product-nav-unified .nav-copy {
    display: none;
  }

  /* Page shell: tighter padding */
  body {
    padding: 10px 8px;
  }
  .hub-focused-page {
    width: calc(100% - 8px);
  }
  .hub-focus-shell {
    padding: 14px 12px;
  }

  /* Hub: nav cards stack */
  .hub-nav-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .hub-nav-card {
    padding: 12px;
  }

  /* Hub: game cards vertical */
  .hub-intent-grid-three {
    grid-template-columns: 1fr;
  }
  a.hub-rich-card {
    flex-direction: row;
    align-items: center;
    text-align: left;
    gap: 10px;
  }
  .hub-card-cover {
    height: 80px;
    max-width: 60px;
  }

  /* Index: result rows compact */
  .result-row.result-row-catalog {
    grid-template-columns: 36px minmax(0, 1fr) auto;
    gap: 8px;
    padding: 8px 10px;
  }
  .result-cover,
  .result-cover-placeholder {
    width: 36px;
    height: 48px;
  }
  .result-row.result-row-catalog .result-title {
    font-size: 0.68rem;
  }
  .result-rarity {
    font-size: 0.58rem;
  }

  /* Collection: summary bar 2 columns */
  .collection-summary-hero {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  /* Collection: signal cards 2 columns */
  .cockpit-signals-bar {
    grid-template-columns: repeat(2, 1fr);
  }

  /* Collection: table horizontal scroll */
  .collection-cockpit-main {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  /* Collection: toolbar wrap */
  .collection-toolbar-group {
    flex-wrap: wrap;
  }
  .collection-toolbar-input,
  .collection-toolbar-select {
    min-width: 0;
    flex: 1 1 120px;
  }

  /* Stats: counters 2 columns */
  .stats-overview-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .stats-bar-row {
    grid-template-columns: 80px 1fr 40px;
  }
  .stats-top-row {
    grid-template-columns: 20px 1fr 60px;
  }
  .stats-top-platform {
    display: none;
  }

  /* Consoles: single column */
  .consoles-layout {
    grid-template-columns: 1fr;
  }
  .consoles-sidebar {
    max-height: 35vh;
  }

  /* Breadcrumb: smaller */
  .breadcrumb {
    font-size: 0.6rem;
  }

  /* Boot screen: smaller text */
  .boot-log {
    font-size: 11px;
    padding: 12px;
  }

  /* CRT toggle: hide on mobile to save space */
  .crt-toggle-btn {
    font-size: 0.5rem;
    padding: 2px 5px;
  }

  /* Codec sprites: ensure not cut */
  .codec-avatar img,
  .codec-avatar svg {
    width: 48px;
    height: 48px;
  }

  /* Game-detail prices: stack on narrow screens */
  .detail-hero-price-row {
    flex-wrap: wrap;
    gap: 8px;
  }
  .detail-hero-price-cell:first-child .detail-hero-price-value {
    font-size: 1.2rem;
  }

  /* Movers grid: single column */
  .stats-movers-grid {
    grid-template-columns: 1fr;
  }
}
