/* Colours, type and rules follow brand/brand-tokens.css and website/style.css (the app's "line HUD" skin).
   Fonts and the mark are served from the public bucket aug-pub (cdn.augaudio.com/brand/v1/). */
@font-face { font-family: "Saira"; font-weight: 400; font-display: swap;
  src: url("https://cdn.augaudio.com/brand/v1/Saira-Regular.woff2") format("woff2"); }
@font-face { font-family: "Saira"; font-weight: 500; font-display: swap;
  src: url("https://cdn.augaudio.com/brand/v1/Saira-Medium.woff2") format("woff2"); }
@font-face { font-family: "Saira"; font-weight: 600; font-display: swap;
  src: url("https://cdn.augaudio.com/brand/v1/Saira-SemiBold.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-weight: 400; font-display: swap;
  src: url("https://cdn.augaudio.com/brand/v1/IBMPlexMono-Regular.woff2") format("woff2"); }

:root {
  color-scheme: dark;
  --bg: #1C1D22; --card: #202127; --hover: #23242A; --well: #16171B; --line: #3A3D46;
  --fg: #E8E6E3; --soft: #C9CCD3; --muted: #8C8F99;
  --accent: #F2726B; --accent-hover: #F58B85; --accent-fg: #1C1D22; --focus: #7FA3C4;
  --warn: #E6B450; --bad: #F2726B; --good: #8FD19E;
  --node: 5px;
  --sans: "Saira", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--fg); font: 400 16px/1.6 var(--sans);
       -webkit-font-smoothing: antialiased; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--accent-hover); }
::selection { background: var(--accent); color: var(--accent-fg); }
header.top, main, footer { max-width: 680px; margin: 0 auto; padding: 0 16px; }

/* Top bar: the skull mark and the name, as on the website. */
header.top { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 72px;
       margin-bottom: 8px; position: relative; }
header.top::after { content: ""; position: absolute; left: 16px; right: 16px; bottom: 0; height: 1px;
       background: var(--line); }
header.top .brand { display: flex; align-items: center; gap: 12px; color: var(--fg); text-decoration: none; }
header.top .brand img { width: auto; height: 40px; }
header.top .brand .name { font: 600 18px/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; }
header.top .brand:focus-visible { outline: 2px solid var(--focus); outline-offset: 5px; }
header.top button.link { font: 500 12px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase;
       text-decoration: none; color: var(--muted); }
header.top button.link:hover { color: var(--fg); }

footer { color: var(--muted); font-size: .875rem; padding-top: 32px; padding-bottom: 40px; }
footer a { color: var(--soft); }

h1 { font: 300 2rem/1.15 var(--sans); margin: 28px 0 16px; letter-spacing: -.005em; }
h2 { font: 500 12px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--muted);
     margin: 28px 0 12px; }
h3 { font: 600 .95rem/1.4 var(--sans); margin: 20px 0 4px; }
p { margin: 0 0 12px; }
.muted, li { color: var(--muted); }

/* Panels: square hairline box with nodes on the top corners, the app's panel edge. */
.card { position: relative; background: var(--card); border: 1px solid var(--line); padding: 24px; margin: 20px 0; }
.card::before, .card::after { content: ""; position: absolute; top: calc((var(--node) + 1px) / -2);
       width: var(--node); height: var(--node); background: var(--soft); }
.card::before { left: calc((var(--node) + 1px) / -2); }
.card::after { right: calc((var(--node) + 1px) / -2); }
.card > h2:first-child { margin-top: 0; }

.key, pre.token { font: 400 1.15rem/1.45 var(--mono); letter-spacing: .04em; color: var(--fg);
       background: var(--well); border: 1px solid var(--line); padding: 12px; margin: 12px 0;
       overflow-wrap: anywhere; user-select: all; }
.key { text-align: center; }
pre.token { font-size: .8rem; letter-spacing: 0; white-space: pre-wrap; word-break: break-all; }

/* Buttons: outline, tracked uppercase; the primary action is accent and fills on hover. */
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0 4px; align-items: center; }
.btn, button { display: inline-flex; align-items: center; gap: 10px; padding: 11px 20px; cursor: pointer;
       font: 600 12px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; text-decoration: none;
       border: 1px solid var(--line); border-radius: 0; color: var(--fg); background: transparent;
       transition: background 120ms, border-color 120ms, color 120ms; }
.btn:hover, button:hover { background: var(--hover); border-color: var(--muted); color: var(--fg); }
.btn.primary, button.primary { border-color: var(--accent); color: var(--accent); }
.btn.primary:hover, button.primary:hover { background: var(--accent); color: var(--accent-fg); }
button.danger { border-color: var(--bad); color: var(--bad); }
button.link { border: 0; padding: 0; background: none; color: var(--muted); text-decoration: underline;
       font: inherit; letter-spacing: 0; text-transform: none; }

