﻿/* PDF page editor: a grid of page cards (drag to reorder), a text tool and a preview. Compact on purpose. */
.pe { display: grid; gap: 10px; margin-bottom: 12px; }
.pe-bar, .pe-save, .pe-add { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.pe-spacer { flex: 1 1 auto; }
.pe-muted { opacity: .7; font-size: .8rem; }
.pe-btn { height: 30px; padding: 0 12px; border-radius: 7px; border: 1px solid rgba(127, 140, 150, .4); background: transparent; color: inherit; font-size: .82rem; font-weight: 600; cursor: pointer; }
.pe-btn:hover:not(:disabled) { background: rgba(127, 140, 150, .14); }
.pe-btn:disabled { opacity: .45; cursor: default; }
.pe-btn.primary { background: #17a780; border-color: #17a780; color: #fff; }
.pe-btn.primary:hover:not(:disabled) { background: #14936f; }
.pe-btn.danger { color: #e0594a; border-color: rgba(224, 89, 74, .5); }
.pe-btn.small { height: 24px; padding: 0 8px; font-size: .75rem; }
.pe-note { padding: 6px 10px; border-radius: 7px; font-size: .84rem; background: rgba(23, 167, 128, .12); }
.pe-note.error { background: rgba(224, 89, 74, .14); color: #c0392b; }
.pe-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 10px; }
.pe-card { display: grid; gap: 4px; padding: 6px; border: 1px solid rgba(127, 140, 150, .35); border-radius: 9px; cursor: grab; background: rgba(127, 140, 150, .06); }
.pe-card.dragging { opacity: .4; }
.pe-sheet { position: relative; width: 100%; max-height: 150px; margin: 0 auto; display: flex; align-items: center; justify-content: center; overflow: hidden; background: #fff; border: 1px solid rgba(127, 140, 150, .4); border-radius: 3px; }
.pe-sheet-inner { position: relative; width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; transition: transform .15s; }
.pe-sheet-inner b { font-size: 1.6rem; color: #9aa7b0; }
.pe-dot { position: absolute; width: 8px; height: 8px; border-radius: 50%; background: #17a780; }
.pe-from { text-align: center; font-size: .72rem; opacity: .75; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pe-tools { display: flex; justify-content: space-between; gap: 2px; }
.pe-tools button { flex: 1; min-width: 0; height: 26px; padding: 0; border: 1px solid rgba(127, 140, 150, .35); border-radius: 6px; background: transparent; color: inherit; font-size: .9rem; cursor: pointer; }
.pe-tools button:hover:not(:disabled) { background: rgba(127, 140, 150, .18); }
.pe-tools button:disabled { opacity: .3; cursor: default; }
.pe-tools button.danger { color: #e0594a; }
.pe-text summary { cursor: pointer; font-weight: 600; font-size: .86rem; }
.pe-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 8px; margin: 8px 0; }
.pe-form label, .pe-save label { display: grid; gap: 2px; font-size: .74rem; font-weight: 600; }
.pe-form label.wide { flex: 1 1 220px; }
.pe-form input, .pe-form select, .pe-save input, .pe-add select { height: 30px; padding: 0 8px; border-radius: 6px; font-size: .84rem; }
.pe-form input[type=number] { width: 70px; }
.pe-save label { flex: 1 1 240px; }
.pe-stamps { list-style: none; margin: 4px 0; padding: 0; display: grid; gap: 4px; }
.pe-stamps li { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: .82rem; }
.pe-frame { width: 100%; height: 70vh; min-height: 420px; border: 1px solid rgba(127, 140, 150, .4); border-radius: 8px; background: #fff; }
