/* Ranking10x — ranking10x.in
   Design language: editorial dossier. Paper + ink, hairline rules, numbered
   sections, small-caps labels, asymmetric two-column reading layout.
   Type: Zodiak (serif display) + Switzer (sans body). No JS frameworks. */

:root {
  --paper:      #FBF9F5;
  --paper-2:    #F3F0E9;
  --paper-3:    #EAE6DC;
  --ink:        #17140F;
  --ink-2:      #45403A;
  --ink-3:      #746D63;
  --rule:       #DDD7CA;
  --rule-soft:  #E8E3D8;
  --accent:     #A63D16;
  --accent-2:   #7E2E10;
  --accent-bg:  #F6EBE4;

  --serif: 'Zodiak', 'Iowan Old Style', Georgia, 'Times New Roman', serif;
  --sans:  'Switzer', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  --mono:  ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;

  --wrap: 1180px;
  --gutter: clamp(20px, 4vw, 56px);
  --rhythm: clamp(56px, 8vw, 104px);
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper:     #111010;
    --paper-2:   #191817;
    --paper-3:   #211F1D;
    --ink:       #F2EFE9;
    --ink-2:     #C4BEB4;
    --ink-3:     #8F887E;
    --rule:      #2E2B28;
    --rule-soft: #232120;
    --accent:    #E0794C;
    --accent-2:  #F0A07B;
    --accent-bg: #241B16;
  }
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 96px; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.62;
  font-feature-settings: 'ss01', 'cv01';
  -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; height: auto; display: block; }

a { color: inherit; }
a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--ink); color: var(--paper);
  padding: 12px 18px; font-size: 14px; text-decoration: none;
}
.skip:focus { left: 12px; top: 12px; }

/* ---------------------------------------------------------------- type --- */

h1, h2, h3, h4 { font-family: var(--serif); font-weight: 700; margin: 0; letter-spacing: -0.015em; }

h1 {
  font-size: clamp(38px, 6.2vw, 68px);
  line-height: 1.03;
  letter-spacing: -0.032em;
}
h2 { font-size: clamp(27px, 3.4vw, 38px); line-height: 1.12; }
h3 { font-size: clamp(19px, 2vw, 22px); line-height: 1.25; letter-spacing: -0.008em; }

p { margin: 0 0 1.05em; }
p:last-child { margin-bottom: 0; }

.lede {
  font-size: clamp(18px, 2.1vw, 22px);
  line-height: 1.5;
  color: var(--ink-2);
  max-width: 62ch;
}

.prose { max-width: 68ch; }
.prose a { color: var(--accent); text-decoration: none; border-bottom: 1px solid color-mix(in srgb, var(--accent) 35%, transparent); }
.prose a:hover { border-bottom-color: var(--accent); }

.label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 0;
}

.accent { color: var(--accent); }
em.mark { font-style: normal; color: var(--accent); }

/* ------------------------------------------------------------- chrome ---- */

.masthead {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: saturate(150%) blur(12px);
  border-bottom: 1px solid var(--rule);
}
.masthead .wrap {
  display: flex; align-items: center; gap: 24px;
  min-height: 68px;
}

.brand { display: flex; align-items: baseline; gap: 10px; text-decoration: none; margin-right: auto; }
.brand b {
  font-family: var(--serif); font-weight: 700; font-size: 21px;
  letter-spacing: -0.02em;
}
.brand span {
  font-family: var(--mono); font-size: 10px; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--ink-3);
}

.nav { display: flex; align-items: center; gap: 4px; }
.nav a {
  text-decoration: none; font-size: 14.5px; font-weight: 500;
  color: var(--ink-2); padding: 8px 12px; border-radius: 4px;
  transition: color .15s ease, background .15s ease;
}
.nav a:hover { color: var(--ink); background: var(--paper-2); }
.nav a[aria-current="page"] { color: var(--ink); }
.nav a[aria-current="page"]::after {
  content: ''; display: block; height: 2px; margin-top: 4px;
  background: var(--accent); border-radius: 2px;
}

.nav-toggle {
  display: none; background: none; border: 1px solid var(--rule);
  border-radius: 5px; padding: 8px; cursor: pointer; color: var(--ink);
}
.nav-toggle svg { width: 20px; height: 20px; stroke: currentColor; fill: none; stroke-width: 1.7; }

@media (max-width: 760px) {
  .nav-toggle { display: block; }
  .nav {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--paper); border-bottom: 1px solid var(--rule);
    padding: 8px var(--gutter) 16px;
  }
  /* Collapsed by default on mobile — a class, not [hidden], so the menu is
     hidden before JS runs and stays in the a11y tree correctly on desktop. */
  .nav:not(.is-open) { display: none; }
  .nav a { padding: 12px 0; border-bottom: 1px solid var(--rule-soft); }
  .nav a[aria-current="page"]::after { display: none; }
  .nav a[aria-current="page"] { color: var(--accent); }
}

