/*
  Ampere Alarm's legal pages, in Ampere Alarm's own look (see /ampere-alarm/index.html): the icon's
  violet-black plate, lavender-white ink, Saira for display and Instrument Sans for reading.
  As on the app's page, the cyan-indigo-magenta gradient only ever shows a level: here the title band's
  faint gauge, filled to 80%, and the small level ticks of the lists.
*/
:root {
  --plate: #0e0b1c;
  --plate-2: #120e24;
  --face: #17132d;
  --face-2: #1e1a3a;
  --line: rgba(214, 218, 255, .11);
  --line-2: rgba(214, 218, 255, .22);
  --ink: #eef0ff;
  --read: #d3d5ef;
  --ink-2: #b0b2d4;
  --ink-3: #9a9cc6;
  --cyan: #5fd0ff;
  --indigo: #6a73f2;
  --magenta: #e65fd6;
  --charge: linear-gradient(90deg, #5fd0ff, #6a73f2 55%, #e65fd6);
  --display: "Saira", "Arial Narrow", sans-serif;
  --body: "Instrument Sans", "Helvetica Neue", Arial, sans-serif;
  --col: 42rem;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--plate); color: var(--read);
  font: 400 17px/1.72 var(--body);
  -webkit-font-smoothing: antialiased;
}
::selection { background: var(--indigo); color: #fff; }
a { color: var(--cyan); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; border-radius: 6px; }
.wrap { width: min(var(--col), 100% - 48px); margin-inline: auto; }

/* ---------- Title band ---------- */
.band { position: relative; overflow: hidden; border-bottom: 1px solid var(--line-2); background: var(--plate); }
.top {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 22px 0;
  width: min(1200px, 100% - 56px); margin-inline: auto; position: relative; z-index: 2;
}
.app { display: flex; align-items: center; gap: 12px; text-decoration: none; white-space: nowrap; color: var(--ink); font-family: var(--display); font-stretch: 112.5%; font-weight: 600; font-size: 1.05rem; letter-spacing: .01em; }
.app img { width: 38px; height: 38px; border-radius: 10px; box-shadow: 0 0 0 1px var(--line-2); }
.top-r { display: flex; align-items: center; gap: 18px; }
.play-mini {
  display: inline-flex; align-items: center; gap: 8px; text-decoration: none; white-space: nowrap;
  font-family: var(--display); font-weight: 600; font-size: .9rem; line-height: 1.3;
  padding: 8px 14px; border-radius: 10px; border: 1px solid var(--line-2); color: var(--ink);
}
.play-mini svg { width: 15px; height: 15px; }
.play-mini:hover { background: rgba(238, 240, 255, .06); color: var(--ink); }
.by { font-size: .88rem; color: var(--ink-3); text-decoration: none; white-space: nowrap; }
.by:hover { color: var(--ink); }

.hero { position: relative; z-index: 1; padding: 44px 0 60px; }
.eyebrow {
  margin: 0 0 16px; font-family: var(--display); font-stretch: 112.5%; font-weight: 500;
  font-size: .86rem; letter-spacing: .02em; line-height: 1.3; color: var(--ink-2);
}
h1 {
  margin: 0 0 32px; font-family: var(--display); font-stretch: 87.5%; font-weight: 700; color: var(--ink);
  font-size: clamp(2.7rem, 5.6vw, 4.6rem); line-height: .94; letter-spacing: -.01em; text-wrap: balance;
}
/* The meta lines as the app page's spec sheet: label on the left, value on the right. */
.meta { display: grid; max-width: 36em; border-bottom: 1px solid var(--line); }
.meta span { display: block; padding: 11px 0 11px 8.6rem; text-indent: -8.6rem; border-top: 1px solid var(--line); font-size: .97rem; line-height: 1.5; color: var(--ink-2); }
.meta b { display: inline-block; width: 8.6rem; text-indent: 0; font-family: var(--display); font-stretch: 112.5%; font-weight: 500; font-size: .8rem; letter-spacing: .02em; color: var(--ink); }
.meta code { font-family: var(--display); font-stretch: 87.5%; font-size: 1em; background: none; padding: 0; color: var(--ink); }

/* The gauge from the app's hero, faint, at the band's edge: ticks round 270°, and the level at 80%. */
.gauge {
  position: absolute; z-index: 0; top: 96px; right: calc(50% - 840px); width: 480px; aspect-ratio: 1; pointer-events: none;
}
.gauge::before {
  content: ""; position: absolute; inset: 18%; border-radius: 50%;
  background: radial-gradient(circle, rgba(106, 115, 242, .26), rgba(106, 115, 242, 0) 68%); filter: blur(10px);
}
.gauge::after, .gauge i { content: ""; position: absolute; inset: 0; border-radius: 50%; }
.gauge::after {
  background: repeating-conic-gradient(from -135deg, rgba(214, 218, 255, .22) 0 .5deg, transparent .5deg 6.75deg);
  -webkit-mask: radial-gradient(closest-side, transparent 85%, #000 85.5% 92%, transparent 92.5%), conic-gradient(from -135deg, #000 270.5deg, transparent 0);
  -webkit-mask-composite: source-in;
  mask: radial-gradient(closest-side, transparent 85%, #000 85.5% 92%, transparent 92.5%) intersect, conic-gradient(from -135deg, #000 270.5deg, transparent 0);
}
.gauge i {
  inset: 3%;
  background: conic-gradient(from -135deg, #5fd0ff, #6a73f2 120deg, #e65fd6 216deg, transparent 216deg);
  -webkit-mask: radial-gradient(closest-side, transparent 95%, #000 95.5%);
  mask: radial-gradient(closest-side, transparent 95%, #000 95.5%);
  opacity: .42;
}

/* ---------- Contents ---------- */
.toc { margin: 52px auto 8px; padding: 24px 28px 20px; background: var(--face); border: 1px solid var(--line); border-radius: 20px; }
.toc h2 { margin: 0 0 12px; font-family: var(--display); font-stretch: 112.5%; font-weight: 500; font-size: .86rem; letter-spacing: .02em; color: var(--ink-2); }
.toc ol { margin: 0; padding-left: 1.7em; columns: 2; column-gap: 32px; }
.toc li { margin: 0 0 6px; break-inside: avoid; font-size: .97rem; line-height: 1.45; }
.toc li::marker { font-family: var(--display); font-stretch: 87.5%; font-weight: 500; color: var(--ink-3); }
.toc a { color: var(--ink); text-decoration: none; }
.toc a:hover { color: var(--cyan); text-decoration: underline; }

/* ---------- The document ---------- */
main { padding: 16px 0 96px; }
section { padding: 40px 0 12px; border-top: 1px solid var(--line); scroll-margin-top: 16px; }
section:first-of-type { border-top: 0; }
h2.sec {
  margin: 0 0 18px; font-family: var(--display); font-stretch: 87.5%; font-weight: 700; color: var(--ink);
  font-size: clamp(1.75rem, 2.8vw, 2.1rem); line-height: 1.08; letter-spacing: -.005em; text-wrap: balance;
}
h3 { margin: 28px 0 8px; font-family: var(--display); font-weight: 600; font-size: 1.2rem; line-height: 1.25; color: var(--ink); }
p { margin: 0 0 18px; }
p, li, td { text-wrap: pretty; }
ul, ol { margin: 0 0 18px; padding-left: 1.3em; }
li { margin: 0 0 10px; }
/* the app page's level tick in front of each bullet */
main ul { list-style: none; padding-left: 0; }
main ul > li { position: relative; padding-left: 26px; }
main ul > li::before { content: ""; position: absolute; left: 0; top: .78em; width: 12px; height: 3px; border-radius: 2px; background: var(--charge); }
strong, b { color: var(--ink); font-weight: 600; }
code {
  font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: .86em; color: var(--ink);
  background: var(--face-2); padding: 1px 6px; border-radius: 5px; overflow-wrap: anywhere;
}

/* Tables scroll inside their own box. */
.table-scroll { overflow-x: auto; margin: 4px 0 24px; border: 1px solid var(--line-2); border-radius: 16px; background: var(--face); -webkit-overflow-scrolling: touch; }
table { width: 100%; border-collapse: collapse; font-size: .95rem; line-height: 1.55; min-width: 560px; }
th, td { text-align: left; vertical-align: top; padding: 13px 16px; border-bottom: 1px solid var(--line); }
tbody tr:last-child td { border-bottom: 0; }
th { font-family: var(--display); font-stretch: 112.5%; font-weight: 500; font-size: .8rem; letter-spacing: .02em; color: var(--ink); background: var(--face-2); border-bottom-color: var(--line-2); }
td { color: var(--read); }
/* wide tables get room to breathe on a phone; their box scrolls */
table:has(th:nth-child(4)) { min-width: 720px; }
td code { overflow-wrap: normal; white-space: nowrap; }

/* Callouts: a face panel, like the app page's alarm cards. */
.callout { margin: 6px 0 24px; padding: 18px 22px; background: var(--face); border: 1px solid var(--line-2); border-radius: 16px; }
.callout p:last-child { margin-bottom: 0; }

/* ---------- Footer, as on Ampere Alarm's page ---------- */
footer { border-top: 1px solid var(--line); padding: 40px 0 56px; color: var(--ink-3); font-size: .9rem; line-height: 1.6; }
footer .wrap { width: min(1200px, 100% - 56px); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 14px 32px; }
footer nav { display: flex; flex-wrap: wrap; gap: 10px 24px; }
footer a { color: var(--ink-2); text-decoration: none; }
footer a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }

@media (max-width: 1180px) {
  .gauge { right: -300px; opacity: .7; }
}
@media (max-width: 900px) {
  .gauge { display: none; }
}
@media (max-width: 760px) {
  .wrap, .top, footer .wrap { width: min(var(--col), 100% - 40px); }
  .toc ol { columns: 1; }
  .hero { padding: 26px 0 44px; }
  h1 { margin-bottom: 26px; }
}
@media (max-width: 480px) {
  body { font-size: 16.5px; }
  .top { gap: 10px; padding: 16px 0; }
  .app { font-size: .9rem; gap: 8px; }
  .app img { width: 30px; height: 30px; border-radius: 8px; }
  .top-r { gap: 10px; }
  .play-mini { padding: 6px 9px; font-size: .78rem; gap: 6px; border-radius: 9px; }
  .play-mini svg { width: 12px; height: 12px; }
  .by { font-size: .78rem; }
  .meta span { padding-left: 0; text-indent: 0; }
  .meta b { display: block; width: auto; margin-bottom: 1px; }
  .toc { padding: 20px 20px 16px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