label { display: block; margin: 14px 0 6px; font: 500 12px/1.2 var(--sans); letter-spacing: .16em;
       text-transform: uppercase; color: var(--muted); }
input[type=text], input[type=email], textarea, select { width: 100%; font: inherit; color: var(--fg);
       background: var(--well); border: 1px solid var(--line); border-radius: 0; padding: 10px 12px; }
input::placeholder, textarea::placeholder { color: #5E616B; }
textarea { font-family: var(--mono); font-size: .9rem; min-height: 7rem; }
textarea.prose { font-family: inherit; font-size: 1rem; min-height: 10rem; resize: vertical; }
input[readonly] { color: var(--muted); }
input[type=file] { font: inherit; color: var(--muted); max-width: 100%; }
input[type=file]::file-selector-button { font: 600 12px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase;
       padding: 9px 14px; margin-right: 12px; border-radius: 0; border: 1px solid var(--line); color: var(--fg);
       background: transparent; cursor: pointer; }
input:focus, textarea:focus, select:focus { outline: 0; border-color: var(--focus); }
button:focus-visible, .btn:focus-visible, a:focus-visible, summary:focus-visible { outline: 2px solid var(--focus);
       outline-offset: 3px; }

.note { border-left: 2px solid var(--line); padding: 4px 0 4px 12px; color: var(--muted); }
.note.ok { border-color: var(--good); color: var(--fg); }
.note.warn { border-color: var(--warn); color: var(--fg); }
.note.bad { border-color: var(--bad); color: var(--fg); }
.status { font: 500 12px/1.4 var(--sans); letter-spacing: .12em; text-transform: uppercase; }
.status.active { color: var(--good); }
.status.refunded, .status.revoked { color: var(--bad); }
.status.disputed, .status.waiting { color: var(--warn); }
.status.closed { color: var(--muted); }
dl { display: grid; grid-template-columns: max-content 1fr; gap: 4px 16px; margin: 8px 0; }
dt { color: var(--muted); }
dd { margin: 0; overflow-wrap: anywhere; }
ul.machines { list-style: none; padding: 0; margin: 8px 0; }
ul.machines li { color: var(--fg); border-top: 1px solid var(--line); padding: 12px 0; display: flex;
       justify-content: space-between; gap: 12px; flex-wrap: wrap; align-items: center; }
details summary { cursor: pointer; color: var(--accent); }
.licmachines:first-of-type h3 { margin-top: 8px; }
a.small { font-size: .875rem; white-space: nowrap; }
.card.msg { padding: 16px 20px; margin: 12px 0; }
.card.msg::before, .card.msg::after { display: none; }
.card.msg.fromus { border-left: 2px solid var(--accent); }
.msgbody { white-space: pre-wrap; overflow-wrap: anywhere; margin-top: 6px; }
.meta { color: var(--muted); font-size: .875rem; }
.date, .meta .mono { font-variant-numeric: tabular-nums; }
table.purchases { width: 100%; border-collapse: collapse; margin: 8px 0 12px; font-size: .95rem; }
table.purchases th { text-align: left; font: 500 11px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase;
       color: var(--muted); padding: 0 8px 8px 0; }
table.purchases td { border-top: 1px solid var(--line); padding: 10px 8px 10px 0; vertical-align: top; }
table.purchases td.date { white-space: nowrap; }
.keyrow { border-top: 1px solid var(--line); padding-top: 12px; margin-top: 12px; }
.keyrow:first-of-type { border-top: 0; }
.or { color: var(--muted); text-align: center; margin: 8px 0; }
@media (max-width: 480px) { .card { padding: 18px; } .key { font-size: 1rem; } h1 { font-size: 1.7rem; }
  table.purchases { font-size: .875rem; } table.purchases th:last-child, table.purchases td:last-child { display: none; } }

.giftcard { border: 1px solid var(--line); padding: 20px; margin: 16px 0; text-align: center; }
.giftcard .label { font: 500 12px/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.note-text { font-size: 1.05rem; white-space: pre-wrap; }
.url { overflow-wrap: anywhere; color: var(--fg); }
@media print {
  :root { --bg: #fff; --card: #fff; --well: #fff; --line: #bbb; --fg: #111; --muted: #555; --soft: #555; color-scheme: light; }
  header.top, footer, .noprint, .actions { display: none !important; }
  .card { border: 0; padding: 0; }
  .card::before, .card::after { display: none; }
}
