.pricing-page {
  min-height: 100vh;
  background: var(--bg);
}

:root {
  --group-destructive: oklch(0.577 0.245 27.325);
  --group-success: oklch(0.596 0.145 163.225);
  --group-warning: oklch(0.681 0.162 75.834);
  --group-info: oklch(0.588 0.158 241.966);
  --group-chart-1: oklch(0.72 0.18 250);
  --group-chart-2: oklch(0.65 0.15 200);
  --group-chart-3: oklch(0.7 0.12 280);
  --group-chart-4: oklch(0.68 0.19 325);
  --group-chart-5: oklch(0.68 0.16 155);
  --group-light-green: #10b981;
}

html[data-theme='dark'] {
  --group-destructive: oklch(0.704 0.191 22.216);
  --group-success: oklch(0.696 0.17 162.48);
  --group-warning: oklch(0.769 0.188 70.08);
  --group-info: oklch(0.613 0.14 239.919);
  --group-chart-1: oklch(0.76 0.14 250);
  --group-chart-2: oklch(0.76 0.13 200);
  --group-chart-3: oklch(0.76 0.13 285);
  --group-chart-4: oklch(0.75 0.16 325);
  --group-chart-5: oklch(0.76 0.14 155);
  --group-light-green: #6ee7b7;
}

.pricing-shell {
  width: min(1280px, 100%);
  margin: 0 auto;
  padding-inline: 32px;
}

.pricing-hero {
  padding: 126px 0 35px;
  border-bottom: 1px solid color-mix(in srgb, var(--border) 70%, transparent);
  background: var(--bg);
}

.pricing-hero h1 {
  margin: 0;
  font-size: 34px;
  line-height: 1.2;
  font-weight: 780;
}

.pricing-hero p {
  max-width: 720px;
  margin: 8px 0 0;
  color: var(--text-soft);
  font-size: 16px;
}

.pricing-hero .pricing-summary {
  margin-top: 4px;
  color: var(--text-faint);
  font-size: 13px;
}

.pricing-main {
  min-height: 650px;
  padding-top: 28px;
  padding-bottom: 64px;
}

.pricing-toolbar {
  display: grid;
  gap: 10px;
}

.filter-primary {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) 220px 220px 42px;
  gap: 12px;
}

.search-control,
.select-control,
.dropdown-trigger,
.sort-control,
.plain-control,
.filter-button,
.segmented {
  min-height: 42px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
}

.search-control {
  padding: 0 9px 0 13px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.search-control:focus-within,
.select-control:focus-within,
.dropdown-trigger:focus-visible {
  border-color: color-mix(in srgb, var(--primary) 68%, var(--border));
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 13%, transparent);
}

.search-control svg,
.sort-control svg,
.filter-button svg,
.drawer-close svg,
.copy-model svg,
.details-button svg,
.icon-segment svg,
.empty-state svg {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.search-control svg { color: var(--text-faint); }
.search-control input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
}

.search-control input::placeholder { color: var(--text-faint); }
.search-control kbd {
  padding: 2px 6px;
  border: 1px solid var(--border);
  border-radius: 5px;
  color: var(--text-faint);
  background: var(--muted);
  font-size: 10px;
  font-family: inherit;
  line-height: 1.3;
}

.select-control {
  padding: 0 9px 0 12px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  overflow: hidden;
}

.select-control > span {
  color: var(--text-soft);
  font-size: 11px;
  white-space: nowrap;
}

.select-control select,
.sort-control select {
  width: 100%;
  min-width: 0;
  height: 40px;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
  cursor: pointer;
}

