.tool-hero .tb-calque{position:absolute;z-index:5;pointer-events:none}
.tool-hero .tb-calque canvas,.tool-hero .tb-calque svg{position:absolute;inset:0;width:100%;height:100%}
.tool-hero .tb-lueur{mix-blend-mode:screen}
.tool-hero .tb-poignees{overflow:visible;touch-action:none}
.tool-hero .tb-guide{fill:none;stroke:rgba(255,255,255,.85);stroke-dasharray:2 5;stroke-linecap:round;vector-effect:non-scaling-stroke;stroke-width:2px}
.tool-hero .tb-poignee{fill:rgba(15,23,42,.35);stroke:#fff;cursor:grab;vector-effect:non-scaling-stroke;stroke-width:2.5px;transition:fill .15s}
.tool-hero .tb-poignee-s{fill:rgba(37,99,235,.55)}
.tool-hero .tb-poignee:hover,.tool-hero .tb-poignees.is-prise .tb-poignee{fill:rgba(37,99,235,.8)}
.tool-hero .tb-poignees.is-prise{cursor:grabbing}

.tb-opts{display:flex;flex-direction:column;gap:var(--s-4)}
.tb-opts .tb-bloc{display:flex;flex-direction:column;gap:var(--s-2);min-width:0}
.tb-opts .tb-deux{display:grid;grid-template-columns:1fr;gap:var(--s-4)}
.tb-opts .tb-analyse{display:flex;align-items:center;gap:var(--s-3);padding:var(--s-3);border-radius:var(--r-2);background:var(--c-action-soft);color:var(--c-action);font-weight:600;font-size:14px}
.tb-opts .tb-barre{flex:0 0 96px;height:6px;border-radius:999px;background:rgba(37,99,235,.18);overflow:hidden}
.tb-opts .tb-barre i{display:block;height:100%;border-radius:inherit;background:var(--c-action);transition:width .4s ease}

.tb-opts .tb-styles{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:var(--s-2)}
.tb-opts .tb-style{display:flex;flex-direction:column;align-items:stretch;gap:6px;padding:6px 6px 8px;border:1px solid var(--c-line-strong);border-radius:var(--r-2);background:var(--c-surface);color:var(--c-ink);cursor:pointer;font:inherit;min-width:0}
.tb-opts .tb-style strong{font-size:12px;font-weight:600;line-height:1.2;text-align:center;overflow-wrap:anywhere}
.tb-opts .tb-style.is-on{border-color:var(--c-action);box-shadow:inset 0 0 0 1px var(--c-action);background:var(--c-action-soft)}
.tb-opts .tb-style:focus-visible,.tb-opts .tb-teinte:focus-visible,.tb-opts .tb-seg button:focus-visible{outline:2px solid var(--c-focus);outline-offset:2px}
.tb-opts .tb-ech{position:relative;display:block;height:34px;border-radius:6px;background:linear-gradient(160deg,#1f5132,#123620);overflow:hidden}
.tb-opts .tb-ech::before,.tb-opts .tb-ech::after{content:"";position:absolute;left:12%;right:22%;top:50%;height:6px;margin-top:-3px;border-radius:999px}
.tb-opts .tb-ech::after{left:auto;right:10%;width:9px;height:9px;margin-top:-4.5px;background:#fff;box-shadow:0 0 0 1px rgba(0,0,0,.25)}
.tb-opts .tb-ech-comete::before{background:linear-gradient(90deg,transparent,var(--c));clip-path:polygon(0 45%,100% 0,100% 100%,0 55%)}
.tb-opts .tb-ech-neon::before{background:#fff;box-shadow:0 0 0 2px var(--c),0 0 10px 3px var(--c);height:3px;margin-top:-1.5px}
.tb-opts .tb-ech-feu::before{background:linear-gradient(90deg,transparent,var(--c) 45%,#ffecaa);clip-path:polygon(0 40%,100% 0,100% 100%,0 60%);filter:drop-shadow(0 0 4px var(--c))}
.tb-opts .tb-ech-tele::before{background:var(--c);height:4px;margin-top:-2px;box-shadow:0 2px 3px rgba(0,0,0,.5)}
.tb-opts .tb-ech-points::before{height:8px;margin-top:-4px;border-radius:0;background:radial-gradient(circle,var(--c) 0 3px,transparent 3.5px) 0 50%/12px 8px repeat-x;-webkit-mask:linear-gradient(90deg,rgba(0,0,0,.25),#000);mask:linear-gradient(90deg,rgba(0,0,0,.25),#000)}

.tb-opts .tb-couleurs{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.tb-opts .tb-teinte{position:relative;width:30px;height:30px;padding:0;border-radius:50%;border:2px solid var(--c-surface);background:var(--c);box-shadow:0 0 0 1px var(--c-line-strong);cursor:pointer}
.tb-opts .tb-teinte.is-on{box-shadow:0 0 0 2px var(--c-action)}
.tb-opts .tb-perso{background:conic-gradient(#ff2d55,#ffd23f,#39ff88,#22d3ee,#3b82f6,#a855f7,#ff2d55);overflow:hidden}
.tb-opts .tb-perso.is-on{background:var(--c)}
.tb-opts .tb-perso input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer;border:0;padding:0}

.tb-opts .tb-seg{display:flex;border:1px solid var(--c-line-strong);border-radius:var(--r-2);overflow:hidden}
.tb-opts .tb-seg button{flex:1 1 0;min-width:0;padding:8px 4px;border:0;border-right:1px solid var(--c-line);background:var(--c-surface);color:var(--c-ink);font:inherit;font-size:13px;font-weight:600;cursor:pointer;white-space:nowrap}
.tb-opts .tb-seg button:last-child{border-right:0}
.tb-opts .tb-seg button.is-on{background:var(--c-action);color:var(--c-on-action)}

.tb-opts .tb-tirs-tete{display:flex;align-items:center;justify-content:space-between;gap:var(--s-2)}
.tb-opts .tb-ajout{display:inline-flex;align-items:center;gap:6px;padding:6px 12px;border:1px solid var(--c-action);border-radius:999px;background:var(--c-surface);color:var(--c-action);font:inherit;font-size:13px;font-weight:600;cursor:pointer}
.tb-opts .tb-liste{display:flex;flex-direction:column;gap:6px;margin:0;padding:0;list-style:none}
.tb-opts .tb-tir{display:flex;align-items:center;gap:6px;padding:4px 4px 4px 10px;border:1px solid var(--c-line);border-radius:var(--r-2);background:var(--c-surface)}
.tb-opts .tb-tir.is-edit{border-color:var(--c-action);background:var(--c-action-soft)}
.tb-opts .tb-tir.is-off .tb-tir-nom{opacity:.5;text-decoration:line-through}
.tb-opts .tb-tir-nom{display:flex;align-items:baseline;gap:8px;flex:1 1 auto;min-width:0;padding:4px 0;border:0;background:none;color:var(--c-ink);font:inherit;font-size:14px;font-weight:600;text-align:left;cursor:pointer}
.tb-opts .tb-tir-nom small{font-weight:500;opacity:.65;font-variant-numeric:tabular-nums}
.tb-opts .tb-tir-act{padding:6px 10px;border:0;border-radius:var(--r-2);background:none;color:var(--c-action);font:inherit;font-size:13px;font-weight:600;cursor:pointer}
.tb-opts .tb-tir-x{display:inline-flex;padding:8px;border:0;border-radius:50%;background:none;color:var(--c-ink);opacity:.6;cursor:pointer}
.tb-opts .tb-tir-x:hover{opacity:1;background:var(--c-danger-soft);color:var(--c-danger)}
.tb-opts .tb-aide{margin:0;font-size:13px;line-height:1.45;opacity:.8}
@media (max-width:639px){.tb-opts .tb-styles{grid-template-columns:repeat(3,minmax(0,1fr))}.tb-opts .tb-deux{grid-template-columns:1fr}}
