/* ==========================================================================
   ONCO-UMBRELLA · estilos
   ========================================================================== */

:root {
  --ink: #14162b;
  --ink-soft: #3d4160;
  --muted: #6d7291;
  --line: #e3e2dc;
  --line-strong: #d2d1c9;
  --paper: #ffffff;
  --canvas: #f7f5f0;
  --canvas-alt: #f1efe8;

  --accent: #3b48a6;
  --accent-dark: #2b3585;
  --accent-soft: #eceef9;
  --accent-tint: #eef0fb;

  --olive: #7d8a3c;
  --amber: #c9a227;
  --clay: #b5651d;
  --rose: #a05a72;

  --good: #3f7a4f;
  --bad: #b0483c;
  --null: #9a9caa;

  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;

  --shadow-xs: 0 1px 2px rgba(20, 22, 43, 0.04);
  --shadow-sm: 0 2px 8px rgba(20, 22, 43, 0.05);
  --shadow: 0 12px 32px -16px rgba(20, 22, 43, 0.22);
  --shadow-lg: 0 30px 70px -34px rgba(20, 22, 43, 0.45);

  --font-display: "Figtree", "Segoe UI", system-ui, sans-serif;
  --font-body: "Inter", "Segoe UI", system-ui, sans-serif;

  --maxw: 1280px;
  --gutter: clamp(18px, 4vw, 40px);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body.is-locked {
  overflow: hidden;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0;
  color: var(--ink);
}

p {
  margin: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  color: inherit;
}

svg {
  display: block;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 50%;
  top: 8px;
  transform: translate(-50%, -160%);
  background: var(--ink);
  color: #fff;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  z-index: 200;
  font-size: 14px;
  transition: transform 0.2s ease;
}

.skip-link:focus-visible {
  transform: translate(-50%, 0);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- Botones ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 10px 20px;
  font-family: var(--font-body);
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: -0.01em;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease,
    transform 0.18s ease, box-shadow 0.18s ease;
}

.btn svg {
  width: 16px;
  height: 16px;
  flex: none;
}

.btn--primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 8px 18px -12px rgba(59, 72, 166, 0.9);
}

.btn--primary:hover {
  background: var(--accent-dark);
  transform: translateY(-1px);
}

.btn--outline {
  background: #fff;
  color: var(--ink);
  border-color: var(--line-strong);
}

.btn--outline:hover {
  border-color: var(--ink);
  background: #fbfaf7;
}

.btn--ghost {
  background: transparent;
  color: var(--ink-soft);
  padding: 9px 14px;
}

.btn--ghost:hover {
  background: rgba(20, 22, 43, 0.05);
  color: var(--ink);
}

.btn--sm {
  padding: 7px 14px;
  font-size: 13.5px;
}

.link-btn {
  background: none;
  border: 0;
  padding: 0;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--accent);
  cursor: pointer;
  border-bottom: 1px solid transparent;
}

.link-btn:hover:not(:disabled) {
  border-color: currentColor;
}

.link-btn:disabled {
  color: var(--muted);
  opacity: 0.55;
  cursor: default;
}

