/* Apollo Build Service portal. Self-hosted, no web fonts, no third-party assets.
 * Light/dark via prefers-color-scheme; layouts hold down to 360 px wide. */

:root {
  color-scheme: light dark;
  --bg: #f5f6fb;
  --bg-elev: #ffffff;
  --surface: #ffffff;
  --surface-2: #f0f2f9;
  --surface-3: #e7eaf4;
  --text: #121626;
  --text-2: #353b52;
  --muted: #5a6178;
  --border: #e1e4ee;
  --border-strong: #c9cee0;
  --accent: #4152f0;
  --accent-hover: #3343d8;
  --accent-ink: #ffffff;
  --accent-soft: #eceffe;
  --accent-2: #8b5cf6;
  --ok: #157f3c;
  --ok-soft: #e5f6ec;
  --warn: #9a5a00;
  --warn-soft: #fff4e0;
  --danger: #c0262d;
  --danger-hover: #a51f25;
  --danger-soft: #fdecec;
  --info: #2f5bd3;
  --info-soft: #eaf0fe;
  --focus: #4152f0;
  --shadow-sm: 0 1px 2px rgba(18, 22, 38, 0.06);
  --shadow: 0 1px 2px rgba(18, 22, 38, 0.05), 0 8px 24px rgba(18, 22, 38, 0.06);
  --radius: 14px;
  --radius-sm: 9px;
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial,
    "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji";
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  --emoji: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", "Twemoji Mozilla", sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b0e17;
    --bg-elev: #10141f;
    --surface: #131828;
    --surface-2: #1a2034;
    --surface-3: #232a42;
    --text: #e9ecf6;
    --text-2: #c8cde0;
    --muted: #9ba3bb;
    --border: #262e47;
    --border-strong: #354062;
    --accent: #8d99ff;
    --accent-hover: #a7b0ff;
    --accent-ink: #0b0e17;
    --accent-soft: #1e2546;
    --accent-2: #b597ff;
    --ok: #5ad48a;
    --ok-soft: #12301f;
    --warn: #f3b552;
    --warn-soft: #33270f;
    --danger: #ff7a7f;
    --danger-hover: #ff969a;
    --danger-soft: #3a1619;
    --info: #8fb0ff;
    --info-soft: #182444;
    --focus: #a7b0ff;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.35), 0 10px 30px rgba(0, 0, 0, 0.35);
  }
}

/* ---- base ---------------------------------------------------------------------------- */

[hidden] {
  display: none !important;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3 {
  line-height: 1.25;
  margin: 0 0 0.5rem;
  letter-spacing: -0.01em;
}

h1 {
  font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.15rem);
  font-weight: 750;
}

h2 {
  font-size: 1.15rem;
  font-weight: 680;
}

h3 {
  font-size: 1rem;
  font-weight: 650;
}

p {
  margin: 0 0 0.85rem;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

a:hover {
  color: var(--accent-hover);
}

code,
.mono {
  font-family: var(--mono);
  font-size: 0.92em;
}

code {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.05em 0.35em;
}

code.wrap {
  overflow-wrap: anywhere;
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  border-radius: 6px;
}

main:focus {
  outline: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip {
  position: absolute;
  left: 12px;
  top: -48px;
  z-index: 20;
  background: var(--accent);
  color: var(--accent-ink);
  padding: 0.5rem 0.9rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  text-decoration: none;
}

.skip:focus {
  top: 12px;
}

.muted {
  color: var(--muted);
}

.small {
  font-size: 0.875rem;
}

.icon {
  flex: none;
  vertical-align: -0.2em;
}

ul.plain {
  list-style: none;
  padding: 0;
  margin: 0 0 0.6rem;
}

/* ---- top bar and navigation ------------------------------------------------------------ */

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--bg-elev) 88%, transparent);
  backdrop-filter: saturate(160%) blur(10px);
  -webkit-backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--border);
}

.topbar-inner,
.mainnav-inner,
.footer-inner,
.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding-left: 16px;
  padding-right: 16px;
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 60px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  min-width: 0;
}

