:root {
  --ink: #111714;
  --muted: #68716c;
  --paper: #f2f2eb;
  --surface: #fafaf6;
  --line: rgba(17, 23, 20, 0.12);
  --green: #77f2b9;
  --green-dark: #08764d;
  --navy: #07130f;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
}
a { color: inherit; }
.container { width: min(1120px, calc(100% - 40px)); margin: 0 auto; }
.directory-header {
  position: sticky;
  top: 0;
  z-index: 20;
  color: white;
  background: rgba(7, 19, 15, 0.92);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(16px);
}
.nav-wrap {
  min-height: 66px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 28px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 800;
}
.brand img { width: 34px; height: 34px; object-fit: contain; }
.directory-nav { display: flex; justify-content: center; gap: 30px; }
.directory-nav a, .back-link {
  color: rgba(255, 255, 255, 0.68);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}
.directory-nav a:hover, .back-link:hover { color: white; }
.back-link span { color: var(--green); }

.hero {
  color: white;
  background:
    radial-gradient(circle at 78% 12%, rgba(119, 242, 185, 0.16), transparent 30%),
    linear-gradient(rgba(119, 242, 185, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(119, 242, 185, 0.025) 1px, transparent 1px),
    var(--navy);
  background-size: auto, 58px 58px, 58px 58px, auto;
}
.hero-inner { padding: clamp(72px, 10vw, 126px) 0 92px; }
.edition, .eyebrow {
  margin: 0 0 16px;
  color: var(--green-dark);
  font: 800 11px/1 "Inter", sans-serif;
  letter-spacing: 0.14em;
}
.edition { color: var(--green); }
h1, h2, h3, p { margin-top: 0; }
h1 {
  margin: 0;
  font: 800 clamp(54px, 8vw, 96px)/0.92 "Inter", sans-serif;
  letter-spacing: -0.07em;
}
h1 em { color: var(--green); font-style: normal; }
.hero-inner > p:not(.edition) {
  margin: 28px 0 30px;
  color: rgba(255, 255, 255, 0.65);
  font-size: 18px;
}
.button {
  min-height: 48px;
  padding: 0 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 99px;
  font-weight: 800;
  text-decoration: none;
}
.button.primary { color: var(--navy); background: var(--green); }
.button.light { color: var(--navy); background: white; }

.directory-tabs-section {
  position: sticky;
  top: 66px;
  z-index: 15;
  padding: 16px 0;
  background: rgba(242, 242, 235, 0.9);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}
.view-tabs {
  display: inline-flex;
  gap: 6px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 99px;
  background: var(--surface);
  box-shadow: 0 12px 30px rgba(17, 23, 20, 0.06);
}
.view-tabs button {
  min-height: 34px;
  padding: 0 18px;
  border: 0;
  border-radius: 99px;
  color: var(--muted);
  background: transparent;
  font: 800 12px/1 "Inter", sans-serif;
  cursor: pointer;
}
.view-tabs button.active {
  color: white;
  background: var(--navy);
}
.content-panel:not(.active) { display: none; }
.content-panel.active { display: block; }
.ranking-section, .category-section { padding: 72px 0; scroll-margin-top: 128px; }
.category-section { padding-top: 0; }
.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 50px;
  margin-bottom: 36px;
}
.section-heading h2 {
  margin: 0;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}
.section-heading > p {
  max-width: 420px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}
