.cpi-page { max-width: 1120px; padding: 24px; margin: 0 auto 60px; color: #e6edf3; line-height: 1.7; }
.cpi-page * { box-sizing: border-box; }
.cpi-page [hidden] { display: none !important; }
.cpi-hero { padding: 30px; border: 1px solid #344154; border-radius: 18px; background: linear-gradient(130deg,#192b43,#151a23); margin-bottom: 24px; }
.cpi-hero h1 { font-size: clamp(1.9rem,4vw,3rem); line-height: 1.2; color: #fff; margin: 12px 0; overflow-wrap: anywhere; }
.cpi-badge { color: #b8d4ff; font-weight: 700; }
.cpi-workspace,.cpi-result { background: #161e29; border: 1px solid #344154; border-radius: 16px; padding: 28px; margin-bottom: 28px; min-width: 0; }
.cpi-drop { border: 2px dashed #6585ae; border-radius: 12px; padding: 28px; text-align: center; }
.cpi-drop.is-over { border-color: #fff; background: #263c56; }
.cpi-page .btn { display: inline-block; padding: 12px 20px; border: 1px solid transparent; border-radius: 10px; background: #c6252d; color: #fff; font: inherit; font-weight: 700; cursor: pointer; text-decoration: none; }
.cpi-page .btn-secondary { background: #293c54; border-color: #526d8c; }
.cpi-page button:disabled { opacity: .45; cursor: not-allowed; }
.cpi-page :is(button,select,input,a,summary):focus-visible { outline: 3px solid #a8ceff; outline-offset: 3px; }
.cpi-page a { color: #b2d1ff; text-underline-offset: 3px; }
.cpi-settings { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 20px; margin-top: 22px; }
.cpi-settings label { display: grid; gap: 8px; font-weight: 600; }
.cpi-settings :is(input,select) { width: 100%; min-width: 0; padding: 12px; background: #0f1724; border: 1px solid #597293; border-radius: 8px; color: #fff; font: inherit; }
.cpi-hint,.cpi-limits { color: #bac8dc; font-size: .93rem; }
.cpi-error { padding: 16px; background: #421e27; border: 1px solid #ee929b; border-radius: 10px; }
.cpi-actions,.cpi-preview-controls,.cpi-related { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.cpi-actions { margin-top: 24px; }
body[data-tool-page="true"] .cpi-page .cpi-related a { color: #b2d1ff; padding: 10px 12px; border: 1px solid #455e7e; border-radius: 8px; }
.cpi-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 14px; padding: 0; list-style: none; }
.cpi-card { min-width: 0; border: 1px solid #455e7e; border-radius: 10px; padding: 12px; background: #1b293a; }
.cpi-thumb { height: 180px; display: flex; align-items: center; justify-content: center; overflow: hidden; background: #0c121b; border-radius: 6px; }
.cpi-thumb img { max-width: 100%; max-height: 100%; object-fit: contain; }
.cpi-card p { font-size: .85rem; overflow-wrap: anywhere; margin: 8px 0; }
.cpi-page-tools { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 4px; }
.cpi-page-tools button,.cpi-preview-controls button { min-height: 44px; padding: 8px; border-radius: 6px; border: 1px solid #607fa6; background: #243c59; color: #fff; font: inherit; cursor: pointer; }
.cpi-busy { display: flex; align-items: center; gap: 14px; padding: 16px; background: #203854; border-radius: 10px; }
.cpi-spinner { width: 28px; height: 28px; flex-shrink: 0; border: 3px solid #6a85a8; border-top-color: #fff; border-radius: 50%; animation: cpi-spin .8s linear infinite; }
@keyframes cpi-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .cpi-spinner { animation: none; border-top-color: #c6252d; } }
#combinePreview { display: block; max-width: 100%; height: auto; margin: 20px auto; background: #fff; }
#combineResultName { overflow-wrap: anywhere; }
.cpi-preview-controls { justify-content: center; }
.cpi-content { max-width: 850px; margin: 40px auto; }
.cpi-content h2 { margin-top: 32px; color: #fff; }
.cpi-content li { padding-bottom: 12px; }
.cpi-content details { padding: 18px 0; border-bottom: 1px solid #344154; }
.cpi-content summary { cursor: pointer; font-weight: 600; }
@media(max-width:900px) { .cpi-grid { grid-template-columns: repeat(3,minmax(0,1fr)); } .cpi-page-tools { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media(max-width:600px) { .cpi-page { padding: 16px; } .cpi-hero,.cpi-workspace,.cpi-result { padding: 20px; } .cpi-drop { padding: 18px 12px; } .cpi-settings { grid-template-columns: minmax(0,1fr); } .cpi-grid { grid-template-columns: repeat(2,minmax(0,1fr)); } .cpi-thumb { height: 140px; } .cpi-page-tools button { padding: 4px; } .cpi-actions .btn { width: 100%; text-align: center; } }

#combinePagesTitle { scroll-margin-top: 180px; }
