:root { --theme-color: #1c1a99; }
body { font-family: 'Arial', sans-serif; background: #f4f4f4; margin: 0; min-height: 100vh; display: flex; flex-direction: column; color: #222; }
#pp-container { max-width: 960px; width: 100%; margin: 40px auto; padding: 20px; box-sizing: border-box; flex: 1; }
#pp-header { text-align: center; font-size: 26px; color: var(--theme-color); margin: 0 0 6px; }
.pp-sub { text-align: center; color: #555; margin: 0 0 24px; }
.pp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.pp-panel { background: #fff; border-radius: 8px; box-shadow: 0 0 10px rgba(0,0,0,.1); padding: 20px; margin-bottom: 20px; }
.section-label { display: block; font-size: 12px; font-weight: bold; color: #666; margin: 0 0 12px; text-transform: uppercase; letter-spacing: .5px; }
.dropzone { display: flex; align-items: center; justify-content: center; text-align: center; min-height: 110px; border: 2px dashed #bbb; border-radius: 8px; cursor: pointer; color: #555; padding: 12px; }
.dropzone.over, .dropzone:focus { border-color: var(--theme-color); outline: none; background: #f0f0ff; }
.dropzone input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.crop-wrap { margin-top: 16px; text-align: center; }
#crop-canvas { touch-action: none; cursor: grab; border: 1px solid #ccc; max-width: 100%; background: #fff; }
#crop-canvas:focus { outline: 2px solid var(--theme-color); }
.crop-tools { display: flex; gap: 6px; align-items: center; justify-content: center; margin-top: 10px; flex-wrap: wrap; }
.crop-tools input[type=range] { flex: 1; min-width: 100px; accent-color: var(--theme-color); }
button { background: #fff; border: 1px solid #ccc; border-radius: 4px; padding: 8px 12px; font-size: 14px; cursor: pointer; }
button:hover:not(:disabled) { border-color: var(--theme-color); color: var(--theme-color); }
button:disabled { opacity: .5; cursor: not-allowed; }
.field { display: flex; flex-direction: column; font-size: 14px; gap: 4px; margin-bottom: 12px; flex: 1; }
.field select, .field input { padding: 8px; border: 1px solid #ccc; border-radius: 4px; font-size: 14px; }
.field-row { display: flex; gap: 12px; }
.check { display: flex; gap: 8px; align-items: center; font-size: 14px; margin-bottom: 8px; }
.hint { font-size: 13px; color: #666; }
.preview-wrap { background: #e8e8e8; padding: 16px; text-align: center; border-radius: 6px; }
#preview-canvas { max-width: 100%; max-height: 520px; box-shadow: 0 2px 8px rgba(0,0,0,.25); background: #fff; }
.download-bar { display: flex; gap: 10px; justify-content: center; margin-top: 16px; flex-wrap: wrap; }
.download-bar button { background: var(--theme-color); color: #fff; border: none; padding: 10px 20px; font-size: 15px; }
.download-bar button:hover:not(:disabled) { color: #fff; filter: brightness(1.15); }
.pp-content { background: #fff; border-radius: 8px; padding: 20px; box-shadow: 0 0 10px rgba(0,0,0,.1); line-height: 1.6; }
.pp-content h2 { color: var(--theme-color); font-size: 20px; }
.pp-content h3 { font-size: 16px; margin-bottom: 4px; }
#toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%); background: #333; color: #fff; padding: 10px 18px; border-radius: 4px; opacity: 0; transition: opacity .3s; pointer-events: none; }
.footer { text-align: center; padding: 16px; font-size: 13px; color: #666; }
.footer a { color: var(--theme-color); }
@media (max-width: 720px) { .pp-grid { grid-template-columns: 1fr; } #pp-container { margin: 16px auto; padding: 12px; } }
[hidden] { display: none !important; }
.table-wrap { overflow-x: auto; }
table.sizes { border-collapse: collapse; width: 100%; font-size: 13px; }
table.sizes caption { text-align: left; font-weight: bold; margin-bottom: 6px; }
table.sizes th, table.sizes td { border: 1px solid #ddd; padding: 6px 8px; text-align: left; white-space: nowrap; }
table.sizes thead th { background: #f4f4f8; }
table.sizes tbody th { font-weight: normal; }
.crumbs { font-size: 13px; margin-bottom: 8px; }
.crumbs a, .related a, .pp-content a { color: var(--theme-color); }
