:root {
  color: #111827;
  background: #ffffff;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  --bg: #ffffff;
  --bg-soft: #f6f8fb;
  --surface: #ffffff;
  --text: #111827;
  --muted: #5b6777;
  --line: #d9e2ec;
  --line-soft: #edf2f7;
  --teal: #087f76;
  --teal-dark: #05635c;
  --blue: #245ec5;
  --green: #157a55;
  --shadow: 0 14px 34px rgba(17, 24, 39, 0.06);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.45;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

.app-shell {
  min-height: 100vh;
  background: linear-gradient(180deg, #f6f8fb 0, #ffffff 330px);
}

.topbar {
  display: flex;
  align-items: center;
  gap: 24px;
  max-width: 1240px;
  margin: 0 auto;
  padding: 14px 20px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.94);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #0b1118;
  font-size: 16px;
  font-weight: 760;
  white-space: nowrap;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 7px;
  background: var(--teal);
  color: #ffffff;
  font-size: 12px;
  font-weight: 850;
}

.nav-links {
  position: relative;
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
  color: #172033;
  font-size: 13px;
  font-weight: 720;
}

.ui-id {
  display: inline-flex;
  align-items: center;
  width: max-content;
  max-width: 100%;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  background: #f8fafc;
  color: #64748b;
  padding: 2px 5px;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.2;
  text-transform: none;
}

.nav-ui-id {
  margin-right: 6px;
}

.nav-links a {
  border-bottom: 2px solid transparent;
  padding: 16px 13px 14px;
}

.nav-links a[aria-current="page"] {
  border-color: var(--teal);
  color: var(--teal-dark);
}

main {
  max-width: 1240px;
  margin: 0 auto;
  padding: 28px 20px 56px;
}

.launch-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 420px);
  gap: 24px;
  align-items: stretch;
}

.hero-copy,
.launch-stats,
.source-card,
.record-card,
.category-card,
.detail-page,
.static-route-notice,
.search-form,
.table-frame,
.empty-state {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.hero-copy {
  padding: 28px;
}

.static-route-notice {
  display: grid;
  gap: 12px;
  max-width: 860px;
  padding: 28px;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--teal-dark);
  font-size: 12px;
  font-weight: 820;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  letter-spacing: 0;
}

.hero-copy h1,
.page-header h1,
.detail-page h1,
.static-route-notice h1 {
  margin: 0;
  color: #080f1a;
  font-size: 30px;
  font-weight: 780;
  line-height: 1.12;
}

.hero-copy p:not(.eyebrow),
.page-header p,
.detail-page header p,
.static-route-notice p:not(.eyebrow) {
  max-width: 760px;
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.55;
}

.hero-search,
.search-form {
  display: grid;
  gap: 10px;
  margin-top: 22px;
}

.hero-search label,
.search-form label {
  color: #263449;
  font-size: 12px;
  font-weight: 760;
}

.hero-search div,
.search-form div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 10px;
}

.hero-search input,
.search-form input {
  width: 100%;
  min-height: 42px;
  border: 1px solid #c8d2dc;
  border-radius: 6px;
  color: var(--text);
  padding: 0 12px;
  outline: none;
}

.hero-search input:focus,
.search-form input:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(8, 127, 118, 0.14);
}

.hero-search button,
.search-form button {
  min-height: 42px;
  border: 1px solid var(--teal-dark);
  border-radius: 6px;
  background: var(--teal);
  color: #ffffff;
  padding: 0 16px;
  font-size: 13px;
  font-weight: 760;
  cursor: pointer;
}

.launch-stats {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1px;
  overflow: hidden;
  background: var(--line);
}

.launch-stats div {
  display: grid;
  align-content: center;
  gap: 4px;
  min-height: 100px;
  background: #ffffff;
  padding: 20px;
}

.launch-stats strong {
  color: #0b1320;
  font-size: 26px;
  line-height: 1;
}

.launch-stats span {
  color: var(--muted);
  font-weight: 700;
}

