﻿:root {
  --bg: #f4efe7;
  --panel: #fffdf8;
  --panel-accent: #f1e0c5;
  --text: #1f1a15;
  --muted: #6f6457;
  --line: #dfd2c0;
  --primary: #0f5b4f;
  --primary-hover: #0b483f;
  --danger: #b63f32;
  --danger-soft: #fbe3de;
  --success: #1e7a54;
  --success-soft: #dff4e8;
  --pending: #7a561e;
  --pending-soft: #f8edd8;
  --shadow: 0 22px 50px rgba(55, 38, 16, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(233, 207, 154, 0.45), transparent 28%),
    radial-gradient(circle at bottom right, rgba(15, 91, 79, 0.16), transparent 24%),
    linear-gradient(180deg, #f7f3ec 0%, #efe6d8 100%);
}

a {
  color: var(--primary);
  text-decoration: none;
}

code {
  padding: 0.15rem 0.35rem;
  border-radius: 6px;
  background: #f2ede4;
  font-family: Consolas, "Courier New", monospace;
  font-size: 0.92rem;
}

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

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

.topbar h1 {
  margin: 8px 0 0;
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 0.95;
}

.eyebrow {
  margin: 0;
  color: var(--muted);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-size: 0.74rem;
}

.content {
  display: grid;
  gap: 22px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 22px;
}

.panel,
.auth-card,
.slot-card,
.empty-state,
.flash {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.panel,
.auth-card,
.slot-card {
  padding: 24px;
}

.panel.accent {
  background: linear-gradient(180deg, #f6ebd7 0%, #f3e1c0 100%);
}

.card-header h2,
.section-title h2,
.slot-card h3 {
  margin: 0 0 8px;
}

.card-header p,
.section-title p,
.muted,
.small-note {
  margin: 0;
  color: var(--muted);
}

.info-stack {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.button,
button,
.button:visited {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  background: var(--primary);
  color: #fff;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.95rem;
}

.button:hover,
button:hover {
  background: var(--primary-hover);
}

.button.secondary {
  background: #efe4d3;
  color: var(--text);
}

.button.secondary:hover {
  background: #e4d4bc;
}

.form-grid,
.inline-form {
  display: grid;
  gap: 14px;
}

label {
  display: grid;
  gap: 8px;
  font-weight: 700;
}

input {
  width: 100%;
  min-height: 50px;
  padding: 0 14px;
  border: 1px solid #d2c4b0;
  border-radius: 14px;
  background: #fff;
  font: inherit;
}

input:focus {
  outline: 2px solid rgba(15, 91, 79, 0.2);
  border-color: var(--primary);
}

.auth-card {
  width: min(560px, 100%);
  margin: 0 auto;
}

.switch-link {
  margin: 18px 0 0;
  color: var(--muted);
}

.flash {
  padding: 16px 18px;
}

.flash-success {
  background: var(--success-soft);
  border-color: #b8dec7;
  color: #15543a;
}

.flash-error {
  background: var(--danger-soft);
  border-color: #e9b9b1;
  color: #86291f;
}

.error-box,
.success-box,
.webhook-box {
  margin-top: 18px;
  padding: 16px;
  border-radius: 18px;
}

.error-box,
.error-inline {
  background: var(--danger-soft);
  color: #86291f;
}

.success-box {
  background: var(--success-soft);
}

.webhook-box {
  background: rgba(255, 255, 255, 0.5);
}

.slots-section {
  display: grid;
  gap: 18px;
}

.slots-grid {
  display: grid;
  gap: 18px;
}

.slot-card {
  display: grid;
  gap: 16px;
}

.slot-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.slot-meta {
  display: grid;
  gap: 8px;
}

.slot-meta p,
.success-box p,
.webhook-box p {
  margin: 0;
}

.slot-actions {
  display: grid;
  gap: 14px;
}

.status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
}

.status-pending_payment {
  background: var(--pending-soft);
  color: var(--pending);
}

.status-awaiting_key {
  background: #dbe7fb;
  color: #2754a7;
}

.status-submitted {
  background: var(--success-soft);
  color: var(--success);
}

.status-failed {
  background: var(--danger-soft);
  color: var(--danger);
}

.empty-state {
  padding: 22px;
  color: var(--muted);
}

.button-row {
  display: flex;
  gap: 12px;
  margin-top: 18px;
}

@media (max-width: 860px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }

  .topbar,
  .slot-top {
    flex-direction: column;
  }

  .page-shell {
    width: min(100% - 20px, 1120px);
    padding-top: 18px;
  }
}
