:root {
  color-scheme: light;
  --bg: #f5f6f8;
  --surface: #ffffff;
  --line: #d8dde5;
  --text: #17202a;
  --muted: #667085;
  --accent: #168a75;
  --accent-strong: #0f6f60;
  --danger: #b42318;
  --warning: #b54708;
  --ok: #067647;
}

html,
body {
  max-width: 100%;
  overflow-x: clip;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 14px/1.45 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a { color: inherit; }

.login-body {
  min-height: 100vh;
  display: grid;
  place-items: center;
  background: #eef1f4;
}

.login-shell {
  width: min(360px, calc(100vw - 32px));
}

.login-logo {
  display: block;
  width: 220px;
  height: auto;
  margin: 0 auto 24px;
}

.login-intro {
  margin-bottom: 14px;
  text-align: center;
}

.login-intro h1 {
  font-size: 22px;
}

.login-intro p {
  margin: 7px 0 0;
  color: var(--muted);
}

.login-form, .panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 20px;
}

label {
  display: grid;
  gap: 6px;
  color: #344054;
  font-size: 13px;
}

.field-label-row {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.field-label-row > span:first-child {
  min-width: 0;
  overflow-wrap: anywhere;
}

.info-tip {
  position: relative;
  z-index: 5;
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  width: 18px;
  height: 18px;
  border: 1px solid #0b5b95;
  border-radius: 4px;
  background: #1570b8;
  color: #fff;
  font-size: 12px;
  font-weight: 850;
  line-height: 1;
  cursor: help;
  user-select: none;
}

.info-tip:focus {
  outline: 2px solid rgba(21,112,184,.28);
  outline-offset: 2px;
}

.info-bubble {
  position: absolute;
  left: 0;
  bottom: calc(100% + 8px);
  z-index: 50;
  display: none;
  width: min(320px, calc(100vw - 32px));
  padding: 10px 12px;
  border: 1px solid #233142;
  border-radius: 6px;
  background: #101820;
  box-shadow: 0 12px 28px rgba(16,24,32,.22);
  color: #f8fafc;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.35;
  opacity: 0;
  pointer-events: none;
  text-align: left;
  white-space: normal;
}

.info-bubble::after {
  content: "";
  position: absolute;
  left: 10px;
  top: 100%;
  border: 6px solid transparent;
  border-top-color: #101820;
}

.info-tip:hover .info-bubble,
.info-tip:focus .info-bubble {
  display: block;
  opacity: 1;
}

input, select, textarea, button {
  width: 100%;
  min-height: 38px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  padding: 8px 10px;
  font: inherit;
  background: #fff;
  color: var(--text);
}

textarea { resize: vertical; }

button {
  width: auto;
  min-width: 94px;
  background: var(--accent);
  color: white;
  border-color: var(--accent);
  cursor: pointer;
  font-weight: 650;
}

button:hover { background: var(--accent-strong); }

.button-secondary,
button.button-secondary {
  background: #fff;
  color: #344054;
  border-color: #cbd5e1;
}

.button-secondary:hover,
button.button-secondary:hover {
  background: #f8fafc;
}

.danger-button {
  background: var(--danger);
  border-color: var(--danger);
}

.danger-button:hover {
  background: #912018;
}

.login-form {
  display: grid;
  gap: 14px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 60px;
  padding: 0 24px;
  background: #101820;
  color: #f8fafc;
  border-bottom: 3px solid var(--accent);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 750;
  text-decoration: none;
  white-space: nowrap;
}

.brand img {
  width: 70px;
  height: 28px;
  object-fit: cover;
}

.topbar nav {
  display: flex;
  align-items: stretch;
  gap: 2px;
  flex: 1;
  min-width: 0;
  overflow: visible;
}

.topbar nav a {
  display: inline-flex;
  align-items: center;
  min-height: 58px;
  padding: 0 12px;
  text-decoration: none;
  color: #cbd5e1;
  white-space: nowrap;
}

.topbar nav a.active, .topbar nav a:hover {
  color: #fff;
  background: rgba(255,255,255,.08);
}

.nav-more {
  position: relative;
  display: flex;
  align-items: stretch;
}

.nav-more > summary {
  display: inline-flex;
  align-items: center;
  min-height: 58px;
  padding: 0 12px;
  color: #cbd5e1;
  cursor: pointer;
  list-style: none;
  white-space: nowrap;
}

.nav-more > summary::-webkit-details-marker {
  display: none;
}

.nav-more > summary::after {
  content: "⌄";
  margin-left: 7px;
  font-size: 12px;
}

.nav-more > summary.active,
.nav-more > summary:hover,
.nav-more[open] > summary {
  color: #fff;
  background: rgba(255,255,255,.08);
}

.nav-more-menu {
  position: absolute;
  top: calc(100% - 2px);
  right: 0;
  z-index: 30;
  display: grid;
  min-width: 220px;
  padding: 6px;
  border: 1px solid #344054;
  border-radius: 8px;
  background: #101820;
  box-shadow: 0 16px 36px rgba(16,24,32,.28);
}

.topbar .nav-more-menu a {
  min-height: 40px;
  border-radius: 5px;
}

.logout-form button {
  background: transparent;
  border-color: #475467;
}

.admin-shell {
  width: min(1480px, calc(100vw - 32px));
  margin: 24px auto 56px;
}

.page-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 16px;
  margin-bottom: 18px;
}

