.menu-pdf-dialog { width:min(820px,calc(100% - 72px)); height:min(760px,80dvh); max-width:none; max-height:none; margin:auto; padding:0; border:0; border-radius:16px; color:var(--ink); background:#fff; box-shadow:0 24px 100px #0004; overflow:hidden }
.menu-pdf-dialog[open] { display:flex; flex-direction:column }
.menu-pdf-dialog::backdrop { background:#1d191878; -webkit-backdrop-filter:blur(10px); backdrop-filter:blur(10px) }
.pdf-heading { display:flex; align-items:center; justify-content:space-between; gap:20px; padding:14px 24px; flex:none }
.pdf-heading h2 { margin:0; font-size:18px; font-weight:500; letter-spacing:-.025em }
.pdf-close { display:grid; place-items:center; width:40px; height:40px; border:0; padding:0; background:none; color:var(--ink); font:300 32px/1 system-ui }
.pdf-toolbar { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:10px 20px; padding:10px 24px; border-top:1px solid #eeeae6; border-bottom:1px solid #e2ded9; background:#fff; flex:none }
.pdf-zoom-controls,.pdf-page-controls { display:flex; align-items:center; gap:5px }
.pdf-toolbar button { display:grid; place-items:center; min-width:36px; min-height:36px; border:0; border-radius:5px; padding:4px 8px; color:var(--ink); background:#f4f2ef; font-size:20px; line-height:1 }
.pdf-toolbar button:hover:not(:disabled) { background:#eae5df }
.pdf-toolbar button:disabled { opacity:.35; cursor:default }
.pdf-zoom-controls output { width:50px; color:var(--muted); font-size:12px; text-align:center; font-variant-numeric:tabular-nums }
.pdf-toolbar .pdf-fit { padding-inline:11px; margin-left:5px; font-size:11px }
.pdf-download { padding-block:8px; color:var(--copper-dark); font-size:11px; font-weight:500 }
.pdf-page-controls span { min-width:42px; text-align:center; font-size:11px }
.pdf-stage { position:relative; flex:1; min-height:0; min-width:0; overflow:auto; background:#eeece8; overscroll-behavior:contain; touch-action:none }
.pdf-surface { display:flex; width:max-content; min-width:100%; min-height:100%; padding:20px }
.pdf-sheet { position:relative; flex:none; margin:auto; background:white; box-shadow:0 3px 16px #312d2420 }
.pdf-sheet canvas { display:block; width:100%; height:100% }
.pdf-status { position:sticky; top:30px; z-index:1; width:calc(100% - 40px); margin:30px auto; color:#756e65; font-size:13px; text-align:center }
.pdf-status:not([hidden]) + .pdf-surface { min-height:0 }
.pdf-open { overflow:hidden }
@media(max-width:620px) {
  .menu-pdf-dialog { width:calc(100% - 32px); height:min(680px,80dvh); border-radius:14px }
  .pdf-heading { padding:10px 14px }
  .pdf-heading h2 { font-size:15px }
  .pdf-close { width:32px; height:34px; font-size:29px }
  .pdf-toolbar { gap:8px; padding:9px 12px }
  .pdf-toolbar button { min-width:32px; min-height:36px }
  .pdf-toolbar .pdf-fit { padding-inline:8px; font-size:10px; margin-left:2px }
  .pdf-zoom-controls output { width:43px; font-size:11px }
  .pdf-download { font-size:10px }
  .pdf-surface { padding:12px }
}
