/* ==========================================================================
   DVS-Mobile public site
   One stylesheet for the landing page, support page, privacy policy and 404.
   Plain CSS, relative paths only — the same bytes have to work on
   https://dvsm-docs.mike-zingman.workers.dev and from file:// during a preview.

   The palette, card and type scale come from the privacy policy, which was the
   first page published. Keeping them here rather than in each page is what
   stops the site looking like separate documents.

   The user guide keeps its own embedded stylesheet: it is a long-form,
   print-friendly document with a table of contents, and it is generated from a
   different tradition. It shares the palette, not the class names.
   ========================================================================== */

:root {
  --bg: #f5f5f7;
  --card: #ffffff;
  --text: #1d1d1f;
  --muted: #6e6e73;
  --accent: #0071e3;
  --accent-ink: #0058b0;
  --ok: #1a7f37;
  --warn: #9a6700;
  --line: #e5e5ea;
  --soft: #f7f7f9;
  --max: 820px;
  --max-wide: 1040px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  padding: 0 16px 56px;
  -webkit-text-size-adjust: 100%;
}
img { max-width: 100%; height: auto; }
.container { max-width: var(--max); margin: 0 auto; }
.wide { max-width: var(--max-wide); margin: 0 auto; }
.card {
  background: var(--card);
  border-radius: 16px;
  padding: 36px 32px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.07);
}
h1 { font-size: 30px; line-height: 1.2; font-weight: 700; margin-bottom: 6px; }
.dates { font-size: 14px; color: var(--muted); margin-bottom: 24px; }
.intro { font-size: 16px; margin-bottom: 24px; }

/* ---- site chrome -------------------------------------------------------- */
.site-header {
  max-width: var(--max-wide);
  margin: 0 auto;
  padding: 18px 4px 14px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 18px;
  justify-content: space-between;
}
.site-header .brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 16px;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.01em;
}
.site-header .brand img { width: 30px; height: 30px; border-radius: 8px; }
.site-header nav { display: flex; flex-wrap: wrap; gap: 4px 18px; }
.site-header nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 14.5px;
  padding: 4px 0;
}
.site-header nav a:hover { color: var(--accent); }
.site-header nav a[aria-current="page"] { color: var(--text); font-weight: 600; }
.site-footer {
  max-width: var(--max-wide);
  margin: 26px auto 0;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  text-align: center;
  font-size: 13px;
  color: var(--muted);
}
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--accent); }
.site-footer p { margin: 6px 0; }

