
:root {
  color-scheme: light;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  background: #f6f7f9;
  color: #18202f;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(246, 247, 249, 0.96)),
    #f6f7f9;
}

button,
input {
  font: inherit;
}

.is-hidden {
  display: none !important;
}

.login-shell {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 24px;
}

.key-form {
  width: min(520px, 100%);
  padding: 28px;
  border: 1px solid #d7dce4;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 18px 48px rgba(36, 48, 71, 0.12);
}

.key-label {
  display: block;
  margin: 0 0 10px;
  color: #4a5568;
  font-size: 14px;
  font-weight: 650;
}

.key-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.key-input {
  min-width: 0;
  height: 46px;
  border: 1px solid #c7ceda;
  border-radius: 6px;
  padding: 0 14px;
  background: #ffffff;
  color: #111827;
  outline: none;
}

.key-input:focus {
  border-color: #2f7a63;
  box-shadow: 0 0 0 3px rgba(47, 122, 99, 0.14);
}

.primary-button,
.ghost-button {
  min-height: 38px;
  border: 1px solid transparent;
  border-radius: 6px;
  padding: 0 16px;
  font-weight: 650;
  cursor: pointer;
}

.primary-button {
  height: 46px;
  background: #255f4e;
  color: #ffffff;
}

.primary-button:hover {
  background: #1f5142;
}

.primary-button:disabled,
.ghost-button:disabled {
  cursor: wait;
  opacity: 0.65;
}

.form-error {
  min-height: 20px;
  margin: 10px 0 0;
  color: #b42318;
  font-size: 13px;
}

.dashboard {
  min-height: 100vh;
  background: #f6f7f9;
}

.dashboard-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 72px;
  padding: 14px max(24px, calc((100vw - 1120px) / 2));
  border-bottom: 1px solid #d9dee7;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 1px 0 rgba(17, 24, 39, 0.02);
}

.account-label {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.account-label span {
  color: #697386;
  font-size: 12px;
  font-weight: 650;
}

.account-label strong {
  overflow: hidden;
  color: #111827;
  font-size: 16px;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dashboard-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.ghost-button {
  background: #ffffff;
  border-color: #cbd3df;
  color: #243047;
}

.ghost-button:hover {
  background: #f3f6f8;
}

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

.stat-item {
  min-width: 0;
  padding: 20px;
  border: 1px solid #d9dee7;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(36, 48, 71, 0.08);
}

.stat-label {
  display: block;
  margin-bottom: 8px;
  color: #697386;
  font-size: 13px;
  font-weight: 650;
}

.stat-value {
  display: block;
  overflow-wrap: anywhere;
  color: #111827;
  font-size: 30px;
  font-weight: 760;
  line-height: 1.15;
}

.dashboard-body {
  display: grid;
  gap: 22px;
  width: min(1120px, calc(100% - 48px));
  min-height: 320px;
  margin: 0 auto;
  padding: 24px 0 48px;
}

.setup-panel {
  padding: 22px;
  border: 1px solid #d9dee7;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 14px 36px rgba(36, 48, 71, 0.08);
}

.setup-panel__header {
  margin-bottom: 8px;
}

.panel-eyebrow {
  margin: 0 0 4px;
  color: #2f7a63;
  font-size: 12px;
  font-weight: 750;
}

.setup-panel h1 {
  margin: 0;
  color: #111827;
  font-size: 22px;
  font-weight: 780;
  line-height: 1.2;
}

.setup-instruction {
  max-width: 680px;
  margin: 10px 0 0;
  color: #687286;
  font-size: 14px;
  line-height: 1.55;
}

.platform-mark {
  display: inline-grid;
  place-items: center;
  min-width: 88px;
  height: 30px;
  border-radius: 6px;
  background: #edf7f3;
  color: #255f4e;
  font-size: 12px;
  font-weight: 750;
}

.copy-status {
  min-height: 18px;
  margin: 12px 0 0;
  color: #255f4e;
  font-size: 12px;
  font-weight: 650;
}

.command-list {
  display: grid;
  gap: 14px;
  margin-top: 16px;
}

.command-row {
  position: relative;
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid #e2e7ef;
  border-radius: 8px;
  background: #f8fafb;
}

.command-row__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.command-row__title {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.command-row__title strong {
  color: #4a5568;
  font-size: 13px;
  font-weight: 750;
}

.command-copy-button {
  min-height: 30px;
  border: 1px solid #cbd3df;
  border-radius: 6px;
  padding: 0 12px;
  background: #ffffff;
  color: #255f4e;
  font-size: 12px;
  font-weight: 750;
  cursor: pointer;
}

.command-copy-button:hover {
  border-color: #2f7a63;
  background: #edf7f3;
}

.command-copy-button:focus-visible {
  border-color: #2f7a63;
  outline: 3px solid rgba(47, 122, 99, 0.14);
}

.command-row code {
  display: block;
  overflow-x: auto;
  color: #172033;
  font-family:
    "SFMono-Regular", Consolas, "Liberation Mono", Menlo, ui-monospace,
    monospace;
  font-size: 12px;
  line-height: 1.6;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

@media (max-width: 820px) {
  .dashboard-header {
    align-items: flex-start;
    flex-direction: column;
    padding: 16px;
  }

  .dashboard-actions {
    justify-content: flex-start;
  }

  .stats-bar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stat-item {
    padding: 18px 16px;
  }

  .stat-value {
    font-size: 24px;
  }

  .dashboard-body {
    width: min(100% - 32px, 1120px);
    padding-top: 18px;
  }

  .setup-panel {
    padding: 18px;
  }

  .setup-panel__header {
    margin-bottom: 6px;
  }
}

@media (max-width: 520px) {
  .key-form {
    padding: 20px;
  }

  .key-input-row {
    grid-template-columns: 1fr;
  }

  .primary-button {
    width: 100%;
  }

  .stats-bar {
    grid-template-columns: 1fr;
  }

  .setup-panel h1 {
    font-size: 20px;
  }

  .setup-instruction {
    font-size: 13px;
  }

  .command-row {
    padding: 14px;
  }

  .command-row__header {
    align-items: flex-start;
  }

  .command-row__title {
    align-items: flex-start;
    flex-direction: column;
  }

  .platform-mark {
    min-width: 0;
    width: fit-content;
    padding: 0 12px;
  }
}
