:root {
  color-scheme: light;
  --bg: #eef3f8;
  --panel: #ffffff;
  --text: #172033;
  --muted: #667085;
  --line: #d8e0ec;
  --accent: #2f6fed;
  --accent-strong: #1e55c8;
  --danger: #c83232;
  --success: #197b4c;
  --shadow: 0 18px 50px rgba(21, 34, 58, 0.14);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
input,
select,
textarea {
  font: inherit;
}

.admin-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px 18px;
}

.admin-panel {
  width: min(760px, 100%);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  padding: clamp(22px, 5vw, 40px);
}

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

.admin-kicker {
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
}

h1,
h2 {
  margin: 0;
  line-height: 1.2;
}

h1 {
  font-size: clamp(28px, 5vw, 40px);
}

h2 {
  font-size: 18px;
}

.status-pill {
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  padding: 8px 12px;
  font-size: 13px;
  white-space: nowrap;
}

.status-pill.ready {
  border-color: rgba(25, 123, 76, 0.3);
  color: var(--success);
  background: rgba(25, 123, 76, 0.08);
}

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

.form-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 16px;
}

label {
  display: grid;
  gap: 8px;
}

label span {
  color: #344054;
  font-size: 14px;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  background: #fbfdff;
  padding: 13px 14px;
  outline: none;
}

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

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(47, 111, 237, 0.14);
}

.hint-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
}

.primary-button {
  min-height: 50px;
  border: 0;
  border-radius: 8px;
  background: var(--accent);
  color: #ffffff;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
}

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

.primary-button:disabled {
  cursor: not-allowed;
  opacity: 0.64;
}

.result-panel {
  margin-top: 26px;
  border-top: 1px solid var(--line);
  padding-top: 20px;
  display: grid;
  gap: 12px;
}

pre {
  margin: 0;
  min-height: 88px;
  white-space: pre-wrap;
  word-break: break-word;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0f172a;
  color: #d7e4ff;
  padding: 14px;
  font-size: 13px;
  line-height: 1.55;
}

pre.error {
  color: #ffd7d7;
}

@media (max-width: 640px) {
  .admin-header,
  .hint-row {
    flex-direction: column;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .status-pill {
    align-self: flex-start;
  }
}