h1, h2 {
  margin: 0;
  line-height: 1.2;
  letter-spacing: 0;
}

h1 { font-size: 26px; }
h2 { font-size: 17px; margin-bottom: 14px; }

.page-head p {
  margin: 6px 0 0;
  color: var(--muted);
}

.api-pill {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 12px;
  background: #fff;
  color: var(--muted);
  white-space: nowrap;
}

.scope-note {
  margin: 0 0 18px;
  padding: 10px 12px;
  border: 1px solid #d6e0ea;
  border-radius: 8px;
  background: #fbfcfe;
  color: var(--muted);
}

.portal-context {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin: 0 0 20px;
  padding: 14px 16px;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  background: #eef7f5;
}

.portal-context-form {
  display: grid;
  grid-template-columns: minmax(240px, 1.2fr) minmax(220px, 1fr) auto;
  align-items: end;
  gap: 12px;
  flex: 1;
}

.portal-context p {
  max-width: 360px;
  margin: 0 0 4px;
  color: #52606d;
  font-size: 12px;
}

.eyebrow {
  display: block;
  margin-bottom: 5px;
  color: var(--accent-strong);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.workspace-hero,
.standard-intro,
.guided-return,
.sdk-primary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
}

.workspace-hero h2,
.standard-intro h2,
.sdk-primary h2 {
  margin-bottom: 6px;
  font-size: 22px;
}

.workspace-hero p,
.standard-intro p,
.sdk-primary p,
.guided-return span {
  margin: 0;
  color: var(--muted);
}

.guided-return > div {
  display: grid;
  gap: 4px;
}

.behavior-summary {
  display: grid;
  grid-template-columns: minmax(240px, .7fr) minmax(0, 1.3fr);
  align-items: center;
  gap: 20px;
  border-left: 4px solid var(--accent);
}

.behavior-summary h2,
.behavior-summary p {
  margin: 0;
}

.next-action {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 20px;
  border: 1px solid #84cdbf;
  border-radius: 10px;
  background: #f1fffb;
}

.next-action h2 {
  margin-bottom: 6px;
}

.next-action p {
  margin: 0;
  color: #475467;
}

.workflow-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

.workflow-card {
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  gap: 10px;
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}

.workflow-card[data-workflow-status="next"] {
  border-color: #70c7b6;
  box-shadow: inset 0 0 0 1px #b9eadf;
}

.workflow-card[data-workflow-status="warning"] {
  border-color: #fec84b;
}

.workflow-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.workflow-number {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: #eef2f6;
  color: #344054;
  font-weight: 850;
}