/* ---------- Barra superior ---------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(247, 245, 240, 0.86);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid rgba(20, 22, 43, 0.07);
}

.topbar__inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 12px var(--gutter);
  display: flex;
  align-items: center;
  gap: 28px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: none;
}

.brand__mark {
  width: 34px;
  height: 34px;
  flex: none;
  transition: transform 0.3s ease;
}

.brand:hover .brand__mark {
  transform: rotate(12deg);
}

.brand__text {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 16.5px;
  letter-spacing: -0.02em;
}

.brand__text span {
  color: var(--accent);
  padding: 0 1px;
}

.brand--light .brand__text {
  color: #fff;
}

.brand--light .brand__text span {
  color: #b9c1f3;
}

.nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-right: auto;
}

.nav a {
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 14.5px;
  color: var(--ink-soft);
  transition: background 0.16s ease, color 0.16s ease;
}

.nav a:hover {
  background: rgba(20, 22, 43, 0.05);
  color: var(--ink);
}

.topbar__actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  width: 40px;
  height: 40px;
  padding: 0 9px;
  background: none;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  cursor: pointer;
}

.nav-toggle span:not(.sr-only) {
  display: block;
  height: 1.8px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform 0.22s ease, opacity 0.22s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(5.8px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-5.8px) rotate(-45deg);
}

.mobile-nav {
  display: none;
  flex-direction: column;
  padding: 6px var(--gutter) 18px;
  border-top: 1px solid var(--line);
  background: var(--canvas);
}

.mobile-nav a {
  padding: 12px 4px;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
}

.mobile-nav.is-open {
  display: flex;
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(48px, 8vw, 96px) 0 clamp(56px, 8vw, 92px);
  background:
    radial-gradient(1100px 520px at 82% -12%, rgba(155, 165, 232, 0.45), transparent 62%),
    radial-gradient(760px 420px at 4% 8%, rgba(214, 205, 178, 0.5), transparent 66%),
    linear-gradient(180deg, #fbfaf6 0%, #f7f5f0 58%, #f4f2ec 100%);
  border-bottom: 1px solid rgba(20, 22, 43, 0.06);
}

.hero__glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.55;
  pointer-events: none;
}

.hero__glow--a {
  width: 420px;
  height: 420px;
  right: -80px;
  top: -160px;
  background: rgba(140, 152, 226, 0.55);
}

.hero__glow--b {
  width: 320px;
  height: 320px;
  left: -100px;
  bottom: -140px;
  background: rgba(201, 162, 39, 0.28);
}

.hero__inner {
  position: relative;
  max-width: 940px;
  margin: 0 auto;
  padding: 0 var(--gutter);
  text-align: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 18px;
}

.eyebrow .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(59, 72, 166, 0.12);
  flex: none;
}

.hero__title {
  font-size: clamp(2.2rem, 5.6vw, 3.9rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.06;
  max-width: 20ch;
  margin: 0 auto;
}

.hero__title .hl {
  display: inline;
  color: var(--accent);
  background: linear-gradient(180deg, transparent 64%, rgba(155, 165, 232, 0.32) 64%);
}

.hero__lede {
  max-width: 62ch;
  margin: 22px auto 0;
  font-size: clamp(1rem, 1.6vw, 1.12rem);
  color: var(--ink-soft);
  line-height: 1.65;
}

.hero__lede strong {
  font-weight: 600;
  color: var(--ink);
}

.hero__search {
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 640px;
  margin: 34px auto 0;
  padding: 7px 7px 7px 16px;
  background: #fff;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  box-shadow: var(--shadow);
}

.hero__search > svg {
  width: 19px;
  height: 19px;
  flex: none;
  color: var(--muted);
}

.hero__search input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: none;
  font: inherit;
  font-size: 15px;
  color: var(--ink);
  padding: 8px 0;
}

.hero__search input:focus {
  outline: none;
}

.hero__search input::placeholder {
  color: #9a9cae;
}

.hero__search .btn {
  padding: 11px 22px;
}

.hero__tags {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 18px;
  font-size: 13.5px;
  color: var(--muted);
}

.hero__tags button {
  padding: 5px 13px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.7);
  border-radius: 999px;
  font-size: 13px;
  color: var(--ink-soft);
  cursor: pointer;
  transition: all 0.16s ease;
}

.hero__tags button:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: #fff;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  list-style: none;
  max-width: 880px;
  margin: 52px auto 0;
  padding: 0;
}

.stat {
  padding: 20px 16px 18px;
  background: rgba(255, 255, 255, 0.66);
  border: 1px solid rgba(20, 22, 43, 0.08);
  border-radius: var(--radius);
  backdrop-filter: blur(6px);
}

.stat__value {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.stat__label {
  display: block;
  margin-top: 6px;
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.35;
}

/* ---------- Secciones ---------- */

.section {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(56px, 8vw, 96px) var(--gutter);
}

.section__head {
  max-width: 760px;
  margin-bottom: clamp(28px, 4vw, 44px);
}

.section__head h2,
.method__intro h2,
.cite h2,
.team h2 {
  font-size: clamp(1.65rem, 3.4vw, 2.5rem);
  letter-spacing: -0.03em;
}

.section__lede {
  margin-top: 16px;
  font-size: 15.5px;
  color: var(--ink-soft);
  line-height: 1.68;
  max-width: 68ch;
}