.source-section,
.record-list-section,
.category-section,
.table-section,
.detail-section {
  margin-top: 30px;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.section-heading h2,
.detail-section h2 {
  margin: 0;
  color: #0b1320;
  font-size: 19px;
  font-weight: 760;
  line-height: 1.25;
}

.text-link,
.source-card a,
.record-card a,
td a,
.category-card a,
.external-link,
.detail-metrics a {
  color: var(--blue);
  font-weight: 740;
}

.source-grid,
.category-grid,
.record-list {
  display: grid;
  gap: 12px;
}

.source-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.source-card,
.category-card,
.record-card {
  display: grid;
  gap: 8px;
  padding: 16px;
  box-shadow: none;
}

.source-card span,
.record-card > div,
.record-meta,
.category-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
}

.source-card strong {
  font-size: 22px;
  line-height: 1.1;
}

.record-list {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.record-card h3 {
  margin: 0;
  color: #0f172a;
  font-size: 16px;
  line-height: 1.28;
}

.record-card p {
  margin: 0;
  color: var(--muted);
}

.record-card > div,
.record-meta,
.source-breakdown {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.rank-pill,
.record-meta span,
.tag-row span,
.source-breakdown div {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f8fafc;
  padding: 5px 7px;
}

.source-breakdown {
  margin: 0;
}

.source-breakdown dt,
.source-breakdown dd {
  display: inline;
  margin: 0;
}

.source-breakdown dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
}

.source-breakdown dt::after {
  content: " ";
}

.source-breakdown dd {
  color: #0f172a;
  font-size: 12px;
  font-weight: 820;
}

.page-header {
  max-width: 860px;
}

.search-form {
  margin-top: 22px;
  padding: 16px;
  box-shadow: none;
}

.table-frame {
  overflow-x: auto;
  box-shadow: none;
}

table {
  width: 100%;
  min-width: 840px;
  border-collapse: collapse;
}

th,
td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line-soft);
  text-align: left;
  font-size: 12px;
  vertical-align: top;
}

th {
  background: #f8fafc;
  color: #425166;
  font-weight: 820;
}

tbody tr:hover {
  background: #fbfefd;
}

.category-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.category-card ul {
  display: grid;
  gap: 6px;
  margin: 4px 0 0;
  padding: 0;
  list-style: none;
}

.detail-page {
  display: grid;
  gap: 22px;
  max-width: 960px;
  padding: 24px;
}

.skill-detail-page {
  display: grid;
  gap: 16px;
}

.detail-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 720;
}

.detail-breadcrumb a,
.detail-back-link {
  color: var(--blue);
}

.detail-back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: max-content;
  max-width: 100%;
  min-height: 34px;
}

.action-id {
  border-color: rgba(8, 127, 118, 0.24);
  background: rgba(8, 127, 118, 0.08);
  color: var(--teal-dark);
}

.detail-hero-grid,
.detail-grid-two {
  display: grid;
  gap: 16px;
}

.detail-hero-grid {
  grid-template-columns: minmax(0, 1fr) 320px;
  align-items: start;
}

.detail-grid-two {
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.64fr);
}

.detail-panel {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: none;
  padding: 16px;
}

.skill-header-panel {
  display: grid;
  gap: 12px;
}

.skill-header-panel h1 {
  margin: 0;
  color: #080f1a;
  font-size: 30px;
  font-weight: 780;
  line-height: 1.12;
}

.skill-header-panel p:not(.eyebrow),
.panel-note {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.panel-heading h2 {
  margin: 0;
  color: #0b1320;
  font-size: 16px;
  font-weight: 800;
  line-height: 1.25;
}

.key-value-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
}

.key-value-grid div,
.metric-grid div,
.schema-grid div,
.source-link-list div {
  min-width: 0;
  background: #ffffff;
}

.key-value-grid div {
  padding: 10px;
}

.key-value-grid dt,
.metric-grid span,
.schema-grid span,
.source-link-list span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.key-value-grid dd {
  margin: 5px 0 0;
  color: #0f172a;
  font-size: 12px;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
}

.metric-grid div {
  display: grid;
  gap: 6px;
  padding: 12px;
}

.metric-grid strong {
  color: #0f172a;
  font-size: 16px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.state-matrix {
  display: grid;
  gap: 8px;
}

.state-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 100%;
  border: 1px solid #fed7aa;
  border-radius: 6px;
  background: #fff7ed;
  color: #9a3412;
  padding: 6px 8px;
  font-size: 11px;
  font-weight: 780;
  line-height: 1.25;
}

