/* Research hub + study pages */
.research {
  --rs-bg: #f4f6fb;
  --rs-card: #fff;
  --rs-border: #e6eaf2;
  --rs-text: #3d4454;
  --rs-dark: #171a22;
  --rs-muted: #6b7280;
  --rs-primary: #35a29f;
  --rs-purple: #7c5cfc;
  --rs-purple-soft: #ece7ff;
  --rs-green: #e8f7ef;
  --rs-radius: 18px;
  color: var(--rs-text);
  font-size: 1.55rem;
  line-height: 1.5;
}

/* Theme styles every ul li:before as a teal bullet — kill that inside research */
.research ul {
  padding-left: 0;
  list-style: none;
}
.research ul li:before,
.research ul li::before {
  content: none !important;
  display: none !important;
  margin: 0 !important;
  width: 0 !important;
  height: 0 !important;
}

.research h1,
.research h2,
.research h3 {
  color: var(--rs-dark);
  margin: 0 0 .75rem;
  font-weight: 700;
  line-height: 1.25;
}

.research h1 { font-size: clamp(2.4rem, 3vw, 3.4rem); }
.research h2 { font-size: clamp(2rem, 2.4vw, 2.6rem); }
.research h3 { font-size: 1.7rem; }

.research__hero {
  padding: 48px 0 28px;
}

.research__lead {
  max-width: 64ch;
  color: var(--rs-muted);
  margin: 0 0 1.2rem;
  font-size: 1.7rem;
}

.research__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  color: var(--rs-muted);
  font-size: 1.35rem;
}

.research__meta span {
  background: var(--rs-bg);
  border: 1px solid var(--rs-border);
  border-radius: 999px;
  padding: 6px 12px;
}

.research__section {
  padding: 28px 0;
}

.research__section--bg {
  background: var(--rs-bg);
}

.research__card {
  background: var(--rs-card);
  border: 1px solid var(--rs-border);
  border-radius: var(--rs-radius);
  padding: 22px;
  box-shadow: 0 1px 0 rgba(23, 26, 34, .03);
}

.research__card > h2,
.research__card > h3 {
  margin-bottom: .35rem;
}

.research__hint {
  color: var(--rs-muted);
  font-size: 1.35rem;
  margin: 0 0 1.2rem;
  max-width: 70ch;
}

.research-kpis {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
}

.research-kpi {
  background: var(--rs-card);
  border: 1px solid var(--rs-border);
  border-radius: 16px;
  padding: 18px 16px;
}

.research-kpi__label {
  display: block;
  color: var(--rs-muted);
  font-size: 1.3rem;
  margin-bottom: 8px;
}

.research-kpi__value {
  display: block;
  color: var(--rs-dark);
  font-size: 3rem;
  font-weight: 700;
  line-height: 1;
  margin-bottom: 6px;
}

.research-kpi__sub {
  color: var(--rs-muted);
  font-size: 1.25rem;
}

.research-grid-2 {
  display: grid;
  grid-template-columns: 1.35fr .95fr;
  gap: 16px;
}

.research-scatter {
  position: relative;
  width: 100%;
  height: 420px;
}

.research-scatter canvas {
  width: 100% !important;
  height: 100% !important;
}

.research-potential__list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.research-potential__row {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.research-potential__domain {
  color: var(--rs-dark);
  font-weight: 600;
  font-size: 1.4rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.research-bar {
  height: 10px;
  background: #efeaff;
  border-radius: 999px;
  overflow: hidden;
  position: relative;
}

.research-bar > i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #8b6cff, #6a4dff);
  border-radius: inherit;
}

.research-potential__score {
  font-weight: 700;
  color: var(--rs-dark);
  min-width: 2.4ch;
  text-align: right;
}

.research-grid-2--equal {
  grid-template-columns: 1fr 1fr;
}

.research-queries {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 340px;
  overflow: auto;
}

.research-queries li {
  padding: 10px 12px;
  background: var(--rs-bg);
  border: 1px solid var(--rs-border);
  border-radius: 10px;
  color: var(--rs-dark);
  font-size: 1.35rem;
  line-height: 1.35;
}

.research-seo {
  max-width: 78ch;
  color: var(--rs-text);
  font-size: 1.5rem;
  line-height: 1.55;
}

.research-seo h2 {
  margin-bottom: 1rem;
}

.research-seo p {
  margin: 0 0 1rem;
}

.research-seo a {
  color: var(--rs-primary);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.research-donut-wrap {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 24px;
  align-items: center;
}

.research-donut {
  position: relative;
  width: 220px;
  height: 220px;
}

.research-donut__center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.research-donut__center strong {
  font-size: 3.2rem;
  color: var(--rs-dark);
  line-height: 1;
}

.research-donut__center span {
  color: var(--rs-muted);
  font-size: 1.3rem;
}

.research-donut__legend {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.research-donut__item {
  display: grid;
  grid-template-columns: 12px 1fr auto auto;
  gap: 10px;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--rs-border);
}

.research-donut__item:last-child { border-bottom: 0; }
.research-donut__dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}
.research-donut__count {
  font-weight: 700;
  color: var(--rs-dark);
}
.research-donut__pct {
  color: var(--rs-muted);
  min-width: 4ch;
  text-align: right;
}

.research-toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 8px;
}

