/* ClearCall account pages. Components follow the landing page (landing/src/layouts/Layout.astro) so both
   feel like one product. Every design value is a variable from tokens.css, generated from
   design/tokens.json (`make tokens`) and linked before this file. No inline styles anywhere: the CSP allows
   only same-origin stylesheets and the fonts beside them. See docs/design/DESIGN.md. */
@font-face { font-family: "Geist"; src: url("/static/fonts/Geist-latin.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }
* { box-sizing: border-box; }
html { font-size: var(--base-product); color-scheme: light dark; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
body {
  margin: 0; min-width: 320px; min-height: 100vh; display: flex; flex-direction: column;
  background: var(--bg); color: var(--fg); font: var(--text-base)/var(--leading-body) var(--sans); letter-spacing: var(--tracking-body);
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
}
h1, h2 { font-family: var(--sans); font-weight: var(--weight-semibold); line-height: var(--leading-heading); letter-spacing: var(--tracking-tight); text-wrap: balance; }
h1 { font-size: var(--text-heading); margin: 0 0 var(--space-8); }
h2 { font-size: var(--text-2xl); margin: 0 0 var(--space-5); }
p { margin: 0 0 var(--space-8); }
ul { margin: 0 0 var(--space-8); padding-left: var(--space-10); }
li { margin-bottom: var(--space-3); }
a { color: var(--fg); text-decoration-color: var(--accent); text-decoration-thickness: var(--underline-width); text-underline-offset: var(--underline-offset); }
a:hover { text-decoration-color: var(--fg); }
:focus-visible { outline: none; box-shadow: var(--focus-ring); border-radius: var(--radius-sm); }
@media (forced-colors: active) {
  :focus-visible { outline: var(--focus-outline-width) solid CanvasText; outline-offset: var(--focus-outline-offset); }
}
.wrap { width: 100%; max-width: var(--measure-mid); margin: 0 auto; padding-inline: var(--gutter); }
main.wrap { flex: 1; padding-block: var(--space-13); }
main.narrow { max-width: var(--measure-form); }
.small { font-size: var(--text-sm); color: var(--muted); }
.lede { font-size: var(--text-lg); color: var(--muted); overflow-wrap: anywhere; }
.eyebrow { font: var(--weight-medium) var(--text-xs)/var(--leading-snug) var(--sans); text-transform: uppercase; letter-spacing: var(--tracking-caps); color: var(--muted); margin-bottom: var(--space-3); }
strong { overflow-wrap: anywhere; }
.visually-hidden {
  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: var(--space-4); top: -4rem; z-index: 20; padding: var(--space-4) var(--space-8);
  background: var(--bg-raised); color: var(--fg); border: var(--border-width-thick) solid var(--focus); border-radius: var(--radius);
}
.skip:focus { top: var(--space-4); }

header.site { border-bottom: var(--border-width) solid var(--border); }
.bar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: var(--space-4) var(--space-8); min-height: var(--header-h); padding-block: var(--space-4); }
/* The logo lockup, as supplied artwork (BRAND.md section 4); made by ops/design/orb-render. */
.brand { display: inline-flex; align-items: center; }
.brand img { display: block; }
header.site ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-8); }
header.site li { margin: 0; }
header.site nav a { color: var(--fg); text-decoration: none; font-size: var(--text-md); padding: var(--space-3) 0; display: inline-block; }
header.site nav a:hover { text-decoration: underline; }
header.site nav a[aria-current="page"] { font-weight: var(--weight-bold); text-decoration: underline; text-decoration-thickness: var(--underline-width); text-decoration-color: var(--accent); }
footer.site { border-top: var(--border-width) solid var(--border); background: var(--bg-sunk); }
.foot { padding-block: var(--space-10); }
.foot p { margin: 0; }

.card {
  background: var(--bg-raised); border: var(--border-width) solid var(--border);
  border-radius: var(--radius-lg); padding: clamp(var(--space-8), 4vw, var(--space-11)); margin: 0 0 var(--space-10);
}
.card > :last-child { margin-bottom: 0; }
.notice, .error, .warning { border-radius: var(--radius); padding: var(--space-6) var(--space-8); border: var(--border-width) solid; }
.notice { background: var(--accent-soft); border-color: var(--accent); }
.error { border-color: var(--danger); color: var(--danger); background: var(--bg-raised); font-weight: var(--weight-semibold); }
.warning, .warning-card { background: var(--warn-bg); border-color: var(--warn-border); }
.tag { font-size: var(--text-xs); font-weight: var(--weight-medium); padding: var(--space-1) var(--space-4); border-radius: var(--radius-pill); background: var(--accent-soft); color: var(--fg); }