.brand:hover {
  color: var(--text);
}

.logo-mark {
  flex: none;
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
}

.brand-text {
  font-size: 1.05rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand-name {
  font-weight: 800;
  letter-spacing: -0.01em;
}

.brand-product {
  font-weight: 500;
  color: var(--muted);
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.iconbtn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 0;
  background: transparent;
  color: var(--text-2);
  cursor: pointer;
  text-decoration: none;
}

.iconbtn:hover,
.iconbtn.is-current {
  background: var(--surface-2);
  color: var(--text);
}

.iconbtn .dot {
  position: absolute;
  top: 3px;
  right: 2px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--danger);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
}

.inline-form {
  display: inline;
  margin: 0;
}

.mainnav {
  border-top: 1px solid var(--border);
}

.mainnav-inner {
  display: flex;
  gap: 2px;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.mainnav-inner::-webkit-scrollbar {
  display: none;
}

.navlink {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0.7rem 0.8rem;
  color: var(--muted);
  font-weight: 560;
  font-size: 0.93rem;
  text-decoration: none;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
}

.navlink:hover {
  color: var(--text);
}

.navlink[aria-current="page"] {
  color: var(--text);
  border-bottom-color: var(--accent);
}

.navlink[aria-current="page"] .icon {
  color: var(--accent);
}

/* ---- page layout ----------------------------------------------------------------------- */

.container {
  flex: 1 0 auto;
  padding-top: 28px;
  padding-bottom: 48px;
}

.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 24px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

.page-head > div {
  max-width: 720px;
}

.page-head form {
  margin: 0;
}

.eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.lede {
  color: var(--text-2);
  font-size: 1.05rem;
  margin: 0;
}

.section-title {
  margin: 30px 0 12px;
}

.crumbs {
  font-size: 0.9rem;
  color: var(--muted);
  margin-bottom: 10px;
}

.crumbs a {
  color: var(--muted);
}

.grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 330px), 1fr));
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr));
}

.grid + section,
.card + section,
section + section {
  margin-top: 8px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px;
  min-width: 0;
}

.card > h2 {
  display: flex;
  align-items: center;
  gap: 9px;
}

.card > h2 .icon {
  color: var(--accent);
}

.card > :last-child {
  margin-bottom: 0;
}

.container > .card + .card,
.container > .card + .grid,
.container > .grid + .grid {
  margin-top: 18px;
}

.card-accent {
  background:
    radial-gradient(120% 140% at 100% 0%, color-mix(in srgb, var(--accent) 12%, transparent), transparent 55%),
    var(--surface);
}

.card-danger {
  border-color: color-mix(in srgb, var(--danger) 35%, var(--border));
}

.card-danger > h2 .icon {
  color: var(--danger);
}

.cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
}

.empty {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 22px;
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius);
  color: var(--muted);
  background: var(--surface);
}

.empty p {
  margin: 0;
}

.empty .icon {
  width: 26px;
  height: 26px;
  color: var(--accent);
}