.research-toolbar h2 { margin-bottom: .35rem; }
.research-toolbar .research__hint { margin-bottom: 0; }

.research-toolbar__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.research-input {
  min-width: 200px;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--rs-border);
  border-radius: 10px;
  background: #fff;
  color: var(--rs-dark);
  font-size: 1.35rem;
}

.research-select {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--rs-muted);
  font-size: 1.3rem;
}

.research-select select {
  height: 40px;
  border: 1px solid var(--rs-border);
  border-radius: 10px;
  background: #fff;
  padding: 0 10px;
  color: var(--rs-dark);
  font-size: 1.35rem;
}

.research-btn {
  height: 40px;
  padding: 0 16px;
  border: 1px solid var(--rs-dark);
  border-radius: 10px;
  background: var(--rs-dark);
  color: #fff;
  font-size: 1.35rem;
  font-weight: 600;
  cursor: pointer;
}

.research-btn:hover { opacity: .92; }

.research-sort {
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .02em;
  cursor: pointer;
  padding: 0;
}

.research-pager {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 14px;
  color: var(--rs-muted);
  font-size: 1.35rem;
}

.research-pager button {
  width: 40px;
  height: 40px;
  border: 1px solid var(--rs-border);
  border-radius: 10px;
  background: #fff;
  color: var(--rs-dark);
  cursor: pointer;
  font-size: 1.5rem;
}

.research-pager button:disabled {
  opacity: .4;
  cursor: default;
}

.research-scatter__tip {
  position: absolute;
  z-index: 5;
  pointer-events: none;
  background: #171a22;
  color: #fff;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 1.25rem;
  line-height: 1.35;
  max-width: 260px;
  box-shadow: 0 8px 24px rgba(0,0,0,.18);
}

.research-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.research-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  min-width: 720px;
  font-size: 1.35rem;
}

.research-table th,
.research-table td {
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--rs-border);
  white-space: nowrap;
}

.research-table th {
  color: var(--rs-muted);
  font-weight: 600;
  font-size: 1.2rem;
  text-transform: uppercase;
  letter-spacing: .02em;
}

.research-table td.num,
.research-table th.num {
  text-align: center;
}

.research-table tr.is-ugc td {
  background: rgba(46, 170, 99, .08);
}

.research-heat {
  display: inline-flex;
  min-width: 3.2rem;
  justify-content: center;
  align-items: center;
  padding: 4px 8px;
  border-radius: 8px;
  font-weight: 600;
  color: #2c2158;
}

.research-inf {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 110px;
}

.research-inf .research-bar {
  flex: 1;
  background: #ece7ff;
}

.research-tops {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.research-top {
  background: var(--rs-card);
  border: 1px solid var(--rs-border);
  border-radius: 16px;
  padding: 16px;
}

.research-top h3 {
  margin-bottom: 12px;
  font-size: 1.55rem;
}

.research-top ol {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: top;
}

.research-top li {
  counter-increment: top;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--rs-border);
  font-size: 1.35rem;
}

.research-top li:last-child { border-bottom: 0; }
.research-top li::before {
  content: counter(top);
  color: var(--rs-muted);
  font-weight: 600;
}
.research-top__name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--rs-dark);
}
.research-top__val {
  font-weight: 700;
  color: var(--rs-dark);
}

.research-hub__stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 1.4rem;
  max-width: 720px;
}

.research-hub__stat {
  background: var(--rs-bg);
  border: 1px solid var(--rs-border);
  border-radius: 14px;
  padding: 14px 16px;
}

