/* Bage developer console: the site's charcoal and paper look ("Ledger" design). */
:root {
  --ink: #121110;
  --panel: #1c1b19;
  --line: #242220;
  --line-2: #2e2c29;
  --line-3: #3a3834;
  --paper: #edebe6;
  --text-2: #d2cfc8;
  --muted: #a19e97;
  --faint: #85827c;
  --orbit: #77746e;
  --mono: "Geist Mono", ui-monospace, monospace;
}
* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: "Geist", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a {
  color: var(--paper);
}
a:hover {
  color: #fff;
}
button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}
:focus-visible {
  outline: 2px solid var(--paper);
  outline-offset: 2px;
}
[hidden] {
  display: none !important;
}
.mono {
  font-family: var(--mono);
}
.eyebrow,
.label {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}
.label {
  font-size: 11px;
}
.muted {
  color: var(--muted);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 16px;
  border-radius: 3px;
  border: 1px solid var(--line-3);
  background: transparent;
  text-decoration: none;
  font-size: 14px;
  cursor: pointer;
  white-space: nowrap;
}
.btn:hover {
  border-color: var(--muted);
}
.btn.light {
  background: var(--paper);
  color: var(--ink);
  border-color: var(--paper);
  font-weight: 500;
}
.btn.light:hover {
  background: #fff;
  color: var(--ink);
}
.btn.small {
  min-height: 36px;
  padding: 0 12px;
  font-size: 13px;
}
.btn.text {
  border: 0;
  padding: 0 4px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: underline;
  color: var(--muted);
}
.btn[disabled] {
  opacity: 0.45;
  cursor: not-allowed;
}

/* Signed out and setup */
.center {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px 16px;
}
.card {
  width: 100%;
  max-width: 420px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.card h1 {
  margin: 0;
  font-size: 40px;
  font-weight: 400;
  letter-spacing: -0.045em;
  line-height: 1.05;
}
.card p {
  margin: 0;
  color: var(--text-2);
  line-height: 1.5;
}

/* Shell: sidebar + content */
/* The sidebar stays put at full viewport height, Sign out pinned at its bottom; only the page content scrolls. */
.shell {
  min-height: 100vh;
  display: flex;
  align-items: flex-start;
}
.side {
  flex: 0 0 232px;
  width: 232px;
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100dvh;
  overflow-y: auto;
  border-right: 1px solid var(--line);
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}
.side > * {
  flex-shrink: 0;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}
.logo .word {
  font-weight: 600;
  font-size: 18px;
  letter-spacing: -0.04em;
}
.tag {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--muted);
  border: 1px solid var(--line-3);
  border-radius: 2px;
  padding: 3px 6px;
}
.logo .tag {
  margin-left: auto;
}
.org {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line-2);
  border-radius: 3px;
  min-height: 44px;
  font-size: 14px;
}
.org .initial {
  width: 22px;
  height: 22px;
  border-radius: 2px;
  background: #2a2826;
  font-size: 12px;
  display: grid;
  place-items: center;
}
.side > .nav {
  flex-shrink: 1;
  min-height: 0;
  overflow-y: auto;
}
.nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.08em;
}
.nav a {
  text-decoration: none;
  padding: 12px;
  border-radius: 2px;
  color: var(--muted);
}
.nav a[aria-current="page"] {
  background: var(--panel);
  color: var(--paper);
}
.nav a:hover {
  color: var(--paper);
}
.side .foot {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
  font-size: 13px;
  color: var(--muted);
}
.side .me {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  min-width: 0;
}
.side .me span:nth-child(2) {
  overflow: hidden;
  text-overflow: ellipsis;
}
.avatar {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--line-2);
  display: grid;
  place-items: center;
  color: var(--paper);
  font-size: 12px;
}
.main {
  flex: 1 1 0;
  min-width: 0;
  padding: 40px 48px 64px;
  display: flex;
  flex-direction: column;
  gap: 36px;
}
.head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.head .title {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.head h1 {
  margin: 0;
  font-size: 44px;
  font-weight: 400;
  letter-spacing: -0.045em;
  line-height: 1;
}
.actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 500;
  letter-spacing: -0.02em;
}
.section {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}

