/* ===== Emsal Kontrol Paneli ===== */
.cp-panel{margin:14px 0 6px;padding:22px 24px;border:1px solid var(--line);border-radius:24px;background:linear-gradient(135deg,#fbfdfc 0%,#f1f7f4 100%);box-shadow:0 10px 30px rgba(16,43,37,.06)}
.cp-head{display:flex;justify-content:space-between;align-items:flex-start;gap:18px;flex-wrap:wrap}
.cp-eyebrow{font-size:11px;letter-spacing:.2em;font-weight:900;color:var(--gold);margin:0 0 6px}
.cp-head h3{margin:0;font-size:21px;letter-spacing:-.02em;color:var(--ink)}
.cp-sub{margin:6px 0 0;font-size:13px;color:#6b7f79;max-width:620px;line-height:1.5}
.cp-actions{display:flex;gap:10px;flex-wrap:wrap}
.cp-actions button{padding:13px 18px;font-size:13px}
.cp-actions .ghost b{display:inline-grid;place-items:center;min-width:22px;height:22px;padding:0 6px;margin-left:6px;border-radius:99px;background:var(--green);color:#fff;font-size:11px}
.cp-stats{display:grid;grid-template-columns:repeat(5,1fr);gap:10px;margin-top:18px}
.cp-stats>div{background:#fff;border:1px solid var(--line);border-radius:16px;padding:14px 16px}
.cp-stats b{display:block;font-size:22px;font-weight:900;color:var(--ink);letter-spacing:-.02em;line-height:1.1}
.cp-stats b small{font-size:13px;color:#93a39e;font-weight:800}
.cp-stats span{display:block;margin-top:5px;font-size:11px;letter-spacing:.06em;font-weight:800;color:#7a8b86;text-transform:uppercase}
.cp-dist{margin-top:16px;padding:18px 16px 10px;background:#fff;border:1px solid var(--line);border-radius:16px}
.cp-track{position:relative;height:34px;margin:18px 6px 0}
.cp-track::before{content:'';position:absolute;left:0;right:0;top:50%;height:4px;margin-top:-2px;border-radius:99px;background:#e6eeea}
.cp-band{position:absolute;top:50%;height:10px;margin-top:-5px;border-radius:99px;background:linear-gradient(90deg,rgba(23,102,83,.18),rgba(23,102,83,.32))}
.cp-dot{position:absolute;top:50%;width:14px;height:14px;margin:-7px 0 0 -7px;padding:0;border-radius:50%;background:var(--c);border:2px solid #fff;box-shadow:0 1px 4px rgba(0,0,0,.25);cursor:pointer;transition:transform .15s}
.cp-dot:hover{transform:scale(1.35);z-index:2}
.cp-dot.off{background:#fff;border:2px dashed #a9b7b2;box-shadow:none}
.cp-est{position:absolute;top:-16px;bottom:-2px;width:2px;margin-left:-1px;background:var(--gold);border-radius:2px}
.cp-est span{position:absolute;top:-20px;left:50%;transform:translateX(-50%);white-space:nowrap;font-size:11px;font-weight:900;color:#8a6817;background:#fff7e0;border:1px solid #f0d48e;padding:2px 8px;border-radius:99px}
.cp-axis{display:flex;justify-content:space-between;gap:10px;margin-top:8px;font-size:11px;color:#8a9a95;font-weight:700}
.cp-axis span:nth-child(2){text-align:center;flex:1}
.cp-bar{display:flex;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap;margin-top:16px}
.cp-chips{display:flex;gap:8px;flex-wrap:wrap}
.cp-chip{display:inline-flex;align-items:center;gap:7px;padding:9px 13px;border-radius:99px;background:#fff;border:1px solid var(--line);font-size:12px;font-weight:800;color:#4e665f}
.cp-chip i{font-style:normal;min-width:20px;padding:1px 6px;border-radius:99px;background:#eef3f1;color:#5e746e;font-size:11px;text-align:center}
.cp-chip.on{background:var(--ink);border-color:var(--ink);color:#fff}.cp-chip.on i{background:rgba(255,255,255,.18);color:#fff}
.cp-sort{flex-direction:row;align-items:center;gap:10px;font-size:12px}
.cp-sort select{height:42px;font-size:13px;padding:0 12px;border-radius:12px}

.cp-card{position:relative}
.cp-card .comp-body .source{padding-right:96px}
.cp-switch{position:absolute;top:14px;right:14px;display:inline-flex;align-items:center;gap:7px;padding:5px 10px 5px 5px;border-radius:99px;background:#f1f3f2;border:1px solid #dfe6e3;font-size:11px;font-weight:900;letter-spacing:.04em;color:#7a8b86;z-index:3;box-shadow:0 2px 8px rgba(16,43,37,.08)}
.cp-switch .knob{position:relative;width:30px;height:18px;border-radius:99px;background:#c9d4d0;transition:background .2s}
.cp-switch .knob::after{content:'';position:absolute;top:2px;left:2px;width:14px;height:14px;border-radius:50%;background:#fff;box-shadow:0 1px 3px rgba(0,0,0,.25);transition:transform .2s}
.cp-switch.on{background:#e7f5ef;border-color:#b8e0cf;color:#0e5f4d}
.cp-switch.on .knob{background:#1d8a6c}.cp-switch.on .knob::after{transform:translateX(12px)}
.cp-switch em{font-style:normal}
.cp-excluded{border-style:dashed!important;background:#fafbfb}
.cp-excluded>*:not(.cp-switch){opacity:.5;filter:grayscale(.85)}
.cp-hide{display:none!important}
.cp-tags{display:flex;flex-wrap:wrap;gap:6px;margin:8px 0 2px}
.cp-tag{display:inline-flex;align-items:center;gap:4px;padding:4px 9px;border-radius:8px;font-size:11px;font-weight:800;letter-spacing:.02em}
.cp-tag a{color:inherit;text-decoration:underline}
.cp-tag.user{background:#efe9fb;color:#5b3fa8}
.cp-tag.pool{background:#fff6dc;color:#8a6817}
.cp-tag.dup{background:#e8f1fb;color:#1a5276}
.cp-tag.off{background:#f6e7e4;color:#9c3b31}
.cp-save{padding:10px 14px;border-radius:12px;font-size:12px;background:#fff7e0;color:#8a6817;border:1px solid #f0d48e}
.cp-save.danger{background:#fff0ee;color:#9c3b31;border-color:#f0c5bc}
.cp-save:disabled{opacity:.7}
.cp-flash{animation:cpFlash 1.4s ease}
@keyframes cpFlash{0%,100%{box-shadow:none}30%{box-shadow:0 0 0 4px rgba(200,146,36,.55)}}
.cp-empty{grid-column:1/-1;padding:20px;border:1px dashed var(--line);border-radius:18px;text-align:center;color:#7a8b86;font-weight:700;background:#fbfdfc}
.cp-empty.big{padding:34px 20px}

.cp-modal{position:fixed;inset:0;z-index:10000;background:rgba(12,30,26,.48);backdrop-filter:blur(4px);display:grid;place-items:center;padding:20px;animation:cpFade .15s ease}
@keyframes cpFade{from{opacity:0}}
body.cp-lock{overflow:hidden}
.cp-dialog{width:min(760px,100%);max-height:calc(100vh - 40px);overflow:auto;background:#fff;border-radius:26px;box-shadow:0 30px 80px rgba(0,0,0,.25)}
.cp-dialog.wide{width:min(1000px,100%)}
.cp-dialog header{position:sticky;top:0;z-index:2;display:flex;justify-content:space-between;align-items:center;padding:18px 24px;background:rgba(255,255,255,.96);border-bottom:1px solid var(--line)}
.cp-dialog header b{font-size:18px;letter-spacing:-.01em}
.cp-x{width:38px;height:38px;padding:0;border-radius:50%;font-size:22px;line-height:1;background:#f1f5f3}
.cp-dbody{padding:20px 24px 24px}
.cp-dbody footer{display:flex;justify-content:flex-end;gap:10px;margin-top:20px;padding-top:16px;border-top:1px solid var(--line)}
.cp-lead{margin:0 0 14px;color:#60736d;font-size:14px;line-height:1.55}
.cp-url{display:flex;gap:10px}.cp-url input{flex:1;min-width:0}.cp-url button{white-space:nowrap}
.cp-fetch{margin-top:10px;padding:11px 14px;border-radius:12px;font-size:13px;font-weight:700;background:#f4f8f6;color:#5e746e}
.cp-fetch.ok{background:#e9f6f0;color:#0e5f4d}.cp-fetch.warn{background:#fff6e5;color:#8a5a0b}
.cp-form{display:grid;grid-template-columns:170px 1fr;gap:18px;margin-top:18px}
.cp-preview{position:relative;border-radius:18px;overflow:hidden;background:linear-gradient(135deg,#c7d8d2,#f1f5f3);min-height:170px;align-self:start;aspect-ratio:4/5}
.cp-preview img{width:100%;height:100%;object-fit:cover;display:block}
.cp-preview span{position:absolute;left:10px;bottom:10px;padding:4px 10px;border-radius:8px;background:rgba(16,43,37,.82);color:#fff;font-size:11px;font-weight:800}
.cp-fields{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.cp-fields .full{grid-column:1/-1}
.cp-fields input{height:48px;font-size:15px}
.cp-unit{margin-top:16px;padding:14px 16px;border-radius:14px;background:#f4f8f6;color:#6b7f79;font-size:14px}
.cp-unit.ready{background:linear-gradient(135deg,#0d493c,#1d755f);color:#d9efe7}.cp-unit.ready b{color:#fff;font-size:18px}
.cp-unit .warn{color:#ffd28a;font-weight:800}
.cp-check{flex-direction:row;align-items:center;gap:10px;margin-top:14px;font-size:13px}.cp-check input{height:auto}
.cp-pool-top{display:flex;justify-content:space-between;gap:16px;align-items:flex-start;flex-wrap:wrap}
.cp-pool-top .cp-lead{flex:1;min-width:260px}
.cp-store{padding:8px 12px;border-radius:99px;font-size:12px;font-weight:800;white-space:nowrap}
.cp-store.d1{background:#e9f6f0;color:#0e5f4d}.cp-store.local{background:#fff6e5;color:#8a5a0b}
.cp-table-wrap{overflow-x:auto;border:1px solid var(--line);border-radius:16px}
.cp-table{width:100%;border-collapse:collapse;font-size:13px}
.cp-table th{text-align:left;font-size:11px;letter-spacing:.08em;text-transform:uppercase;color:#7a8b86;background:#f7faf8;padding:11px 12px;border-bottom:1px solid var(--line)}
.cp-table td{padding:11px 12px;border-bottom:1px solid #eef2f0;vertical-align:top}
.cp-table tr:last-child td{border-bottom:0}
.cp-table .n{text-align:right;white-space:nowrap;font-weight:800}
.cp-table a{color:var(--ink);font-weight:700;text-decoration:none}.cp-table a:hover{color:var(--green);text-decoration:underline}
.cp-table small{display:block;color:#8a9a95;margin-top:3px}
.cp-mini{display:inline-block;padding:1px 6px;border-radius:6px;background:#eef3f1;color:#5e746e;font-size:10px;font-weight:900}
.cp-mini.warn{background:#f6e7e4;color:#9c3b31}
.cp-del{padding:7px 12px;border-radius:10px;font-size:12px;background:#fff0ee;color:#9c3b31}
.cp-pool-load{padding:30px;text-align:center;color:#7a8b86}

@media(max-width:900px){.cp-stats{grid-template-columns:repeat(3,1fr)}.cp-form{grid-template-columns:1fr}.cp-preview{aspect-ratio:16/9;min-height:0}}
@media(max-width:560px){.cp-panel{padding:18px 16px;border-radius:20px}.cp-stats{grid-template-columns:1fr 1fr}.cp-head h3{font-size:18px}.cp-actions{width:100%}.cp-actions button{flex:1}.cp-fields{grid-template-columns:1fr}.cp-url{flex-direction:column}.cp-dbody{padding:16px}.cp-dialog header{padding:14px 16px}.cp-card .comp-body .source{padding-right:0;padding-top:30px}}
@media print{.cp-panel,.cp-switch,.cp-save,.cp-tags,.cp-modal{display:none!important}.cp-excluded{display:none!important}}
