/* Recanati per Due — tema tramonto sul Conero, mobile-first */
:root {
  --sunset1: #f48b5e;
  --sunset2: #ffc19e;
  --sea1: #0c3a4f;
  --sea2: #1e6f8a;
  --sand: #fff6ec;
  --ink: #23303a;
  --ok: #2e9e6b;
  --card: #ffffff;
  --muted: #7b8a94;
  --radius: 18px;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", sans-serif;
  background: linear-gradient(180deg, var(--sunset2) 0%, var(--sand) 30%);
  color: var(--ink);
  min-height: 100vh;
  padding-bottom: calc(84px + env(safe-area-inset-bottom));
}
#app { max-width: 560px; margin: 0 auto; padding: 14px 16px 8px; }

.hero {
  text-align: center;
  padding: 26px 10px 14px;
}
.hero h1 { margin: 0; font-size: 30px; letter-spacing: -0.5px; }
.hero .sub { color: var(--muted); margin-top: 6px; font-size: 15px; }
.hero .big-emoji { font-size: 56px; display: block; margin-bottom: 6px; }

.card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 16px;
  margin: 12px 0;
  box-shadow: 0 4px 18px rgba(12, 58, 79, 0.10);
}
.card h2 { margin: 0 0 8px; font-size: 19px; }
.card h3 { margin: 14px 0 6px; font-size: 16px; }
.card .muted { color: var(--muted); font-size: 14px; }
.card img.photo {
  width: 100%; border-radius: 12px; display: block; margin: 8px 0;
  aspect-ratio: 16/10; object-fit: cover; background: #e8eef1;
}
.credit { font-size: 10px; color: var(--muted); text-align: right; margin-top: -4px; }

