/* ==========================================================================
   Il Ricre a San Martino — parte pubblica
   Palette dalla locandina: blu #004FB7, arancione #FC5C24, cielo #63D0F4.
   ========================================================================== */
:root{
  --blue:#004FB7; --blue-deep:#003a86; --blue-soft:#2f6fd0;
  --orange:#FC5C24; --orange-deep:#e04a15;
  --sky:#63D0F4; --sky-2:#8fe0f8;
  --paper:#f4fbff; --ink:#12293f; --muted:#5b7186; --line:#d7e8f2;
  --radius:16px;
}
*{box-sizing:border-box;}
body.pub{
  background:var(--paper); color:var(--ink); margin:0;
  font-family:-apple-system,"Segoe UI",system-ui,Roboto,Helvetica,Arial,sans-serif;
}

/* ---------- HERO ---------- */
.pub-hero{
  background:linear-gradient(160deg,var(--sky) 0%, var(--sky-2) 55%, #eaf8ff 100%);
  border-bottom:5px solid var(--orange);
  padding:2.4rem 1rem 2rem;
}
.pub-hero-inner{max-width:820px; margin:0 auto; display:flex; align-items:center; gap:1.6rem; flex-wrap:wrap; justify-content:center;}
.pub-logo{width:172px; height:172px; border-radius:50%; box-shadow:0 6px 22px rgba(0,50,120,.18); background:#fff;}
.pub-dates{display:flex; align-items:center; gap:.5rem; flex-wrap:wrap;}
.pub-date-chip{
  background:var(--blue); color:#fff; font-weight:800; font-size:1.6rem;
  width:56px; height:56px; border-radius:12px; display:grid; place-items:center;
  box-shadow:0 3px 0 var(--blue-deep); font-variant-numeric:tabular-nums;
}
.pub-date-month{color:var(--blue); font-weight:800; letter-spacing:.06em; font-size:1.05rem; margin-left:.3rem;}

.pub-main{max-width:820px; padding:2.2rem 1rem 3rem;}
.pub-intro{text-align:center; margin-bottom:1.6rem;}
.pub-intro h1{color:var(--blue); font-weight:800; letter-spacing:-.02em; font-size:clamp(1.6rem,4vw,2.2rem);}
.pub-intro p{color:var(--muted); max-width:560px; margin:.4rem auto 0;}

/* ---------- Card ---------- */
.pub .card{
  border:1px solid var(--line); border-radius:var(--radius); background:#fff;
  box-shadow:0 2px 16px rgba(0,60,130,.06); padding:0; overflow:hidden;
}
.book-card{max-width:720px;}

/* ---------- Step ---------- */
.step{display:flex; gap:1rem; padding:1.5rem 1.5rem;}
.step + .step{border-top:1px solid var(--line);}
.step-badge{
  flex:0 0 34px; width:34px; height:34px; border-radius:50%;
  background:var(--blue); color:#fff; font-weight:800; display:grid; place-items:center;
  box-shadow:0 2px 0 var(--blue-deep);
}
.step-body{flex:1;}
.step-body h2{font-size:1.15rem; font-weight:800; color:var(--blue); margin-bottom:.9rem;}

.step-2.locked{opacity:.5;}
.step-2.locked .step-badge{background:#a9c4dd; box-shadow:0 2px 0 #90b0cd;}
.step-2.locked .step-body{filter:grayscale(.3);}

.pub .form-label{font-weight:600; font-size:.85rem; margin-bottom:.25rem; color:#33506b;}
.pub .form-control, .pub .form-select{border-radius:10px; border-color:var(--line); padding:.55rem .7rem;}
.pub .form-control:focus, .pub .form-select:focus{border-color:var(--blue); box-shadow:0 0 0 .2rem rgba(0,79,183,.15);}

/* ---------- Bottoni brand ---------- */
.btn-brand{background:var(--blue); border:0; color:#fff; font-weight:700; border-radius:10px; padding:.65rem 1rem; box-shadow:0 3px 0 var(--blue-deep);}
.btn-brand:hover{background:var(--blue-deep); color:#fff;}
.btn-brand:active{transform:translateY(2px); box-shadow:none;}
.btn-accent{background:var(--orange); border:0; color:#fff; font-weight:800; border-radius:10px; box-shadow:0 3px 0 var(--orange-deep);}
.btn-accent:hover{background:var(--orange-deep); color:#fff;}
.btn-accent:active{transform:translateY(2px); box-shadow:none;}
.btn-outline-brand{border:1.5px solid var(--line); color:#33506b; background:#fff; font-weight:600;}
.btn-check:checked + .btn-outline-brand{background:var(--blue); border-color:var(--blue); color:#fff;}

/* ---------- Riquadro esito ---------- */
.av-result{border-radius:12px; padding:.85rem .95rem; font-size:.95rem; line-height:1.35;}
.av-result.loading{background:#eaf4fb; color:var(--muted);}
.av-result.ok{background:#e6f7ec; color:#12643a; border:1px solid #b4e2c6;}
.av-result.no{background:#fdece7; color:#9a3417; border:1px solid #f6c9ba;}
.av-detail{display:block; margin-top:.25rem; font-size:.82rem; opacity:.85;}

.pub-privacy{font-size:.78rem; color:var(--muted); line-height:1.4;}

/* ---------- Conferma ---------- */
.pub .confirm-card{max-width:560px; text-align:center; padding:3rem 2.6rem;}
@media (max-width:575.98px){ .pub .confirm-card{padding:2.2rem 1.4rem;} }
.confirm-check{width:66px; height:66px; margin:0 auto 1rem; background:#12a05a; color:#fff; border-radius:50%; font-size:2rem; line-height:66px; font-weight:700;}
.confirm-card h2{color:var(--blue); font-weight:800;}
.confirm-dl{text-align:left; margin:1.2rem 0; border-top:1px solid var(--line);}
.confirm-dl>div{display:flex; justify-content:space-between; gap:1rem; padding:.6rem .2rem; border-bottom:1px solid var(--line);}
.confirm-dl dt{color:var(--muted); font-weight:500; margin:0;}
.confirm-dl dd{font-weight:700; margin:0; text-align:right;}
.confirm-note{background:#eaf4fb; border:1px solid #c3ddf0; color:#254a68; border-radius:12px; padding:.85rem .9rem; font-size:.85rem; margin-bottom:1.3rem; text-align:left;}

/* ---------- Footer ---------- */
.pub-footer{border-top:1px solid var(--line); padding:1.4rem 1rem; text-align:center; color:var(--muted); font-size:.82rem;}

/* ---------- Fix mobile: evita che le combo escano dal form ---------- */
.step-body{min-width:0;}                 /* permette al contenuto flex di restringersi */
.book-card .row{--bs-gutter-x:.75rem;}   /* niente margini negativi eccessivi */
.zone-pick{flex-wrap:wrap;}
@media (max-width:575.98px){
  .step{padding:1.15rem 1rem;}
  .book-card .col-md-6,.book-card .col-md-4,.book-card .col-md-8{flex:0 0 100%; max-width:100%;}
}

/* ---------- Card "prenotazioni chiuse" + WhatsApp ---------- */
.pub .closed-card{max-width:560px; text-align:center; padding:2.2rem 1.8rem;}
.closed-icon{font-size:2.4rem; margin-bottom:.4rem;}
.closed-card h2{color:var(--blue); font-weight:800;}
.closed-actions{display:flex; flex-direction:column; gap:.6rem; margin-top:1.2rem;}
.btn-wa{background:#25D366; color:#fff; font-weight:700; border-radius:10px; padding:.65rem 1rem; box-shadow:0 3px 0 #1da851; text-decoration:none;}
.btn-wa:hover{background:#1da851; color:#fff;}
.btn-wa:active{transform:translateY(2px); box-shadow:none;}
.closed-actions .btn{display:inline-flex; align-items:center; justify-content:center; gap:.4rem;}
