:root {
  --ink: #0d0d0d;
  --muted: #686868;
  --subtle: #8f8f8f;
  --line: #e5e5e5;
  --line-strong: #d5d5d5;
  --surface: #fff;
  --surface-soft: #f7f7f7;
  --sidebar: #f9f9f9;
  --black: #171717;
  --green: #10a37f;
  --green-soft: #eaf8f4;
  --red: #c83232;
  --blue: #2563eb;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
.dev-body { margin: 0; min-width: 320px; min-height: 100vh; color: var(--ink); background: var(--surface); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
code, pre { font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* Application chrome */
.dev-topbar { position: fixed; inset: 0 0 auto 0; z-index: 50; height: 60px; display: flex; align-items: center; justify-content: space-between; padding: 0 18px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.94); backdrop-filter: blur(16px); }
.dev-topbar-left, .dev-topbar-actions { display: flex; align-items: center; }
.dev-brand { display: flex; align-items: center; gap: 9px; color: var(--ink); text-decoration: none; }
.dev-brand > img { width: 29px; height: 29px; object-fit: cover; display: block; border-radius: 8px; }
.dev-brand strong { font-size: 14px; font-weight: 650; letter-spacing: -.015em; }
.topbar-divider { width: 1px; height: 22px; margin: 0 12px; background: var(--line); }
.project-switcher { height: 34px; display: flex; align-items: center; gap: 8px; padding: 0 9px; border: 0; border-radius: 7px; color: #333; background: transparent; font-size: 12px; }
.project-switcher:hover { background: var(--surface-soft); }
.project-switcher strong { font-weight: 550; }
.project-switcher svg { width: 13px; height: 13px; color: var(--subtle); }
.project-dot { width: 18px; height: 18px; display: grid; place-items: center; border-radius: 5px; background: #e7e7e7; }
.project-dot::after { content: "D"; color: #555; font-size: 9px; font-weight: 700; }
.dev-topbar-actions { gap: 2px; }
.dev-topbar-actions > a { min-height: 34px; display: inline-flex; align-items: center; padding: 0 10px; border-radius: 7px; color: #4d4d4d; text-decoration: none; font-size: 12px; font-weight: 500; }
.dev-topbar-actions > a:hover { color: var(--ink); background: var(--surface-soft); }
.dev-topbar-actions .chat-link { margin-left: 6px; border: 1px solid var(--line-strong); color: var(--ink); background: white; }
.profile-button { width: 32px; height: 32px; display: grid; place-items: center; margin-left: 9px; padding: 0; border: 0; border-radius: 50%; color: white; background: #7656b5; }
.profile-button span { font-size: 11px; font-weight: 700; }
.guest-only { display: none !important; }
.docs-route-label { display: none; margin-left: 4px; color: #555; font-size: 12px; font-weight: 600; }
.sign-in-link { min-height: 34px; display: inline-flex; align-items: center; margin-left: 8px; padding: 0 12px; border: 1px solid var(--line-strong); border-radius: 7px; color: var(--ink); background: white; text-decoration: none; font-size: 12px; font-weight: 600; }
.sign-in-link:hover { background: var(--surface-soft); }
.docs-public .authed-only { display: none !important; }
.docs-public .guest-only.sign-in-link { display: inline-flex !important; }
.docs-public .guest-only.sidebar-sign-in { display: flex !important; }
.docs-public .docs-route-label { display: inline-flex; }
.docs-public .project-switcher,
.docs-public .topbar-divider { display: none; }
.docs-public .dev-account { opacity: .9; }

.dev-shell { min-height: 100vh; display: grid; grid-template-columns: 232px minmax(0, 1fr); padding-top: 60px; }
.dev-sidebar { position: fixed; top: 60px; bottom: 0; left: 0; z-index: 30; width: 232px; display: flex; flex-direction: column; padding: 14px 10px 12px; border-right: 1px solid var(--line); background: var(--sidebar); }
.dev-nav { display: grid; gap: 2px; }
.dev-nav > p { margin: 18px 10px 6px; color: #969696; font-size: 10px; font-weight: 650; text-transform: uppercase; letter-spacing: .08em; }
.dev-nav > p:first-child { margin-top: 5px; }
.dev-nav button, .dev-nav > a { position: relative; width: 100%; height: 36px; display: flex; align-items: center; gap: 10px; padding: 0 10px; border: 0; border-radius: 7px; color: #555; background: transparent; text-decoration: none; text-align: left; font-size: 12.5px; font-weight: 500; }
.dev-nav button:hover, .dev-nav > a:hover { color: var(--ink); background: #eee; }
.dev-nav button.active { color: var(--ink); background: #e9e9e9; font-weight: 600; }
.dev-nav svg { width: 16px; height: 16px; stroke-width: 1.8; }
.dev-nav .nav-external { width: 12px; height: 12px; margin-left: auto; color: #aaa; }
.dev-sidebar-foot { margin-top: auto; }
.api-health { padding: 11px 10px; border-bottom: 1px solid var(--line); color: #696969; font-size: 10.5px; }
.api-health span { display: flex; align-items: center; gap: 7px; }
.api-health i { width: 7px; height: 7px; border-radius: 50%; background: #22a06b; box-shadow: 0 0 0 3px #e2f4ed; }
.dev-account { display: flex; align-items: center; gap: 9px; min-width: 0; margin-top: 10px; padding: 7px 8px; border-radius: 8px; }
.dev-account:hover { background: #eee; }
.dev-account > span { width: 27px; height: 27px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; color: white; background: #7656b5; font-size: 10px; font-weight: 700; }
.dev-account div { min-width: 0; }
.dev-account strong, .dev-account small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dev-account strong { font-size: 10.5px; font-weight: 600; }
.dev-account small { margin-top: 2px; color: var(--subtle); font-size: 9.5px; text-transform: capitalize; }

/* Shared page primitives */
.dev-main { grid-column: 2; min-width: 0; padding: 48px clamp(28px, 5vw, 72px) 80px; }
.dev-view { display: none; width: min(1120px, 100%); margin: 0 auto; }
.dev-view.active { display: block; animation: page-in .18s ease-out; }
@keyframes page-in { from { opacity: 0; transform: translateY(3px); } }
.dev-heading { min-height: 70px; display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; margin-bottom: 30px; }
.dev-heading p, .eyebrow { display: block; margin: 0 0 8px; color: var(--subtle); font-size: 10px; font-weight: 650; text-transform: uppercase; letter-spacing: .09em; }
.dev-heading h1 { margin: 0; font-size: 29px; line-height: 1.15; font-weight: 650; letter-spacing: -.035em; }
.dev-heading div > span { display: block; margin-top: 8px; color: var(--muted); font-size: 13px; line-height: 1.5; }
.primary-button, .secondary-button { min-height: 38px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 0 14px; border-radius: 7px; font-size: 12px; font-weight: 600; white-space: nowrap; }
.primary-button { border: 1px solid var(--black); color: white; background: var(--black); box-shadow: 0 1px 2px rgba(0,0,0,.08); }
.primary-button:hover { background: #000; }
.secondary-button { border: 1px solid var(--line-strong); color: var(--ink); background: white; }
.secondary-button:hover { background: var(--surface-soft); }
.primary-button:disabled, .secondary-button:disabled { cursor: wait; opacity: .6; }
.primary-button svg, .secondary-button svg { width: 15px; height: 15px; }
.text-button { padding: 0; border: 0; color: var(--ink); background: transparent; font-size: 11px; font-weight: 600; }
.text-button:hover { text-decoration: underline; }
.section-heading, .section-title { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.section-heading { margin: 44px 0 14px; }
.section-heading h2, .section-title h2 { margin: 0; font-size: 14px; font-weight: 650; letter-spacing: -.01em; }
.section-heading p, .section-title p { margin: 5px 0 0; color: var(--muted); font-size: 11px; line-height: 1.45; }
.section-heading > span, .section-title > span { color: var(--subtle); font-size: 10px; }

/* Home */
.home-hero { display: grid; grid-template-columns: minmax(0, .9fr) minmax(420px, 1.1fr); gap: 54px; align-items: center; min-height: 340px; padding: 34px 0 46px; border-bottom: 1px solid var(--line); }
.home-hero h1 { max-width: 520px; margin: 0; font-size: clamp(38px, 5vw, 56px); line-height: 1.02; font-weight: 620; letter-spacing: -.055em; }
.home-hero > div:first-child > p { max-width: 520px; margin: 18px 0 0; color: var(--muted); font-size: 15px; line-height: 1.65; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 25px; }
.hero-code { min-width: 0; border: 1px solid #262626; border-radius: 12px; background: #111; color: #e8e8e8; box-shadow: 0 16px 50px rgba(0,0,0,.10); overflow: hidden; }
.hero-code > div { height: 42px; display: flex; align-items: center; justify-content: space-between; padding: 0 10px 0 14px; border-bottom: 1px solid #282828; color: #aaa; font-size: 10px; }
.hero-code button { width: 28px; height: 28px; display: grid; place-items: center; border: 0; border-radius: 5px; color: #aaa; background: transparent; }
.hero-code button:hover { color: white; background: #292929; }
.hero-code svg { width: 14px; height: 14px; }
.hero-code pre { min-height: 185px; margin: 0; padding: 22px; overflow: auto; color: #d9d9d9; font-size: 11px; line-height: 1.75; white-space: pre-wrap; overflow-wrap: anywhere; }
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: 10px; background: white; overflow: hidden; }
.metric-grid article { min-width: 0; padding: 18px 20px; border-right: 1px solid var(--line); }
.metric-grid article:last-child { border-right: 0; }
.metric-grid span, .metric-grid small, .metric-grid strong { display: block; }
.metric-grid span { color: var(--muted); font-size: 10px; font-weight: 550; }
.metric-grid strong { margin-top: 8px; font-size: 22px; font-weight: 620; letter-spacing: -.025em; }
.metric-grid small { margin-top: 4px; overflow: hidden; color: var(--subtle); font-size: 9.5px; text-overflow: ellipsis; white-space: nowrap; }
.home-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(340px, .8fr); gap: 16px; margin-top: 16px; }
.credit-card, .getting-started-card, .activity-panel, .endpoint-panel { border: 1px solid var(--line); border-radius: 10px; background: white; }
.credit-card { min-height: 188px; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: start; gap: 16px; padding: 22px; background: linear-gradient(135deg, #fbfbfb 0%, #f4f4f4 100%); }
.card-icon { width: 38px; height: 38px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 9px; background: white; }
.card-icon svg { width: 18px; height: 18px; }
.credit-card-copy > span { color: var(--muted); font-size: 10px; }
.credit-card-copy > strong { display: block; margin-top: 5px; font-size: 30px; font-weight: 620; letter-spacing: -.04em; }
.credit-card-copy > p { max-width: 340px; margin: 8px 0 0; color: var(--muted); font-size: 10px; line-height: 1.5; }
.credit-card .form-status { color: var(--red); }
.getting-started-card { padding: 20px; }
.getting-started-card .section-title { margin-bottom: 12px; }
.getting-started-card > button { width: 100%; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 11px; padding: 10px 6px; border: 0; border-top: 1px solid var(--line); color: var(--ink); background: transparent; text-align: left; }
.getting-started-card > button:hover { background: var(--surface-soft); }
.getting-started-card b { width: 23px; height: 23px; display: grid; place-items: center; border: 1px solid var(--line-strong); border-radius: 50%; font-size: 9px; font-weight: 600; }
.getting-started-card strong, .getting-started-card small { display: block; }
.getting-started-card strong { font-size: 10.5px; font-weight: 600; }
.getting-started-card small { margin-top: 3px; color: var(--subtle); font-size: 9px; }
.getting-started-card svg { width: 14px; height: 14px; color: var(--subtle); }
.overview-columns { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(330px, .8fr); gap: 16px; margin-top: 16px; }
.activity-panel, .endpoint-panel { padding: 20px; }
.recent-keys { margin: 14px -20px -20px; }
.recent-key { min-height: 54px; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 15px; padding: 10px 20px; border-top: 1px solid var(--line); }
.recent-key strong, .recent-key small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.recent-key strong { font-size: 10.5px; font-weight: 600; }
.recent-key small { margin-top: 3px; color: var(--subtle); font-size: 9px; }
.recent-key > span { color: var(--subtle); font-size: 9px; }
.empty-state { padding: 26px 20px; color: var(--muted); text-align: center; font-size: 11px; }
.endpoint-panel label { display: block; margin: 18px 0 7px; color: var(--subtle); font-size: 9px; font-weight: 650; text-transform: uppercase; letter-spacing: .06em; }
.copy-field { height: 40px; display: flex; align-items: center; border: 1px solid var(--line); border-radius: 7px; background: var(--surface-soft); overflow: hidden; }
.copy-field code { min-width: 0; flex: 1; padding: 0 11px; overflow: hidden; color: #3b3b3b; font-size: 9.5px; text-overflow: ellipsis; white-space: nowrap; }
.copy-field button, .secret-value button { width: 38px; height: 100%; display: grid; place-items: center; flex: 0 0 auto; border: 0; border-left: 1px solid var(--line); color: var(--subtle); background: transparent; }
.copy-field button:hover, .secret-value button:hover { color: var(--ink); background: #eee; }
.copy-field svg, .secret-value svg { width: 14px; height: 14px; }
.endpoint-note { display: flex; align-items: center; gap: 6px; margin-top: 11px; color: var(--subtle); font-size: 9px; }
.endpoint-note svg { width: 12px; height: 12px; }

/* Keys */
.notice { display: flex; align-items: center; gap: 9px; min-height: 44px; margin-bottom: 18px; padding: 10px 13px; border: 1px solid #dce6f5; border-radius: 8px; color: #31547c; background: #f5f8fc; font-size: 10.5px; line-height: 1.5; }
.notice svg { width: 15px; height: 15px; flex: 0 0 auto; }
.notice.warning { margin: 14px 0 0; border-color: #eadab7; color: #6d4a12; background: #fffaf0; }
.keys-panel { border: 1px solid var(--line); border-radius: 10px; background: white; overflow: hidden; }
.table-scroll { overflow-x: auto; }
.keys-table { width: 100%; min-width: 850px; border-collapse: collapse; font-size: 10.5px; }
.keys-table th { height: 42px; padding: 0 16px; border-bottom: 1px solid var(--line); color: var(--subtle); background: #fafafa; text-align: left; font-size: 9px; font-weight: 650; text-transform: uppercase; letter-spacing: .05em; white-space: nowrap; }
.keys-table td { height: 62px; padding: 9px 16px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.keys-table tr:last-child td { border-bottom: 0; }
.keys-table code { color: #555; font-size: 9.5px; }
.cell-muted { color: var(--subtle); font-size: 8.5px; }
.key-name { min-width: 165px; }
.key-name strong, .key-name small { display: block; }
.key-name strong { font-size: 10.5px; font-weight: 600; }
.key-name small { margin-top: 4px; color: var(--subtle); font-size: 8.5px; }
.status-pill { display: inline-flex; align-items: center; gap: 5px; color: #18794e; font-size: 9px; font-weight: 600; }
.status-pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #23a26d; }
.status-pill.revoked { color: #985858; }
.status-pill.revoked::before { background: #c06b6b; }
.table-action { width: 29px; height: 29px; display: grid; place-items: center; border: 1px solid transparent; border-radius: 6px; color: var(--subtle); background: transparent; }
.table-action:hover { border-color: #f0d1d1; color: var(--red); background: #fff7f7; }
.table-action svg { width: 14px; height: 14px; }

/* Playground */
.playground-view { width: min(1240px, 100%); }
.playground-grid { min-height: 620px; display: grid; grid-template-columns: minmax(350px, .72fr) minmax(0, 1.28fr); border: 1px solid var(--line); border-radius: 10px; background: white; overflow: hidden; }
.request-panel, .response-panel { min-width: 0; padding: 22px; }
.request-panel { border-right: 1px solid var(--line); background: #fcfcfc; }
.panel-heading { min-height: 30px; display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-bottom: 20px; }
.panel-heading h2 { margin: 0; font-size: 12px; font-weight: 650; }
.panel-heading > span { color: var(--subtle); font-size: 9px; }
.method-label { border-radius: 5px; padding: 4px 7px; color: #176b4d !important; background: #e8f6f0; font-weight: 700; }
.request-panel > label, .field-pair label { display: grid; gap: 7px; margin-bottom: 16px; color: #555; font-size: 9.5px; font-weight: 600; }
.request-panel input, .request-panel select, .request-panel textarea, .dev-dialog input { width: 100%; border: 1px solid var(--line-strong); border-radius: 7px; color: var(--ink); background: white; outline: none; }
.request-panel input, .request-panel select, .dev-dialog input { height: 40px; padding: 0 11px; }
.request-panel textarea { min-height: 170px; padding: 11px; resize: vertical; line-height: 1.55; }
.request-panel input:focus, .request-panel select:focus, .request-panel textarea:focus, .dev-dialog input:focus { border-color: #8b8b8b; box-shadow: 0 0 0 3px rgba(0,0,0,.055); }
.secret-input { position: relative; }
.secret-input input { padding-right: 42px; }
.secret-input button { position: absolute; top: 1px; right: 1px; width: 38px; height: 38px; display: grid; place-items: center; border: 0; color: var(--subtle); background: transparent; }
.secret-input svg { width: 14px; height: 14px; }
.field-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.toggle-row { min-height: 54px; display: flex !important; align-items: center; justify-content: space-between; gap: 14px; margin: 2px 0 17px !important; padding: 10px 12px; border: 1px solid var(--line); border-radius: 7px; background: white; }
.toggle-row strong, .toggle-row small { display: block; }
.toggle-row strong { color: var(--ink); font-size: 10px; }
.toggle-row small { margin-top: 3px; color: var(--subtle); font-size: 8.5px; line-height: 1.4; }
.toggle-row input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.toggle-row > i { position: relative; width: 34px; height: 19px; flex: 0 0 auto; border-radius: 10px; background: #c5c5c5; transition: background .2s; }
.toggle-row > i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 13px; height: 13px; border-radius: 50%; background: white; transition: transform .2s; }
.toggle-row input:checked + i { background: var(--black); }
.toggle-row input:checked + i::after { transform: translateX(15px); }
.run-button { width: 100%; }
.form-status { min-height: 16px; margin: 9px 0 0; color: var(--red); font-size: 9.5px; }
.response-panel { display: flex; flex-direction: column; background: #111; color: #e6e6e6; }
.response-panel .panel-heading { padding-bottom: 15px; border-bottom: 1px solid #292929; }
.response-panel .panel-heading > span { color: #949494; }
.response-panel pre { min-height: 420px; flex: 1; margin: 0; overflow: auto; color: #d8d8d8; font-size: 11px; line-height: 1.7; white-space: pre-wrap; overflow-wrap: anywhere; }
.response-footer { display: flex; flex-wrap: wrap; gap: 14px; padding-top: 14px; border-top: 1px solid #292929; color: #949494; font-size: 9px; }

/* Documentation */
.dev-view[data-panel="docs"] { width: min(1160px, 100%); }
.docs-page { width: 100%; display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 54px; align-items: start; }
.docs-rail { position: sticky; top: 84px; display: grid; gap: 14px; align-content: start; }
.docs-search { min-height: 36px; display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-soft); padding: 0 11px; color: var(--subtle); }
.docs-search svg { width: 13px; height: 13px; }
.docs-search input { width: 100%; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 11px; }
.docs-rail nav { display: grid; gap: 1px; }
.docs-rail nav > p { margin: 17px 0 6px; padding: 0 9px; color: var(--ink); font-size: 10px; font-weight: 650; }
.docs-rail nav > p:first-child { margin-top: 2px; }
.docs-rail a { min-height: 30px; display: flex; align-items: center; border-radius: 6px; padding: 0 9px; color: var(--muted); text-decoration: none; font-size: 11px; }
.docs-rail a:hover { color: var(--ink); background: var(--surface-soft); }
.docs-rail a.active { color: var(--ink); background: #eee; font-weight: 600; }
.docs-rail a[hidden] { display: none; }
.docs-content { min-width: 0; padding-bottom: 50px; }
.docs-breadcrumb, .docs-crumb { margin: 0 0 10px; color: var(--subtle); font-size: 10px; }
.docs-page-title { margin: 0; color: var(--ink); font-size: 42px; line-height: 1.08; font-weight: 650; letter-spacing: -.045em; }
.docs-lede { max-width: 680px; margin: 14px 0 0; color: var(--muted); font-size: 14px; line-height: 1.7; }
.docs-section { padding: 44px 0 0; scroll-margin-top: 86px; }
.docs-section[hidden] { display: none; }
.docs-section h2 { margin: 0; color: var(--ink); font-size: 24px; line-height: 1.25; font-weight: 650; letter-spacing: -.025em; }
.docs-section > p { max-width: 720px; margin: 12px 0 0; color: var(--muted); font-size: 13px; line-height: 1.75; }
.docs-quickstart { padding-top: 30px; }
.docs-quickstart-card { display: grid; grid-template-columns: minmax(240px, .9fr) minmax(0, 1.15fr); border: 1px solid var(--line); border-radius: 14px; background: var(--surface-soft); overflow: hidden; }
.docs-quickstart-copy { display: flex; flex-direction: column; justify-content: center; gap: 14px; padding: 28px; }
.docs-quickstart-copy h2 { font-size: 27px; }
.docs-quickstart-copy p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.65; }
.docs-quickstart-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 5px; }
.docs-btn-primary, .docs-btn-secondary { min-height: 35px; display: inline-flex; align-items: center; justify-content: center; padding: 0 13px; border-radius: 7px; font-size: 11px; font-weight: 600; }
.docs-btn-primary { border: 1px solid var(--black); color: white; background: var(--black); }
.docs-btn-secondary { border: 1px solid var(--line-strong); color: var(--ink); background: white; }
.docs-quickstart-code { min-width: 0; padding: 11px; }
.code-panel { border: 1px solid #222; border-radius: 10px; background: #101010; overflow: hidden; }
.docs-inline-code { height: 100%; }
.code-toolbar { min-height: 42px; display: flex; align-items: center; justify-content: space-between; padding: 0 9px 0 11px; border-bottom: 1px solid #242424; }
.code-mode { display: flex; gap: 3px; }
.code-mode button { height: 27px; padding: 0 9px; border: 0; border-radius: 5px; color: #999; background: transparent; font-size: 10px; }
.code-mode button.active { color: white; background: #292929; }
.code-toolbar-right { display: flex; align-items: center; gap: 5px; }
.code-lang-select select { height: 27px; border: 0; border-radius: 5px; color: #ddd; background: #242424; padding: 0 7px; font-size: 10px; }
.code-lang-select[hidden] { display: none; }
.code-toolbar > button, .code-toolbar-right > button { width: 28px; height: 28px; display: grid; place-items: center; border: 0; border-radius: 5px; color: #999; background: transparent; }
.code-toolbar button:hover { color: white; background: #292929; }
.code-toolbar svg { width: 14px; height: 14px; }
.code-panel pre { min-height: 270px; margin: 0; padding: 16px; overflow: auto; color: #e5e5e5; font-size: 11px; line-height: 1.7; white-space: pre-wrap; overflow-wrap: anywhere; }
.docs-path-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px; margin-top: 16px; }
.docs-path-grid article { display: grid; gap: 8px; padding: 18px; border: 1px solid var(--line); border-radius: 10px; background: white; }
.docs-path-grid h3 { margin: 0; font-size: 13px; }
.docs-path-grid p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.55; }
.docs-path-grid a, .docs-path-grid button { width: fit-content; margin-top: 3px; padding: 0; border: 0; color: var(--ink); background: transparent; font-size: 11px; font-weight: 600; text-decoration: none; }
.docs-path-grid a:hover, .docs-path-grid button:hover { text-decoration: underline; }
.docs-copy-row, .docs-endpoint-row { max-width: 760px; min-height: 44px; display: flex; align-items: center; gap: 10px; margin-top: 16px; border: 1px solid var(--line); border-radius: 8px; background: #fafafa; padding: 8px 8px 8px 13px; }
.docs-copy-row code, .docs-endpoint-row code { min-width: 0; flex: 1; color: var(--ink); font-size: 11px; overflow-wrap: anywhere; }
.docs-copy-row button, .docs-endpoint-row button { width: 31px; height: 31px; display: grid; place-items: center; border: 0; border-radius: 6px; color: var(--subtle); background: transparent; }
.docs-copy-row button:hover, .docs-endpoint-row button:hover { color: var(--ink); background: #eee; }
.docs-copy-row svg, .docs-endpoint-row svg { width: 14px; height: 14px; }
.docs-callout { max-width: 760px; display: flex; align-items: flex-start; gap: 9px; margin-top: 16px; border: 1px solid #dce6f5; border-radius: 9px; color: #31547c; background: #f5f8fc; padding: 12px 13px; font-size: 11px; line-height: 1.6; }
.docs-callout svg { width: 14px; height: 14px; flex: 0 0 auto; margin-top: 2px; }
.docs-link-button { padding: 0; border: 0; color: inherit; background: transparent; font: inherit; font-weight: 700; text-decoration: underline; }
.docs-method { border-radius: 5px; color: #176b4d; background: #e7f6f0; padding: 3px 7px; font-size: 9px; font-weight: 750; }
.docs-meta-inline { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 12px; color: var(--subtle); font-size: 10px; }
.docs-meta-inline code { color: var(--ink); }
.param-table, .response-schema, .error-table { display: grid; margin-top: 18px; border-top: 1px solid var(--line); }
.param-table > div { display: grid; gap: 6px; padding: 15px 0; border-bottom: 1px solid var(--line); }
.param-table > div[hidden] { display: none; }
.param-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.param-table strong { font-size: 11px; font-weight: 650; }
.param-table .param-head span { color: var(--subtle); font-size: 10px; }
.param-table b { height: 19px; display: inline-flex; align-items: center; border-radius: 999px; color: var(--ink); background: #eee; padding: 0 7px; font-size: 8.5px; }
.param-table p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.6; }
.response-schema > div { display: grid; grid-template-columns: minmax(130px, 170px) 100px minmax(0, 1fr); gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.response-schema code { color: var(--ink); font-size: 11px; }
.response-schema span { color: var(--subtle); font-size: 10px; }
.response-schema p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.55; }
.error-table > div { display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: 14px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.error-table strong { font-size: 11px; }
.error-table span { color: var(--muted); font-size: 11px; line-height: 1.55; }
.docs-plain-list { max-width: 720px; margin: 14px 0 0; padding-left: 18px; color: var(--muted); font-size: 12px; line-height: 1.7; }
.docs-empty { color: var(--muted); font-size: 11px; }

/* Dialogs */
.dev-dialog { width: min(450px, calc(100vw - 28px)); padding: 0; border: 1px solid var(--line-strong); border-radius: 12px; color: var(--ink); background: white; box-shadow: 0 24px 80px rgba(0,0,0,.22); }
.dev-dialog::backdrop { background: rgba(0,0,0,.42); backdrop-filter: blur(2px); }
.dev-dialog form, .secret-dialog { padding: 23px; }
.dialog-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.dialog-heading h2 { margin: 0; font-size: 17px; font-weight: 650; letter-spacing: -.02em; }
.dialog-heading p { margin: 6px 0 0; color: var(--muted); font-size: 10.5px; line-height: 1.5; }
.dialog-heading > button { width: 29px; height: 29px; display: grid; place-items: center; flex: 0 0 auto; margin: -4px -4px 0 0; border: 0; border-radius: 6px; color: var(--subtle); background: transparent; }
.dialog-heading > button:hover { color: var(--ink); background: var(--surface-soft); }
.dialog-heading svg { width: 15px; height: 15px; }
.dev-dialog form > label { display: grid; gap: 7px; margin-top: 20px; color: #555; font-size: 9.5px; font-weight: 600; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 22px; }
.dialog-actions > button:not(.primary-button) { min-height: 38px; padding: 0 14px; border: 1px solid var(--line-strong); border-radius: 7px; color: #555; background: white; font-size: 11px; font-weight: 600; }
.credit-packs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-top: 19px; }
.credit-pack { min-height: 44px; border: 1px solid var(--line-strong); border-radius: 7px; color: var(--ink); background: var(--surface-soft); font-size: 13px; font-weight: 650; }
.credit-pack.active, .credit-pack:hover { border-color: var(--ink); color: white; background: var(--ink); }
.credit-provider-field { margin: 0; border: 0; padding: 0; }
.credit-provider-field legend { margin-bottom: 8px; color: var(--muted); font-size: 11px; font-weight: 650; }
.credit-providers { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.credit-provider { min-height: 40px; border: 1px solid var(--line-strong); border-radius: 7px; color: var(--ink); background: white; font-size: 12px; font-weight: 650; }
.credit-provider.active, .credit-provider:hover { border-color: var(--ink); color: white; background: var(--ink); }
.field-hint { margin: 8px 0 0; color: var(--subtle); font-size: 11px; line-height: 1.45; }
.secret-value { height: 46px; display: flex; align-items: center; margin-top: 20px; border: 1px solid var(--line-strong); border-radius: 7px; background: var(--surface-soft); overflow: hidden; }
.secret-value code { min-width: 0; flex: 1; padding: 0 12px; overflow-x: auto; color: var(--ink); font-size: 10px; white-space: nowrap; }

@media (max-width: 980px) {
  .home-hero { grid-template-columns: 1fr; gap: 30px; }
  .hero-code { max-width: 680px; }
  .home-grid, .overview-columns, .playground-grid { grid-template-columns: 1fr; }
  .request-panel { border-right: 0; border-bottom: 1px solid var(--line); }
  .docs-page { grid-template-columns: 180px minmax(0, 1fr); gap: 30px; }
}

@media (max-width: 760px) {
  .dev-shell { display: block; padding-top: 108px; }
  .dev-sidebar { top: 60px; right: 0; bottom: auto; width: auto; height: 48px; display: block; padding: 5px 8px; border-right: 0; border-bottom: 1px solid var(--line); overflow-x: auto; }
  .dev-nav { display: grid; grid-template-columns: repeat(4, minmax(92px, 1fr)); gap: 3px; }
  .dev-nav > p, .dev-nav > a, .dev-sidebar-foot { display: none; }
  .dev-nav button { justify-content: center; }
  .dev-main { padding: 30px 18px 58px; }
  .metric-grid { grid-template-columns: 1fr 1fr; }
  .metric-grid article:nth-child(2) { border-right: 0; }
  .metric-grid article:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .docs-page { grid-template-columns: 1fr; }
  .docs-rail { position: static; }
  .docs-rail nav { display: flex; flex-wrap: wrap; gap: 4px; }
  .docs-rail nav > p { width: 100%; }
  .docs-quickstart-card { grid-template-columns: 1fr; }
  .docs-path-grid { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .dev-topbar { padding: 0 12px; }
  .topbar-divider, .project-switcher, .dev-topbar-actions > a { display: none; }
  .dev-topbar-actions .chat-link { display: inline-flex; }
  .home-hero { min-height: 0; padding: 16px 0 34px; }
  .home-hero h1 { font-size: 38px; }
  .home-hero > div:first-child > p { font-size: 13px; }
  .hero-code pre { min-height: 210px; font-size: 10px; }
  .metric-grid { grid-template-columns: 1fr; }
  .metric-grid article { border-right: 0; border-bottom: 1px solid var(--line); }
  .metric-grid article:last-child { border-bottom: 0; }
  .credit-card { grid-template-columns: auto minmax(0, 1fr); }
  .credit-card > .primary-button { grid-column: 1 / -1; width: 100%; }
  .dev-heading { min-height: 0; margin-bottom: 22px; }
  .dev-heading h1 { font-size: 25px; }
  .dev-heading > .primary-button, .dev-heading > .secondary-button { width: 38px; padding: 0; font-size: 0; }
  .field-pair { grid-template-columns: 1fr; gap: 0; }
  .request-panel, .response-panel { padding: 17px; }
  .response-panel pre { min-height: 320px; }
  .docs-page-title { font-size: 34px; }
  .response-schema > div { grid-template-columns: 1fr; gap: 4px; }
  .credit-packs { grid-template-columns: 1fr 1fr; }
}