.dropdown-control { position: relative; min-width: 0; }
.dropdown-trigger {
  width: 100%;
  min-height: 42px;
  padding: 0 11px 0 12px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  color: var(--text);
  cursor: pointer;
  text-align: left;
}
.dropdown-trigger > span { color: var(--text-soft); font-size: 11px; white-space: nowrap; }
.dropdown-trigger > strong { min-width: 0; overflow: hidden; font-size: 13px; font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }
.dropdown-trigger > svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: transform 150ms ease; }
.dropdown-trigger[aria-expanded='true'] { border-color: color-mix(in srgb, var(--primary) 55%, var(--border)); }
.dropdown-trigger[aria-expanded='true'] > svg:last-child { transform: rotate(180deg); }
.dropdown-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 35;
  width: max(100%, 210px);
  max-height: 280px;
  padding: 5px;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: auto;
  background: color-mix(in srgb, var(--surface) 97%, transparent);
  box-shadow: 0 14px 34px rgba(24, 35, 48, .14);
  backdrop-filter: blur(18px);
  animation: panel-in 140ms ease-out;
}
.dropdown-menu.align-right { right: 0; left: auto; }
.dropdown-menu button {
  width: 100%;
  min-height: 34px;
  padding: 6px 9px;
  border: 0;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--text-soft);
  background: transparent;
  cursor: pointer;
  text-align: left;
}
.dropdown-menu button:hover { color: var(--text); background: var(--muted); }
.dropdown-menu button[aria-checked='true'] { color: var(--text); background: var(--primary-soft); }
.dropdown-menu button[aria-checked='true']::after { content: '✓'; color: var(--primary); font-weight: 700; }

.filter-button,
.plain-control {
  padding: 0 13px;
  color: var(--text-soft);
  cursor: pointer;
}

.filter-button:hover,
.plain-control:hover { color: var(--text); background: var(--muted); }
.filter-button.icon-only { width: 42px; padding: 0; display: grid; place-items: center; }
.filter-button[aria-expanded='true'] { color: var(--primary); border-color: color-mix(in srgb, var(--primary) 45%, var(--border)); background: var(--primary-soft); }

.more-filters {
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  display: grid;
  grid-template-columns: 220px 220px auto;
  gap: 12px;
  justify-content: end;
  background: var(--muted);
}

