/* Big Print Project — "insegna a pennarello": forex bianco, inchiostro viola, pennarello nei colori del logo. */

@font-face {
  font-family: "Archivo";
  src: url("../fonts/archivo.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Archivo";
  src: url("../fonts/archivo-italic.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Permanent Marker";
  src: url("../fonts/permanent-marker.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #ffffff;
  --paper-2: #f7f6fb;
  --ink: #2b2170;
  --ink-deep: #1c1650;
  --ink-2: #5d5786;
  --rule: #e2e0ee;
  --rule-2: #cfccdf;
  --yellow: #ffd200;
  --yellow-deep: #e6bd00;
  --yellow-ink: #3a3100;
  --cyan: #00a9e0;
  --cyan-deep: #0084b0;
  --magenta: #e5007e;
  --orange: #f7941d;
  --green: #2aa84a;
  --red-list: #d81f26;
  --blue-list: #1e4fb5;
  --shadow-slab: 0 14px 30px -12px rgba(43, 33, 112, 0.28), 0 3px 6px rgba(43, 33, 112, 0.08);
  --shadow-slab-sm: 0 8px 18px -8px rgba(43, 33, 112, 0.22), 0 1px 3px rgba(43, 33, 112, 0.08);
  --font: "Archivo", system-ui, -apple-system, "Segoe UI", sans-serif;
  --marker: "Permanent Marker", "Archivo", sans-serif;
  --wrap: 1200px;
  --gutter: clamp(16px, 4vw, 40px);
  --r: 3px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--paper);
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1, "kern" 1;
}

::selection { background: var(--yellow); color: var(--ink-deep); }
:focus-visible { outline: 3px solid var(--cyan); outline-offset: 2px; border-radius: 2px; }
a { color: var(--cyan-deep); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { color: var(--ink); }
img { max-width: 100%; height: auto; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { margin: 0; line-height: 1.1; font-weight: 700; letter-spacing: -0.01em; text-wrap: balance; }
p { margin: 0 0 0.9em; }
small { font-size: 0.85em; }
code { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 0.9em; background: var(--paper-2); padding: 0 4px; border-radius: 2px; }

.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 14px; z-index: 100; }
.skip:focus { left: 8px; }

.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }

/* ----- pennarello ----- */
.marker {
  font-family: var(--marker);
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.05;
  color: var(--ink);
}
h1.marker { font-size: clamp(2.1rem, 1.3rem + 3.2vw, 3.6rem); margin-bottom: 0.35em; }
h2.marker { font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.2rem); margin-bottom: 0.4em; }
.lead { font-size: 1.125rem; color: var(--ink-2); max-width: 62ch; margin-bottom: 1.4em; }

/* tratto di sottolineatura a pennarello (stato attivo) */
.u-stroke { position: relative; }
.u-stroke::after {
  content: "";
  position: absolute; left: -2%; right: -2%; bottom: -3px; height: 8px;
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 8' preserveAspectRatio='none'><path d='M1 5 C 20 2, 40 7, 60 4 S 90 3, 99 5' fill='none' stroke='%2300a9e0' stroke-width='3.2' stroke-linecap='round'/></svg>") no-repeat center / 100% 100%;
  pointer-events: none;
}

/* ----- lastre di forex ----- */
.slab {
  position: relative;
  background: var(--paper);
  border-radius: var(--r);
  box-shadow: var(--shadow-slab);
  padding: 26px 24px 24px;
}
.slab--yellow { background: var(--yellow); color: var(--yellow-ink); }
.slab--yellow a { color: var(--ink-deep); }
.slab--yellow .marker { color: var(--ink-deep); }
.slab--white { background: var(--paper); }
.tape {
  position: absolute; top: -11px; left: 50%; width: 78px; height: 22px;
  transform: translateX(-50%) rotate(-2deg);
  background: rgba(255, 248, 200, 0.72);
  border: 1px solid rgba(43, 33, 112, 0.08);
  box-shadow: 0 1px 2px rgba(43, 33, 112, 0.12);
  border-radius: 1px;
  pointer-events: none;
}
.slab--yellow .tape { background: rgba(255, 255, 255, 0.55); }

/* ----- pulsanti ----- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 18px; border-radius: 4px; border: 2px solid var(--ink);
  font-weight: 700; text-decoration: none; cursor: pointer; line-height: 1.2;
  transition: background-color 140ms ease-out, color 140ms ease-out, transform 140ms ease-out, box-shadow 140ms ease-out;
}
.btn--ink { background: var(--ink); color: #fff; }
.btn--ink:hover { background: var(--ink-deep); color: #fff; box-shadow: 0 6px 14px -6px rgba(43, 33, 112, 0.5); }
.btn--ink:active { transform: translateY(1px); }
.btn--ghost { background: transparent; color: var(--ink); }
.btn--ghost:hover { background: rgba(43, 33, 112, 0.06); color: var(--ink); }
.btn--danger { border-color: var(--magenta); color: var(--magenta); }
.btn--danger:hover { background: rgba(229, 0, 126, 0.08); color: var(--magenta); }
.btn--big { width: 100%; padding: 15px 20px; font-size: 1.05rem; }
.btn--sm { padding: 6px 12px; font-size: 0.9rem; border-width: 1.5px; }
.btn[disabled] { cursor: not-allowed; box-shadow: none; transform: none; }
.btn--ink[disabled] { background: rgba(43, 33, 112, 0.28); border-color: transparent; color: rgba(255, 255, 255, 0.9); }
.link-quiet { color: var(--ink-2); }

/* ----- testata ----- */
.top { position: sticky; top: 0; z-index: 50; background: var(--paper); box-shadow: 0 1px 0 var(--rule); }
.top__in { display: flex; align-items: center; gap: 24px; min-height: 72px; }
.brand { display: block; flex: 0 0 auto; }
.brand img { display: block; width: auto; height: 46px; }
.nav { display: flex; align-items: center; gap: 4px 22px; margin-left: auto; flex-wrap: wrap; }
.nav > a { color: var(--ink); text-decoration: none; font-weight: 600; padding: 6px 2px; position: relative; }
.nav > a:hover { color: var(--cyan-deep); }
.nav > a.is-active::after {
  content: ""; position: absolute; left: -3%; right: -3%; bottom: -1px; height: 8px;
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 8' preserveAspectRatio='none'><path d='M1 5 C 20 2, 40 7, 60 4 S 90 3, 99 5' fill='none' stroke='%2300a9e0' stroke-width='3.2' stroke-linecap='round'/></svg>") no-repeat center / 100% 100%;
}
.nav__admin { color: var(--orange) !important; }
.tray {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 12px 8px 10px; border-radius: 4px; border: 2px solid var(--ink);
  color: var(--ink) !important; text-decoration: none; font-weight: 700;
}
.tray.has-items { background: var(--yellow); border-color: var(--yellow-deep); color: var(--ink-deep) !important; }
.tray__n { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--ink); color: #fff; font-size: 0.85rem; display: inline-grid; place-items: center; }
.tray.is-bump { animation: bump 360ms cubic-bezier(0.16, 1, 0.3, 1); }
@keyframes bump { 0% { transform: scale(1); } 40% { transform: scale(1.12); } 100% { transform: scale(1); } }
.top__burger { display: none; margin-left: auto; width: 44px; height: 44px; border: 0; background: transparent; border-radius: 4px; padding: 10px; flex-direction: column; justify-content: space-between; cursor: pointer; }
.top__burger span { display: block; height: 3px; background: var(--ink); border-radius: 2px; }
.top__burger .sr { height: 1px; }

.ribbon { font-size: 0.92rem; padding: 7px var(--gutter); }
.ribbon--wait { background: #fff4d6; color: var(--yellow-ink); }
.ribbon--reseller { background: var(--ink); color: #fff; }
.ribbon--reseller strong { color: var(--yellow); }

.flash { margin-top: 16px; padding: 12px 16px; border-radius: var(--r); font-weight: 600; }
.flash--ok { background: #e6f7ec; color: #145a2a; }
.flash--err { background: #fde7f1; color: #8f004f; }

/* ----- hero ----- */
.hero { display: grid; grid-template-columns: minmax(0, 45fr) minmax(0, 55fr); gap: clamp(24px, 4vw, 56px); align-items: start; padding-top: clamp(28px, 5vw, 64px); padding-bottom: clamp(28px, 4vw, 56px); }
.hero__copy { padding-top: 12px; }
.hero__lead { font-size: 1.2rem; color: var(--ink-2); max-width: 44ch; margin-bottom: 1.6em; }
.hero__res { color: var(--ink-2); font-size: 0.98rem; max-width: 46ch; margin-top: 1.6em; }
.cats { display: flex; flex-wrap: wrap; gap: 8px 10px; }
.cats__a {
  display: inline-flex; align-items: baseline; gap: 6px;
  padding: 8px 12px; border: 1.5px solid var(--rule-2); border-radius: 4px;
  color: var(--ink); text-decoration: none; font-weight: 600; font-size: 0.95rem;
  transition: border-color 120ms ease-out, background-color 120ms ease-out;
}
.cats__a small { color: var(--ink-2); font-weight: 500; }
.cats__a:hover { border-color: var(--ink); background: var(--paper-2); color: var(--ink); }
.cats__a.tint-red:hover { border-color: var(--red-list); }
.cats__a.tint-blue:hover { border-color: var(--blue-list); }
.hero__calc { min-width: 0; }

/* ----- calcolatore ----- */
.calc { padding: 28px 26px 24px; }
.calc__title { font-family: var(--marker); font-weight: 400; font-size: clamp(1.7rem, 1.2rem + 1.4vw, 2.3rem); color: var(--ink-deep); }
.calc__list { color: rgba(58, 49, 0, 0.75); font-size: 0.9rem; margin: 2px 0 18px; }
.calc__row { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 8px 14px; align-items: start; padding: 10px 0; border-top: 1px solid rgba(43, 33, 112, 0.14); }
.calc__row[hidden] { display: none; }
.calc__lab { font-weight: 700; padding-top: 9px; font-size: 0.95rem; }
.calc__fields { min-width: 0; }
.calc__fields--2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; }
.calc select, .calc input[type="text"], .calc input[type="number"] {
  width: 100%; padding: 9px 10px; border: 2px solid rgba(43, 33, 112, 0.35); border-radius: 4px; background: #fff; color: var(--ink);
  min-height: 42px;
}
.calc select:focus, .calc input:focus { border-color: var(--ink); outline: 3px solid rgba(0, 169, 224, 0.45); outline-offset: 0; }
.formats { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.formats[hidden] { display: none; }
.chip {
  display: inline-flex; flex-direction: column; align-items: center; line-height: 1.1;
  padding: 6px 10px; border: 2px solid rgba(43, 33, 112, 0.35); border-radius: 4px; background: rgba(255, 255, 255, 0.7);
  cursor: pointer; color: var(--ink); transition: background-color 120ms ease-out, border-color 120ms ease-out;
}
.chip__k { font-weight: 700; font-size: 0.92rem; }
.chip__p { font-size: 0.8rem; color: var(--ink-2); }
.chip:hover { background: #fff; border-color: var(--ink); }
.chip.is-on { background: var(--ink); border-color: var(--ink); color: #fff; }
.chip.is-on .chip__p { color: var(--yellow); }
.dims { display: flex; align-items: flex-end; gap: 8px; flex-wrap: wrap; }
.dims__f { display: grid; gap: 3px; width: 116px; }
.dims__f--wide { width: 170px; }
.dims__f > span { font-size: 0.78rem; font-weight: 600; color: rgba(58, 49, 0, 0.8); }
.dims__f { position: relative; }
.dims__f em { position: absolute; right: 10px; bottom: 11px; font-style: normal; font-size: 0.85rem; color: var(--ink-2); pointer-events: none; }
.dims__f input { padding-right: 34px !important; font-weight: 700; font-size: 1.05rem; }
.dims__x { font-size: 1.3rem; padding-bottom: 8px; color: var(--ink-2); }
.dims__area { padding-bottom: 10px; font-weight: 700; color: var(--ink-deep); }
.check { display: inline-flex; align-items: center; gap: 8px; padding: 6px 0; cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--ink); }
.check em { font-style: normal; color: var(--ink-2); font-size: 0.9rem; }
.qty { display: inline-flex; align-items: center; gap: 0; }
.qty__b { width: 42px; height: 42px; border: 2px solid rgba(43, 33, 112, 0.35); background: #fff; font-size: 1.3rem; font-weight: 700; cursor: pointer; border-radius: 4px 0 0 4px; }
.qty__b + input { border-radius: 0 !important; border-left: 0 !important; border-right: 0 !important; width: 78px !important; text-align: center; font-weight: 700; -moz-appearance: textfield; }
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.qty__b:last-of-type { border-radius: 0 4px 4px 0; }
.qty__u { margin-left: 10px; color: var(--ink-2); }

.calc__result { border-top: 2px solid rgba(43, 33, 112, 0.35); margin-top: 6px; padding-top: 14px; min-height: 96px; }
.calc__breakdown { font-size: 0.92rem; color: rgba(58, 49, 0, 0.85); margin-bottom: 4px; min-height: 1.4em; }
.calc__total { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin: 0; }
.calc__total-n { font-family: var(--marker); font-size: clamp(2.2rem, 1.6rem + 2.4vw, 3.4rem); line-height: 1; color: var(--ink-deep); display: inline-block; }
.calc__total-n.is-writing { animation: writing 420ms cubic-bezier(0.16, 1, 0.3, 1) both; }
@keyframes writing { from { clip-path: inset(0 100% -10% 0); } to { clip-path: inset(0 -2% -10% 0); } }
.calc__total-vat { color: rgba(58, 49, 0, 0.8); font-weight: 600; }
.calc__err { color: var(--magenta); font-weight: 700; margin: 6px 0 0; }
.calc__note { font-size: 0.88rem; color: rgba(58, 49, 0, 0.8); margin: 6px 0 0; }
.calc__actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.calc.is-busy .calc__total-n { opacity: 0.6; }
@media (prefers-reduced-motion: reduce) { .calc__total-n.is-writing, .tray.is-bump { animation: none; } }

/* ----- listino ----- */
.listino { padding-block: clamp(20px, 3vw, 40px); }
.listino__head { max-width: 70ch; margin-bottom: 20px; }
.listino__head p { color: var(--ink-2); }
.jump { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: -6px 0 22px; font-size: 0.95rem; }
.jump a { font-weight: 600; }
.list { margin: 0 0 40px; scroll-margin-top: 90px; }
.list__head { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 20px; align-items: end; margin-bottom: 10px; }
.list__title { font-family: var(--marker); font-weight: 400; font-size: clamp(1.4rem, 1.1rem + 1.2vw, 1.9rem); grid-column: 1; position: relative; display: inline-block; padding-bottom: 4px; }
.list__title::after {
  content: ""; position: absolute; left: 0; width: 100%; bottom: -2px; height: 8px;
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 8' preserveAspectRatio='none'><path d='M1 5 C 20 2, 40 7, 60 4 S 90 3, 99 5' fill='none' stroke='%23d81f26' stroke-width='3' stroke-linecap='round'/></svg>") no-repeat center / 100% 100%;
}
.tint-blue .list__title::after { background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 8' preserveAspectRatio='none'><path d='M1 5 C 20 2, 40 7, 60 4 S 90 3, 99 5' fill='none' stroke='%231e4fb5' stroke-width='3' stroke-linecap='round'/></svg>"); }
.list__intro { grid-column: 1; color: var(--ink-2); margin: 0; max-width: 78ch; }
.list__more { grid-column: 2; grid-row: 1 / 3; align-self: end; white-space: nowrap; font-weight: 600; }
.list__foot { font-size: 0.9rem; color: var(--ink-2); margin: 8px 0 0; }
.tbl-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; margin-inline: calc(-1 * var(--gutter)); padding-inline: var(--gutter); }
.tbl { width: 100%; border-collapse: collapse; font-size: 0.95rem; min-width: 560px; }
.tbl th, .tbl td { padding: 8px 8px; border-bottom: 1px solid var(--rule); text-align: left; vertical-align: middle; }
.tbl thead th { font-size: 0.78rem; font-weight: 700; color: var(--ink-2); background: var(--paper-2); border-bottom: 2px solid var(--rule-2); white-space: nowrap; }
.tint-red .tbl thead th { color: var(--red-list); }
.tint-blue .tbl thead th { color: var(--blue-list); }
.tbl tbody th { font-weight: 600; }
.tbl__name { min-width: 200px; }
.tbl__num { text-align: right !important; white-space: nowrap; }
.tbl__unit { font-weight: 700; }
.tbl__f { width: 78px; }
.tbl__act { width: 1%; text-align: right !important; }
.tbl__dash { color: var(--rule-2); }
.tbl tbody tr:hover { background: #fffbe0; }
.tbl__check { display: inline-block; margin-left: 6px; font-size: 0.72rem; font-weight: 700; color: var(--orange); border: 1px solid var(--orange); border-radius: 3px; padding: 0 5px; vertical-align: middle; }
.pick { background: none; border: 0; padding: 4px 6px; margin: -4px -6px; border-radius: 3px; color: var(--ink); font-weight: 700; cursor: pointer; font-variant-numeric: tabular-nums; }
.pick small { font-weight: 500; color: var(--ink-2); }
.pick:hover { background: var(--yellow); color: var(--ink-deep); }
.pick--quote { font-weight: 500; color: var(--ink-2); font-style: italic; }
.pick--go { background: var(--ink); color: #fff; padding: 6px 10px; margin: 0; font-size: 0.85rem; border-radius: 4px; }
.pick--go:hover { background: var(--ink-deep); color: var(--yellow); }
.tbl--orders { min-width: 460px; }

/* ----- due colonne ----- */
.two { display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: clamp(24px, 4vw, 48px); padding-block: clamp(24px, 4vw, 48px); align-items: start; }
.two__side { position: sticky; top: 88px; }
.two--cart { grid-template-columns: minmax(0, 1fr) 380px; }
.crumbs { font-size: 0.9rem; color: var(--ink-2); margin-bottom: 8px; }
.prose { max-width: 70ch; font-size: 1.05rem; margin-bottom: 28px; }
.prose p { margin-bottom: 1em; }
.back { margin-top: 20px; }
.faq { margin-top: 48px; max-width: 72ch; }
.faq__i { border-top: 1px solid var(--rule); padding: 12px 0; }
.faq__i:last-child { border-bottom: 1px solid var(--rule); }
.faq__i summary { cursor: pointer; font-weight: 700; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq__i summary::-webkit-details-marker { display: none; }
.faq__i summary::after { content: "+"; color: var(--cyan); font-weight: 700; font-size: 1.3rem; line-height: 1; }
.faq__i[open] summary::after { content: "–"; }
.faq__i p { margin: 10px 0 0; color: var(--ink-2); }

/* ----- come funziona ----- */
.how { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(24px, 4vw, 56px); padding-block: clamp(32px, 5vw, 64px); border-top: 1px solid var(--rule); }
.steps { margin: 0 0 20px; padding: 0 0 0 1.4em; }
.steps li { margin-bottom: 8px; }
.steps li::marker { font-family: var(--marker); color: var(--cyan-deep); }
.how__where { color: var(--ink-2); }

/* ----- schede prodotto (indice) ----- */
.sheets { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 28px 24px; margin: 28px 0 40px; }
.sheet { position: relative; display: block; padding: 26px 22px 22px; text-decoration: none; color: var(--ink); background: var(--paper); border-radius: var(--r); box-shadow: var(--shadow-slab-sm); transition: transform 160ms ease-out, box-shadow 160ms ease-out; }
.sheet:hover { transform: translateY(-2px); box-shadow: var(--shadow-slab); color: var(--ink); }
.sheet h2 { font-family: var(--marker); font-weight: 400; font-size: 1.45rem; margin-bottom: 8px; position: relative; display: inline-block; padding-bottom: 3px; }
.sheet h2::after { content: ""; position: absolute; left: 0; width: 100%; bottom: -1px; height: 7px; background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 8' preserveAspectRatio='none'><path d='M1 5 C 20 2, 40 7, 60 4 S 90 3, 99 5' fill='none' stroke='%23d81f26' stroke-width='3' stroke-linecap='round'/></svg>") no-repeat center / 100% 100%; }
.sheet.tint-blue h2::after { background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 8' preserveAspectRatio='none'><path d='M1 5 C 20 2, 40 7, 60 4 S 90 3, 99 5' fill='none' stroke='%231e4fb5' stroke-width='3' stroke-linecap='round'/></svg>"); }
.sheet p { color: var(--ink-2); font-size: 0.95rem; }
.sheet__n { font-weight: 700; font-size: 0.85rem; }

/* ----- form ----- */
.form h2 { font-size: 1.35rem; margin-bottom: 14px; }
.f { display: grid; gap: 4px; margin-bottom: 12px; }
.f > span { font-size: 0.85rem; font-weight: 700; color: var(--ink-2); }
.f input, .f select, .f textarea { width: 100%; padding: 10px 11px; border: 2px solid var(--rule-2); border-radius: 4px; background: #fff; min-height: 44px; }
.f textarea { min-height: 72px; resize: vertical; }
.f input:focus, .f select:focus, .f textarea:focus { border-color: var(--ink); outline: 3px solid rgba(0, 169, 224, 0.4); outline-offset: 0; }
.f.is-err input, .f.is-err textarea { border-color: var(--magenta); }
.f em { font-style: normal; font-size: 0.85rem; color: var(--magenta); font-weight: 600; }
.f--hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.f--inline { display: inline-grid; grid-auto-flow: column; align-items: center; gap: 8px; margin: 0; }
.f--inline > span { padding-right: 2px; }
.f--qty input { width: 110px; }
.f__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 14px; }
.f__grid--1 { grid-template-columns: 1fr; }
.f--wide { grid-column: 1 / -1; }
.form__err { background: #fde7f1; color: #8f004f; padding: 10px 12px; border-radius: 4px; font-weight: 600; }
.form__hint { font-size: 0.88rem; color: var(--ink-2); margin: 12px 0 0; }
.slab--yellow .form__hint { color: rgba(58, 49, 0, 0.8); }
.slab--yellow .f > span { color: rgba(58, 49, 0, 0.85); }
.slab--yellow .f input, .slab--yellow .f textarea, .slab--yellow .f select { border-color: rgba(43, 33, 112, 0.35); }
.tabs { display: flex; gap: 0; border-bottom: 2px solid var(--rule-2); margin-bottom: 26px; }
.tabs a { padding: 10px 18px; font-weight: 700; text-decoration: none; color: var(--ink-2); margin-bottom: -2px; border-bottom: 3px solid transparent; }
.tabs a[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--ink); }
.auth { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(24px, 5vw, 64px); padding-block: clamp(28px, 5vw, 64px); }
.notice h2 { font-size: 1.3rem; margin-bottom: 8px; }
.contact__dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; margin: 0 0 16px; }
.contact__dl dt { font-weight: 700; color: var(--ink-2); }
.contact__dl dd { margin: 0; }
.contact__dl--2 { grid-template-columns: max-content 1fr; }
.map { aspect-ratio: 4 / 3; border-radius: var(--r); overflow: hidden; box-shadow: var(--shadow-slab); }
.map iframe { width: 100%; height: 100%; border: 0; display: block; }
.status { display: inline-block; font-family: var(--font); letter-spacing: 0; padding: 2px 8px; border-radius: 3px; font-size: 0.8rem; font-weight: 700; background: var(--paper-2); color: var(--ink-2); vertical-align: middle; }
.status--nuovo, .status--pending { background: #fff4d6; color: #6b5300; }
.status--in_produzione { background: #e3f4fb; color: #0a5f80; }
.status--pronto, .status--approved { background: #e6f7ec; color: #145a2a; }
.status--consegnato { background: var(--paper-2); color: var(--ink-2); }
.status--annullato, .status--rejected { background: #fde7f1; color: #8f004f; }
.empty { color: var(--ink-2); }
.empty-slab h2 { font-size: 1.4rem; margin-bottom: 8px; }
.thanks { padding-block: clamp(28px, 6vw, 72px); max-width: 720px; }

/* ----- ordine ----- */
.lines { display: grid; gap: 28px; }
.line { padding-top: 24px; }
.line__head { display: flex; justify-content: space-between; gap: 12px; align-items: start; }
.line__title { font-size: 1.15rem; }
.line__n { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--ink); color: #fff; font-family: var(--marker); font-size: 0.95rem; margin-right: 4px; vertical-align: 2px; }
.line__x { background: none; border: 0; color: var(--ink-2); text-decoration: underline; cursor: pointer; padding: 2px 4px; }
.line__x:hover { color: var(--magenta); }
.line__cat { color: var(--ink-2); font-size: 0.9rem; margin: 2px 0 6px; }
.line__math { font-size: 0.92rem; background: var(--paper-2); padding: 8px 10px; border-radius: 3px; margin-bottom: 12px; }
.line__grid { display: flex; justify-content: space-between; align-items: end; gap: 16px; flex-wrap: wrap; margin-bottom: 10px; }
.line__tot { margin: 0 0 12px; text-align: right; }
.line__tot strong { font-family: var(--marker); font-weight: 400; font-size: 1.6rem; display: block; line-height: 1; }
.line__tot span { color: var(--ink-2); font-size: 0.85rem; }
.lines__actions { display: flex; gap: 10px; flex-wrap: wrap; }
.files { margin: 6px 0 12px; }
.files__lab { font-weight: 700; margin-bottom: 6px; }
.files__lab small { display: block; font-weight: 500; color: var(--ink-2); }
.files__list { list-style: none; margin: 0 0 8px; padding: 0; display: grid; gap: 4px; }
.files__list li { display: flex; align-items: center; gap: 10px; padding: 6px 10px; background: var(--paper-2); border-radius: 3px; font-size: 0.92rem; }
.files__name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.files__size { color: var(--ink-2); font-size: 0.85rem; white-space: nowrap; }
.files__rm { border: 0; background: none; color: var(--ink-2); font-size: 1.2rem; line-height: 1; cursor: pointer; padding: 0 4px; }
.files__rm:hover { color: var(--magenta); }
.files__none { color: var(--ink-2); font-size: 0.9rem; }
.drop { display: block; position: relative; border: 2px dashed var(--rule-2); border-radius: 4px; padding: 18px 14px; text-align: center; cursor: pointer; color: var(--ink-2); transition: border-color 120ms ease-out, background-color 120ms ease-out; }
.drop input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.drop:hover, .drop.is-over { border-color: var(--cyan); background: #f0f9fd; color: var(--ink); }
.drop__p { display: block; margin-top: 8px; font-weight: 700; color: var(--ink); }
.files__err { color: var(--magenta); font-weight: 600; font-size: 0.9rem; margin: 6px 0 0; }
.summary h2 { font-size: 1.6rem; margin-bottom: 12px; }
.summary__dl { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; margin: 0 0 16px; padding-bottom: 12px; border-bottom: 2px solid rgba(43, 33, 112, 0.3); }
.summary__dl dt { color: rgba(58, 49, 0, 0.85); }
.summary__dl dd { margin: 0; text-align: right; font-weight: 700; }
.summary__tot { font-family: var(--marker); font-weight: 400 !important; font-size: 1.35rem; color: var(--ink-deep) !important; padding-top: 6px; }
.toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 4px; box-shadow: 0 10px 30px rgba(28, 22, 80, 0.4); z-index: 60; max-width: min(92vw, 560px); font-weight: 600; animation: toast-in 260ms cubic-bezier(0.16, 1, 0.3, 1) both; }
.toast a { color: var(--yellow); }
.toast.is-out { opacity: 0; transition: opacity 300ms; }
@keyframes toast-in { from { transform: translate(-50%, 12px); opacity: 0; } to { transform: translate(-50%, 0); opacity: 1; } }

/* ----- admin ----- */
.admin { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 32px; padding-block: 28px; align-items: start; }
.admin__nav { display: grid; gap: 2px; position: sticky; top: 88px; }
.admin__nav a { padding: 8px 10px; border-radius: 3px; text-decoration: none; color: var(--ink); font-weight: 600; }
.admin__nav a:hover { background: var(--paper-2); }
.admin__nav a[aria-current="page"] { background: var(--ink); color: #fff; }
.admin__sec { margin: 28px 0; }
.admin__sec h2 { font-size: 1.25rem; margin-bottom: 12px; display: flex; align-items: center; gap: 10px; }
.admin__sec.slab { padding-top: 28px; }
.pill { display: inline-grid; place-items: center; min-width: 24px; height: 24px; padding: 0 7px; border-radius: 12px; background: var(--magenta); color: #fff; font-size: 0.8rem; font-weight: 700; }
.admin__filters { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 16px; }
.admin__filters input, .admin__filters select { padding: 8px 10px; border: 2px solid var(--rule-2); border-radius: 4px; min-height: 40px; }
.admin__actions { display: flex; flex-wrap: wrap; gap: 14px 22px; align-items: center; padding: 14px 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); margin: 8px 0 14px; }
.inline { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.tbl--admin { min-width: 640px; }
.tbl--admin td small { color: var(--ink-2); }
.tbl--edit { min-width: 900px; }
.tbl--edit tr.is-off { opacity: 0.5; }
.tbl--edit tr.is-addon td { background: #fffbe0; }
.pin { width: 76px; padding: 5px 6px; border: 1.5px solid var(--rule-2); border-radius: 3px; text-align: right; font-variant-numeric: tabular-nums; }
.pin:focus { border-color: var(--ink); outline: 2px solid rgba(0, 169, 224, 0.45); outline-offset: 0; }
.pin-lab { display: inline-flex; align-items: center; gap: 4px; margin-right: 8px; font-size: 0.85rem; white-space: nowrap; }
.sticky-save { position: sticky; bottom: 0; padding: 12px 0; background: linear-gradient(to top, #fff 70%, rgba(255, 255, 255, 0)); }
.regen { margin: 8px 0 24px; }
.regen h2 { font-size: 1.2rem; margin-bottom: 6px; }

/* ----- piede ----- */
.foot { border-top: 3px solid var(--ink); margin-top: clamp(32px, 6vw, 72px); background: var(--paper-2); }
.foot__in { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px 48px; padding-block: 36px 28px; }
.foot__who p { margin-bottom: 6px; color: var(--ink-2); }
.foot__name { font-family: var(--marker); font-size: 1.3rem; color: var(--ink); }
.foot__links { display: grid; gap: 6px; align-content: start; }
.foot__links a { font-weight: 600; }
.foot__legal { grid-column: 1 / -1; font-size: 0.85rem; color: var(--ink-2); border-top: 1px solid var(--rule); padding-top: 14px; margin: 0; }

/* ----- responsive ----- */
@media (max-width: 1080px) {
  .two, .two--cart { grid-template-columns: minmax(0, 1fr) 340px; }
}
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; }
  .hero__calc { order: -1; }
  .two, .two--cart { grid-template-columns: 1fr; }
  .two__side { position: static; }
  .page-listino .two__side, .page-sheet .two__side { order: -1; }
  .how { grid-template-columns: 1fr; }
  .auth { grid-template-columns: 1fr; }
  .admin { grid-template-columns: 1fr; }
  .admin__nav { position: static; grid-auto-flow: column; overflow-x: auto; }
}
@media (max-width: 780px) {
  .top__burger { display: flex; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--paper); box-shadow: 0 12px 24px -8px rgba(43, 33, 112, 0.25); padding: 12px var(--gutter) 18px; flex-direction: column; align-items: stretch; gap: 2px; }
  .nav.is-open { display: flex; }
  .nav > a { padding: 10px 6px; border-bottom: 1px solid var(--rule); }
  .nav > a.is-active::after { display: none; }
  .nav > a.is-active { color: var(--cyan-deep); }
  .tray { margin-top: 8px; justify-content: center; }
  .brand img { height: 38px; }
  .list__head { grid-template-columns: 1fr; }
  .list__more { grid-column: 1; grid-row: auto; }
  .f__grid { grid-template-columns: 1fr; }
  .foot__in { grid-template-columns: 1fr; }
  .calc__row { grid-template-columns: 1fr; gap: 4px; }
  .calc__lab { padding-top: 0; }
  .calc__fields--2 { grid-template-columns: 1fr; }
}
@media (max-width: 420px) {
  .calc { padding: 22px 16px 18px; }
  .dims__f { width: calc(50% - 20px); }
  .dims__area { width: 100%; padding: 0; }
}
@media print {
  .top, .foot, .calc__actions, .lines__actions, .tray, .pick--go { display: none !important; }
  .slab { box-shadow: none; border: 1px solid #ccc; }
  .two { grid-template-columns: 1fr; }
}

/* hint scorrimento tabelle (solo schermi stretti) */
.tbl-hint { display: none; font-size: 0.85rem; color: var(--ink-2); margin: 0 0 6px; }
@media (max-width: 780px) { .tbl-hint { display: block; } }

/* segno di categoria: stesso colore della tabella corrispondente */
.cats__a::before { content: ""; width: 14px; height: 5px; border-radius: 3px; background: var(--red-list); transform: rotate(-4deg); align-self: center; }
.cats__a.tint-blue::before { background: var(--blue-list); }
.u-stroke { display: inline-block; }

/* ===== rifiniture dopo la revisione ===== */

/* 3. categorie come nomi a inchiostro con tratto colorato, non chip */
.cats { gap: 6px 22px; }
.cats__a { padding: 4px 0; border: 0; border-radius: 0; background: none; font-weight: 600; font-size: 1.02rem; position: relative; }
.cats__a::before { width: 16px; height: 6px; }
.cats__a:hover, .cats__a:focus-visible { background: none; color: var(--ink); }
.cats__a::after { content: ""; position: absolute; left: 24px; right: 0; bottom: -2px; height: 8px; opacity: 0; transition: opacity 120ms ease-out;
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 8' preserveAspectRatio='none'><path d='M1 5 C 20 2, 40 7, 60 4 S 90 3, 99 5' fill='none' stroke='%23d81f26' stroke-width='3' stroke-linecap='round'/></svg>") no-repeat center / 100% 100%; }
.cats__a.tint-blue::after { background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 8' preserveAspectRatio='none'><path d='M1 5 C 20 2, 40 7, 60 4 S 90 3, 99 5' fill='none' stroke='%231e4fb5' stroke-width='3' stroke-linecap='round'/></svg>"); }
.cats__a:hover::after, .cats__a:focus-visible::after { opacity: 1; }

/* 5. nastro adesivo che si legge come nastro: strappi laterali e grana */
.tape {
  width: 96px; height: 26px; top: -13px;
  background:
    repeating-linear-gradient(90deg, rgba(255,255,255,0) 0 3px, rgba(255,255,255,0.18) 3px 4px),
    rgba(255, 246, 190, 0.86);
  border: 0;
  box-shadow: 0 2px 3px rgba(43, 33, 112, 0.18), inset 0 0 0 1px rgba(43, 33, 112, 0.06);
  clip-path: polygon(0 12%, 3% 0, 6% 14%, 9% 2%, 12% 12%, 100% 8%, 97% 22%, 100% 40%, 96% 58%, 100% 76%, 97% 100%, 10% 96%, 7% 84%, 4% 100%, 1% 86%);
}
.slab--yellow .tape { background: repeating-linear-gradient(90deg, rgba(255,255,255,0) 0 3px, rgba(255,255,255,0.22) 3px 4px), rgba(255, 255, 255, 0.74); }

/* 6. pennarello solo dove il contratto lo consente */
.line__n { font-family: var(--font); font-weight: 800; font-size: 0.85rem; }
.foot__name { font-family: var(--font); font-weight: 800; font-size: 1.05rem; }
.steps li::marker { font-family: var(--font); font-weight: 800; }

/* 7. profondità reale: la lastra gialla lappa la sezione listino; le righe ordine si accavallano */
.hero__calc { position: relative; z-index: 2; margin-bottom: -34px; }
.listino { padding-top: clamp(48px, 5vw, 72px); }
.lines { gap: 0; }
.lines .line + .line { margin-top: -10px; }
.lines .line:nth-child(even) { transform: rotate(0.25deg); }
.lines .line:nth-child(odd) { transform: rotate(-0.2deg); }
.lines .line { z-index: 1; }
.lines .line:focus-within { z-index: 3; }
.lines__actions { margin-top: 28px; }

/* 8. superfici del browser */
html { scrollbar-color: var(--ink-2) var(--paper-2); }
input, textarea, select { caret-color: var(--ink); }
input::placeholder, textarea::placeholder { color: #8a86a6; }

/* 2. stato attivo admin col tratto, non col blocco pieno */
.admin__nav a[aria-current="page"] { background: none; color: var(--ink); position: relative; }
.admin__nav a[aria-current="page"]::after { content: ""; position: absolute; left: 10px; right: 10px; bottom: 2px; height: 8px;
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 8' preserveAspectRatio='none'><path d='M1 5 C 20 2, 40 7, 60 4 S 90 3, 99 5' fill='none' stroke='%2300a9e0' stroke-width='3.2' stroke-linecap='round'/></svg>") no-repeat center / 100% 100%; }
@media (max-width: 900px) { .hero__calc { margin-bottom: 0; } .listino { padding-top: clamp(20px, 3vw, 40px); } }
@media (prefers-reduced-motion: reduce) { .lines .line { transform: none; } }

/* ===== notifiche, suoneria, area stampa ===== */
.appbox { margin: 0 0 28px; }
.appbox h2 { font-size: 1.25rem; margin-bottom: 6px; }
.notif { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; }
.notif__state { margin: 0; font-size: 0.92rem; color: var(--ink-2); }
.notif__state.is-on { color: #145a2a; font-weight: 600; }
.notif__state.is-off { color: var(--magenta); }
.ring { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: 20px; background: rgba(28, 22, 80, 0.8); }
.ring[hidden] { display: none; }
.ring__box { width: min(560px, 100%); text-align: center; padding: 34px 26px 26px; animation: ring-shake 1.6s ease-in-out 3; }
@keyframes ring-shake { 0%, 100% { transform: rotate(0); } 8% { transform: rotate(-1.2deg); } 16% { transform: rotate(1.2deg); } 24% { transform: rotate(-0.8deg); } 32% { transform: rotate(0.8deg); } 40% { transform: rotate(0); } }
@media (prefers-reduced-motion: reduce) { .ring__box { animation: none; } }
.ring__box h2 { font-size: clamp(2rem, 6vw, 3rem); margin-bottom: 14px; }
.ring__list { list-style: none; margin: 0 0 18px; padding: 0; display: grid; gap: 8px; text-align: left; }
.ring__list li { background: rgba(255, 255, 255, 0.7); border-radius: 4px; padding: 10px 14px; }
.ring__list a { font-weight: 800; font-size: 1.1rem; }
.ring__list p { margin: 2px 0 0; color: var(--yellow-ink); }
.ring__ok { font-size: 1.3rem; padding: 18px; }
.ring__hint { margin: 10px 0 0; font-size: 0.85rem; color: rgba(58, 49, 0, 0.75); }
body.is-ringing { overflow: hidden; }
.board { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; align-items: start; }
.board__col { display: grid; gap: 22px; align-content: start; }
.board__h { font-size: 1.1rem; display: flex; align-items: center; gap: 8px; padding-bottom: 8px; border-bottom: 2px solid var(--rule-2); }
.board__n { min-width: 24px; height: 24px; padding: 0 7px; border-radius: 12px; background: var(--ink); color: #fff; font-size: 0.8rem; display: inline-grid; place-items: center; }
.job { padding-top: 24px; }
.job__t { font-size: 1.05rem; margin-bottom: 4px; }
.job__m { color: var(--ink-2); font-size: 0.9rem; margin-bottom: 8px; }
.job__note { font-size: 0.9rem; background: var(--paper-2); padding: 6px 10px; border-radius: 3px; }
.job form .btn { width: 100%; }
.admin__h2 { font-size: 1.2rem; margin: 28px 0 10px; }
.page-ricezione .lead { max-width: 70ch; }
@media (max-width: 900px) { .board { grid-template-columns: 1fr; } }
