﻿.pdf-page{
  display:grid;
  gap:16px;
}

.pdf-hero{
  border:1px solid var(--border);
  border-radius:16px;
  background:linear-gradient(130deg, rgba(11,95,255,.10), rgba(11,95,255,.04) 36%, transparent 70%), var(--surface);
  box-shadow:var(--shadow2);
  padding:18px;
}

.pdf-hero h1{ margin:0; font-size:clamp(28px,3.2vw,40px); }
.pdf-hero p{ margin:8px 0 0; color:var(--muted); max-width:74ch; }

.pdf-status{
  border:1px solid var(--border);
  border-radius:12px;
  background:var(--surface);
  color:var(--muted);
  padding:10px 12px;
  font-size:13px;
}

.pdf-status.error{
  border-color: rgba(185, 28, 28, 0.3);
  color:#b91c1c;
  background: rgba(185, 28, 28, 0.06);
}

.pdf-mode-panel{
  display:grid;
  gap:14px;
}

.pdf-controls-card{
  border:1px solid var(--border);
  border-radius:14px;
  background:var(--surface);
  box-shadow:var(--shadow2);
  padding:12px;
  display:grid;
  gap:12px;
}

.pdf-dropzone{
  border:1px dashed var(--border);
  border-radius:12px;
  background:var(--surface2);
  padding:14px;
}

.pdf-dropzone.is-over{
  border-color:rgba(11,95,255,.5);
  background:rgba(11,95,255,.08);
}

.pdf-dropzone p{
  margin:0;
  color:var(--muted);
}

.pdf-stat-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:8px;
}

.pdf-stat-item{
  border:1px solid var(--border);
  border-radius:10px;
  background:var(--surface2);
  padding:10px;
  display:grid;
  gap:4px;
}

.pdf-stat-item span{
  color:var(--muted);
  font-size:12px;
}

.pdf-stat-item strong{
  font-size:15px;
}

.pdf-control-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:8px 12px;
  align-items:center;
}

.pdf-control-grid label{
  font-size:13px;
  color:var(--muted);
  font-weight:700;
}

.pdf-control-grid select,
.pdf-control-grid input[type="range"]{
  width:100%;
}

.pdf-control-grid select{
  border:1px solid var(--border);
  border-radius:9px;
  background:var(--surface2);
  color:var(--text);
  padding:8px;
  font:inherit;
}

.pdf-range-row{
  display:flex;
  align-items:center;
  gap:8px;
}

.pdf-range-row span{
  min-width:50px;
  font-size:12px;
  color:var(--muted);
}

.pdf-switch-control{
  display:flex;
  align-items:center;
  gap:8px;
  font-weight:600;
}

.pdf-switch-control input{
  width:16px;
  height:16px;
}

.pdf-simple-controls{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  align-items:center;
}

.pdf-note{
  margin:0;
  color:var(--muted);
  font-size:12px;
}

.pdf-hint{
  margin:0;
  font-size:12px;
  color:var(--muted);
}

.pdf-preview-grid{
  display:grid;
  gap:12px;
  grid-template-columns:1fr 1fr;
}

.pdf-preview-card{
  border:1px solid var(--border);
  border-radius:14px;
  background:var(--surface);
  box-shadow:var(--shadow2);
  display:grid;
  grid-template-rows:auto 1fr auto;
  min-height:380px;
}

.pdf-preview-top{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:8px;
  padding:10px;
  border-bottom:1px solid var(--border);
}

.pdf-meta-text{ color:var(--muted); font-size:12px; margin-top:2px; }

.pdf-canvas-wrap{
  min-height:270px;
  padding:10px;
  background:var(--surface2);
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:auto;
}

.pdf-canvas-wrap canvas{
  max-width:100%;
  height:auto;
  border:1px solid var(--border);
  background:#fff;
}

.pdf-nav{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  padding:10px;
  border-top:1px solid var(--border);
}

.pdf-nav span{ font-size:12px; color:var(--muted); min-width:82px; text-align:center; }

@media (max-width: 980px){
  .pdf-preview-grid{ grid-template-columns:1fr; }
}

@media (max-width: 760px){
  .pdf-stat-grid,
  .pdf-control-grid{ grid-template-columns:1fr; }
}
