:root {
  --bg: #f2eadf;
  --paper: rgba(255, 250, 243, 0.82);
  --ink: #16212a;
  --muted: #56616b;
  --line: rgba(22, 33, 42, 0.12);
  --accent: #b7492a;
  --accent-dark: #7f2f1c;
  --secondary: #275d63;
  --success: #1f7a53;
  --warning: #9e5b00;
  --error: #a33232;
  --shadow: 0 24px 64px rgba(22, 33, 42, 0.14);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: 'Segoe UI Variable', 'Trebuchet MS', sans-serif;
  background:
    radial-gradient(circle at top left, rgba(183, 73, 42, 0.18), transparent 32%),
    radial-gradient(circle at bottom right, rgba(39, 93, 99, 0.16), transparent 28%),
    linear-gradient(135deg, #efe0cf, #f7f3ed 55%, #ede5dc);
}

.page-shell {
  display: grid;
  grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
  min-height: 100vh;
}

.hero-panel {
  padding: 48px 36px;
  background: linear-gradient(180deg, rgba(22, 33, 42, 0.96), rgba(48, 64, 76, 0.88));
  color: #f7f0e5;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.hero-panel h1,
.app-panel h2,
.app-panel h3 {
  font-family: Georgia, 'Times New Roman', serif;
  letter-spacing: 0.02em;
  margin: 0;
}

.hero-copy {
  line-height: 1.6;
  max-width: 28ch;
}

.hero-card {
  padding: 18px 20px;
  border: 1px solid rgba(247, 240, 229, 0.16);
  border-radius: 18px;
  background: rgba(247, 240, 229, 0.08);
  backdrop-filter: blur(14px);
}

.hero-label,
.eyebrow {
  display: inline-block;
  font-size: 0.74rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: inherit;
  opacity: 0.72;
  margin-bottom: 12px;
}

.app-panel {
  padding: 32px;
}

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.card-large {
  max-width: 480px;
  margin: 64px auto;
  padding: 28px;
}

.toolbar,
.section-heading,
.inline-heading,
.toolbar-actions,
.status-grid,
.layout-grid,
.button-row,
.button-column {
  display: flex;
}

.toolbar,
.inline-heading,
.toolbar-actions,
.button-row {
  align-items: center;
}

.toolbar,
.inline-heading {
  justify-content: space-between;
}

.toolbar {
  margin-bottom: 24px;
}

.toolbar-actions,
.button-row,
.button-column,
.status-grid,
.layout-grid {
  gap: 12px;
}

.button-column,
.section-heading,
.stack-form {
  flex-direction: column;
}

.status-grid,
.layout-grid {
  margin-bottom: 20px;
}

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

.layout-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
}

.status-card,
.runs-card,
.config-card {
  padding: 22px;
}

.stack-form {
  gap: 14px;
}

.compact {
  gap: 18px;
}

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

label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-weight: 600;
  color: var(--muted);
}

input,
button {
  font: inherit;
}

input[type='text'],
input[type='email'],
input[type='password'],
input[type='number'] {
  width: 100%;
  padding: 13px 14px;
  border-radius: 14px;
  border: 1px solid rgba(22, 33, 42, 0.16);
  background: rgba(255, 255, 255, 0.85);
  color: var(--ink);
}

input[type='checkbox'] {
  width: 18px;
  height: 18px;
}

.button {
  border: 0;
  border-radius: 999px;
  padding: 12px 18px;
  cursor: pointer;
  transition: transform 160ms ease, opacity 160ms ease, background 160ms ease;
}

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

.button.primary {
  background: linear-gradient(135deg, var(--accent), #cf6c3b);
  color: #fff7f0;
}

.button.secondary {
  background: linear-gradient(135deg, var(--secondary), #397f87);
  color: #eef8f8;
}

.button.ghost {
  background: rgba(22, 33, 42, 0.06);
  color: var(--ink);
}

.pill {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(22, 33, 42, 0.08);
  color: var(--muted);
}

.notice {
  padding: 12px 14px;
  border-radius: 14px;
  margin-top: 14px;
}

.notice.success {
  background: rgba(31, 122, 83, 0.12);
  color: var(--success);
}

.notice.error {
  background: rgba(163, 50, 50, 0.12);
  color: var(--error);
}

.notice.warning {
  background: rgba(158, 91, 0, 0.12);
  color: var(--warning);
}

.muted,
.status-label {
  color: var(--muted);
}

.runs-table-wrap {
  overflow-x: auto;
}

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

.runs-table th,
.runs-table td {
  text-align: left;
  padding: 12px 10px;
  border-bottom: 1px solid rgba(22, 33, 42, 0.08);
  vertical-align: top;
}

.status-chip {
  display: inline-block;
  min-width: 92px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.82rem;
  text-align: center;
}

.status-chip.success {
  background: rgba(31, 122, 83, 0.14);
  color: var(--success);
}

.status-chip.partial,
.status-chip.warning {
  background: rgba(158, 91, 0, 0.14);
  color: var(--warning);
}

.status-chip.error {
  background: rgba(163, 50, 50, 0.14);
  color: var(--error);
}

.status-chip.idle {
  background: rgba(22, 33, 42, 0.08);
  color: var(--muted);
}

.hidden {
  display: none !important;
}

@media (max-width: 1080px) {
  .page-shell,
  .layout-grid,
  .status-grid,
  .form-grid {
    grid-template-columns: 1fr;
  }

  .hero-panel {
    min-height: 280px;
  }
}

@media (max-width: 720px) {
  .app-panel,
  .hero-panel {
    padding: 22px;
  }

  .toolbar,
  .inline-heading,
  .toolbar-actions,
  .button-row {
    flex-direction: column;
    align-items: stretch;
  }
}