/* ---- landing ------------------------------------------------------------ */
.hero { text-align: center; padding: 34px 20px 30px; }
.hero .hero-icon {
  width: 104px; height: 104px;
  border-radius: 24px;
  box-shadow: 0 10px 28px rgba(0, 113, 227, 0.22);
  margin-bottom: 20px;
}
.hero .kicker {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  font-weight: 700;
  margin-bottom: 8px;
}
.hero h1 { font-size: 40px; letter-spacing: -0.02em; margin-bottom: 12px; }
.hero .lede {
  font-size: 18px;
  color: #3a3a3c;
  max-width: 640px;
  margin: 0 auto 24px;
}
.buttons { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.btn {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  padding: 12px 22px;
  border-radius: 999px;
  transition: background 0.15s ease;
}
.btn:hover { background: var(--accent-ink); }
.btn.secondary {
  background: #fff;
  color: var(--accent);
  border: 1px solid #cfe2fb;
}
.btn.secondary:hover { background: #f2f7ff; }
.hero-note { margin-top: 16px; font-size: 13.5px; color: var(--muted); }

.strip {
  max-width: 720px;
  margin: 8px auto 26px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.strip figure {
  background: var(--card);
  border-radius: 14px;
  padding: 10px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}
.strip img {
  border-radius: 8px;
  display: block;
  width: 100%;
  height: auto;
  /* Reserve the frame before the lazy image arrives. The screenshots are
     1320x2868; without the intrinsic ratio the grid reserves no height and the
     page jumps as they load — which is also how a full-page capture ends up
     with empty cards. */
  aspect-ratio: 9 / 16;
  object-fit: cover;
  background: #000;
}
.strip figcaption {
  font-size: 12.5px;
  color: var(--muted);
  text-align: center;
  padding-top: 8px;
}

.ipad-band {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) minmax(200px, 320px);
  gap: 24px;
  align-items: center;
  background: var(--card);
  border-radius: 16px;
  padding: 26px 28px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
  margin: 26px 0;
}
.ipad-band h2 { font-size: 22px; margin-bottom: 8px; }
.ipad-band p { font-size: 15px; color: #3a3a3c; }
.ipad-band img {
  display: block;
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.14);
}

.section-head { margin: 30px 0 14px; }
.section-head h2 { font-size: 24px; letter-spacing: -0.01em; margin-bottom: 6px; }
.section-head p { color: var(--muted); font-size: 15px; }

.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.feature {
  background: var(--card);
  border-radius: 14px;
  padding: 20px 22px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}
.feature h3 { font-size: 16px; margin-bottom: 6px; }
.feature p { font-size: 14.5px; color: #3a3a3c; }

.steps { counter-reset: step; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.step {
  background: var(--card);
  border-radius: 14px;
  padding: 18px 20px 20px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}
.step::before {
  counter-increment: step;
  content: counter(step);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px; height: 26px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 8px;
}
.step h3 { font-size: 15.5px; margin-bottom: 4px; }
.step p { font-size: 14px; color: #3a3a3c; }

.privacy-strip {
  background: #f2f7ff;
  border: 1px solid #d6e6ff;
  border-radius: 16px;
  padding: 22px 24px;
  margin: 26px 0 8px;
}
.privacy-strip h2 { font-size: 18px; margin-bottom: 6px; }
.privacy-strip p { font-size: 14.5px; margin-bottom: 10px; }
.privacy-strip a { color: var(--accent); font-weight: 600; text-decoration: none; }
.privacy-strip a:hover { text-decoration: underline; }

.licence-note {
  margin: 18px 0 0;
  padding: 16px 18px;
  border-left: 3px solid #c7c7cc;
  color: var(--muted);
  font-size: 14px;
}

/* ---- support ------------------------------------------------------------ */
.contact-card {
  background: #f2f7ff;
  border: 1px solid #d6e6ff;
  border-radius: 14px;
  padding: 20px 22px;
  margin: 18px 0 26px;
}
.contact-card h2 { font-size: 18px; margin-bottom: 8px; }
.contact-card p { font-size: 15px; margin-bottom: 8px; }
.contact-card a { color: var(--accent); font-weight: 600; }
.contact-card ul { margin: 8px 0 0; padding-left: 22px; font-size: 14.5px; }
.contact-card li { margin: 4px 0; }

.faq { margin: 8px 0 20px; }
.faq details {
  background: var(--card);
  border-radius: 12px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.05);
  margin-bottom: 10px;
  padding: 14px 18px;
}
.faq summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 15.5px;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: " +"; color: var(--accent); font-weight: 700; }
.faq details[open] summary::after { content: " –"; }
.faq .answer { font-size: 14.5px; color: #3a3a3c; padding-top: 8px; }
.faq .answer p { margin-bottom: 8px; }
.faq .answer ul { margin: 6px 0 8px; padding-left: 22px; }
.faq .answer a { color: var(--accent); }

/* ---- long-form pages (policy) ------------------------------------------- */
.summary {
  background: #f2f7ff;
  border: 1px solid #d6e6ff;
  border-radius: 12px;
  padding: 18px 20px;
  margin: 0 0 28px;
}
.summary h2 { font-size: 17px; margin-bottom: 10px; }
.summary ul { margin: 0; padding-left: 20px; }
.summary li { font-size: 14.5px; margin: 5px 0; }

nav.toc {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px 20px;
  margin: 0 0 28px;
  background: #fcfcfd;
}
nav.toc h2 {
  font-size: 15px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin-bottom: 8px;
}
nav.toc ol { margin: 0; padding-left: 22px; }
nav.toc li { font-size: 14.5px; margin: 4px 0; }
nav.toc a { color: var(--accent); text-decoration: none; }
nav.toc a:hover { text-decoration: underline; }

section { margin-bottom: 30px; }
h2.section-title {
  display: flex;
  gap: 10px;
  font-size: 19px;
  line-height: 1.3;
  margin-bottom: 10px;
  scroll-margin-top: 20px;
}
.num { color: var(--accent); font-weight: 700; min-width: 24px; }
.section-content { font-size: 15.5px; }
.section-content p { margin: 0 0 12px; }
.section-content ul, .section-content ol { margin: 0 0 12px; padding-left: 24px; }
.section-content li { margin: 6px 0; }
h3 { font-size: 16px; margin: 18px 0 8px; }
strong { font-weight: 600; }
a { color: var(--accent); }
code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 1px 5px;
  overflow-wrap: anywhere;
}

.callout {
  background: #fff8e6;
  border: 1px solid #f0d894;
  border-radius: 10px;
  padding: 14px 16px;
  margin: 14px 0;
  font-size: 15px;
}
.callout strong { color: var(--warn); }
.callout.info { background: #f2f7ff; border-color: #d6e6ff; }
.callout.info strong { color: var(--accent-ink); }

.table-wrap { overflow-x: auto; margin: 12px 0 18px; }
table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
th, td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--line); }
th { background: var(--soft); font-weight: 600; }
tr:last-child td { border-bottom: none; }

.contact {
  margin-top: 12px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: 15.5px;
}

/* ---- 404 ---------------------------------------------------------------- */
.notfound { text-align: center; padding: 48px 24px 40px; }
.notfound .code { font-size: 64px; font-weight: 700; color: var(--accent); line-height: 1; }
.notfound h1 { margin: 10px 0 8px; }
.notfound p { color: var(--muted); margin-bottom: 20px; }
.notfound .links { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }

/* ---- responsive / print ------------------------------------------------- */
@media (max-width: 720px) {
  .ipad-band { grid-template-columns: 1fr; }
  .ipad-band img { max-width: 320px; margin: 0 auto; }
}
@media (max-width: 640px) {
  body { padding: 0 10px 40px; }
  .site-header { padding: 14px 2px 10px; }
  .card { padding: 24px 18px; border-radius: 12px; }
  h1 { font-size: 25px; }
  .hero { padding: 22px 6px 24px; }
  .hero h1 { font-size: 31px; }
  .hero .lede { font-size: 16.5px; }
  .hero .hero-icon { width: 84px; height: 84px; border-radius: 20px; }
  h2.section-title { font-size: 17.5px; }
  .section-content { font-size: 15px; }
}
@media print {
  body { background: #fff; padding: 0; }
  .card { box-shadow: none; padding: 0; }
  nav.toc, .site-header, .site-footer { display: none; }
  a { color: inherit; text-decoration: none; }
}

/* ---- release notes ------------------------------------------------------ */
.release-list { margin-top: 8px; }
.release { padding: 18px 0; border-top: 1px solid var(--line); }
.release:first-child { border-top: 0; }
.release h2 { font-size: 16px; letter-spacing: -0.01em; margin-bottom: 4px; }
.release p { color: var(--muted); font-size: 15px; }
