* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: #f7f7f7;
  background: #08090c;
  font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

button,
input {
  font: inherit;
}

button {
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid rgba(216, 181, 109, 0.42);
  border-radius: 8px;
  color: #fff;
  background: #191919;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
}

button:hover,
.job-card:hover {
  border-color: #d8b56d;
}

input {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(216, 181, 109, 0.26);
  border-radius: 8px;
  padding: 0 14px;
  color: #fff;
  background: #090a0d;
  outline: none;
}

input:focus {
  border-color: #d8b56d;
}

.shell {
  display: grid;
  gap: 28px;
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 26px 0 44px;
}

.site-header {
  align-items: center;
  display: flex;
  justify-content: space-between;
  gap: 18px;
}

.brand-mark img {
  display: block;
  height: auto;
  width: clamp(170px, 18vw, 220px);
}

.back-link {
  border: 1px solid rgba(216, 181, 109, 0.28);
  border-radius: 8px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 800;
  padding: 12px 15px;
  text-decoration: none;
  text-transform: uppercase;
}

.topbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 28px;
}

header p,
.label {
  display: block;
  margin: 0 0 10px;
  color: #d8b56d;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 4px;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: clamp(34px, 6vw, 58px);
  line-height: 1;
}

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

.panel,
.auth-panel,
.jobs-panel,
.detail-panel {
  border: 1px solid rgba(216, 181, 109, 0.26);
  border-radius: 8px;
  background: #151515;
}

.panel {
  min-height: 104px;
  padding: 20px;
}

.panel strong {
  display: block;
  font-size: 20px;
}

code {
  display: block;
  color: #ffffff;
  font-size: 16px;
  font-weight: 800;
  word-break: break-word;
}

.auth-panel {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  align-items: end;
  margin-top: 14px;
  padding: 18px;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(360px, 0.85fr);
  gap: 16px;
  margin-top: 16px;
}

.jobs-panel,
.detail-panel {
  min-height: 520px;
  padding: 16px;
}

.section-title {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: baseline;
  margin-bottom: 14px;
}

.section-title strong {
  font-size: 20px;
}

.jobs-list {
  display: grid;
  gap: 10px;
}

.job-card {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  min-height: auto;
  padding: 14px;
  text-align: left;
  border-color: rgba(255, 255, 255, 0.1);
}

.job-card.active {
  border-color: #d8b56d;
  background: #202020;
}

.job-title {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 900;
}

.job-meta,
.muted {
  color: #b7bac4;
  font-size: 13px;
  line-height: 1.55;
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  color: #111;
  background: #d8b56d;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.pill.soft {
  color: #f5f5f5;
  background: #333;
}

.job-detail.empty {
  color: #b7bac4;
}

.detail-block {
  padding: 14px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.detail-block:first-child {
  border-top: 0;
  padding-top: 0;
}

.detail-grid {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 8px 12px;
  color: #d9dce4;
  font-size: 14px;
}

.detail-grid strong {
  font-size: 18px;
  line-height: 1.25;
}

.detail-grid span:nth-child(odd) {
  color: #858a96;
}

.asset-list,
.channel-list {
  display: grid;
  gap: 8px;
}

.asset-link,
.channel-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  color: #fff;
  font-size: 16px;
  background: #0c0d11;
  text-decoration: none;
}

.asset-link strong,
.channel-row strong {
  font-size: 18px;
}

.asset-link:hover {
  color: #d8b56d;
}

.error {
  color: #ffb4a8;
}

@media (max-width: 860px) {
  .topbar,
  .site-header,
  .auth-panel {
    grid-template-columns: 1fr;
    display: grid;
    align-items: stretch;
  }

  .status-grid,
  .workspace {
    grid-template-columns: 1fr;
  }

  .detail-panel {
    min-height: 360px;
  }
}
