/* =============================================================================
   pds.css — one stylesheet, both front ends
   No framework and no build step: this is a small site whose whole job is to
   be legible and to not get in the way of a download.
   ========================================================================== */

:root {
  --bg: #fbfbfc;
  --surface: #ffffff;
  --border: #e3e3e7;
  --text: #17171a;
  --muted: #65656d;
  --accent: #1a5fb4;
  --accent-text: #ffffff;
  --warn-bg: #fff8e6;
  --warn-border: #e5c76b;
  --danger: #a51d2d;
  --ok: #1a7f4b;
  --radius: 8px;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #131316;
    --surface: #1c1c20;
    --border: #2e2e34;
    --text: #ececf0;
    --muted: #a0a0aa;
    --accent: #6ba3e8;
    --accent-text: #0d1117;
    --warn-bg: #2b2413;
    --warn-border: #6b5a2b;
    --danger: #f08c8c;
    --ok: #63c68f;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font: 15px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

header.top {
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  padding: 14px 16px;
}
header.top .inner {
  max-width: 940px; margin: 0 auto;
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
}
.brand { font-weight: 650; letter-spacing: -0.01em; }
.brand small { color: var(--muted); font-weight: 400; margin-left: 8px; }
.spacer { flex: 1 1 auto; }

main { max-width: 940px; margin: 0 auto; padding: 24px 16px 64px; }

h1 { font-size: 22px; margin: 0 0 6px; letter-spacing: -0.015em; }
h2 { font-size: 16px; margin: 28px 0 10px; }
p.lead { color: var(--muted); margin: 0 0 22px; }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 14px;
}
.card h3 { margin: 0 0 4px; font-size: 15px; }
.card .meta { color: var(--muted); font-size: 13px; }

button, .btn {
  font: inherit; font-weight: 550;
  background: var(--accent); color: var(--accent-text);
  border: 1px solid transparent; border-radius: 6px;
  padding: 9px 16px; cursor: pointer; text-decoration: none;
  display: inline-block;
}
button:hover, .btn:hover { filter: brightness(1.08); }
button:disabled { opacity: 0.45; cursor: not-allowed; filter: none; }
button.secondary, .btn.secondary {
  background: transparent; color: var(--text); border-color: var(--border);
}
button.danger { background: transparent; color: var(--danger); border-color: var(--border); }

input[type="text"], input[type="email"], input[type="number"], textarea, select {
  font: inherit; width: 100%;
  background: var(--bg); color: var(--text);
  border: 1px solid var(--border); border-radius: 6px; padding: 9px 11px;
}
label { display: block; font-weight: 550; margin: 14px 0 5px; font-size: 14px; }
label .hint { font-weight: 400; color: var(--muted); }

table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--border); }
th { color: var(--muted); font-weight: 550; font-size: 13px; }

ul.crumbs { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 0 0 12px; font-size: 14px; }
ul.crumbs li::after { content: "/"; color: var(--muted); margin-left: 6px; }
ul.crumbs li:last-child::after { content: ""; }
ul.crumbs a { color: var(--accent); text-decoration: none; cursor: pointer; }

.rows { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.row { display: flex; align-items: center; gap: 11px; padding: 10px 13px; border-bottom: 1px solid var(--border); }
.row:last-child { border-bottom: none; }
.row .name { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
.row .size { color: var(--muted); font-size: 13px; white-space: nowrap; }
.row.dir .name { cursor: pointer; color: var(--accent); }
.row input[type="checkbox"] { width: 17px; height: 17px; flex: none; }

.notice {
  border: 1px solid var(--warn-border); background: var(--warn-bg);
  border-radius: var(--radius); padding: 12px 14px; margin: 14px 0; font-size: 14px;
}
.notice.error { border-color: var(--danger); background: transparent; color: var(--danger); }
.notice.ok { border-color: var(--ok); background: transparent; color: var(--ok); }

.pill { font-size: 12px; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--border); color: var(--muted); }
.pill.live { color: var(--ok); border-color: var(--ok); }
.pill.revoked, .pill.expired { color: var(--muted); }

.empty { text-align: center; color: var(--muted); padding: 40px 16px; }
.mono { font-family: var(--mono); font-size: 13px; }
footer.foot { max-width: 940px; margin: 0 auto; padding: 0 16px 40px; color: var(--muted); font-size: 13px; }

@media (max-width: 560px) {
  main { padding: 18px 16px 56px; }
  .row { flex-wrap: wrap; }
}

/* ---------------------------------------------------------------------------
   Utility classes, and why they exist rather than inline style attributes.

   The site's Content-Security-Policy sets `style-src 'self'`, which forbids
   inline style attributes exactly as `script-src 'self'` forbids inline
   scripts. Seventeen `style="..."` attributes were being silently dropped.

   The easy fix was to add 'unsafe-inline' to style-src. That turns a control
   into decoration, on a site whose entire job is handing out files, to save
   replacing fourteen declarations. These are the fourteen.
   --------------------------------------------------------------------------- */
.mt-6   { margin-top: 6px; }
.mt-10  { margin-top: 10px; }
.mt-12  { margin-top: 12px; }
.mt-20  { margin-top: 20px; }
.mt-22  { margin-top: 22px; }
.mt-28  { margin-top: 28px; }
.ml-10  { margin-left: 10px; }
.ml-12  { margin-left: 12px; }
.m-0    { margin: 0; }
.mb-10  { margin: 0 0 10px; }
.mt-12-flush { margin: 12px 0 0; }
.inline { display: inline; }
.t-danger { color: var(--danger); }
.t-ok     { color: var(--ok); }
