/* ===== Asta delle maglie di Natale · bianco perla, rosso del logo, oro ===== */
@font-face { font-family: "Mountains of Christmas"; font-weight: 700; font-style: normal; font-display: swap;
  src: url(fonts/mountains-of-christmas-latin-700-normal.woff2) format("woff2"); }
@font-face { font-family: "Mountains of Christmas"; font-weight: 400; font-style: normal; font-display: swap;
  src: url(fonts/mountains-of-christmas-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: "Nunito"; font-weight: 400; font-style: normal; font-display: swap;
  src: url(fonts/nunito-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: "Nunito"; font-weight: 700; font-style: normal; font-display: swap;
  src: url(fonts/nunito-latin-700-normal.woff2) format("woff2"); }
@font-face { font-family: "Nunito"; font-weight: 800; font-style: normal; font-display: swap;
  src: url(fonts/nunito-latin-800-normal.woff2) format("woff2"); }

:root {
  --pearl: #fbf8f3; --pearl-2: #f3ece1; --pearl-3: #e6dac7;
  --ink: #2a1a1b; --muted: #6a5959;
  --red: #d5050f; --red-d: #a8040c; --red-dd: #7d0309; --logo-red: #e30613;
  --gold: #c9a24b; --gold-l: #ecd596; --gold-d: #8a6a1f;
  --ok: #14633f; --ok-bg: #e3f4ea; --bad: #a8040c; --bad-bg: #fdeaea;
  --gold-grad: linear-gradient(135deg, #a67c24 0%, #ecd596 35%, #c9a24b 60%, #8a6a1f 100%);
  --stripe: repeating-linear-gradient(135deg, var(--red) 0 10px, #fff 10px 20px);
  --display: "Mountains of Christmas", Georgia, "Times New Roman", serif;
  --text: "Nunito", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --radius: 18px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; color: var(--ink); background: var(--pearl); font: 400 17px/1.55 var(--text); }
a { color: var(--red-d); }
img { max-width: 100%; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- barra in alto ---------- */
header.top { position: sticky; top: 0; z-index: 30; background: rgba(251, 248, 243, .95);
  backdrop-filter: blur(6px); border-bottom: 2px solid transparent; border-image: var(--gold-grad) 1; }
header.top::before { content: ""; display: block; height: 6px; background: var(--stripe); }
header.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 8px; padding-bottom: 8px; }
.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand img { width: 40px; height: 40px; object-fit: contain; flex: none; }
header.top h1 { margin: 0; font: 700 1.3rem/1.1 var(--display); color: var(--red-d); letter-spacing: .01em; }
#account { display: flex; align-items: center; gap: 8px; font-size: .85rem; color: var(--muted); min-width: 0; }
#account span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 34vw; }

/* ---------- apertura natalizia ---------- */
.hero { position: relative; overflow: hidden; color: #fff; text-align: center; padding: 78px 16px 86px;
  background: radial-gradient(120% 100% at 50% 0%, #ea1420 0%, #c4040e 52%, #8f0309 100%); }
.hero canvas { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.hero .garland { position: absolute; top: 0; left: 0; right: 0; height: 58px; background: url(img/deco/garland.svg) repeat-x top left / 160px 58px; }
.hero .edge { position: absolute; left: 0; right: 0; bottom: -1px; height: 40px; background: url(img/deco/drift-up.svg) repeat-x bottom / 640px 100%; }
.hero .deco { position: absolute; top: 0; width: 140px; height: 300px; background-repeat: no-repeat; background-size: contain; pointer-events: none; display: none; }
.hero .deco.l { left: 2%; background-image: url(img/deco/baubles.svg); }
.hero .deco.r { right: 2%; background-image: url(img/deco/baubles-r.svg); }
.hero .inner { position: relative; z-index: 2; max-width: 720px; margin: 0 auto; }
.medal { width: 138px; height: 138px; margin: 0 auto 20px; border-radius: 50%; display: grid; place-items: center;
  border: 6px solid transparent; box-shadow: 0 8px 24px rgba(0, 0, 0, .35), 0 0 0 4px rgba(236, 213, 150, .25);
  background: linear-gradient(var(--pearl), var(--pearl)) padding-box, var(--gold-grad) border-box; }
.medal img { width: 80%; height: 80%; object-fit: contain; }
.hero .kicker { margin: 0 0 10px; font: 700 .95rem/1 var(--text); letter-spacing: .22em; text-transform: uppercase; color: var(--gold-l); }
.hero h2 { margin: 0 0 22px; font: 700 clamp(2.5rem, 10vw, 4.4rem)/1.02 var(--display); text-shadow: 0 3px 0 rgba(80, 0, 5, .35); }
.hero p { margin: 0 auto 20px; color: #ffeee6; max-width: 58ch; font-size: 1.02rem; }
.status { display: inline-flex; gap: 10px; align-items: center; justify-content: center; text-align: center; max-width: 100%; font-size: .98rem; padding: 9px 18px 9px 14px; border-radius: 999px; color: var(--ink);
  font-weight: 800; border: 2px solid transparent;
  background: linear-gradient(var(--pearl), var(--pearl)) padding-box, var(--gold-grad) border-box; box-shadow: 0 4px 14px rgba(0, 0, 0, .25); }
.status::before { content: ""; width: 20px; height: 20px; background: url(img/deco/star.svg) center / contain no-repeat; flex: none; }
.status.open { color: var(--ok); } .status.closed { color: var(--bad); }

/* ---------- schede delle maglie ---------- */
.grid { display: grid; gap: 24px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); padding: 30px 0 70px;
  background: url(img/deco/snow.svg) repeat; }
.card { position: relative; display: flex; flex-direction: column; overflow: hidden; border-radius: var(--radius);
  border: 3px solid transparent; box-shadow: 0 12px 28px rgba(125, 3, 9, .12);
  background: linear-gradient(#fff, #fff) padding-box, var(--gold-grad) border-box; }
.card::before { content: ""; height: 8px; background: var(--stripe); flex: none; }
.pic { position: relative; aspect-ratio: 540 / 600; display: flex; align-items: flex-end; justify-content: center; overflow: hidden;
  background: radial-gradient(72% 62% at 50% 40%, #fff 0%, #fbeee4 55%, #f3dccd 100%); }
.pic::after { content: ""; position: absolute; inset: 0; background: url(img/deco/snow.svg) center / 150px; opacity: .8; }
.pic img { position: relative; z-index: 1; height: 100%; width: auto; max-width: 100%; object-fit: contain; object-position: bottom; }
.pic .num { position: absolute; z-index: 2; top: 12px; left: 12px; width: 50px; height: 50px; border-radius: 50%;
  display: grid; place-items: center; color: #fff; font: 700 1.5rem/1 var(--display);
  background: radial-gradient(circle at 35% 30%, #ff5a5f, var(--red) 60%, var(--red-dd)); border: 3px solid var(--gold-l);
  box-shadow: 0 3px 8px rgba(0, 0, 0, .3); }
.card .body { display: flex; flex-direction: column; gap: 6px; flex: 1; padding: 14px 18px 18px; }
.card h3 { margin: 0; font: 700 1.65rem/1.1 var(--display); color: var(--red-d); }
.card .desc { margin: 0; color: var(--muted); font-size: .92rem; }
.amount { margin-top: auto; padding-top: 6px; font: 800 2.1rem/1.05 var(--text); color: var(--red-d); }
.amount small { display: block; margin-bottom: 2px; font: 700 .78rem/1.2 var(--text); letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.badge { display: inline-block; width: fit-content; padding: 4px 12px; border-radius: 999px; font-size: .82rem; font-weight: 800; }
.badge.lead { background: var(--ok-bg); color: var(--ok); }
.badge.out  { background: var(--bad-bg); color: var(--bad); }
.badge.mine { background: #fff4d6; color: var(--gold-d); }
.empty { grid-column: 1 / -1; text-align: center; color: var(--muted); padding: 30px 0; }

/* ---------- pulsanti e moduli ---------- */
button, .btn { font: 800 1rem/1 var(--text); cursor: pointer; border-radius: 12px; padding: 13px 18px; min-height: 46px; color: #fff;
  border: 2px solid var(--gold); background: linear-gradient(#e8101b, #b30410); text-shadow: 0 1px 0 rgba(0, 0, 0, .3);
  box-shadow: 0 3px 0 var(--red-dd), 0 6px 12px rgba(125, 3, 9, .25); }
button:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--red-dd); }
button.ghost { background: #fff; color: var(--red-d); border: 2px solid var(--pearl-3); text-shadow: none; box-shadow: none; }
button.small { padding: 7px 12px; min-height: 36px; font-size: .88rem; }
button:disabled { opacity: .5; cursor: not-allowed; box-shadow: none; filter: grayscale(.4); }
button:focus-visible, input:focus-visible, select:focus-visible, a:focus-visible { outline: 3px solid var(--red-dd); outline-offset: 2px; }
dialog { border: 3px solid transparent; border-radius: var(--radius); color: var(--ink); width: min(450px, calc(100vw - 24px)); padding: 0 22px 22px;
  background: linear-gradient(var(--pearl), var(--pearl)) padding-box, var(--gold-grad) border-box; overflow: hidden; }
dialog::before { content: ""; display: block; height: 8px; margin: 0 -22px; background: var(--stripe); }
dialog::backdrop { background: rgba(60, 4, 8, .62); }
dialog h3 { margin: 18px 0 4px; font: 700 1.8rem/1.1 var(--display); color: var(--red-d); }
dialog p { color: var(--muted); margin: 0 0 14px; }
dialog form { margin: 0; }
label { display: block; font-size: .92rem; font-weight: 800; margin: 12px 0 4px; }
input, select { width: 100%; font: inherit; padding: 11px 12px; border-radius: 10px; border: 2px solid var(--pearl-3); background: #fff; color: var(--ink); min-height: 46px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; }
.check input { width: 22px; min-height: 22px; margin-top: 3px; flex: none; accent-color: var(--red); }
.row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; }
.quick { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.msg { margin-top: 12px; padding: 10px 12px; border-radius: 10px; font-size: .93rem; font-weight: 700; }
.msg.err { background: var(--bad-bg); color: var(--bad); } .msg.ok { background: var(--ok-bg); color: var(--ok); }
.muted { color: var(--muted); } .note { margin-top: 10px; font-size: .86rem; }

/* ---------- piede ---------- */
footer { position: relative; margin-top: 10px; padding: 70px 0 44px; color: #ffe9e2; font-size: .9rem; text-align: center;
  background: linear-gradient(#b30410, #8a0309); }
footer::before { content: ""; position: absolute; top: -1px; left: 0; right: 0; height: 40px; background: url(img/deco/drift-down.svg) repeat-x top / 640px 100%; }
footer a { color: var(--gold-l); }
footer .sign { display: block; margin-top: 8px; font: 700 1.3rem/1.2 var(--display); color: var(--gold-l); }

/* ---------- pannello amministratori ---------- */
.tabs { display: flex; gap: 8px; flex-wrap: wrap; margin: 22px 0 14px; }
.tabs button { background: #fff; color: var(--red-d); border: 2px solid var(--pearl-3); text-shadow: none; box-shadow: none; }
.tabs button[aria-selected="true"] { background: linear-gradient(#e8101b, #b30410); color: #fff; border-color: var(--gold); }
.tablewrap { overflow-x: auto; border: 2px solid var(--pearl-3); border-radius: var(--radius); background: #fff; }
table { width: 100%; border-collapse: collapse; font-size: .93rem; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--pearl-2); white-space: nowrap; }
th { color: var(--red-dd); font-weight: 800; background: var(--pearl-2); }
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; align-items: end; }
.toolbar > * { flex: 0 1 220px; }
.panel { background: #fff; border: 2px solid var(--pearl-3); border-radius: var(--radius); padding: 18px; margin-bottom: 16px; }
.login { max-width: 420px; margin: 40px auto; }
.panel h2 { margin-top: 0; font: 700 1.8rem/1.1 var(--display); color: var(--red-d); }
.two { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.grow { flex: 1 1 auto !important; }
.doc { padding: 30px 16px 60px; max-width: 760px; }
.doc h1, .doc h2 { font-family: var(--display); color: var(--red-d); }

/* ---------- schermi larghi ---------- */
@media (min-width: 820px) { .hero .deco { display: block; } .hero { padding-top: 84px; } header.top h1 { font-size: 1.55rem; } }
@media (max-width: 520px) { .status { font-size: .92rem; padding: 8px 14px 8px 12px; } .hero { padding-top: 74px; } }
@media (max-width: 380px) { header.top h1 { font-size: 1.05rem; } #account span { display: none; } }
@media (prefers-reduced-motion: no-preference) {
  .card { transition: transform .2s, box-shadow .2s; }
  .card:hover { transform: translateY(-3px); box-shadow: 0 16px 34px rgba(125, 3, 9, .18); }
}

button.link { background: none; border: 0; padding: 0; min-height: 0; color: var(--red-dd); font: inherit; font-weight: 800; text-decoration: underline; cursor: pointer; box-shadow: none; width: auto; }

button.danger { color: var(--bad); border-color: var(--bad); }
button.danger:hover { background: var(--bad-bg); }

/* ---------- home di benvenuto ---------- */
@font-face { font-family: "Emilys Candy"; font-weight: 400; font-style: normal; font-display: swap;
  src: url(fonts/emilys-candy-latin-400-normal.woff2) format("woff2"); }
.home[hidden], .intro[hidden], .grid[hidden], .backbar[hidden] { display: none; }
.home { padding: 36px 0 64px; text-align: center; background: url(img/deco/snow.svg) repeat; }
.home h2 { margin: 0 0 30px; font: 700 clamp(2.2rem, 8vw, 3.2rem)/1.05 var(--display); color: var(--red-d); }
.steps { list-style: none; margin: 0 auto; padding: 0; display: grid; gap: 34px 20px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); max-width: 960px; counter-reset: s; }
.steps li { --c: var(--red); --c2: var(--red-dd); position: relative; padding: 44px 20px 24px; border-radius: 26px; border: 4px solid var(--c); text-align: center;
  background: linear-gradient(#fff, var(--pearl)); box-shadow: 0 10px 0 var(--c2), 0 18px 28px rgba(60, 4, 8, .14); }
.steps li:nth-child(2) { --c: #1f7a4d; --c2: #135536; }
.steps li:nth-child(3) { --c: #b9851a; --c2: #7d5a0f; }
.steps li::after { content: ""; position: absolute; inset: 8px; border-radius: 18px; border: 2px dashed var(--c); opacity: .35; pointer-events: none; }
.steps .ball { position: absolute; top: -26px; left: 50%; transform: translateX(-50%); width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; z-index: 1;
  color: #fff; font: 400 1.9rem/1 "Emilys Candy", var(--display); background: radial-gradient(circle at 35% 30%, #fff8 0 8%, var(--c) 30%, var(--c2)); border: 4px solid var(--gold-l); box-shadow: 0 4px 8px rgba(0, 0, 0, .25); }
.steps h3 { margin: 0 0 8px; font: 400 clamp(1.9rem, 6vw, 2.2rem)/1.1 "Emilys Candy", var(--display); color: var(--c); letter-spacing: .02em; }
.steps p { margin: 0; font: 700 1.3rem/1.3 var(--display); color: var(--ink); }
.steps p b { color: var(--c); font-weight: 700; }
.intro { padding: 26px 0 0; text-align: center; background: url(img/deco/snow.svg) repeat; }
.strip { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; margin: 0 0 6px; }
.mini { width: 62px; height: 62px; border-radius: 50%; overflow: hidden; border: 3px solid var(--gold); background: radial-gradient(#fff, #f3dccd); box-shadow: 0 6px 14px rgba(125, 3, 9, .15); }
.mini img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; }
.facts { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); max-width: 900px; margin: 18px auto 0; }
.fact { padding: 12px; border-radius: 14px; background: var(--pearl-2); border: 2px solid var(--pearl-3); }
.fact small { display: block; color: var(--muted); font-weight: 700; }
.fact strong { color: var(--red-d); font-size: 1.1rem; }
.privnote { margin: 14px 0 0; color: var(--muted); font-size: .9rem; }
@media (max-width: 480px) { .mini { width: 50px; height: 50px; border-width: 2px; } .strip { gap: 6px; } }

.statuscta { margin-top: 40px; display: flex; flex-direction: column; align-items: center; gap: 22px; }
.statuscta p { margin: -4px 0 0; }
.bigcta { font: 400 clamp(1.5rem, 6vw, 2rem)/1.1 "Emilys Candy", var(--display); padding: 18px 34px; min-height: 64px; border-radius: 999px; color: #fff;
  background: linear-gradient(#f0202b, #b30410); border: 4px solid var(--gold); letter-spacing: .02em; cursor: pointer;
  box-shadow: 0 8px 0 var(--red-dd), 0 16px 28px rgba(125, 3, 9, .3); text-shadow: 0 2px 0 rgba(80, 0, 5, .45); max-width: 100%; }
.bigcta:hover { filter: brightness(1.06); transform: translateY(-1px); }
.bigcta:active { transform: translateY(4px); box-shadow: 0 4px 0 var(--red-dd), 0 8px 16px rgba(125, 3, 9, .3); }
@media (prefers-reduced-motion: no-preference) { .bigcta { animation: pulse 2.6s ease-in-out infinite; } @keyframes pulse { 50% { box-shadow: 0 8px 0 var(--red-dd), 0 16px 34px rgba(201, 162, 75, .75); } } }
.backbar { padding: 22px 0 0; text-align: center; }
.bigcta.alt { color: var(--red-d); background: linear-gradient(#fff, var(--pearl-2)); border-color: var(--red); text-shadow: none;
  box-shadow: 0 8px 0 var(--pearl-3), 0 16px 28px rgba(125, 3, 9, .18); animation: none; }
.bigcta.alt:active { box-shadow: 0 4px 0 var(--pearl-3), 0 8px 16px rgba(125, 3, 9, .18); }
.amount.empty { min-height: 3.1rem; }
.bigback { font: 400 clamp(1.3rem, 5vw, 1.6rem)/1.1 "Emilys Candy", var(--display); padding: 14px 28px; min-height: 56px; border-radius: 999px; cursor: pointer;
  color: #fff; background: linear-gradient(#f0202b, #b30410); border: 3px solid var(--gold); letter-spacing: .02em; text-shadow: 0 2px 0 rgba(80, 0, 5, .45);
  box-shadow: 0 6px 0 var(--red-dd), 0 12px 22px rgba(125, 3, 9, .25); max-width: 100%; }
.bigback:hover { filter: brightness(1.06); }
.bigback:active { transform: translateY(3px); box-shadow: 0 3px 0 var(--red-dd), 0 6px 12px rgba(125, 3, 9, .25); }

dialog .or { display: flex; align-items: center; gap: 12px; margin: 20px 0 14px; color: var(--muted); font-weight: 800; text-transform: uppercase; font-size: .8rem; letter-spacing: .12em; }
dialog .or::before, dialog .or::after { content: ""; flex: 1; height: 2px; background: var(--pearl-3); }
.regbox { padding: 14px 16px 16px; border-radius: 16px; border: 3px solid var(--gold); background: linear-gradient(#fffaf0, #fbefd2); text-align: center; }
.regbox h4 { margin: 0 0 6px; font: 400 1.45rem/1.15 "Emilys Candy", var(--display); color: var(--red-d); }
.regbox p { margin: 0 0 12px; color: var(--ink); font-size: .95rem; }
.regbtn { width: 100%; font: 400 1.3rem/1.1 "Emilys Candy", var(--display); padding: 13px 16px; min-height: 52px; border-radius: 999px; cursor: pointer;
  color: var(--red-d); background: #fff; border: 3px solid var(--red); box-shadow: 0 4px 0 var(--pearl-3); }
.regbtn:hover { background: var(--bad-bg); }
.regbtn:active { transform: translateY(3px); box-shadow: none; }

.photorow { display: flex; gap: 14px; align-items: flex-start; flex-wrap: wrap; }
.photorow > div { display: grid; gap: 6px; flex: 1; min-width: 220px; }
.thumb { width: 90px; height: 113px; object-fit: cover; object-position: top; border-radius: 12px; border: 2px solid var(--gold); background: radial-gradient(#fff, #f3dccd); }
.thumb[hidden] { display: none; }
.photo { grid-column: 1 / -1; }

/* ---------- home compatta: tutto visibile in una sola schermata (PC e telefono) ---------- */
body.is-home { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
body.is-home main { flex: 1; display: flex; flex-direction: column; justify-content: center; }
body.is-home header.top .wrap { padding-top: 4px; padding-bottom: 4px; }
body.is-home .hero { padding: 40px 14px 30px; }
body.is-home .hero .garland { height: 30px; background-size: 84px 30px; }
body.is-home .hero .edge { height: 22px; }
body.is-home .hero .deco { display: none; }
body.is-home .medal { width: clamp(50px, 9vh, 80px); height: clamp(50px, 9vh, 80px); margin: 0 auto 6px; border-width: 3px; }
body.is-home .hero .kicker { margin: 0 0 8px; font-size: .72rem; }
body.is-home .hero h2 { line-height: 1.12; }
body.is-home .hero h2 { margin: 0 0 6px; font-size: clamp(1.9rem, 6.5vh, 3rem); }
body.is-home .hero p { margin: 0 auto 8px; font-size: .84rem; line-height: 1.3; max-width: 76ch; }
body.is-home .status { font-size: .84rem; padding: 5px 14px 5px 11px; }
body.is-home .status::before { width: 16px; height: 16px; }
body.is-home .home { padding: 12px 0 6px; background: none; }
body.is-home .home h2 { margin: 0 0 12px; font-size: clamp(1.5rem, 4.6vh, 2.1rem); }
body.is-home .steps { gap: 10px; max-width: 900px; grid-template-columns: 1fr; }
body.is-home .steps li { padding: 7px 12px 7px 62px; text-align: left; border-width: 3px; border-radius: 18px; box-shadow: 0 5px 0 var(--c2); }
body.is-home .steps li::after { display: none; }
body.is-home .steps .ball { left: 29px; top: 50%; transform: translate(-50%, -50%); width: 38px; height: 38px; font-size: 1.4rem; border-width: 3px; }
body.is-home .steps h3 { margin: 0; font-size: 1.35rem; }
body.is-home .steps p { font-size: .88rem; line-height: 1.22; }
body.is-home .statuscta { margin-top: 14px; gap: 9px; }
body.is-home .bigcta { max-width: 100%; padding: 8px 22px; min-height: 46px; font-size: clamp(1.2rem, 4.8vw, 1.5rem); border-width: 3px; box-shadow: 0 5px 0 var(--red-dd), 0 9px 16px rgba(125, 3, 9, .25); }
body.is-home .bigcta.alt { box-shadow: 0 5px 0 var(--pearl-3), 0 9px 16px rgba(125, 3, 9, .15); }
body.is-home .statuscta p { font-size: .8rem; margin: 0; }
body.is-home footer { margin-top: 6px; padding: 30px 0 12px; }
body.is-home footer::before { height: 20px; }
body.is-home footer .wrap { display: flex; justify-content: center; align-items: baseline; gap: 6px 16px; flex-wrap: wrap; }
body.is-home footer .sign { display: inline; margin: 0; font-size: 1.05rem; }
@media (min-width: 820px) {
  body.is-home .steps { grid-template-columns: repeat(3, 1fr); gap: 22px; }
  body.is-home .steps li { padding: 26px 14px 10px; text-align: center; }
  body.is-home .steps .ball { left: 50%; top: -20px; width: 40px; height: 40px; transform: translateX(-50%); }
  body.is-home .steps h3 { font-size: 1.55rem; margin-bottom: 2px; }
  body.is-home .statuscta { flex-direction: row; flex-wrap: wrap; justify-content: center; gap: 10px 18px; }
  body.is-home .statuscta p { flex-basis: 100%; }
  body.is-home .hero p { font-size: .95rem; }
  body.is-home .home h2 { margin-bottom: 26px; }
}
@media (max-height: 760px) { body.is-home .medal { display: none; } body.is-home .hero { padding-top: 38px; } }
@media (max-height: 700px), (max-width: 819px) {
  body.is-home .medal { display: none; }
  body.is-home .home h2 { display: none; }
  body.is-home .home { padding-top: 8px; }
  body.is-home .home h2 { display: none; }
  body.is-home .hero { padding: 33px 12px 20px; }
  body.is-home .hero .garland { height: 26px; background-size: 72px 26px; }
  body.is-home .hero .edge { height: 16px; }
  body.is-home .hero .kicker { margin-bottom: 2px; }
  body.is-home .status { font-size: .78rem; padding: 3px 12px 3px 9px; }
  body.is-home .hero h2 { font-size: clamp(1.8rem, 7vh, 2.4rem); margin-bottom: 4px; }
  body.is-home .hero p { font-size: .78rem; line-height: 1.25; margin-bottom: 6px; }
  body.is-home .statuscta { margin-top: 8px; gap: 6px; }
  body.is-home .bigcta { min-height: 40px; padding: 5px 18px; font-size: 1.2rem; }
  body.is-home .statuscta p { font-size: .72rem; }
  body.is-home footer { padding: 22px 0 6px; margin-top: 2px; }
  body.is-home footer::before { height: 14px; }
  body.is-home footer a, body.is-home footer .sign { font-size: .85rem; }
}
@media (max-width: 819px) and (max-height: 700px) {
  body.is-home .steps { gap: 7px; }
  body.is-home .steps li { padding: 3px 10px 3px 54px; box-shadow: 0 4px 0 var(--c2); }
  body.is-home .steps .ball { left: 26px; width: 34px; height: 34px; font-size: 1.25rem; }
  body.is-home .steps h3 { font-size: 1.2rem; }
  body.is-home .steps p { font-size: .78rem; line-height: 1.18; }
}
@media (min-width: 820px) and (max-height: 700px) {
  body.is-home .steps li { padding: 24px 14px 8px; }
  body.is-home .steps h3 { font-size: 1.45rem; }
  body.is-home .steps p { font-size: .85rem; line-height: 1.2; }
  body.is-home .home { padding-top: 22px; }
}
@media (max-height: 640px) and (max-width: 819px) {
  body.is-home .hero .kicker { display: none; }
  body.is-home .hero h2 { font-size: 1.7rem; margin-bottom: 2px; }
  body.is-home .hero p { font-size: .72rem; margin-bottom: 4px; }
  body.is-home .hero { padding-top: 30px; padding-bottom: 16px; }
  body.is-home .steps { gap: 5px; }
  body.is-home .steps p { font-size: .72rem; }
  body.is-home .steps h3 { font-size: 1.1rem; }
  body.is-home .bigcta { min-height: 36px; padding: 3px 16px; font-size: 1.1rem; }
  body.is-home .statuscta { margin-top: 6px; gap: 5px; }
  body.is-home .statuscta p { font-size: .68rem; }
  body.is-home footer { padding-top: 18px; }
}

/* ---------- elenco maglie compatto (dopo l'accesso o "Guarda lo stato"): poco scorrimento, foto sempre intera ---------- */
body.is-list { --ph: 64px; --pw: calc(var(--ph) * .794); }   /* altezza e larghezza (540:680) della foto */
body.is-list .hero { padding: 36px 12px 18px; }
body.is-list .hero .garland { height: 26px; background-size: 72px 26px; }
body.is-list .hero .edge { height: 14px; }
body.is-list .hero .deco, body.is-list .medal, body.is-list .hero .kicker, body.is-list .hero p { display: none; }
body.is-list .hero h2 { margin: 0 0 6px; font-size: clamp(1.5rem, 4.2vh, 2rem); }
body.is-list .status { font-size: .82rem; padding: 4px 12px 4px 10px; }
body.is-list .status::before { width: 15px; height: 15px; }
body.is-list .backbar { padding: 10px 0 0; }
body.is-list .bigback { min-height: 36px; padding: 5px 18px; font-size: 1.1rem; border-width: 2px; box-shadow: 0 3px 0 var(--red-dd); }
body.is-list .grid { gap: 8px; padding: 10px 0 8px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
body.is-list .card { flex-direction: row; border-radius: 14px; border-width: 2px; box-shadow: 0 4px 10px rgba(125, 3, 9, .12); min-height: var(--ph); }
body.is-list .card::before { display: none; }
body.is-list .pic { aspect-ratio: auto; width: var(--pw); flex: none; }
body.is-list .pic::after { display: none; }
body.is-list .pic img { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: contain; object-position: bottom center; }
body.is-list .pic .num { top: 3px; left: 3px; width: 20px; height: 20px; font-size: .72rem; border-width: 2px; }
body.is-list .card .body { min-width: 0; overflow: hidden; padding: 4px 6px 5px 6px; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; align-content: center; column-gap: 6px; row-gap: 1px; }
body.is-list .card h3 { grid-column: 1 / -1; font-size: 1rem; line-height: 1.02; }
body.is-list .card .desc { display: none; }
body.is-list .badge { position: absolute; left: 0; bottom: 0; width: var(--pw); padding: 1px 0; text-align: center; border-radius: 0 8px 0 0; font-size: .58rem; z-index: 3; }
body.is-list .amount { grid-column: 1; margin: 0; padding: 0; font-size: 1rem; white-space: nowrap; }
body.is-list .amount small { display: block; margin: 0; font-size: .6rem; letter-spacing: 0; text-transform: none; white-space: nowrap; }
body.is-list .amount.empty { min-height: 0; }
body.is-list .card button { grid-column: 2; justify-self: end; font-size: 0; width: 32px; min-height: 32px; height: 32px; padding: 0; border-radius: 50%; box-shadow: 0 2px 0 var(--red-dd); }
body.is-list .card button::before { content: "+"; font: 800 1.5rem/1 var(--text); }
body.is-list footer { margin-top: 2px; padding: 26px 0 8px; }
body.is-list footer::before { height: 16px; }
body.is-list footer .wrap { display: flex; justify-content: center; align-items: baseline; gap: 4px 14px; flex-wrap: wrap; font-size: .8rem; }
body.is-list footer .sign { display: inline; margin: 0; font-size: .95rem; }
header.top #account span { }
@media (max-width: 520px) { header.top #account span { display: none; } header.top h1 { font-size: 1.05rem; } }
@media (max-width: 599px) and (max-height: 760px) {
  body.is-list .hero h2 { display: none; }
  body.is-list .hero { padding: 32px 12px 14px; }
  body.is-list .grid { gap: 6px; padding-top: 8px; }
  body.is-list footer { padding-top: 22px; }
  body.is-list footer .wrap { font-size: .7rem; line-height: 1.25; }
  body.is-list footer .sign { font-size: .85rem; }
}
@media (max-width: 380px) { body.is-list .amount { font-size: .95rem; } }
/* tablet e computer: la foto intera cresce con l'altezza dello schermo, il pulsante torna con la scritta */
@media (min-width: 600px) {
  body.is-list { --ph: clamp(86px, 15vh, 170px); }
  body.is-list .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
  body.is-list .pic .num { width: 24px; height: 24px; font-size: .85rem; }
  body.is-list .card .body { padding: 6px 10px 8px 8px; display: flex; flex-direction: column; justify-content: center; gap: 2px; overflow: visible; }
  body.is-list .card h3 { font-size: 1.2rem; }
  body.is-list .amount { font-size: 1.3rem; }
  body.is-list .amount small { font-size: .68rem; text-transform: uppercase; }
  body.is-list .badge { font-size: .62rem; }
  body.is-list .card button { width: 100%; height: auto; min-height: 32px; border-radius: 999px; padding: 4px 10px; font-size: .9rem; }
  body.is-list .card button::before { content: none; }
}
@media (min-width: 1000px) { body.is-list .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