label { display: block; font-weight: var(--weight-semibold); margin: 0 0 var(--space-3); }
input[type=email], input[type=text], input[type=number] {
  width: 100%; font: inherit; color: var(--fg); background: var(--bg);
  padding: var(--space-5) var(--space-6); border: var(--border-width) solid var(--border); border-radius: var(--radius); margin: 0 0 var(--space-8);
}
input:focus-visible { border-color: var(--focus); }
/* iOS zooms focused fields below 16px. 767px is --bp-md (design/tokens.json); media queries cannot read variables. */
@media (max-width: 767px) { input[type=email], input[type=text], input[type=number] { font-size: 16px; } }
input[aria-invalid="true"] { border-color: var(--danger); }
/* Field and meter widths (9rem, 20rem) and the meter's height are layout, not tokens. */
input[type=number] { max-width: 9rem; }
meter { width: 100%; max-width: var(--measure-aside); height: 0.9rem; vertical-align: middle; }
.stack > .btn, .stack > .row { margin-top: var(--space-2); }
.row { display: flex; flex-wrap: wrap; gap: var(--space-6); align-items: center; margin: 0 0 var(--space-8); }
.row form { margin: 0; }
form.inline { display: inline; margin: 0; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-4);
  min-height: var(--control-h); padding: var(--space-5) var(--space-10); font: var(--weight-medium) var(--text-lg)/var(--leading-snug) var(--sans); text-decoration: none;
  color: var(--bg); background: var(--fg);
  border: var(--border-width) solid var(--fg); border-radius: var(--radius); cursor: pointer;
}
.btn:hover { text-decoration: none; opacity: var(--opacity-hover); }
.btn-ghost { color: var(--fg); background: var(--bg-raised); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--border-hover); opacity: 1; }
.btn-small { min-height: var(--control-h-sm); padding: var(--space-3) var(--space-7); font-size: var(--text-md); border-radius: var(--radius-sm); }
.btn-danger { color: var(--danger-fg); background: var(--danger); border-color: var(--danger); }
.btn[disabled], .btn[aria-disabled="true"] { cursor: not-allowed; opacity: var(--opacity-disabled); }
button.link { font: inherit; color: var(--fg); background: none; border: 0; padding: 0; text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: var(--underline-width); text-underline-offset: var(--underline-offset); cursor: pointer; }
button.link:hover { text-decoration-color: var(--fg); }

.links { list-style: none; padding: 0; }
.list { list-style: none; padding: 0; margin: 0 0 var(--space-8); }
.list li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-2) var(--space-8); padding: var(--space-5) 0; border-bottom: var(--border-width) solid var(--border); margin: 0; overflow-wrap: anywhere; }
.list li:last-child { border-bottom: 0; }
.table-wrap { overflow-x: auto; margin: 0 0 var(--space-10); }
table { width: 100%; border-collapse: collapse; background: var(--bg-raised); border: var(--border-width) solid var(--border); border-radius: var(--radius); }
th, td { text-align: left; padding: var(--space-5) var(--space-6); border-bottom: var(--border-width) solid var(--border); vertical-align: top; }
thead th { font-size: var(--text-sm); color: var(--muted); font-weight: var(--weight-semibold); }
tbody th { font-weight: var(--weight-semibold); overflow-wrap: anywhere; }
/* 480px is --bp-sm (design/tokens.json). */
@media (max-width: 480px) {
  thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  table, tbody, tr, th, td { display: block; }
  tr { border-bottom: var(--border-width) solid var(--border); padding: var(--space-4) 0; }
  th, td { border: 0; padding: var(--space-1) var(--space-6); }
  td:nth-of-type(1)::before { content: "Added "; color: var(--muted); }
  td:nth-of-type(2)::before { content: "Last seen "; color: var(--muted); }
}