.workflow-card h3,
.workflow-card p {
  margin: 0;
}

.workflow-card p {
  color: var(--muted);
  font-size: 13px;
}

.status-tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border-radius: 999px;
  background: #eef2f6;
  color: #344054;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.status-tag.ready { background: #ecfdf3; color: var(--ok); }
.status-tag.next { background: #e7f8f4; color: var(--accent-strong); }
.status-tag.warning, .status-tag.pilot { background: #fffaeb; color: var(--warning); }
.status-tag.blocked { background: #fef3f2; color: var(--danger); }
.status-tag.waiting { background: #f2f4f7; color: #475467; }

.text-link {
  color: var(--accent-strong);
  font-weight: 750;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.cockpit-details {
  align-items: stretch;
}

.cockpit-details > .panel {
  margin: 0;
}

.identifier-chips {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 7px;
}

.identifier-chips code {
  display: inline-flex;
  padding: 4px 8px;
  border: 1px solid #b8d9d2;
  border-radius: 6px;
  background: #f1fffb;
  color: #0f6f60;
}

.mini-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.mini-metrics > div {
  display: grid;
  gap: 3px;
  padding: 12px;
  border: 1px solid #e4e9f0;
  border-radius: 8px;
  background: #fbfcfe;
}

.mini-metrics strong {
  font-size: 22px;
}

.mini-metrics span {
  color: var(--muted);
  font-size: 12px;
}

.capability-boundary,
.advanced-panel,
.secondary-workflow,
.advanced-fields {
  border: 1px solid #d6e0ea;
  border-radius: 9px;
  background: #fff;
}

.capability-boundary > summary,
.advanced-panel > summary,
.secondary-workflow > summary,
.advanced-fields > summary {
  padding: 13px 15px;
  color: #344054;
  cursor: pointer;
  font-weight: 800;
}

.capability-list,
.advanced-panel-body,
.secondary-workflow-body {
  padding: 0 15px 15px;
}

.capability-row {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  align-items: start;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid #edf0f5;
}

.advanced-panel-body > h2,
.secondary-workflow-body > h2 {
  margin-top: 5px;
}

.secondary-workflow {
  margin-top: 20px;
}

.advanced-fields {
  align-self: stretch;
  background: #fbfcfe;
}

.advanced-fields-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(150px, 1fr));
  gap: 14px;
  padding: 0 14px 14px;
}

.scope-summary {
  margin: 0 0 16px;
  padding: 11px 13px;
  border: 1px solid #b8d9d2;
  border-radius: 8px;
  background: #f6fffc;
  color: #344054;
}

.scope-summary.warning {
  border-color: #fedf89;
  background: #fffcf5;
}

.sdk-primary {
  align-items: stretch;
}

.sdk-primary-main {
  min-width: 0;
  flex: 1;
}

.sdk-primary-action {
  display: grid;
  align-content: center;
  justify-items: stretch;
  gap: 7px;
  min-width: 290px;
  text-align: center;
}

.sdk-primary-action span {
  color: var(--muted);
  font-size: 12px;
}

.integration-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.integration-steps article {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 11px;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
}

.integration-steps article > span {
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-weight: 850;
}

.integration-steps h3,
.integration-steps p {
  margin: 0;
}

.integration-steps p {
  margin-top: 5px;
  color: var(--muted);
  font-size: 13px;
}

.credential-warning {
  padding: 14px 16px;
  border: 1px solid #fedf89;
  border-radius: 9px;
  background: #fffcf5;
}

.credential-warning p {
  margin: 5px 0 0;
  color: #7a2e0e;
}

.advanced-subheading {
  margin-top: 20px;
}

.empty-onboarding {
  max-width: 760px;
  margin: 60px auto;
  text-align: center;
}

.empty-onboarding p {
  color: var(--muted);
}

section {
  margin-top: 20px;
}

.two-col {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.grid-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(160px, 1fr));
  gap: 14px;
  align-items: end;
}

.wide { grid-column: 1 / -1; }

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.section-head h2,
.section-head h3 {
  margin: 0;
}

.code-list-summary {
  white-space: nowrap;
}

h3 {
  font-size: 15px;
  line-height: 1.25;
  letter-spacing: 0;
}

.product-create-panel .grid-form {
  grid-template-columns: repeat(5, minmax(150px, 1fr));
}

.wizard-shell {
  display: grid;
  gap: 16px;
}

.wizard-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 16px;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.wizard-head p {
  margin: 6px 0 0;
  color: var(--muted);
}

.wizard-steps {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.wizard-steps li {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.wizard-steps span {
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: #eef2f6;
  color: #475467;
}

.wizard-steps li.current {
  border-color: #9ed8cc;
  color: var(--text);
}

.wizard-steps li.current span,
.wizard-steps li.done span {
  background: var(--accent);
  color: #fff;
}

.wizard-form h2 {
  margin-bottom: 8px;
}

.wizard-form h3 {
  margin: 20px 0 10px;
}

.choice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.wizard-glossary {
  display: grid;
  gap: 10px;
  margin-top: 14px;
  padding: 12px 14px;
  border: 1px solid #d6e0ea;
  border-radius: 8px;
  background: #fbfcfe;
}

.wizard-glossary strong {
  color: var(--text);
}

.wizard-glossary dl {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 8px 14px;
  margin: 0;
}

.wizard-glossary dt {
  color: #344054;
  font-weight: 750;
}

.wizard-glossary dd {
  margin: 0;
  color: var(--muted);
}

.choice-card {
  position: relative;
  display: block;
  min-width: 0;
  cursor: pointer;
}

.choice-card input {
  position: absolute;
  inset: 14px auto auto 14px;
  width: 18px;
  min-height: 18px;
  margin: 0;
  accent-color: var(--accent);
}

.choice-card-body {
  display: grid;
  gap: 7px;
  align-content: start;
  min-height: 150px;
  padding: 14px 14px 14px 42px;
  border: 1px solid #d6e0ea;
  border-radius: 8px;
  background: #fff;
}

.choice-card input:checked + .choice-card-body {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
  background: #f6fffc;
}

.choice-card strong {
  color: var(--text);
  font-size: 14px;
}

.choice-card span span {
  color: var(--muted);
}

.choice-section-title {
  margin-top: 4px;
  color: #344054;
  font-size: 12px;
  font-weight: 800;
}

.choice-card ul {
  margin: 4px 0 0;
  padding-left: 18px;
  color: #475467;
}

.choice-card .technical-list {
  color: #667085;
  font-size: 12px;
}

.guided-identifier-intro {
  margin-bottom: 16px;
}

.guided-identifier-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(280px, .8fr);
  gap: 16px;
  align-items: start;
}

.guided-identifier-form {
  display: grid;
  gap: 18px;
  min-width: 0;
}

.guided-form-section {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding-top: 4px;
}

.guided-form-section:not(:first-of-type) {
  padding-top: 18px;
  border-top: 1px solid #e7ebf0;
}

.guided-form-section h3,
.guided-form-section p {
  margin: 0;
}

.guided-form-section p {
  margin-top: 4px;
  color: var(--muted);
}

.guided-step-number {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-weight: 850;
}

.guided-identifier-basics,
.guided-version-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.guided-choice-grid {
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  margin-top: -6px;
}

.guided-choice-card .choice-card-body {
  min-height: 100%;
}

.guided-choice-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.choice-card .guided-choice-title .recommended-pill {
  flex: 0 0 auto;
  padding: 2px 7px;
  border-radius: 999px;
  background: #dcfae6;
  color: #067647;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: .03em;
  text-transform: uppercase;
}

.guided-optional {
  border: 1px solid #dfe6ee;
  border-radius: 8px;
  background: #fbfcfe;
}

.guided-optional > summary {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  cursor: pointer;
  color: #344054;
  font-weight: 750;
}

.guided-optional > summary span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.guided-optional-body {
  display: grid;
  gap: 14px;
  padding: 2px 14px 14px;
}

.guided-optional-body h3,
.guided-optional-body p {
  margin: 0;
}

.guided-offline-note {
  padding: 11px 13px;
  border-left: 3px solid #667085;
  background: #f2f4f7;
  color: #475467;
  font-size: 12px;
}

.guided-submit {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 2px;
}

.guided-impact {
  position: sticky;
  top: 78px;
  border-top: 4px solid var(--accent);
}

.guided-impact h2 {
  margin: 0 0 14px;
}

.guided-impact dl {
  display: grid;
  gap: 9px;
  margin: 0;
}

.guided-impact dl div {
  padding: 10px 11px;
  border: 1px solid #e4e9f0;
  border-radius: 7px;
  background: #fbfcfe;
}

.guided-impact dt {
  margin-bottom: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.guided-impact dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.guided-non-effects {
  margin-top: 14px;
  padding: 11px 13px;
  border: 1px solid #fedf89;
  border-radius: 7px;
  background: #fffcf5;
}

.guided-non-effects ul {
  margin: 7px 0 0;
  padding-left: 18px;
}

.guided-impact > p:last-child {
  margin-bottom: 0;
}

.identifier-guided-entry {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 12px;
  padding: 12px 13px;
  border: 1px solid #b8d9d2;
  border-radius: 8px;
  background: #f6fffc;
}

.identifier-guided-entry > div {
  display: grid;
  gap: 3px;
}

.identifier-guided-entry span {
  color: var(--muted);
  font-size: 12px;
}

.generated-field {
  align-self: stretch;
  display: grid;
  gap: 5px;
  padding: 10px 12px;
  border: 1px solid #e4e9f0;
  border-radius: 8px;
  background: #fbfcfe;
}

.generated-field span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.generated-field strong {
  overflow-wrap: anywhere;
}

.generated-field p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.wizard-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
}

.wizard-review {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0 0;
}

.wizard-review div {
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid #e4e9f0;
  border-radius: 8px;
  background: #fbfcfe;
}

.wizard-review dt {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.wizard-review dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.product-workspace {
  display: grid;
  gap: 16px;
}

.product-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: visible;
}

.product-card summary::-webkit-details-marker {
  display: none;
}

.product-card-summary {
  display: grid;
  grid-template-columns: auto minmax(180px, 1fr) auto auto;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  cursor: pointer;
  list-style: none;
}

.product-card-summary:hover {
  background: #f8fafc;
}

.product-caret {
  width: 16px;
  height: 16px;
  color: var(--muted);
}

.product-caret::before {
  content: "›";
  display: block;
  transform: rotate(0deg);
  transform-origin: center;
  font-size: 22px;
  line-height: 14px;
  transition: transform .16s ease;
}

.product-card[open] .product-caret::before {
  transform: rotate(90deg);
}

.product-identity {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.product-identity strong,
.product-identity span {
  overflow-wrap: anywhere;
}

.product-identity span {
  color: var(--muted);
  font-size: 12px;
}

.product-card-status {
  white-space: nowrap;
}

.product-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  min-width: 0;
}

.stat-chip,
.count-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 26px;
  padding: 3px 9px;
  border: 1px solid #d6e0ea;
  border-radius: 999px;
  background: #f8fafc;
  color: #475467;
  font-size: 12px;
  white-space: nowrap;
}

.stat-chip strong {
  color: var(--text);
}

.product-card-body {
  padding: 0 18px 18px;
  border-top: 1px solid #edf0f5;
}

.product-card:not([open]) > .product-card-body {
  display: none;
}

.product-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  align-items: start;
}

.product-section {
  min-width: 0;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid #edf0f5;
}

.product-section-overview {
  margin-top: 0;
}

.product-section-wide,
.product-section-overview {
  grid-column: 1 / -1;
}

.product-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
}