.section__lede strong {
  font-weight: 600;
  color: var(--ink);
}

/* ---------- Base de datos ---------- */

.section--wide {
  max-width: 1440px;
  padding-left: clamp(12px, 2vw, 24px);
  padding-right: clamp(12px, 2vw, 24px);
}

.db {
  display: grid;
  grid-template-columns: 258px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}

.filters {
  position: sticky;
  top: 84px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 20px 18px;
  box-shadow: var(--shadow-xs);
  max-height: calc(100vh - 108px);
  overflow-y: auto;
  scrollbar-width: thin;
}

.filters__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
}

.filters__head h3 {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.filter-search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--canvas);
  margin-bottom: 16px;
}

.filter-search svg {
  width: 15px;
  height: 15px;
  color: var(--muted);
  flex: none;
}

.filter-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: none;
  font: inherit;
  font-size: 13.5px;
  padding: 2px 0;
}

.filter-search input:focus {
  outline: none;
}

.filter-group {
  border-top: 1px solid var(--line);
  padding: 4px 0;
}

.filter-group__toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 11px 2px;
  background: none;
  border: 0;
  text-align: left;
  cursor: pointer;
  font-size: 13.5px;
  font-weight: 600;
  letter-spacing: -0.005em;
  color: var(--ink);
}

.filter-group__toggle svg {
  width: 11px;
  height: 11px;
  margin-left: auto;
  color: var(--muted);
  transition: transform 0.2s ease;
  flex: none;
}

.filter-group__toggle[aria-expanded="true"] svg {
  transform: rotate(90deg);
}

.filter-group__count {
  font-size: 11.5px;
  font-weight: 500;
  color: var(--muted);
  background: var(--canvas-alt);
  border-radius: 999px;
  padding: 1px 7px;
}

.filter-group__body {
  padding: 2px 0 12px;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.filter-group__body[hidden] {
  display: none;
}

.filter-option {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 6px 6px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 13.5px;
  color: var(--ink-soft);
  transition: background 0.14s ease;
  line-height: 1.4;
}

.filter-option:hover {
  background: var(--canvas);
}

.filter-option input {
  appearance: none;
  width: 15px;
  height: 15px;
  flex: none;
  margin: 0;
  border: 1.5px solid var(--line-strong);
  border-radius: 4px;
  background: #fff;
  cursor: pointer;
  position: relative;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.filter-option input:checked {
  background: var(--accent);
  border-color: var(--accent);
}

.filter-option input:checked::after {
  content: "";
  position: absolute;
  left: 4px;
  top: 1px;
  width: 4px;
  height: 8px;
  border: solid #fff;
  border-width: 0 1.8px 1.8px 0;
  transform: rotate(42deg);
}

.filter-option.is-empty {
  opacity: 0.45;
}

.filter-option__label {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.filter-option__n {
  font-size: 11.5px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  flex: none;
}

.filter-option__swatch {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex: none;
}

.filters__note {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: 11.5px;
  line-height: 1.55;
  color: var(--muted);
}

.filters__note strong {
  color: var(--ink-soft);
}

.db__main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* ---------- Tarjetas resumen ---------- */

.overview {
  display: grid;
  grid-template-columns: 1.15fr 1fr 1fr;
  gap: 16px;
}

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 18px 20px 20px;
  box-shadow: var(--shadow-xs);
  min-width: 0;
}

.card__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 16px;
}

.card__head h3 {
  font-size: 13.5px;
  font-weight: 600;
  letter-spacing: -0.005em;
}

.card__hint {
  font-size: 11.5px;
  color: var(--muted);
  white-space: nowrap;
}

.donut-wrap {
  display: flex;
  align-items: center;
  gap: 18px;
}

.donut {
  width: 116px;
  height: 116px;
  flex: none;
  transform: rotate(-90deg);
}

.donut circle {
  fill: none;
  stroke-width: 3.6;
  transition: stroke-opacity 0.18s ease, stroke-width 0.18s ease;
}

.donut circle:hover {
  stroke-opacity: 0.78;
  stroke-width: 4.6;
}

.donut-legend {
  list-style: none;
  margin: 0;
  padding: 0;
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 12px;
}

.donut-legend li {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--ink-soft);
  line-height: 1.3;
}

