/* Base comune ai template Valle Alta: reset, componenti, filtri, carrello, ricerca, barra mockup, pannello Aspetto. */

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { background: var(--canvas); color: var(--ink); font: 15px/1.5 var(--f-b); -webkit-font-smoothing: antialiased; padding-bottom: 88px; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--canvas); }
img { display: block; max-width: 100%; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
svg.i { width: 20px; height: 20px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.shell { max-width: 1480px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.d { font-family: var(--f-d); font-weight: var(--dw); letter-spacing: var(--ls-d); text-transform: var(--tt-d, none); }
.it { font-family: var(--f-i); font-style: italic; font-weight: 400; letter-spacing: -.01em; }
.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }

/* pulsanti */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; height: 52px; padding: 0 26px; border-radius: var(--pill); background: var(--primary); color: var(--on-primary); font-weight: 600; font-size: 15px; white-space: nowrap; transition: transform .2s ease, opacity .2s; }
.btn:hover { transform: translateY(-1px); }
.btn.light { background: #FFFFFF; color: #141414; }
.btn.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1px var(--line); }
.btn.glass { background: rgb(255 255 255 / .16); color: #FFFFFF; box-shadow: inset 0 0 0 1px rgb(255 255 255 / .35); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.btn .dot { width: 34px; height: 34px; margin-right: -16px; border-radius: 50%; display: grid; place-items: center; background: var(--primary); color: var(--on-primary); }
.btn.light .dot { background: #141414; color: #FFFFFF; }
.circle { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); color: var(--ink); flex: none; transition: background .2s; }
.circle:hover { background: var(--soft); }
.circle.sm { width: 36px; height: 36px; }
.circle.sm svg.i { width: 17px; height: 17px; }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 12px; border-radius: var(--pill); font-size: 12.5px; font-weight: 600; background: var(--surface); color: var(--ink); white-space: nowrap; }
.chip.acc { background: var(--accent); color: var(--on-accent); }
.chip.dark { background: #141414; color: #FFFFFF; }
.chip.glass { background: rgb(255 255 255 / .18); color: #FFFFFF; backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: inset 0 0 0 1px rgb(255 255 255 / .3); }
.avail { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--muted); }
.avail::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 3px color-mix(in oklab, var(--ok) 18%, transparent); }
.avail.sup::before { background: var(--warn); box-shadow: 0 0 0 3px color-mix(in oklab, var(--warn) 18%, transparent); }
.stars { color: var(--star); letter-spacing: 1px; font-size: 14px; }

.fg { padding-block: 18px; border-bottom: 1px solid var(--line); display: grid; gap: 12px; }
.fg:last-child { border-bottom: 0; }
.fg h4 { margin: 0; font-size: 14px; font-weight: 600; display: flex; justify-content: space-between; }
.fg h4 small { font-weight: 500; color: var(--muted); }
.tog { display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 14px; text-align: left; width: 100%; }
.tog span small { display: block; font-size: 12px; color: var(--muted); }
.sw-t { width: 40px; height: 24px; border-radius: 12px; background: var(--line); position: relative; flex: none; transition: background .2s; }
.sw-t::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #FFFFFF; box-shadow: 0 1px 3px rgb(0 0 0 / .2); transition: transform .2s; }
.tog[aria-pressed="true"] .sw-t { background: var(--primary); }
.tog[aria-pressed="true"] .sw-t::after { transform: translateX(16px); background: var(--on-primary); }
.hist { display: flex; align-items: end; gap: 3px; height: 54px; }
.hist i { flex: 1; border-radius: 3px 3px 0 0; background: var(--line); }
.hist i.in { background: color-mix(in oklab, var(--primary) 70%, var(--surface)); }
.range { position: relative; height: 4px; border-radius: 2px; background: var(--line); margin: 2px 8px 6px; }
.range b { position: absolute; left: 8%; right: 30%; top: 0; bottom: 0; background: var(--primary); border-radius: 2px; }
.range i { position: absolute; top: 50%; width: 18px; height: 18px; margin: -9px 0 0 -9px; border-radius: 50%; background: var(--surface); box-shadow: 0 0 0 2px var(--primary); }
.prices { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.prices span { height: 40px; border-radius: var(--r-sm); background: var(--soft); display: flex; align-items: center; padding: 0 12px; font-size: 13.5px; }
.prices span small { color: var(--muted); margin-right: 6px; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chips button { height: 34px; padding: 0 14px; border-radius: var(--pill); font-size: 13px; font-weight: 500; box-shadow: inset 0 0 0 1px var(--line); }
.chips button[aria-pressed="true"] { background: var(--ink); color: var(--surface); box-shadow: none; }
.checks { display: grid; gap: 10px; }
.checks button { display: flex; align-items: center; gap: 10px; font-size: 14px; text-align: left; }
.checks button i { width: 18px; height: 18px; border-radius: 5px; box-shadow: inset 0 0 0 1.5px var(--line); display: grid; place-items: center; flex: none; }
.checks button[aria-pressed="true"] i { background: var(--primary); box-shadow: none; color: var(--on-primary); }
.checks button i svg.i { width: 13px; height: 13px; stroke-width: 2.6; opacity: 0; }
.checks button[aria-pressed="true"] i svg.i { opacity: 1; }
.checks small { margin-left: auto; color: var(--muted); font-size: 12.5px; }
.colors { display: flex; gap: 8px; flex-wrap: wrap; }
.colors button { width: 30px; height: 30px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgb(0 0 0 / .12); outline: 2px solid transparent; outline-offset: 2px; }
.colors button[aria-pressed="true"] { outline-color: var(--ink); }
.sizes { display: flex; gap: 8px; flex-wrap: wrap; }
.sizes button { min-width: 74px; height: 46px; padding: 0 16px; border-radius: var(--r-sm); font-size: 14px; font-weight: 500; box-shadow: inset 0 0 0 1px var(--line); }
.sizes button[aria-pressed="true"] { box-shadow: inset 0 0 0 2px var(--ink); font-weight: 600; }
.sizes button:disabled { color: var(--muted); text-decoration: line-through; cursor: not-allowed; opacity: .6; }
.step { display: inline-flex; align-items: center; height: 56px; border-radius: var(--pill); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.step button { width: 46px; height: 100%; display: grid; place-items: center; }
.step span { min-width: 22px; text-align: center; font-weight: 600; font-variant-numeric: tabular-nums; }
.acc details { border-bottom: 1px solid var(--line); }
.acc summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; padding-block: 18px; font-weight: 600; }
.acc summary::-webkit-details-marker { display: none; }
.acc summary svg.i { transition: transform .2s; }
.acc details[open] summary svg.i { transform: rotate(45deg); }
.acc .body { padding-bottom: 18px; color: var(--muted); font-size: 14.5px; }
.acc .body p { margin: 0 0 10px; }
.specs { display: grid; grid-template-columns: auto 1fr; gap: 8px 24px; margin: 0; font-size: 14px; }
.specs dt { color: var(--muted); }
.specs dd { margin: 0; color: var(--ink); text-align: right; }
.verified { font-size: 12px; font-weight: 600; color: var(--ok); display: inline-flex; gap: 4px; align-items: center; }
.verified svg.i { width: 14px; height: 14px; stroke-width: 2.4; }
/* carrello */
.scrim { position: fixed; inset: 0; z-index: 60; background: rgb(10 10 12 / .45); backdrop-filter: blur(2px); }
.drawer { position: fixed; z-index: 61; top: 10px; right: 10px; bottom: 10px; width: min(460px, calc(100% - 20px)); background: var(--surface); color: var(--ink); border-radius: var(--r-xl); box-shadow: var(--shadow-pop); display: flex; flex-direction: column; overflow: hidden; margin-top: env(safe-area-inset-top, 0px); margin-bottom: env(safe-area-inset-bottom, 0px); }
.drawer header { display: flex; justify-content: space-between; align-items: center; padding: 22px 22px 14px; }
.drawer header h3 { margin: 0; font-size: 24px; }
.drawer header .circle { background: var(--soft); }
.freeship { margin: 0 22px; padding: 14px 16px; border-radius: var(--r); background: var(--soft); font-size: 13.5px; display: grid; gap: 10px; }
.freeship i { display: block; height: 6px; border-radius: 3px; background: color-mix(in oklab, var(--ink) 10%, transparent); overflow: hidden; }
.freeship i b { display: block; height: 100%; background: var(--ok); border-radius: 3px; transition: width .4s; }
.lines { flex: 1; overflow-y: auto; padding: 8px 22px; display: grid; align-content: start; }
.ln { display: grid; grid-template-columns: 84px 1fr auto; gap: 14px; padding-block: 16px; border-bottom: 1px solid var(--line); }
.ln img { width: 84px; height: 104px; border-radius: var(--r-sm); object-fit: cover; background: var(--soft); }
.ln b { display: block; font-size: 14.5px; line-height: 1.3; }
.ln small { display: block; font-size: 12.5px; color: var(--muted); margin-top: 3px; }
.ln .ctl { display: flex; align-items: center; gap: 12px; margin-top: 10px; }
.ln .step { height: 36px; }
.ln .step button { width: 34px; }
.ln .rm { font-size: 12.5px; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }
.ln .price { text-align: right; }
.upsell { margin: 4px 22px 0; display: grid; grid-template-columns: 56px 1fr auto; gap: 12px; align-items: center; padding: 10px; border-radius: var(--r); box-shadow: inset 0 0 0 1px var(--line); }
.upsell img { width: 56px; height: 66px; border-radius: calc(var(--r-sm) * .8); object-fit: cover; }
.upsell small { display: block; font-size: 12px; color: var(--muted); }
.upsell b { font-size: 13.5px; }
.upsell .btn { height: 38px; padding: 0 14px; font-size: 13px; }
.dfoot { padding: 18px 22px 22px; display: grid; gap: 10px; border-top: 1px solid var(--line); margin-top: 14px; }
.dfoot .row { display: flex; justify-content: space-between; font-size: 14px; color: var(--muted); }
.dfoot .row.tot { color: var(--ink); font-weight: 600; font-size: 18px; }
.dfoot .btn { width: 100%; margin-top: 4px; }
.empty { padding: 40px 0; text-align: center; color: var(--muted); }

/* ricerca */
.cmd { position: fixed; inset: 0; z-index: 62; display: grid; place-items: start center; padding: calc(9vh + env(safe-area-inset-top, 0px)) 16px 16px; background: rgb(10 10 12 / .45); backdrop-filter: blur(2px); }
.cmd-box { width: min(680px, 100%); background: var(--surface); border-radius: var(--r-xl); box-shadow: var(--shadow-pop); overflow: hidden; }
.cmd-in { display: flex; align-items: center; gap: 12px; padding: 18px 22px; border-bottom: 1px solid var(--line); color: var(--muted); }
.cmd-in input { flex: 1; border: 0; background: none; outline: none; font-size: 18px; color: var(--ink); min-width: 0; }
.cmd-res { padding: 10px; max-height: 60vh; overflow-y: auto; }
.cmd-res h5 { margin: 10px 12px 6px; font-size: 12px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; }
.cmd-res .r { width: 100%; display: grid; grid-template-columns: 44px 1fr auto; gap: 14px; align-items: center; padding: 8px 12px; border-radius: var(--r-sm); text-align: left; }
.cmd-res .r:hover, .cmd-res .r:focus-visible { background: var(--soft); }
.cmd-res .r img { width: 44px; height: 54px; border-radius: 8px; object-fit: cover; }
.cmd-res .r small { display: block; font-size: 12.5px; color: var(--muted); }
.cmd-pop { display: flex; gap: 6px; flex-wrap: wrap; padding: 4px 12px 10px; }
.cmd-pop button { height: 34px; padding: 0 14px; border-radius: var(--pill); background: var(--soft); font-size: 13px; }

/* barra del mockup e pannello Aspetto */
.mock { position: fixed; z-index: 55; left: 50%; transform: translateX(-50%); bottom: calc(14px + env(safe-area-inset-bottom, 0px)); display: flex; align-items: center; gap: 4px; padding: 5px; border-radius: 999px; background: var(--mock-bg); color: var(--mock-fg); box-shadow: 0 18px 40px -14px rgb(0 0 0 / .5); font: 500 13px "Geist", system-ui, sans-serif; max-width: calc(100% - 24px); }
.mock .lab { padding: 0 10px 0 12px; opacity: .6; font-size: 12px; white-space: nowrap; }
.mock button { height: 36px; padding: 0 14px; border-radius: 999px; color: inherit; opacity: .7; white-space: nowrap; }
.mock button[aria-pressed="true"] { background: var(--mock-fg); color: var(--mock-bg); opacity: 1; }
.mock .asp { opacity: 1; box-shadow: inset 0 0 0 1px currentColor; margin-left: 4px; }
.panel { position: fixed; z-index: 70; top: 10px; left: 10px; bottom: 10px; width: min(380px, calc(100% - 20px)); overflow-y: auto; background: var(--surface); color: var(--ink); border-radius: 26px; box-shadow: var(--shadow-pop); padding: 22px; display: grid; gap: 20px; align-content: start; font-family: "Geist", system-ui, sans-serif; margin-top: env(safe-area-inset-top, 0px); margin-bottom: env(safe-area-inset-bottom, 0px); }
.panel header { display: flex; justify-content: space-between; align-items: center; }
.panel h2 { margin: 0; font-size: 20px; letter-spacing: -.02em; }
.panel header .circle { background: var(--soft); }
.panel .hd-act { display: flex; align-items: center; gap: 8px; }
.panel .reset { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: 999px; border: 1px solid color-mix(in oklab, var(--ink) 18%, transparent); background: var(--surface); color: var(--ink); font: 600 13px/1 var(--f-b); cursor: pointer; }
.panel .reset:hover { background: var(--soft); }
.panel .reset svg { width: 15px; height: 15px; }
.panel h3 { margin: 0 0 10px; font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.panel p { margin: 0; font-size: 13.5px; color: var(--muted); }
.lays { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.lays button { padding: 9px 10px; border-radius: 12px; box-shadow: inset 0 0 0 1px var(--line); display: grid; gap: 2px; text-align: left; font-family: "Geist", system-ui, sans-serif; }
.lays button b { font-size: 13.5px; font-weight: 600; }
.lays button small { font-size: 11.5px; color: var(--muted); line-height: 1.3; }
.lays button[aria-pressed="true"] { box-shadow: inset 0 0 0 2px var(--ink); }
.pals { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.pals button { padding: 8px; border-radius: 14px; box-shadow: inset 0 0 0 1px var(--line); display: grid; gap: 8px; font-size: 12.5px; font-weight: 600; text-align: left; }
.pals button[aria-pressed="true"] { box-shadow: inset 0 0 0 2px var(--ink); }
.pals i { display: flex; height: 26px; border-radius: 8px; overflow: hidden; }
.pals i b { flex: 1; }
.opts { display: flex; gap: 6px; flex-wrap: wrap; }
.opts button { height: 38px; padding: 0 14px; border-radius: 12px; font-size: 13px; font-weight: 600; box-shadow: inset 0 0 0 1px var(--line); }
.opts button[aria-pressed="true"] { background: var(--ink); color: var(--surface); box-shadow: none; }
.fonts { display: grid; gap: 6px; }
.fonts button { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; border-radius: 14px; box-shadow: inset 0 0 0 1px var(--line); text-align: left; }
.fonts button[aria-pressed="true"] { box-shadow: inset 0 0 0 2px var(--ink); }
.fonts button span { font-size: 20px; }
.fonts button small { font-size: 11.5px; color: var(--muted); text-align: right; }
.json { margin: 0; padding: 14px; border-radius: 14px; background: var(--soft); font: 11.5px/1.5 ui-monospace, "Cascadia Mono", Consolas, monospace; overflow-x: auto; white-space: pre; }
.toast { position: fixed; z-index: 80; left: 50%; bottom: calc(76px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); display: flex; align-items: center; gap: 12px; padding: 8px 18px 8px 8px; border-radius: 999px; background: var(--ink); color: var(--surface); font-size: 14px; font-weight: 500; box-shadow: var(--shadow-pop); max-width: calc(100% - 32px); }
.toast img { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; }

@media (max-width: 640px) { .mock .lab { display: none; } .mock button { padding: 0 11px; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }
.price { font-weight: 600; font-variant-numeric: tabular-nums; }
.price s { font-weight: 400; color: var(--muted); margin-left: 6px; font-size: .88em; }
.pays { display: flex; gap: 6px; flex-wrap: wrap; }
.pays span { height: 30px; padding: 0 12px; border-radius: 8px; display: grid; place-items: center; font-size: 12px; font-weight: 700; background: var(--soft); color: var(--ink); }
.prices { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.prices span { height: 40px; border-radius: var(--r-sm); background: var(--soft); display: flex; align-items: center; padding: 0 12px; font-size: 13.5px; }
.prices span small { color: var(--muted); margin-right: 6px; }
.opt { display: grid; gap: 10px; }
.opt h4 { margin: 0; font-size: 14px; font-weight: 600; display: flex; gap: 6px; }
.opt h4 span { font-weight: 400; color: var(--muted); }
.opt .colors button { width: 40px; height: 40px; }
.opts { display: flex; gap: 6px; flex-wrap: wrap; }
.opts button { height: 38px; padding: 0 14px; border-radius: 12px; font-size: 13px; font-weight: 600; box-shadow: inset 0 0 0 1px var(--line); }
.opts button[aria-pressed="true"] { background: var(--ink); color: var(--surface); box-shadow: none; }
/* rate senza interessi nella scheda prodotto (tutti i layout) */
.rate-l { display: flex; align-items: center; gap: 8px; margin: 10px 0 0; font-size: 13.5px; color: color-mix(in oklab, var(--ink) 72%, transparent); }
.rate-l .i { width: 18px; height: 18px; flex: none; color: var(--accent); }

/* cassa: il carrello si allarga a tutta pagina (stile Stripe Checkout / Shopify). Colori, font, angoli e ombre dal tema. */
.drawer { transition: width .45s cubic-bezier(.2, .8, .2, 1), top .45s, right .45s, bottom .45s, border-radius .45s; }
.drawer.xp { top: 0; right: 0; bottom: 0; width: 100%; margin: 0; border-radius: 0; box-shadow: none; background: var(--canvas); }
.drawer.xp ~ .scrim, .scrim:has(~ .drawer.xp) { background: transparent; backdrop-filter: none; }
.drawer.xp > * { animation: co-in .35s .18s both ease-out; }
@keyframes co-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.co-bar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; height: 62px; padding: 0 max(18px, calc((100% - 1180px) / 2)); border-bottom: 1px solid var(--line); background: var(--surface); flex: none; }
.co-bar .co-back { justify-self: start; display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 600; color: var(--ink); }
.co-bar .co-back svg.i { width: 17px; height: 17px; }
.co-bar .co-st { font-size: 22px; letter-spacing: -.03em; }
.co-bar .co-secure { justify-self: end; display: inline-flex; align-items: center; gap: 12px; font-size: 13px; color: var(--muted); }
.co-bar .co-secure > svg.i { width: 16px; height: 16px; margin-right: -6px; }
.co-bar .circle { background: var(--soft); }
.co-scroll { flex: 1; overflow-y: auto; overscroll-behavior: contain; }
.co { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; min-height: 100%; background: linear-gradient(90deg, var(--soft) 50%, var(--surface) 50%); }
.co-main { grid-column: 2; grid-row: 1; padding: 40px clamp(18px, 4vw, 64px) 64px; display: grid; gap: 26px; align-content: start; width: 100%; max-width: 680px; justify-self: start; }
.co-side { grid-column: 1; grid-row: 1; position: sticky; top: 0; max-height: calc(100vh - 62px); overflow-y: auto; scrollbar-width: thin; background: var(--soft); border-right: 1px solid var(--line); padding: 40px clamp(18px, 4vw, 64px) 40px; display: grid; gap: 20px; align-content: start; justify-items: end; }
.co-side > * { max-width: 460px; width: 100%; }
.co-side h3 { margin: 0; font-size: 20px; }
.co-mobsum { display: none; }
.co .co-lab { margin: 0; font-size: 12.5px; color: var(--muted); }
.co-exp { display: grid; gap: 10px; }
.co-exp .co-xb { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.co-exp .co-xb button { height: 46px; border-radius: var(--r-sm); font-weight: 700; font-size: 15px; display: inline-flex; align-items: center; justify-content: center; gap: 4px; background: var(--ink); color: var(--surface); }
.co-exp .co-xb .co-x1 { background: var(--accent); color: var(--on-accent); font-style: italic; }
.co-exp .co-xb svg.i { width: 16px; height: 16px; }
.co-exp .co-or { margin: 6px 0 0; display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 12.5px; }
.co-exp .co-or::before, .co-exp .co-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.co-sec { display: grid; gap: 12px; }
.co-sec .co-hd { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.co-sec h3 { margin: 0; font-size: 20px; }
.co .co-lnk { font-size: 13px; font-weight: 600; color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.co-f { display: grid; gap: 5px; font-size: 13px; min-width: 0; }
.co-f span { color: var(--muted); font-weight: 500; }
.co-f input, .co-code input { width: 100%; height: 46px; padding: 0 14px; border-radius: var(--r-sm); border: 1px solid color-mix(in oklab, var(--ink) 18%, transparent); background: var(--surface); color: var(--ink); font-size: 15px; box-shadow: 0 1px 2px rgb(0 0 0 / .04); transition: border-color .15s, box-shadow .15s; }
.co-f input:focus, .co-code input:focus, .cardbox input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in oklab, var(--primary) 22%, transparent); }
.co-f.co-err input, .cardbox.co-err { border-color: #D93025; box-shadow: 0 0 0 3px rgb(217 48 37 / .14); }
.co-f em, .cerr { font-style: normal; font-size: 12.5px; color: #D93025; }
.co-g2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.co-g3 { display: grid; grid-template-columns: 1fr 1.6fr .8fr; gap: 10px; }
.cchk { display: flex; align-items: center; gap: 10px; font-size: 14px; text-align: left; }
.cchk i { width: 20px; height: 20px; flex: none; border-radius: min(var(--r-sm), 6px); box-shadow: inset 0 0 0 1.5px color-mix(in oklab, var(--ink) 25%, transparent); display: grid; place-items: center; background: var(--surface); }
.cchk i svg.i { width: 13px; height: 13px; stroke-width: 2.8; opacity: 0; }
.cchk[aria-pressed="true"] i { background: var(--primary); color: var(--on-primary); box-shadow: none; }
.cchk[aria-pressed="true"] i svg.i { opacity: 1; }
.co-radios, .co-acc { display: grid; border-radius: var(--r); border: 1px solid color-mix(in oklab, var(--ink) 16%, transparent); overflow: hidden; background: var(--surface); }
.co-rd { display: grid; grid-template-columns: auto auto minmax(0, 1fr) auto; align-items: center; gap: 12px; width: 100%; padding: 14px 16px; text-align: left; font-size: 14px; }
.co-acc .co-rd { grid-template-columns: auto minmax(0, 1fr); }
.co-radios .co-rd + .co-rd, .co-acc .co-pm + .co-pm { border-top: 1px solid var(--line); }
.co-rd small { display: block; color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.co-rd .co-o { width: 18px; height: 18px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px color-mix(in oklab, var(--ink) 30%, transparent); }
.co-rd[aria-pressed="true"] { background: color-mix(in oklab, var(--primary) 7%, var(--surface)); }
.co-rd[aria-pressed="true"] .co-o { box-shadow: inset 0 0 0 5px var(--primary); }
.co-rd > svg.i { color: var(--muted); }
.co-pm.co-on { background: color-mix(in oklab, var(--primary) 4%, var(--surface)); }
.co-pm .co-pb { padding: 0 16px 16px 46px; display: grid; gap: 12px; }
.cardbox { border-radius: var(--r-sm); border: 1px solid color-mix(in oklab, var(--ink) 18%, transparent); background: var(--surface); overflow: hidden; }
.cardbox input { width: 100%; height: 46px; padding: 0 14px; border: 0; background: transparent; color: var(--ink); font-size: 15px; font-variant-numeric: tabular-nums; min-width: 0; }
.cardbox input:focus { box-shadow: inset 0 0 0 2px var(--primary); }
.cardbox .co-cn { display: flex; align-items: center; border-bottom: 1px solid var(--line); }
.cardbox .co-brands { display: flex; gap: 4px; padding-right: 10px; }
.cardbox .co-brands i { font-style: normal; font-size: 9.5px; font-weight: 800; padding: 3px 5px; border-radius: 4px; background: var(--soft); color: var(--muted); letter-spacing: .02em; }
.cardbox .co-row2 { display: grid; grid-template-columns: 1fr 1fr; }
.cardbox .co-row2 input + input { border-left: 1px solid var(--line); }
.co .co-hint { margin: 0; display: flex; gap: 8px; align-items: flex-start; font-size: 13px; color: var(--muted); }
.co .co-hint svg.i { width: 15px; height: 15px; margin-top: 2px; }
.co-r3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.co-r3 span { padding: 10px 12px; border-radius: var(--r-sm); background: var(--soft); display: grid; gap: 2px; }
.co-r3 b { font-size: 15px; }
.co-r3 small { font-size: 12px; color: var(--muted); }
.pickbox { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: var(--r); background: var(--soft); font-size: 14px; }
.pickbox small { display: block; color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.co-b2b { display: grid; gap: 10px; padding: 14px; border-radius: var(--r); background: var(--soft); }
.co-pay { width: 100%; height: 56px; font-size: 16px; border-radius: var(--r-sm); box-shadow: var(--shadow); }
.co-pay svg.i { width: 17px; height: 17px; }
.co .co-legal { margin: -12px 0 0; font-size: 12px; color: var(--muted); text-align: center; }
.co-lines { display: grid; gap: 14px; }
.co-ln { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; gap: 14px; align-items: center; font-size: 14px; }
.co-ln .co-th { position: relative; width: 64px; height: 64px; }
.co-ln .co-th img { width: 64px; height: 64px; border-radius: var(--r-sm); object-fit: cover; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.co-ln .co-th b { position: absolute; top: -7px; right: -7px; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--muted); color: var(--surface); font-size: 12px; display: grid; place-items: center; }
.co-ln small { display: block; color: var(--muted); font-size: 12.5px; }
.co-ln small.co-sup { color: var(--warn); }
.co-code { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.co-code .btn { height: 46px; border-radius: var(--r-sm); background: var(--surface); }
.co-ok { display: inline-flex; gap: 6px; align-items: center; font-size: 13px; color: var(--ok); font-weight: 600; }
.co-ok svg.i { width: 15px; height: 15px; stroke-width: 2.6; }
.co-bad { font-size: 13px; color: #D93025; }
.co-tot { display: grid; gap: 8px; font-size: 14px; border-top: 1px solid var(--line); padding-top: 16px; }
.co-tot div { display: flex; justify-content: space-between; gap: 12px; }
.co-tot .co-disc { color: var(--ok); }
.co-tot .co-gt { font-size: 19px; font-weight: 700; padding-top: 6px; }
.co-tot .co-gt small { font-size: 12px; font-weight: 500; color: var(--muted); margin-right: 4px; }
.co-tot p { margin: -4px 0 0; font-size: 12.5px; color: var(--muted); text-align: right; }
.co-note { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: var(--r); background: var(--surface); font-size: 13px; }
.co-note svg.i { color: var(--accent); }
.co-trust { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: 13px; color: var(--muted); }
.co-trust li { display: flex; gap: 10px; align-items: center; }
.co-trust svg.i { width: 17px; height: 17px; }
.co-done { display: grid; gap: 16px; justify-items: start; }
.co-done .co-okc { width: 56px; height: 56px; border-radius: 50%; background: color-mix(in oklab, var(--ok) 16%, var(--surface)); color: var(--ok); display: grid; place-items: center; }
.co-done .co-okc svg.i { width: 28px; height: 28px; stroke-width: 2.6; }
.co-done h2 { margin: 0; font-size: clamp(26px, 3vw, 36px); line-height: 1.08; }
.co-done > p { margin: 0; color: var(--muted); }
.co-done .co-steps { list-style: none; margin: 6px 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); width: 100%; font-size: 12.5px; color: var(--muted); }
.co-done .co-steps li { position: relative; padding-top: 18px; }
.co-done .co-steps li::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 4px; border-radius: 2px; background: var(--line); margin-right: 6px; }
.co-done .co-steps li.co-on { color: var(--ink); font-weight: 600; }
.co-done .co-steps li.co-on::before { background: var(--ok); }
.co-done .co-boxes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; width: 100%; }
.co-done .co-boxes div { padding: 14px; border-radius: var(--r); border: 1px solid var(--line); display: grid; gap: 3px; font-size: 13px; align-content: start; }
.co-done .co-boxes small { color: var(--muted); }
.co-done .co-boxes span { color: var(--muted); }
.co-done .co-iban { width: 100%; padding: 16px; border-radius: var(--r); background: var(--soft); font-size: 14px; }
.co-done .co-iban dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 18px; margin: 10px 0 0; }
.co-done .co-iban dt { color: var(--muted); }
.co-done .co-iban dd { margin: 0; font-weight: 600; }
.co-done .co-acts { display: flex; gap: 8px; flex-wrap: wrap; }
@media (max-width: 900px) {
  .drawer.xp { top: 0; right: 0; bottom: 0; width: 100%; border-radius: 0; margin: 0; }
  .co-bar { grid-template-columns: auto 1fr auto; padding-top: env(safe-area-inset-top, 0px); height: calc(58px + env(safe-area-inset-top, 0px)); }
  .co-bar .co-st { text-align: center; }
  .co-bar .co-secure > span, .co-bar .co-secure > svg.i { display: none; }
  .co { grid-template-columns: minmax(0, 1fr); background: var(--surface); }
  .co-main, .co-side { grid-column: auto; grid-row: auto; }
  .co-side { position: static; max-height: none; border-right: 0; justify-items: stretch; }
  .co-bar { padding: 0 14px; }
  .co-main { max-width: none; justify-self: stretch; padding: 22px 16px calc(40px + env(safe-area-inset-bottom, 0px)); order: 3; }
  .co-mobsum { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 14px 16px; background: var(--soft); border-bottom: 1px solid var(--line); font-size: 14px; font-weight: 600; color: var(--ink); order: 1; }
  .co-mobsum span { display: inline-flex; align-items: center; gap: 8px; }
  .co-mobsum svg.i { width: 18px; height: 18px; }
  .co-side { display: none; border-left: 0; padding: 18px 16px 22px; border-bottom: 1px solid var(--line); order: 2; }
  .co-side.open { display: grid; }
  .co-side > * { max-width: none; }
  .co-side h3 { display: none; }
  .co.co-dn .co-mobsum { display: none; }
  .co-done .co-boxes { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 480px) {
  .co-exp .co-xb { grid-template-columns: minmax(0, 1fr); }
  .co-g3 { grid-template-columns: 1fr 1fr; }
  .co-g3 .co-f:nth-child(2) { grid-column: 1 / -1; grid-row: 1; }
  .co-rd { grid-template-columns: auto minmax(0, 1fr) auto; gap: 10px; padding: 14px 12px; }
  .co-radios .co-rd > svg.i { display: none; }
  .co-pm .co-pb { padding-left: 16px; }
  .co-r3 { grid-template-columns: minmax(0, 1fr); }
  .co-done .co-steps { font-size: 11px; }
}

/* funzioni comuni a tutti i layout: percorso, sottocategorie, albero, menu del catalogo, confronto, IVA esclusa, marche.
   Colori, font, angoli e ombre dal tema; ogni layout può ridisegnarle con le stesse classi. */
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); }
.crumbs button:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.crumbs b { font-weight: 600; color: var(--ink); }
.crumbs span { opacity: .5; }
.subcats { display: flex; gap: 8px; flex-wrap: wrap; }
.subcats button { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: var(--pill); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); font-size: 13.5px; font-weight: 600; white-space: nowrap; }
.subcats button small { font-weight: 500; color: var(--muted); font-size: 12px; }
.subcats button:hover { box-shadow: inset 0 0 0 1px var(--ink); }
.subcats button[aria-pressed="true"] { background: var(--primary); color: var(--on-primary); box-shadow: none; }
.subcats button[aria-pressed="true"] small { color: inherit; opacity: .75; }
.ctree ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.ctree ul ul { padding-left: 14px; margin: 2px 0 6px; border-left: 1px solid var(--line); }
.ctree button { width: 100%; display: flex; justify-content: space-between; gap: 10px; padding: 6px 8px; border-radius: var(--r-sm); font-size: 14px; text-align: left; }
.ctree button small { color: var(--muted); font-size: 12px; }
.ctree button:hover { background: var(--soft); }
.ctree button[aria-pressed="true"] { font-weight: 700; background: color-mix(in oklab, var(--primary) 12%, transparent); }
.ctree .ct2, .ctree .ct3 { font-size: 13.5px; }
.catbtn { display: inline-flex; align-items: center; gap: 8px; }
.catbtn svg.i { width: 18px; height: 18px; }

.mega { position: fixed; z-index: 63; top: calc(10px + env(safe-area-inset-top, 0px)); left: 50%; transform: translateX(-50%); width: min(1180px, calc(100% - 20px)); max-height: calc(100% - 110px); display: flex; }
.mega-box { flex: 1; min-width: 0; display: flex; flex-direction: column; background: var(--surface); color: var(--ink); border-radius: var(--r-xl); box-shadow: var(--shadow-pop, 0 30px 80px -20px rgb(0 0 0 / .4)); overflow: hidden; animation: co-in .25s both ease-out; }
.mega-box > header { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.mega-box > header b { font-size: 22px; }
.mega-box > header .circle { background: var(--soft); }
.mega-in { display: grid; grid-template-columns: 260px minmax(0, 1fr) 240px; min-height: 0; overflow-y: auto; }
.mg-l1 { list-style: none; margin: 0; padding: 12px; display: grid; align-content: start; gap: 2px; border-right: 1px solid var(--line); }
.mg-l1 button { width: 100%; display: grid; grid-template-columns: 1fr auto auto; gap: 8px; align-items: center; padding: 12px 14px; border-radius: var(--r-sm); font-size: 15px; font-weight: 600; text-align: left; }
.mg-l1 button small { font-weight: 500; font-size: 12px; color: var(--muted); }
.mg-l1 button svg.i { width: 16px; height: 16px; opacity: .4; }
.mg-l1 button[aria-pressed="true"] { background: var(--soft); }
.mg-l1 button[aria-pressed="true"] svg.i { opacity: 1; }
.mg-l2 { padding: 20px 24px 26px; display: grid; align-content: start; gap: 18px; }
.mg-all { justify-self: start; display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 700; color: var(--acc-t, var(--primary)); }
.mg-all small { font-weight: 500; color: var(--muted); }
.mg-all svg.i { width: 16px; height: 16px; }
.mg-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px 26px; }
.mg-h { font-size: 15px; font-weight: 700; text-align: left; }
.mg-h:hover, .mg-col li button:hover { text-decoration: underline; text-underline-offset: 3px; }
.mg-col ul { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 7px; }
.mg-col li button { display: inline-flex; gap: 6px; font-size: 14px; color: color-mix(in oklab, var(--ink) 78%, transparent); text-align: left; }
.mg-col li button small { color: var(--muted); font-size: 12px; }
.mg-img { position: relative; margin: 14px; border-radius: var(--r); overflow: hidden; align-self: start; aspect-ratio: 4 / 5; }
.mg-img img { width: 100%; height: 100%; object-fit: cover; }
.mg-img span { position: absolute; left: 12px; bottom: 12px; padding: 6px 12px; border-radius: var(--pill); background: rgb(10 10 12 / .7); color: #FFFFFF; font-size: 13px; font-weight: 600; }

.cmpb { display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 600; color: color-mix(in oklab, var(--ink) 75%, transparent); }
.cmpb svg.i { width: 18px; height: 18px; }
.cmpb:hover { color: var(--ink); }
.cmpb[aria-pressed="true"] { color: var(--ink); }
.cmpb[aria-pressed="true"] svg.i { color: var(--acc-t, var(--primary)); }
.cmpbar { position: fixed; z-index: 56; right: calc(14px + env(safe-area-inset-right, 0px)); bottom: calc(14px + env(safe-area-inset-bottom, 0px)); display: flex; align-items: center; gap: 12px; padding: 8px 8px 8px 10px; border-radius: var(--r-xl); background: var(--surface); color: var(--ink); box-shadow: 0 0 0 1px var(--line), 0 20px 50px -20px rgb(0 0 0 / .35); }
.cmpbar .cb-th { display: flex; }
.cmpbar .cb-th img { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; background: var(--soft); box-shadow: 0 0 0 2px var(--surface); margin-left: -10px; }
.cmpbar .cb-th img:first-child { margin-left: 0; }
.cmpbar .cb-t { display: grid; font-size: 13.5px; line-height: 1.25; }
.cmpbar .cb-t small { color: var(--muted); font-size: 12px; }
.cmpbar .btn { height: 40px; padding: 0 18px; font-size: 13.5px; }
.cmpbar .btn[disabled] { opacity: .45; cursor: default; transform: none; }
.cmpbar .circle { background: var(--soft); }
.cmpv { position: fixed; inset: 0; z-index: 64; display: flex; flex-direction: column; background: var(--canvas); color: var(--ink); }
.cv-scroll { flex: 1; overflow: auto; }
.cv { max-width: 1180px; margin: 0 auto; padding: 28px 18px 110px; }
.cv-t { width: 100%; min-width: calc(160px + var(--n) * 200px); border-collapse: separate; border-spacing: 0; background: var(--surface); border-radius: var(--r-xl); overflow: hidden; box-shadow: 0 0 0 1px var(--line); }
.cv-t th, .cv-t td { padding: 14px 16px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); font-size: 14px; }
.cv-t tbody th { width: 160px; font-weight: 600; color: var(--muted); font-size: 13px; }
.cv-t thead th { position: relative; font-weight: 400; display: table-cell; }
.cv-t thead th > * { display: block; }
.cv-t .cv-p img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: var(--r); background: var(--soft); margin-bottom: 10px; }
.cv-t .cv-p b { font-size: 15px; line-height: 1.3; text-align: left; }
.cv-t .cv-pr { margin-top: 8px; font-size: 18px; font-weight: 700; }
.cv-t .avail { margin: 8px 0 12px; display: inline-flex; }
.cv-t .btn { height: 42px; width: 100%; font-size: 13.5px; }
.cv-t .cv-rm { position: absolute; top: 22px; right: 24px; background: var(--surface); box-shadow: 0 2px 8px rgb(0 0 0 / .15); z-index: 1; }

.vatx { display: block; font-size: 12.5px; font-weight: 500; color: var(--muted); letter-spacing: 0; font-family: var(--f-b); text-transform: none; }
.ln .price .vatx { font-size: 11.5px; margin-top: 2px; }
.dfoot .row.vatr { font-size: 12.5px; margin-top: -6px; }

.brands-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; }
.brands-row button { display: grid; gap: 4px; justify-items: center; padding: 24px 12px; border-radius: var(--r); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow .2s; }
.brands-row button:hover { box-shadow: inset 0 0 0 1px var(--ink); }
.brands-row b { font-size: 24px; line-height: 1; }
.brands-row small { font-size: 12px; color: var(--muted); }

@media (max-width: 760px) {
  .mega { top: 0; left: 0; transform: none; width: 100%; max-height: none; bottom: 0; }
  .mega-box { border-radius: 0; padding-top: env(safe-area-inset-top, 0px); }
  .mega-in { grid-template-columns: minmax(0, 1fr); align-content: start; }
  .mg-l1 { border-right: 0; border-bottom: 1px solid var(--line); grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .mg-l1 button { padding: 10px 12px; font-size: 14px; grid-template-columns: 1fr auto; }
  .mg-l1 button svg.i { display: none; }
  .mg-l2 { padding: 16px 18px 90px; }
  .mg-cols { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .mg-img { display: none; }
  .cmpbar { left: 10px; right: 10px; bottom: calc(66px + env(safe-area-inset-bottom, 0px)); }
  .cmpbar .cb-t { flex: 1; }
  .cv { padding: 18px 12px 110px; }
  .cv-t tbody th { width: 110px; }
  .cv-t { min-width: calc(110px + var(--n) * 160px); }
}