/* --------------------------------------------------------------- hero ---- */

.hero { padding: clamp(56px, 9vw, 104px) 0 clamp(40px, 6vw, 64px); }
.hero-grid {
  display: grid; gap: clamp(32px, 5vw, 64px);
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  align-items: start;
}
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; } }

.hero .label { margin-bottom: 20px; }
.hero h1 { margin-bottom: 24px; }
.hero h1 em { font-style: italic; color: var(--accent); }

/* --------------------------------------------------- the identity card --- */

.card {
  border: 1px solid var(--rule);
  background: var(--paper-2);
  border-radius: 3px;
  padding: clamp(22px, 3vw, 30px);
}
.card > .label { padding-bottom: 14px; border-bottom: 1px solid var(--rule); margin-bottom: 4px; }

.facts { margin: 0; font-size: 15px; }
.facts div {
  display: grid; grid-template-columns: 116px minmax(0, 1fr);
  gap: 16px; padding: 11px 0; border-bottom: 1px solid var(--rule-soft);
}
.facts div:last-child { border-bottom: 0; padding-bottom: 0; }
.facts dt {
  font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--ink-3); padding-top: 4px;
}
.facts dd { margin: 0; color: var(--ink); }
.facts dd a { color: var(--accent); text-decoration: none; }
.facts dd a:hover { text-decoration: underline; }
@media (max-width: 420px) { .facts div { grid-template-columns: 1fr; gap: 2px; } }

/* ------------------------------------------------------------ sections --- */

.band { border-top: 1px solid var(--rule); padding: var(--rhythm) 0; }
.band.tint { background: var(--paper-2); }

.band-head {
  display: grid; gap: 16px 48px;
  grid-template-columns: 190px minmax(0, 1fr);
  margin-bottom: clamp(32px, 4vw, 48px);
}
@media (max-width: 780px) { .band-head { grid-template-columns: 1fr; } }
.band-head .label { padding-top: 10px; }
.band-head h2 { margin-bottom: 14px; }
.band-head p { color: var(--ink-2); max-width: 60ch; }

/* numbered editorial list — the discipline / process blocks */

.entries { display: grid; gap: 0; border-top: 1px solid var(--rule); }
.entries > * {
  display: grid; gap: 8px 48px;
  grid-template-columns: 190px minmax(0, 1fr);
  padding: clamp(22px, 3vw, 30px) 0;
  border-bottom: 1px solid var(--rule);
}
@media (max-width: 780px) { .entries > * { grid-template-columns: 1fr; gap: 10px; } }

.entries .n {
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.14em;
  color: var(--ink-3); padding-top: 6px;
}
.entries h3 { margin-bottom: 8px; }
.entries p { color: var(--ink-2); max-width: 62ch; font-size: 16px; }
.entries .also {
  font-family: var(--mono); font-size: 12px; color: var(--ink-3);
  margin-top: 10px; line-height: 1.7;
}

/* two-up / three-up plain blocks (no icon-square grid) */

.cols {
  display: grid; gap: clamp(24px, 3vw, 40px);
  grid-template-columns: repeat(auto-fit, minmax(255px, 1fr));
}
.cols > div { border-top: 2px solid var(--ink); padding-top: 18px; }
.cols h3 { margin-bottom: 10px; }
.cols p { color: var(--ink-2); font-size: 15.5px; }

/* tag rows — named tools, markets, entities */

.tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.tags li {
  font-family: var(--mono); font-size: 12.5px; letter-spacing: 0.01em;
  border: 1px solid var(--rule); border-radius: 3px;
  padding: 6px 11px; color: var(--ink-2); background: var(--paper);
}
.tags.strong li { border-color: color-mix(in srgb, var(--accent) 30%, var(--rule)); background: var(--accent-bg); color: var(--accent-2); }

/* pull quote / statement */

.statement {
  font-family: var(--serif); font-size: clamp(23px, 3vw, 32px);
  line-height: 1.28; letter-spacing: -0.018em; max-width: 20ch;
}

/* --------------------------------------------------------------- faq ----- */

.faq { border-top: 1px solid var(--rule); }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary {
  cursor: pointer; list-style: none;
  display: flex; align-items: baseline; gap: 18px;
  padding: 22px 0;
  font-family: var(--serif); font-weight: 700;
  font-size: clamp(18px, 2vw, 21px); letter-spacing: -0.01em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: '+'; margin-left: auto; font-family: var(--mono);
  font-size: 20px; color: var(--accent); line-height: 1;
  transition: transform .18s ease;
}
.faq details[open] summary::after { content: '\2212'; }
.faq summary:hover { color: var(--accent); }
.faq .answer { padding: 0 0 24px; color: var(--ink-2); max-width: 68ch; }
.faq .answer p { font-size: 16px; }
.faq .answer a { color: var(--accent); }