/* ---- buttons and forms ----------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 0.55rem 1.05rem;
  border-radius: 10px;
  border: 1px solid transparent;
  font: inherit;
  font-weight: 620;
  font-size: 0.95rem;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.btn-primary {
  background: var(--accent);
  color: var(--accent-ink);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.15) inset, var(--shadow-sm);
}

.btn-primary:hover {
  background: var(--accent-hover);
  color: var(--accent-ink);
}

.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border-strong);
}

.btn-secondary:hover {
  background: var(--surface-2);
  color: var(--text);
}

.btn-ghost {
  background: transparent;
  color: var(--text-2);
  border-color: var(--border);
}

.btn-ghost:hover {
  background: var(--surface-2);
  color: var(--text);
}

.btn-danger {
  background: var(--danger);
  color: #fff;
}

.btn-danger:hover {
  background: var(--danger-hover);
  color: #fff;
}

@media (prefers-color-scheme: dark) {
  .btn-danger,
  .btn-danger:hover {
    color: #1a0a0b;
  }
}

.btn-sm {
  min-height: 34px;
  padding: 0.35rem 0.75rem;
  font-size: 0.88rem;
}

.btn-block {
  width: 100%;
}

.btn[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
}

.btn.is-copied {
  border-color: var(--ok);
  color: var(--ok);
}

.field {
  margin-bottom: 14px;
}

.field label {
  display: block;
  font-weight: 600;
  font-size: 0.92rem;
  margin-bottom: 6px;
}

input[type="text"],
input[type="email"] {
  width: 100%;
  min-height: 44px;
  padding: 0.55rem 0.8rem;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  background: var(--bg-elev);
  color: var(--text);
  font: inherit;
}

input[type="text"]:focus,
input[type="email"]:focus {
  border-color: var(--accent);
  outline: 3px solid color-mix(in srgb, var(--accent) 30%, transparent);
  outline-offset: 0;
}

input[readonly] {
  background: var(--surface-2);
}

.hint {
  font-size: 0.86rem;
  color: var(--muted);
  margin: 6px 0 0;
}

.check {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}

.check input {
  width: 20px;
  height: 20px;
  accent-color: var(--accent);
}

.check label {
  font-weight: 600;
}

.form-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  flex-wrap: wrap;
}

.form-row .grow {
  flex: 1 1 260px;
  margin-bottom: 0;
}

.form-row > .btn {
  margin-top: 28px;
}

.stack > * + * {
  margin-top: 12px;
}

.copybox {
  display: flex;
  gap: 8px;
}

.copybox input {
  flex: 1 1 auto;
  min-width: 0;
}

.copybox-big input {
  font-size: clamp(1.15rem, 0.9rem + 1.6vw, 1.75rem);
  font-weight: 700;
  letter-spacing: 0.06em;
  min-height: 60px;
  text-align: center;
  color: var(--text);
}

.arrowlink {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  text-decoration: none;
}

.arrowlink:hover .icon {
  transform: translateX(2px);
}

/* ---- alerts, badges, banners ------------------------------------------------------------ */

.alert {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 13px 15px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  margin: 0 0 18px;
}

.alert > .icon {
  margin-top: 2px;
}

.alert p:last-child,
.alert ul:last-child {
  margin-bottom: 0;
}

.alert-title {
  font-size: 1rem;
  margin-bottom: 4px;
}

.alert-ok {
  background: var(--ok-soft);
  border-color: color-mix(in srgb, var(--ok) 30%, transparent);
}

.alert-ok > .icon {
  color: var(--ok);
}

.alert-info {
  background: var(--info-soft);
  border-color: color-mix(in srgb, var(--info) 25%, transparent);
}

.alert-info > .icon {
  color: var(--info);
}

.alert-warn {
  background: var(--warn-soft);
  border-color: color-mix(in srgb, var(--warn) 30%, transparent);
}

.alert-warn > .icon {
  color: var(--warn);
}

.alert-danger {
  background: var(--danger-soft);
  border-color: color-mix(in srgb, var(--danger) 30%, transparent);
}

.alert-danger > .icon {
  color: var(--danger);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0.12rem 0.55rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  white-space: nowrap;
  border: 1px solid transparent;
}

.badge::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.badge-ok {
  background: var(--ok-soft);
  color: var(--ok);
}

.badge-warn {
  background: var(--warn-soft);
  color: var(--warn);
}

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

.badge-info {
  background: var(--info-soft);
  color: var(--info);
}

.badge-muted {
  background: var(--surface-2);
  color: var(--muted);
  border-color: var(--border);
}

