/* ==========================================================================
   Carol — Atelier di borse fatte a mano
   Palette: notte (prugna), cipria, avorio, oro antico
   ========================================================================== */

@font-face { font-family: "Cormorant"; src: url("../fonts/cormorant-garamond-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Cormorant"; src: url("../fonts/cormorant-garamond-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Cormorant"; src: url("../fonts/cormorant-garamond-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: "Cormorant"; src: url("../fonts/cormorant-garamond-latin-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Cormorant"; src: url("../fonts/cormorant-garamond-latin-500-italic.woff2") format("woff2"); font-weight: 500; font-style: italic; font-display: swap; }
@font-face { font-family: "Jost"; src: url("../fonts/jost-latin-300-normal.woff2") format("woff2"); font-weight: 300; font-display: swap; }
@font-face { font-family: "Jost"; src: url("../fonts/jost-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Jost"; src: url("../fonts/jost-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --notte: #2a1a22;
  --notte-2: #3a2630;
  --ink: #241c20;
  --cipria: #f1e7e2;
  --cipria-2: #e6d6cf;
  --linea: #dccbc3;
  --avorio: #fffdfb;
  --oro: #a88352;
  --oro-chiaro: #d7bd92;
  --muted: #76666c;
  --ok: #4f6b4a;
  --warn: #a4782c;
  --err: #a1402f;
  --info: #3f5a73;

  --serif: "Cormorant", "Cormorant Garamond", Georgia, serif;
  --sans: "Jost", "Helvetica Neue", Arial, sans-serif;

  --gutter: clamp(18px, 4.5vw, 64px);
  --maxw: 1360px;
  --header-h: 68px;
  --ease: cubic-bezier(.22, .61, .36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--cipria); color: var(--ink);
  font-family: var(--sans); font-weight: 400; font-size: 16px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
::selection { background: var(--notte); color: var(--cipria); }
:focus-visible { outline: 2px solid var(--oro); outline-offset: 3px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 200; background: var(--notte); color: var(--cipria); padding: 10px 16px; }
.skip:focus { top: 12px; }
body.locked { overflow: hidden; }

/* ---------- Tipografia ---------- */
h1, h2, h3, h4, .order-num, .totals .grand, .step-n, .card-title, .line-title, .adm-o-num, .adm-stats span { font-variant-numeric: lining-nums; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 400; line-height: 1.08; margin: 0; letter-spacing: -.01em; }
.display { font-size: clamp(46px, 8.4vw, 112px); line-height: .95; letter-spacing: -.025em; }
.h1 { font-size: clamp(38px, 5.2vw, 68px); }
.h2 { font-size: clamp(32px, 4vw, 52px); }
.h3 { font-size: clamp(24px, 2.4vw, 30px); }
.lead { font-size: clamp(17px, 1.6vw, 19px); font-weight: 300; line-height: 1.7; color: var(--muted); max-width: 34em; }
.kicker { font-family: var(--serif); font-style: italic; font-size: 20px; color: var(--oro); margin: 0 0 10px; }
.muted { color: var(--muted); }
.small { font-size: 13.5px; }
.prose { max-width: 70ch; font-size: 16px; }
.prose h2 { font-size: 30px; margin: 46px 0 12px; }
.prose h3 { font-size: 22px; margin: 30px 0 8px; }
.prose p, .prose li { color: #4a3e43; }
.prose ul { padding-left: 1.2em; }
.prose a { color: var(--notte); text-decoration-color: var(--oro); text-underline-offset: 3px; }
.prose table { border-collapse: collapse; width: 100%; font-size: 14px; margin: 12px 0 20px; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--linea); vertical-align: top; }
.prose th { font-weight: 500; }

/* ---------- Struttura ---------- */
.wrap { max-width: var(--maxw); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.narrow { max-width: 860px; }
.section { padding: clamp(64px, 9vw, 128px) 0; }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: clamp(30px, 4vw, 56px); flex-wrap: wrap; }
.page-top { padding-top: clamp(36px, 6vw, 72px); }
main { min-height: 70vh; }
main:focus { outline: none; }

/* ---------- Pulsanti ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 30px; border: 1px solid var(--notte); background: var(--notte); color: var(--cipria);
  font-family: var(--sans); font-size: 14px; font-weight: 500; letter-spacing: .06em; text-decoration: none;
  transition: background .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease);
}
.btn:hover { background: var(--notte-2); }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.btn-light { background: var(--cipria); color: var(--notte); border-color: var(--cipria); }
.btn-light:hover { background: var(--avorio); }
.btn-ghost { background: transparent; color: var(--notte); }
.btn-ghost:hover { background: var(--notte); color: var(--cipria); }
.btn-block { width: 100%; }
.btn-sm { min-height: 40px; padding: 0 18px; font-size: 13px; }
.link { background: none; border: 0; padding: 0; color: var(--notte); text-decoration: underline; text-decoration-color: var(--oro); text-underline-offset: 4px; font-size: 14.5px; }
.link:hover { color: var(--oro); }
.icon-btn { width: 44px; height: 44px; display: inline-grid; place-items: center; background: none; border: 0; padding: 0; position: relative; color: inherit; }
.icon-btn svg { width: 22px; height: 22px; }

/* ---------- Barra annuncio + header ---------- */
.announce { background: var(--notte); color: var(--cipria-2); text-align: center; font-size: 13px; padding: 8px var(--gutter); letter-spacing: .02em; }
.header {
  position: sticky; top: 0; z-index: 60; height: var(--header-h);
  background: rgba(241, 231, 226, .9); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid transparent; transition: border-color .3s;
}
.header.scrolled { border-bottom-color: var(--linea); }
.header-in { height: 100%; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; }
.nav { display: flex; gap: clamp(18px, 2.4vw, 34px); }
.nav a { text-decoration: none; font-size: 14.5px; letter-spacing: .02em; padding: 6px 0; border-bottom: 1px solid transparent; }
.nav a:hover, .nav a[aria-current="page"] { border-bottom-color: var(--oro); }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img { height: 50px; width: auto; }
.header-actions { display: flex; justify-content: flex-end; align-items: center; gap: 4px; }
.cart-count {
  position: absolute; top: 4px; right: 2px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: var(--oro); color: #fff; font-size: 11px; font-weight: 500; line-height: 18px; text-align: center;
}
.menu-toggle { display: none; }
.header-track { font-size: 14px; text-decoration: none; margin-right: 10px; }
.header-track:hover { color: var(--oro); }

/* Menu mobile */
.mobile-menu {
  position: fixed; inset: 0; z-index: 90; background: var(--notte); color: var(--cipria);
  display: flex; flex-direction: column; padding: 20px var(--gutter) 36px;
  transform: translateY(-100%); visibility: hidden; transition: transform .45s var(--ease), visibility 0s .45s;
}
.mobile-menu.open { transform: none; visibility: visible; transition: transform .45s var(--ease); }
.mobile-menu-top { display: flex; justify-content: space-between; align-items: center; height: 48px; }
.mobile-menu nav { display: flex; flex-direction: column; margin-top: 8vh; }
.mobile-menu nav a { font-family: var(--serif); font-size: 42px; line-height: 1.25; text-decoration: none; }
.mobile-menu-foot { margin-top: auto; display: flex; flex-direction: column; gap: 6px; font-size: 14px; color: var(--cipria-2); }
.mobile-menu-foot a { text-decoration: none; }

/* ---------- Hero ---------- */
.hero { background: var(--notte); color: var(--cipria); display: grid; grid-template-columns: 1.08fr 1fr; min-height: min(88vh, 860px); }
.hero-text { display: flex; flex-direction: column; justify-content: space-between; padding: clamp(40px, 6vw, 88px) var(--gutter); gap: 40px; }
.hero-text .display { max-width: 9.5em; }
.hero-text .lead { color: var(--cipria-2); margin: 28px 0 38px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.hero-actions .link { color: var(--cipria); }
.hero-sign { display: flex; align-items: center; gap: 16px; color: var(--cipria-2); font-size: 13.5px; }
.hero-sign img { width: 64px; height: auto; opacity: .92; }
.hero-media { position: relative; overflow: hidden; }
.hero-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-media img.cutout { object-fit: contain; background: var(--avorio); padding: 8%; }
.hero.reveal .hero-text > * { animation: rise .9s var(--ease) both; }
.hero.reveal .hero-text > *:nth-child(2) { animation-delay: .12s; }
.hero.reveal .hero-media img { animation: unveil 1.4s var(--ease) both; }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@keyframes unveil { from { opacity: 0; transform: scale(1.05); } to { opacity: 1; transform: none; } }

/* ---------- Griglia prodotti ---------- */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(28px, 3.4vw, 52px) clamp(14px, 2.2vw, 32px); }
.card { display: block; text-decoration: none; color: inherit; }
.card-media { position: relative; aspect-ratio: 4 / 5; background: #fff; overflow: hidden; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: opacity .5s var(--ease), transform 1.2s var(--ease); }
.card-media img.cutout { object-fit: contain; padding: 9%; }
.card-media .alt-img { position: absolute; inset: 0; opacity: 0; }
@media (hover: hover) {
  .card:hover .card-media .alt-img { opacity: 1; }
  .card:hover .card-media img:only-child { transform: scale(1.03); }
}
.badge { position: absolute; left: 12px; top: 12px; background: rgba(255, 253, 251, .92); color: var(--notte); font-size: 12px; padding: 4px 10px; letter-spacing: .03em; }
.badge.dark { background: var(--notte); color: var(--cipria); }
.card-body { padding-top: 16px; display: flex; justify-content: space-between; gap: 14px; align-items: baseline; }
.card-title { font-family: var(--serif); font-size: clamp(21px, 1.9vw, 26px); line-height: 1.15; }
.card-sub { color: var(--muted); font-size: 13.5px; margin-top: 4px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.price { font-size: 15px; white-space: nowrap; letter-spacing: .02em; }
.price small { color: var(--muted); font-size: 12px; margin-right: 4px; }
.empty { padding: 60px 0; text-align: center; color: var(--muted); }

.card-title::first-letter, .pdp-info h1::first-letter, .chip::first-letter, .line-title::first-letter, .adm-h::first-letter { text-transform: uppercase; }

/* ---------- Processo ---------- */
.process { background: var(--avorio); }
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; border-top: 1px solid var(--linea); counter-reset: s; }
.step { padding: 30px 26px 10px 0; border-right: 1px solid var(--linea); margin-right: 26px; }
.step:last-child { border-right: 0; margin-right: 0; }
.step-n { font-family: var(--serif); font-size: 54px; color: var(--oro); line-height: 1; margin-bottom: 18px; font-style: italic; }
.step h3 { font-size: 24px; margin-bottom: 8px; }
.step p { margin: 0; color: var(--muted); font-size: 15px; }

/* ---------- Atelier ---------- */
.atelier { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 96px); align-items: center; }
.atelier-media { aspect-ratio: 4/5; background: #fff; overflow: hidden; }
.atelier-media img { width: 100%; height: 100%; object-fit: cover; }
.atelier-media img.cutout { object-fit: contain; padding: 10%; }
.atelier-text p { color: #4a3e43; font-size: 17px; font-weight: 300; line-height: 1.8; max-width: 32em; white-space: pre-line; }
.signature { font-family: var(--serif); font-style: italic; font-size: 30px; color: var(--notte); margin-top: 20px; }

/* ---------- Recensioni ---------- */
.reviews { background: var(--notte); color: var(--cipria); }
.review-track { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(280px, 1fr); gap: 28px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; scrollbar-width: none; }
.review-track::-webkit-scrollbar { display: none; }
.review { scroll-snap-align: start; border-top: 1px solid rgba(215, 189, 146, .4); padding-top: 26px; }
.review blockquote { margin: 0 0 18px; font-family: var(--serif); font-size: 24px; line-height: 1.35; }
.review cite { font-style: normal; color: var(--cipria-2); font-size: 14px; }
.stars { color: var(--oro-chiaro); letter-spacing: 3px; font-size: 13px; margin-bottom: 14px; }

/* ---------- Novità ---------- */
.posts { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 36px; }
.post img { aspect-ratio: 4/3; object-fit: cover; width: 100%; background: #fff; margin-bottom: 16px; }
.post time { color: var(--oro); font-family: var(--serif); font-style: italic; font-size: 17px; }
.post h3 { font-size: 26px; margin: 4px 0 8px; }
.post p { color: var(--muted); margin: 0; white-space: pre-line; }

/* ---------- Iscrizione ---------- */
.subscribe { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: end; border-top: 1px solid var(--linea); padding-top: clamp(48px, 6vw, 80px); }
.inline-form { display: flex; gap: 0; border-bottom: 1px solid var(--notte); }
.inline-form input { flex: 1; border: 0; background: transparent; padding: 14px 0; font-size: 16px; outline: none; min-width: 0; }
.inline-form button { border: 0; background: none; font-weight: 500; letter-spacing: .05em; padding: 0 0 0 16px; font-size: 14px; }

/* ---------- Footer ---------- */
.footer { background: var(--notte); color: var(--cipria-2); padding: clamp(56px, 7vw, 96px) 0 28px; font-size: 14.5px; }
.footer a { text-decoration: none; }
.footer a:hover { color: var(--oro-chiaro); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; }
.footer h4 { font-family: var(--serif); font-size: 22px; color: var(--cipria); margin-bottom: 14px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer-logo { width: 110px; margin-bottom: 18px; }
.socials { display: flex; gap: 8px; margin-top: 18px; }
.socials a { width: 42px; height: 42px; border: 1px solid rgba(230, 214, 207, .3); display: grid; place-items: center; border-radius: 50%; transition: border-color .2s, color .2s; }
.socials a:hover { border-color: var(--oro-chiaro); }
.socials svg { width: 18px; height: 18px; }
.footer-legal { margin-top: 56px; padding-top: 22px; border-top: 1px solid rgba(230, 214, 207, .18); display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap; font-size: 12.5px; color: #b9a6a6; }
.footer-legal button { background: none; border: 0; padding: 0; color: inherit; font-size: inherit; text-decoration: underline; text-underline-offset: 3px; }
.withdraw-link { display: inline-block; margin-top: 6px; color: var(--cipria) !important; text-decoration: underline !important; text-underline-offset: 3px; }

/* ---------- Scheda prodotto ---------- */
.crumbs { font-size: 13px; color: var(--muted); padding: 22px 0; }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--notte); }
.pdp { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 80px); align-items: start; padding-bottom: 80px; }
.gallery { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.gallery figure { margin: 0; background: #fff; aspect-ratio: 4/5; overflow: hidden; }
.gallery figure:first-child { grid-column: 1 / -1; }
.gallery figure:only-child { grid-column: 1 / -1; }
.gallery img { width: 100%; height: 100%; object-fit: cover; }
.gallery img.cutout { object-fit: contain; padding: 7%; }
.gallery-dots { display: none; }
.pdp-info { position: sticky; top: calc(var(--header-h) + 24px); }
.pdp-info h1 { font-size: clamp(38px, 4.2vw, 58px); margin-bottom: 10px; }
.pdp-desc { color: #4a3e43; font-weight: 300; font-size: 16.5px; line-height: 1.75; margin: 18px 0 28px; white-space: pre-line; }
.pdp-price { font-size: 22px; letter-spacing: .02em; }
.pdp-price .from { color: var(--muted); font-size: 14px; }
.config { border-top: 1px solid var(--linea); padding-top: 22px; display: grid; gap: 22px; }
.field-label { display: flex; justify-content: space-between; font-size: 14px; margin-bottom: 10px; }
.field-label span:last-child { color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1px solid var(--linea); background: var(--avorio); padding: 10px 14px; font-size: 14px; line-height: 1.25; text-align: left;
  transition: border-color .2s, background .2s;
}
.chip small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; }
.chip:hover { border-color: var(--notte); }
.chip[aria-pressed="true"] { border-color: var(--notte); background: var(--notte); color: var(--cipria); }
.chip[aria-pressed="true"] small { color: var(--cipria-2); }
.select-wrap select { width: 100%; }
textarea.note { width: 100%; min-height: 84px; resize: vertical; }
.pdp-buy { display: flex; gap: 14px; align-items: center; margin-top: 26px; }
.pdp-buy .btn { flex: 1; }
.pdp-assure { margin-top: 26px; display: grid; gap: 10px; font-size: 14px; color: var(--muted); border-top: 1px solid var(--linea); padding-top: 20px; }
.pdp-assure div { display: flex; gap: 12px; align-items: flex-start; }
.pdp-assure svg { width: 18px; height: 18px; flex: none; margin-top: 2px; color: var(--oro); }
.buybar { display: none; }

/* ---------- Form ---------- */
.input, select, textarea {
  width: 100%; border: 1px solid var(--linea); background: var(--avorio); padding: 13px 14px; font-size: 16px; border-radius: 0;
  transition: border-color .2s; -webkit-appearance: none; appearance: none;
}
select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23241c20' fill='none' stroke-width='1.4'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 38px; }
.input:focus, select:focus, textarea:focus { border-color: var(--notte); outline: none; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-grid .full { grid-column: 1 / -1; }
.field label { display: block; font-size: 13.5px; margin-bottom: 6px; color: #4a3e43; }
.field label .opt { color: var(--muted); }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; line-height: 1.5; color: #4a3e43; cursor: pointer; }
.check input { width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--notte); flex: none; }
.check a { color: var(--notte); }
.hp { position: absolute; left: -9999px; }
.alert { padding: 14px 16px; font-size: 14.5px; border-left: 3px solid var(--err); background: #f8ebe7; color: #6d2b20; }
.alert.ok { border-color: var(--ok); background: #eaf0e7; color: #2e4329; }
.alert.info { border-color: var(--oro); background: var(--avorio); color: #4a3e43; }

/* ---------- Pagamento ---------- */
.pay-options { display: grid; gap: 10px; }
.pay-opt { display: flex; gap: 14px; align-items: flex-start; padding: 16px 18px; border: 1px solid var(--linea); background: var(--avorio); cursor: pointer; transition: border-color .2s; }
.pay-opt:has(input:checked) { border-color: var(--notte); box-shadow: inset 0 0 0 1px var(--notte); }
.pay-opt input { margin-top: 4px; accent-color: var(--notte); width: 18px; height: 18px; }
.pay-opt strong { font-weight: 500; display: block; }
.pay-opt span { font-size: 13.5px; color: var(--muted); }

/* ---------- Checkout ---------- */
.checkout { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: start; padding-bottom: 90px; }
.checkout h2 { font-size: 28px; margin: 34px 0 16px; }
.checkout h2:first-child { margin-top: 0; }
.summary { background: var(--avorio); padding: clamp(22px, 3vw, 34px); position: sticky; top: calc(var(--header-h) + 24px); }
.summary h2 { font-size: 26px; margin-bottom: 18px; }
.line { display: grid; grid-template-columns: 64px 1fr auto; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--cipria-2); font-size: 14px; }
.line img { width: 64px; height: 80px; object-fit: cover; background: #fff; }
.line img.cutout { object-fit: contain; padding: 4px; }
.line-title { font-family: var(--serif); font-size: 19px; line-height: 1.2; }
.line-sub { color: var(--muted); font-size: 12.5px; }
.totals { display: grid; gap: 8px; padding-top: 16px; font-size: 14.5px; }
.totals div { display: flex; justify-content: space-between; }
.totals .grand { font-family: var(--serif); font-size: 26px; padding-top: 10px; border-top: 1px solid var(--cipria-2); margin-top: 6px; }

/* ---------- Carrello (pannello) ---------- */
.drawer-bg { position: fixed; inset: 0; background: rgba(42, 26, 34, .45); z-index: 80; opacity: 0; visibility: hidden; transition: opacity .35s, visibility 0s .35s; }
.drawer-bg.open { opacity: 1; visibility: visible; transition: opacity .35s; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 81; width: min(460px, 100%); background: var(--cipria);
  display: flex; flex-direction: column; transform: translateX(100%); transition: transform .45s var(--ease); visibility: hidden;
}
.drawer.open { transform: none; visibility: visible; }
.drawer-head { display: flex; justify-content: space-between; align-items: center; padding: 18px 24px; border-bottom: 1px solid var(--linea); }
.drawer-head h2 { font-size: 28px; }
.drawer-body { flex: 1; overflow-y: auto; padding: 4px 24px; }
.drawer-foot { padding: 20px 24px calc(20px + env(safe-area-inset-bottom)); border-top: 1px solid var(--linea); background: var(--avorio); }
.drawer-foot .totals { padding-top: 0; margin-bottom: 16px; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--linea); margin-top: 10px; }
.qty button { width: 34px; height: 34px; background: none; border: 0; font-size: 16px; }
.qty span { min-width: 26px; text-align: center; font-size: 14px; }
.remove { background: none; border: 0; padding: 0; color: var(--muted); font-size: 12.5px; text-decoration: underline; margin-left: 14px; }
.free-ship { font-size: 13px; color: var(--muted); margin: 14px 0 0; }

/* ---------- Ordine / traccia ---------- */
.order-hero { text-align: center; padding: clamp(40px, 6vw, 80px) 0 30px; }
.order-hero .h1 { margin: 6px 0 14px; }
.order-num { display: inline-block; font-family: var(--serif); font-size: 26px; padding: 6px 18px; border: 1px solid var(--oro); color: var(--notte); margin-bottom: 18px; }
.pay-box { background: var(--avorio); padding: clamp(22px, 3vw, 34px); border: 1px solid var(--cipria-2); }
.pay-box dl { display: grid; grid-template-columns: auto 1fr; gap: 8px 18px; margin: 16px 0; font-size: 15px; }
.pay-box dt { color: var(--muted); }
.pay-box dd { margin: 0; word-break: break-word; }
.copy { background: none; border: 1px solid var(--linea); padding: 2px 10px; font-size: 12px; margin-left: 8px; vertical-align: middle; }
.timeline { display: grid; grid-template-columns: repeat(3, 1fr); margin: 26px 0 30px; position: relative; }
.timeline div { text-align: center; font-size: 13.5px; color: var(--muted); position: relative; padding-top: 34px; }
.timeline div::before { content: ""; position: absolute; top: 9px; left: 0; right: 0; height: 1px; background: var(--linea); }
.timeline div:first-child::before { left: 50%; }
.timeline div:last-child::before { right: 50%; }
.timeline div::after { content: ""; position: absolute; top: 3px; left: calc(50% - 7px); width: 14px; height: 14px; border-radius: 50%; background: var(--cipria); border: 1px solid var(--linea); }
.timeline div.done { color: var(--ink); }
.timeline div.done::after { background: var(--notte); border-color: var(--notte); }
.status { display: inline-block; padding: 4px 12px; font-size: 12.5px; letter-spacing: .03em; background: var(--cipria-2); color: var(--notte); }
.status.pagato { background: #e4ebe1; color: var(--ok); }
.status.spedito { background: #e2e8ee; color: var(--info); }
.status.non_pagato, .status.annullato { background: #f3e1dc; color: var(--err); }
.status.in_attesa { background: #f3ead9; color: var(--warn); }
.my-orders { background: var(--avorio); padding: 22px 24px; margin-top: 18px; display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }

/* ---------- Configuratore a passaggi ---------- */
.config { gap: 0; overflow-anchor: none; }
body { overflow-anchor: none; }
.cfg-progress { display: flex; gap: 6px; margin-bottom: 6px; }
.cfg-progress i { flex: 1; height: 2px; background: var(--cipria-2); transition: background .3s; }
.cfg-progress i.on { background: var(--notte); }
.cfg-step { padding: 18px 0; border-bottom: 1px solid var(--linea); transition: opacity .25s; scroll-margin-top: 90px; }
.cfg-step.locked { opacity: .45; }
.cfg-step.pulse { animation: pulse .9s var(--ease); }
@keyframes pulse { 0%, 100% { background: transparent; } 40% { background: rgba(168, 131, 82, .14); } }
.cfg-head { display: grid; grid-template-columns: 28px auto 1fr; gap: 10px; align-items: center; font-size: 14.5px; width: 100%; background: none; border: 0; padding: 0; text-align: left; color: inherit; }
.cfg-step.current .cfg-head { margin-bottom: 14px; }
button.cfg-head { cursor: pointer; min-height: 30px; }
button.cfg-head:hover .cfg-edit { color: var(--notte); }
.cfg-edit { margin-left: 12px; font-size: 12.5px; color: var(--oro); text-underline-offset: 3px; font-style: normal; font-family: var(--sans); }
.cfg-step.done:not(.current) .cfg-val { color: var(--ink); }
.cfg-step .chips { animation: rise .35s var(--ease) both; }
.cfg-step.locked .cfg-head { margin-bottom: 4px; }
.cfg-step { padding: 16px 0; }
.cfg-n { width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--linea); display: grid; place-items: center; font-size: 12.5px; color: var(--muted); }
.cfg-step.current .cfg-n { border-color: var(--notte); color: var(--notte); }
.cfg-step.done .cfg-n { background: var(--notte); border-color: var(--notte); color: var(--cipria); }
.cfg-label { font-weight: 500; }
.cfg-val { text-align: right; color: var(--muted); font-size: 13.5px; }
.cfg-step.current .cfg-val { color: var(--oro); font-style: italic; font-family: var(--serif); font-size: 16px; }
.cfg-lock { margin: 0 0 0 38px; font-size: 13px; color: var(--muted); }
.btn.is-incomplete { background: var(--notte-2); opacity: .85; }
.pdp-price .from { color: var(--muted); font-size: .7em; }

/* ---------- WhatsApp ---------- */
.wa-link { display: flex; gap: 12px; align-items: center; margin-top: 18px; padding: 14px 16px; background: var(--avorio); border: 1px solid var(--cipria-2); text-decoration: none; font-size: 14.5px; transition: border-color .2s; }
.wa-link:hover { border-color: #3d7a5b; }
.wa-link svg, .btn-wa svg { width: 22px; height: 22px; flex: none; color: #3d7a5b; }
.wa-link u { text-decoration-color: #3d7a5b; text-underline-offset: 3px; }
.wa-box { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; background: var(--avorio); border: 1px solid var(--cipria-2); padding: 18px 22px; margin-top: 18px; }
.wa-box strong { display: block; font-weight: 500; }
.wa-box span { font-size: 13.5px; color: var(--muted); }
.btn-wa { background: #fff; color: var(--ink); border-color: #3d7a5b; }
.btn-wa:hover { background: #eef5f0; }
.btn-wa svg { color: #3d7a5b; }
.timeline.t4 { grid-template-columns: repeat(4, 1fr); }
.status.consegnato { background: #e4ebe1; color: var(--ok); }
/* Stelle per la recensione */
.stars-input { display: inline-flex; flex-direction: row-reverse; justify-content: flex-end; }
.stars-input input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.stars-input label { font-size: 34px; color: var(--cipria-2); cursor: pointer; padding: 0 3px; transition: color .15s; }
.stars-input input:checked ~ label, .stars-input label:hover, .stars-input label:hover ~ label { color: var(--oro); }
.stars-input input:focus-visible + label { outline: 2px solid var(--oro); }
.stars-input legend { width: 100%; }

/* ---------- Cookie ---------- */
.cookie-bar {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 100; max-width: 560px;
  background: var(--avorio); border: 1px solid var(--linea); box-shadow: 0 24px 60px -24px rgba(42, 26, 34, .45);
  padding: 22px 24px; font-size: 14px; animation: rise .5s var(--ease) both;
}
.cookie-bar h2 { font-size: 24px; margin-bottom: 6px; padding-right: 30px; }
.cookie-bar p { margin: 0 0 16px; color: #4a3e43; }
.cookie-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.cookie-actions .btn { flex: 1; min-height: 46px; padding: 0 16px; }
.cookie-close { position: absolute; top: 10px; right: 10px; }
.modal-bg { position: fixed; inset: 0; z-index: 110; background: rgba(42, 26, 34, .5); display: grid; place-items: center; padding: 16px; }
.modal { background: var(--avorio); width: min(620px, 100%); max-height: 90vh; overflow-y: auto; padding: clamp(22px, 4vw, 38px); position: relative; }
.modal h2 { font-size: 32px; margin-bottom: 10px; padding-right: 36px; }
.cookie-cat { border-top: 1px solid var(--linea); padding: 18px 0; }
.cookie-cat-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.cookie-cat-head strong { font-weight: 500; }
.cookie-cat p { margin: 8px 0 0; font-size: 13.5px; color: var(--muted); }
.switch { position: relative; width: 46px; height: 26px; flex: none; }
.switch input { opacity: 0; width: 100%; height: 100%; position: absolute; margin: 0; cursor: pointer; z-index: 1; }
.switch span { position: absolute; inset: 0; background: var(--cipria-2); border-radius: 13px; transition: background .2s; }
.switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform .2s var(--ease); box-shadow: 0 1px 3px rgba(0,0,0,.2); }
.switch input:checked + span { background: var(--notte); }
.switch input:checked + span::after { transform: translateX(20px); }
.switch input:disabled + span { opacity: .55; }
.switch input:focus-visible + span { outline: 2px solid var(--oro); outline-offset: 2px; }

/* ---------- Toast ---------- */
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 120; background: var(--notte); color: var(--cipria); padding: 14px 22px; font-size: 14px; box-shadow: 0 18px 40px -18px rgba(0,0,0,.5); animation: rise .35s var(--ease) both; max-width: calc(100% - 32px); }

/* ---------- Loader ---------- */
.loading { display: grid; place-items: center; min-height: 60vh; }
.loading span { width: 34px; height: 34px; border: 1px solid var(--linea); border-top-color: var(--notte); border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ==========================================================================
   Tablet e telefono
   ========================================================================== */
@media (max-width: 1080px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr 1fr; }
  .step:nth-child(2) { border-right: 0; margin-right: 0; }
  .step:nth-child(n+3) { border-top: 1px solid var(--linea); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
  :root { --header-h: 60px; }
  .nav, .header-track { display: none; }
  .menu-toggle { display: inline-grid; }
  .brand img { height: 42px; }
  .hero { grid-template-columns: 1fr; min-height: 0; }
  .hero-media { order: -1; height: 56vh; min-height: 300px; max-height: 520px; }
  .hero-media img { object-position: center 22%; }
  .hero-text { padding-top: 34px; padding-bottom: 44px; gap: 28px; }
  .hero-text .lead { margin: 18px 0 28px; }
  .hero-actions .btn { flex: 1; }
  .hero-sign { display: none; }
  .atelier, .subscribe, .checkout, .pdp { grid-template-columns: 1fr; }
  .atelier-media { aspect-ratio: 1 / 1; }
  .summary, .pdp-info { position: static; }
  .summary { order: -1; }
  .checkout .summary { order: 0; }

  /* Galleria a scorrimento orizzontale */
  .pdp { gap: 22px; padding-bottom: 120px; }
  .crumbs { display: none; }
  .gallery-shell { margin: 0 calc(var(--gutter) * -1); position: relative; }
  .gallery { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 0; scrollbar-width: none; }
  .gallery::-webkit-scrollbar { display: none; }
  .gallery figure { flex: 0 0 100%; scroll-snap-align: center; aspect-ratio: 1 / 1.08; }
  .gallery-dots { display: flex; justify-content: center; gap: 7px; position: absolute; bottom: 14px; left: 0; right: 0; }
  .gallery-dots i { width: 6px; height: 6px; border-radius: 50%; background: rgba(42, 26, 34, .25); transition: background .2s, transform .2s; }
  .gallery-dots i.on { background: var(--notte); transform: scale(1.25); }

  .buybar {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; gap: 14px; align-items: center;
    padding: 12px var(--gutter) calc(12px + env(safe-area-inset-bottom)); background: rgba(255, 253, 251, .96);
    backdrop-filter: blur(10px); border-top: 1px solid var(--linea);
  }
  .buybar .btn { flex: 1; min-height: 50px; }
  .buybar .pdp-price { font-size: 19px; }
  .pdp-buy { display: none; }
  .toast { bottom: calc(96px + env(safe-area-inset-bottom)); }
  .footer-legal { flex-direction: column; }
}

@media (max-width: 560px) {
  body { font-size: 15.5px; }
  .grid { gap: 30px 12px; }
  .card-body { flex-direction: column; gap: 4px; padding-top: 12px; }
  .card-title { font-size: 19px; }
  .card-sub { display: none; }
  .price { font-size: 14px; }
  .badge { left: 8px; top: 8px; font-size: 11px; padding: 3px 8px; }
  .steps { grid-template-columns: 1fr; }
  .step { border-right: 0; margin-right: 0; border-top: 1px solid var(--linea); display: grid; grid-template-columns: 56px 1fr; padding: 22px 0; }
  .step:first-child { border-top: 0; }
  .step-n { font-size: 40px; margin: 0; grid-row: span 2; }
  .form-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 34px; }
  .section-head { margin-bottom: 26px; }
  .cookie-bar { left: 0; right: 0; bottom: 0; max-width: none; border-left: 0; border-right: 0; padding: 20px var(--gutter) calc(20px + env(safe-area-inset-bottom)); }
  .cookie-actions .btn { flex: 1 1 40%; }
  .drawer-head, .drawer-body, .drawer-foot { padding-left: 18px; padding-right: 18px; }
  .timeline div { font-size: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
