/* One twelve-column layout for the Spruce catalogue and its cloned sticky head. */
.articles-table.spruce-catalog-table {
  --catalog-min-width: 1080px;
  --catalog-cell-padding: 8px;
  --catalog-row-height: 38px;
  --catalog-header-height: 40px;
  --catalog-id-width: 11.5%;
  --catalog-title-width: 20.3%;
  --catalog-stage-width: 6.75%;
  --catalog-score-width: 7.6%;
  --catalog-ai-width: 6.75%;
  --catalog-links-width: 6.75%;
  --catalog-images-width: 4.9%;
  width: 100%;
  min-width: var(--catalog-min-width);
  table-layout: fixed;
}

.articles-table.spruce-catalog-table .spruce-col-id { width: var(--catalog-id-width); }
.articles-table.spruce-catalog-table .spruce-col-title { width: var(--catalog-title-width); }
.articles-table.spruce-catalog-table .spruce-col-stage { width: var(--catalog-stage-width); }
.articles-table.spruce-catalog-table .spruce-col-score { width: var(--catalog-score-width); }
.articles-table.spruce-catalog-table .spruce-col-ai { width: var(--catalog-ai-width); }
.articles-table.spruce-catalog-table .spruce-col-links { width: var(--catalog-links-width); }
.articles-table.spruce-catalog-table .spruce-col-images { width: var(--catalog-images-width); }

.articles-table.spruce-catalog-table th,
.articles-table.spruce-catalog-table td {
  width: auto;
  max-width: none;
  padding: var(--catalog-cell-padding);
  text-align: center;
  vertical-align: middle;
  white-space: nowrap;
}

.articles-table.spruce-catalog-table th {
  height: var(--catalog-header-height);
  font-size: 10px;
  letter-spacing: .02em;
  hyphens: none;
}

.articles-table.spruce-catalog-table td { height: var(--catalog-row-height); }
.articles-table.spruce-catalog-table th:nth-child(-n+2),
.articles-table.spruce-catalog-table td:nth-child(-n+2) { text-align: left; }

.articles-table.spruce-catalog-table .article-title,
.articles-table.spruce-catalog-table .article-title a {
  max-width: 100%;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.articles-table.spruce-catalog-table .ocenka0-cell,
.articles-table.spruce-catalog-table .ai-score-cell,
.articles-table.spruce-catalog-table .third-score-cell {
  color: var(--fw-paper);
  font-size: 15px !important;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

/* This legacy, unheaded cell remains in old records; it must not create column 13. */
.articles-table.spruce-catalog-table td[data-label="Ссылка на переделку"] { display: none; }

/* Fixed header is decorative; keep wheel/touch input on the scrolling page. */
.articles-sticky-head, .articles-sticky-head * { pointer-events:none !important; }

/* Tighter gap between article ID and source columns. */
.articles-table.spruce-catalog-table th:first-child,
.articles-table.spruce-catalog-table td:first-child { padding-right: 4px; }
.articles-table.spruce-catalog-table th:nth-child(2),
.articles-table.spruce-catalog-table td:nth-child(2) { padding-left: 4px; }

/* Narrow the ID-to-source gap without clipping long Spruce IDs. */
.articles-table.spruce-catalog-table { --catalog-id-width: 10.5%; }
.articles-table.spruce-catalog-table .spruce-col-id { width: var(--catalog-id-width); }
.articles-table.spruce-catalog-table td.article-number { font-size: 14px; }
.articles-table.spruce-catalog-table th:first-child,
.articles-table.spruce-catalog-table td:first-child { padding-right: 2px; }
.articles-table.spruce-catalog-table th:nth-child(2),
.articles-table.spruce-catalog-table td:nth-child(2) { padding-left: 2px; }

/* Keep article IDs to nine characters and put the source marker beside them. */
.articles-table.spruce-catalog-table col.spruce-col-id { width: calc(9ch + 12px) !important; }
