:root {
  color-scheme: dark;
  --canvas: #111314;
  --panel: #181818;
  --border: #2b2b2b;
  --text: #cccccc;
  --strong: #e9e9e9;
  --muted: #a0a0a0;
  --blue: #75beff;
  --button: #0e639c;
  --button-hover: #1177bb;
  --hover: #2a2d2e;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--canvas); color: var(--text); }
a { color: inherit; text-decoration: none; }
a:focus-visible, [tabindex]:focus-visible { outline: 2px solid var(--blue); outline-offset: 4px; }
svg { width: 18px; height: 18px; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.sr-only, .skip-link:not(:focus) { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link:focus { position: fixed; inset: 12px auto auto 12px; z-index: 2; padding: 12px; background: var(--panel); color: var(--blue); }
.resume-shell { width: min(1200px, 100%); margin: 0 auto; padding: 16px 12px 12px; }
.resume-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 4px 18px; }
.identity { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: var(--strong); font-size: 14px; font-weight: 600; }
.monogram { display: grid; place-items: center; width: 38px; height: 38px; border: 1px solid #345772; border-radius: 9px; background: #203647; color: var(--blue); font: 15px "SFMono-Regular", Consolas, monospace; }
.identity-detail { display: block; margin-top: 4px; color: var(--muted); font-size: 12px; font-weight: 400; }
.back-link { display: inline-flex; align-items: center; gap: 7px; min-height: 44px; padding: 0 6px; color: var(--muted); font-size: 12px; border-radius: 5px; }
.back-link:hover { color: var(--strong); background: var(--hover); }
.resume-panel { overflow: hidden; border: 1px solid var(--border); border-radius: 10px; background: var(--panel); }
.resume-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; padding: 16px; border-bottom: 1px solid var(--border); }
.document-title { display: flex; align-items: center; gap: 12px; }
.document-title > svg { width: 24px; height: 24px; color: var(--blue); }
h1 { margin: 0; font-size: 20px; line-height: 1.3; font-weight: 600; color: var(--strong); letter-spacing: -.3px; }
.document-title p { margin: 4px 0 0; font-size: 12px; color: var(--muted); }
.document-title p span { padding: 0 4px; }
.document-actions { display: flex; align-items: center; gap: 12px; width: 100%; }
.open-link, .download-link { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 14px; border-radius: 5px; font-size: 13px; font-weight: 500; white-space: nowrap; }
.open-link { border: 1px solid var(--border); }
.open-link:hover { background: var(--hover); color: var(--strong); }
.open-link svg { width: 14px; height: 14px; }
.download-link { background: var(--button); color: #fff; border: 1px solid #1685bd; }
.download-link:hover { background: var(--button-hover); }
.document-actions > a { flex: 1; }
.document-frame { height: calc(100svh - 255px); min-height: 480px; background: #282828; overflow: auto; scrollbar-gutter: stable; }
#pdf-pages { display: grid; justify-items: center; gap: 16px; padding: 16px 12px; }
.pdf-page { position: relative; flex-shrink: 0; background: white; color: black; box-shadow: 0 2px 8px #0004; --scale-round-x: 1px; --scale-round-y: 1px; }
.pdf-page canvas { display: block; }
.viewer-status { padding: 36px 20px; margin: 0; text-align: center; font-size: 14px; line-height: 1.7; color: var(--text); }
.viewer-status[hidden] { display: none; }
.pdf-fallback { display: flex; align-items: center; justify-content: center; flex-direction: column; min-height: 400px; padding: 28px; text-align: center; }
.pdf-fallback h2 { margin: 0 0 12px; color: var(--strong); font-size: 22px; }
.pdf-fallback p { max-width: 32ch; margin: 0 0 24px; line-height: 1.6; color: var(--muted); }
@media (min-width: 640px) {
  .resume-shell { padding: 24px 24px 20px; }
  .resume-header { margin-bottom: 22px; }
  .identity { font-size: 15px; }
  .back-link { font-size: 13px; }
  .resume-toolbar { padding: 18px 22px; }
  .document-actions { width: auto; }
  .document-actions > a { flex: initial; }
  .document-frame { height: calc(100svh - 197px); min-height: 560px; }
}
