:root { --brand:#007d91; --ink:#222; --panel:#fff; --edge:#ddd; }
*{box-sizing:border-box}
body{font-family:system-ui,-apple-system,Segoe UI,Roboto,sans-serif;background:#f5f7f8;color:var(--ink);margin:0;display:flex;flex-direction:column;align-items:center}
header #logo{width:260px;margin:20px auto;display:block}
.wrap{background:var(--panel);border:1px solid var(--edge);border-radius:8px;padding:20px;max-width:1100px;width:95%;box-shadow:0 2px 6px rgba(0,0,0,.06);margin:0 0 36px}
.dropzone{border:2px dashed var(--brand);border-radius:12px;padding:36px;text-align:center;cursor:pointer;background:#fafafa;margin-bottom:16px}
.dropzone.hover{background:#e0f7fa}
.preview-img{max-width:100%;display:block;border-radius:6px}
button{background:var(--brand);color:#fff;border:none;border-radius:8px;padding:10px 14px;cursor:pointer;font-weight:600;margin:4px}
button.secondary{background:#e0e0e0;color:#111}
button:disabled{opacity:.6;cursor:not-allowed}
#panel-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:20px;margin-top:16px}
.panel{background:#fff;border:1px solid var(--edge);border-radius:10px;padding:14px}
.panel h3{margin:0 0 8px}
#tuning-panel{transition:all .3s ease;overflow:hidden;opacity:1;max-height:1200px;margin-top:16px}
#tuning-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:18px}
.slider-wrap{display:flex;align-items:center;gap:10px}
.slider-input{flex:1;accent-color:var(--brand)}
#tuning-panel input[type=number]{width:70px;text-align:center}
.preset-row button{background:#ececec;color:#111}
.note{font-size:.9em;color:#555}
@media (max-width:860px){#panel-grid{grid-template-columns:1fr}#tuning-grid{grid-template-columns:1fr}}
/* Spinner overlay */
#spinner-overlay{position:fixed;inset:0;background:rgba(255,255,255,.85);display:none;align-items:center;justify-content:center;flex-direction:column;z-index:9999}
.spinner{border:6px solid #ddd;border-top:6px solid var(--brand);border-radius:50%;width:60px;height:60px;animation:spin .8s linear infinite;margin-bottom:12px}
@keyframes spin{to{transform:rotate(360deg)}}
