/* ─────────────────────────────────────────────────────────────────────────
   NedDev UI · panel shell
   The chrome shared by every page of the panel: sidebar, toolbar, cards,
   toast. Component styles live in the components themselves.
   ───────────────────────────────────────────────────────────────────────── */

* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { height: 100%; }

body {
  background: #000;
  color: #cbd5e1;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
body.locked { overflow: hidden; position: fixed; width: 100%; }

.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;
}

/* a faint aurora behind the whole panel, so the chrome is not flat black */
body::before {
  content: "";
  position: fixed;
  inset: -25%;
  z-index: -2;
  pointer-events: none;
  background-image:
    radial-gradient(38vw 34vw at 12% 8%, rgba(129,140,248,0.13), transparent 62%),
    radial-gradient(34vw 30vw at 88% 78%, rgba(103,232,249,0.09), transparent 62%),
    radial-gradient(30vw 26vw at 60% 30%, rgba(244,114,182,0.07), transparent 62%);
  filter: blur(52px);
  animation: shellDrift 34s ease-in-out infinite alternate;
}
@keyframes shellDrift {
  to { transform: translate3d(3%, -2%, 0) scale(1.08); }
}

/* film grain over everything, the same treatment the components use */
body::after {
  content: "";
  position: fixed; inset: 0; z-index: 60; pointer-events: none; opacity: 0.075;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 2 2' xmlns='http://www.w3.org/2000/svg'%3E%3Crect width='1' height='1' fill='white'/%3E%3Crect x='1' y='1' width='1' height='1' fill='white'/%3E%3C/svg%3E");
  background-size: 2px 2px;
}

/* A component open in a sheet is the only thing on the screen, and what is
   behind it sits under a veil that is all but solid. The drifting 52px blur
   and the grain are invisible under that, and they still cost a full-viewport
   composite on every frame. A WebGL preview pays for it in dropped frames.
   What cannot be seen is not drawn. */
body.locked::before, body.locked::after { display: none; }

.layout { display: flex; min-height: 100vh; }

/* ───── sidebar ───── */
aside {
  width: 248px; flex: 0 0 auto;
  border-right: 1px solid rgba(255,255,255,0.06);
  padding: 26px 20px 40px;
  position: sticky; top: 0; height: 100vh; overflow-y: auto;
  background: rgba(0,0,0,0.45);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}
aside::-webkit-scrollbar { width: 8px; }
aside::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 4px; }

/* An anchor with no colour of its own falls back to the browser's link blue,
   and a button's falls back to black. Neither shows today, because every
   child sets its own colour, but the first time anyone adds a word directly
   to one of these it lands unreadable and nobody will know why. */
