/* Bancarella AI — stile mobile-first, testi e pulsanti GRANDI (si legge dal telefono). */

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 19px;
  line-height: 1.5;
  background: #f6f1e7;
  color: #1d1d1d;
}

header {
  background: #0b5cad;
  color: #fff;
  text-align: center;
  padding: 26px 16px 20px;
}

header h1 { margin: 0 0 4px; font-size: 2rem; }

.tagline {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #ffe08a;
}

.sottotitolo { margin: 10px auto 0; max-width: 640px; font-size: 1.05rem; }

main { padding: 8px 12px 32px; }

.card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.10);
  padding: 20px 18px 24px;
  margin: 16px auto;
  max-width: 720px;
}

.card h2 { margin: 0 0 14px; font-size: 1.45rem; }
.card h3 { font-size: 1.3rem; margin: 8px 0 6px; }

label {
  display: block;
  font-weight: 700;
  margin: 16px 0 6px;
  font-size: 1.1rem;
}

input[type="file"],
input[type="number"],
select,
textarea {
  width: 100%;
  font-size: 1.1rem;
  padding: 14px;
  border: 2px solid #b9b9b9;
  border-radius: 12px;
  background: #fff;
  color: #1d1d1d;
}

textarea { resize: vertical; }

#anteprima {
  display: block;
  max-width: 100%;
  border-radius: 12px;
  margin-top: 12px;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  border-radius: 12px;
}

button.grande {
  width: 100%;
  min-height: 60px;
  font-size: 1.2rem;
  font-weight: 700;
  margin-top: 20px;
  padding: 12px;
}

button.primario { background: #0b5cad; color: #fff; }
button.primario:active { background: #084a8a; }

button.vendi { background: #ffc439; color: #1d1d1d; }

button.test {
  width: 100%;
  min-height: 56px;
  font-size: 1.1rem;
  font-weight: 700;
  margin-top: 12px;
  padding: 10px;
  background: #fff;
  color: #a11212;
  border: 3px dashed #a11212;
}

.badge {
  display: inline-block;
  background: #e8f1fb;
  color: #0b5cad;
  font-weight: 700;
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 1rem;
}

table.preventivo {
  width: 100%;
  border-collapse: collapse;
  margin: 14px 0 6px;
  font-size: 1.1rem;
}

table.preventivo td {
  padding: 10px 8px;
  border-bottom: 1px solid #e3e3e3;
  vertical-align: top;
}

table.preventivo td.cifra { text-align: right; font-weight: 600; white-space: nowrap; }

table.preventivo tr.totale td {
  border-bottom: none;
  border-top: 3px solid #0b5cad;
  font-size: 1.25rem;
  font-weight: 800;
}

.note, .note-fondo { font-size: 0.98rem; color: #555; }
.nota-fondo { text-align: center; max-width: 720px; margin: 18px auto 0; }

.messaggio {
  background: #e6f6e6;
  border: 2px solid #2e7d32;
  color: #1b4d1e;
  border-radius: 12px;
  padding: 12px 14px;
  font-weight: 700;
}

/* Schede articolo in bacheca */
.articolo {
  border: 2px solid #e0d9c8;
  border-radius: 14px;
  padding: 16px;
  margin-top: 16px;
  background: #fffdf7;
}

.articolo img {
  width: 100%;
  max-height: 320px;
  object-fit: cover;
  border-radius: 10px;
}

.articolo .titolo { font-size: 1.3rem; font-weight: 800; margin: 10px 0 2px; }
.articolo .desc { margin: 4px 0; color: #444; }
.articolo .prezzo-grande { font-size: 1.7rem; font-weight: 800; margin: 8px 0; }

.stato {
  display: inline-block;
  border-radius: 999px;
  padding: 5px 14px;
  font-weight: 800;
  font-size: 1rem;
}

.stato.disponibile { background: #d8f3d8; color: #1b5e20; }
.stato.venduto { background: #e0e0e0; color: #555; }

.link-pagamento {
  font-size: 0.95rem;
  color: #555;
  word-break: break-all;
  margin: 10px 0 0;
}

.contenitore-paypal { margin-top: 14px; }

.fallback-paypal {
  background: #fff4e0;
  border: 2px solid #e0a100;
  border-radius: 12px;
  padding: 12px 14px;
  font-weight: 600;
}

/* Registro vendite */
#lista-vendite { list-style: none; padding: 0; margin: 0; }

#lista-vendite li {
  padding: 12px 6px;
  border-bottom: 1px solid #e3e3e3;
  font-size: 1.05rem;
}

#lista-vendite .esito-ok { color: #1b5e20; font-weight: 800; }
#lista-vendite .esito-ko { color: #a11212; font-weight: 800; }
