:root {
  --ink: #1d1d1f;
  --muted: #6e6e73;
  --line: rgba(0, 0, 0, 0.12);
  --soft: rgba(255, 255, 255, 0.78);
  --bg: #f5f5f7;
  --accent: #0071e3;
  --good: #248a3d;
  --bad: #d70015;
}

* {
  box-sizing: border-box;
}

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

button,
input {
  font: inherit;
}

.shell {
  width: min(1180px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 34px 0;
}

.topbar,
.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: 30px;
}

h2 {
  font-size: 18px;
}

p,
.hint {
  color: var(--muted);
}

.grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

.panel {
  display: grid;
  gap: 13px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--soft);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.08);
}

label {
  display: grid;
  gap: 7px;
  font-size: 13px;
  font-weight: 700;
}

input {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 0 12px;
}

button {
  min-height: 40px;
  border: 0;
  border-radius: 9px;
  background: var(--accent);
  color: white;
  font-weight: 800;
  cursor: pointer;
}

button.danger {
  background: var(--bad);
}

button.muted {
  border: 1px solid var(--line);
  background: white;
  color: var(--ink);
}

.result,
.license-card {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: white;
}

.result code,
.license-card code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-weight: 800;
}

.license-list {
  display: grid;
  gap: 12px;
}

.license-list.empty {
  min-height: 140px;
  place-items: center;
  color: var(--muted);
  border: 1px dashed var(--line);
  border-radius: 10px;
}

.license-card {
  display: grid;
  gap: 10px;
}

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

.badge {
  color: var(--good);
  font-weight: 800;
}

.badge.off {
  color: var(--bad);
}

.devices {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
}

.license-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.license-actions button {
  min-height: 34px;
  padding: 0 12px;
}

@media (max-width: 760px) {
  .grid,
  .topbar {
    display: grid;
    grid-template-columns: 1fr;
  }
}