.logo { display: flex; align-items: center; gap: 10px; margin-bottom: 24px; text-decoration: none; color: #fff; }
.logo .mark {
  width: 30px; height: 30px; border-radius: 8px;
  background-image: linear-gradient(135deg, #e4e4e7, #52525b);
  display: grid; place-content: center;
  color: #000; font-weight: 600; font-size: 0.8rem;
}
.logo .name {
  font-size: 0.88rem; font-weight: 300; letter-spacing: 0.22em;
  text-transform: uppercase; color: #fff;
}

.nav-link {
  display: block; padding: 8px 10px; border-radius: 8px; margin-bottom: 3px;
  font-size: 0.82rem; font-weight: 300; color: #94a3b8; text-decoration: none;
  transition: background 0.25s, color 0.25s;
}
.nav-link:hover { background: rgba(255,255,255,0.06); color: #fff; }
.nav-link.on { background: rgba(255,255,255,0.09); color: #fff; font-weight: 400; }
.nav-link:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

.cat-title {
  font-size: 0.6rem; font-weight: 400; letter-spacing: 0.26em;
  text-transform: uppercase; color: #7d8ba1; margin: 24px 0 10px;
}

.set, .cat {
  display: flex; align-items: center; justify-content: space-between;
  width: 100%; padding: 8px 10px; border-radius: 8px;
  border: 0; background: transparent; font-family: inherit;
  font-size: 0.82rem; font-weight: 300; color: #94a3b8;
  cursor: pointer; user-select: none; text-align: left;
  transition: background 0.25s, color 0.25s;
}
.set:hover, .set.on, .cat:hover, .cat.active {
  background: rgba(255,255,255,0.06); color: #fff;
}
.set .count, .cat .count { font-size: 0.68rem; color: #7d8ba1; }
.set:focus-visible, .cat:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

.licence-note {
  margin-top: 26px; padding-top: 18px;
  border-top: 1px solid rgba(255,255,255,0.06);
  font-size: 0.66rem; font-weight: 300; line-height: 1.65; color: #7d8ba1;
}
.licence-note a { color: #c4b5fd; text-decoration: none; }
.licence-note a:hover { text-decoration: underline; }

/* ───── content ───── */
.main { flex: 1; padding: 26px 30px 60px; min-width: 0; }

header.topbar {
  display: flex; align-items: baseline; justify-content: space-between;
  flex-wrap: wrap; gap: 12px; margin-bottom: 20px;
}
.topbar h1 {
  font-size: 1.45rem; font-weight: 100; letter-spacing: 0.06em;
  text-transform: uppercase; color: #fff;
}
.topbar .meta {
  font-size: 0.68rem; font-weight: 300; letter-spacing: 0.2em;
  text-transform: uppercase; color: #7d8ba1;
}

.toolbar { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 22px; }

.search {
  flex: 1; min-width: 220px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px; padding: 11px 14px;
  color: #e2e8f0; font-family: inherit; font-size: 0.85rem; font-weight: 300;
  outline: 0; transition: border-color 0.3s, background 0.3s;
}
.search::placeholder { color: #7d8ba1; }
.search:focus { border-color: rgba(255,255,255,0.28); background: rgba(255,255,255,0.06); }

.seg { display: flex; background: rgba(255,255,255,0.05); border-radius: 10px; padding: 3px; }
.seg button {
  border: 0; background: transparent; cursor: pointer;
  padding: 7px 14px; border-radius: 8px;
  color: #7d8ba1; font-family: inherit;
  font-size: 0.7rem; font-weight: 400; letter-spacing: 0.1em; text-transform: uppercase;
  display: inline-flex; align-items: center; gap: 6px;
  transition: background 0.25s, color 0.25s;
}
.seg button svg { width: 14px; height: 14px; stroke: currentColor; fill: none; stroke-width: 1.8; }
.seg button:hover { color: #d4d4d8; }
.seg button.on { background: rgba(255,255,255,0.12); color: #fff; }
.seg button:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

/* shared button */
.btn {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 14px; border-radius: 9px;
  border: 1px solid rgba(255,255,255,0.12);
  background: transparent; color: #cbd5e1;
  font-family: inherit;
  font-size: 0.7rem; font-weight: 400; letter-spacing: 0.1em;
  text-transform: uppercase; cursor: pointer; white-space: nowrap;
  transition: background 0.25s, color 0.25s, border-color 0.25s;
}
.btn:hover { background: rgba(255,255,255,0.08); color: #fff; border-color: rgba(255,255,255,0.24); }
.btn:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.btn.solid { background: #fafafa; color: #09090b; border-color: transparent; font-weight: 500; }
.btn.solid:hover { background: #e4e4e7; color: #09090b; }
.btn.done { background: #4ade80; color: #052e16; border-color: transparent; }
.btn svg { width: 14px; height: 14px; stroke: currentColor; fill: none; stroke-width: 1.8; }

.empty, .loading {
  padding: 60px 0; text-align: center;
  font-size: 0.85rem; font-weight: 300; color: #7d8ba1;
}

.more {
  display: block; margin: 28px auto 0;
  padding: 11px 24px; border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.14);
  background: transparent; color: #cbd5e1; font-family: inherit;
  font-size: 0.72rem; font-weight: 400; letter-spacing: 0.12em;
  text-transform: uppercase; cursor: pointer;
  transition: background 0.25s, color 0.25s;
}
/* A class that names a display value outranks the browser's own rule for the
   `hidden` attribute, so setting `hidden` on this button did nothing and it
   sat there reading "0 left" under an empty grid. Anything given a display of
   its own has to say what hidden means for it. */
[hidden] { display: none !important; }

.more:hover { background: rgba(255,255,255,0.08); color: #fff; }
.more:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }

/* toast */
.toast {
  position: fixed; left: 50%; bottom: 28px;
  transform: translate(-50%, 14px);
  padding: 11px 20px; border-radius: 11px;
  background: #101013; border: 1px solid rgba(255,255,255,0.14);
  font-size: 0.78rem; font-weight: 300; color: #e4e4e7;
  opacity: 0; pointer-events: none;
  transition: opacity 0.25s, transform 0.32s cubic-bezier(0.16,1,0.3,1);
  z-index: 110;
  box-shadow: 0 16px 40px rgba(0,0,0,0.6);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast code { font-family: "JetBrains Mono", monospace; font-size: 0.72rem; color: #a5b4fc; }

@media (max-width: 860px) {
  aside { display: none; }
  .main { padding: 22px 18px 48px; }
}

@media (prefers-reduced-motion: reduce) {
  body::before { animation: none; }
  .set, .cat, .btn, .more, .toast, .nav-link, .search { transition: none; }
}

/* ─────────────────────────────────────────────────────────────────────────
   Accounts, plans and the panels that read them
   ───────────────────────────────────────────────────────────────────────── */

/* ───── the copy meter in the sidebar ───── */
.meter {
  margin-top: 22px; padding-top: 18px;
  border-top: 1px solid rgba(255,255,255,0.06);
  display: flex; flex-direction: column; gap: 5px;
}
.meter-count {
  font-size: 1.15rem; font-weight: 200; color: #fff; letter-spacing: 0.02em;
}
.meter-count.out { color: #fca5a5; }
.meter-label {
  font-size: 0.62rem; font-weight: 300; letter-spacing: 0.14em;
  text-transform: uppercase; color: #7d8ba1; line-height: 1.5;
}
.meter-plan {
  font-size: 0.64rem; font-weight: 400; letter-spacing: 0.16em;
  text-transform: uppercase;
}
.meter-plan.premium {
  color: #86efac;
}
.meter-who {
  font-size: 0.68rem; font-weight: 300; color: #94a3b8;
  text-decoration: none; word-break: break-all;
}
.meter-who:hover { color: #fff; text-decoration: underline; }
.meter-in {
  border: 1px solid rgba(255,255,255,0.14); background: transparent;
  color: #cbd5e1; font-family: inherit; cursor: pointer;
  padding: 8px 12px; border-radius: 9px;
  font-size: 0.68rem; font-weight: 400; letter-spacing: 0.12em; text-transform: uppercase;
  transition: background 0.25s, color 0.25s;
}
.meter-in:hover { background: rgba(255,255,255,0.08); color: #fff; }
.meter-in:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

/* ───── language picker ───── */
.lang-pick {
  width: 100%; margin-top: 12px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 9px; padding: 8px 10px;
  color: #cbd5e1; font-family: inherit; font-size: 0.76rem; font-weight: 300;
  outline: 0; cursor: pointer;
}
.lang-pick:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.lang-pick option { background: #101013; color: #e4e4e7; }

/* ───── sign-in dialog ───── */
.gate-veil {
  position: fixed; inset: 0; z-index: 120;
  display: grid; place-items: center; padding: 22px;
  background: rgba(0,0,0,0.7);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.gate-card {
  position: relative; width: min(420px, 100%);
  padding: 34px 30px 26px; border-radius: 18px;
  background: #0b0b0f;
  border: 1px solid rgba(255,255,255,0.1);
  box-shadow: 0 30px 80px rgba(0,0,0,0.7);
}
/* Entrar sem escrever nada. Os botões vêm antes do campo de email porque é
   o caminho que quase toda a gente vai querer, e o campo fica para quem não
   tem, ou não quer usar, conta em nenhum dos dois. */
.gate-social { display: grid; gap: 9px; margin-bottom: 16px; }
.gate-with {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  padding: 11px 14px; border-radius: 10px; text-decoration: none;
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.12);
  color: #fafafa; font-size: 14px; font-weight: 500;
  transition: background 0.2s, border-color 0.2s;
}
.gate-with:hover { background: rgba(255,255,255,0.1); border-color: rgba(255,255,255,0.24); }
.gate-with:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.gate-or {
  display: flex; align-items: center; gap: 12px; margin: 0 0 16px;
  font-size: 11.5px; letter-spacing: 0.12em; text-transform: uppercase; color: #6d6d78;
}
.gate-or::before, .gate-or::after {
  content: ""; flex: 1; height: 1px; background: rgba(255,255,255,0.1);
}

/* ── as três portas, na página da conta ──
   Os mesmos botões do diálogo, mas à vista e não por cima da página, porque
   quem abre a página da conta veio precisamente perguntar como se entra. */
.ways { display: grid; gap: 10px; max-width: 380px; }
.way {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  padding: 12px 16px; border-radius: 10px; cursor: pointer; text-decoration: none;
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.12);
  color: #fafafa; font: 500 14px/1 Inter, system-ui, sans-serif;
  transition: background 0.2s, border-color 0.2s;
}
.way:hover { background: rgba(255,255,255,0.1); border-color: rgba(255,255,255,0.24); }
.way:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

/* ── a conversa com o suporte ── */
.thread-box {
  margin-bottom: 16px; padding: 14px; border-radius: 12px;
  background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.07);
}
.thread-head {
  margin: 0 0 12px; font-size: 14px; font-weight: 500;
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
}
.msg {
  padding: 10px 13px; border-radius: 11px; margin-bottom: 8px;
  font-size: 13.5px; font-weight: 300; line-height: 1.6; max-width: 78%;
  white-space: pre-wrap; word-break: break-word;
}
.msg.you   { background: rgba(255,255,255,0.06); margin-right: auto; border-bottom-left-radius: 4px; }
.msg.them  { background: rgba(167,139,250,0.14); margin-left: auto; border-bottom-right-radius: 4px; }
.msg-when {
  display: block; margin-top: 7px;
  font: 500 10.5px/1 "JetBrains Mono", ui-monospace, monospace; color: #6d6d78;
}
.composer { display: flex; gap: 10px; align-items: flex-start; margin-top: 14px; }
.composer textarea {
  flex: 1; padding: 11px 13px; border-radius: 10px; resize: vertical;
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.12);
  color: #fafafa; font: 300 14px/1.6 Inter, system-ui, sans-serif; outline: none;
}
.composer textarea:focus { border-color: #a78bfa; }
.fields { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.fields input {
  padding: 11px 13px; border-radius: 10px;
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.12);
  color: #fafafa; font: 300 14px/1 Inter, system-ui, sans-serif; outline: none;
}
.fields input:focus { border-color: #a78bfa; }
.note-line { margin: 12px 0 0; font-size: 13px; min-height: 1em; }
.note-line.good { color: #4ade80; }
.note-line.bad  { color: #f87171; }
.slab .lead { margin: 0 0 16px; font-size: 14px; font-weight: 300; color: #8b8b93; }

.gate-card h2 {
  font-size: 1.15rem; font-weight: 200; letter-spacing: 0.04em; color: #fff;
}
.gate-blurb {
  margin-top: 9px; font-size: 0.8rem; font-weight: 300;
  line-height: 1.6; color: #94a3b8;
}
.gate-form { margin-top: 20px; display: flex; flex-direction: column; gap: 10px; }
.gate-form input {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px; padding: 12px 14px;
  color: #e2e8f0; font-family: inherit; font-size: 0.86rem; font-weight: 300;
  outline: 0; transition: border-color 0.25s, background 0.25s;
}
.gate-form input::placeholder { color: #64748b; }
.gate-form input:focus { border-color: rgba(255,255,255,0.3); background: rgba(255,255,255,0.06); }
.gate-go {
  border: 0; border-radius: 10px; padding: 12px 16px;
  background: #fafafa; color: #09090b; font-family: inherit;
  font-size: 0.72rem; font-weight: 500; letter-spacing: 0.12em;
  text-transform: uppercase; cursor: pointer;
  transition: background 0.25s;
}
.gate-go:hover { background: #e4e4e7; }
.gate-go:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.gate-error {
  margin-top: 10px; font-size: 0.76rem; font-weight: 300; color: #fca5a5;
}
.gate-legal {
  margin-top: 16px; font-size: 0.66rem; font-weight: 300;
  line-height: 1.6; color: #64748b;
}
.gate-close {
  position: absolute; top: 12px; right: 14px;
  border: 0; background: transparent; color: #64748b;
  font-size: 1.4rem; line-height: 1; cursor: pointer; padding: 4px 8px;
}
.gate-close:hover { color: #fff; }
.gate-close:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

/* ───── panels built from plain sections ───── */
.slab {
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px; padding: 22px 24px;
  background: rgba(255,255,255,0.025);
  margin-bottom: 18px;
}
.slab h2 {
  font-size: 0.66rem; font-weight: 400; letter-spacing: 0.24em;
  text-transform: uppercase; color: #7d8ba1; margin-bottom: 16px;
}
.figures { display: flex; flex-wrap: wrap; gap: 34px; }
.figure .n {
  font-size: 2rem; font-weight: 100; color: #fff; letter-spacing: 0.01em;
  line-height: 1.1;
}
.figure .k {
  margin-top: 4px;
  font-size: 0.62rem; font-weight: 300; letter-spacing: 0.18em;
  text-transform: uppercase; color: #7d8ba1;
}

.rows { width: 100%; border-collapse: collapse; }
.rows th {
  text-align: left; padding: 0 14px 10px 0;
  font-size: 0.6rem; font-weight: 400; letter-spacing: 0.2em;
  text-transform: uppercase; color: #64748b;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
.rows td {
  padding: 11px 14px 11px 0;
  font-size: 0.8rem; font-weight: 300; color: #cbd5e1;
  border-bottom: 1px solid rgba(255,255,255,0.045);
  vertical-align: top;
}
.rows tr:last-child td { border-bottom: 0; }
.rows td .dim { color: #64748b; font-size: 0.74rem; }
.scroll-x { overflow-x: auto; }

.pill {
  display: inline-block; padding: 3px 9px; border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.12);
  font-size: 0.6rem; font-weight: 400; letter-spacing: 0.12em;
  text-transform: uppercase; color: #94a3b8;
}
.pill.premium { border-color: rgba(134,239,172,0.4); color: #86efac; }

.bar { height: 4px; border-radius: 999px; background: rgba(255,255,255,0.08); overflow: hidden; }
.bar span {
  display: block; height: 100%; border-radius: 999px;
  background-image: linear-gradient(90deg, #a5b4fc, #67e8f9);
}

/* ───── plans ───── */
.plans {
  display: grid; gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  align-items: start;
}
.plan {
  border: 1px solid rgba(255,255,255,0.09);
  border-radius: 18px; padding: 28px 26px 26px;
  background: rgba(255,255,255,0.025);
  display: flex; flex-direction: column; gap: 16px;
}
.plan.lead {
  border-color: rgba(165,180,252,0.34);
  background:
    radial-gradient(120% 100% at 0% 0%, rgba(129,140,248,0.12), transparent 62%),
    rgba(255,255,255,0.03);
}
.plan h3 {
  font-size: 0.66rem; font-weight: 400; letter-spacing: 0.24em;
  text-transform: uppercase; color: #94a3b8;
}
.plan .price {
  font-size: 2.6rem; font-weight: 100; color: #fff; line-height: 1;
}
.plan .price small {
  font-size: 0.72rem; font-weight: 300; letter-spacing: 0.14em;
  text-transform: uppercase; color: #7d8ba1; margin-left: 8px;
}
.plan .term { font-size: 0.72rem; font-weight: 300; color: #7d8ba1; }
.plan ul { list-style: none; display: flex; flex-direction: column; gap: 9px; }
.plan li {
  font-size: 0.82rem; font-weight: 300; line-height: 1.55; color: #cbd5e1;
  padding-left: 20px; position: relative;
}
.plan li::before {
  content: ""; position: absolute; left: 2px; top: 0.55em;
  width: 7px; height: 7px; border-radius: 999px;
  background-image: linear-gradient(135deg, #a5b4fc, #67e8f9);
}
.plan .go { margin-top: auto; }

.save-tag {
  display: inline-block; margin-left: 9px;
  padding: 3px 9px; border-radius: 999px;
  background: rgba(134,239,172,0.14); color: #86efac;
  font-size: 0.6rem; font-weight: 400; letter-spacing: 0.12em; text-transform: uppercase;
}

/* ───── prose pages ───── */
.prose { max-width: 68ch; }
.prose h2 {
  margin: 30px 0 10px;
  font-size: 1rem; font-weight: 300; letter-spacing: 0.03em; color: #fff;
}
.prose h3 {
  margin: 22px 0 8px;
  font-size: 0.86rem; font-weight: 400; color: #e2e8f0;
}
.prose p, .prose li {
  font-size: 0.86rem; font-weight: 300; line-height: 1.75; color: #a8b3c4;
  margin-bottom: 11px;
}
.prose ul { padding-left: 20px; }
.prose a { color: #c4b5fd; text-decoration: none; }
.prose a:hover { text-decoration: underline; }
.prose code {
  font-family: "JetBrains Mono", monospace; font-size: 0.78rem;
  color: #a5b4fc; background: rgba(255,255,255,0.05);
  padding: 2px 6px; border-radius: 5px;
}

.notice {
  border: 1px solid rgba(252,211,77,0.28);
  background: rgba(252,211,77,0.06);
  border-radius: 12px; padding: 14px 16px; margin: 18px 0;
  font-size: 0.8rem; font-weight: 300; line-height: 1.65; color: #fde68a;
}

@media (prefers-reduced-motion: reduce) {
  .gate-form input, .gate-go, .meter-in { transition: none; }
}

/* ───── site footer ─────
   Carried by every page. Somebody who lands deep in the catalogue and wants
   the refund policy should not have to find their way back to the landing
   page for it. */
.sitefoot {
  margin-top: 56px; padding-top: 22px;
  border-top: 1px solid rgba(255,255,255,0.06);
  display: flex; flex-wrap: wrap; gap: 14px 26px;
  align-items: center; justify-content: space-between;
  font-size: 0.72rem; font-weight: 300; color: #64748b;
}
.sitefoot .footlinks { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.sitefoot a { color: #94a3b8; text-decoration: none; }
.sitefoot a:hover { color: #fff; text-decoration: underline; }

/* ───── the phone ─────
   The sidebar is hidden below 860px, and everything that lived only inside
   it went with it: sign-in, the copy counter, the language picker, the
   links. This is the same chrome in a bar at the top, so a phone gets the
   whole site rather than the catalogue with the product removed. */
.mobilebar { display: none; }

@media (max-width: 860px) {
  .mobilebar {
    display: block;
    margin: -22px -18px 18px;
    padding: 12px 18px;
    border-bottom: 1px solid rgba(255,255,255,0.07);
    background: rgba(0,0,0,0.6);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
    position: sticky; top: 0; z-index: 50;
  }
  .mobilebar-top {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
  }
  .mobilebar-brand {
    display: flex; align-items: center; gap: 9px;
    text-decoration: none; color: #fff;
    font-size: 0.8rem; font-weight: 300; letter-spacing: 0.18em; text-transform: uppercase;
  }
  .mobilebar-brand .mark {
    width: 26px; height: 26px; border-radius: 7px; flex: 0 0 auto;
    background-image: linear-gradient(135deg, #e4e4e7, #52525b);
    display: grid; place-content: center; color: #000; font-weight: 600; font-size: 0.72rem;
  }
  .mobilebar-right { display: flex; align-items: center; gap: 12px; }

  /* the counter reads across, not down, when it sits in a bar */
  .meter-inline {
    margin: 0; padding: 0; border: 0;
    flex-direction: row; align-items: center; gap: 7px;
  }
  .meter-inline .meter-count { font-size: 0.95rem; }
  .meter-inline .meter-label,
  .meter-inline .meter-who { display: none; }
  .meter-inline .meter-in { padding: 10px 14px; }

  .mobilebar-menu {
    width: 42px; height: 42px; flex: 0 0 auto;
    display: grid; place-content: center; gap: 4px;
    border: 1px solid rgba(255,255,255,0.14); border-radius: 10px;
    background: transparent; cursor: pointer; padding: 0;
  }
  .mobilebar-menu span {
    display: block; width: 16px; height: 1.5px; border-radius: 2px;
    background: #cbd5e1;
  }
  .mobilebar-menu:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

  .mobilebar-drawer {
    margin-top: 12px; padding-top: 12px;
    border-top: 1px solid rgba(255,255,255,0.07);
    display: flex; flex-direction: column; gap: 4px;
  }
  .mobilebar-drawer .nav-link { padding: 12px 10px; font-size: 0.88rem; }
  .mobilebar-drawer .meter-in { margin-top: 8px; }
  .mobilebar-drawer .lang-pick { margin-top: 8px; padding: 12px 10px; }

  /* a footer link at 14px is a coin flip with a thumb */
  .sitefoot { gap: 10px 18px; }
  .sitefoot .footlinks { gap: 4px 14px; }
  .sitefoot a { display: inline-block; padding: 9px 0; }
}

@media (max-width: 860px) {
  /* Anything a thumb has to hit gets 44px of height, the size Apple and
     Google both settled on. These were 26 to 32, which is the difference
     between tapping a thing and tapping near it. */
  .mobilebar-brand { padding: 9px 0; }
  .seg button { padding: 12px 16px; }
  .plan .go .btn, .plan .go button { padding: 13px 18px; }
  .btn { padding: 12px 16px; }
}

/* ───── the thirty day shape ─────
   A total says how big something is. Only a shape says which way it is
   going, and which way it is going is the question a dashboard exists to
   answer. */
.spark {
  margin-top: 22px;
  display: flex; align-items: flex-end; gap: 3px;
  height: 74px;
}
.spark-bar {
  flex: 1; min-width: 3px; border-radius: 2px 2px 0 0;
  background-image: linear-gradient(180deg, #a5b4fc, #4f46e5);
  transition: filter 0.2s;
}
/* A day with no copies is a fact, not an absence of one. At two percent of
   the height and seven percent opacity it read as "no data here", which is a
   different statement and the wrong one. */
.spark-bar.idle {
  background-image: none;
  background: rgba(255,255,255,0.16);
  min-height: 4px;
}
.spark-bar:hover { filter: brightness(1.35); }
.spark-foot {
  margin-top: 9px;
  font-size: 0.62rem; font-weight: 300; letter-spacing: 0.16em;
  text-transform: uppercase; color: #64748b;
}
.topbar .meta .btn { margin-left: 10px; vertical-align: middle; }

@media (prefers-reduced-motion: reduce) { .spark-bar { transition: none; } }

/* ───── focus, for everything ─────
   The panel names a focus ring on each control it knows about, which works
   until somebody adds one it does not: the sidebar logo, the language picker,
   a link in a footer written later. A rule for everything comes first and the
   specific ones still win where they say something different. */
:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
  border-radius: 4px;
}
/* Only for the keyboard. A ring left behind by a mouse click reads as a bug
   to everybody who did not need it. */
:focus:not(:focus-visible) { outline: none; }

/* The wordmark is the brand, whole, rather than a mark beside typed text.
   Sized by height so it sits on the same baseline as the links below it. */
.logo-img { display: block; height: 34px; width: auto; }
@media (max-width: 860px) { .mobilebar-brand img { height: 26px; width: auto; } }
