.admin-shell {
  max-width: 1180px;
  padding-top: 48px;
  padding-bottom: 80px;
}

.admin-header h1 {
  margin: 0 0 6px;
  font-size: 1.9rem;
  font-weight: 900;
}

.admin-header p {
  margin: 0 0 32px;
  color: var(--text-muted);
}

.player-cell {
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.player-cell img {
  width: 24px;
  height: 24px;
  border-radius: 999px;
  flex-shrink: 0;
}

.admin-tabs {
  display: flex;
  gap: 6px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 28px;
  overflow-x: auto;
}

.admin-tab {
  display: flex;
  align-items: center;
  gap: 8px;
  background: none;
  border: none;
  color: var(--text-muted);
  font-weight: 700;
  font-size: 0.92rem;
  padding: 12px 16px;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  white-space: nowrap;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.admin-tab svg {
  display: block;
}

.admin-tab:hover {
  color: var(--text);
}

.admin-tab.active {
  color: var(--text);
  border-bottom-color: var(--accent-b);
}

.admin-panel {
  display: none;
}

.admin-panel.active {
  display: block;
  animation: admin-fade-in 0.15s ease;
}

@keyframes admin-fade-in {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.admin-form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 22px;
  margin-bottom: 24px;
}

.admin-form-row {
  display: flex;
  align-items: flex-end;
  gap: 16px;
  flex-wrap: wrap;
}

.admin-form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  align-items: end;
}

.admin-form-columns {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 28px;
  margin-bottom: 18px;
}

.form-col-inputs,
.form-col-checkboxes {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.form-col-inputs .field,
.form-col-checkboxes .field {
  flex: none;
  min-width: 0;
}

.form-col-checkboxes {
  padding-top: 2px;
}

@media (max-width: 760px) {
  .admin-form-columns {
    grid-template-columns: 1fr;
  }
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  min-width: 180px;
}

.field-wide {
  grid-column: 1 / -1;
}

.field-checkbox {
  flex-direction: row;
  align-items: center;
}

.field-checkbox label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.88rem;
  color: var(--text-muted);
  cursor: pointer;
}

.field label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-muted);
}

.field input,
.field select,
.field textarea {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.92rem;
  outline: none;
  transition: border-color 0.15s ease;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--accent-b);
}

.field textarea {
  resize: vertical;
  min-height: 70px;
}

.admin-table-wrap {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.admin-table th {
  text-align: left;
  padding: 12px 16px;
  color: var(--text-muted);
  font-weight: 700;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.admin-table td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.admin-table tr:last-child td {
  border-bottom: none;
}

.admin-table-empty {
  text-align: center;
  color: var(--text-muted);
  padding: 28px 16px;
}

.admin-table code {
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 0.85em;
  color: var(--accent-a);
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.icon-btn:hover {
  color: var(--danger);
  border-color: rgba(255, 77, 77, 0.4);
  background: rgba(255, 77, 77, 0.08);
}

.pill-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 700;
}

.pill-badge.popular {
  background: rgba(224, 38, 46, 0.16);
  color: var(--accent-a);
}

.pill-badge.status-test_completed,
.pill-badge.status-executed,
.pill-badge.status-completed {
  background: rgba(243, 238, 238, 0.1);
  color: var(--text);
}

.webhook-payload {
  margin: 0;
  padding: 14px 16px;
  background: var(--bg-elevated);
  border-radius: var(--radius-sm);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 0.8rem;
  color: var(--text-muted);
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 320px;
  overflow-y: auto;
}

.pill-badge.status-pending {
  background: rgba(224, 38, 46, 0.14);
  color: var(--accent-a);
}

.admin-panel-toolbar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 14px;
}

.admin-note {
  color: var(--text-muted);
  font-size: 0.84rem;
  margin: 14px 2px 0;
  line-height: 1.6;
}

.admin-result {
  margin-top: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  font-size: 0.88rem;
}

.admin-result.hidden {
  display: none;
}

.admin-note.hidden,
#cancelEditProductBtn.hidden {
  display: none;
}

.admin-result.success {
  border-color: rgba(243, 238, 238, 0.3);
}

.admin-result.error {
  border-color: rgba(255, 77, 77, 0.4);
  color: var(--danger);
}

.perk-list-inline {
  color: var(--text-muted);
  font-size: 0.85rem;
}

/* Staff Training */

.training-section {
  margin-bottom: 40px;
}

.training-section h2 {
  font-size: 1.15rem;
  margin: 0 0 14px;
}

.guide-content {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 22px;
  white-space: pre-wrap;
  line-height: 1.65;
  color: var(--text);
}

.exam-log-item {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  margin-bottom: 10px;
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.exam-log-item:hover {
  transform: translateY(-2px);
  border-color: rgba(224, 38, 46, 0.4);
}

.exam-log-item img {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  flex-shrink: 0;
}

.exam-log-item-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  flex: 1;
  min-width: 0;
}

.exam-log-item-title {
  font-weight: 700;
  font-size: 0.95rem;
}

.exam-log-item-meta {
  color: var(--text-muted);
  font-size: 0.8rem;
}

.field-with-btn {
  display: flex;
  gap: 8px;
}

.field-with-btn input {
  flex: 1;
}

.field-with-btn .icon-btn {
  flex-shrink: 0;
}

.exam-question {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 18px;
  margin-bottom: 14px;
}

.exam-question-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.exam-question-answer {
  color: var(--text-muted);
  font-size: 0.88rem;
  margin: 0 0 12px;
  line-height: 1.5;
}

.exam-summary .field {
  gap: 4px;
}

.exam-summary .field span {
  color: var(--text);
  font-size: 0.92rem;
}

.exam-summary-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 22px;
  margin: 24px 0;
}

.exam-summary-stat {
  flex: 1;
  min-width: 140px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: center;
}

.exam-summary-label {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  font-weight: 700;
}

.exam-summary-value {
  font-size: 1.6rem;
  font-weight: 900;
}

.verdict-pass {
  color: #3ddc73;
}

.verdict-fail {
  color: var(--danger);
}

.post-interview-notes p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.6;
  margin: 0 0 12px;
}

.post-interview-notes p:last-child {
  margin-bottom: 0;
}

.post-interview-notes a {
  color: var(--accent-a);
  text-decoration: underline;
}