.toolbar-secondary {
  min-height: 52px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.model-total {
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  white-space: nowrap;
}
.model-total strong { font-size: 15px; }
.model-total span { color: var(--text-soft); font-size: 13px; }

.toolbar-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.segmented {
  min-height: 34px;
  padding: 3px;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  background: var(--muted);
}

.segmented button {
  min-width: 52px;
  height: 28px;
  padding: 0 9px;
  border: 0;
  border-radius: 6px;
  color: var(--text-soft);
  background: transparent;
  cursor: pointer;
  font-size: 12px;
}

.segmented button:hover { color: var(--text); }
.segmented button.active {
  color: #fff;
  background: var(--primary);
  box-shadow: 0 1px 3px rgba(24, 35, 48, .16);
}

.sort-control {
  width: auto;
  min-height: 34px;
  padding: 0 8px 0 10px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.sort-control svg { width: 15px; height: 15px; }
.sort-control strong { min-width: 58px; font-size: 12px; font-weight: 550; text-align: center; }
.sort-control .chevron { width: 13px; height: 13px; }
.sort-dropdown .dropdown-menu { min-width: 190px; }

.icon-segment button { min-width: 30px; width: 30px; padding: 0; display: grid; place-items: center; }
.icon-segment svg { width: 15px; height: 15px; }

.catalog-results { margin-top: 12px; }
.model-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }

.catalog-card {
  min-width: 0;
  min-height: 430px;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}
.catalog-card:hover {
  border-color: color-mix(in srgb, var(--primary) 36%, var(--border));
  box-shadow: 0 12px 30px rgba(24, 35, 48, .07);
  transform: translateY(-1px);
}

.card-head { display: flex; align-items: flex-start; gap: 11px; }
.vendor-icon {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: #1a1d21;
  background: #f6f7f8;
  font-size: 16px;
  font-weight: 760;
}
html[data-theme='dark'] .vendor-icon { color: #f1f4f6; background: #23272c; }
.vendor-icon.anthropic { color: #cf6b4b; background: #fff7f3; }
.vendor-icon.google { color: #2e75d4; background: #f2f7ff; }
.vendor-icon.xai { color: #fff; background: #111; }
.vendor-icon.deepseek { color: #3271e7; background: #edf4ff; }
html[data-theme='dark'] .vendor-icon.anthropic { background: #2e1d18; }
html[data-theme='dark'] .vendor-icon.google,
html[data-theme='dark'] .vendor-icon.deepseek { background: #14233b; }
.vendor-icon.model-svg-icon svg {
  width: 24px;
  height: 24px;
  display: block;
}
.vendor-icon.model-svg-anthropic,
.table-model .vendor-icon.model-svg-anthropic,
.table-vendor-icon.model-svg-anthropic,
.drawer-provider-mark.model-svg-anthropic,
.vendor-icon.model-svg-claude,
.table-model .vendor-icon.model-svg-claude,
.table-vendor-icon.model-svg-claude,
.drawer-provider-mark.model-svg-claude { color: #d97757; }
.table-model .vendor-icon.model-svg-icon svg { width: 20px; height: 20px; }

.card-title { min-width: 0; flex: 1; }
.card-title p { margin: 0; color: var(--text-soft); font-size: 12px; line-height: 1.3; }
.card-title h2 { margin: 3px 0 0; overflow: hidden; color: var(--text); font-size: 18px; line-height: 1.25; text-overflow: ellipsis; white-space: nowrap; }
.card-title code { display: block; margin-top: 2px; overflow: hidden; color: var(--text-faint); font-size: 11px; line-height: 1.4; text-overflow: ellipsis; white-space: nowrap; }

.copy-model,
.details-button,
.drawer-close {
  border: 0;
  display: grid;
  place-items: center;
  color: var(--text-soft);
  background: transparent;
  cursor: pointer;
}
.copy-model { width: 30px; height: 30px; flex: 0 0 30px; border-radius: 6px; }
.copy-model:hover,
.drawer-close:hover { color: var(--text); background: var(--muted); }
.copy-model svg { width: 16px; height: 16px; }

.endpoint-tags { min-height: 25px; margin-top: 16px; display: flex; flex-wrap: wrap; gap: 6px; }
.endpoint-tag,
.group-tag,
.billing-tag,
.status-tag {
  min-height: 22px;
  padding: 2px 8px;
  border: 1px solid var(--border);
  border-radius: 7px;
  display: inline-flex;
  align-items: center;
  color: var(--text-soft);
  background: var(--muted);
  font-size: 10px;
  line-height: 1.2;
}

.model-description {
  min-height: 44px;
  margin: 13px 0 0;
  display: -webkit-box;
  overflow: hidden;
  color: var(--text-soft);
  font-size: 13px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.model-facts {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.model-facts span { min-width: 0; }
.model-facts small { display: block; color: var(--text-faint); font-size: 10px; }
.model-facts strong { display: block; margin-top: 1px; overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }

.price-list {
  margin-top: 15px;
  padding-top: 13px;
  border-top: 1px solid var(--border);
  display: grid;
  gap: 8px;
}
.price-row { display: grid; grid-template-columns: 46px minmax(72px, auto) 1fr; align-items: baseline; gap: 8px; }
.price-row > span { color: var(--text-soft); font-size: 12px; }
.price-row strong { color: var(--primary); font-size: 14px; text-align: right; }
.price-row small { min-width: 0; overflow: hidden; color: var(--text-faint); font-size: 10px; text-align: right; text-overflow: ellipsis; white-space: nowrap; }
.price-row del { margin-left: 3px; }

.card-footer {
  min-height: 39px;
  margin-top: auto;
  padding-top: 14px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  align-items: center;
  gap: 3px 10px;
}
.card-tags { min-width: 0; grid-column: 1; grid-row: 1; display: flex; align-items: center; gap: 6px; overflow: hidden; white-space: nowrap; }
.card-tags .billing-tag { margin-right: 0; }
.card-footer > .metric-strip { grid-column: 1; grid-row: 2; justify-self: start; }
.card-footer > .details-button { grid-column: 2; grid-row: 1 / 3; align-self: center; }
.group-tag {
  max-width: 160px;
  min-height: 20px;
  padding: 0 6px;
  border: 0;
  border-radius: 999px;
  overflow: hidden;
  background: transparent;
  font-size: 14px;
  font-weight: 500;
  line-height: 20px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.group-color-amber,
.group-color-orange,
.group-color-yellow { color: var(--group-warning); }
.group-color-blue,
.group-color-indigo { color: var(--group-chart-1); }
.group-color-cyan,
.group-color-teal { color: var(--group-chart-2); }
.group-color-green { color: var(--group-success); }
.group-color-grey { color: var(--text-soft); }
.group-color-light-blue { color: var(--group-info); }
.group-color-light-green { color: var(--group-light-green); }
.group-color-lime { color: var(--group-chart-3); }
.group-color-pink { color: var(--group-chart-5); }
.group-color-purple,
.group-color-violet { color: var(--group-chart-4); }
.group-color-red { color: var(--group-destructive); }
.rate-tag {
  min-height: 20px;
  padding: 1px 7px;
  border: 1px solid var(--border);
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  color: var(--text-soft);
  background: var(--muted);
  font: 500 12px/1 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  white-space: nowrap;
}
.rate-info { color: rgb(0, 112, 176); border-color: rgba(0, 132, 204, .18); background: rgba(0, 132, 204, .09); }
.rate-warning { color: rgb(176, 103, 0); border-color: rgba(205, 137, 0, .2); background: rgba(205, 137, 0, .1); }
.rate-neutral { color: var(--text-soft); background: color-mix(in srgb, var(--muted) 76%, var(--surface)); }
.billing-tag { margin-right: auto; }
.details-button {
  height: 30px;
  padding: 0 9px;
  border: 1px solid var(--border);
  border-radius: 6px;
  grid-auto-flow: column;
  gap: 4px;
  color: var(--text);
  font-size: 11px;
}
.details-button:hover { border-color: color-mix(in srgb, var(--primary) 42%, var(--border)); background: var(--primary-soft); }
.details-button svg { width: 13px; height: 13px; }

.metric-strip {
  width: 132px;
  display: grid;
  grid-template-columns: 38px 48px 30px;
  gap: 8px;
  color: var(--text-soft);
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.metric-item { min-width: 0; }
.metric-item small { display: block; overflow: hidden; color: color-mix(in srgb, var(--text-faint) 78%, transparent); font-size: 10px; line-height: 16px; text-overflow: ellipsis; white-space: nowrap; }
.metric-item strong { display: block; overflow: hidden; color: color-mix(in srgb, var(--text-soft) 86%, transparent); font: 400 12px/16px ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; text-overflow: ellipsis; white-space: nowrap; }
.status-bars { height: 16px; display: flex; align-items: center; justify-content: flex-end; gap: 2px; }
.status-bar { width: 4px; border-radius: 999px; }
.status-bar-1 { height: 8px; }
.status-bar-2 { height: 10px; }
.status-bar-3 { height: 12px; }
.status-excellent { background: #10b981; }
.status-good { background: #34d399; }
.status-warning { background: #f59e0b; }
.status-critical { background: #ef4444; }
.status-unknown { background: #9ca3af; }
.status-empty { background: color-mix(in srgb, var(--text-faint) 18%, transparent); }

.catalog-table-wrap { border: 1px solid var(--border); border-radius: 8px; overflow: auto; background: var(--surface); }
.catalog-table { width: 100%; min-width: 1180px; border-collapse: collapse; table-layout: fixed; }
.catalog-table th,
.catalog-table td { padding: 12px 10px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: middle; font-size: 12px; }
.catalog-table th { height: 42px; padding: 8px 10px; border-bottom: 1px solid var(--border); color: var(--text-soft); background: var(--surface); font-size: 12px; font-weight: 500; text-align: left; }
.catalog-table th:nth-child(1) { width: 205px; }
.catalog-table th:nth-child(2) { width: 105px; }
.catalog-table th:nth-child(3) { width: 190px; }
.catalog-table th:nth-child(4) { width: 120px; }
.catalog-table th:nth-child(5) { width: 125px; }
.catalog-table th:nth-child(6) { width: 110px; }
.catalog-table th:nth-child(7) { width: 115px; }
.catalog-table th:nth-child(8) { width: 210px; }
.catalog-table tr:last-child td { border-bottom: 0; }
.catalog-table tbody tr { cursor: pointer; transition: background-color 150ms ease; }
.catalog-table tbody tr:hover,
.catalog-table tbody tr:focus-visible { outline: 0; background: color-mix(in srgb, var(--muted) 52%, transparent); }
.table-sort-button { height: 26px; padding: 0; border: 0; display: inline-flex; align-items: center; gap: 7px; color: inherit; background: transparent; cursor: pointer; font: inherit; }
.table-sort-button svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 1.6; opacity: .55; }
.table-sort-button.active { color: var(--text); }
.table-sort-button.active svg { opacity: 1; }
.table-model { min-width: 0; display: flex; align-items: center; gap: 8px; }
.table-model .vendor-icon { width: 16px; height: 16px; flex: 0 0 16px; border-radius: 0; color: var(--text); background: transparent; font-size: 9px; }
.table-model .vendor-icon.model-svg-icon svg { width: 14px; height: 14px; }
.table-model strong { min-width: 0; overflow: hidden; font: 500 13px/1.3 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; text-overflow: ellipsis; white-space: nowrap; }
.table-type { color: var(--primary); font-weight: 500; white-space: nowrap; }
.table-price-cell { min-width: 0; display: grid; gap: 2px; }
.table-price-cell strong { overflow: hidden; color: var(--primary); font: 600 13px/1.3 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; text-overflow: ellipsis; white-space: nowrap; }
.table-price-cell small { overflow: hidden; color: var(--text-faint); font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.table-price-cell span { color: color-mix(in srgb, var(--text-faint) 72%, transparent); font-size: 11px; }
.table-price-cell del { margin-left: 2px; }
.table-empty { color: var(--text-faint); }
.table-vendor { min-width: 0; display: flex; align-items: center; gap: 7px; font-size: 13px; white-space: nowrap; }
.table-vendor-icon { width: 14px; height: 14px; flex: 0 0 14px; display: grid; place-items: center; }
.table-vendor-icon.model-svg-icon svg { width: 12px; height: 12px; display: block; }
.table-badge-list { min-width: 0; display: flex; align-items: center; gap: 8px; overflow: hidden; }
.table-text-badge { min-width: 0; overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.table-group { min-width: 0; display: flex; align-items: center; gap: 8px; overflow: hidden; }
.table-group .group-tag { min-width: 0; max-width: 145px; }
.table-group .rate-tag { flex: 0 0 auto; }

.catalog-message,
.empty-state {
  min-height: 300px;
  border: 1px solid var(--border);
  border-radius: 8px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  color: var(--text-soft);
  background: var(--surface);
  text-align: center;
}
.catalog-message .spinner {
  width: 24px;
  height: 24px;
  border: 2px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: pricing-spin .8s linear infinite;
}
.catalog-message button { min-height: 34px; }
.empty-state svg { width: 30px; height: 30px; color: var(--text-faint); }
@keyframes pricing-spin { to { transform: rotate(360deg); } }

.catalog-pagination {
  margin-top: 20px;
  padding: 12px 16px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--text-soft);
  font-size: 14px;
}
.catalog-pagination p { margin: 0; }
.pagination-actions { display: flex; align-items: center; gap: 8px; }
.catalog-pagination button {
  min-width: 82px;
  height: 28px;
  padding: 0 10px;
  border: 1px solid var(--border);
  border-radius: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: var(--text-soft);
  background: var(--surface);
  font: inherit;
  font-size: 12.8px;
  font-weight: 500;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition: color 150ms ease, background-color 150ms ease, border-color 150ms ease, box-shadow 150ms ease, transform 100ms ease;
}
.catalog-pagination button svg {
  width: 14px;
  height: 14px;
  flex: 0 0 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.catalog-pagination button:hover:not(:disabled) { color: var(--text); background: var(--muted); }
.catalog-pagination button:focus-visible { outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 28%, transparent); }
.catalog-pagination button:active:not(:disabled) { transform: translateY(1px); }
.catalog-pagination button:disabled { opacity: .5; cursor: default; pointer-events: none; }

.drawer-backdrop {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: rgba(16, 20, 24, .34);
  backdrop-filter: blur(1.5px);
  animation: backdrop-in 160ms ease-out;
}
.model-drawer {
  position: fixed;
  inset: 0 0 0 auto;
  z-index: 81;
  width: min(80vw, 1120px);
  min-width: 680px;
  height: 100dvh;
  padding: 0;
  border: 0;
  border-left: 1px solid var(--border);
  overflow: hidden;
  color: var(--text);
  background: var(--surface);
  box-shadow: none;
  animation: drawer-in 220ms cubic-bezier(.16, 1, .3, 1);
}
@keyframes backdrop-in { from { opacity: 0; } }
@keyframes drawer-in { from { transform: translateX(40px); opacity: .5; } }
body.drawer-open { overflow: hidden; }
.drawer-close {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 4;
  width: 32px;
  height: 32px;
  border-radius: 7px;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  backdrop-filter: blur(12px);
}
.drawer-close svg { width: 17px; height: 17px; }
#drawer-content { height: 100%; }
.official-details-frame {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  color-scheme: light dark;
  background: var(--surface);
}
.drawer-inner svg,
.drawer-close svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.drawer-inner {
  height: 100%;
  padding: 48px 24px 24px;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}
.drawer-heading { min-height: 72px; padding-bottom: 16px; }
.drawer-title-line { min-width: 0; display: flex; align-items: center; gap: 8px; }
.drawer-provider-mark {
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  display: grid;
  place-items: center;
  color: var(--text-soft);
  font-size: 17px;
  font-weight: 800;
}
.drawer-provider-mark.anthropic { color: #d66e4d; }
.drawer-provider-mark.google { color: #3178d4; }
.drawer-provider-mark.xai { color: var(--text); }
.drawer-provider-mark.deepseek { color: #3271e7; }
.drawer-provider-mark.model-svg-icon svg {
  width: 20px;
  height: 20px;
  display: block;
  fill: currentColor;
  stroke: none;
  stroke-width: 0;
}
.drawer-heading h2 {
  min-width: 0;
  margin: 0;
  overflow: hidden;
  font: 750 24px/1.25 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.drawer-copy { width: 26px; height: 26px; flex: 0 0 26px; }
.drawer-copy svg { width: 13px; height: 13px; }
.drawer-heading p { margin: 7px 0 0; display: flex; align-items: center; gap: 8px; color: var(--text-soft); font-size: 12px; }
.drawer-heading p i { color: var(--text-faint); font-style: normal; }
.drawer-billing { color: var(--primary); }
.drawer-tabs {
  min-height: 40px;
  padding: 4px;
  border-radius: 12px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px;
  background: color-mix(in srgb, var(--muted) 70%, transparent);
}
.drawer-tabs button {
  min-width: 0;
  height: 32px;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: var(--text-soft);
  background: transparent;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
}
.drawer-tabs button svg { width: 14px; height: 14px; }
.drawer-tabs button:hover { color: var(--text); }
.drawer-tabs button.active { color: var(--text); border-color: color-mix(in srgb, var(--border) 70%, transparent); background: var(--surface); box-shadow: 0 1px 3px rgba(24, 35, 48, .1); }
.drawer-tabs button:focus-visible { outline: 2px solid color-mix(in srgb, var(--primary) 65%, transparent); outline-offset: 0; }
.drawer-panel { min-width: 0; padding-top: 16px; }
.drawer-section { margin-top: 24px; }
.drawer-section:first-child { margin-top: 0; }
.drawer-section h3,
.drawer-pricing-card h3 { margin: 0 0 12px; color: var(--text-soft); font-size: 12px; font-weight: 650; text-transform: uppercase; }
.drawer-section-note { margin: 8px 0 0; color: var(--text-faint); font-size: 11px; }
.drawer-metrics {
  border: 1px solid var(--border);
  border-radius: 9px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  overflow: hidden;
  background: color-mix(in srgb, var(--muted) 22%, transparent);
}
.drawer-metrics > div { min-width: 0; min-height: 50px; padding: 8px 12px; display: flex; align-items: center; gap: 8px; }
.drawer-metrics > div + div { border-left: 1px solid var(--border); }
.drawer-metrics svg { width: 14px; height: 14px; flex: 0 0 14px; color: var(--text-faint); }
.drawer-metrics span { min-width: 0; }
.drawer-metrics small { display: block; overflow: hidden; color: var(--text-soft); font-size: 10px; font-weight: 550; text-overflow: ellipsis; text-transform: uppercase; white-space: nowrap; }
.drawer-metrics strong { display: block; margin-top: 2px; overflow: hidden; font: 650 14px/1.2 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; text-overflow: ellipsis; white-space: nowrap; }
.drawer-pricing-card { margin-top: 24px; padding: 16px; border: 1px solid var(--border); border-radius: 12px; background: color-mix(in srgb, var(--surface) 86%, var(--muted)); box-shadow: 0 1px 3px rgba(24, 35, 48, .05); }
.drawer-pricing-card > section + section { margin-top: 20px; }
.base-price-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.base-price-item { min-width: 0; padding: 12px; border: 1px solid var(--border); border-radius: 9px; background: color-mix(in srgb, var(--muted) 24%, transparent); }
.base-price-item small { display: block; color: var(--text-soft); font-size: 12px; }
.base-price-item strong { display: block; margin-top: 5px; overflow: hidden; font: 650 16px/1.25 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; text-overflow: ellipsis; white-space: nowrap; }
.base-price-item strong span { margin-left: 5px; color: var(--text-faint); font-size: 11px; font-weight: 400; }
.base-price-wide { width: 100%; }
.cache-price-item { margin-top: 12px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 9px; display: flex; align-items: baseline; justify-content: space-between; gap: 16px; background: color-mix(in srgb, var(--muted) 24%, transparent); }
.cache-price-item > span { color: var(--text-soft); font-size: 13px; }
.cache-price-item strong { font: 500 14px/1.2 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; }
.cache-price-item small { margin-left: 5px; color: var(--text-faint); font-size: 11px; font-weight: 400; }
.drawer-price-table { margin-inline: -16px; overflow: auto hidden; }
.drawer-price-table table { width: 100%; min-width: 610px; border-collapse: collapse; }
.drawer-price-table th,
.drawer-price-table td { height: 50px; padding: 8px; border-bottom: 1px solid var(--border); text-align: left; font-size: 12px; white-space: nowrap; }
.drawer-price-table th { height: 40px; color: var(--text-soft); font-size: 10px; font-weight: 600; text-transform: uppercase; }
.drawer-price-table th:nth-child(n+3),
.drawer-price-table td:nth-child(n+3) { text-align: right; }
.drawer-price-table tr:last-child td { border-bottom: 0; }
.drawer-price-table .group-tag { max-width: 190px; }
.drawer-model-section > h3 { margin-bottom: 12px; }
.drawer-info-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.drawer-info-grid > div { min-width: 0; min-height: 66px; padding: 12px; border: 1px solid var(--border); border-radius: 9px; background: color-mix(in srgb, var(--muted) 22%, transparent); }
.drawer-info-grid small { display: block; color: var(--text-soft); font-size: 11px; }
.drawer-info-grid strong { display: block; margin-top: 6px; overflow-wrap: anywhere; font-size: 13px; }
.drawer-info-grid .billing-tag { min-height: 20px; margin: 0; border: 0; color: var(--primary); background: transparent; font-size: 13px; }
.drawer-tag-list { margin-top: 6px; display: flex; flex-wrap: wrap; gap: 5px; }
.drawer-tag-list .endpoint-tag { min-height: 20px; padding: 1px 7px; border-radius: 999px; font-size: 11px; }
.performance-empty { min-height: 74px; padding: 14px; border: 1px dashed var(--border); border-radius: 9px; display: grid; place-items: center; align-content: center; color: var(--text-soft); text-align: center; }
.performance-empty svg { width: 17px; height: 17px; color: var(--text-faint); }
.performance-empty strong { margin-top: 5px; font-size: 13px; }
.performance-empty p { margin: 2px 0 0; color: var(--text-faint); font-size: 11px; }
.metric-detail-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.api-panel { min-width: 0; display: grid; gap: 24px; }
.api-example-section,
.api-doc-section { min-width: 0; }
.api-example-section > h3,
.api-doc-section > h3 { margin: 0 0 10px; display: flex; align-items: center; gap: 7px; font-size: 16px; font-weight: 700; }
.api-example-section > h3 svg,
.api-doc-section > h3 svg { width: 15px; height: 15px; color: var(--text-soft); }
.api-example-controls { min-width: 0; min-height: 34px; margin-bottom: 10px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.api-tabs { min-width: 0; display: flex; align-items: center; gap: 2px; }
.api-tabs button { height: 30px; padding: 0 11px; border: 0; border-radius: 999px; color: var(--text-soft); background: transparent; cursor: pointer; font-size: 12px; white-space: nowrap; }
.api-tabs button:hover { color: var(--text); background: color-mix(in srgb, var(--muted) 56%, transparent); }
.api-tabs button.active { color: var(--text); background: var(--surface); box-shadow: 0 1px 7px rgba(24, 35, 48, .12); }
.api-code-box { position: relative; width: 100%; min-width: 0; min-height: 370px; border: 1px solid var(--border); border-radius: 16px; overflow: hidden; background: color-mix(in srgb, var(--surface) 92%, var(--muted)); }
.api-code-box pre { width: 100%; max-width: 100%; min-height: 368px; margin: 0; padding: 20px 48px 20px 16px; overflow: auto; color: var(--text); font: 12px/1.95 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; tab-size: 2; white-space: pre; }
.api-code-box button { position: absolute; top: 10px; right: 10px; width: 30px; height: 30px; padding: 0; border: 0; border-radius: 7px; display: grid; place-items: center; color: var(--text-soft); background: color-mix(in srgb, var(--surface) 85%, transparent); cursor: pointer; }
.api-code-box button:hover { color: var(--text); background: var(--muted); }
.api-code-box button svg { width: 15px; height: 15px; }
.api-key-note { margin: 10px 0 0; color: var(--text-soft); font-size: 12px; }
.api-key-note code,
.api-doc-section p code { padding: 1px 4px; border-radius: 4px; color: var(--text); background: var(--muted); font: 11px/1.5 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; }
.api-doc-section { padding-top: 2px; }
.api-doc-section p { margin: 6px 0 0; color: var(--text-soft); font-size: 13px; line-height: 1.7; }
.api-table-wrap { width: 100%; max-width: 100%; min-width: 0; border: 1px solid var(--border); border-radius: 9px; overflow: auto hidden; }
.api-table { width: 100%; min-width: 700px; border-collapse: collapse; }
.api-table th,
.api-table td { padding: 10px 12px; border-bottom: 1px solid var(--border); text-align: left; font-size: 12px; vertical-align: middle; }
.api-table th { height: 40px; color: var(--text-soft); background: color-mix(in srgb, var(--muted) 42%, transparent); font-size: 10px; font-weight: 650; text-transform: uppercase; }
.api-table tr:last-child td { border-bottom: 0; }
.api-table td code { color: var(--text); font: 600 12px/1.4 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; }
.api-table td > span { color: var(--text-soft); }
.parameter-table th:nth-child(1) { width: 23%; }
.parameter-table th:nth-child(2) { width: 14%; }
.parameter-table th:nth-child(3) { width: 24%; }
.rate-table { min-width: 520px; }
.rate-table th:not(:first-child),
.rate-table td:not(:first-child) { text-align: right; }
html[data-theme='dark'] .api-code-box { background: #111418; }
html[data-theme='dark'] .api-tabs button.active { background: #252a30; }

@media (max-width: 1080px) {
  .filter-primary { grid-template-columns: minmax(260px, 1fr) 190px 190px 42px; }
  .model-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 820px) {
  .pricing-shell { padding-inline: 20px; }
  .pricing-hero { padding-top: 108px; }
  .filter-primary { grid-template-columns: 1fr 1fr 42px; }
  .search-control { grid-column: 1 / -1; }
  .toolbar-secondary { align-items: flex-start; flex-direction: column; }
  .toolbar-actions { justify-content: flex-start; }
  .model-drawer { width: min(94vw, 760px); min-width: 0; }
}

@media (max-width: 767px) {
  .model-grid { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .pricing-shell { padding-inline: 14px; }
  .pricing-hero { padding: 94px 0 26px; }
  .pricing-hero h1 { font-size: 28px; }
  .pricing-hero p { font-size: 14px; }
  .pricing-main { padding-top: 18px; }
  .filter-primary { grid-template-columns: 1fr 42px; gap: 8px; }
  .filter-primary .dropdown-control { grid-column: 1 / -1; }
  .filter-primary .filter-button { grid-column: 2; grid-row: 1; }
  .search-control { grid-column: 1; }
  .search-control kbd { display: none; }
  .more-filters { grid-template-columns: 1fr; justify-content: stretch; }
  .toolbar-actions { width: 100%; gap: 6px; }
  .segmented button { min-width: 45px; }
  .sort-control { order: 3; }
  .icon-segment { margin-left: auto; order: 4; }
  .model-grid { grid-template-columns: 1fr; }
  .catalog-pagination { flex-direction: column; justify-content: space-between; }
  .catalog-card { min-height: 410px; }
  .model-drawer { width: 100%; }
  .drawer-inner { padding: 44px 16px 28px; }
  .drawer-heading { min-height: 68px; }
  .drawer-heading h2 { font-size: 20px; }
  .drawer-metrics { grid-template-columns: 1fr; }
  .drawer-metrics > div + div { border-top: 1px solid var(--border); border-left: 0; }
  .drawer-info-grid { grid-template-columns: 1fr; }
  .drawer-tabs button { padding-inline: 7px; }
  .drawer-tabs button span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .drawer-pricing-card { padding: 14px; }
  .drawer-price-table { margin-inline: -14px; }
  .api-example-controls { align-items: flex-start; flex-direction: column; }
  .api-tabs { width: 100%; overflow-x: auto; }
  .language-tabs { justify-content: flex-start; }
  .api-code-box { min-height: 330px; border-radius: 12px; }
  .api-code-box pre { min-height: 328px; padding-left: 14px; font-size: 11px; }
}

@media (max-width: 459px) {
  .metric-strip { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .catalog-card,
  .model-drawer,
  .drawer-backdrop { animation: none; transition: none; }
}