/* --------------------------------------------------------------- cta ----- */

.closer { border-top: 1px solid var(--rule); padding: var(--rhythm) 0; }
.closer-grid {
  display: grid; gap: clamp(28px, 4vw, 56px);
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: end;
}
@media (max-width: 780px) { .closer-grid { grid-template-columns: 1fr; align-items: start; } }

.mail {
  font-family: var(--serif); font-weight: 700;
  font-size: clamp(24px, 3.6vw, 40px); letter-spacing: -0.025em;
  color: var(--accent); text-decoration: none;
  border-bottom: 2px solid color-mix(in srgb, var(--accent) 30%, transparent);
  display: inline-block; word-break: break-word;
  transition: border-color .15s ease;
}
.mail:hover { border-bottom-color: var(--accent); }

.btn {
  display: inline-flex; align-items: center; gap: 9px;
  font-size: 15px; font-weight: 600; text-decoration: none;
  padding: 12px 20px; border-radius: 4px;
  background: var(--ink); color: var(--paper);
  border: 1px solid var(--ink);
  transition: transform .12s ease, opacity .15s ease;
}
.btn:hover { opacity: .88; transform: translateY(-1px); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--rule); }
.btn.ghost:hover { border-color: var(--ink); opacity: 1; }
.btn svg { width: 16px; height: 16px; stroke: currentColor; fill: none; stroke-width: 1.9; }

.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }

/* ------------------------------------------------------------- footer ---- */

.site-foot { border-top: 1px solid var(--rule); background: var(--paper-2); padding: 44px 0 34px; }
.foot-grid {
  display: grid; gap: 28px 48px;
  grid-template-columns: minmax(0, 1.6fr) repeat(2, minmax(0, 1fr));
}
@media (max-width: 780px) { .foot-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .foot-grid { grid-template-columns: 1fr; } }

.foot-grid h4 {
  font-family: var(--mono); font-weight: 400; font-size: 10.5px;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-3);
  margin-bottom: 14px;
}
.foot-grid ul { list-style: none; margin: 0; padding: 0; font-size: 15px; }
.foot-grid li { margin-bottom: 8px; }
.foot-grid a { text-decoration: none; color: var(--ink-2); }
.foot-grid a:hover { color: var(--accent); }
.foot-blurb { font-size: 15px; color: var(--ink-2); max-width: 42ch; }
.foot-blurb b { font-family: var(--serif); font-size: 19px; display: block; margin-bottom: 8px; color: var(--ink); }

.colophon {
  margin-top: 36px; padding-top: 20px; border-top: 1px solid var(--rule);
  display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between;
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.06em;
  color: var(--ink-3);
}

/* ------------------------------------------------------- inner pages ----- */

.page-head { padding: clamp(48px, 7vw, 88px) 0 clamp(30px, 4vw, 44px); }
.page-head .label { margin-bottom: 18px; }
.page-head h1 { margin-bottom: 20px; max-width: 18ch; }

.breadcrumb {
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--ink-3);
  padding-top: 22px;
}
.breadcrumb a { text-decoration: none; color: var(--ink-3); }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb span { margin: 0 8px; opacity: .5; }

.split {
  display: grid; gap: clamp(32px, 5vw, 72px);
  grid-template-columns: 190px minmax(0, 1fr);
  align-items: start;
}
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } }

.rail { position: sticky; top: 96px; }
@media (max-width: 900px) { .rail { position: static; } }
.rail ol { list-style: none; margin: 12px 0 0; padding: 0; }
.rail li { margin-bottom: 2px; }
.rail a {
  display: block; text-decoration: none; font-size: 14px;
  color: var(--ink-3); padding: 5px 0 5px 12px;
  border-left: 2px solid var(--rule);
  transition: color .15s ease, border-color .15s ease;
}
.rail a:hover { color: var(--ink); }
.rail a.on { color: var(--accent); border-left-color: var(--accent); }

.prose h2 { margin: 52px 0 16px; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { margin: 32px 0 10px; }
.prose ul { padding-left: 20px; margin: 0 0 1.1em; }
.prose li { margin-bottom: 7px; color: var(--ink-2); }
.prose li b { color: var(--ink); }
.prose blockquote {
  margin: 28px 0; padding-left: 22px;
  border-left: 2px solid var(--accent);
  font-family: var(--serif); font-size: 20px; line-height: 1.4;
  color: var(--ink);
}
.prose hr { border: 0; border-top: 1px solid var(--rule); margin: 44px 0; }