.statusline {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.testbanner {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin: 0 0 22px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  color: #3b2a00;
  background: repeating-linear-gradient(-45deg, #ffd166, #ffd166 12px, #ffc94d 12px, #ffc94d 24px);
  font-size: 0.92rem;
}

.testbanner strong {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.8rem;
  background: #3b2a00;
  color: #ffd166;
  padding: 2px 8px;
  border-radius: 6px;
}

.checklist {
  list-style: none;
  padding: 0;
  margin: 14px 0;
}

.checklist li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 8px;
  color: var(--text-2);
}

.checklist .icon {
  color: var(--ok);
  margin-top: 3px;
}

/* ---- fingerprint ------------------------------------------------------------------------ */

.sas {
  list-style: none;
  margin: 6px 0 4px;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 5px;
}

.sas li {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 10px 0 8px;
  border-radius: 12px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  min-width: 0;
}

.sas-emoji {
  font-family: var(--emoji);
  font-size: clamp(1.5rem, 1.1rem + 1.5vw, 2.1rem);
  line-height: 1.1;
}

.sas-name {
  font-size: 0.64rem;
  letter-spacing: -0.01em;
  font-weight: 600;
  color: var(--muted);
  text-align: center;
  overflow-wrap: break-word;
  hyphens: none;
  max-width: 100%;
  line-height: 1.15;
}

.sas-small li {
  padding: 6px 1px 5px;
  border-radius: 9px;
}

.sas-small .sas-emoji {
  font-size: 1.35rem;
}

.sas-small .sas-name {
  font-size: 0.62rem;
}

.sas-names {
  font-size: 0.85rem;
  margin: 6px 0 10px;
}

.inline-sas {
  font-family: var(--emoji);
  white-space: nowrap;
}

.hexpin {
  font-family: var(--mono);
  font-size: 0.86rem;
  line-height: 1.7;
  letter-spacing: 0.02em;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  border: 1px solid var(--border);
  overflow-x: auto;
}

.hexrow {
  display: block;
  white-space: nowrap;
}

.hexdetails summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 0.9rem;
  margin: 6px 0;
  color: var(--text-2);
}

.hexdetails .btn {
  margin-top: 8px;
}

/* ---- stats and meters ------------------------------------------------------------------- */

.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 6px 0 14px;
}

.stats-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.stat {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.stat-label {
  font-size: 0.78rem;
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.stat-value {
  font-size: clamp(1.15rem, 0.95rem + 0.9vw, 1.55rem);
  font-weight: 750;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}

progress.meter {
  -webkit-appearance: none;
  appearance: none;
  display: block;
  width: 100%;
  height: 10px;
  border: 0;
  border-radius: 999px;
  background: var(--surface-3);
  overflow: hidden;
  margin: 4px 0 10px;
}

progress.meter::-webkit-progress-bar {
  background: var(--surface-3);
  border-radius: 999px;
}

progress.meter::-webkit-progress-value {
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  border-radius: 999px;
}

progress.meter::-moz-progress-bar {
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  border-radius: 999px;
}

progress.meter-warn::-webkit-progress-value {
  background: var(--warn);
}

progress.meter-warn::-moz-progress-bar {
  background: var(--warn);
}

/* ---- key display and countdown ---------------------------------------------------------- */

.card-key {
  border-color: color-mix(in srgb, var(--accent) 40%, var(--border));
  background:
    radial-gradient(100% 120% at 0% 0%, color-mix(in srgb, var(--accent) 10%, transparent), transparent 60%),
    var(--surface);
  margin-bottom: 18px;
}

.countdown-line {
  margin: 0;
}

.countdown-line .icon {
  margin-right: 4px;
}

.countdown-text {
  font-variant-numeric: tabular-nums;
  color: var(--text);
}

.countdown.is-ending .countdown-text {
  color: var(--warn);
}

.countdown.is-expired .countdown-line {
  display: none;
}

.countdown-expired {
  margin: 8px 0 0;
}

.keyinline {
  font-weight: 700;
  letter-spacing: 0.04em;
}

/* ---- steps -------------------------------------------------------------------------------- */

.steps {
  list-style: none;
  counter-reset: step;
  margin: 0;
  padding: 0;
}

.steps > li {
  counter-increment: step;
  position: relative;
  padding: 0 0 14px 44px;
}

.steps > li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: -2px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 750;
  font-size: 0.9rem;
  color: var(--accent);
  background: var(--accent-soft);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
}

.steps > li:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 15px;
  top: 32px;
  bottom: 4px;
  width: 1px;
  background: var(--border);
}

.steps h3 {
  margin-bottom: 4px;
}