/* Stats */
.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--line-2);
  border-bottom: 1px solid var(--line-2);
}
.stats > div {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.stats > div:first-child {
  padding-left: 0;
}
.stats > div + div {
  border-left: 1px solid var(--line-2);
}
.stats .value {
  font-size: 32px;
  letter-spacing: -0.04em;
}

/* Tables */
.table-box {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 3px;
}
table {
  width: 100%;
  min-width: 820px;
  border-collapse: collapse;
  font-size: 14px;
}
th {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.1em;
  color: var(--muted);
  text-align: left;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
}
td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}
tr:last-child td {
  border-bottom: 0;
}
tbody tr.link {
  cursor: pointer;
}
tbody tr.link:hover {
  background: var(--panel);
}
td.code {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--text-2);
}
td.faint {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
}
.agent-cell {
  display: flex;
  align-items: center;
  gap: 12px;
}
.agent-cell a {
  text-decoration: none;
  font-weight: 500;
}
.agent-cell .sub {
  font-size: 12px;
  color: var(--muted);
}
.icon {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  border-radius: 3px;
  object-fit: cover;
  background: var(--paper);
  color: var(--ink);
  display: grid;
  place-items: center;
  font-weight: 600;
  font-size: 16px;
}
.icon.mark {
  background: transparent;
  border: 1px solid var(--line-3);
}
.icon.big {
  width: 72px;
  height: 72px;
  font-size: 32px;
}
.spark {
  display: flex;
  align-items: center;
  gap: 12px;
}
.status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.status::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--paper);
}
.status.test {
  color: var(--muted);
}
.status.test::before {
  background: transparent;
  border: 1px solid var(--muted);
}
.status.off {
  color: var(--faint);
}
.status.off::before {
  background: transparent;
  border: 1px solid var(--faint);
}
.pill {
  display: inline-block;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 5px 8px;
  border-radius: 2px;
  white-space: nowrap;
}
.pill.approved {
  background: var(--paper);
  color: var(--ink);
}
.pill.pending {
  border: 1px dashed var(--orbit);
}
.pill.denied {
  border: 1px solid var(--line-3);
  color: var(--muted);
  text-decoration: line-through;
}
.pill.expired {
  color: var(--faint);
  padding-left: 0;
}
.empty {
  border: 1px dashed var(--line-3);
  border-radius: 3px;
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  align-items: flex-start;
  color: var(--text-2);
}
.empty p {
  margin: 0;
}

/* Forms */
.form {
  display: flex;
  flex-direction: column;
  gap: 32px;
}
fieldset {
  border: 0;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}