.product-facts div {
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid #e4e9f0;
  border-radius: 8px;
  background: #fbfcfe;
}

.product-facts dt {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.product-facts dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.product-local-form {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #edf0f5;
}

.identifier-editor {
  margin-top: 12px;
  border: 1px solid #dfe6ee;
  border-radius: 8px;
  background: #fbfcfe;
}

.identifier-editor > summary {
  padding: 11px 13px;
  cursor: pointer;
  color: #344054;
  font-weight: 750;
}

.identifier-editor > .product-local-form {
  margin: 0 13px 13px;
}

.product-section .grid-form {
  grid-template-columns: repeat(2, minmax(150px, 1fr));
}

.product-section-wide .grid-form {
  grid-template-columns: repeat(4, minmax(150px, 1fr));
}

.form-section-title {
  grid-column: 1 / -1;
  align-self: end;
  padding-top: 4px;
  color: #475467;
  font-size: 12px;
  font-weight: 800;
}

.danger-section {
  border-top-color: #fecdca;
}

.danger-pill {
  display: inline-flex;
  min-height: 24px;
  align-items: center;
  padding: 3px 8px;
  border-radius: 999px;
  background: #fef3f2;
  color: var(--danger);
  font-size: 12px;
  font-weight: 800;
}

.deletion-summary {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.deletion-summary span {
  display: grid;
  gap: 2px;
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid #fecdca;
  border-radius: 8px;
  background: #fffbfa;
  color: #7a271a;
  font-size: 12px;
}

.deletion-summary strong {
  color: var(--danger);
  font-size: 18px;
}

.trash-icon {
  position: relative;
  display: inline-block;
  width: 14px;
  height: 15px;
  margin-right: 7px;
  border: 2px solid currentColor;
  border-top: 0;
  border-radius: 0 0 2px 2px;
  vertical-align: -2px;
}

.trash-icon::before {
  content: "";
  position: absolute;
  left: -3px;
  right: -3px;
  top: -5px;
  height: 2px;
  background: currentColor;
}

.trash-icon::after {
  content: "";
  position: absolute;
  left: 4px;
  top: -8px;
  width: 6px;
  height: 2px;
  background: currentColor;
}

.check {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
}

.check input {
  width: auto;
  min-height: auto;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.metric {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
}

.metric span {
  display: block;
  color: var(--muted);
  margin-bottom: 6px;
}

.metric strong {
  font-size: 30px;
}

.compact-metrics {
  grid-template-columns: repeat(4, minmax(140px, 1fr));
}

.table-wrap {
  min-width: 0;
  max-width: 100%;
  overflow-x: auto;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 8px;
}

table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
}

th, td {
  text-align: left;
  vertical-align: top;
  padding: 10px 12px;
  border-bottom: 1px solid #edf0f5;
}

th {
  background: #f8fafc;
  color: #475467;
  font-weight: 700;
  font-size: 12px;
}

tr:last-child td { border-bottom: 0; }

.empty {
  color: var(--muted);
  text-align: center;
  padding: 24px;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #eef2f6;
  color: #344054;
  font-size: 12px;
  font-weight: 700;
}

.badge.active, .badge.latest, .badge.ok, .badge.new { color: var(--ok); background: #ecfdf3; }
.badge.revoked, .badge.disabled, .badge.error { color: var(--danger); background: #fef3f2; }
.badge.archive, .badge.expired { color: var(--warning); background: #fffaeb; }

.inline-form {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  margin: 0 6px 6px 0;
}

.inline-form select, .inline-form button {
  min-height: 32px;
  padding: 5px 8px;
}

.flash {
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #fff;
  margin: 0 0 14px;
}

.flash.success { border-color: #abefc6; color: var(--ok); background: #f6fef9; }
.flash.error { border-color: #fecdca; color: var(--danger); background: #fffbfa; }

.csv-box, .code-block {
  white-space: pre-wrap;
  word-break: break-word;
  background: #101820;
  color: #eef7ff;
  border-radius: 8px;
  padding: 16px;
  overflow-x: auto;
}

.copy-box {
  width: 100%;
  min-height: 150px;
  margin-bottom: 12px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  white-space: pre;
}

.key-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 13px;
  white-space: nowrap;
}

.muted {
  color: var(--muted);
}

.toolbar {
  display: flex;
  justify-content: flex-start;
  margin-bottom: 16px;
}

.download-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: 12px;
}

.download-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  text-decoration: none;
  background: #fff;
  font-weight: 700;
}

.download-link span {
  color: var(--muted);
  font-weight: 500;
}

.button-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 7px 10px;
  border-radius: 6px;
  background: var(--accent);
  color: #fff;
  text-decoration: none;
  font-weight: 650;
  white-space: nowrap;
}

.error-page {
  max-width: 720px;
  margin: 80px auto;
  padding: 24px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

@media (max-width: 900px) {
  input,
  select,
  textarea {
    font-size: 16px;
  }
  .topbar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px 12px;
    padding: 10px 16px;
  }
  .brand {
    min-width: 0;
  }
  .brand img {
    flex: 0 0 auto;
  }
  .brand {
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .topbar nav {
    grid-column: 1 / -1;
    order: 3;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    flex-wrap: wrap;
    overflow: visible;
  }
  .topbar nav a {
    min-height: 38px;
    padding: 0 10px;
  }
  .nav-more > summary {
    min-height: 38px;
    padding: 0 10px;
  }
  .nav-more-menu {
    position: absolute;
    left: auto;
    right: 0;
    top: calc(100% + 4px);
    width: min(300px, calc(100vw - 32px));
    min-width: min(220px, calc(100vw - 32px));
  }
  .info-bubble {
    position: fixed;
    left: 16px;
    right: 16px;
    bottom: 16px;
    width: auto;
    max-width: none;
  }
  .info-bubble::after {
    display: none;
  }
  .logout-form {
    justify-self: end;
  }
  .page-head, .two-col { display: block; }
  .grid-form,
  .metric-grid,
  .download-grid,
  .portal-context-form,
  .behavior-summary,
  .workflow-grid,
  .mini-metrics,
  .integration-steps,
  .advanced-fields-grid,
  .guided-identifier-layout,
  .guided-identifier-basics,
  .guided-version-fields {
    grid-template-columns: 1fr;
  }
  .portal-context,
  .workspace-hero,
  .standard-intro,
  .guided-return,
    .next-action,
    .sdk-primary,
    .identifier-guided-entry {
    display: grid;
    align-items: stretch;
  }
  .guided-impact {
    position: static;
  }
  .guided-submit {
    justify-content: stretch;
  }
  .guided-submit > * {
    flex: 1;
  }
  .portal-context p {
    max-width: none;
  }
  .sdk-primary-action {
    min-width: 0;
  }
  .capability-row {
    grid-template-columns: 1fr;
  }
  .panel { margin-bottom: 16px; }
  .api-pill { display: inline-flex; margin-top: 12px; }
  .product-create-panel .grid-form,
  .product-section .grid-form,
  .product-section-wide .grid-form,
  .product-detail-grid,
  .product-facts,
  .wizard-review,
  .choice-grid,
  .deletion-summary {
    grid-template-columns: 1fr;
  }
  .wizard-head {
    display: grid;
  }
  .wizard-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .wizard-glossary dl {
    grid-template-columns: 1fr;
  }
  .wizard-glossary dd {
    margin-bottom: 4px;
  }
  .wizard-actions {
    justify-content: stretch;
  }
  .wizard-actions > * {
    flex: 1;
  }
  .product-card-summary {
    grid-template-columns: auto minmax(0, 1fr);
    align-items: start;
  }
  .product-card-status {
    justify-self: start;
  }
  .product-chips {
    grid-column: 2;
    justify-content: flex-start;
  }
  .product-card-body,
  .product-card-summary {
    padding-left: 14px;
    padding-right: 14px;
  }
}

@media (max-width: 520px) {
  .nav-more-menu {
    left: 0;
    right: auto;
  }
}