.steps p {
  color: var(--text-2);
  margin-bottom: 0;
}

.numbered {
  padding-left: 1.3rem;
  margin: 0 0 0.85rem;
}

.numbered li {
  margin-bottom: 8px;
}

/* ---- key/value lists ---------------------------------------------------------------------- */

.kv {
  margin: 0 0 12px;
}

.kv > div {
  display: grid;
  grid-template-columns: minmax(110px, 38%) minmax(0, 1fr);
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid var(--border);
}

.kv > div:last-child {
  border-bottom: 0;
}

.kv dt {
  color: var(--muted);
  font-size: 0.9rem;
}

.kv dd {
  margin: 0;
  min-width: 0;
  overflow-wrap: anywhere;
}

.kv-compact > div {
  padding: 6px 0;
}

/* ---- tables ------------------------------------------------------------------------------- */

table.data {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  font-size: 0.94rem;
}

table.data th,
table.data td {
  text-align: left;
  padding: 11px 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

table.data thead th {
  background: var(--surface-2);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

table.data tbody tr:last-child td {
  border-bottom: 0;
}

table.data tbody tr:hover td {
  background: color-mix(in srgb, var(--surface-2) 60%, transparent);
}

table.data tr.is-current td {
  background: var(--accent-soft);
}

table.data .num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

table.data .actions {
  text-align: right;
  white-space: nowrap;
}

table.data .actions form {
  margin: 0;
}

table.data .reason {
  max-width: 360px;
  overflow-wrap: anywhere;
}

.device {
  overflow-wrap: anywhere;
}

table.data .when {
  white-space: nowrap;
}

.refusal {
  display: inline-flex;
  gap: 6px;
  align-items: flex-start;
  color: var(--warn);
  font-weight: 560;
}

.refusal .icon {
  margin-top: 2px;
}

@media (max-width: 760px) {
  table.responsive,
  table.responsive tbody,
  table.responsive tr,
  table.responsive td {
    display: block;
    width: 100%;
  }

  table.responsive {
    background: transparent;
    border: 0;
    box-shadow: none;
  }

  table.responsive thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
  }

  table.responsive tr {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    margin-bottom: 12px;
    padding: 6px 0;
  }

  table.responsive td {
    position: relative;
    border: 0;
    padding: 6px 14px 6px calc(36% + 22px);
    text-align: left;
    min-height: 2.1em;
  }

  table.responsive td.num,
  table.responsive td.actions {
    text-align: left;
  }

  table.responsive td.actions {
    padding-left: 14px;
  }

  table.responsive td[data-label]::before {
    content: attr(data-label);
    position: absolute;
    left: 14px;
    top: 8px;
    width: 36%;
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 650;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    line-height: 1.4;
  }

  table.responsive td:empty {
    display: none;
  }

  table.data .reason {
    max-width: none;
  }
}

/* ---- dashboards and notices --------------------------------------------------------------- */

.dash {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.dash-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.dash-title {
  margin: 0;
  overflow-wrap: anywhere;
}

.dash-title a {
  color: var(--text);
  text-decoration: none;
}

.dash-title a:hover {
  color: var(--accent);
}

.dash-fp p {
  margin: 0 0 4px;
}

.dash-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  margin: auto 0 0;
}

.notices {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.notice {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 4px solid var(--border-strong);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
}

.notice.is-unread.notice-info {
  border-left-color: var(--info);
}

.notice.is-unread.notice-warn {
  border-left-color: var(--warn);
}

.notice-body {
  min-width: 0;
}

.notice-body p:last-child {
  margin-bottom: 0;
}

.notice-title {
  font-size: 1rem;
  display: flex;
  align-items: center;
  gap: 8px;
}

.notice form {
  margin: 0;
  flex: none;
}

.unread-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent);
  flex: none;
}

.notice-banner {
  margin-bottom: 22px;
}

.notice-banner li {
  margin-bottom: 4px;
}

/* ---- billing -------------------------------------------------------------------------------- */

.plan h3 {
  font-size: 1.2rem;
}

.plan form {
  margin: 0;
}

