/* ==========================================================================
   ranking.css - main ranking page only
   Signature device: `.is-unknown` renders an unconfirmed data point as a
   first-class visual state instead of hiding it. The rating's editorial claim
   is that it never fills gaps with guesses, so the gaps are made visible.
   ========================================================================== */

/* --- Hero ---------------------------------------------------------------- */

.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: var(--s8) 0 var(--s7);
  background:
    radial-gradient(120% 90% at 78% -10%, rgba(248, 96, 8, .20), transparent 58%),
    radial-gradient(90% 70% at 8% 4%, rgba(20, 22, 49, .95), transparent 60%),
    radial-gradient(70% 120% at 50% 120%, rgba(216, 72, 0, .10), transparent 62%),
    var(--bg);
  border-bottom: 1px solid var(--border);
}

/* Grain. Depth without another gradient stop. */
.hero__grain {
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: .05;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)'/%3E%3C/svg%3E");
}

.hero__inner { position: relative; }

.hero h1 { max-width: 20ch; margin-bottom: var(--s5); }

.hero__sub {
  max-width: 62ch;
  margin: 0 0 var(--s6);
  font-size: 1.125rem;
  line-height: 1.6;
  color: var(--text-dim);
}

@media (min-width: 768px) {
  .hero { padding: var(--s9) 0 var(--s8); }
  .hero h1 { max-width: 24ch; }
  .hero__sub { font-size: 1.25rem; }
}

/* Anchor rail. Reads as a set of jump targets, not decoration. */
.jump {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s2);
  margin-bottom: var(--s7);
}

.jump__link {
  display: inline-block;
  padding: .4375rem .875rem;
  border: 1px solid var(--border-2);
  border-radius: 999px;
  background: rgba(0, 0, 0, .4);
  color: var(--text-dim);
  font-family: var(--mono);
  font-size: .75rem;
  letter-spacing: .04em;
  transition: color .18s var(--ease), border-color .18s var(--ease),
              transform .18s var(--ease);
}
.jump__link:hover {
  color: var(--text);
  border-color: var(--accent);
  transform: translateY(-1px);
}
.jump__link:active { transform: translateY(0); }

/* Hero layout: the pitch on the left, the actual ranked list on the right.
   The list is the page's thesis and its fastest navigation, not an ornament. */
.hero__top { display: grid; gap: var(--s6); }

@media (min-width: 1024px) {
  .hero__top {
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: var(--s8);
    align-items: start;
  }
  .hero .jump { margin-bottom: 0; }
}

.ranklist {
  padding: var(--s4) var(--s5) var(--s5);
  background: rgba(0, 0, 0, .45);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--lift-1);
}