.donut-legend i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex: none;
}

.donut-legend span {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.donut-legend b {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  flex: none;
}

.stack {
  display: flex;
  height: 10px;
  border-radius: 999px;
  overflow: hidden;
  gap: 2px;
  background: var(--canvas-alt);
  margin-bottom: 14px;
}

.stack__seg {
  height: 100%;
  border-radius: 999px;
  transition: flex-grow 0.3s ease;
}

.bar-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.bar-list li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--ink-soft);
}

.bar-list i {
  width: 7px;
  height: 7px;
  border-radius: 2px;
  flex: none;
}

.bar-list span {
  flex: 1;
  min-width: 0;
}

.bar-list em {
  font-style: normal;
  color: var(--muted);
  font-size: 11.5px;
  font-variant-numeric: tabular-nums;
}

.bar-list b {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  min-width: 42px;
  text-align: right;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: #fff;
  font-size: 12.5px;
  color: var(--ink-soft);
  cursor: pointer;
  transition: all 0.16s ease;
  max-width: 100%;
  min-width: 0;
}

.chip span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}

.chip b {
  font-weight: 600;
  font-size: 11.5px;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.chip:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-tint);
}

/* ---------- Tabla ---------- */

.table-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
  overflow: hidden;
}

.toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
}

.toolbar__left h3 {
  font-size: 17px;
  letter-spacing: -0.015em;
}

.toolbar__meta {
  margin-top: 3px;
  font-size: 12.5px;
  color: var(--muted);
}

.toolbar__right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.select {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12.5px;
  color: var(--muted);
}

.select select {
  font: inherit;
  font-size: 13px;
  color: var(--ink);
  padding: 7px 10px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: #fff;
  cursor: pointer;
}

.active-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 11px 20px;
  border-bottom: 1px solid var(--line);
  background: var(--canvas);
}

.active-filters__label {
  font-size: 12px;
  color: var(--muted);
  margin-right: 2px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 6px 3px 11px;
  border-radius: 999px;
  background: var(--accent-tint);
  color: var(--accent-dark);
  font-size: 12px;
  border: 1px solid rgba(59, 72, 166, 0.16);
}

.pill button {
  display: grid;
  place-items: center;
  width: 17px;
  height: 17px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(59, 72, 166, 0.12);
  cursor: pointer;
  color: inherit;
  font-size: 13px;
  line-height: 1;
}

.pill button:hover {
  background: rgba(59, 72, 166, 0.28);
}

.table-scroll {
  overflow-x: auto;
  scrollbar-width: thin;
}

.table {
  width: 100%;
  min-width: 900px;
  table-layout: fixed;
  border-collapse: collapse;
  font-size: 13px;
}

.col-review { width: 12%; }
.col-site { width: 10.5%; }
.col-exposure { width: 13%; }
.col-outcome { width: 12%; }
.col-studies { width: 6.5%; }
.col-participants { width: 9.5%; }
.col-effect { width: 14.5%; }
.col-grade { width: 9%; }
.col-amstar { width: 7%; }
.col-detail { width: 5.5%; }

.table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #fbfaf7;
  border-bottom: 1px solid var(--line);
  padding: 11px 10px;
  text-align: left;
  font-size: 10.5px;
  font-weight: 600;
    letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
    white-space: normal;
}

.table thead th.num {
  text-align: right;
}

.table tbody td {
  padding: 12px 10px;
  border-bottom: 1px solid #f0efe9;
  vertical-align: top;
  color: var(--ink-soft);
}

.table tbody tr {
  transition: background 0.12s ease;
}

.table tbody tr:hover {
  background: #fbfaf7;
}

.table tbody tr.is-open {
  background: var(--accent-tint);
}

.cell-review {
  min-width: 0;
}

.cell-review b {
  display: block;
  font-weight: 600;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.35;
}

.cell-review span {
  display: block;
  margin-top: 3px;
  font-size: 11.5px;
  color: var(--muted);
  line-height: 1.3;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11.5px;
  line-height: 1.7;
  background: var(--canvas-alt);
  color: var(--ink-soft);
  white-space: nowrap;
  max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tag i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex: none;
}