.ranking-list {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--surface);
}
.ranking-row {
  min-height: 72px;
  display: grid;
  grid-template-columns: 48px 42px minmax(230px, 1.15fr) minmax(120px, 0.55fr) minmax(170px, 0.75fr) 58px 76px;
  gap: 14px;
  align-items: center;
  padding: 8px 18px;
  border-bottom: 1px solid var(--line);
  transition: background 0.2s ease;
}
.ranking-row:last-child { border-bottom: 0; }
.ranking-row:hover { background: white; }
.rank-number {
  color: rgba(17, 23, 20, 0.26);
  font: 800 20px/1 "Inter", sans-serif;
}
.ranking-row:nth-child(-n+3) .rank-number { color: var(--green-dark); }
.agent-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  color: #d9ffeb;
  background: var(--navy);
  font: 800 11px "Inter", sans-serif;
}
.agent-main > span, .agent-compare > span {
  color: var(--muted);
  font-size: 9px;
  font-weight: 700;
}
.agent-main h3 {
  margin: 1px 0 3px;
  font-size: 15px;
  line-height: 1.2;
}
.agent-main p {
  margin: 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.45;
}
.agent-compare span, .agent-compare strong { display: block; }
.agent-compare strong {
  margin-top: 3px;
  font-size: 10px;
  line-height: 1.5;
}
.details-link,
.official-link {
  color: var(--green-dark);
  font-size: 11px;
  font-weight: 800;
  text-decoration: none;
  text-align: right;
}
.details-link { color: var(--muted); }
.category-filters {
  display: flex;
  gap: 8px;
  margin-bottom: 28px;
  overflow-x: auto;
  scrollbar-width: none;
}
.category-filters button {
  min-height: 38px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 99px;
  color: var(--muted);
  background: var(--surface);
  font: 700 12px inherit;
  white-space: nowrap;
  cursor: pointer;
}
.category-filters button.active {
  color: white;
  background: var(--navy);
  border-color: var(--navy);
}
.category-intro {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 30px;
  margin-bottom: 18px;
}
.category-intro span {
  color: var(--green-dark);
  font: 800 9px "Inter";
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.category-intro h3 { margin: 2px 0 0; font-size: 26px; }
.category-intro p {
  max-width: 440px;
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}
.static-category-panel { margin-bottom: 56px; }
.static-category-panel:not(.active) { display: none; }
.static-category-panel.active { display: block; }
.comparison-section {
  padding: 72px 0;
  background: #e8e9e1;
}
.comparison-table-wrap {
  overflow: auto;
  max-height: 720px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
  box-shadow: 0 18px 45px rgba(17, 23, 20, 0.06);
}
.comparison-table {
  width: 100%;
  min-width: 1520px;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
  font-size: 10px;
  line-height: 1.45;
}
.skill-table { min-width: 1660px; }
.comparison-table th,
.comparison-table td {
  padding: 11px 12px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
}
.comparison-table thead th {
  position: sticky;
  top: 0;
  z-index: 3;
  color: rgba(255, 255, 255, 0.74);
  background: var(--navy);
  font: 800 9px/1.2 "Inter", sans-serif;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.comparison-table tbody th {
  position: sticky;
  left: 0;
  z-index: 2;
  background: var(--surface);
}
.comparison-table thead th:first-child {
  left: 0;
  z-index: 4;
}
.comparison-table tbody tr:hover td,
.comparison-table tbody tr:hover th { background: white; }
.comparison-table th:nth-child(1) { width: 190px; }
.comparison-table th:nth-child(2) { width: 115px; }
.comparison-table th:nth-child(3) { width: 120px; }
.comparison-table th:nth-child(4),
.comparison-table th:nth-child(5),
.comparison-table th:nth-child(6) { width: 78px; text-align: center; }
.comparison-table th:nth-child(7) { width: 160px; }
.comparison-table th:nth-child(8) { width: 210px; }
.comparison-table th:nth-child(9),
.comparison-table th:nth-child(10) { width: 210px; }
.comparison-table th:nth-child(11) { width: 72px; }
.skill-table th:nth-child(1) { width: 220px; }
.skill-table th:nth-child(2) { width: 155px; }
.skill-table th:nth-child(3),
.skill-table th:nth-child(4),
.skill-table th:nth-child(5) { width: 90px; text-align: center; }
.skill-table th:nth-child(6),
.skill-table th:nth-child(7),
.skill-table th:nth-child(8) { width: 190px; }
.skill-table th:nth-child(9),
.skill-table th:nth-child(10) { width: 260px; }
.skill-table th:nth-child(11) { width: 76px; }
.comparison-table td:nth-child(4),
.comparison-table td:nth-child(5),
.comparison-table td:nth-child(6) { text-align: center; }
.skill-table td:nth-child(3),
.skill-table td:nth-child(4),
.skill-table td:nth-child(5) { text-align: center; }
.table-product { display: flex; align-items: center; gap: 10px; }
.table-product small,
.table-product strong { display: block; }
.table-product small { color: var(--muted); font-size: 8px; }
.table-product strong { margin-top: 1px; font-size: 12px; line-height: 1.2; }
.status-badge {
  display: inline-flex;
  min-width: 34px;
  min-height: 22px;
  align-items: center;
  justify-content: center;
  border-radius: 99px;
  font-size: 8px;
  font-weight: 800;
}
.status-badge.yes { color: #076640; background: rgba(8, 118, 77, 0.11); }
.status-badge.no { color: #7b4a43; background: rgba(123, 74, 67, 0.1); }
.status-badge.check { color: var(--muted); background: rgba(104, 113, 108, 0.1); }
.comparison-table a {
  color: var(--green-dark);
  font-size: 10px;
  font-weight: 800;
  text-decoration: none;
}
.loading-state {
  padding: 60px;
  color: var(--muted);
  text-align: center;
}
.more-section { padding: 28px; color: white; background: var(--navy); }
.more-card {
  min-height: 260px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 40px;
  padding: 54px;
  border-radius: 26px;
  background: linear-gradient(135deg, #174934, #12241c 60%, #17223c);
}
.more-card .eyebrow { color: var(--green); }
.more-card h2 {
  max-width: 700px;
  margin: 0;
  font-size: clamp(32px, 5vw, 54px);
  line-height: 1.08;
  letter-spacing: -0.05em;
}
footer { padding: 28px 0; color: rgba(255, 255, 255, 0.52); background: var(--navy); }
.footer-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.footer-row p { margin: 0; font-size: 10px; }

@media (max-width: 900px) {
  .ranking-row {
    grid-template-columns: 42px 40px minmax(190px, 1fr) 58px 72px;
  }
  .agent-compare { display: none; }
}

@media (max-width: 680px) {
  .container { width: min(100% - 24px, 1120px); }
  .nav-wrap { grid-template-columns: 1fr auto; }
  .directory-nav { display: none; }
  .back-link { font-size: 0; }
  .back-link span { font-size: 18px; }
  .hero-inner { padding: 64px 0 72px; }
  .directory-tabs-section { top: 66px; padding: 10px 0; }
  .view-tabs { display: flex; width: 100%; }
  .view-tabs button { flex: 1; padding: 0 10px; }
  h1 { font-size: clamp(52px, 17vw, 76px); }
  h1 em { display: block; }
  .hero-inner > p:not(.edition) { font-size: 15px; }
  .ranking-section { padding: 60px 0; }
  .category-section { padding-bottom: 72px; }
  .section-heading, .category-intro { display: block; }
  .section-heading > p, .category-intro p { margin-top: 16px; }
  .ranking-list { border-radius: 18px; }
  .ranking-row {
    min-height: 76px;
    grid-template-columns: 30px 38px 1fr 44px;
    gap: 8px;
    padding: 9px 10px;
  }
  .rank-number { font-size: 16px; }
  .agent-mark { width: 36px; height: 36px; border-radius: 10px; }
  .agent-main h3 { font-size: 15px; }
  .agent-main > span,
  .agent-main p { display: none; }
  .details-link { display: none; }
  .official-link { font-size: 10px; }
  .comparison-section { padding: 72px 0; }
  .comparison-table-wrap {
    max-height: 620px;
    border-radius: 14px;
  }
  .comparison-table { min-width: 1420px; }
  .more-section { padding: 12px; }
  .more-card {
    min-height: 310px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-end;
    padding: 32px 24px;
  }
  .footer-row { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; }
}