legend {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--muted);
  padding: 0;
  margin-bottom: 14px;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 13px;
  color: var(--text-2);
}
.field input,
.field textarea,
.field select,
.inline input {
  min-height: 46px;
  padding: 0 14px;
  background: var(--panel);
  border: 1px solid var(--line-3);
  border-radius: 3px;
  color: var(--paper);
  font-size: 15px;
}
.field textarea {
  padding: 12px 14px;
  font-family: var(--mono);
  font-size: 13px;
  resize: vertical;
}
.field input:focus,
.field textarea:focus,
.inline input:focus {
  border-color: var(--muted);
  outline: none;
}
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.choice {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 18px;
  border: 1px solid var(--line-3);
  border-radius: 3px;
  cursor: pointer;
}
.choice:has(input:checked) {
  border-color: var(--paper);
}
.choice input {
  margin: 3px 0 0;
  accent-color: var(--paper);
  width: 16px;
  height: 16px;
}
.choice > span {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.choice small {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
}
.drop {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px;
  border: 1px dashed var(--line-3);
  border-radius: 3px;
  cursor: pointer;
  flex-wrap: wrap;
}
.drop input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}
.drop:focus-within {
  outline: 2px solid var(--paper);
  outline-offset: 2px;
}
.drop .text {
  flex: 1;
  min-width: 200px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 15px;
}
.drop .text small {
  font-size: 13px;
  color: var(--muted);
}
.error {
  color: #f0b8a8;
  font-size: 14px;
}
.inline {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.inline input {
  flex: 1;
  min-width: 220px;
}

/* Two columns: content + aside */
.split {
  display: flex;
  gap: 48px;
  flex-wrap: wrap;
  align-items: flex-start;
}
.split > :first-child {
  flex: 999 1 520px;
  min-width: 0;
}
.split > aside {
  flex: 1 1 340px;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Paper previews: the approval email and the push */
.paper {
  background: var(--paper);
  color: var(--ink);
  border-radius: 3px;
  padding: 26px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.paper .k {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  color: #5f5c56;
}
.paper .big {
  font-size: 22px;
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 1.15;
}
.paper .sub {
  font-size: 14px;
  color: #5f5c56;
}
.paper .icon {
  background: var(--ink);
  color: var(--paper);
}
.paper .icon.mark {
  background: transparent;
  border-color: #c9c6be;
}
.paper .cta {
  text-align: center;
  padding: 12px;
  background: var(--ink);
  color: var(--paper);
  border-radius: 2px;
  font-size: 14px;
}
.push {
  background: var(--panel);
  border: 1px solid var(--line-2);
  border-radius: 14px;
  padding: 14px 16px;
  display: flex;
  gap: 12px;
}
.push .app {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  background: var(--paper);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.push .lines {
  display: flex;
  flex-direction: column;
  gap: 3px;
  flex: 1;
  min-width: 0;
  font-size: 14px;
}
.push .meta {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--muted);
}

/* Panels on the agent page */
.panel {
  border: 1px solid var(--line-2);
  border-radius: 3px;
}
.panel > .panel-head {
  padding: 18px 22px;
  border-bottom: 1px solid var(--line-2);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.panel > .panel-body {
  padding: 6px 22px 18px;
  display: flex;
  flex-direction: column;
}
.row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  flex-wrap: wrap;
}
.row:last-child {
  border-bottom: 0;
}
.row .k {
  width: 120px;
  font-size: 13px;
  color: var(--muted);
}
.row code {
  flex: 1;
  font-family: var(--mono);
  font-size: 14px;
  word-break: break-all;
}
.row .row-value {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.row .row-value small {
  font-size: 12px;
}
.verify-options {
  gap: 4px;
}
.verify-option {
  padding: 16px 0 4px;
  border-bottom: 1px solid var(--line);
}
.verify-option-head {
  display: flex;
  align-items: baseline;
  gap: 12px;
  font-size: 15px;
}
.verify-option > p {
  margin: 6px 0 2px;
  font-size: 13px;
  line-height: 1.5;
}
pre.code {
  margin: 0;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 18px 20px;
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.7;
  color: var(--text-2);
  overflow-x: auto;
}
pre.code .c {
  color: var(--faint);
}
.key-box {
  background: var(--paper);
  color: var(--ink);
  border-radius: 3px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.key-box p {
  margin: 0;
  line-height: 1.5;
}
.key-box .btn {
  border-color: #b8b5ae;
}
.key-box .btn.dark {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}
.key-box label {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 14px;
  padding-top: 14px;
  border-top: 1px solid #c9c6be;
}
.key-box input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--ink);
}
.danger {
  border: 1px solid var(--line-3);
  border-radius: 3px;
  padding: 18px 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.danger div {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.danger small {
  color: var(--muted);
  font-size: 13px;
}
.test-people {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
}
.test-people li {
  display: flex;
  gap: 16px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  flex-wrap: wrap;
  font-size: 14px;
}
.test-people li:last-child {
  border-bottom: 0;
}
.test-people code {
  font-family: var(--mono);
  font-size: 13px;
  min-width: 220px;
}

/* Request list rows */
.requests {
  display: flex;
  flex-direction: column;
  font-size: 14px;
}

#toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  background: var(--paper);
  color: var(--ink);
  padding: 12px 18px;
  border-radius: 3px;
  font-size: 14px;
  max-width: calc(100vw - 32px);
  z-index: 10;
}

/* Websites */
.choice.compact {
  padding: 14px 16px;
}
.scope-list {
  display: flex;
  flex-direction: column;
}
.scope-row {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) auto 84px;
  gap: 16px;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.scope-row code {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--text-2);
  word-break: break-all;
}
.scope-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.scope-text small {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
}
.scope-row .btn {
  justify-self: end;
}
.scope-form,
.scope-directory {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 20px;
}
.scope-form h3,
.scope-directory h3 {
  margin: 0;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}
.scope-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 10px;
}
.scope-fields label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
}
.scope-fields .wide {
  grid-column: 1 / -1;
}
.scope-fields input {
  min-height: 42px;
  padding: 0 12px;
  background: var(--panel);
  border: 1px solid var(--line-3);
  border-radius: 3px;
  color: var(--paper);
  font-size: 14px;
}
.scope-fields input.mono {
  font-family: var(--mono);
}
.scope-fields input:focus {
  border-color: var(--muted);
  outline: none;
}
.scope-pick {
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
}
.scope-pick:hover {
  border-color: var(--muted);
}
.scope-pick .plus {
  font-family: var(--mono);
  color: var(--muted);
  width: 16px;
}
@media (max-width: 640px) {
  .scope-row {
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 8px 12px;
  }
  .scope-row .scope-text {
    grid-column: 1 / -1;
    grid-row: 2;
  }
  .scope-fields {
    grid-template-columns: minmax(0, 1fr);
  }
}
.scope-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 10px;
}
fieldset.focus {
  gap: 10px;
}
fieldset.focus legend {
  font-family: inherit;
  font-size: 14px;
  letter-spacing: 0;
  color: var(--text-2);
  margin-bottom: 10px;
}
.card fieldset.focus .choice {
  text-align: left;
}
ol.steps {
  margin: 0;
  padding-left: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  color: var(--text-2);
  font-size: 14px;
  line-height: 1.55;
}
ol.steps li::marker {
  font-family: var(--mono);
  color: var(--faint);
}
ol.steps strong {
  font-weight: 500;
  color: var(--paper);
}
ul.checks {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 3px;
}
ul.checks li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
}
ul.checks li:last-child {
  border-bottom: 0;
}
ul.checks .mark {
  font-family: var(--mono);
  width: 16px;
  color: var(--paper);
}
ul.checks li.bad .mark {
  color: var(--muted);
}
ul.checks span {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 14px;
}
ul.checks strong {
  font-weight: 500;
}
ul.checks small {
  color: var(--muted);
  font-size: 13px;
}

@media (max-width: 720px) {
  .shell {
    flex-direction: column;
    align-items: stretch;
  }
  .side {
    position: static;
    flex: none;
    width: auto;
    height: auto;
    overflow: visible;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    gap: 16px;
  }
  .side > .nav {
    overflow: visible;
  }
  .nav {
    flex-direction: row;
    flex-wrap: wrap;
  }
  .side .foot {
    margin-top: 0;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
  .side .me {
    display: none;
  }
  .main {
    padding: 28px 16px 48px;
  }
  .head h1 {
    font-size: 34px;
  }
  .stats > div {
    padding: 14px 12px;
  }
  .stats .value {
    font-size: 24px;
  }
  .grid-2 {
    grid-template-columns: minmax(0, 1fr);
  }
}