.tag--phase {
  background: #f2f1ea;
  color: #5a5c4a;
  font-size: 11px;
  font-weight: 400;
}

.cell-exposure {
  font-weight: 500;
  color: var(--ink);
}

.cell-exposure small {
  display: block;
  font-weight: 400;
  font-size: 11.5px;
  color: var(--muted);
  margin-top: 2px;
}

.cell-outcome {
  min-width: 0;
}

.cell-num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  color: var(--ink);
}

.effect {
  min-width: 0;
}

.effect__top {
  display: flex;
  align-items: baseline;
  gap: 5px;
  margin-bottom: 5px;
  flex-wrap: wrap;
}

.effect__value {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.effect__ci {
  font-size: 10.5px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.effect__bar {
  position: relative;
  height: 6px;
  border-radius: 999px;
  background: #efeee8;
  overflow: hidden;
}

.effect__null {
  position: absolute;
  top: -1px;
  bottom: -1px;
  width: 1px;
  background: rgba(20, 22, 43, 0.28);
}

.effect__point {
  position: absolute;
  top: 50%;
  width: 7px;
  height: 7px;
  margin-left: -3.5px;
  border-radius: 50%;
  background: #fff;
  border: 1.5px solid rgba(20, 22, 43, 0.55);
  transform: translateY(-50%);
}

.effect__fill {
  position: absolute;
  top: 0;
  bottom: 0;
  border-radius: 999px;
}

.effect__fill--good {
  background: linear-gradient(90deg, #6aa07a, var(--good));
}

.effect__fill--bad {
  background: linear-gradient(90deg, #cf7d72, var(--bad));
}

.effect__fill--null {
  background: var(--null);
}

.cell-grade {
  white-space: nowrap;
}

.grade {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: var(--ink-soft);
  min-width: 0;
  max-width: 100%;
}

.grade > span:first-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.grade__dots {
  display: inline-flex;
  gap: 2px;
  flex: none;
}

.grade__dots i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--line-strong);
}

.grade__dots i.on {
  background: var(--accent);
}

.grade--low .grade__dots i.on {
  background: var(--amber);
}

.grade--verylow .grade__dots i.on {
  background: var(--bad);
}

.amstar {
  display: inline-flex;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.amstar--alta {
  background: rgba(63, 122, 79, 0.1);
  color: #2f6b41;
}

.amstar--moderada {
  background: rgba(201, 162, 39, 0.14);
  color: #8a6d10;
}

.amstar--baja {
  background: rgba(176, 72, 60, 0.1);
  color: #9c3f35;
}

.btn-row {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: #fff;
  font-size: 12px;
  font-weight: 500;
  color: var(--ink-soft);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.16s ease;
}

.btn-row:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-tint);
}

.btn-row svg {
  width: 12px;
  height: 12px;
}

.icon-row {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: #fff;
  color: var(--ink-soft);
  cursor: pointer;
  transition: all 0.16s ease;
}

.icon-row svg {
  width: 11px;
  height: 11px;
}

.icon-row:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-tint);
}

.empty {
  padding: 56px 24px;
  text-align: center;
}

.empty h4 {
  font-size: 16px;
  margin-bottom: 6px;
}

.empty p {
  font-size: 13.5px;
  color: var(--muted);
  max-width: 42ch;
  margin: 0 auto 18px;
}

.table-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
  padding: 14px 20px;
  border-top: 1px solid var(--line);
  background: #fbfaf7;
}

.table-legend {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 11.5px;
  color: var(--muted);
}

.legend-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
}

.legend-dot--good {
  background: var(--good);
}

.legend-dot--bad {
  background: var(--bad);
}

.legend-dot--null {
  background: var(--null);
}

.pagination {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}

.pagination button {
  min-width: 32px;
  height: 32px;
  padding: 0 9px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: #fff;
  font-size: 13px;
  color: var(--ink-soft);
  cursor: pointer;
  font-variant-numeric: tabular-nums;
  transition: all 0.14s ease;
}

.pagination button:hover:not(:disabled) {
  border-color: var(--accent);
  color: var(--accent);
}

