:root {
  --bg: #f3f1ea;
  --ink: #191714;
  --muted: #6f6a61;
  --line: #d8d1c4;
  --panel: #fffdf7;
  --accent: #21695a;
  --accent-2: #c94f2d;
  --ok: #1f7a4d;
  --blocked: #9d3428;
  --shadow: 0 18px 50px rgba(35, 31, 25, 0.11);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    linear-gradient(120deg, rgba(33, 105, 90, 0.12), transparent 34rem),
    linear-gradient(260deg, rgba(201, 79, 45, 0.12), transparent 28rem),
    var(--bg);
  color: var(--ink);
  font-family: "Avenir Next", "Segoe UI", sans-serif;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  min-height: 44px;
  border: 0;
  border-radius: 7px;
  padding: 0 18px;
  background: var(--accent);
  color: white;
  cursor: pointer;
}

button:disabled {
  opacity: 0.55;
  cursor: wait;
}

.ghost {
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
}

.shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 48px;
}

.login,
.panel,
dialog {
  background: rgba(255, 253, 247, 0.92);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.login {
  min-height: min(680px, calc(100vh - 56px));
  display: grid;
  align-content: center;
  gap: 28px;
  padding: clamp(24px, 6vw, 64px);
}

.login h1,
.topbar h1 {
  margin: 0;
  font-size: clamp(36px, 8vw, 88px);
  line-height: 0.95;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--accent-2);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0;
}

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

.login-form {
  display: flex;
  gap: 10px;
  max-width: 560px;
}

.login-form input {
  flex: 1;
}

.topbar,
.panel-head,
.developer-head,
.actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.topbar {
  margin-bottom: 24px;
}

.grid {
  display: grid;
  grid-template-columns: minmax(320px, 0.95fr) minmax(320px, 1fr);
  gap: 18px;
}

.panel {
  padding: 18px;
  margin-bottom: 18px;
}

.panel h2 {
  margin: 0;
  font-size: 20px;
}

.badge {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  border-radius: 999px;
  background: #ece5d6;
  color: var(--muted);
  padding: 0 10px;
  font-size: 13px;
  font-weight: 700;
}

label,
fieldset {
  display: grid;
  gap: 7px;
  margin-top: 14px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: white;
  color: var(--ink);
  padding: 12px 13px;
}

textarea {
  resize: vertical;
}

fieldset {
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 12px;
}

legend {
  padding: 0 6px;
}

.check {
  display: flex;
  grid-template-columns: none;
  align-items: center;
  gap: 10px;
  margin: 8px 0;
}

.check input {
  width: 18px;
  height: 18px;
}

.form-panel button[type="submit"] {
  width: 100%;
  margin-top: 16px;
}

.message {
  min-height: 20px;
  color: var(--accent);
}

.service-list,
.developers,
.audit,
.workflow,
.deploy-requests {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.service,
.developer,
.audit-row,
.workflow article,
.deploy-request {
  border: 1px solid var(--line);
  border-radius: 7px;
  background: white;
  padding: 13px;
}

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

.workflow article {
  display: grid;
  align-content: start;
  gap: 8px;
}

.workflow span {
  color: var(--muted);
  font-size: 14px;
}

code {
  border-radius: 5px;
  background: #f1eadb;
  color: var(--ink);
  padding: 2px 5px;
}

.service a {
  color: var(--accent);
  font-weight: 800;
}

.developer {
  display: grid;
  gap: 12px;
}

.deploy-request {
  display: grid;
  gap: 10px;
}

.deploy-request pre {
  max-height: 260px;
  margin: 0;
  font-size: 12px;
}

.request-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.empty-state {
  display: grid;
  gap: 6px;
  border: 1px dashed var(--line);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.62);
  padding: 18px;
  color: var(--muted);
}

.empty-state strong {
  color: var(--ink);
  font-size: 18px;
}

.developer-title {
  display: grid;
  gap: 4px;
}

.developer-title strong {
  font-size: 18px;
}

.status {
  color: white;
  background: var(--ok);
}

.status.blocked {
  background: var(--blocked);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.access-line {
  display: grid;
  gap: 8px;
}

.access-label {
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.chip {
  border-radius: 999px;
  background: #f1eadb;
  padding: 6px 10px;
  font-size: 13px;
  font-weight: 800;
}

.audit-row {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 14px;
}

.audit-row strong {
  color: var(--ink);
}

.is-hidden {
  display: none;
}

dialog {
  width: min(720px, calc(100% - 28px));
  border: 1px solid var(--line);
  padding: 18px;
}

pre {
  white-space: pre-wrap;
  overflow: auto;
  background: #191714;
  color: #fffdf7;
  border-radius: 7px;
  padding: 14px;
}

@media (max-width: 820px) {
  .shell {
    width: min(100% - 20px, 1180px);
    padding-top: 12px;
  }

  .grid,
  .workflow,
  .login-form {
    grid-template-columns: 1fr;
    display: grid;
  }

  .topbar,
  .developer-head,
  .actions {
    align-items: stretch;
    flex-direction: column;
  }

  .topbar button,
  .actions button {
    width: 100%;
  }

  .developer {
    padding: 14px;
  }

  .login h1,
  .topbar h1 {
    font-size: clamp(34px, 13vw, 56px);
  }
}
