/* =====================================================================
   DoYouMad — sito pubblico (landing MAD + Interpelli + checkout + scheda)
   ===================================================================== */
:root {
  --navy: #062b4f; --navy-2: #0a3a69; --blue: #0047ab; --sky: #6fa8dc; --teal: #4aa3ad; --mint: #8fe3d0;
  --ink: #0f1f33; --muted: #5d6f86; --line: #e3e9f2; --bg: #f5f8fc;
  --bs-body-font-family: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --bs-primary: #0047ab; --bs-primary-rgb: 0, 71, 171;
}
body.dym-site { background: var(--bg); color: var(--ink); }
a { color: var(--blue); text-decoration: none; }
.font-display { font-family: "Fraunces", Georgia, serif; letter-spacing: -.02em; }
.text-teal { color: var(--teal) !important; }
.text-sky { color: var(--sky) !important; }

/* ---------- Nav ---------- */
.site-nav { position: sticky; top: 0; z-index: 1030; padding: .7rem 0; background: rgba(6,43,79,.82); backdrop-filter: blur(14px); border-bottom: 1px solid rgba(255,255,255,.08); }
.site-brand { display: inline-flex; align-items: center; gap: .6rem; color: #fff; font-weight: 800; font-size: 1.05rem; }
.site-brand img { width: 40px; height: 40px; border-radius: 12px; background: #fff; padding: 3px; object-fit: contain; }
.site-link { color: #cfe0f3; padding: .45rem .8rem; border-radius: 999px; font-weight: 600; font-size: .92rem; }
.site-link:hover, .site-link.active { color: #fff; background: rgba(255,255,255,.1); }
.btn-glow { background: linear-gradient(135deg, var(--teal), #2fd1b6); color: #062b4f; font-weight: 800; border: 0; border-radius: 999px; padding: .55rem 1.1rem; box-shadow: 0 10px 30px rgba(47,209,182,.35); }
.btn-glow:hover { color: #062b4f; transform: translateY(-1px); box-shadow: 0 14px 34px rgba(47,209,182,.45); }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; color: #fff; padding: 4.5rem 0 5.5rem;
  background: radial-gradient(900px 500px at 15% 10%, rgba(74,163,173,.45), transparent 60%),
              radial-gradient(800px 600px at 95% 30%, rgba(0,71,171,.65), transparent 60%),
              linear-gradient(160deg, #041d36 0%, var(--navy) 55%, #08345f 100%); }
.hero.alt { background: radial-gradient(900px 500px at 85% 10%, rgba(143,227,208,.35), transparent 60%),
              radial-gradient(800px 600px at 5% 40%, rgba(111,168,220,.45), transparent 60%),
              linear-gradient(160deg, #041d36 0%, #073b5a 55%, #0a4a5c 100%); }
.hero::after { content: ""; position: absolute; inset: auto 0 -1px 0; height: 90px; background: var(--bg); clip-path: ellipse(75% 100% at 50% 100%); }
.hero h1 { font-size: clamp(2.2rem, 5vw, 3.8rem); line-height: 1.04; font-weight: 800; }
.hero h1 .accent { background: linear-gradient(90deg, var(--mint), var(--sky)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .lead { color: #cfe0f3; font-size: 1.15rem; max-width: 560px; }
.hero-badges .b { display: inline-flex; align-items: center; gap: .45rem; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14); padding: .4rem .8rem; border-radius: 999px; font-size: .85rem; margin: 0 .35rem .5rem 0; }
.hero-stats { display: flex; gap: 2rem; flex-wrap: wrap; margin-top: 2rem; }
.hero-stats .n { font-size: 2rem; font-weight: 800; line-height: 1; }
.hero-stats .l { color: #9fb8d3; font-size: .82rem; }
.orb { position: absolute; border-radius: 50%; filter: blur(60px); opacity: .5; animation: float 14s ease-in-out infinite; pointer-events: none; }
.orb.o1 { width: 340px; height: 340px; background: #2fd1b6; top: -80px; left: 40%; }
.orb.o2 { width: 280px; height: 280px; background: #2b6fd6; bottom: -60px; left: -60px; animation-delay: -6s; }
@keyframes float { 0%, 100% { transform: translate(0, 0) scale(1); } 50% { transform: translate(30px, 20px) scale(1.08); } }
.plane { position: absolute; color: rgba(255,255,255,.35); font-size: 1.6rem; animation: fly 11s linear infinite; pointer-events: none; }
.plane.p2 { animation-duration: 15s; animation-delay: -5s; font-size: 1.1rem; top: 70% !important; }
.plane.p3 { animation-duration: 19s; animation-delay: -9s; font-size: 1.3rem; top: 30% !important; }
@keyframes fly { 0% { transform: translate(-10vw, 30px) rotate(10deg); opacity: 0; } 10% { opacity: 1; } 90% { opacity: 1; } 100% { transform: translate(110vw, -80px) rotate(-5deg); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .orb, .plane { animation: none; } }

/* ---------- Configuratore ---------- */
.configurator { position: relative; z-index: 2; background: rgba(255,255,255,.98); color: var(--ink); border-radius: 24px; box-shadow: 0 30px 80px rgba(2,20,40,.45); overflow: hidden; }
.cfg-head { padding: 1.1rem 1.4rem; background: linear-gradient(90deg, #f0f6ff, #effbf8); border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: .75rem; }
.cfg-head .dot { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--navy); color: #fff; }
.cfg-steps { display: flex; gap: .4rem; padding: .9rem 1.4rem 0; }
.cfg-steps .s { flex: 1; height: 5px; border-radius: 999px; background: #e3e9f2; transition: background .3s; }
.cfg-steps .s.on { background: linear-gradient(90deg, var(--blue), var(--teal)); }
.cfg-body { padding: 1.2rem 1.4rem 1.4rem; }
.cfg-label { font-weight: 800; color: var(--navy); font-size: .95rem; margin-bottom: .55rem; display: flex; align-items: center; gap: .5rem; }
.cfg-label .num { width: 24px; height: 24px; border-radius: 50%; background: var(--navy); color: #fff; font-size: .75rem; display: grid; place-items: center; }
.role-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; }
.role-pick label { border: 2px solid var(--line); border-radius: 14px; padding: .65rem .5rem; text-align: center; cursor: pointer; font-weight: 700; font-size: .85rem; transition: all .15s; }
.role-pick label i { display: block; font-size: 1.35rem; color: var(--blue); margin-bottom: .15rem; }
.role-pick input { display: none; }
.role-pick input:checked + label { border-color: var(--blue); background: #eef4ff; box-shadow: 0 0 0 3px rgba(0,71,171,.12); }
.area-search { position: relative; }
.area-results { position: absolute; left: 0; right: 0; top: 100%; z-index: 20; background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 18px 40px rgba(6,43,79,.15); max-height: 300px; overflow-y: auto; display: none; margin-top: .3rem; }
.area-results.show { display: block; }
.area-results button { display: flex; width: 100%; justify-content: space-between; align-items: center; border: 0; background: none; padding: .55rem .8rem; text-align: left; font-size: .9rem; }
.area-results button:hover, .area-results button.hl { background: #f0f6ff; }
.area-results .kind { font-size: .68rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 700; }
.chips { display: flex; flex-wrap: wrap; gap: .35rem; min-height: 1rem; }
.chip { display: inline-flex; align-items: center; gap: .35rem; background: #eef4ff; color: var(--navy); border-radius: 999px; padding: .3rem .4rem .3rem .75rem; font-weight: 600; font-size: .82rem; }
.chip.big { background: #fff4dc; color: #7a4d00; }
.chip button { border: 0; background: rgba(6,43,79,.08); width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-size: .7rem; color: var(--navy); }
.region-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: .4rem; }
.region-grid button { border: 1px solid var(--line); background: #fff; border-radius: 12px; padding: .45rem .6rem; text-align: left; font-size: .82rem; font-weight: 600; }
.region-grid button:hover { border-color: var(--sky); background: #f6faff; }
.region-grid button small { display: block; color: var(--muted); font-weight: 500; font-size: .72rem; }
.summary { background: linear-gradient(135deg, var(--navy), #0b3f73); color: #fff; border-radius: 18px; padding: 1.1rem 1.2rem; }
.summary .count { font-size: 2.2rem; font-weight: 800; line-height: 1; }
.summary .price { font-size: 2.1rem; font-weight: 800; line-height: 1; color: var(--mint); }
.summary .brk { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .6rem; }
.summary .brk span { background: rgba(255,255,255,.12); border-radius: 999px; padding: .2rem .6rem; font-size: .75rem; }
.summary .lines { font-size: .78rem; color: #cfe0f3; margin-top: .6rem; }
.summary .lines div { display: flex; justify-content: space-between; gap: 1rem; }
.pay-methods { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.pay-methods label { border: 2px solid var(--line); border-radius: 14px; padding: .8rem; text-align: center; cursor: pointer; font-weight: 700; }
.pay-methods input { display: none; }
.pay-methods input:checked + label { border-color: var(--blue); background: #eef4ff; }
.pay-methods i { font-size: 1.5rem; display: block; color: var(--blue); }
.btn-pay { background: linear-gradient(135deg, var(--blue), #0a63d8); color: #fff; border: 0; border-radius: 16px; padding: 1rem; font-weight: 800; font-size: 1.1rem; width: 100%; box-shadow: 0 12px 30px rgba(0,71,171,.35); }
.btn-pay:hover { color: #fff; filter: brightness(1.05); }
.btn-pay:disabled { opacity: .5; box-shadow: none; }
.trust { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; font-size: .78rem; color: var(--muted); margin-top: .8rem; }
.ts-wrapper.multi .ts-control > div { background: #eef4ff; color: var(--navy); border-radius: 999px; padding: .1rem .55rem; font-weight: 600; }
.ts-control { border-radius: 14px; padding: .55rem .7rem; border-color: #d6dfeb; }
.ts-dropdown { border-radius: 14px; }
.ts-dropdown .optgroup-header { font-weight: 800; color: var(--navy); background: #f5f8fc; }

/* ---------- Sezioni ---------- */
.section { padding: 5rem 0; }
.section-title { font-weight: 800; color: var(--navy); font-size: clamp(1.7rem, 3vw, 2.5rem); letter-spacing: -.02em; }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-weight: 800; font-size: .75rem; color: var(--teal); }
.step-card { background: #fff; border: 1px solid var(--line); border-radius: 22px; padding: 1.6rem; height: 100%; position: relative; transition: transform .2s, box-shadow .2s; }
.step-card:hover { transform: translateY(-4px); box-shadow: 0 20px 40px rgba(6,43,79,.08); }
.step-card .n { position: absolute; top: 1rem; right: 1.2rem; font-size: 3rem; font-weight: 800; color: #eef3fa; line-height: 1; }
.step-card .ic { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; font-size: 1.5rem; margin-bottom: 1rem; background: linear-gradient(135deg, #eaf2ff, #e6faf6); color: var(--blue); }
.order-tiles .tile { background: #fff; border: 1px solid var(--line); border-radius: 20px; padding: 1.3rem; text-align: center; }
.order-tiles .tile .n { font-size: 2rem; font-weight: 800; color: var(--navy); }
.split { background: linear-gradient(135deg, #062b4f, #0b3f73); color: #fff; border-radius: 28px; padding: 2.5rem; overflow: hidden; position: relative; }
.split .card-x { background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.12); border-radius: 20px; padding: 1.4rem; height: 100%; }
.faq .accordion-button { font-weight: 700; color: var(--navy); }
.faq .accordion-button:not(.collapsed) { background: #eef4ff; box-shadow: none; }
.faq .accordion-item { border-radius: 14px !important; overflow: hidden; border: 1px solid var(--line); margin-bottom: .6rem; }
.cta-band { background: radial-gradient(600px 300px at 20% 0%, rgba(143,227,208,.35), transparent 60%), linear-gradient(135deg, var(--blue), var(--navy)); color: #fff; border-radius: 28px; padding: 3rem 2rem; }
.site-footer { background: #041d36; color: #cfe0f3; padding: 3rem 0 2rem; margin-top: 4rem; }
.site-footer a { color: #cfe0f3; }
.site-footer a:hover { color: #fff; }
.sticky-cta { position: fixed; bottom: 0; left: 0; right: 0; z-index: 1040; background: rgba(6,43,79,.96); color: #fff; padding: .7rem 1rem; display: none; align-items: center; gap: .8rem; box-shadow: 0 -10px 30px rgba(0,0,0,.25); }
@media (max-width: 991.98px) { .sticky-cta.show { display: flex; } .hero { padding: 2.5rem 0 4rem; } .role-pick { grid-template-columns: repeat(3, 1fr); } }

/* ---------- Pagine ordine / scheda ---------- */
.page-card { background: #fff; border-radius: 24px; border: 1px solid var(--line); box-shadow: 0 20px 50px rgba(6,43,79,.08); padding: 2rem; }
.status-pill { display: inline-flex; align-items: center; gap: .4rem; padding: .35rem .9rem; border-radius: 999px; font-weight: 700; font-size: .85rem; }
.status-pill.ok { background: #e3f8f1; color: #116149; }
.status-pill.wait { background: #fff4dc; color: #7a4d00; }
.status-pill.no { background: #ffe8ec; color: #a62a43; }
.check-hero { width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; font-size: 2.6rem; background: linear-gradient(135deg, #2fd1b6, var(--teal)); color: #fff; margin: 0 auto 1rem; box-shadow: 0 16px 40px rgba(47,209,182,.4); }
.scheda-step { background: #fff; border: 1px solid var(--line); border-radius: 24px; padding: 1.6rem; margin-bottom: 1.5rem; position: relative; }
.scheda-step .tag { position: absolute; top: -14px; left: 1.4rem; background: var(--navy); color: #fff; font-weight: 800; border-radius: 999px; padding: .25rem .9rem; font-size: .8rem; }
.form-label { font-weight: 600; font-size: .85rem; }
.form-control, .form-select { border-radius: 12px; padding: .6rem .85rem; border-color: #d6dfeb; }
.form-control:focus, .form-select:focus { border-color: var(--sky); box-shadow: 0 0 0 .2rem rgba(111,168,220,.25); }
.dropzone { border: 2px dashed #c4d3e6; border-radius: 18px; padding: 1.6rem; text-align: center; background: #f8fbff; cursor: pointer; transition: all .15s; }
.dropzone.drag { border-color: var(--teal); background: #effbf8; }
.file-row { display: flex; align-items: center; gap: .75rem; padding: .6rem .8rem; border: 1px solid var(--line); border-radius: 14px; margin-bottom: .5rem; background: #fff; }
.file-row i.big { font-size: 1.5rem; color: var(--blue); }