.plan-featured {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--border));
}

/* ---- prose (data handling) ------------------------------------------------------------------ */

.prose {
  max-width: 860px;
}

.prose section {
  margin-bottom: 30px;
}

.prose h2 {
  font-size: 1.3rem;
  margin-bottom: 12px;
}

.prose ul,
.prose ol {
  padding-left: 1.3rem;
}

.prose li {
  margin-bottom: 8px;
  color: var(--text-2);
}

.prose table.pii td:first-child {
  font-weight: 600;
}

/* ---- auth pages ------------------------------------------------------------------------------ */

.page-auth .container {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.auth-wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: 0;
  max-width: 940px;
  width: 100%;
  margin: 0 auto;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.auth-aside {
  padding: 40px 36px;
  color: #eef0ff;
  background:
    radial-gradient(90% 80% at 100% 0%, rgba(255, 209, 102, 0.22), transparent 60%),
    radial-gradient(120% 100% at 0% 100%, rgba(155, 92, 255, 0.55), transparent 60%),
    linear-gradient(150deg, #2b33b8, #4c3fd9 55%, #6b3fd9);
}

.auth-aside h2 {
  font-size: clamp(1.4rem, 1.1rem + 1.2vw, 1.9rem);
  font-weight: 760;
  margin-bottom: 18px;
}

.eyebrow-light {
  color: #ffd98a;
}

.checklist-light li {
  color: #e3e6ff;
}

.checklist-light .icon {
  color: #9ff0bf;
}

.auth-card {
  border: 0;
  border-radius: 0;
  box-shadow: none;
  padding: 40px 36px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.auth-card h1 {
  font-size: 1.6rem;
}

.auth-icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  margin-bottom: 14px;
  background: var(--ok-soft);
  color: var(--ok);
}

.auth-icon-warn {
  background: var(--warn-soft);
  color: var(--warn);
}

.auth-icon .icon {
  width: 24px;
  height: 24px;
}

@media (max-width: 760px) {
  .auth-wrap {
    grid-template-columns: minmax(0, 1fr);
  }

  .auth-aside {
    padding: 26px 22px;
  }

  .auth-aside .checklist {
    margin-bottom: 0;
  }

  .auth-card {
    padding: 26px 22px;
  }
}

/* ---- error page ------------------------------------------------------------------------------ */

.errorpage {
  max-width: 560px;
  margin: 40px auto;
  text-align: center;
}

.errorcode {
  font-size: 4.5rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 10px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.errorpage .lede {
  margin-bottom: 22px;
}

/* ---- footer ---------------------------------------------------------------------------------- */

.footer {
  border-top: 1px solid var(--border);
  background: var(--bg-elev);
  color: var(--muted);
  font-size: 0.88rem;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px 20px;
  flex-wrap: wrap;
  padding-top: 18px;
  padding-bottom: 18px;
}

.footer-inner > span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
}

.footer nav {
  display: flex;
  gap: 6px 18px;
  flex-wrap: wrap;
}

.footer a {
  color: var(--muted);
}

/* ---- small screens ------------------------------------------------------------------------- */

@media (max-width: 560px) {
  .container {
    padding-top: 20px;
  }

  .card {
    padding: 16px;
  }

  .brand-product {
    display: none;
  }

  .stats,
  .stats-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .sas {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .copybox {
    flex-wrap: wrap;
  }

  .copybox .btn {
    flex: 1 1 auto;
  }

  .form-row > .btn {
    margin-top: 0;
    width: 100%;
  }

  .page-head > .btn,
  .page-head > form,
  .page-head > form .btn {
    width: 100%;
  }

  .hexpin {
    font-size: 0.8rem;
  }

  .notice {
    flex-direction: column;
  }

  .mainnav-inner {
    -webkit-mask-image: linear-gradient(to right, #000 82%, transparent);
    mask-image: linear-gradient(to right, #000 82%, transparent);
    padding-right: 40px;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    animation: none !important;
  }
}

@media print {
  .topbar,
  .footer,
  .btn,
  .skip {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
  }
}