.pagination button[aria-current="page"] {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  font-weight: 500;
}

.pagination button:disabled {
  opacity: 0.4;
  cursor: default;
}

.pagination .gap {
  padding: 0 3px;
  color: var(--muted);
  font-size: 13px;
}

/* ---------- Drawer ---------- */

.backdrop {
  position: fixed;
  inset: 0;
  background: rgba(20, 22, 43, 0.42);
  backdrop-filter: blur(2px);
  z-index: 90;
  opacity: 0;
  transition: opacity 0.24s ease;
}

.backdrop.is-visible {
  opacity: 1;
}

.drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(560px, 100%);
  background: var(--canvas);
  z-index: 100;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
  transform: translateX(100%);
  transition: transform 0.32s cubic-bezier(0.32, 0.72, 0, 1);
  overflow: hidden;
}

.drawer.is-open {
  transform: translateX(0);
}

.drawer__head {
  position: relative;
  padding: 26px 28px 22px;
  background: #fff;
  border-bottom: 1px solid var(--line);
}

.drawer__eyebrow {
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 9px;
}

.drawer__head h2 {
  font-size: 1.32rem;
  line-height: 1.28;
  letter-spacing: -0.02em;
  padding-right: 40px;
}

.icon-btn {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: #fff;
  cursor: pointer;
  color: var(--ink-soft);
}

.icon-btn svg {
  width: 15px;
  height: 15px;
}

.icon-btn:hover {
  background: var(--canvas);
  color: var(--ink);
}

.drawer__head .icon-btn {
  position: absolute;
  top: 22px;
  right: 22px;
}

.drawer__body {
  padding: 24px 28px 40px;
  overflow-y: auto;
  flex: 1;
}

.drawer__section + .drawer__section {
  margin-top: 26px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.drawer__section h3 {
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 12px;
}

.drawer__meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 18px;
}

.meta-item dt {
  font-size: 11.5px;
  color: var(--muted);
  margin-bottom: 3px;
}

.meta-item dd {
  margin: 0;
  font-size: 13.5px;
  color: var(--ink);
  font-weight: 500;
  line-height: 1.45;
}

.drawer__review {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
}

.drawer__review p {
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--ink-soft);
}

.drawer__review .src {
  margin-top: 8px;
  font-size: 12.5px;
  color: var(--muted);
  font-style: italic;
}

.effect-big {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
}

