:root { --acc: #c8102e; --accd: #a50d26; --accbg: #fdeef0 }
.hint { font-size: 13px; color: var(--tx2); margin-top: -4px }
.pages { display: flex; flex-wrap: wrap; gap: 24px 0; padding-top: 8px; align-content: flex-start; user-select: none; padding-bottom: 40px }
.pg { width: 168px; position: relative; cursor: pointer; padding: 6px 8px 0; margin: 0 4px }
.pg .th { height: 196px; background: var(--panel); border: 1px solid var(--line); display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden }
.pg .th canvas, .pg .th img { max-width: 100%; max-height: 100%; display: block; box-shadow: 0 0 0 1px #e5e7eb }
.pg .th .ld { width: 70%; height: 80%; background: #f3f4f6 }
.pg .cap { display: flex; align-items: center; gap: 6px; padding: 6px 2px 0; font-size: 12px; color: var(--tx2) }
.pg .cap i { width: 10px; height: 10px; flex: none } .pg .cap span { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis }
.pg .cap b { font-family: var(--mono); color: var(--tx); font-weight: 600 }
.pg .tools { position: absolute; top: 12px; right: 14px; display: none; gap: 4px }
.pg:hover .tools { display: flex }
.pg .tools button { width: 28px; height: 28px; border: 0; background: var(--ink); color: #fff; cursor: pointer; font-size: 14px; line-height: 1 }
.pg .tools button:hover { background: var(--acc) }
.pg.sel .th { outline: 3px solid var(--acc); outline-offset: -1px }
.pg.sel::after { content: '\2713'; position: absolute; top: 12px; left: 14px; width: 24px; height: 24px; background: var(--acc); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 13px }
.pg.drag { opacity: .3 }
.pg .rot { position: absolute; bottom: 8px; left: 8px; background: rgba(20,22,26,.8); color: #fff; font: 600 11px var(--mono); padding: 2px 6px }
.ins { width: 4px; margin: 6px -2px 0; background: var(--acc); align-self: stretch; height: 222px; flex: none }
.gap { width: 22px; height: 196px; margin-top: 6px; position: relative; flex: none; display: flex; align-items: center; justify-content: center; cursor: pointer; margin-left: -4px; margin-right: -4px; z-index: 2 }
.gap::before { content: ''; position: absolute; top: 8px; bottom: 8px; left: 50%; border-left: 2px dashed transparent }
.gap b { width: 22px; height: 22px; display: grid; place-items: center; background: var(--panel); border: 1px solid var(--line); font-size: 13px; color: var(--tx3); opacity: 0; z-index: 1 }
.gap:hover b { opacity: 1; color: var(--acc); border-color: var(--acc) }
.gap.cut::before { border-left-color: var(--acc) } .gap.cut b { opacity: 1; background: var(--acc); color: #fff; border-color: var(--acc) }
.pg.part0 .cap i { outline: 0 }
.partlab { position: absolute; top: -14px; left: 8px; font-size: 10.5px; font-weight: 700; color: var(--acc); letter-spacing: .04em; text-transform: uppercase }
.dragghost { position: fixed; pointer-events: none; z-index: 70; width: 120px; height: 150px; background: var(--panel); border: 2px solid var(--acc); box-shadow: 0 10px 30px rgba(0,0,0,.18); display: grid; place-items: center; font-weight: 800; color: var(--acc) }
.dragghost canvas { max-width: 100%; max-height: 100%; opacity: .8 }
.dragghost em { position: absolute; top: -10px; right: -10px; background: var(--acc); color: #fff; font-style: normal; font-size: 12px; padding: 2px 7px }
.flist .f { cursor: default } .flist .f i { width: 12px; height: 40px; flex: none }
.flist .f .mv { display: flex; flex-direction: column } .flist .f .mv button { border: 0; background: none; cursor: pointer; color: var(--tx3); height: 18px; padding: 0 4px; font-size: 11px } .flist .f .mv button:hover { color: var(--tx) } .flist .f .mv button:disabled { opacity: .25; cursor: default }
.modes { display: flex; flex-direction: column; border: 1px solid var(--line) }
.modes label { display: grid; grid-template-columns: 22px 1fr; padding: 10px 12px; border-bottom: 1px solid var(--line2); cursor: pointer; align-items: start; column-gap: 8px }
.modes label:last-child { border-bottom: 0 }
.modes label > input[type=radio] { margin: 3px 0 0; accent-color: var(--acc); width: 16px; height: 16px; grid-row: span 2 }
.modes label b { font-size: 14px; display: flex; align-items: center; gap: 6px } .modes label span { font-size: 12px; color: var(--tx2); display: block }
.modes label:has(input[type=radio]:checked) { background: var(--accbg); box-shadow: inset 3px 0 0 var(--acc) }
.done .dl { display: flex; flex-direction: column; gap: 6px; max-height: 260px; overflow: auto }
.done .dl a { display: flex; justify-content: space-between; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); text-decoration: none; color: var(--tx); font-size: 13px }
.done .dl a:hover { border-color: var(--acc) } .done .dl a span { font-family: var(--mono); color: var(--tx2); flex: none }
.done .ok { font-weight: 800; font-size: 18px } .done .tip { font-size: 12.5px; color: var(--tx2) } .done .tip a { color: var(--accd); font-weight: 600 }
