:root {
  --bg: #f3f5fb;
  --surface: #ffffff;
  --surface-alt: #f7f9ff;
  --text: #101a2e;
  --muted: #56627a;
  --line: #dbe3f3;
  --brand: #3f63ff;
  --brand-dark: #2845c9;
  --brand-soft: #e8edff;
  --radius-xl: 20px;
  --radius-lg: 14px;
  --shadow: 0 18px 44px rgba(16, 26, 46, 0.08);
}

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

body {
  margin: 0;
  font-family: "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
  background:
    radial-gradient(circle at 8% -10%, #dfe7ff 0, transparent 32%),
    radial-gradient(circle at 95% 4%, #ece1ff 0, transparent 28%),
    var(--bg);
  color: var(--text);
}

img { max-width: 100%; height: auto; }
a { color: var(--brand-dark); }

.skip-link { position: absolute; left: -9999px; top: auto; }
.skip-link:focus {
  left: 1rem; top: 1rem; background: #fff; border: 2px solid var(--brand);
  padding: 0.5rem 0.75rem; z-index: 1000;
}

.container { width: min(1120px, 92%); margin: 0 auto; }

.site-header {
  position: sticky; top: 0; z-index: 20;
  backdrop-filter: blur(8px);
  background: rgba(255,255,255,0.92);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; gap: 1rem; align-items: center; justify-content: space-between;
  padding: 0.8rem 0;
}
.brand img { display: block; }
.nav-list {
  list-style: none; display: flex; flex-wrap: wrap; gap: 0.65rem;
  margin: 0; padding: 0;
}
.nav-list a {
  text-decoration: none; color: var(--text);
  border: 1px solid transparent; padding: 0.42rem 0.72rem; border-radius: 999px;
  font-weight: 600;
}
.nav-list a:hover,.nav-list a:focus { background: var(--surface-alt); border-color: var(--line); }
.nav-list a[aria-current="page"] { background: var(--brand-soft); border-color: #cad7ff; }

h1,h2,h3 { line-height: 1.2; margin: 0 0 0.65rem; }
h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); }
h2 { font-size: clamp(1.35rem, 2.5vw, 1.8rem); }

.hero { padding: 2rem 0 1.1rem; }
.hero-affiliate .hero-block {
  background: linear-gradient(180deg, #ffffff, #f3f7ff);
  color: #1a2a46;
  border: 1px solid #cfdcf5;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
  padding: 1.45rem;
}
.hero-affiliate h1 { color: #102449; text-align: center; }
.hero-lead {
  font-size: 1.04rem; color: #425a84; margin: 0 auto; max-width: 62ch; text-align: center;
}
.hero-highlight { color: #2f63ff; }

.notice,.methodology,.responsible,.comparison,.page { padding: 1rem 0 1.7rem; }
.notice .container,.methodology .container,.responsible .container,.comparison .container,.prose {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
  padding: 1.25rem;
}

.notice .container {
  background: linear-gradient(180deg, #f5f9ff, #eef4ff);
  border-color: #cfe0ff;
}

.methodology .container {
  background: linear-gradient(180deg, #f8f7ff, #f1efff);
  border-color: #d8cffc;
}

.responsible .container {
  background: linear-gradient(180deg, #f2fbf7, #eaf7f1);
  border-color: #cceadf;
}

.notice h2,
.methodology h2,
.responsible h2 {
  display: inline-block;
  margin-bottom: 0.75rem;
  padding-bottom: 0.2rem;
  border-bottom: 3px solid #87a7e8;
}

.methodology h2 { border-bottom-color: #9a86e8; }
.responsible h2 { border-bottom-color: #64b692; }

.notice p,
.methodology p,
.responsible p {
  color: #334b72;
}

.methodology ol,
.responsible ul {
  margin-top: 0.55rem;
  padding-left: 1.2rem;
}

.methodology li,
.responsible li {
  margin-bottom: 0.35rem;
}

.cards { display: grid; gap: 1rem; }
.cards.stacked { grid-template-columns: 1fr; }

.leaderboard .cards.stacked {
  gap: 0;
  border: 1px solid #d7e1f3;
  border-radius: 14px;
  overflow: hidden;
  background: #ffffff;
}

.leaderboard .container {
  background: linear-gradient(180deg, #ffffff, #f9fbff);
  border: 1px solid #d6e0f2;
}
.leaderboard h2,.leaderboard .meta-note { color: #13284d; }
.leaderboard-note { color: #5f7397 !important; }

.card {
  border: 1px solid var(--line);
  background: var(--surface-alt);
  border-radius: var(--radius-lg);
  padding: 1rem;
}

.affiliate-row {
  position: relative;
  background: #ffffff;
  border: 0;
  border-top: 1px solid #e3e9f6;
  color: #142647;
  box-shadow: none;
  border-radius: 0;
  padding: 0.85rem;
}

.leaderboard .affiliate-row:first-child {
  border-top: 0;
}

.pick-badge {
  display: inline-block;
  margin: 0 0 0.6rem;
  background: #2353bf; color: #fff;
  font-size: 0.78rem; font-weight: 700;
  padding: 0.25rem 0.7rem; border-radius: 999px;
}
.affiliate-main {
  display: grid;
  grid-template-columns: 170px 1.55fr 0.55fr 160px;
  gap: 0.75rem;
  margin-bottom: 0;
  align-items: center;
}
.affiliate-left {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0;
}
.logo-cell { margin-bottom: 0; }
.logo-cell img {
  border: 1px solid #ccdaf2;
  border-radius: 10px;
  background: #fff;
  width: min(100%, 165px);
}

.affiliate-right {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  border: 1px solid #d5e2f8;
  border-radius: 10px;
  background: #fbfdff;
  padding: 0.48rem 0.6rem;
  text-align: left;
  gap: 0.45rem;
}
.score-number { margin: 0; font-size: 1.45rem; line-height: 1; color: #102a59; font-weight: 800; }
.score-label {
  margin: 0; font-size: 0.72rem; color: #4b628a; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.02em;
}
.rating-stars { margin: 0; color: #ef9a22; font-size: 0.78rem; white-space: nowrap; }
.score-votes { margin: 0; color: #5f7397; font-size: 0.72rem; white-space: nowrap; }

.bonus-main { margin: 0; color: #25529a; font-size: 1.28rem; font-weight: 800; line-height: 1.2; }
.bonus-sub { margin: 0.35rem 0 0; color: #5a7092; font-size: 0.84rem; }
.payments-title {
  margin: 0.6rem 0 0.35rem; color: #3a557d; font-size: 0.84rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.02em;
}
.pay-badge {
  display: inline-block; margin: 0.15rem 0.25rem 0.15rem 0; padding: 0.2rem 0.45rem;
  border-radius: 6px; border: 1px solid #7fa4d8; background: #eef5ff; color: #1b3c68;
  font-size: 0.72rem; font-weight: 700;
}

.cta {
  display: inline-block; background: linear-gradient(180deg, #4f79ff, #315ae0);
  color: #fff; text-decoration: none; border-radius: 10px; padding: 0.62rem 0.9rem;
  border: 1px solid #234cc8; font-weight: 700;
}
.cta:hover,.cta:focus { background: linear-gradient(180deg, #5f86ff, #3961e0); }
.cta-main { width: 100%; text-align: center; }

.site-footer {
  margin-top: 1rem;
  background: linear-gradient(180deg, #0f1730, #0a1022);
  color: #e5ebff;
  padding: 1.55rem 0 1.8rem;
}
.footer-grid { display: grid; gap: 1.1rem; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer a { color: #cbdbff; }

@media (max-width: 920px) {
  .affiliate-main { grid-template-columns: 1fr 1fr; }

  .logo-cell {
    grid-column: 1 / -1;
  }

  .cta-main {
    grid-column: 1 / -1;
  }

  .affiliate-right {
    padding: 0.48rem 0.6rem;
    gap: 0.45rem;
  }

  .score-number { font-size: 1.4rem; }
}

@media (max-width: 760px) {
  .header-inner { flex-direction: column; align-items: flex-start; }
  .hero .container,.notice .container,.methodology .container,.responsible .container,.comparison .container,.prose { padding: 1rem; }
  .affiliate-row { padding: 0.72rem; }
  .pick-badge { margin: 0 0 0.5rem; font-size: 0.74rem; }
  .affiliate-left { padding: 0.62rem; }
  .logo-cell { margin-bottom: 0.4rem; }
  .affiliate-main { grid-template-columns: 1fr; gap: 0.6rem; }
  .logo-cell img { width: min(100%, 150px); margin: 0 auto; display: block; }
  .bonus-main { font-size: 1.1rem; }
  .bonus-main { text-align: center; }
  .bonus-sub { font-size: 0.84rem; }
  .pay-badge { font-size: 0.68rem; padding: 0.18rem 0.4rem; }
  .affiliate-right {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    text-align: left;
    width: 100%;
  }
  .score-number { font-size: 1.25rem; }
  .rating-stars { font-size: 0.75rem; }
  .score-votes { font-size: 0.7rem; }
  .cta { width: 100%; text-align: center; }
}