.research-hub__stat strong {
  display: block;
  color: var(--rs-dark);
  font-size: 2.4rem;
  line-height: 1.1;
  margin-bottom: 4px;
}

.research-hub__stat span {
  color: var(--rs-muted);
  font-size: 1.3rem;
}

.research-hub__toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px 24px;
  margin-bottom: 22px;
  align-items: flex-end;
}

.research-hub__toolbar-title {
  margin-bottom: .35rem;
}

.research-hub__toolbar .research__hint {
  margin-bottom: 0;
}

.research-hub__filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.research-hub__chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--rs-border);
  border-radius: 999px;
  background: #fff;
  color: var(--rs-dark);
  font-size: 1.35rem;
  cursor: pointer;
}

.research-hub__chip em {
  font-style: normal;
  color: var(--rs-muted);
  font-size: 1.2rem;
}

.research-hub__chip.is-active {
  background: var(--rs-dark);
  border-color: var(--rs-dark);
  color: #fff;
}

.research-hub__chip.is-active em { color: rgba(255,255,255,.7); }

.research-hub__niche {
  margin-bottom: 28px;
}

.research-hub__niche-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.research-hub__niche-head h3 {
  margin: 0;
  font-size: 1.9rem;
}

.research-hub__niche-head span {
  color: var(--rs-muted);
  font-size: 1.3rem;
}

.research-hub__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.research-hub__card {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  background: var(--rs-card);
  border: 1px solid var(--rs-border);
  border-radius: var(--rs-radius);
  padding: 22px 22px 18px;
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
  min-height: 100%;
}

a.research-hub__card:hover {
  border-color: rgba(53, 162, 159, .55);
  box-shadow: 0 10px 28px rgba(23, 26, 34, .07);
  transform: translateY(-2px);
}

.research-hub__card.is-soon {
  opacity: .72;
  background: #f8f9fc;
}

.research-hub__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.research-hub__tag {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(53, 162, 159, .12);
  color: #1f6f6d;
  font-size: 1.2rem;
  font-weight: 600;
}

.research-hub__tag--type {
  background: #eef2f8;
  color: #3d4454;
}

.research-hub__tag--muted {
  background: #eceff5;
  color: var(--rs-muted);
}

.research-hub__card h4 {
  margin: 0 0 .55rem;
  font-size: clamp(1.7rem, 2vw, 2.1rem);
  line-height: 1.3;
  color: var(--rs-dark);
}

.research-hub__card p {
  margin: 0;
  color: var(--rs-muted);
  font-size: 1.4rem;
  flex: 1;
}

.research-hub__metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
  color: var(--rs-muted);
  font-size: 1.25rem;
}

.research-hub__metrics li {
  margin: 0;
  padding: 0;
  position: static;
}

.research-hub__metrics strong {
  color: var(--rs-dark);
  font-weight: 700;
}

.research-hub__more {
  display: inline-block;
  margin-top: 14px;
  color: var(--rs-primary);
  font-weight: 600;
  font-size: 1.4rem;
}

.research-hub__empty {
  color: var(--rs-muted);
  font-size: 1.5rem;
  margin: 8px 0 0;
}

.research-hub__steps {
  margin: 0;
  padding-left: 1.2em;
  color: var(--rs-text);
  font-size: 1.45rem;
  line-height: 1.55;
}

.research-hub__steps li { margin-bottom: .55rem; }
.research-hub__steps li:last-child { margin-bottom: 0; }

.research-cta {
  margin: 24px 0 48px;
  background: #171a22;
  color: #fff;
  border-radius: 20px;
  padding: 28px;
}

.research-cta h2 { color: #fff; }
.research-cta p { color: rgba(255,255,255,.75); margin: 0 0 1rem; max-width: 54ch; }
.research-cta .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 4.6rem;
  padding: 0 24px;
  border-radius: 12px;
  background: var(--rs-primary);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
}

@media (max-width: 1100px) {
  .research-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .research-grid-2,
  .research-grid-2--equal,
  .research-donut-wrap,
  .research-tops,
  .research-hub__grid { grid-template-columns: 1fr; }
  .research-hub__stats { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: none; }
}

@media (max-width: 700px) {
  .research-kpis { grid-template-columns: 1fr 1fr; }
  .research-scatter { height: 320px; }
  .research-potential__row {
    grid-template-columns: 1fr auto;
  }
  .research-bar { grid-column: 1 / -1; }
  .research-hub__stats { grid-template-columns: 1fr 1fr; }
}
