:root {
  --bg: #f3efe6;
  --bg-panel: rgba(255, 252, 246, 0.92);
  --line: #d6c8b2;
  --text: #221b16;
  --muted: #64584a;
  --accent: #a23b22;
  --accent-soft: #f2d1bf;
  --success: #2f6b3d;
  --error: #8b1e1e;
  --shadow: 0 24px 60px rgba(74, 46, 20, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(162, 59, 34, 0.12), transparent 34%),
    radial-gradient(circle at right center, rgba(116, 137, 84, 0.13), transparent 28%),
    linear-gradient(180deg, #f8f5ee 0%, #efe6d8 100%);
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
}

.page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 20px 48px;
}

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

.login-card,
.panel {
  background: var(--bg-panel);
  border: 1px solid rgba(214, 200, 178, 0.9);
  border-radius: 24px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.login-card {
  width: min(460px, 100%);
  padding: 32px;
}

.hero {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 24px;
}

.eyebrow {
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.8rem;
  font-weight: 700;
}

h1,
h2 {
  font-family: "IBM Plex Serif", Georgia, serif;
  margin: 0 0 8px;
}

p {
  color: var(--muted);
  line-height: 1.5;
}

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

.panel {
  padding: 24px;
  margin-bottom: 20px;
}

.panel.accent {
  background:
    linear-gradient(135deg, rgba(162, 59, 34, 0.08), rgba(255, 252, 246, 0.92)),
    var(--bg-panel);
}

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

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

.meta div {
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(214, 200, 178, 0.7);
}

dt {
  color: var(--muted);
  font-size: 0.85rem;
  margin-bottom: 6px;
}

dd {
  margin: 0;
  font-size: 0.98rem;
  word-break: break-word;
}

.badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: rgba(100, 88, 74, 0.12);
}

.badge.success {
  background: rgba(47, 107, 61, 0.14);
  color: var(--success);
}

.badge.failed {
  background: rgba(139, 30, 30, 0.14);
  color: var(--error);
}

.badge.running {
  background: rgba(162, 59, 34, 0.14);
  color: var(--accent);
}

button,
a {
  transition: transform 0.16s ease, opacity 0.16s ease;
}

button {
  border: 0;
  border-radius: 14px;
  background: var(--accent);
  color: white;
  padding: 12px 18px;
  font: inherit;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(162, 59, 34, 0.22);
}

button:hover,
a:hover {
  transform: translateY(-1px);
}

button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

button.ghost {
  background: rgba(255, 255, 255, 0.8);
  color: var(--text);
  box-shadow: none;
  border: 1px solid rgba(214, 200, 178, 0.85);
}

button.danger {
  background: #8b1e1e;
  box-shadow: 0 10px 24px rgba(139, 30, 30, 0.22);
}

label {
  display: block;
  font-weight: 600;
  margin-bottom: 8px;
}

input {
  width: 100%;
  border-radius: 14px;
  border: 1px solid rgba(214, 200, 178, 0.95);
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.88);
  font: inherit;
  color: var(--text);
}

.stack {
  display: grid;
  gap: 14px;
}

.flash {
  padding: 12px 14px;
  border-radius: 14px;
  margin-bottom: 14px;
}

.flash.success {
  background: rgba(47, 107, 61, 0.12);
  color: var(--success);
}

.flash.error {
  background: rgba(139, 30, 30, 0.12);
  color: var(--error);
}

.hint,
.small {
  font-size: 0.9rem;
}

.mono,
.snippet,
.log {
  font-family: "IBM Plex Mono", "SFMono-Regular", monospace;
}

.snippet,
.log {
  white-space: pre-wrap;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid rgba(214, 200, 178, 0.85);
  background: #fffdfa;
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  text-align: left;
  padding: 12px 8px;
  border-bottom: 1px solid rgba(214, 200, 178, 0.7);
  vertical-align: top;
}

a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 700;
}

.actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.actions form {
  margin: 0;
}

.actions button {
  padding: 8px 12px;
  font-size: 0.92rem;
}

@media (max-width: 900px) {
  .grid.two,
  .meta {
    grid-template-columns: 1fr;
  }

  .hero {
    flex-direction: column;
  }
}
