/* Trama 4.9 — tutto quello che è nuovo. Le regole dello stile nuovo valgono solo sotto html.v49 (chi ha la 4.9):
   per gli altri questo file non cambia niente, tranne il pop-up delle novità (.v49-ov), che vedono tutti. */

/* ============================ pop-up «Arriva la 4.9» ============================ */
.v49-ov { --vc-bg: #FFFFFF; --vc-ink: #1C1C1E; --vc-ink2: #6C6C70; --vc-stage: #F2F2F7; --vc-line: rgba(60,60,67,.18); --vc-tint: #C98500; --vc-fill: rgba(118,118,128,.12);
  position: fixed; inset: 0; z-index: 9000; display: grid; place-items: center; padding: 20px; background: rgba(0,0,0,.42);
  -webkit-backdrop-filter: blur(10px) saturate(1.2); backdrop-filter: blur(10px) saturate(1.2); opacity: 0; transition: opacity .25s ease;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", "Segoe UI", Roboto, system-ui, sans-serif; letter-spacing: -.011em; -webkit-font-smoothing: antialiased; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .v49-ov { --vc-bg: #1C1C1E; --vc-ink: #FFFFFF; --vc-ink2: #AEAEB2; --vc-stage: #2C2C2E; --vc-line: rgba(84,84,88,.65); --vc-tint: #FFB52E; --vc-fill: rgba(118,118,128,.24); } }
[data-theme="dark"] .v49-ov { --vc-bg: #1C1C1E; --vc-ink: #FFFFFF; --vc-ink2: #AEAEB2; --vc-stage: #2C2C2E; --vc-line: rgba(84,84,88,.65); --vc-tint: #FFB52E; --vc-fill: rgba(118,118,128,.24); }
.v49-ov.in { opacity: 1; } .v49-ov.out { opacity: 0; }
.v49-card { position: relative; width: 430px; max-width: 100%; height: min(700px, calc(100dvh - 40px)); background: var(--vc-bg); color: var(--vc-ink); border-radius: 26px; overflow: hidden;
  display: flex; flex-direction: column; box-shadow: 0 30px 90px rgba(0,0,0,.35); transform: translateY(14px) scale(.97); transition: transform .35s cubic-bezier(.2,.9,.25,1); }
.v49-ov.in .v49-card { transform: none; }
.v49-bars { position: absolute; top: 12px; left: 14px; right: 50px; display: flex; gap: 4px; z-index: 3; }
.v49-bars i { flex: 1; height: 3px; border-radius: 2px; background: rgba(255,255,255,.4); overflow: hidden; box-shadow: 0 0 0 .5px rgba(0,0,0,.08); }
.v49-bars i b { display: block; height: 100%; width: 0; background: #fff; border-radius: 2px; }
.v49-bars i.done b { width: 100%; }
.v49-bars i.on b { animation: v49-bar 7s linear forwards; }
.v49-ov.paused .v49-bars i.on b { animation-play-state: paused; }
.v49-card:has(.st-stile, .st-schede, .st-condividi, .st-icone) .v49-bars i { background: rgba(0,0,0,.12); }
.v49-card:has(.st-stile, .st-schede, .st-condividi, .st-icone) .v49-bars i b { background: #1C1C1E; }
@keyframes v49-bar { to { width: 100%; } }
.v49-x { position: absolute; top: 6px; right: 8px; z-index: 4; width: 34px; height: 34px; border: 0; border-radius: 50%; background: rgba(0,0,0,.28); color: #fff; font-size: 14px; font-weight: 700; cursor: pointer; display: grid; place-items: center; }
.v49-stage { position: relative; flex: 0 0 52%; overflow: hidden; display: grid; place-items: center; background: var(--vc-stage); touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.v49-stage.st-intro, .v49-stage.st-piano { background: radial-gradient(120% 90% at 50% 20%, #3A2D10 0%, #1C1C1E 55%, #0E0E10 100%); }
.v49-text { flex: 1; padding: 22px 26px 0; overflow: auto; }
.v49-text small { display: block; font-size: 12.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--vc-tint); margin-bottom: 7px; }
.v49-text h2 { margin: 0 0 8px; font-family: inherit; font-size: 27px; font-weight: 700; line-height: 1.12; letter-spacing: -.028em; color: var(--vc-ink); }
.v49-text p { margin: 0; font-size: 16px; line-height: 1.45; color: var(--vc-ink2); }
.v49-nav { display: flex; gap: 10px; align-items: center; padding: 14px 20px calc(18px + env(safe-area-inset-bottom)); }
.v49-prev { width: 50px; height: 50px; border-radius: 15px; border: 0; background: var(--vc-fill); color: var(--vc-ink); font-size: 26px; line-height: 1; cursor: pointer; flex: none; }
.v49-next { flex: 1; height: 50px; border: 0; border-radius: 15px; background: var(--vc-ink); color: var(--vc-bg); font-size: 17px; font-weight: 600; font-family: inherit; cursor: pointer; letter-spacing: -.01em; }
@media (max-width: 600px) { .v49-ov { padding: 0; } .v49-card { width: 100%; height: 100dvh; border-radius: 0; } .v49-bars { top: calc(10px + env(safe-area-inset-top)); } .v49-x { top: calc(4px + env(safe-area-inset-top)); } }
@media (prefers-reduced-motion: reduce) { .v49-stage * { animation-duration: .01s !important; animation-delay: 0s !important; } }

/* --- illustrazione: il marchio che si intreccia --- */
.vi-intro { display: flex; flex-direction: column; align-items: center; gap: 14px; position: relative; }
.vi-mark { position: relative; width: 132px; height: 132px; }
.vi-mark i { position: absolute; border-radius: 3px; opacity: 0; animation: v49-in .55s cubic-bezier(.2,.9,.25,1) var(--d) forwards; }
.vi-mark .mh { left: 10.8px; width: 110.4px; height: 20.2px; background: #F5F5F7; transform: translateX(-34px); }
.vi-mark .h1 { top: 20.9px; } .vi-mark .h2 { top: 55.9px; } .vi-mark .h3 { top: 90.9px; }
.vi-mark .mv { top: 10.8px; height: 110.4px; width: 20.2px; background: #D9A21B; transform: translateY(-34px); }
.vi-mark .v1 { left: 20.9px; } .vi-mark .v2 { left: 55.9px; } .vi-mark .v3 { left: 90.9px; }
.vi-mark .mk { width: 20.2px; height: 20.2px; background: #F5F5F7; border-radius: 0; transform: scale(0); }
.vi-mark .k1 { left: 55.9px; top: 20.9px; } .vi-mark .k2 { left: 20.9px; top: 55.9px; } .vi-mark .k3 { left: 90.9px; top: 55.9px; } .vi-mark .k4 { left: 55.9px; top: 90.9px; }
@keyframes v49-in { to { opacity: 1; transform: none; } }
.vi-num { color: #fff; font-size: 58px; font-weight: 800; line-height: 1; letter-spacing: -.05em; opacity: 0; transform: scale(.7); animation: v49-pop .6s cubic-bezier(.3,1.4,.4,1) 1.35s forwards;
  background: linear-gradient(180deg, #fff 30%, #F5D08A); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
@keyframes v49-pop { to { opacity: 1; transform: none; } }
.vi-spark { position: absolute; left: 50%; top: 66px; width: 0; height: 0; }
.vi-spark i { position: absolute; width: 6px; height: 6px; margin: -3px; border-radius: 50%; background: #F5C04A; opacity: 0; transform: rotate(var(--a)) translateY(0); animation: v49-spark 1.1s ease-out var(--d) forwards; }
.vi-spark i:nth-child(3n) { background: #fff; width: 4px; height: 4px; } .vi-spark i:nth-child(4n) { background: #E0578C; }
@keyframes v49-spark { 0% { opacity: 0; transform: rotate(var(--a)) translateY(-10px); } 25% { opacity: 1; } 100% { opacity: 0; transform: rotate(var(--a)) translateY(-112px); } }

/* --- illustrazione: il foglio «Nuovo evento» --- */
.vi-phone { position: relative; width: 176px; height: 300px; border-radius: 30px; border: 6px solid #1C1C1E; background: #F2F2F7; overflow: hidden; box-shadow: 0 20px 40px rgba(0,0,0,.15); margin-top: 26px; font-size: 8.5px; color: #1C1C1E; }
.vi-pbg { padding: 22px 12px; animation: v49-dim .5s ease .35s forwards; }
.vi-pbg b { display: block; width: 60%; height: 12px; border-radius: 4px; background: #1C1C1E; margin-bottom: 12px; }
.vi-pbg i { display: block; height: 30px; border-radius: 8px; background: #fff; margin-bottom: 7px; }
@keyframes v49-dim { to { filter: brightness(.6); transform: scale(.94); } }
.vi-sheet { position: absolute; left: 0; right: 0; bottom: 0; top: 30px; background: #F2F2F7; border-radius: 12px 12px 0 0; padding: 0 8px; transform: translateY(105%); animation: v49-up .6s cubic-bezier(.2,.9,.25,1) .35s forwards; box-shadow: 0 -4px 16px rgba(0,0,0,.12); }
@keyframes v49-up { to { transform: none; } }
.vi-shh { display: flex; justify-content: space-between; align-items: center; height: 26px; font-size: 8px; color: #C98500; }
.vi-shh b { color: #1C1C1E; font-weight: 600; } .vi-shh .t { font-weight: 700; }
.vi-grp { background: #fff; border-radius: 8px; margin-bottom: 7px; overflow: hidden; }
.vi-row { display: flex; align-items: center; gap: 4px; min-height: 22px; padding: 0 7px; border-top: .5px solid rgba(60,60,67,.16); }
.vi-row:first-child { border-top: 0; } .vi-row > span:first-child { flex: 1; }
.vi-tt { font-weight: 500; }
.vi-sw { width: 22px; height: 13px; border-radius: 7px; background: rgba(118,118,128,.2); position: relative; animation: v49-swbg .3s ease 1.55s forwards; }
.vi-sw::after { content: ""; position: absolute; top: 1.5px; left: 1.5px; width: 10px; height: 10px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.25); animation: v49-swk .3s ease 1.55s forwards; }
@keyframes v49-swbg { to { background: #34C759; } } @keyframes v49-swk { to { left: 10.5px; } }
.vi-pill { background: rgba(118,118,128,.12); border-radius: 4px; padding: 2px 4px; animation: v49-pill .3s ease 2.05s forwards; }
.vi-pill + .vi-pill { animation: none; }
@keyframes v49-pill { to { color: #C98500; background: #FFF1D6; } }
.vi-cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px 0; padding: 4px 6px 6px; font-size: 7px; text-align: center; color: #1C1C1E; }
.vi-cal i { font-style: normal; height: 13px; display: grid; place-items: center; border-radius: 50%; }
.vi-cal i.on { animation: v49-day .45s cubic-bezier(.3,1.5,.4,1) 2.45s forwards; }
@keyframes v49-day { 0% { transform: scale(.6); } 100% { transform: none; background: #FFE7B3; color: #9A6400; font-weight: 700; } }
.vi-v { color: #8E8E93; display: flex; align-items: center; gap: 3px; } .vi-v i { width: 5px; height: 5px; border-radius: 50%; display: inline-block; }

/* --- illustrazione: le schede --- */
.vi-win { position: relative; width: 300px; height: 196px; border-radius: 12px; background: #fff; overflow: hidden; box-shadow: 0 0 0 .5px rgba(0,0,0,.12), 0 22px 44px rgba(0,0,0,.16); color: #1C1C1E; margin-top: 20px; }
.vi-wbar { height: 32px; background: #ECECEE; display: flex; align-items: flex-end; padding: 0 0 0 8px; gap: 2px; font-size: 9px; border-bottom: .5px solid rgba(0,0,0,.1); }
.vi-lights { display: flex; gap: 4px; align-self: center; margin-right: 6px; } .vi-lights i { width: 7px; height: 7px; border-radius: 50%; background: #FF5F57; } .vi-lights i:nth-child(2) { background: #FEBC2E; } .vi-lights i:nth-child(3) { background: #28C840; }
.vi-tab { display: flex; align-items: center; gap: 3px; width: 52px; height: 24px; padding: 0 5px; border-radius: 6px 6px 0 0; color: #6C6C70; transform-origin: left bottom; opacity: 0; transform: scaleX(.3);
  animation: v49-in .35s cubic-bezier(.2,.9,.25,1) var(--d) forwards, v49-tabon .9s step-end calc(1.9s + var(--n) * .9s) forwards; }
.vi-tab .ti { width: 10px; height: 10px; }
.vi-tab:nth-child(5) { animation: v49-in .35s cubic-bezier(.2,.9,.25,1) var(--d) forwards, v49-tablast .1s linear calc(1.9s + 3 * .9s) forwards; }
@keyframes v49-tabon { 0% { background: #fff; color: #1C1C1E; font-weight: 600; } 100% { background: transparent; color: #6C6C70; font-weight: 400; } }
@keyframes v49-tablast { to { background: #fff; color: #1C1C1E; font-weight: 600; } }
.vi-tplus { align-self: center; color: #8E8E93; font-size: 13px; padding: 0 6px; }
.vi-wbody { position: relative; height: calc(100% - 32px); }
.vi-wpage { position: absolute; inset: 0; padding: 14px 16px; opacity: 0; animation: v49-page .9s step-end calc(1.9s + var(--n, 0) * .9s) forwards; }
.vi-wpage.p0 { --n: 0; } .vi-wpage.p1 { --n: 1; } .vi-wpage.p2 { --n: 2; } .vi-wpage.p3 { --n: 3; animation: v49-in .2s linear calc(1.9s + 3 * .9s) forwards; }
@keyframes v49-page { 0% { opacity: 1; } 100% { opacity: 0; } }
.vi-wpage b { display: block; font-size: 15px; font-weight: 700; letter-spacing: -.02em; margin-bottom: 10px; }
.vi-wpage > i { display: block; height: 9px; border-radius: 4px; background: #E5E5EA; margin-bottom: 8px; width: 92%; } .vi-wpage > i.s { width: 60%; }
.vi-blocks, .vi-bars { display: flex; gap: 6px; align-items: flex-end; height: 90px; }
.vi-blocks i { flex: 1; border-radius: 5px; background: #DCE8FD; border-left: 3px solid #2E7CF6; } .vi-blocks i:nth-child(1) { height: 50%; } .vi-blocks i:nth-child(2) { height: 80%; background: #FDE7D2; border-color: #F08A24; } .vi-blocks i:nth-child(3) { height: 35%; }
.vi-bars i { flex: 1; border-radius: 4px 4px 2px 2px; background: #1E9FA8; } .vi-bars i:nth-child(1) { height: 40%; } .vi-bars i:nth-child(2) { height: 70%; } .vi-bars i:nth-child(3) { height: 55%; } .vi-bars i:nth-child(4) { height: 85%; }
.vi-cursor { position: absolute; width: 16px; height: 16px; left: 150px; top: 150px; opacity: 0; animation: v49-cur 3.6s cubic-bezier(.45,0,.3,1) 1.35s forwards; z-index: 2; }
.vi-cursor svg { width: 16px; height: 16px; display: block; }
@keyframes v49-cur { 0% { opacity: 0; left: 150px; top: 150px; } 12% { opacity: 1; left: 72px; top: 18px; } 37% { left: 72px; top: 18px; } 45% { left: 126px; top: 18px; } 62% { left: 126px; } 70% { left: 180px; } 87% { left: 180px; } 95% { left: 234px; } 100% { opacity: 1; left: 234px; top: 18px; } }

/* --- illustrazione: la condivisione --- */
.vi-share { position: relative; width: 320px; height: 100%; display: grid; grid-template-columns: 64px 1fr 64px; grid-template-rows: auto auto 1fr auto; align-items: center; justify-items: center; padding: 34px 6px 14px; gap: 6px 4px; color: #1C1C1E; }
.vi-who { display: flex; flex-direction: column; align-items: center; gap: 3px; opacity: 0; animation: v49-pop .5s cubic-bezier(.3,1.4,.4,1) .15s forwards; transform: scale(.6); }
.vi-who.a { animation-delay: .3s; }
.vi-who span { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 19px; background: linear-gradient(160deg, #E6B04A, #C98500); box-shadow: 0 6px 14px rgba(0,0,0,.15); }
.vi-who.a span { background: linear-gradient(160deg, #EE8AB0, #E0578C); }
.vi-who small { font-size: 10px; color: #6C6C70; }
.vi-link { width: 100%; height: 20px; } .vi-link path { stroke: #C98500; stroke-width: 2.2; fill: none; stroke-linecap: round; animation: v49-dash 1s linear infinite; }
@keyframes v49-dash { to { stroke-dashoffset: -22; } }
.vi-code { grid-column: 1 / 4; display: flex; gap: 1px; font: 700 17px ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: .04em; background: #fff; border-radius: 10px; padding: 5px 12px; box-shadow: 0 0 0 .5px rgba(0,0,0,.1); }
.vi-code i { font-style: normal; opacity: 0; animation: v49-in .12s linear var(--d) forwards; }
.vi-week { grid-column: 1 / 4; width: 100%; height: 100%; display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; }
.vi-week div { position: relative; background: #fff; border-radius: 8px; box-shadow: 0 0 0 .5px rgba(0,0,0,.06); }
.vi-week small { position: absolute; top: 3px; left: 0; right: 0; text-align: center; font-size: 8px; color: #8E8E93; }
.vi-week i { position: absolute; left: 4px; right: 4px; border-radius: 4px; }
.vi-week i.own { background: #DCE8FD; border-left: 2.5px solid #2E7CF6; }
.vi-week i.sh { background: repeating-linear-gradient(135deg, #FBE0EA 0 4px, #F6C9D9 4px 8px); border-left: 2.5px dashed #E0578C; opacity: 0; transform: translateX(26px); animation: v49-in .45s cubic-bezier(.2,.9,.25,1) var(--d) forwards; }
.vi-chips { grid-column: 1 / 4; display: flex; gap: 6px; }
.vi-chips span { font-size: 10px; padding: 3px 8px; border-radius: 10px; background: #fff; box-shadow: 0 0 0 .5px rgba(0,0,0,.1); opacity: 0; transform: translateY(6px); animation: v49-in .3s ease var(--d) forwards; }
.vi-chips span.on { background: #FFF1D6; color: #9A6400; font-weight: 600; }

/* --- illustrazione: le icone --- */
.vi-icons { width: 300px; display: flex; flex-direction: column; align-items: center; gap: 12px; margin-top: 18px; }
.vi-search { width: 100%; height: 30px; border-radius: 9px; background: rgba(118,118,128,.14); display: flex; align-items: center; gap: 6px; padding: 0 9px; color: #8E8E93; font-size: 13px; }
.vi-search svg { width: 13px; height: 13px; }
.vi-typed { color: #1C1C1E; display: inline-block; overflow: hidden; white-space: nowrap; width: 0; border-right: 1.5px solid #C98500; animation: v49-type .6s steps(5) 1.7s forwards, v49-caret .8s step-end infinite; }
@keyframes v49-type { to { width: 5.1ch; } } @keyframes v49-caret { 50% { border-color: transparent; } }
.vi-grid { display: grid; grid-template-columns: repeat(5, 46px); gap: 10px 12px; }
.vi-it { opacity: 0; transform: scale(.3); animation: v49-bounce .5s cubic-bezier(.3,1.5,.4,1) var(--d) forwards; }
.vi-it .ti-tile { width: 46px; height: 46px; border-radius: 13px; } .vi-it .ti-tile .ti { width: 28px; height: 28px; }
@keyframes v49-bounce { to { opacity: 1; transform: none; } }
.vi-it.hit .ti-tile { animation: v49-ring .5s ease 2.35s forwards; }
@keyframes v49-ring { to { box-shadow: 0 0 0 3px #fff, 0 0 0 5.5px #E5534B; } }
.vi-colors { display: flex; gap: 9px; } .vi-colors i { width: 20px; height: 20px; border-radius: 50%; opacity: 0; transform: scale(.4); animation: v49-bounce .4s cubic-bezier(.3,1.5,.4,1) var(--d) forwards; }
.vi-colors i:first-child { box-shadow: 0 0 0 2px #F2F2F7, 0 0 0 3.5px #E5534B; }
/* l'illustrazione delle icone usa le .ti-tile dell'app anche per chi non ha ancora la 4.9 */
.v49-ov .ti-tile { display: inline-grid; place-items: center; background: color-mix(in srgb, var(--ac) 15%, #fff); }

/* --- illustrazione: il piano e la carta --- */
.vi-pay { display: flex; flex-direction: column; align-items: center; gap: 16px; margin-top: 16px; }
.vi-card { position: relative; width: 236px; height: 146px; border-radius: 16px; padding: 16px 18px; color: #fff; background: linear-gradient(135deg, #2C2C2E 0%, #1C1C1E 45%, #6B4A0C 100%);
  box-shadow: 0 24px 50px rgba(0,0,0,.45), inset 0 0 0 .5px rgba(255,255,255,.15); opacity: 0; transform: translateY(40px) rotate(-9deg); animation: v49-card .8s cubic-bezier(.2,.9,.25,1) .25s forwards; }
@keyframes v49-card { to { opacity: 1; transform: rotate(-3deg); } }
.vi-chip { position: absolute; left: 18px; top: 46px; width: 30px; height: 22px; border-radius: 5px; background: linear-gradient(135deg, #F5D08A, #C99A3A); }
.vi-mk { position: absolute; right: 18px; top: 16px; display: grid; gap: 3px; } .vi-mk i { display: block; width: 22px; height: 4px; border-radius: 1px; background: #D9A21B; }
.vi-card b { position: absolute; left: 18px; bottom: 34px; font: 600 15px ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: .08em; }
.vi-card small { position: absolute; left: 18px; bottom: 16px; font-size: 10px; color: rgba(255,255,255,.7); }
.vi-brand { position: absolute; right: 18px; bottom: 14px; font-weight: 800; font-style: italic; font-size: 15px; letter-spacing: .02em; }
.vi-wallets { display: flex; gap: 7px; } .vi-wallets span { font-size: 11.5px; font-weight: 600; color: #fff; padding: 5px 11px; border-radius: 14px; background: rgba(255,255,255,.12); box-shadow: inset 0 0 0 .5px rgba(255,255,255,.25); opacity: 0; transform: translateY(8px); animation: v49-in .35s ease var(--d) forwards; }
.vi-receipt { display: flex; align-items: center; gap: 8px; color: #fff; font-size: 12.5px; opacity: 0; transform: translateY(8px); animation: v49-in .4s ease var(--d) forwards; }
.vi-receipt i { width: 20px; height: 20px; border-radius: 50%; background: #34C759; display: grid; place-items: center; font-style: normal; font-size: 11px; font-weight: 800; }

/* ============================ pannello «Trama 4.9» e segno dell'anteprima ============================ */
a.v49-chip, .nav a.v49-chip { display: inline-flex; align-items: center; margin-left: 8px; font: 700 10.5px/1 system-ui, -apple-system, sans-serif; letter-spacing: .02em; text-decoration: none; padding: 4px 7px; min-height: 0; border: 0; border-radius: 6px; background: color-mix(in srgb, var(--dawn) 20%, var(--surface)); color: var(--dawn-ink); white-space: nowrap; flex: none; }
a.v49-chip:not(.on), .nav a.v49-chip:not(.on) { background: rgba(118,118,128,.14); color: var(--ink-3); }
#topbar .v49-chip { margin: 0 auto 0 6px; }
.v49-adm { max-width: 720px; }
.v49-state { display: flex; align-items: center; gap: 14px; padding: 16px 18px; margin-bottom: 8px; }
.v49-state b { display: block; font-size: 17px; } .v49-state small { display: block; color: var(--ink-3); font-size: .86rem; line-height: 1.4; margin-top: 2px; }
.v49-dot { width: 12px; height: 12px; border-radius: 50%; background: #F5A623; flex: none; box-shadow: 0 0 0 4px rgba(245,166,35,.18); }
.v49-state.live .v49-dot { background: #34C759; box-shadow: 0 0 0 4px rgba(52,199,89,.18); }
.v49-row { display: flex; align-items: center; gap: 12px; padding: .8rem 1rem; border-top: 1px solid var(--line-2); }
.v49-row b { display: block; } .v49-row small { display: block; color: var(--ink-3); font-size: .84rem; }
.v49-row input[type="email"] { flex: 1; min-width: 0; }
.v49-adm .s-switch + .s-switch, .v49-adm .s-switch + .v49-row { border-top: 1px solid var(--line-2); }
.v49-adm .card.list > :first-child { border-top: 0; }

/* =====================================================================================================
   4.9 — STILE APPLE. Vale solo con html.v49 (admin in anteprima, tester, o tutti dopo il rilascio):
   per gli altri Trama resta identica alla 4.8. «:where(.v49)» non aggiunge peso ai selettori: ogni regola
   qui sotto si comporta come se correggesse quella originale di app.css, senza scavalcare le varianti.
   ===================================================================================================== */
html.v49 {
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI Variable Text", "Segoe UI", Roboto, "Helvetica Neue", Inter, system-ui, sans-serif;
  --serif: var(--sans);
  --r: 14px; --r-sm: 10px;
  --fill: rgba(118,118,128,.12); --fill-2: rgba(118,118,128,.07);
  --sep: rgba(60,60,67,.17); --sw-on: #34C759; --sheet: var(--bg); --cell: var(--surface);
}
/* scuro: i fogli «salgono» di un gradino (come su iOS), altrimenti sparirebbero sul nero */
html.v49[data-theme="dark"] { --fill: rgba(118,118,128,.26); --fill-2: rgba(118,118,128,.16); --sep: rgba(84,84,88,.6); --sw-on: #30D158; --sheet: var(--surface); --cell: var(--surface-2); }
@media (prefers-color-scheme: dark) { html.v49:not([data-theme="light"]) { --fill: rgba(118,118,128,.26); --fill-2: rgba(118,118,128,.16); --sep: rgba(84,84,88,.6); --sw-on: #30D158; --sheet: var(--surface); --cell: var(--surface-2); } }
/* Alba (il tema di partenza) diventa i grigi di iOS con l'accento ambra; gli altri temi tengono i loro colori */
html.v49:not([data-palette]) {
  --bg: #F2F2F7; --surface: #FFFFFF; --surface-2: #EBEBF0; --ink: #1C1C1E; --ink-2: #636366; --ink-3: #8E8E93;
  --line: #D8D8DD; --line-2: #E8E8ED; --dawn: #C98500; --dawn-soft: #FFF3D9; --dawn-ink: #A66C00; --dusk: #8E8E93; --dusk-soft: #EBEBF0;
  --pat: none; --hero: #1C1C1E; --today: #FF3B30;
  --shadow: 0 1px 2px rgba(0,0,0,.035); --shadow-lg: 0 22px 60px rgba(0,0,0,.2);
  --amb-1: transparent; --amb-2: transparent; --amb-3: transparent;
}
html.v49:not([data-palette])[data-theme="dark"] {
  --bg: #000000; --surface: #1C1C1E; --surface-2: #2C2C2E; --ink: #F5F5F7; --ink-2: #AEAEB2; --ink-3: #8E8E93;
  --line: #38383A; --line-2: #2C2C2E; --dawn: #FFB52E; --dawn-soft: #33270F; --dawn-ink: #FFC456; --dusk: #8E8E93; --dusk-soft: #2C2C2E;
  --hero: #1C1C1E; --shadow: none; --shadow-lg: 0 22px 60px rgba(0,0,0,.6);
}
@media (prefers-color-scheme: dark) { html.v49:not([data-palette]):not([data-theme="light"]) {
  --bg: #000000; --surface: #1C1C1E; --surface-2: #2C2C2E; --ink: #F5F5F7; --ink-2: #AEAEB2; --ink-3: #8E8E93;
  --line: #38383A; --line-2: #2C2C2E; --dawn: #FFB52E; --dawn-soft: #33270F; --dawn-ink: #FFC456; --dusk: #8E8E93; --dusk-soft: #2C2C2E;
  --hero: #1C1C1E; --shadow: none; --shadow-lg: 0 22px 60px rgba(0,0,0,.6);
} }
html.v49:not([data-palette]) body::after { display: none; }
:where(html.v49) body { letter-spacing: -.008em; }

/* --- testi: un solo carattere, titoli in neretto come su iPhone --- */
:where(html.v49) h1, :where(html.v49) h2, :where(html.v49) h3 { font-weight: 700; letter-spacing: -.022em; }
:where(html.v49) .s-h1 { font-weight: 700; letter-spacing: -.028em; font-size: clamp(1.9rem, 6vw, 2.25rem); }
:where(html.v49) .page-head h1 { font-weight: 700; letter-spacing: -.028em; }
:where(html.v49) .s-date, :where(html.v49) .page-head .date { letter-spacing: .01em; font-size: .8rem; font-weight: 600; color: var(--ink-3); }
:where(html.v49) .s-sum { color: var(--ink-3); }
:where(html.v49) .s-lbl { font-size: 1.3rem; letter-spacing: -.02em; text-transform: none; color: var(--ink); font-weight: 700; margin: 1.6rem .15rem .55rem; }
:where(html.v49) .s-lbl a, :where(html.v49) .s-lbl button { font-size: .95rem; font-weight: 400; color: var(--dawn-ink); }
:where(html.v49) .pt-sec, :where(html.v49) .nav-group .gt { letter-spacing: .02em; font-weight: 600; }
:where(html.v49) .card-head h2, :where(html.v49) .section-title h2 { font-weight: 700; font-size: 1.1rem; letter-spacing: -.015em; }
:where(html.v49) .s-asegbar b { font-weight: 700; letter-spacing: -.02em; }
:where(html.v49) .mono { font-family: var(--sans); font-variant-numeric: tabular-nums; }

/* --- carte e liste raggruppate: niente bordi, separatori sottili rientrati --- */
:where(html.v49) .card { border: 0; box-shadow: var(--shadow); border-radius: var(--r); }
:where(html.v49) .s-tile { border: 0; box-shadow: var(--shadow); border-radius: 16px; }
:where(html.v49) .s-tile.add { border: 1.5px dashed var(--line); background: transparent; }
:where(html.v49) .s-task, :where(html.v49) .s-evl, :where(html.v49) .s-links a, :where(html.v49) .s-menu button, :where(html.v49) .s-sp { border-bottom: 0; position: relative; }
:where(html.v49) .s-task + .s-task::before, :where(html.v49) .s-evl + .s-evl::before, :where(html.v49) .s-links a + a::before, :where(html.v49) .s-sp + .s-sp::before {
  content: ''; position: absolute; top: 0; right: 0; left: var(--sep-l, 3.4rem); height: 1px; background: var(--sep); transform: scaleY(.6); transform-origin: top; }
:where(html.v49) .s-evl + .s-evl::before { --sep-l: 1.9rem; }
:where(html.v49) .s-links a + a::before { --sep-l: 3.2rem; }
:where(html.v49) .s-sp + .s-sp::before { --sep-l: 3.6rem; }
:where(html.v49) .card > .task, :where(html.v49) .card > .event, :where(html.v49) .card > .tx, :where(html.v49) .card > .cat-row, :where(html.v49) .card > .menu-list > a { border-top-color: var(--sep); }
:where(html.v49) .s-ck { border: 1.6px solid color-mix(in srgb, var(--ink-3) 70%, transparent); width: 24px; height: 24px; }
:where(html.v49) .s-ck.on { background: var(--dawn); border-color: var(--dawn); }
:where(html.v49) .s-ck:hover { border-color: var(--dawn); }
:where(html.v49) .s-tt small { color: var(--ink-3); }
:where(html.v49) .s-evl i { width: 3.5px; }
:where(html.v49) .s-evl small { color: var(--ink-3); }

/* --- il prossimo impegno: una carta bianca pulita (Alba); negli altri temi resta il loro colore --- */
html.v49:not([data-palette]) .s-now, html.v49:not([data-palette])[data-theme="dark"] .s-now { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); padding: 1rem 1.1rem 1rem 1.45rem; border-radius: 16px; }
@media (prefers-color-scheme: dark) { html.v49:not([data-palette]):not([data-theme="light"]) .s-now { background: var(--surface); color: var(--ink); box-shadow: none; } }
html.v49:not([data-palette]) .s-now::before { left: .75rem; top: 1rem; bottom: 1rem; width: 4px; border-radius: 3px; }
:where(html.v49) .s-now small { letter-spacing: .01em; text-transform: none; font-size: .82rem; font-weight: 600; color: var(--dawn-ink); opacity: 1; }
html.v49[data-palette] .s-now small { color: inherit; opacity: .8; }
:where(html.v49) .s-now b { font-weight: 700; font-size: 1.3rem; letter-spacing: -.02em; }
:where(html.v49) .s-now span { opacity: 1; color: var(--ink-3); }
html.v49[data-palette] .s-now span { color: inherit; opacity: .82; }

/* --- pulsanti --- */
:where(html.v49) .btn { border: 0; background: var(--fill); border-radius: 12px; font-weight: 600; color: var(--ink); }
:where(html.v49) .btn:hover { background: color-mix(in srgb, var(--fill) 100%, var(--fill-2)); filter: brightness(.97); }
:where(html.v49) .btn.primary, :where(html.v49) .btn.dawn { background: var(--ink); color: var(--bg); }
html.v49:not([data-palette]) .btn.primary { color: var(--surface); }
:where(html.v49) .btn.ghost { background: transparent; color: var(--dawn-ink); font-weight: 500; }
:where(html.v49) .btn.ghost:hover { background: var(--fill-2); filter: none; }
:where(html.v49) .btn.danger { color: var(--warn); }
:where(html.v49) .btn.sm { border-radius: 10px; }
:where(html.v49) .s-addb { border: 0; background: var(--fill); border-radius: 999px; color: var(--dawn-ink); }
:where(html.v49) .s-link { color: var(--dawn-ink); }
/* il segmento come quello di iOS: fondo grigio, la scelta su una pastiglia bianca */
:where(html.v49) .seg { border: 0; background: var(--fill); border-radius: 10px; padding: 2px; gap: 0; }
:where(html.v49) .seg button, :where(html.v49) .seg a { border-radius: 8px; color: var(--ink); font-weight: 500; min-height: 32px; padding: .3rem .85rem; font-size: .88rem; }
:where(html.v49) .seg button.on, :where(html.v49) .seg a.on { background: var(--surface); color: var(--ink); font-weight: 600; box-shadow: 0 3px 8px rgba(0,0,0,.12), 0 3px 1px rgba(0,0,0,.04); }
html.v49[data-theme="dark"] .seg button.on, html.v49[data-theme="dark"] .seg a.on { background: #636366; color: #fff; }
@media (prefers-color-scheme: dark) { html.v49:not([data-theme="light"]) .seg button.on, html.v49:not([data-theme="light"]) .seg a.on { background: #636366; color: #fff; } }

/* --- interruttori al posto delle caselle (a destra, come in Impostazioni di iPhone) --- */
:where(html.v49) .s-switch input, :where(html.v49) .pers-row input[type=checkbox], :where(html.v49) .ev-onlyday input, :where(html.v49) label.row.small > input[type=checkbox], :where(html.v49) .v49-sw {
  -webkit-appearance: none; appearance: none; width: 51px; height: 31px; border-radius: 16px; background: var(--fill); position: relative; flex: none; margin: 0; cursor: pointer; transition: background .2s; border: 0; accent-color: auto; }
:where(html.v49) .s-switch input::after, :where(html.v49) .pers-row input[type=checkbox]::after, :where(html.v49) .ev-onlyday input::after, :where(html.v49) label.row.small > input[type=checkbox]::after, :where(html.v49) .v49-sw::after {
  content: ''; position: absolute; top: 2px; left: 2px; width: 27px; height: 27px; border-radius: 50%; background: #fff; box-shadow: 0 3px 8px rgba(0,0,0,.15), 0 1px 1px rgba(0,0,0,.08); transition: transform .22s cubic-bezier(.3,.7,.4,1); }
:where(html.v49) .s-switch input:checked, :where(html.v49) .pers-row input[type=checkbox]:checked, :where(html.v49) .ev-onlyday input:checked, :where(html.v49) label.row.small > input[type=checkbox]:checked, :where(html.v49) .v49-sw:checked { background: var(--sw-on); }
:where(html.v49) .s-switch input:checked::after, :where(html.v49) .pers-row input[type=checkbox]:checked::after, :where(html.v49) .ev-onlyday input:checked::after, :where(html.v49) label.row.small > input[type=checkbox]:checked::after, :where(html.v49) .v49-sw:checked::after { transform: translateX(20px); }
:where(html.v49) .s-switch input:disabled, :where(html.v49) .v49-sw:disabled { opacity: .45; cursor: default; }
:where(html.v49) .s-switch, :where(html.v49) .pers-row, :where(html.v49) .ev-onlyday, :where(html.v49) label.row.small:has(> input[type=checkbox]) { flex-direction: row-reverse; justify-content: space-between; align-items: center; gap: 1rem; }
:where(html.v49) .s-switch > :not(input), :where(html.v49) .pers-row > :not(input) { flex: 1; min-width: 0; }
:where(html.v49) .s-switch input { margin-top: 0; }
:where(html.v49) .ev-onlyday { color: var(--ink); font-size: .95rem; }

/* --- campi fuori dai fogli (ricerche, budget, impostazioni) --- */
:where(html.v49) .field input, :where(html.v49) .field select, :where(html.v49) .field textarea { border: 0; background: var(--fill-2); border-radius: 10px; }
:where(html.v49) .field input:focus, :where(html.v49) .field select:focus, :where(html.v49) .field textarea:focus { box-shadow: 0 0 0 2px var(--dawn); }
:where(html.v49) .s-search { background: var(--fill); border-radius: 10px; }
:where(html.v49) .s-chip span { border: 0; background: var(--fill); color: var(--ink); }
:where(html.v49) .s-chip input:checked + span { background: var(--ink); color: var(--surface); }

/* --- barra laterale (computer): come la barra di un'app del Mac --- */
@media (min-width: 700px) {
  :where(html.v49) .nav { background: color-mix(in srgb, var(--surface) 55%, var(--bg)); border-right: 1px solid var(--sep); }
  :where(html.v49) .nav a { border-radius: 8px; font-size: .94rem; color: var(--ink); }
  :where(html.v49) .nav a:hover { background: var(--fill-2); }
  :where(html.v49) .nav a.active { background: var(--fill); border: 0; padding-top: .5rem; padding-bottom: .5rem; font-weight: 600; }
  html.v49 .nav a.active::before { display: none; }
  :where(html.v49) .brand { font-weight: 700; letter-spacing: -.02em; font-size: 1.2rem; }
  :where(html.v49) .capture form { border: 0; background: var(--surface); box-shadow: 0 1px 2px rgba(0,0,0,.05), 0 0 0 1px var(--sep); border-radius: 12px; }
  :where(html.v49) .capture form:focus-within { box-shadow: 0 0 0 2px var(--dawn); }
  :where(html.v49) .capture .go { border-radius: 9px; }
}
/* --- telefono e tablet: barre traslucide come su iOS --- */
@media (max-width: 699px) {
  :where(html.v49) .topbar { background: color-mix(in srgb, var(--bg) 82%, transparent); -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px); border-bottom: 1px solid var(--sep); }
  :where(html.v49) .topbar .brand { font-weight: 700; font-size: 1.12rem; }
  :where(html.v49) .tabbar { background: color-mix(in srgb, var(--surface) 80%, transparent); -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px); border-top: 1px solid var(--sep); }
  :where(html.v49) .tabbar .s-tab { font-size: .68rem; font-weight: 500; color: var(--ink-3); }
  :where(html.v49) .tabbar .s-tab.active { color: var(--ink); font-weight: 600; }
  html.v49 .tabbar .s-tab:not(.active) .ti-tile { filter: grayscale(1); opacity: .55; }
  html.v49 .tabbar .s-tab.active .ti-tile.tb { background: transparent; }
  :where(html.v49) .s-plus { border-radius: 50%; width: 52px; height: 52px; box-shadow: 0 6px 16px rgba(0,0,0,.2); }
}
html.v49:not([data-palette]) .s-plus { background: var(--ink); color: var(--surface); }
:where(html.v49) .avatar { background: linear-gradient(160deg, #E0A526, #B97800); color: #fff; }

/* --- foglio «Cosa vuoi aggiungere?» --- */
:where(html.v49) .s-plus-ov { background: rgba(0,0,0,.32); }
:where(html.v49) .s-plus-sh { background: var(--sheet); border-radius: 14px 14px 0 0; }
:where(html.v49) .s-plus-sh h2 { font-weight: 700; font-size: 1.3rem; letter-spacing: -.02em; }
:where(html.v49) .s-plus-sh .grab { background: color-mix(in srgb, var(--ink-3) 50%, transparent); width: 36px; }
:where(html.v49) .s-qk button { border: 0; background: var(--cell); border-radius: 14px; color: var(--ink); font-weight: 500; }
:where(html.v49) .s-capslot .capture.in-sheet form { border: 0; box-shadow: 0 0 0 1px var(--sep); background: var(--surface); border-radius: 12px; }
@media (min-width: 700px) { :where(html.v49) .s-plus-sh { border-radius: 16px; } }
:where(html.v49) .toast { border-radius: 14px; background: color-mix(in srgb, var(--ink) 92%, transparent); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); font-weight: 500; }

/* =====================================================================================================
   4.9 — I FOGLI (tutti i moduli): «Annulla · Titolo · Salva», sfondo grigio, campi in gruppi bianchi
   ===================================================================================================== */
.v49-mbg { background: rgba(0,0,0,.34); animation: v49fade .2s ease; }
@keyframes v49fade { from { opacity: 0; } }
.modal.v49-sheet { background: var(--sheet); padding: 0; border-radius: 14px 14px 0 0; max-height: 94dvh; display: flex; flex-direction: column; overflow: hidden; box-shadow: var(--shadow-lg); animation: v49up .32s cubic-bezier(.2,.85,.25,1); }
@keyframes v49up { from { transform: translateY(40px); opacity: .4; } }
@media (min-width: 640px) { .modal.v49-sheet { border-radius: 16px; max-height: 88dvh; animation: v49pop .24s cubic-bezier(.2,.85,.25,1); } @keyframes v49pop { from { transform: scale(.96); opacity: 0; } } }
.v49-grab { display: block; width: 36px; height: 5px; border-radius: 3px; background: color-mix(in srgb, var(--ink-3) 45%, transparent); margin: 6px auto 0; flex: none; }
@media (min-width: 640px) { .v49-grab { display: none; } }
.v49-mh { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: .5rem; padding: .35rem .6rem .45rem; min-height: 52px; flex: none; }
.v49-mh h2 { margin: 0 !important; font-size: 1.04rem !important; font-weight: 600 !important; letter-spacing: -.015em; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 62vw; font-family: var(--sans) !important; }
.v49-mh-a { background: none; border: 0; color: var(--dawn); font: inherit; font-size: 1.04rem; padding: .45rem .5rem; cursor: pointer; justify-self: start; border-radius: 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.v49-mh-a.b { font-weight: 600; justify-self: end; }
.v49-mh-a:disabled { color: var(--ink-3); }
.v49-mh-a:hover { background: var(--fill-2); }
.v49-mb { overflow-y: auto; -webkit-overflow-scrolling: touch; padding: .3rem 1rem max(1.2rem, env(safe-area-inset-bottom)); flex: 1; overscroll-behavior: contain; }
.v49-sheet .v49-mb > p, .v49-sheet .v49-mb > .small { margin-left: .2rem; margin-right: .2rem; }

/* i campi: celle bianche; quelli corti su una riga (etichetta · valore), gli altri con l'etichetta sopra */
.v49-sheet .field { background: var(--cell); border-radius: 12px; padding: .55rem 1rem .65rem; margin: 0 0 .75rem; gap: .25rem; }
.v49-sheet .field > label { font-size: .8rem; color: var(--ink-3); font-weight: 500; }
.v49-sheet .field input:not([type=checkbox]):not([type=radio]), .v49-sheet .field select, .v49-sheet .field textarea { border: 0; background: transparent; padding: .2rem 0; min-height: 32px; border-radius: 0; box-shadow: none; font-size: 17px; color: var(--ink); }
.v49-sheet .field input:focus, .v49-sheet .field select:focus, .v49-sheet .field textarea:focus { box-shadow: none; }
.v49-sheet .field.v49-r { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; min-height: 48px; padding: .3rem 1rem; gap: .25rem .75rem; }
.v49-sheet .field.v49-r > label { font-size: 17px; color: var(--ink); font-weight: 400; flex: 1; min-width: 0; }
.v49-sheet .field.v49-r > select { width: auto; max-width: 62%; text-align: right; text-align-last: right; color: var(--ink-3); -webkit-appearance: none; appearance: none; padding-right: 1.1rem; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='16' viewBox='0 0 10 16'%3E%3Cpath d='M2 4l4 4-4 4' fill='none' stroke='%238E8E93' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right center / 9px 14px; cursor: pointer; }
.v49-sheet .field.v49-r > input[type=time], .v49-sheet .field.v49-r > input[type=number] { width: auto; min-width: 0; background: var(--fill); border-radius: 8px; padding: .3rem .65rem; text-align: center; min-height: 34px; font-variant-numeric: tabular-nums; }
.v49-sheet .field.v49-r > input[type=number] { max-width: 6.5rem; }
.v49-sheet .field input::-webkit-calendar-picker-indicator { opacity: .35; }
.v49-sheet input[type=time]::-webkit-calendar-picker-indicator { display: none; }
.v49-sheet .field textarea { resize: vertical; line-height: 1.4; }
.v49-sheet .field .seg { display: flex; width: 100%; margin-top: .15rem; }
.v49-sheet .field .seg button { flex: 1; justify-content: center; }
.v49-sheet .field .row { gap: .5rem; }
/* due campi affiancati (vecchio .grid2) → un solo gruppo con le righe una sotto l'altra */
.v49-sheet .grid2 { display: block; background: var(--cell); border-radius: 12px; margin: 0 0 .75rem; overflow: hidden; }
.v49-sheet .grid2 > .field, .v49-grp > .field, .v49-grp > .v49-row { margin: 0; border-radius: 0; background: transparent; }
.v49-sheet .grid2 > * + *, .v49-grp > * + * { background-image: linear-gradient(var(--sep), var(--sep)); background-repeat: no-repeat; background-size: calc(100% - 1rem) 1px; background-position: right top; }
/* i gruppi del modulo evento */
.v49-grp { background: var(--cell); border-radius: 12px; margin: 0 0 .9rem; overflow: hidden; }
.v49-grp > textarea, .v49-title { display: block; width: 100%; border: 0; background: transparent; font: inherit; font-size: 17px; color: var(--ink); padding: .8rem 1rem; outline: 0; resize: vertical; min-height: 50px; }
.v49-title { font-weight: 500; }
.v49-title::placeholder, .v49-grp > textarea::placeholder { color: var(--ink-3); opacity: .8; }
.v49-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 50px; padding: .35rem 1rem; cursor: pointer; font-size: 17px; }
.v49-row > span { flex: 1; min-width: 0; }
.v49-ad .v49-tm { display: none !important; }
.v49-grp .rec-opts { padding: .2rem 1rem .8rem; }
.v49-grp .field:not(.v49-r) { padding-top: .7rem; }
/* la data: pastiglia; il calendario si apre dentro il foglio */
.v49-dhid { position: absolute !important; opacity: 0 !important; pointer-events: none !important; width: 1px !important; height: 1px !important; min-height: 0 !important; padding: 0 !important; margin: 0 !important; }
.field:has(> .v49-dhid), .rec-row:has(> .v49-dhid) { position: relative; }
.v49-dp { border: 0; background: var(--fill); color: var(--ink); font: inherit; font-size: 17px; border-radius: 8px; padding: .32rem .7rem; cursor: pointer; white-space: nowrap; min-height: 34px; font-variant-numeric: tabular-nums; }
.v49-dp.open { color: var(--dawn); }
.v49-dp.none { color: var(--ink-3); }
.v49-cal { padding: .2rem .7rem .7rem; background: var(--cell); animation: v49cal .2s ease; }
@keyframes v49cal { from { opacity: 0; transform: translateY(-4px); } }
.field + .v49-cal, .rec-row + .v49-cal { border-radius: 0 0 12px 12px; margin: -.75rem 0 .75rem; }
.v49-grp > .v49-cal, .grid2 > .v49-cal, .rec-opts .v49-cal { margin: 0; border-radius: 0; }
.v49-calh { display: flex; justify-content: space-between; align-items: center; padding: .5rem .35rem .35rem; }
.v49-calh b { font-size: 1.02rem; font-weight: 600; text-transform: lowercase; }
.v49-calh span { display: flex; gap: .3rem; }
.v49-calh button { border: 0; background: none; color: var(--dawn); font-size: 1.6rem; line-height: 1; width: 40px; height: 36px; border-radius: 8px; cursor: pointer; }
.v49-calh button:hover { background: var(--fill-2); }
.v49-calw, .v49-cald { display: grid; grid-template-columns: repeat(7, 1fr); text-align: center; }
.v49-calw i { font-style: normal; font-size: .75rem; font-weight: 600; color: var(--ink-3); padding: .2rem 0 .35rem; }
.v49-cald button { border: 0; background: none; font: inherit; font-size: 1.1rem; color: var(--ink); height: 42px; display: grid; place-items: center; cursor: pointer; position: relative; font-variant-numeric: tabular-nums; }
.v49-cald button::before { content: ''; position: absolute; width: 38px; height: 38px; border-radius: 50%; z-index: -1; }
.v49-cald button { z-index: 0; }
.v49-cald button:hover::before { background: var(--fill-2); }
.v49-cald button.tdy { color: var(--dawn); font-weight: 600; }
.v49-cald button.sel { color: var(--dawn); font-weight: 700; }
.v49-cald button.sel::before { background: color-mix(in srgb, var(--dawn) 16%, transparent); }
.v49-calf { display: flex; justify-content: space-between; padding: .4rem .3rem 0; }
.v49-calf button { border: 0; background: none; color: var(--dawn); font: inherit; font-size: .95rem; cursor: pointer; padding: .3rem .4rem; }
/* in fondo: il pulsante grande (etichette lunghe) e le azioni come «Elimina» */
.v49-mx { flex-direction: column; align-items: stretch; gap: .6rem; margin: .4rem 0 0; }
.v49-mx .btn { width: 100%; min-height: 50px; border-radius: 12px; font-size: 1.02rem; margin: 0 !important; }
.v49-mx .btn.primary.v49-big { background: var(--ink); color: var(--surface); }
.v49-mx .btn.danger-solid, .v49-mx .btn.danger, .v49-mx #ev-del, .v49-mx #tx-del { background: var(--cell); color: var(--warn); border: 0; font-weight: 500; }
.v49-mx .left { margin-right: 0; }
.v49-sheet .f-hint, .v49-sheet .rec-summary { margin-left: .2rem; }
.v49-sheet .ev-onlyday { background: var(--cell); border-radius: 12px; padding: .5rem 1rem; min-height: 50px; margin: 0 0 .75rem; }

/* Registra: il tipo in alto, l'importo grande al centro, la descrizione sotto */
.v49-sheet .field:has(.tx-kind) { background: transparent; padding: 0; }
.v49-sheet .field:has(.tx-kind) > label, .v49-sheet .field:has(> input[name=amount]) > label, .v49-sheet .field:has(> #txdesc) > label { display: none; }
.v49-sheet .tx-save .seg { display: flex; margin-bottom: .5rem; } .v49-sheet .tx-save .seg button { flex: 1; justify-content: center; }
.v49-sheet .field:has(> input[name=amount]) { background: transparent; padding: .6rem 0 0; margin: 0; }
.v49-sheet .field > input[name=amount] { text-align: center; font-size: 3.4rem !important; font-weight: 700; letter-spacing: -.035em; min-height: 76px !important; font-variant-numeric: tabular-nums; caret-color: var(--dawn); }
.v49-sheet .field > input[name=amount]::placeholder { color: color-mix(in srgb, var(--ink-3) 55%, transparent); }
.v49-sheet .field:has(> #txdesc) { background: transparent; padding: 0 0 .6rem; }
.v49-sheet .field > #txdesc { text-align: center; font-size: 1.1rem; }
.v49-sheet .qf-more { display: inline-block; margin: 0 .2rem .8rem; color: var(--dawn); cursor: pointer; }
.v49-sheet .moods { justify-content: space-between; }
/* scheda «Nuova» (cosa da fare / impegno in un colpo) */
.v49-sheet .s-bigin { background: var(--cell) !important; border: 0 !important; border-radius: 12px !important; padding: .8rem 1rem !important; font: 500 17px/1.3 var(--sans) !important; margin-bottom: .9rem; }
.v49-sheet .s-fld { background: var(--cell); border-radius: 12px; padding: .7rem 1rem .85rem; margin-bottom: .75rem; border: 0; }
.v49-sheet .s-fld > small { letter-spacing: 0; text-transform: none; font-size: .8rem; font-weight: 500; color: var(--ink-3); }
.v49-sheet .s-times input { border: 0; background: var(--fill); border-radius: 8px; text-align: center; font-variant-numeric: tabular-nums; }
.v49-sheet .s-fld .v49-dp { margin-top: .6rem; }
.v49-sheet .s-fld + .v49-cal { margin: -.75rem 0 .75rem; border-radius: 0 0 12px 12px; }
.v49-sheet .qf-more { text-decoration: none; font-size: .95rem; }
.v49-dp[hidden] { display: none; }
/* i pulsanti «Chiaro/Scuro» portano data-theme: senza questo ereditano i colori del tema che rappresentano */
html.v49 #theme-seg button[data-theme] { --ink: inherit; --ink-2: inherit; --ink-3: inherit; --surface: inherit; --bg: inherit; --line: inherit; --dawn: inherit; }
/* segmenti secondari (Settimana · Mese · Anno, Termina: Mai · In una data…) come quello principale */
:where(html.v49) .rec-seg { border: 0; background: var(--fill); border-radius: 10px; padding: 2px; gap: 0; }
:where(html.v49) .rec-seg button, :where(html.v49) .rec-seg label span { color: var(--ink); font-weight: 500; height: 30px; }
:where(html.v49) .rec-seg button.on, :where(html.v49) .rec-seg label input:checked + span { background: var(--surface); color: var(--ink); font-weight: 600; box-shadow: 0 3px 8px rgba(0,0,0,.12), 0 3px 1px rgba(0,0,0,.04); }
html.v49[data-theme="dark"] .rec-seg button.on, html.v49[data-theme="dark"] .rec-seg label input:checked + span { background: #636366; color: #fff; }
@media (prefers-color-scheme: dark) { html.v49:not([data-theme="light"]) .rec-seg button.on, html.v49:not([data-theme="light"]) .rec-seg label input:checked + span { background: #636366; color: #fff; } }
:where(html.v49) .tpl { border-style: solid; border-color: transparent; background: var(--surface); box-shadow: var(--shadow); }

/* =====================================================================================================
   4.9 — ICONE: pannello con ricerca, colori, categorie a pastiglie, sezioni in celle bianche
   ===================================================================================================== */
.emj49 { gap: .6rem; }
.emj49 .emj-sbox { border: 0; background: var(--fill); border-radius: 10px; padding: 0 .65rem; }
.emj49 .emj-sbox .emj-search { font-size: 16px; padding: .5rem 0; background: transparent; border: 0; }
.e49-cols { display: flex; gap: .45rem; overflow-x: auto; scrollbar-width: none; padding: .15rem .1rem; }
.e49-cols::-webkit-scrollbar { display: none; }
.e49-c { flex: none; width: 28px; height: 28px; border-radius: 50%; border: 0; padding: 0; cursor: pointer; background: var(--cc, conic-gradient(#E5534B, #F2A516, #3DAA55, #14A8C7, #5B6CF0, #E0578C, #E5534B)); display: grid; place-items: center; }
.e49-c i { width: 100%; height: 100%; border-radius: 50%; box-shadow: inset 0 0 0 2px transparent; transition: box-shadow .15s; }
.e49-c.on i { box-shadow: inset 0 0 0 2.5px var(--cell, var(--surface)), 0 0 0 2px var(--cc, var(--ink)); }
.e49-chips { display: flex; gap: .4rem; overflow-x: auto; scrollbar-width: none; padding-bottom: .1rem; }
.e49-chips::-webkit-scrollbar { display: none; }
.e49-chips .emj-tab { flex: none; opacity: 1; font: inherit; font-size: .88rem; font-weight: 500; background: var(--fill); color: var(--ink); border-radius: 999px; padding: .38rem .85rem; }
.e49-chips .emj-tab.on { background: var(--ink); color: var(--surface); }
.e49-grid { max-height: min(46vh, 380px); }
.e49-sec { display: block !important; }
.e49-sec[hidden] { display: none !important; }
.e49-sec .emj-h { position: static; letter-spacing: .02em; font-size: .74rem; font-weight: 600; padding: .7rem .5rem .35rem; background: none; }
.e49-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(50px, 1fr)); gap: 6px; background: var(--cell, var(--surface)); border-radius: 12px; padding: 8px; }
.e49-tiles button { padding: 0 !important; aspect-ratio: 1; display: grid; place-items: center; }
.e49-tiles button .ti-tile { width: 100%; height: 100%; max-width: 50px; max-height: 50px; border-radius: 12px; }
.e49-tiles button .ti-tile .ti { width: 26px; height: 26px; }
.emj49 .emj-none { margin: .2rem 0 0 !important; border: 0 !important; background: var(--fill) !important; color: var(--ink) !important; }
/* fuori da un foglio (pannello dentro Abitudini) la cella resta bianca */
.h-emoji-grid .e49-tiles { background: var(--surface-2); }

/* l'ambito: anteprima grande + nome, colori, icone rapide */
.b49-head { display: flex; flex-direction: column; align-items: center; gap: .8rem; padding: 1.1rem 1rem 1rem; }
.b49-ic { width: 88px; height: 88px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--bc) 16%, var(--cell, var(--surface))); color: var(--bc); font-size: 2.2rem; font-weight: 700; transition: background .2s; }
.b49-ic .ti { width: 48px; height: 48px; }
.b49-name { width: 100%; border: 0; background: var(--fill); border-radius: 12px; padding: .7rem 1rem; text-align: center; font: inherit; font-size: 1.3rem; font-weight: 700; letter-spacing: -.02em; color: var(--ink); outline: 0; }
.b49-name:focus { box-shadow: 0 0 0 2px var(--dawn); }
.b49-cols .bk-pick.colors { display: grid; grid-template-columns: repeat(6, 1fr); justify-items: center; gap: .7rem .4rem; padding: 1rem .8rem; }
.b49-cols .csw { width: 40px; height: 40px; border: 0; }
.b49-cols .csw.on { box-shadow: 0 0 0 3px var(--cell, var(--surface)), 0 0 0 5.5px var(--bc); }
.b49-cols .csw-free { width: 40px; height: 40px; }
.b49-quick { display: grid; grid-template-columns: repeat(auto-fill, minmax(46px, 1fr)); gap: .6rem .4rem; padding: 1rem .8rem; justify-items: center; }
.b49-quick button { width: 46px; height: 46px; border-radius: 50%; border: 0; background: var(--fill-2); display: grid; place-items: center; cursor: pointer; color: var(--ink-3); font-size: 1.2rem; }
.b49-quick button:not(.on) .ti { filter: grayscale(1); opacity: .55; }
.b49-quick button.on { background: color-mix(in srgb, var(--bc, var(--dawn)) 16%, transparent); box-shadow: 0 0 0 2px currentColor; }
.b49-quick button .ti { width: 26px; height: 26px; }
.b49-all { width: 100%; border: 0; background: transparent; font: inherit; font-size: 17px; color: var(--dawn); text-align: left; }
.b49-all small { color: var(--ink-3); font-size: 1rem; }
.b49-all::after { content: '›'; color: var(--ink-3); font-size: 1.3rem; margin-left: .3rem; }
#b49-panel { padding: .2rem .8rem .9rem; }
.v49-note { font-size: .82rem; color: var(--ink-3); margin: -.2rem .3rem .8rem; line-height: 1.4; }
/* l'icona dell'ambito dove compare il suo nome */
.bk-ti { width: 1.05em; height: 1.05em; vertical-align: -.16em; }
.bk-pick span.has-ic::before, .s-bk.has-ic::before { display: none; }
.bk-pick span.has-ic .bk-ti { width: 15px; height: 15px; margin-left: -.1rem; }
.s-bk.has-ic .bk-ti { width: 13px; height: 13px; }
.bdot.ic { width: 28px; height: 28px; margin-top: 0; display: grid; place-items: center; border-radius: 8px; background: color-mix(in srgb, var(--bc) 15%, transparent); }
.bdot.ic .bk-ti { width: 18px; height: 18px; }
:where(html.v49) .bk-pick span { border: 0; background: var(--fill); color: var(--ink); }
:where(html.v49) .bk-pick input:checked + span { background: color-mix(in srgb, var(--bc) 18%, var(--cell, var(--surface))); box-shadow: inset 0 0 0 1.5px var(--bc); }
:where(html.v49) .bk-pick .bk-add { border: 0; background: transparent; color: var(--dawn); }

/* =====================================================================================================
   4.9 — SCHEDE: barra in alto sul computer, panoramica sul telefono
   ===================================================================================================== */
.tb-strip { display: none; }
@media (min-width: 700px) {
  html.v49.has-tabs .tb-strip { display: flex; align-items: flex-end; gap: 4px; position: fixed; top: 0; left: var(--nav-w); right: 0; height: 42px; z-index: 32; padding: 0 .6rem 0 .5rem; background: color-mix(in srgb, var(--bg) 70%, var(--surface-2)); border-bottom: 1px solid var(--sep); }
  html.v49.has-tabs .capture { top: 42px; }
  html.v49.has-tabs .main { padding-top: calc(5.25rem + 42px); }
  html.v49.has-tabs body.chat-open .main { padding-top: calc(1.5rem + 42px); }
}
.tb-list { display: flex; align-items: flex-end; gap: 2px; flex: 1; min-width: 0; height: 100%; overflow: hidden; }
.vtab { position: relative; flex: 1 1 210px; max-width: 230px; min-width: 44px; height: 34px; display: flex; align-items: center; gap: .45rem; padding: 0 .4rem 0 .7rem; border-radius: 10px 10px 0 0; cursor: pointer; color: var(--ink-2); font-size: .84rem; user-select: none; -webkit-user-select: none; }
.vtab:hover { background: var(--fill-2); }
.vtab + .vtab:not(.on)::before { content: ''; position: absolute; left: -2px; top: 9px; bottom: 9px; width: 1px; background: var(--sep); }
.vtab.on + .vtab::before, .vtab:hover + .vtab::before, .vtab:hover::before { display: none; }
.vtab.on { background: var(--bg); color: var(--ink); font-weight: 600; box-shadow: 0 -1px 0 var(--sep), 1px 0 0 var(--sep), -1px 0 0 var(--sep); height: 35px; margin-bottom: -1px; }
.vtab.on::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--bg); }
.tb-ic { flex: none; display: grid; place-items: center; width: 18px; height: 18px; }
.tb-ic .ti { width: 17px; height: 17px; }
.tb-t { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tb-x { flex: none; width: 22px; height: 22px; border: 0; border-radius: 6px; background: transparent; color: var(--ink-3); font-size: 1.05rem; line-height: 1; cursor: pointer; display: grid; place-items: center; opacity: 0; }
.vtab.on .tb-x, .vtab:hover .tb-x { opacity: 1; }
.tb-x:hover { background: var(--fill); color: var(--ink); }
.tb-new { flex: none; width: 32px; height: 32px; margin-bottom: 2px; border: 0; border-radius: 8px; background: transparent; color: var(--ink-2); font-size: 1.35rem; font-weight: 300; cursor: pointer; }
.tb-new:hover { background: var(--fill); color: var(--ink); }
@keyframes tbflash { 30% { background: color-mix(in srgb, var(--dawn) 26%, transparent); } }
.vtab.tb-flash, .tb-count.tb-flash { animation: tbflash .9s ease; }
/* telefono: il quadratino col numero delle schede */
.tb-count { display: none; }
@media (max-width: 699px) {
  html.v49.has-tabs .tb-count { display: grid; place-items: center; margin-left: auto; margin-right: .55rem; width: 34px; height: 34px; border: 0; background: transparent; cursor: pointer; padding: 0; border-radius: 8px; }
  html.v49.has-tabs .tb-count span { min-width: 22px; height: 22px; padding: 0 4px; border: 2px solid var(--ink); border-radius: 6px; display: grid; place-items: center; font-size: .72rem; font-weight: 700; color: var(--ink); line-height: 1; }
}
.tb-ov { position: fixed; inset: 0; z-index: 70; background: var(--bg); display: flex; flex-direction: column; animation: tbov .22s cubic-bezier(.2,.85,.25,1); }
.tb-ov.out { opacity: 0; transform: scale(1.03); transition: opacity .18s, transform .18s; }
@keyframes tbov { from { opacity: 0; transform: scale(.97); } }
.tb-grid { flex: 1; overflow-y: auto; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 1.1rem .9rem; padding: calc(1.2rem + env(safe-area-inset-top)) 1rem 1rem; align-content: start; }
.tb-card { cursor: pointer; display: flex; flex-direction: column; gap: .45rem; animation: tbcard .3s cubic-bezier(.2,.85,.25,1) both; }
.tb-card:nth-child(2) { animation-delay: .03s; } .tb-card:nth-child(3) { animation-delay: .06s; } .tb-card:nth-child(4) { animation-delay: .09s; }
@keyframes tbcard { from { opacity: 0; transform: translateY(10px) scale(.97); } }
.tb-shot { position: relative; aspect-ratio: 3 / 4; background: var(--surface); border-radius: 16px; padding: .8rem .8rem 0; overflow: hidden; box-shadow: 0 1px 3px rgba(0,0,0,.06), 0 6px 20px rgba(0,0,0,.06); }
.tb-shot b { display: block; font-size: 1.05rem; font-weight: 700; letter-spacing: -.02em; margin: .2rem 1.6rem .4rem 0; line-height: 1.2; }
.tb-shot p { margin: 0; font-size: .68rem; line-height: 1.45; color: var(--ink-2); display: -webkit-box; -webkit-line-clamp: 12; -webkit-box-orient: vertical; overflow: hidden; }
.tb-shot::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 40%; background: linear-gradient(transparent, var(--surface)); pointer-events: none; }
.tb-card.on .tb-shot { box-shadow: 0 0 0 3px var(--dawn), 0 6px 20px rgba(0,0,0,.08); }
.tb-cx { position: absolute; top: 7px; right: 7px; width: 26px; height: 26px; border-radius: 50%; border: 0; background: rgba(60,60,67,.55); color: #fff; font-size: 1rem; line-height: 1; cursor: pointer; z-index: 1; display: grid; place-items: center; }
.tb-cap { display: flex; align-items: center; justify-content: center; gap: .4rem; font-size: .9rem; color: var(--ink); min-width: 0; }
.tb-cap .ti { width: 17px; height: 17px; flex: none; }
.tb-cap span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tb-foot { flex: none; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding: .6rem 1rem max(.8rem, env(safe-area-inset-bottom)); border-top: 1px solid var(--sep); background: color-mix(in srgb, var(--surface) 85%, transparent); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); }
.tb-foot button { border: 0; background: none; color: var(--dawn); font: inherit; font-size: 1.05rem; cursor: pointer; justify-self: start; padding: .4rem .3rem; }
.tb-foot button[data-tbnew] { font-size: 1.8rem; font-weight: 300; line-height: 1; }
.tb-foot button.b { font-weight: 600; justify-self: end; }
.tb-foot b { font-weight: 600; }
/* il menu «Apri in una nuova scheda» */
.tb-menu { position: fixed; z-index: 90; min-width: 250px; background: color-mix(in srgb, var(--surface) 92%, transparent); -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%); border-radius: 12px; padding: 5px; box-shadow: 0 0 0 1px var(--sep), 0 14px 40px rgba(0,0,0,.18); display: flex; flex-direction: column; animation: tbm .14s ease; }
@keyframes tbm { from { opacity: 0; transform: scale(.97); } }
.tb-menu button { border: 0; background: none; font: inherit; font-size: .92rem; color: var(--ink); text-align: left; padding: .45rem .7rem; border-radius: 7px; cursor: pointer; display: flex; justify-content: space-between; gap: 1rem; }
.tb-menu button small { color: var(--ink-3); font-size: .8rem; }
.tb-menu button:hover, .tb-menu button.hi:hover { background: var(--dawn); color: #fff; }
.tb-menu button:hover small { color: rgba(255,255,255,.8); }
.tb-menu.sheet { left: .6rem; right: .6rem; bottom: max(.6rem, env(safe-area-inset-bottom)); top: auto; min-width: 0; padding: 6px; border-radius: 16px; animation: v49up .26s cubic-bezier(.2,.85,.25,1); }
.tb-menu.sheet button { font-size: 1.05rem; padding: .85rem 1rem; justify-content: center; color: var(--dawn); }
.tb-menu.sheet button + button { border-top: 1px solid var(--sep); border-radius: 0; }
html.v49 a[href^="#"] { -webkit-touch-callout: none; }
/* la pagina «Nuova scheda» */
.tb-page { max-width: 680px; }
.tb-go { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .9rem .5rem; }
.tb-go a { display: flex; flex-direction: column; align-items: center; gap: .4rem; text-decoration: none; color: var(--ink); font-size: .82rem; text-align: center; }
.tb-go a span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.tb-go .ti-tile.lg { width: 56px; height: 56px; border-radius: 16px; }
.tb-go .ti-tile.lg .ti { width: 30px; height: 30px; }
.tb-q { margin: .4rem 0 .8rem; }
.tb-keys { margin: 1.4rem .2rem; }

/* =====================================================================================================
   4.9 — CONDIVISIONE
   ===================================================================================================== */
.sh-page { max-width: 640px; }
.sh-code { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 1.3rem 1rem 1.1rem; gap: .25rem; }
.sh-qr { background: #fff; border-radius: 16px; padding: 6px; box-shadow: 0 0 0 1px var(--sep); margin-bottom: .6rem; line-height: 0; }
.sh-qr svg { width: 168px; height: 168px; }
.sh-code small { color: var(--ink-3); font-size: .85rem; }
.sh-big { font-size: 2rem; font-weight: 700; letter-spacing: .08em; font-variant-numeric: tabular-nums; }
.sh-btns { display: flex; gap: .6rem; margin-top: .6rem; }
.sh-btns .btn { color: var(--dawn-ink); background: var(--dawn-soft); border-radius: 999px; padding: .45rem 1.1rem; }
.sh-note { margin: .6rem .4rem 0; }
.sh-list { padding: 0; }
.sh-row { display: flex; align-items: center; gap: .8rem; width: 100%; border: 0; background: none; font: inherit; color: var(--ink); text-align: left; padding: .7rem 1rem; cursor: pointer; position: relative; }
.sh-row + .sh-row::before, .sh-list > .sh-act::before { content: ''; position: absolute; top: 0; right: 0; left: 3.9rem; height: 1px; background: var(--sep); transform: scaleY(.6); }
.sh-list > .sh-act::before { left: 1rem; }
.sh-row .t { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.sh-row .t b { font-weight: 500; }
.sh-row .t small { color: var(--ink-3); font-size: .85rem; }
.sh-row .t em { font-style: normal; color: var(--dawn-ink); }
.sh-row .chev { color: var(--ink-3); }
.sh-badge { background: var(--dawn); color: #fff; border-radius: 999px; padding: .2rem .6rem; font-size: .78rem; font-weight: 600; }
.sh-act { display: block; width: 100%; border: 0; background: none; text-align: left; font: inherit; color: var(--dawn); padding: .85rem 1rem; cursor: pointer; position: relative; }
.sh-av { flex: none; width: 38px; height: 38px; border-radius: 50%; display: inline-grid; place-items: center; font-weight: 600; font-size: 1rem; color: #fff; background: linear-gradient(160deg, color-mix(in srgb, var(--bc) 82%, #fff), var(--bc)); }
.sh-av.sm { width: 22px; height: 22px; font-size: .7rem; margin-right: .45rem; vertical-align: middle; }
.sh-av.xl { width: 72px; height: 72px; font-size: 2rem; }
.sh-inv { display: flex; flex-direction: column; align-items: center; text-align: center; gap: .35rem; padding: .6rem .4rem 1rem; }
.sh-inv h3 { font-size: 1.35rem; font-weight: 700; letter-spacing: -.02em; margin: .4rem 0 0; line-height: 1.2; }
.sh-inv p { color: var(--ink-3); margin: 0; }
.sh-yes, .sh-no, .sh-alt { display: flex; width: 100%; min-height: 50px; border-radius: 12px; margin-top: .5rem; font-size: 1.02rem; }
.sh-yes { background: var(--ink) !important; color: var(--surface) !important; }
.sh-no { background: var(--cell, var(--surface)); color: var(--warn); font-weight: 500; }
.sh-alt { background: var(--cell, var(--surface)); color: var(--dawn); }
.sh-who { gap: .8rem; justify-content: flex-start; }
.sh-who > span:not(.sh-av), .sh-found > span:not(.sh-av) { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.sh-who small, .sh-found small, .sh-pick small { display: block; color: var(--ink-3); font-size: .82rem; }
.sh-found { gap: .8rem; justify-content: flex-start; }
.sh-ok { font-style: normal; color: #fff; background: var(--sw-on); width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: .85rem; }
.sh-err { color: var(--warn); font-size: .92rem; }
.sh-codein { border: 0; background: transparent; text-align: right; font: inherit; font-size: 1.15rem; font-weight: 600; letter-spacing: .08em; color: var(--ink); width: 10.5rem; outline: 0; text-transform: uppercase; }
.sh-codein::placeholder { color: var(--ink-3); font-weight: 400; }
.v49-gh { font-size: .8rem; color: var(--ink-3); text-transform: uppercase; letter-spacing: .02em; margin: 1rem 1rem .4rem; }
.sh-pick input[type=radio] { position: absolute; opacity: 0; pointer-events: none; }
.sh-pick .sh-tick { width: 18px; flex: none; }
.sh-pick input[type=radio]:checked + .sh-tick::before { content: '✓'; color: var(--dawn); font-weight: 700; font-style: normal; font-size: 1.1rem; }
.sh-pick input[type=radio]:disabled ~ * , .sh-pick label:has(input:disabled) { opacity: .45; }
.sh-bks { }
.sh-bk { padding-left: 2rem; }
.sh-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: .6rem; }
.sh-ck { -webkit-appearance: none; appearance: none; width: 24px; height: 24px; border-radius: 7px; border: 1.6px solid color-mix(in srgb, var(--ink-3) 60%, transparent); margin: 0; flex: none; display: grid; place-items: center; cursor: pointer; }
.sh-ck:checked { background: var(--dawn); border-color: var(--dawn); }
.sh-ck:checked::after { content: ''; width: 10px; height: 5px; border: 2.2px solid #fff; border-top: 0; border-right: 0; transform: rotate(-45deg) translate(1px, -1px); }
.sh-cols { display: grid; grid-template-columns: repeat(8, 1fr); gap: .4rem; padding: .9rem; justify-items: center; }
.sh-cols .csw { width: 32px; height: 32px; border: 0; }
.sh-cols .csw.on { box-shadow: 0 0 0 3px var(--cell, var(--surface)), 0 0 0 5px var(--bc); }
.sh-manage { display: inline-block; margin-top: .8rem; color: var(--dawn); text-decoration: none; }
/* in Agenda: gli impegni di altri, a righe, con l'iniziale */
.chip.shared { background: repeating-linear-gradient(135deg, color-mix(in srgb, var(--bc) 20%, var(--surface)) 0 6px, color-mix(in srgb, var(--bc) 11%, var(--surface)) 6px 12px) !important; color: var(--ink) !important; border-left: 3px solid var(--bc) !important; }
.s-ev.shared { background: repeating-linear-gradient(135deg, color-mix(in srgb, var(--ec) 16%, var(--surface)) 0 6px, color-mix(in srgb, var(--ec) 8%, var(--surface)) 6px 12px); }
.sh-ini { font-style: normal; display: inline-grid; place-items: center; width: 15px; height: 15px; border-radius: 50%; background: var(--bc, var(--ec)); color: #fff; font-size: .6rem; font-weight: 700; margin-right: .3rem; vertical-align: 1px; }
.s-ev .sh-ini { background: var(--ec); width: 18px; height: 18px; font-size: .68rem; }

/* =====================================================================================================
   4.9 — IL TUO PIANO: scelta pulita e metodo di pagamento visibile
   ===================================================================================================== */
:where(html.v49) .p-card { border: 0; border-radius: 16px; }
:where(html.v49) .p-card.mine { box-shadow: 0 0 0 2px var(--dawn), var(--shadow); }
:where(html.v49) .p-card h2 { font-weight: 700; letter-spacing: -.02em; }
:where(html.v49) .p-price b { font-weight: 700; letter-spacing: -.03em; }
:where(html.v49) .p-card li::before { border-color: var(--dawn); }
:where(html.v49) .p-now { border-radius: 16px; }
:where(html.v49) .p-now b { font-weight: 700; }
:where(html.v49) .p-cta { border-radius: 12px; min-height: 48px; }
@media (min-width: 700px) { :where(html.v49) .p-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } :where(html.v49) .p-page { max-width: 980px; } }
.p49-card { padding: 0; }
.p49-row { display: flex; align-items: center; gap: 1rem; padding: 1rem; }
.p49-cc { position: relative; flex: none; width: 92px; height: 58px; border-radius: 9px; padding: 7px 9px; color: #fff; display: flex; flex-direction: column; justify-content: space-between; background: linear-gradient(135deg, #3A3A3C, #1C1C1E); box-shadow: 0 4px 12px rgba(0,0,0,.18); font-size: .55rem; }
.p49-cc.visa { background: linear-gradient(135deg, #1A3FA6, #0B1F5C); }
.p49-cc.mastercard { background: linear-gradient(135deg, #3C3C3E, #121214); }
.p49-cc.amex { background: linear-gradient(135deg, #2E7DD1, #1A4F8F); }
.p49-cc b { font-size: .62rem; letter-spacing: .06em; font-style: italic; }
.p49-cc i { position: absolute; left: 9px; top: 22px; width: 15px; height: 11px; border-radius: 2px; background: linear-gradient(135deg, #E9C46A, #B98A2A); }
.p49-cc span { font-variant-numeric: tabular-nums; letter-spacing: .06em; text-align: right; }
.p49-ci { display: flex; flex-direction: column; min-width: 0; }
.p49-ci b { font-weight: 600; }
.p49-ci small { color: var(--ink-3); font-size: .85rem; }
.p49-act { display: flex; align-items: center; gap: .5rem; padding: .85rem 1rem; border-top: 1px solid var(--sep); color: var(--dawn); text-decoration: none; }
.p49-act small { color: var(--ink-3); font-size: .82rem; margin-left: .3rem; flex: 1; }
.p49-act .chev { color: var(--ink-3); margin-left: auto; }
.p49-amt { font-weight: 600; font-variant-numeric: tabular-nums; margin-left: auto; padding-left: .5rem; }
:where(html.v49) .p-page .card { width: 100%; max-width: none; box-sizing: border-box; }
:where(html.v49) .s-tt small .s-bk { display: inline-flex; font-size: inherit; line-height: inherit; }