.ranklist__title {
  margin: 0 0 var(--s3);
  padding-bottom: var(--s3);
  border-bottom: 1px solid var(--border);
  font-family: var(--mono);
  font-size: .6875rem;
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.ranklist ol { list-style: none; margin: 0; padding: 0; }
.ranklist li { margin: 0; }

.ranklist a {
  display: flex;
  align-items: baseline;
  gap: var(--s3);
  padding: .3125rem 0;
  border: 0;
  color: var(--text-dim);
  font-size: .875rem;
  font-weight: 500;
  transition: color .18s var(--ease), transform .18s var(--ease);
}
.ranklist a:hover { color: var(--text); transform: translateX(3px); }
.ranklist a:active { color: var(--accent-lt); }

.ranklist__n {
  flex: 0 0 auto;
  font-family: var(--mono);
  font-size: .75rem;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.hero__stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  margin: var(--s7) 0 0;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.hero__stats > div {
  padding: var(--s4) var(--s5);
  background: var(--surface);
}

.hero__stats dt {
  font-family: var(--mono);
  font-size: .6875rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: var(--s2);
}

.hero__stats dd {
  margin: 0;
  font-family: var(--mono);
  font-size: 1.5rem;
  font-weight: 500;
  letter-spacing: -.02em;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

@media (min-width: 768px) {
  .hero__stats { grid-template-columns: repeat(4, 1fr); }
  .hero__stats dd { font-size: 1.875rem; }
}

/* --- Split section head -------------------------------------------------- */

.section__head--split { display: grid; gap: var(--s4); }
.section__head--split h2 { margin-bottom: 0; }

@media (min-width: 768px) {
  .section__head--split {
    grid-template-columns: 1fr 1fr;
    gap: var(--s7);
    align-items: end;
  }
  .section__head--split p { max-width: 46ch; }
}

/* --- Criteria grid ------------------------------------------------------- */

.crit {
  list-style: none;
  display: grid;
  gap: var(--s4);
  margin: 0 0 var(--s7);
  padding: 0;
}

@media (min-width: 768px) {
  .crit { grid-template-columns: repeat(3, 1fr); gap: var(--s5); }
}

.crit__item {
  margin: 0;
  display: flex;
  flex-direction: column;
  padding: var(--s5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--lift-1);
  transition: transform .22s var(--ease), border-color .22s var(--ease),
              box-shadow .22s var(--ease);
}
.crit__item:hover {
  transform: translateY(-3px);
  border-color: var(--border-2);
  box-shadow: var(--lift-2);
}

.crit__weight {
  margin: 0 0 var(--s3);
  font-family: var(--mono);
  font-size: 2.25rem;
  font-weight: 500;
  line-height: 1;
  letter-spacing: -.04em;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}
.crit__weight span { font-size: 1.375rem; opacity: .55; letter-spacing: -.02em; }

.crit__name {
  font-size: 1.0625rem;
  font-weight: 650;
  letter-spacing: -.015em;
  line-height: 1.35;
  margin: 0 0 var(--s3);
}

.crit__desc {
  margin: 0 0 var(--s4);
  font-size: .9375rem;
  line-height: 1.6;
  color: var(--text-dim);
}

/* Weight rendered as a bar, relative to the heaviest criterion (25%). */
.crit__bar {
  margin: auto 0 0; /* pin to the card floor so the row reads as one scale */
  height: 3px;
  border-radius: 2px;
  background: var(--border-2);
  overflow: hidden;
}
.crit__bar span {
  display: block;
  height: 100%;
  border-radius: 2px;
  background: linear-gradient(to right, var(--accent-deep), var(--accent-lt));
}

.crit__note { padding-left: 0; padding-right: 0; }
.crit__note p { color: var(--text-dim); }
.crit__note p:last-child { margin-bottom: 0; }

@media (min-width: 768px) {
  .crit__note { margin: 0; }
}

/* --- Comparison table ---------------------------------------------------- */

.cmp { min-width: 940px; }
.cmp__rank { width: 36px; min-width: 36px; text-align: center; color: var(--text-faint); }
.cmp__name { min-width: 160px; }
.cmp thead .cmp__rank { text-align: center; }
.cmp tbody th a { border-bottom-color: transparent; font-weight: 600; }
.cmp tbody th a:hover { border-bottom-color: var(--accent); }
.cmp td { color: var(--text-dim); }

/* The signature state, in table form. */
.is-unknown {
  color: var(--text-faint);
  font-family: var(--mono);
  font-size: .8125rem;
}

td.is-unknown::before {
  content: "";
  display: inline-block;
  width: 10px;
  height: 1px;
  margin-right: .4375rem;
  vertical-align: middle;
  background: var(--text-faint);
}

/* Only surfaced where the table actually overflows. */
.scroll-hint {
  display: block;
  margin: var(--s3) 0 0;
  text-transform: none;
  letter-spacing: .02em;
  color: var(--text-faint);
}
.scroll-hint::after { content: " →"; }

@media (min-width: 1024px) {
  .scroll-hint { display: none; }
}

.table-note {
  display: block;
  margin: var(--s4) 0 0;
  text-transform: none;
  letter-spacing: .01em;
  line-height: 1.6;
}

/* --- Operator cards ------------------------------------------------------ */

.op {
  position: relative;
  margin-bottom: var(--s6);
  padding: var(--s5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--lift-1);
  scroll-margin-top: 84px;
  transition: border-color .22s var(--ease), box-shadow .22s var(--ease);
}
.op:hover { border-color: var(--border-2); box-shadow: var(--lift-2); }
.op:last-child { margin-bottom: 0; }

@media (min-width: 768px) {
  .op { padding: var(--s6) var(--s7); margin-bottom: var(--s7); }
}

.op__head {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--s2) var(--s4);
  align-items: start;
  padding-bottom: var(--s5);
  margin-bottom: var(--s5);
  border-bottom: 1px solid var(--border);
}

/* Oversized mono numeral. The rank is information, so it gets the weight. */
.op__rank {
  grid-row: span 2;
  margin: 0;
  font-family: var(--mono);
  font-size: 2.5rem;
  font-weight: 500;
  line-height: .9;
  letter-spacing: -.06em;
  color: transparent;
  -webkit-text-stroke: 1px var(--accent);
  font-variant-numeric: tabular-nums;
}

.op__id { min-width: 0; }
.op__name { margin: 0 0 var(--s1); font-size: 1.375rem; }

.op__tag {
  margin: 0;
  font-family: var(--mono);
  font-size: .75rem;
  letter-spacing: .04em;
  color: var(--text-faint);
}

.op__link {
  grid-column: 2;
  justify-self: start;
  font-family: var(--mono);
  font-size: .8125rem;
  letter-spacing: .02em;
}
.op__link::after { content: " ↗"; }

@media (min-width: 768px) {
  .op__head {
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: var(--s5);
  }
  .op__rank { grid-row: auto; font-size: 3.25rem; }
  .op__link { grid-column: auto; justify-self: end; }
}

/* Screenshot. Cropped to a wide band so the card stays scannable. */
.op__shot { margin: 0 0 var(--s5); }

.op__shot img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1280 / 560; /* sized so the tallest hero headline still fits uncut */
  object-fit: cover;
  object-position: center top;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-2);
}

