/* Tool board (camping-tools category) */
.tool-lab{margin-top:28px;margin-bottom:8px}
.tb-head{max-width:680px;margin-bottom:18px}
.tb-head h2{margin:.2em 0 .25em;font-size:clamp(22px,2.6vw,32px);line-height:1.35}
.tb-head p{margin:0;color:var(--muted);font-size:14px}
.tb-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(320px,480px);gap:22px;align-items:start}
.tb-side{display:flex;flex-direction:column;gap:14px;min-width:0}

.tb-control{background:#fbfaf6;border:1px solid var(--line);border-radius:22px;padding:16px 18px}
.tb-label{display:block;font-size:13px;font-weight:700;margin-bottom:10px}
.tb-tasks{display:flex;flex-wrap:wrap;gap:8px}
.tb-task{display:inline-flex;align-items:center;gap:7px;border:1px solid var(--line);background:#fff;border-radius:999px;padding:8px 14px;font:inherit;font-size:13px;color:var(--ink);cursor:pointer;transition:all .2s}
.tb-task:hover{border-color:var(--olive)}
.tb-dot{width:14px;height:14px;border-radius:4px;border:1.5px solid #b9b5a6;transition:all .2s}
.tb-task.is-on{border-color:var(--forest);background:#eef1e6}
.tb-task.is-on .tb-dot{background:var(--forest);border-color:var(--forest);box-shadow:inset 0 0 0 2px #fff}

.tb-result{background:#fbfaf6;border:1px solid var(--line);border-radius:22px;padding:14px 18px 16px}
.tb-count{font-size:13px;color:var(--muted);padding:8px 12px;border-radius:12px;background:#f3efe4;margin-bottom:6px}
.tb-count strong{color:var(--forest);font-size:15px}
.tb-list{list-style:none;margin:0;padding:0}
.tb-row{display:grid;grid-template-columns:24px 44px 1fr auto;gap:10px;align-items:center;padding:8px 0;border-bottom:1px dashed var(--line);animation:tb-in .3s ease}
.tb-row.is-advice{grid-template-columns:1fr}
@keyframes tb-in{from{transform:translateY(4px)}}
.tb-check{position:relative;display:inline-flex;cursor:pointer}
.tb-check input{position:absolute;opacity:0;width:0;height:0}
.tb-check span{width:20px;height:20px;border-radius:6px;border:1.5px solid #b9b5a6;background:#fff;transition:all .2s}
.tb-check input:checked+span{background:var(--forest);border-color:var(--forest);box-shadow:inset 0 0 0 3px #fff}
.tb-check input:focus-visible+span{outline:2px solid var(--olive);outline-offset:2px}
.tb-row img{width:44px;height:44px;object-fit:cover;border-radius:10px;background:#efede4}
.tb-row-body{display:flex;flex-direction:column;min-width:0}
.tb-row-body strong{font-size:13.5px}
.tb-row-body a{color:var(--ink);text-decoration:none}
.tb-row-body a:hover{text-decoration:underline}
.tb-row-body small{font-size:11.5px;color:var(--muted)}
.tb-row-price{font-size:12.5px;white-space:nowrap}
.tb-buy{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:12px;flex-wrap:wrap}
.tb-sum{display:flex;flex-direction:column;font-size:12px;color:var(--muted)}
.tb-sum strong{font-size:17px;color:var(--ink)}
.tb-add{display:inline-flex;align-items:center;gap:6px}
.tb-add .icon{width:17px;height:17px}
.tb-add[disabled]{opacity:.5;cursor:not-allowed}
.tb-msg{margin:10px 0 0;font-size:13px;color:var(--forest)}
.tb-msg a{color:inherit;font-weight:700}

.tb-stage{position:sticky;top:110px}
.tb-board{display:block;width:100%;height:auto;aspect-ratio:400/270;filter:drop-shadow(0 14px 26px rgba(20,41,46,.18))}
.tb-hit{fill:transparent}
.tb-slot{outline:none}
.tb-slot .tb-tool{opacity:.18;filter:grayscale(1);transition:opacity .3s,filter .3s}
.tb-slot.is-need{cursor:pointer}
.tb-slot.is-need .tb-tool{opacity:1;filter:none}
.tb-slot.is-need:hover .tb-hit,.tb-slot.is-need:focus-visible .tb-hit{fill:rgba(255,255,255,.25)}
.tb-slot:focus-visible .tb-hit{stroke:#253c31;stroke-width:2}
.tb-slot.is-owned .tb-tool{opacity:.4}
.tb-badge{opacity:0;transition:opacity .2s}
.tb-slot.is-owned .tb-badge{opacity:1}
.tb-name{font-size:10px;font-family:inherit;fill:#6d5034;font-weight:700;opacity:.5}
.tb-slot.is-need .tb-name{opacity:1;fill:#3a2a1c}
.tb-slot.is-owned .tb-name{text-decoration:line-through}
.tb-tool.is-swing{animation:tb-swing 1.1s ease-out}
@keyframes tb-swing{0%{transform:rotate(14deg)}30%{transform:rotate(-9deg)}55%{transform:rotate(5deg)}80%{transform:rotate(-2deg)}100%{transform:rotate(0)}}
.tb-hint{margin:8px 0 0;font-size:12px;color:var(--muted);text-align:center}

@media (max-width:900px){
 .tb-grid{grid-template-columns:1fr}
 .tb-stage{order:-1;position:sticky;top:84px;z-index:3;background:var(--bg,#f7f5ef);padding-bottom:4px}
 .tb-board{max-height:min(230px,30vh)}
 .tb-hint{margin-top:2px;font-size:11px}
 .tb-control,.tb-result{padding:14px}
 .tb-row{grid-template-columns:24px 40px 1fr}
 .tb-row-price{grid-column:3}
 .tb-add{flex:1;justify-content:center}
}
@media (prefers-reduced-motion:reduce){.tb-tool.is-swing,.tb-row{animation:none}}

/* =====================================================================
   Realistic look (matches the fitting room): framed module, a real
   pegboard on a plaster wall, shaded tools with a painted outline board
   ===================================================================== */
.tool-lab{--fr-noise:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .32 0 0 0 0 .27 0 0 0 0 .2 0 0 0 .14 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");--fr-grain:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='600' height='120'%3E%3Cfilter id='w'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.004 .22' numOctaves='4' seed='7' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .3 0 0 0 0 .18 0 0 0 0 .08 0 0 -1.4 0 .95'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23w)'/%3E%3C/svg%3E");--fr-planks:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100' preserveAspectRatio='none'%3E%3Cpath d='M-83.0 100L-5.9 0M-73.5 100L-1.9 0M-64.0 100L2.1 0M-54.5 100L6.1 0M-45.0 100L10.1 0M-35.5 100L14.1 0M-26.0 100L18.1 0M-16.5 100L22.1 0M-7.0 100L26.1 0M2.5 100L30.1 0M12.0 100L34.0 0M21.5 100L38.0 0M31.0 100L42.0 0M40.5 100L46.0 0M50.0 100L50.0 0M59.5 100L54.0 0M69.0 100L58.0 0M78.5 100L62.0 0M88.0 100L66.0 0M97.5 100L70.0 0M107.0 100L73.9 0M116.5 100L77.9 0M126.0 100L81.9 0M135.5 100L85.9 0M145.0 100L89.9 0M154.5 100L93.9 0M164.0 100L97.9 0M173.5 100L101.9 0M183.0 100L105.9 0' stroke='rgb(70,45,22)' stroke-opacity='.38' stroke-width='1' vector-effect='non-scaling-stroke' fill='none'/%3E%3Cpath d='M-19.1 17.1H-14.1M-63.0 74.0H-54.9M-17.0 21.1H-11.8M-56.4 76.1H-48.2M-16.9 28.8H-11.3M-35.8 57.3H-28.6M-0.2 10.4H4.4M-45.0 84.3H-36.4M0.3 17.8H5.3M-24.7 63.2H-17.3M-5.7 39.9H0.5M-21.3 71.5H-13.4M2.6 35.1H8.5M-13.5 71.7H-5.6M10.8 29.2H16.4M-1.2 60.3H6.1M16.5 29.0H22.0M-2.2 85.4H6.5M23.0 25.7H28.4M7.7 80.9H16.2M27.4 30.1H33.0M21.4 57.2H28.6M32.6 32.7H38.4M25.5 75.7H33.7M39.9 19.0H45.0M35.8 56.1H42.9M44.0 36.0H50.0M42.1 71.5H50.0M50.0 31.6H55.7M50.0 85.8H58.7M55.7 31.4H61.4M58.8 87.2H67.6M60.4 21.8H65.6M67.1 83.0H75.7M65.8 23.3H71.1M76.5 87.7H85.3M74.0 36.4H80.0M78.8 58.4H86.0M73.8 14.1H78.6M87.2 62.6H94.6M86.8 39.0H93.0M97.2 70.3H105.0M89.0 28.8H94.6M103.2 65.5H110.8M93.0 25.2H98.4M112.1 68.5H119.9M96.1 20.5H101.2M123.3 75.5H131.5M105.1 27.5H110.6M137.6 86.6H146.4M112.4 30.5H118.0M146.9 87.5H155.7M121.5 35.7H127.4M157.2 89.7H166.1M123.5 30.1H129.1M145.4 60.7H152.7' stroke='rgb(70,45,22)' stroke-opacity='.25' stroke-width='1' vector-effect='non-scaling-stroke' fill='none'/%3E%3C/svg%3E");}
.tb-shell{position:relative;padding:clamp(18px,2.6vw,32px);border-radius:32px;border:1px solid rgba(37,60,49,.09);
 background:radial-gradient(70% 60% at 100% 0,rgba(240,160,58,.07),rgba(240,160,58,0) 70%),radial-gradient(60% 60% at 0 100%,rgba(104,115,75,.1),rgba(104,115,75,0) 70%),linear-gradient(180deg,#f4f1e8,#f8f6f0);
 box-shadow:0 30px 60px -40px rgba(31,45,36,.35)}
.tb-eyebrow{display:inline-block;font-size:13px;font-weight:700;color:var(--ember-deep,#a8501a)}
.tb-head{margin-bottom:22px}
.tb-head h2{margin:.45em 0 .3em;font-size:clamp(24px,3vw,36px);line-height:1.3;color:var(--ink)}
.tb-head p{font-size:14.5px;line-height:1.9}
@media (min-width:901px){.tb-grid{gap:24px}}
.tb-side{gap:18px}
.tb-control,.tb-result{border-radius:26px;border:1px solid rgba(37,60,49,.1);background:linear-gradient(180deg,#fffdf9,#fbf9f3);box-shadow:0 1px 0 rgba(255,255,255,.9) inset,0 22px 40px -30px rgba(31,45,36,.45)}
.tb-row img{border-radius:12px}
.tb-add{min-height:46px;padding-inline:20px;border-radius:14px;box-shadow:0 12px 24px -12px rgba(227,119,43,.65)}
.tb-add[disabled]{opacity:.45;box-shadow:none;filter:grayscale(.4)}

/* stage: pegboard hung on a plaster wall */
.tb-stage{border-radius:26px;overflow:hidden;padding:22px 20px 0;
 background:var(--fr-noise),radial-gradient(60% 55% at 50% -6%,rgba(255,244,222,.9),rgba(255,244,222,0) 72%),linear-gradient(90deg,rgba(58,46,32,.2),rgba(58,46,32,0) 22%,rgba(58,46,32,0) 78%,rgba(58,46,32,.24)),linear-gradient(180deg,#d9d1c1 0%,#e6dfd1 40%,#ddd4c3 100%);
 box-shadow:inset 0 0 0 1px rgba(37,60,49,.1),inset 0 30px 60px -30px rgba(40,30,18,.3),0 26px 50px -30px rgba(31,45,36,.5)}
.tb-board{filter:drop-shadow(8px 12px 14px rgba(40,26,12,.35))}
.tb-slot .tb-tool{opacity:.2;filter:brightness(0);transition:opacity .35s,filter .35s}
.tb-slot.is-need .tb-tool{opacity:1;filter:drop-shadow(2.5px 4px 2.5px rgba(20,10,2,.5))}
.tb-slot.is-owned .tb-tool{opacity:.45}
.tb-slot .tb-peg{opacity:.55}
.tb-slot.is-need .tb-peg{opacity:1}
.tb-slot.is-need:hover .tb-hit,.tb-slot.is-need:focus-visible .tb-hit{fill:rgba(255,248,230,.16)}
.tb-name{fill:#2b1a0b;font-weight:800;font-size:9px;opacity:.4;letter-spacing:0}
.tb-slot.is-need .tb-name{opacity:.85;fill:#1f1307}
.tb-hint{margin:0 -20px;padding:11px 16px 13px;font-size:12.5px;font-weight:600;color:var(--ink);background:rgba(255,253,248,.82);backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px);border-top:1px solid rgba(255,255,255,.6);margin-top:16px}

/* result card: title and an empty state like the fitting room */
.tb-result{padding-top:16px}
.tb-result-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:10px}
.tb-result-head strong{font-size:16px;color:var(--ink)}
.tb-empty{display:none}
.tool-lab.is-empty .tb-empty{display:block}
.tool-lab.is-empty .tb-count,.tool-lab.is-empty .tb-list{display:none}
.tb-empty-box{display:flex;flex-direction:column;align-items:center;gap:4px;padding:18px 12px;border:1.5px dashed rgba(37,60,49,.18);border-radius:18px;text-align:center;background:rgba(255,255,255,.55)}
.tb-empty-box svg{width:40px;height:34px;fill:none;stroke:var(--olive,#68734b);stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round;margin-bottom:4px;opacity:.85}
.tb-empty-box b{font-size:13.5px;color:var(--forest)}
.tb-empty-box small{font-size:12px;color:var(--muted);line-height:1.8;max-width:330px}
.tb-buy{margin-top:14px;padding-top:14px;border-top:1px solid rgba(37,60,49,.12)}
.tb-sum strong{font-size:20px;font-weight:800}
@media (max-width:900px){
 .tb-stage{padding:12px 12px 0;background-color:#e2dacb}
 .tb-hint{margin:8px -12px 0;padding:6px 10px 8px}
}
@media (max-width:600px){
 .tb-shell{padding:16px 12px;border-radius:24px;margin-inline:-4px}
}

/* mobile: tool names under each tool, larger and clearer on the pegboard */
@media (max-width:900px){
 .tb-name{font-size:12px;opacity:.7;paint-order:stroke;stroke:rgba(255,240,214,.75);stroke-width:2.4px;stroke-linejoin:round}
 .tb-slot.is-need .tb-name{opacity:1}
}
