/*
 * Shared data primitives used by real data surfaces. The internal data view
 * renders the same sources as their named public consumers; it does not host
 * speculative component candidates.
 */
.tp-data-rank {
  color: var(--tpl-ink);
  font-family: var(--tpl-font-body);
  font-size: 18px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  line-height: 1.4;
}

.tp-data-rating {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--tpl-ink);
  font-family: var(--tpl-font-body);
  font-size: 15px;
  font-weight: 500;
  line-height: 24px;
  white-space: nowrap;
}

.tp-data-rating__stars {
  display: inline-flex;
  height: 16px;
  gap: 1px;
}

.tp-data-rating__star {
  position: relative;
  display: block;
  width: 16px;
  height: 16px;
  color: var(--tpl-placeholder);
}

.tp-data-rating__star > .tp-site-icon,
.tp-data-rating__fill > .tp-site-icon { display: block; }

.tp-data-rating__fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 16px;
  overflow: hidden;
  color: var(--tpl-rating);
}

.tp-data-rating__value { font-variant-numeric: tabular-nums; }
.tp-data-rating_missing { color: var(--tpl-ink-muted); font-weight: 400; white-space: normal; }
/* Named text-action treatment; semantics and markup remain with shared Button. */
.tp-site-chrome .tp-site-button_context-data-action.tp-site-button_variant-secondary {
  height: auto;
  min-height: 44px;
  min-width: 44px;
  max-width: 100%;
  padding: 8px 0;
  border: 0;
  background: transparent;
  color: var(--tpl-link);
  font-family: var(--tpl-font-body);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.6;
  text-align: left;
  text-transform: none;
  justify-content: flex-start;
  white-space: normal;
  text-decoration-line: underline;
  text-decoration-color: transparent;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: color var(--tpl-link-transition), text-decoration-color var(--tpl-link-transition);
}

.tp-site-chrome .tp-site-button_context-data-action.tp-site-button_variant-secondary:hover,
.tp-site-chrome .tp-site-button_context-data-action.tp-site-button_variant-secondary:focus-visible {
  background: transparent;
  color: var(--tpl-blue-strong);
  box-shadow: none;
  text-decoration-color: currentColor;
}

.tp-site-chrome .tp-site-button_context-data-action.tp-site-button_variant-secondary:focus-visible {
  outline: 2px solid var(--tpl-blue);
  outline-offset: 3px;
}

/* Structural wait state for the real Ranking table. It reuses `.tpl-table`
   geometry and the existing Locations skeleton sweep; only placeholder
   proportions live here, so loading cannot drift into a second table design. */
.tp-data-ranking-loader,
.tp-data-ranking-loader .tpl-tablewrap { width: 100%; min-width: 0; }
.tp-data-ranking-loader__table { table-layout: fixed; }
.tp-data-ranking-loader__table tbody tr:hover { background: var(--tpl-white); }
/* Locations' 64px content row plus its 1px separator. The shared
   tpl-transition-table wrapper owns the border, radius and placeholder ink. */
.tp-data-ranking-loader__table tbody tr { height: 65px; }
.tp-data-ranking-loader__table .tpl-transition-line { height: 10px; }
.tp-data-ranking-loader__rank { width: 20px; }
.tp-data-ranking-loader__name { width: 72%; }
.tp-data-ranking-loader__location { width: 58%; }
.tp-data-ranking-loader__rating { width: 96px; max-width: 100%; }
.tp-data-ranking-loader__metric { width: 76px; max-width: 100%; }

@media (max-width: 720px) {
  .tp-data-ranking-loader__table tbody tr {
    height: auto;
    min-height: 188px;
  }
}

.tp-data-visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (prefers-reduced-motion: reduce) {
  .tp-site-chrome .tp-site-button_context-data-action { transition: none; }
}
