.wm, .wm * { box-sizing: border-box; }
.wm { --wm-blue: #037fbb; --wm-ink: #19384d; --wm-line: #dbe5ec; color: var(--wm-ink); font: 15px/1.5 Arial, sans-serif; }
.wm [hidden] { display: none !important; }
.wm-heading { padding: 8px 0 18px; }
.wm-heading p { color: #087ea6; font-size: 11px; font-weight: bold; letter-spacing: 1.2px; margin: 0 0 9px; text-transform: uppercase; }
.wm-heading h2 { color: var(--wm-blue); font-size: clamp(25px, 4vw, 32px); margin: 0; line-height: 1.2; }
.wm-hint { color: #005b85; font-weight: bold; background: #edf5fb; border-left: 4px solid #087ea6; border-radius: 4px; margin: 0 0 12px; padding: 12px 16px; }
.wm-stage { position: relative; background: #f6f8fa; border: 1px solid var(--wm-line); border-radius: 10px; }
.wm-view { position: relative; height: clamp(330px, 62vh, 700px); overflow: hidden; border-radius: 9px 9px 0 0; background: #c7ddf5; }
.wm-view canvas { position: absolute; inset: 0; display: block; width: 100%; height: 100%; }
.wm-view-status { position: absolute; z-index: 1; padding: 10px 15px; margin: 10px; border-radius: 6px; background: #fff; }
.wm-toolbar { position: absolute; top: 12px; right: 12px; z-index: 1; }
.wm-toolbar, .wm-parts { display: flex; flex-wrap: wrap; gap: 6px; }
.wm-parts { padding: 10px 12px; border-top: 1px solid var(--wm-line); }
.wm button, .wm input, .wm select { font: inherit; border: 1px solid var(--wm-line); border-radius: 6px; padding: 6px 9px; }
.wm button { cursor: pointer; color: #fff; background: var(--wm-blue); border-color: var(--wm-blue); font-weight: bold; }
.wm button:hover { color: var(--wm-ink); background: #c7ddf5; }
.wm button[aria-pressed=true], .wm button[aria-expanded=true] { box-shadow: inset 0 0 0 2px var(--wm-ink); }
.wm :focus-visible { outline: 3px solid #e4ab44; outline-offset: 2px; }
.wm-panel { position: absolute; z-index: 2; top: 12px; left: 12px; width: min(330px, 42%); max-height: calc(100% - 72px); overflow: auto; background: white; border: 1px solid var(--wm-line); border-radius: 8px; box-shadow: 0 8px 24px #19384d29; padding: 12px; }
.wm-panel-title { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.wm-panel-title button { line-height: 1; font-size: 19px; }
.wm h3 { color: var(--wm-blue); margin: 0; font-size: 16px; }
.wm-fields, .wm-fabrics { display: grid; gap: 8px; }
.wm [data-pane=valance]:not([hidden]) + .wm-fabrics { margin-top: 10px; }
.wm label { display: grid; gap: 3px; font-weight: bold; }
.wm input, .wm select { width: 100%; min-width: 0; color: var(--wm-ink); background: #fff; }
.wm-swatches { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 6px; }
.wm .wm-swatch, .wm-panel-title button { color: var(--wm-ink); background: #fff; border-color: var(--wm-blue); }
.wm .wm-swatch { min-width: 0; overflow-wrap: anywhere; padding: 5px; }
.wm-swatch span { display: block; height: 28px; border: 1px solid #19384d33; border-radius: 3px; background: var(--sample) center / cover; }
.wm-summary { margin: 12px 0; padding: 12px 16px; border: 1px solid var(--wm-line); border-radius: 8px; }
.wm-summary p, .wm-note { margin: 4px 0; }
.wm-note { color: #536a78; font-size: 13px; }
.wm-summary a { color: #005b85; }
@media (max-width: 650px) {
    .wm-panel { position: static; width: auto; max-height: min(440px, 65vh); margin: 0 10px 10px; }
}

.wm-tools { display:flex; flex-wrap:wrap; gap:12px 20px; padding:12px 0; align-items:center; }
.wm-tools label { display:flex; align-items:center; gap:6px; flex-wrap:wrap; }
.wm-tools input[type=file] { max-width:220px; }
.wm-measure { position:absolute; bottom:12px; left:12px; background:#fffffff2; border-radius:5px; padding:6px 10px; font-size:13px; pointer-events:none; }
.wm-lines { border-collapse:collapse; width:100%; }
.wm-lines td,.wm-lines th { text-align:right; padding:6px; border-bottom:1px solid var(--wm-line); }
.wm-lines td:first-child,.wm-lines th:first-child { text-align:left; }
.wm [data-cart] { display:inline-block; }
.wm [data-sensors] label { display:flex; align-items:center; gap:8px; }
.wm-product { display:grid;grid-template-columns:repeat(auto-fit,minmax(min(280px,100%),1fr));gap:2rem;align-items:center; }
.wm-product nav { display:flex;gap:.75rem;flex-wrap:wrap; }
.wm-entry { padding:12px 18px;display:inline-block;background:#037fbb;color:white;border-radius:5px; }

.wm-actions { display:flex; flex-wrap:wrap; align-items:center; gap:5px; padding:8px 12px; background:white; border:1px solid var(--wm-line); border-radius:7px; }
.wm-actions [data-code] { width:13ch; }
.wm-actions [data-total] { margin-left:auto; color:#005587; font-size:1.15em; }
.wm-actions form { margin:0; }
.wm button.wm-icon { width:35px; height:35px; display:inline-flex; flex-direction:column; justify-content:center; align-items:center; padding:3px; font-size:9px; line-height:1; }
.wm-icon svg { width:18px; height:18px; fill:none; stroke:currentColor; stroke-width:1.6; stroke-linecap:round; stroke-linejoin:round; }
.wm button:disabled { opacity:.45; cursor:default; }
.wm-toolbar { justify-content:flex-end; left:8px; right:10px; top:6px; pointer-events:none; }
.wm-toolbar button { pointer-events:auto; }
.wm-toolbar [data-redo] { margin-right:12px; }
.wm .wm-keyboard:not(:focus-within):not(.wm-fallback) { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); padding:0; border:0; }
.wm-panel.wm-wide { left:8px; width:calc(100% - 16px); max-height:calc(100% - 24px); }
.wm-wide .wm-swatches { grid-template-columns:minmax(0,1fr); }
.wm-wide .wm-swatch { display:grid; grid-template-columns:minmax(0,3fr) minmax(95px,1fr); align-items:center; text-align:left; gap:12px; }
.wm-wide .wm-swatch span { height:76px; background-position:center; }
.wm-wide [data-pane=valance] { grid-template-columns:repeat(auto-fit,minmax(135px,1fr)); margin-bottom:12px; }
.wm-panel-title { position:sticky; top:-12px; z-index:1; background:#fff; padding:5px 0; }
.wm-product .wm-entry,.wm-product nav a { display:block; text-align:center; background:#0085ae; color:white; padding:16px 8px; border-radius:5px; text-decoration:none; font-weight:700; }
.wm-product nav { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:6px; }
.wm-product nav a { font-size:.9em; }
.wm-product nav svg { display:block; margin:0 auto 6px; width:25px; height:25px; fill:none; stroke:currentColor; stroke-width:1.5; }
.wm-product header,.wm-product aside { border-top:1px solid var(--wm-line); padding:14px 0; }
.wm-product .availability { padding:9px; background:#fff0bd; }
@media(max-width:650px) { .wm-panel.wm-wide { margin:6px; width:calc(100% - 12px); max-height:75vh; } .wm-toolbar { gap:3px; } }
.wm-product { grid-template-columns:minmax(0,1fr) minmax(0,400px); align-items:start; }
.wm-product h1 { color:#0085ba; font-size:32px; }
.wm-product .wm-kicker { color:#0085ba; text-transform:uppercase; font-size:11px; letter-spacing:1px; font-weight:bold; }
.wm-product .wm-identity { display:flex; justify-content:space-between; gap:10px; margin-bottom:8px; }
.wm-product h3 { margin-bottom:10px; }
@media(max-width:700px) { .wm-product { grid-template-columns:minmax(0,1fr); } }