.effect-big__row {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.effect-big__value {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.effect-big__metric {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.effect-big__ci {
  margin-top: 7px;
  font-size: 12.5px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.ci-scale {
  margin-top: 16px;
  position: relative;
  height: 34px;
}

.ci-scale__axis {
  position: absolute;
  left: 0;
  right: 0;
  top: 16px;
  height: 1px;
  background: var(--line-strong);
}

.ci-scale__tick {
  position: absolute;
  top: 11px;
  width: 1px;
  height: 11px;
  background: var(--line-strong);
}

.ci-scale__null {
  position: absolute;
  top: 4px;
  bottom: 0;
  width: 1px;
  background: var(--ink);
  opacity: 0.35;
}

.ci-scale__band {
  position: absolute;
  top: 13px;
  height: 7px;
  border-radius: 999px;
  background: rgba(59, 72, 166, 0.28);
}

.ci-scale__point {
  position: absolute;
  top: 10px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: var(--accent);
  border: 2.5px solid #fff;
  box-shadow: 0 0 0 1px rgba(59, 72, 166, 0.35);
  transform: translateX(-50%);
}

.ci-scale__labels {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  justify-content: space-between;
  font-size: 10.5px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.interpretation {
  border-left: 2.5px solid var(--accent);
  padding: 2px 0 2px 14px;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--ink-soft);
}

.interpretation strong {
  color: var(--ink);
  font-weight: 600;
}

.quality-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.quality {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 16px;
}

.quality dt {
  font-size: 11px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
}

.quality dd {
  margin: 0;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink);
}

.quality dd small {
  display: block;
  font-weight: 400;
  font-size: 11.5px;
  color: var(--muted);
  margin-top: 3px;
  line-height: 1.4;
}

.sibling-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
}

.sibling-list li + li {
  border-top: 1px solid var(--line);
}

.sibling-list button {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 11px 15px;
  background: none;
  border: 0;
  text-align: left;
  font-size: 13px;
  color: var(--ink-soft);
  cursor: pointer;
}

.sibling-list button:hover {
  background: var(--canvas);
  color: var(--ink);
}

.sibling-list button.is-current {
  background: var(--accent-tint);
  color: var(--accent-dark);
  font-weight: 500;
}

.sibling-list .nm {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sibling-list .ef {
  font-variant-numeric: tabular-nums;
  font-size: 12px;
  color: var(--muted);
  flex: none;
}

/* ---------- Metodología ---------- */

.section--method {
  max-width: none;
  padding-left: 0;
  padding-right: 0;
  background: #fff;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.method {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(28px, 5vw, 64px);
  align-items: start;
}

.method__intro {
  position: sticky;
  top: 104px;
}

.method__intro .btn {
  margin-top: 24px;
}

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 14px;
}

.step {
  position: relative;
  padding: 24px 26px 26px;
  background: var(--canvas);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  transition: border-color 0.18s ease, transform 0.18s ease;
}

.step:hover {
  border-color: rgba(59, 72, 166, 0.4);
  transform: translateX(2px);
}

.step__num {
  display: block;
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.08em;
  margin-bottom: 10px;
}

.step h3 {
  font-size: 1.15rem;
  margin-bottom: 8px;
}

.step p {
  font-size: 14px;
  color: var(--ink-soft);
  line-height: 1.6;
}

.step__list {
  list-style: none;
  margin: 14px 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.step__list li {
  font-size: 11.5px;
  color: var(--muted);
  padding: 3px 10px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--line);
}

/* ---------- Cite ---------- */

.section--cite {
  max-width: none;
  padding-left: 0;
  padding-right: 0;
}

.cite {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: clamp(26px, 4vw, 56px);
  align-items: center;
}

.citation {
  margin: 0;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 20px 22px;
  box-shadow: var(--shadow-sm);
}

.citation pre {
  margin: 0;
  font-family: var(--font-body);
  font-size: 13px;
  line-height: 1.65;
  color: var(--ink-soft);
  white-space: pre-wrap;
  word-break: break-word;
}

.citation figcaption {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.copy-msg {
  font-size: 12.5px;
  color: var(--good);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.copy-msg.is-visible {
  opacity: 1;
}

/* ---------- Equipo ---------- */

.team {
  max-width: 1040px;
}

.team__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 30px;
}

.person {
  padding: 22px 20px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  text-align: center;
}

.avatar {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: var(--accent-tint);
  color: var(--accent-dark);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0.02em;
}

.person h3 {
  font-size: 14.5px;
  margin-bottom: 4px;
}

.person p {
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.45;
}

/* ---------- Footer ---------- */

.footer {
  background: #14162b;
  color: #d8d9e6;
}

.footer__inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(44px, 6vw, 68px) var(--gutter) 36px;
  display: grid;
  grid-template-columns: 1.6fr repeat(3, minmax(0, 1fr));
  gap: 32px;
}

.footer__brand p {
  margin-top: 14px;
  font-size: 13.5px;
  line-height: 1.6;
  color: #a4a6bd;
  max-width: 34ch;
}

.footer__disclaimer {
  font-size: 12px !important;
  color: #7e819c !important;
}

.footer__col {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.footer__col h3 {
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: #8f92ad;
  margin-bottom: 4px;
}

.footer__col a {
  font-size: 13.5px;
  color: #d8d9e6;
  width: fit-content;
  transition: color 0.16s ease;
}

.footer__col a:hover {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.footer__small {
  font-size: 12.5px;
  color: #8f92ad;
  line-height: 1.5;
}

.footer__bottom {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 18px var(--gutter) 26px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 12px;
  color: #8f92ad;
}

/* ---------- Responsive ---------- */

@media (max-width: 1180px) {
  .table {
      min-width: 1060px;
    font-size: 12.5px;
  }

  .grade__dots {
    display: none;
  }

  .overview {
    grid-template-columns: 1fr 1fr;
  }

  .card--donut {
    grid-column: 1 / -1;
  }

  .donut-wrap {
    gap: 24px;
  }

  .donut-legend {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px 18px;
  }
}

@media (max-width: 1024px) {
  .nav {
    display: none;
  }

  .nav-toggle {
    display: flex;
  }

  .db {
    grid-template-columns: 1fr;
  }

  .filters {
    position: static;
    max-height: none;
    overflow: visible;
  }

  .filters__head {
    margin-bottom: 12px;
  }

  #filterGroups {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 0 20px;
  }

  .filter-group:first-child {
    border-top: 1px solid var(--line);
  }

  .method {
    grid-template-columns: 1fr;
  }

  .method__intro {
    position: static;
  }

  .cite {
    grid-template-columns: 1fr;
  }

  .team__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer__inner {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 760px) {
  .table {
    min-width: 0;
    table-layout: auto;
    display: block;
  }

  .table thead {
    display: none;
  }

  .table tbody {
    display: block;
  }

  .table tbody tr {
    display: grid;
    grid-template-columns: 1fr 1fr;
      gap: 10px 14px;
    padding: 16px 18px;
    border-bottom: 1px solid var(--line);
  }

  .table tbody td {
    display: block;
    padding: 0;
    border: 0;
    min-width: 0;
  }

  .table tbody td::before {
    content: attr(data-label);
    display: block;
    font-size: 9.5px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 3px;
  }

  .cell-review,
  .cell-exposure,
  .cell-outcome,
  .cell-effect {
    grid-column: 1 / -1;
  }

    .cell-effect .effect__bar {
      height: 8px;
    }

    .cell-grade,
    .cell-amstar {
      display: flex;
      align-items: center;
      gap: 8px;
    }

    .cell-grade::before,
    .cell-amstar::before {
      margin-bottom: 0;
    }

  .cell-site {
      grid-column: 1 / -1;
      display: flex;
      align-items: center;
      gap: 6px;
  }

    .cell-site > div {
      margin-top: 0 !important;
  }

  .cell-num {
    text-align: left;
  }

  .cell-effect .effect__top {
    margin-bottom: 7px;
  }

  .col-detail-cell {
    position: absolute;
    top: 12px;
    right: 14px;
  }

  .table tbody tr {
    position: relative;
  }

  .col-detail-cell::before {
    content: none !important;
  }

  .cell-review {
    padding-right: 40px !important;
  }

  .stats {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 38px;
  }

  .stat {
    padding: 16px 14px;
  }

  .overview {
    grid-template-columns: 1fr;
  }

  .card--donut {
    grid-column: auto;
  }

  .donut-legend {
    display: flex;
  }

  .hero__search {
      position: relative;
    flex-wrap: wrap;
    padding: 8px;
    border-radius: 20px;
  }

  .hero__search > svg {
      position: absolute;
      left: 20px;
      top: 22px;
      width: 17px;
      height: 17px;
  }

  .hero__search input {
    width: 100%;
    flex: 1 1 100%;
      padding: 8px 10px 8px 34px;
  }

  .hero__search .btn {
    width: 100%;
  }

  .topbar__actions .btn--primary,
  .topbar__actions .btn--ghost {
    display: none;
  }

  .topbar__inner {
    gap: 12px;
  }

  .toolbar {
    align-items: flex-start;
  }

  .toolbar__right {
    width: 100%;
    justify-content: space-between;
  }

  .table-foot {
    flex-direction: column;
    align-items: flex-start;
  }

  .pagination {
    width: 100%;
  }

  .drawer__head {
    padding: 22px 20px 18px;
  }

  .drawer__body {
    padding: 20px 20px 32px;
  }

  .drawer__meta,
  .quality-grid {
    grid-template-columns: 1fr;
  }

  .footer__inner {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .footer__bottom {
    flex-direction: column;
  }
}

@media (max-width: 480px) {
  .stats {
    grid-template-columns: 1fr;
  }

  .team__grid {
    grid-template-columns: 1fr;
  }

  .donut-wrap {
    gap: 14px;
  }

  .donut {
    width: 96px;
    height: 96px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

@media print {
  .topbar,
  .filters,
  .toolbar__right,
  .pagination,
  .footer {
    display: none !important;
  }

  .db {
    grid-template-columns: 1fr;
  }
}