.btn {
  display: block; width: 100%;
  border: none; border-radius: 14px;
  background: linear-gradient(135deg, var(--sunset1), #e56a4b);
  color: #fff; font-size: 17px; font-weight: 600;
  padding: 15px; margin: 10px 0; cursor: pointer;
  transition: transform .08s;
}
.btn:active { transform: scale(0.97); }
.btn.secondary { background: var(--sea2); }
.btn.ghost { background: #eef3f6; color: var(--ink); }

/* Chi sei */
.who { display: flex; gap: 12px; margin-top: 18px; }
.who button {
  flex: 1; border: none; border-radius: var(--radius);
  background: var(--card); padding: 24px 10px;
  font-size: 17px; font-weight: 700; color: var(--ink);
  box-shadow: 0 4px 18px rgba(12,58,79,.10); cursor: pointer;
}
.who button .we { font-size: 44px; display: block; margin-bottom: 8px; }
.who button:active { transform: scale(.96); }

/* Quiz */
.progress {
  height: 10px; background: #eadfd4; border-radius: 99px; overflow: hidden; margin: 10px 0 4px;
}
.progress > div {
  height: 100%; background: linear-gradient(90deg, var(--sunset1), var(--sea2));
  border-radius: 99px; transition: width .35s ease;
}
.progress-label { text-align: center; font-size: 12px; color: var(--muted); margin-bottom: 8px; }
.section-chip {
  display: inline-block; background: var(--sea1); color: #fff;
  font-size: 12px; font-weight: 700; padding: 4px 12px; border-radius: 99px;
  margin-bottom: 6px;
}
.qtext { font-size: 21px; font-weight: 700; line-height: 1.3; margin: 6px 0 14px; }
.sec-intro { font-size: 13px; color: var(--muted); font-style: italic; margin: 0 0 10px; }
.opt {
  display: block; width: 100%; text-align: left;
  background: #f5f8fa; border: 2px solid transparent; border-radius: 14px;
  padding: 13px 14px; margin: 8px 0; font-size: 16px; color: var(--ink);
  cursor: pointer; transition: transform .08s, border-color .15s, background .15s;
}
.opt:active { transform: scale(.98); }
.opt.selected { border-color: var(--sunset1); background: #fff1e8; }
.opt .k { font-weight: 800; color: var(--sunset1); margin-right: 6px; }
.quiz-anim-out { animation: slideout .22s ease forwards; }
.quiz-anim-in { animation: slidein .25s ease; }
@keyframes slideout { to { opacity: 0; transform: translateX(-30px); } }
@keyframes slidein { from { opacity: 0; transform: translateX(30px); } }

/* Attesa */
.waiting { text-align: center; padding: 30px 10px; }
.waiting .pulse { font-size: 64px; animation: pulse 1.6s infinite; display: block; }
@keyframes pulse { 0%,100% { transform: scale(1);} 50% { transform: scale(1.15);} }

/* Confronto */
.compat-ring {
  width: 150px; height: 150px; margin: 8px auto; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 34px; font-weight: 800; color: var(--sea1);
  background: conic-gradient(var(--sunset1) calc(var(--p) * 1%), #eadfd4 0);
}
.compat-ring > div {
  width: 118px; height: 118px; border-radius: 50%; background: var(--card);
  display: flex; align-items: center; justify-content: center; flex-direction: column;
}
.compat-ring small { font-size: 11px; color: var(--muted); font-weight: 600; }
.match-row { padding: 10px 0; border-bottom: 1px solid #f0e9e1; font-size: 14px; }
.match-row .q { font-weight: 700; margin-bottom: 4px; }
.match-row .ans { display: flex; gap: 8px; }
.match-row .ans span { flex: 1; background: #f5f8fa; padding: 6px 8px; border-radius: 8px; font-size: 13px; }
.match-row.same .ans span { background: #e7f6ee; }
.badge-match { color: var(--ok); font-weight: 700; font-size: 12px; }
.badge-diff { color: var(--sunset1); font-weight: 700; font-size: 12px; }
.bar-row { margin: 8px 0; font-size: 13px; }
.bar-row .lbl { display: flex; justify-content: space-between; margin-bottom: 3px; }
.bar { height: 8px; background: #eadfd4; border-radius: 99px; overflow: hidden; }
.bar > div { height: 100%; background: linear-gradient(90deg, var(--sea2), var(--sunset1)); border-radius: 99px; }

/* Guida */
.pill { display: inline-block; background: #fff1e8; color: #b34f2e; font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 99px; margin: 2px 4px 2px 0; }
.pill.blue { background: #e8f2f6; color: var(--sea2); }
.stars { color: var(--sunset1); letter-spacing: 2px; }
.guide-item { padding: 10px 0; border-bottom: 1px solid #f0e9e1; }
.guide-item:last-child { border-bottom: none; }
.guide-item .t { font-weight: 700; font-size: 15px; }
.guide-item .d { font-size: 14px; color: #4a5a64; margin-top: 2px; }
.guide-item a { color: var(--sea2); font-size: 13px; }
.tag-consiglio { background: var(--ok); color: #fff; font-size: 11px; font-weight: 800; padding: 2px 8px; border-radius: 99px; margin-left: 6px; }
.locked { text-align: center; padding: 34px 16px; }
.locked .lock { font-size: 58px; display: block; margin-bottom: 8px; }
details { margin: 8px 0; }
details summary { font-weight: 700; font-size: 15px; cursor: pointer; padding: 8px 0; }

/* Meteo + countdown */
.tiles { display: flex; gap: 10px; }
.tile { flex: 1; background: var(--card); border-radius: 14px; padding: 12px; text-align: center; box-shadow: 0 4px 18px rgba(12,58,79,.08); }
.tile .big { font-size: 26px; font-weight: 800; }
.tile .sm { font-size: 12px; color: var(--muted); }

/* Tab bar */
nav.tabs {
  position: fixed; bottom: 0; left: 0; right: 0;
  background: rgba(255,255,255,.94); backdrop-filter: blur(12px);
  display: flex; border-top: 1px solid #eee;
  padding-bottom: env(safe-area-inset-bottom);
  max-width: 100%; z-index: 10;
}
nav.tabs button {
  flex: 1; background: none; border: none; padding: 10px 4px 8px;
  font-size: 11px; font-weight: 600; color: var(--muted); cursor: pointer;
}
nav.tabs button .ico { display: block; font-size: 22px; margin-bottom: 2px; }
nav.tabs button.active { color: var(--sunset1); }

/* Cuoricini flottanti (confronto) */
.float-heart {
  position: fixed; font-size: 26px; pointer-events: none; z-index: 99;
  animation: floatup 3s ease-in forwards;
}
@keyframes floatup {
  from { opacity: 1; transform: translateY(0) rotate(0); }
  to { opacity: 0; transform: translateY(-60vh) rotate(30deg); }
}

/* --- v2: Oggi + Mappa --- */
.day-hero { text-align: center; padding: 18px 8px 6px; }
.day-hero h1 { margin: 0; font-size: 24px; }
.day-hero .sub { color: var(--muted); font-size: 14px; margin-top: 4px; }
.block { border-left: 4px solid #eadfd4; padding: 4px 0 10px 12px; margin: 12px 0; }
.block.now { border-left-color: var(--sunset1); background: #fff8f2; border-radius: 0 12px 12px 0; padding-right: 8px; }
.fascia-chip { font-size: 11px; font-weight: 800; letter-spacing: 1px; text-transform: uppercase; color: var(--sea2); }
.now-badge { background: var(--sunset1); color: #fff; font-size: 10px; font-weight: 800; padding: 2px 8px; border-radius: 99px; margin-left: 6px; vertical-align: middle; }
.block .bt { font-weight: 800; font-size: 16px; margin: 3px 0; }
.block .bd { font-size: 14px; color: #4a5a64; }
.navbtns { display: flex; gap: 8px; margin-top: 8px; }
.navbtns a { flex: 1; text-align: center; background: #eef3f6; color: var(--ink); text-decoration: none; font-size: 13px; font-weight: 700; padding: 8px; border-radius: 10px; }
.navbtns a.apple { background: #e9f0f4; }
.dist { font-size: 12px; color: var(--sea2); font-weight: 700; margin-top: 4px; display: inline-block; }
.pianob { margin-top: 6px; }
.pianob summary { font-size: 13px; color: #b34f2e; font-weight: 700; }
.pianob p { font-size: 13px; color: #4a5a64; margin: 6px 0 0; }
.check-row { display: flex; align-items: flex-start; gap: 10px; padding: 10px 0; border-bottom: 1px solid #f0e9e1; }
.check-row:last-child { border-bottom: none; }
.check-row input { width: 22px; height: 22px; accent-color: var(--sunset1); margin-top: 2px; }
.check-row .cv { flex: 1; font-size: 14px; font-weight: 600; }
.check-row .cn { font-size: 12px; color: var(--muted); font-weight: 400; }
.check-row.done .cv { text-decoration: line-through; color: var(--muted); }
.deadline { font-size: 11px; font-weight: 800; padding: 2px 8px; border-radius: 99px; background: #e8f2f6; color: var(--sea2); white-space: nowrap; }
.deadline.hot { background: #ffe3e0; color: #c0392b; }
#map { height: 62vh; border-radius: var(--radius); box-shadow: 0 4px 18px rgba(12,58,79,.12); }
.emoji-pin { font-size: 26px; text-shadow: 0 1px 3px rgba(0,0,0,.35); }
.geo-btn { margin: 10px 0 0; }
