:root {
  color-scheme: dark;
  --ink: #f2f3f4;
  --muted: #8e9299;
  --muted-bright: #b9bdc3;
  --base: #090a0c;
  --surface: #111316;
  --surface-raised: #17191d;
  --surface-soft: #0d0f12;
  --line: #292c31;
  --line-bright: #3c4047;
  --silver: #d8dbdf;
  --red: #d73241;
  --red-hover: #ec4452;
  --red-wash: rgba(215, 50, 65, .1);
  --radius-small: 7px;
  --radius-medium: 12px;
  --radius-large: 18px;
  font-family: "Segoe UI", "Aptos", system-ui, sans-serif;
  background: var(--base);
  color: var(--ink);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

* { box-sizing: border-box; }
body { min-width: 320px; min-height: 100vh; margin: 0; background: var(--base); }
button, input { font: inherit; }
button { color: inherit; }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 2px solid var(--silver); outline-offset: 3px; }
[hidden] { display: none !important; }

.auth-screen { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.auth-card { display: grid; width: min(100%, 980px); min-height: 560px; grid-template-columns: minmax(0, 1fr) minmax(340px, 400px); grid-template-rows: auto 1fr; align-items: center; column-gap: clamp(52px, 7vw, 90px); padding: 46px clamp(38px, 6vw, 72px); border: 1px solid #303339; border-radius: var(--radius-large); background: linear-gradient(155deg, #111316, #0c0d10 76%); }
.auth-top-row { grid-column: 1 / -1; grid-row: 1; display: flex; align-items: start; justify-content: space-between; }
.language-switch { display: inline-flex; align-items: center; gap: 2px; padding: 3px; border: 1px solid #62666d; border-radius: var(--radius-small); background: #0b0d10; }
.language-option { min-width: 34px; min-height: 28px; padding: 0 7px; border: 1px solid transparent; border-radius: 4px; background: transparent; color: var(--muted-bright); cursor: pointer; font-size: 10px; font-weight: 650; letter-spacing: .04em; }
.language-option:hover { color: var(--ink); }
.language-option.is-active { border-color: #686d75; background: linear-gradient(155deg, #292c31, #191b1f); color: var(--ink); box-shadow: inset 0 1px 0 rgba(255,255,255,.08); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--ink); font-size: 13px; font-weight: 700; letter-spacing: .13em; text-decoration: none; }
.brand-light { color: var(--muted); font-weight: 500; }
.auth-copy { grid-column: 1; grid-row: 2; max-width: 480px; margin: 0; }
.auth-access { grid-column: 2; grid-row: 2; }
.eyebrow { margin: 0 0 13px; color: var(--muted); font-size: 10px; font-weight: 700; letter-spacing: .18em; }
.auth-copy h1, .page-heading h1 { margin: 0; font-family: Georgia, "Times New Roman", serif; font-weight: 400; letter-spacing: -.035em; }
.auth-copy h1 { font-size: clamp(40px, 3.2vw, 48px); line-height: 1.03; }
.auth-copy > p:last-child { max-width: 330px; margin: 19px 0 0; color: var(--muted-bright); font-size: 14px; line-height: 1.7; }
.form-stack { display: grid; gap: 12px; }
label { color: var(--muted-bright); font-size: 12px; font-weight: 600; }
input { width: 100%; min-height: 46px; padding: 0 13px; border: 1px solid var(--line-bright); border-radius: var(--radius-small); background: #0b0d10; color: var(--ink); }
input::placeholder { color: #62666d; }
input:focus { border-color: #9da1a8; outline: none; }
.button { display: inline-flex; min-height: 42px; align-items: center; justify-content: center; gap: 9px; padding: 0 16px; border: 1px solid transparent; border-radius: var(--radius-small); cursor: pointer; font-size: 12px; font-weight: 650; transition: background-color .15s ease, border-color .15s ease, color .15s ease, transform .15s ease; }
.button:active { transform: translateY(1px); }
.button-primary { border-color: #e6505d; background: var(--red); color: #fff; }
.button-primary:hover { border-color: #f46e79; background: var(--red-hover); }
.button-secondary { border-color: var(--line-bright); background: linear-gradient(160deg, #202328, #15171a); color: var(--silver); box-shadow: inset 0 1px 0 rgba(255,255,255,.07); }
.button-secondary:hover { border-color: #666b72; background: #25282d; }
.button-quiet { min-height: 38px; border-color: var(--line); background: transparent; color: var(--muted-bright); }
.button-quiet:hover { border-color: var(--line-bright); color: var(--ink); }
.button-small { min-height: 34px; padding: 0 11px; font-size: 11px; }
.button-wide { width: 100%; min-height: 46px; margin-top: 5px; }
.button-symbol { font-size: 18px; font-weight: 400; line-height: 1; }
.form-error { min-height: 17px; margin: 0; color: #ff7a84; font-size: 12px; line-height: 1.5; }
.auth-footnote { margin: 24px 0 0; color: #8e9299; font-size: 11px; line-height: 1.6; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; margin: 12px 0 22px; padding: 4px; border: 1px solid var(--line); border-radius: var(--radius-small); background: #090a0c; }
.auth-tab { min-height: 36px; border: 0; border-radius: 4px; background: transparent; color: var(--muted); cursor: pointer; font-size: 12px; }
.auth-tab.is-active { background: linear-gradient(155deg, #272a2f, #17191c); color: var(--silver); box-shadow: inset 0 1px 0 rgba(255,255,255,.08); }
.text-button { justify-self: start; padding: 6px 0; border: 0; background: transparent; color: var(--silver); cursor: pointer; font-size: 12px; text-decoration: underline; text-decoration-color: #6e7278; text-underline-offset: 3px; }
.text-button:hover { color: var(--ink); }
.key-owner { margin-left: 9px; color: #7f848b; font-size: 10px; font-weight: 400; }
.invite-list-heading { margin-top: 42px; }

.workspace { min-height: 100vh; }
.topbar { position: sticky; z-index: 5; top: 0; display: flex; min-height: 72px; align-items: center; gap: clamp(28px, 6vw, 92px); padding: 0 clamp(22px, 5.6vw, 86px); border-bottom: 1px solid #202226; background: rgba(9,10,12,.97); }
.topnav { display: flex; height: 72px; align-items: stretch; gap: 29px; }
.nav-link { position: relative; display: inline-flex; align-items: center; padding: 0 2px; border: 0; background: none; color: #8f9399; cursor: pointer; font-size: 12px; }
.nav-link:hover, .nav-link.is-active { color: var(--ink); }
.nav-link.is-active::after { position: absolute; right: 0; bottom: -1px; left: 0; height: 2px; background: var(--red); content: ""; }
.topbar-actions { display: flex; align-items: center; gap: 16px; margin-left: auto; }
.service-state { display: inline-flex; align-items: center; color: #aeb1b6; font-size: 11px; white-space: nowrap; }
.main-content { width: min(100% - 48px, 1180px); min-height: calc(100vh - 132px); margin: 0 auto; padding: clamp(42px, 6.8vw, 86px) 0 74px; }
.view { display: none; }
.view.is-visible { display: block; animation: view-enter .22s ease-out both; }
@keyframes view-enter { from { opacity: .65; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }
.page-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; }
.page-heading .eyebrow { margin-bottom: 17px; }
.page-heading h1 { font-size: clamp(36px, 4.7vw, 56px); line-height: 1.08; }
.page-description { margin: 13px 0 0; color: var(--muted-bright); font-size: 13px; line-height: 1.7; }
.overview-line { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin: 40px 0 56px; padding: 17px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); color: var(--muted); font-size: 11px; }
.overview-line strong { margin-right: 4px; color: var(--silver); font-size: 13px; font-weight: 650; font-variant-numeric: tabular-nums; }
.overview-divider { width: 1px; height: 15px; background: var(--line-bright); }
.section-heading { display: flex; min-height: 43px; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 12px; }
.section-heading h2 { margin: 0; font-size: 14px; font-weight: 600; letter-spacing: -.01em; }
.muted-copy { color: #777b82; font-size: 11px; }
.provider-list, .key-list { display: grid; border-top: 1px solid var(--line); }
.provider-row { display: grid; grid-template-columns: minmax(150px, 1fr) minmax(180px, 1.1fr) minmax(200px, 1.25fr) auto; align-items: center; gap: 18px; padding: 21px 8px; border-bottom: 1px solid var(--line); }
.provider-identity { min-width: 0; }
.provider-name { overflow: hidden; color: var(--ink); font-size: 13px; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.provider-url { overflow: hidden; margin-top: 6px; color: #777b82; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.route-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.route-tag { max-width: 100%; overflow: hidden; padding: 6px 8px; border: 1px solid #2b2e33; border-radius: 4px; background: #141619; color: #c1c4c8; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.provider-controls { display: flex; align-items: center; justify-content: end; gap: 9px; }
.provider-usage { min-width: 0; }
.provider-usage-assignment { overflow: hidden; margin-bottom: 8px; color: var(--muted); font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.usage-summary { margin: 34px 0 0; padding: 18px 0 20px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.usage-meters { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.usage-meters-compact { gap: 10px; }
.usage-meter { min-width: 0; }
.usage-meter-heading { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 7px; color: var(--muted-bright); font-size: 10px; }
.usage-meter-value { color: var(--silver); font-variant-numeric: tabular-nums; }
.usage-track { height: 5px; overflow: hidden; border-radius: 4px; background: #292c31; }
.usage-fill { display: block; height: 100%; border-radius: inherit; background: #b9bdc2; }
.usage-fill.is-warning { background: #c59b53; }
.usage-fill.is-critical { background: #d43746; }
.usage-meter-detail { display: block; margin-top: 5px; color: #777b82; font-size: 9px; font-variant-numeric: tabular-nums; }
.usage-note { margin: 10px 0 0; color: var(--muted); font-size: 10px; line-height: 1.55; }
.user-pool-summary { color: var(--muted); font-size: 10px; line-height: 1.5; }
.pool-options { margin: 14px 0 3px; padding: 0; border: 0; }
.pool-options legend { margin-bottom: 9px; color: var(--silver); font-size: 11px; }
.pool-options #pool-provider-list { display: grid; max-height: min(45vh, 360px); overflow: auto; border-top: 1px solid var(--line); }
.pool-option { display: grid; grid-template-columns: 18px minmax(0, 1fr); align-items: center; gap: 3px 10px; padding: 11px 4px; border-bottom: 1px solid var(--line); cursor: pointer; }
.pool-option input { grid-row: span 2; accent-color: #d43746; }
.pool-option-copy { overflow: hidden; color: var(--ink); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.pool-option-url { overflow: hidden; color: var(--muted); font: 9px ui-monospace, SFMono-Regular, Consolas, monospace; text-overflow: ellipsis; white-space: nowrap; }
.invite-limit-options { display: grid; gap: 8px; margin: 17px 0 4px; padding: 0; border: 0; }
.invite-limit-options legend { margin-bottom: 2px; color: var(--silver); font-size: 11px; }
.invite-limit-option { display: flex; align-items: flex-start; gap: 10px; padding: 11px 12px; border: 1px solid var(--line); border-radius: var(--radius-small); cursor: pointer; }
.invite-limit-option:focus-within { border-color: var(--line-bright); }
.invite-limit-option input { flex: 0 0 auto; margin: 2px 0 0; accent-color: #d43746; }
.invite-limit-option span { display: grid; gap: 4px; }
.invite-limit-option strong { color: var(--ink); font-size: 11px; font-weight: 600; }
.invite-limit-option small { color: var(--muted); font-size: 10px; line-height: 1.5; }
.invite-limit-warning { margin: 1px 0 0; padding: 9px 11px; border-left: 2px solid #d43746; color: #dcaeb2; font-size: 10px; line-height: 1.55; }
.key-state { margin-left: 8px; color: #db9298; font-size: 9px; font-weight: 500; }
.loading-state { padding: 21px 8px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 11px; }
.provider-enabled { display: inline-flex; align-items: center; gap: 7px; margin-right: 9px; color: #aeb2b8; font-size: 10px; white-space: nowrap; }
.provider-enabled::before { width: 6px; height: 6px; border-radius: 50%; background: #b9bdc2; content: ""; }
.provider-enabled.is-disabled { color: #696d73; }
.provider-enabled.is-disabled::before { background: #555960; }
.empty-state { display: grid; justify-items: start; padding: 34px 8px 24px; }
.empty-state h3 { margin: 21px 0 0; font-size: 16px; font-weight: 550; }
.empty-state p { max-width: 460px; margin: 9px 0 19px; color: var(--muted); font-size: 12px; line-height: 1.7; }
.page-error { margin-top: 8px; }
.notice-strip { display: flex; align-items: center; gap: 11px; margin: 38px 0 45px; padding: 13px 15px; border: 1px solid var(--line); border-radius: var(--radius-small); background: #101215; }
.notice-strip p { margin: 0; color: #a0a4aa; font-size: 11px; line-height: 1.6; }
.key-list-heading { margin-top: 0; }
.key-row { display: grid; grid-template-columns: minmax(180px, 1.1fr) minmax(140px, .8fr) minmax(150px, 1fr) auto; align-items: center; gap: 18px; min-height: 66px; padding: 11px 8px; border-bottom: 1px solid var(--line); }
.key-label { overflow: hidden; font-size: 12px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.key-prefix { color: #afb2b8; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 10px; }
.key-date { color: #777b82; font-size: 10px; }
.key-actions { display: flex; justify-content: end; gap: 7px; }
.button-danger-quiet { border-color: #433035; color: #d98990; }
.button-danger-quiet:hover { border-color: #88505a; background: #251719; }
.guide-layout { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(280px, .85fr); gap: 13px; margin-top: 44px; }
.guide-panel { min-width: 0; padding: 22px; border: 1px solid var(--line); border-radius: var(--radius-medium); background: linear-gradient(150deg, #131518 0%, #0e1012 78%); }
.guide-panel h2 { margin: 0; font-family: Georgia, "Times New Roman", serif; font-size: 22px; font-weight: 400; letter-spacing: -.02em; }
.endpoint-panel { grid-row: span 1; }
.copy-field { display: flex; min-width: 0; align-items: center; gap: 12px; margin-top: 20px; padding: 7px; border: 1px solid #35383d; border-radius: var(--radius-small); background: #090a0c; }
.copy-field code { min-width: 0; overflow: auto; flex: 1; padding-left: 7px; color: #d4d7dc; font-size: 11px; white-space: nowrap; }
.guide-note { margin: 13px 0 0; color: var(--muted); font-size: 11px; line-height: 1.7; }
.guide-note code, .empty-state code { color: #d4d7dc; font-size: 11px; }
.request-panel { grid-column: 1; grid-row: span 2; }
.guide-panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.guide-panel-heading .eyebrow { margin-bottom: 9px; }
.code-block { overflow: auto; margin: 23px 0 0; padding: 17px; border: 1px solid #282b30; border-radius: var(--radius-small); background: #090a0c; color: #d3d5d9; font: 11px/1.75 ui-monospace, SFMono-Regular, Consolas, monospace; white-space: pre; }
.models-panel { grid-column: 2; }
.inline-code { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; margin-top: 20px; padding: 12px 13px; border: 1px solid #2c2f34; border-radius: var(--radius-small); background: #090a0c; }
.inline-code code { color: #d3d5d9; font-size: 11px; }
.inline-code span { color: #777b82; font-size: 10px; }
.model-note { margin: 11px 0 0; color: var(--muted-bright); font-size: 11px; line-height: 1.65; }
.model-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; margin: 16px 0 0; padding: 0; list-style: none; }
.model-list li { min-width: 0; }
.model-list code { display: block; min-height: 38px; padding: 9px 10px; border: 1px solid #35383d; border-radius: var(--radius-small); background: #090a0c; color: #d4d7dc; font: 10px/1.5 ui-monospace, SFMono-Regular, Consolas, monospace; overflow-wrap: anywhere; }
.models-panel .inline-code { margin-top: 14px; }
.compatibility-panel { grid-column: 2; }
.compatibility-panel p:last-child { margin: 14px 0 0; color: var(--muted); font-size: 11px; line-height: 1.75; }
.app-footer { display: flex; justify-content: space-between; gap: 14px; padding: 18px clamp(24px, 5.6vw, 86px); border-top: 1px solid #202226; color: #666a70; font-size: 9px; letter-spacing: .12em; }
.app-footer span:last-child { font-size: 10px; letter-spacing: 0; }

.dialog-card { width: min(calc(100% - 32px), 560px); max-height: min(90vh, 850px); overflow: auto; padding: 0; border: 1px solid #3b3e44; border-radius: var(--radius-large); background: #101215; color: var(--ink); box-shadow: 0 28px 90px rgba(0,0,0,.62); }
.dialog-card::backdrop { background: rgba(0,0,0,.72); }
.dialog-narrow { width: min(calc(100% - 32px), 470px); }
.dialog-form { display: grid; gap: 11px; padding: 25px; }
.dialog-heading { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 10px; }
.dialog-heading .eyebrow { margin-bottom: 8px; }
.dialog-heading h2, .new-key-result h3 { margin: 0; font-family: Georgia, "Times New Roman", serif; font-size: 28px; font-weight: 400; letter-spacing: -.025em; }
.icon-button { display: grid; width: 40px; height: 40px; place-items: center; border: 1px solid var(--line); border-radius: var(--radius-small); background: #15171a; color: #a9adb3; cursor: pointer; font-size: 23px; }
.icon-button:hover { border-color: var(--line-bright); color: var(--ink); }
.label-aside { float: right; color: #747880; font-size: 10px; font-weight: 400; }
.field-hint { margin: -6px 0 3px; color: #777b82; font-size: 10px; line-height: 1.6; }
.form-section-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 8px; padding-top: 14px; border-top: 1px solid var(--line); }
.form-section-heading p { margin: 5px 0 0; color: #777b82; font-size: 10px; line-height: 1.5; }
.route-editor { display: grid; gap: 8px; }
.route-row { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr) 40px; gap: 8px; }
.route-row input { min-width: 0; min-height: 42px; font-size: 11px; }
.remove-route { min-height: 42px; padding: 0; color: #aaaeb4; font-size: 19px; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 7px; }
.new-key-result { display: grid; gap: 13px; padding: 26px; border-top: 1px solid var(--line); }
.new-key-result .eyebrow { margin: 0; color: #db7580; }
.new-key-result h3 { font-size: 25px; }
.new-key-result > p:not(.eyebrow) { margin: -6px 0 0; color: var(--muted); font-size: 11px; }
.confirm-dialog { width: min(calc(100% - 32px), 440px); }
.confirm-content { padding: 26px; }
.confirm-content .eyebrow { margin-bottom: 12px; color: #db9298; }
.confirm-content h2 { margin: 0; font-family: Georgia, "Times New Roman", serif; font-size: 27px; font-weight: 400; letter-spacing: -.025em; }
.confirm-message { margin: 12px 0 0; color: var(--muted-bright); font-size: 12px; line-height: 1.65; overflow-wrap: anywhere; }
.confirm-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 26px; }
.confirm-actions .button { min-width: 96px; min-height: 44px; }
.key-copy-field code { overflow-wrap: anywhere; white-space: normal; }
.toast { position: fixed; z-index: 20; right: 22px; bottom: 20px; max-width: min(360px, calc(100vw - 44px)); padding: 12px 16px; border: 1px solid #50545b; border-radius: var(--radius-small); background: #1a1d21; color: #e3e5e8; box-shadow: 0 12px 36px rgba(0,0,0,.3); font-size: 11px; opacity: 0; pointer-events: none; transform: translateY(8px); transition: opacity .16s ease, transform .16s ease; }
.toast.is-visible { opacity: 1; transform: translateY(0); }

@media (max-width: 760px) {
  .auth-screen { padding: 20px; }
  .auth-card { display: block; width: min(100%, 480px); min-height: 0; padding: 26px; }
  .auth-copy { margin: 48px 0 30px; }
  .auth-copy h1 { font-size: clamp(40px, 5.2vw, 44px); }
  .topbar { min-height: auto; flex-wrap: wrap; gap: 0 18px; padding: 15px 20px 0; }
  .topnav { order: 3; width: 100%; height: 49px; gap: clamp(20px, 8vw, 36px); overflow-x: auto; }
  .topbar-actions { gap: 9px; }
  .service-state { display: none; }
  .topbar-actions .button { min-height: 38px; padding: 0 10px; }
  .button-small { min-height: 44px; }
  .main-content { width: calc(100% - 40px); min-height: calc(100vh - 167px); padding: 42px 0 58px; }
  .page-heading { align-items: flex-start; }
  .page-heading .button { flex: 0 0 auto; }
  .overview-line { gap: 12px; margin: 30px 0 42px; }
  .provider-row { grid-template-columns: minmax(0, 1fr) auto; gap: 13px 12px; padding: 17px 2px; }
  .provider-identity { grid-column: 1; }
  .provider-controls { grid-column: 2; grid-row: 1; }
  .route-tags { grid-column: 1 / -1; }
  .provider-usage { grid-column: 1 / -1; }
  .provider-enabled { margin-right: 3px; }
  .guide-layout { grid-template-columns: 1fr; margin-top: 32px; }
  .request-panel, .models-panel, .compatibility-panel { grid-column: 1; grid-row: auto; }
  .app-footer { padding: 17px 20px; }
}

@media (max-width: 520px) {
  .brand { font-size: 11px; }
  .topbar { padding-right: 14px; padding-left: 14px; }
  .topnav { gap: 23px; }
  .model-list { grid-template-columns: 1fr; }
  .main-content { width: calc(100% - 32px); padding-top: 34px; }
  .page-heading { display: grid; gap: 20px; }
  .page-heading h1 { font-size: clamp(37px, 11vw, 47px); }
  .page-heading .button { justify-self: start; }
  .overview-line { align-items: flex-start; gap: 8px 10px; font-size: 10px; }
  .overview-divider { height: 13px; }
  .section-heading { align-items: flex-start; flex-direction: column; gap: 5px; margin-bottom: 9px; }
  .provider-controls { gap: 4px; }
  .provider-controls .button { min-width: 40px; padding: 0 9px; }
  .provider-controls { grid-column: 1 / -1; grid-row: 2; justify-content: flex-start; flex-wrap: wrap; }
  .provider-row .route-tags { grid-row: 3; }
  .provider-enabled { font-size: 0; }
  .provider-enabled::before { width: 8px; height: 8px; }
  .key-row { grid-template-columns: minmax(0, 1fr) auto; gap: 7px 10px; padding: 15px 2px; }
  .key-prefix { grid-column: 1; grid-row: 2; }
  .key-date { grid-column: 1; grid-row: 3; }
  .key-actions { grid-column: 2; grid-row: 1 / span 3; flex-direction: column; }
  .user-pool-summary { grid-column: 1; }
  .usage-meters { grid-template-columns: 1fr; gap: 13px; }
  .usage-meters-compact { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .notice-strip { align-items: flex-start; margin: 29px 0 34px; }
  .guide-panel { padding: 17px; }
  .guide-panel-heading { align-items: flex-start; }
  .guide-panel h2 { font-size: 20px; }
  .guide-panel-heading .button { flex: 0 0 auto; }
  .copy-field { gap: 7px; }
  .copy-field code { padding-left: 3px; font-size: 10px; }
  .dialog-form, .new-key-result { padding: 20px; }
  .confirm-content { padding: 21px; }
  .confirm-actions { margin-top: 22px; }
  .route-row { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr) 36px; gap: 5px; }
  .route-row input { padding: 0 8px; font-size: 10px; }
  .form-section-heading { align-items: flex-start; }
  .app-footer { align-items: flex-start; flex-direction: column; gap: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

.code-block::-webkit-scrollbar { height: 8px; width: 8px; }
.code-block::-webkit-scrollbar-track { background: transparent; }
.code-block::-webkit-scrollbar-thumb { background: #3a3d42; border-radius: 4px; }
.code-block::-webkit-scrollbar-thumb:hover { background: #4a4d53; }
.code-block { scrollbar-width: thin; scrollbar-color: #3a3d42 transparent; }