.detail-table-frame {
  margin-top: 12px;
  border-radius: var(--radius);
}

.detail-table-frame table {
  min-width: 1120px;
}

.compact-table table {
  min-width: 840px;
}

.detail-table-frame code {
  border-radius: 4px;
  background: #f1f5f9;
  color: #0f172a;
  padding: 2px 4px;
  font-size: 11px;
}

.table-action {
  color: var(--blue);
  font-weight: 800;
  white-space: nowrap;
}

.source-link-list,
.schema-grid {
  display: grid;
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
}

.source-link-list {
  grid-template-columns: 1fr;
}

.source-link-list > div {
  display: grid;
  grid-template-columns: minmax(150px, 0.28fr) minmax(0, 1fr) max-content;
  gap: 10px;
  align-items: center;
  padding: 10px;
}

.source-link-list strong,
.schema-grid strong {
  color: #0f172a;
  font-size: 12px;
  overflow-wrap: anywhere;
}

.source-link-list button,
.panel-actions button {
  min-height: 30px;
  border: 1px solid var(--teal);
  border-radius: 6px;
  background: #ffffff;
  color: var(--teal-dark);
  padding: 0 10px;
  font-size: 12px;
  font-weight: 800;
}

.schema-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.schema-grid div {
  display: grid;
  gap: 5px;
  padding: 10px;
}

.panel-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.contract-box {
  overflow-x: auto;
  margin: 0 0 10px;
  border: 1px solid #111827;
  border-radius: 7px;
  background: #111827;
  color: #f8fbff;
  padding: 12px;
  font-size: 12px;
  line-height: 1.55;
}

.detail-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
}

.detail-metrics div {
  min-width: 0;
  background: #ffffff;
  padding: 14px;
}

.detail-metrics dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 780;
}

.detail-metrics dd {
  margin: 7px 0 0;
  overflow-wrap: anywhere;
  color: #0f172a;
  font-weight: 760;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.command-box {
  margin: 0;
  overflow-x: auto;
  border: 1px solid #111827;
  border-radius: 7px;
  background: #111827;
  color: #f8fbff;
  padding: 14px;
  font-size: 13px;
  line-height: 1.55;
}

.external-link {
  overflow-wrap: anywhere;
}

.empty-state {
  padding: 16px;
  color: var(--muted);
  box-shadow: none;
}

@media (max-width: 920px) {
  .topbar {
    flex-wrap: wrap;
  }

  .nav-links {
    order: 3;
    width: 100%;
    margin-left: 0;
    flex-wrap: wrap;
  }

  .nav-links a {
    padding-top: 10px;
    padding-bottom: 10px;
  }

  .launch-hero,
  .source-grid,
  .record-list,
  .category-grid,
  .detail-metrics,
  .detail-hero-grid,
  .detail-grid-two {
    grid-template-columns: 1fr;
  }

  .key-value-grid,
  .metric-grid,
  .schema-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .launch-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  main {
    padding: 22px 14px 46px;
  }

  .brand {
    width: 100%;
  }

  .hero-copy {
    padding: 20px;
  }

  .hero-copy h1,
  .page-header h1,
  .detail-page h1,
  .static-route-notice h1 {
    font-size: 24px;
  }

  .hero-search div,
  .search-form div,
  .launch-stats {
    grid-template-columns: 1fr;
  }

  .key-value-grid,
  .metric-grid,
  .schema-grid,
  .source-link-list > div {
    grid-template-columns: 1fr;
  }

  .detail-panel {
    padding: 12px;
  }

  .detail-table-frame {
    max-width: calc(100vw - 52px);
    overflow-x: auto;
  }

  .detail-table-frame table {
    width: max-content;
    min-width: 780px;
  }

  .compact-table table {
    min-width: 680px;
  }

  .state-pill {
    align-items: flex-start;
  }

  .hero-search button,
  .search-form button {
    width: 100%;
  }

  .section-heading {
    display: grid;
    align-items: start;
  }
}