/* Fact chips. Confirmed vs unconfirmed, at a glance. */
.facts {
  list-style: none;
  display: grid;
  gap: var(--s3);
  margin: 0 0 var(--s5);
  padding: 0;
}

@media (min-width: 600px) {
  .facts { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 900px) {
  .facts { grid-template-columns: repeat(4, 1fr); }
}

.fact {
  margin: 0;
  padding: var(--s3) var(--s4);
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}

.fact__k {
  display: block;
  font-family: var(--mono);
  font-size: .625rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: var(--s1);
}

.fact__v {
  display: block;
  font-size: .875rem;
  font-weight: 550;
  line-height: 1.4;
  color: var(--text);
}

/* Signature state: a dashed, unfilled chip. Absence is designed, not hidden. */
.fact:has(.is-unknown) {
  background: transparent;
  border-style: dashed;
  border-color: var(--border-2);
}

.fact .fact__v.is-unknown {
  font-family: var(--mono);
  font-size: .75rem;
  font-weight: 400;
  color: var(--text-faint);
}

.op__body > p { max-width: 74ch; }

.op__cols { display: grid; gap: var(--s5); margin: var(--s5) 0; }

@media (min-width: 768px) {
  .op__cols { grid-template-columns: 1fr 1fr; gap: var(--s7); }
}

.op__col h4 {
  font-family: var(--mono);
  font-size: .6875rem;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 var(--s3);
}
.op__col h4 + h4,
.op__col p + h4,
.op__col ul + h4 { margin-top: var(--s5); }
.op__col ul { padding-left: 1.15rem; margin-bottom: 0; }
.op__col li, .op__col p { font-size: .9375rem; line-height: 1.6; color: var(--text-dim); }
.op__col p { margin-bottom: 0; }

.op__services {
  margin: 0;
  padding-top: var(--s4);
  border-top: 1px solid var(--border);
  font-size: .875rem;
  line-height: 1.7;
  color: var(--text-dim);
}
.op__services .stamp {
  margin-right: var(--s3);
  color: var(--accent);
}

/* --- Trends -------------------------------------------------------------- */

.trend { display: grid; gap: var(--s4); }

@media (min-width: 768px) {
  .trend { grid-template-columns: repeat(2, 1fr); gap: var(--s5); }
}

.trend__card {
  position: relative;
  padding: var(--s5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--lift-1);
  transition: transform .22s var(--ease), box-shadow .22s var(--ease);
}
.trend__card:hover { transform: translateY(-3px); box-shadow: var(--lift-2); }

.trend__num {
  margin: 0 0 var(--s3);
  font-family: var(--mono);
  font-size: .75rem;
  letter-spacing: .14em;
  color: var(--accent);
}

.trend__card h3 { font-size: 1.1875rem; margin-bottom: var(--s3); }
.trend__card p { font-size: .9375rem; line-height: 1.65; color: var(--text-dim); }

.trend__who {
  margin: var(--s4) 0 0;
  padding-top: var(--s4);
  border-top: 1px solid var(--border);
  font-size: .875rem;
}
.trend__who .stamp { display: block; margin-bottom: var(--s1); color: var(--accent); }

/* --- Checklist ----------------------------------------------------------- */

.check {
  list-style: none;
  counter-reset: check;
  margin: 0 0 var(--s6);
  padding: 0;
}

.check > li {
  counter-increment: check;
  position: relative;
  margin: 0;
  padding: var(--s4) 0 var(--s4) 3.25rem;
  border-bottom: 1px solid var(--border);
}
.check > li:last-child { border-bottom: 0; }

.check > li::before {
  content: counter(check, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: var(--s4);
  font-family: var(--mono);
  font-size: .875rem;
  font-weight: 500;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.check h3 {
  font-size: 1.0625rem;
  font-weight: 650;
  letter-spacing: -.012em;
  line-height: 1.4;
  margin: 0 0 var(--s2);
}
.check p { margin: 0; font-size: .9375rem; line-height: 1.6; color: var(--text-dim); }

/* --- FAQ ----------------------------------------------------------------- */

.faq { margin-bottom: var(--s6); }

.faq details {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  margin-bottom: var(--s3);
  transition: border-color .18s var(--ease);
}
.faq details:hover { border-color: var(--border-2); }
.faq details[open] { border-color: var(--border-2); background: var(--surface-2); }

.faq summary {
  cursor: pointer;
  list-style: none;
  padding: var(--s4) var(--s5);
  padding-right: 3rem;
  position: relative;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: -.012em;
  color: var(--text);
}
.faq summary::-webkit-details-marker { display: none; }

.faq summary::after {
  content: "";
  position: absolute;
  right: var(--s5);
  top: 50%;
  width: 9px;
  height: 9px;
  margin-top: -5px;
  border-right: 1.5px solid var(--accent);
  border-bottom: 1.5px solid var(--accent);
  transform: rotate(45deg);
  transition: transform .22s var(--ease);
}
.faq details[open] summary::after { transform: rotate(-135deg); }

.faq__body {
  padding: 0 var(--s5) var(--s5);
  border-top: 1px solid var(--border);
  padding-top: var(--s4);
  margin-top: 0;
}
.faq__body p { margin: 0; color: var(--text-dim); font-size: .9375rem; line-height: 1.7; }

/* --- CTA ----------------------------------------------------------------- */

.cta {
  display: grid;
  gap: var(--s5);
  padding: var(--s6);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(90% 140% at 100% 0%, rgba(248, 96, 8, .12), transparent 62%),
    var(--surface);
  box-shadow: var(--lift-1);
}
.cta h2 { font-size: clamp(1.375rem, 3.4vw, 1.875rem); }
.cta p { color: var(--text-dim); margin-bottom: 0; }
.cta__action { margin: 0; }

@media (min-width: 768px) {
  .cta {
    grid-template-columns: 1fr auto;
    gap: var(--s7);
    align-items: center;
    padding: var(--s7);
  }
  .cta p { max-width: 62ch; }
}

/* --- Disclosure ---------------------------------------------------------- */

.disclosure { border-top: 1px solid var(--border); }
.disclosure p { font-size: .9375rem; color: var(--text-faint); }
.disclosure a { color: var(--text-dim); }
.disclosure a:hover { color: var(--accent-lt); }

/* A question promoted to <h2> inside <summary> for document structure must not
   inherit the section-heading scale or the prose top border. */
.faq summary h2 {
  display: inline;
  margin: 0;
  padding: 0;
  border: 0;
  font: inherit;
  letter-spacing: inherit;
  color: inherit;
  text-wrap: inherit;
}
