:root {
  color-scheme: dark;
  font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  background: #050505;
  color: #f8fafc;
  --line: rgba(255, 255, 255, 0.12);
  --muted: #a7b0c0;
  --muted-soft: #778197;
  --white: #ffffff;
  --silver: #d8dbe1;
  --gold: #d8b56d;
  --gold-soft: #f2d999;
  --gold-line: rgba(216, 181, 109, 0.28);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 15% 5%, rgba(216, 181, 109, 0.16), transparent 28rem),
    radial-gradient(circle at 85% 18%, rgba(242, 217, 153, 0.1), transparent 30rem),
    linear-gradient(180deg, #060910 0%, #05070d 45%, #040404 100%);
}

.shell {
  display: grid;
  gap: 34px;
  min-height: 100vh;
  padding: 26px 20px 44px;
}

.site-header,
.panel {
  margin: 0 auto;
  width: min(100%, 1180px);
}

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

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

.back-link,
.ghost-button {
  border: 1px solid var(--gold-line);
  border-radius: 8px;
  color: var(--white);
  font-size: 13px;
  font-weight: 800;
  padding: 12px 15px;
  text-decoration: none;
  text-transform: uppercase;
}

.panel {
  align-self: start;
  background:
    linear-gradient(145deg, rgba(216, 181, 109, 0.1), rgba(255, 255, 255, 0.02)),
    rgba(6, 9, 16, 0.86);
  border: 1px solid var(--gold-line);
  border-radius: 8px;
  box-shadow: 0 35px 90px rgba(0, 0, 0, 0.35);
  padding: 34px;
}

.brand {
  color: var(--gold-soft);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.22em;
  margin-bottom: 10px;
  text-transform: uppercase;
}

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

.intro {
  color: var(--muted);
  font-size: 18px;
  line-height: 1.55;
  margin: 18px 0 28px;
  max-width: 760px;
}

.content-form {
  display: grid;
  gap: 18px;
}

.controls {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}

label {
  color: var(--silver);
  font-size: 14px;
  font-weight: 700;
}

input,
textarea,
button {
  border-radius: 8px;
  font: inherit;
  width: 100%;
}

input,
textarea {
  background: #050814;
  border: 1px solid var(--line);
  color: var(--white);
  margin-top: 7px;
  padding: 12px;
}

textarea {
  min-height: 110px;
  resize: vertical;
}

.wide-label {
  display: grid;
}

button {
  background: linear-gradient(135deg, #fff7df 0%, var(--gold) 100%);
  border: 0;
  color: #080808;
  cursor: pointer;
  font-weight: 800;
  padding: 15px 18px;
  text-transform: uppercase;
}

button:disabled {
  background: #8a93a3;
  cursor: wait;
}

.ghost-button {
  background: rgba(216, 181, 109, 0.05);
  color: var(--white);
  max-width: 170px;
}

.status {
  color: var(--muted);
  margin: 0;
  min-height: 22px;
}

.results {
  margin-top: 30px;
}

.result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 18px;
}

.result-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.result-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  padding: 18px;
}

.result-card h2 {
  color: var(--gold-soft);
  font-size: 18px;
  margin: 0 0 12px;
}

.result-card pre {
  color: var(--muted);
  font-family: inherit;
  line-height: 1.65;
  margin: 0;
  white-space: pre-wrap;
}

@media (max-width: 680px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 18px;
  }

  .back-link,
  .ghost-button {
    max-width: none;
    text-align: center;
    width: 100%;
  }

  .panel {
    padding: 24px;
  }
}
