:root {
  --naranja: #F97316;
  --naranja-osc: #EA580C;
  --crema: #FFF7ED;
  --texto: #1F2937;
  --gris: #6B7280;
  --verde: #16A34A;
  --rojo: #DC2626;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; }
body {
  background: var(--crema);
  color: var(--texto);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 18px;
  line-height: 1.45;
  min-height: 100vh;
  padding: calc(16px + env(safe-area-inset-top)) 16px calc(24px + env(safe-area-inset-bottom));
}
.hidden { display: none !important; }
.screen { max-width: 460px; margin: 0 auto; }
.card {
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 6px 24px rgba(124, 45, 18, .10);
  padding: 22px 20px;
  margin-bottom: 16px;
}
h1 { font-size: 26px; line-height: 1.2; margin: 0 0 10px; }
h2 { font-size: 20px; margin: 0 0 12px; }
p { margin: 0 0 10px; }
.title { font-size: 34px; text-align: center; }
.lead { text-align: center; font-size: 19px; margin-bottom: 20px; }
.logo { display: block; margin: 0 auto 12px; border-radius: 16px; }
label { display: block; font-weight: 600; margin-bottom: 6px; }
input {
  width: 100%; font: inherit; font-size: 19px; padding: 14px; border: 2px solid #FED7AA;
  border-radius: 14px; color: var(--texto); background: #fff;
}
input:focus { outline: none; border-color: var(--naranja); }

.btn {
  display: block; width: 100%; text-align: center; text-decoration: none;
  font: inherit; font-weight: 700; font-size: 18px; padding: 14px 12px; border: 0; border-radius: 14px;
  background: var(--naranja); color: #fff; cursor: pointer; margin-top: 12px;
}
.btn:active { background: var(--naranja-osc); }
.btn:disabled { opacity: .55; }
.btn.big { font-size: 21px; padding: 18px; }
.btn.ghost { background: #FFEDD5; color: #9A3412; }
.btn.green { background: var(--verde); }
.row { display: flex; gap: 10px; }
.row .btn { flex: 1; font-size: 16px; padding: 14px 8px; }
.err { color: var(--rojo); font-weight: 600; margin-top: 10px; min-height: 1em; }
.note { color: var(--verde); font-weight: 600; text-align: center; margin: 8px 0 0; min-height: 1em; }

.steps { list-style: none; padding: 0; margin: 18px 0; }
.steps li { display: flex; gap: 14px; align-items: flex-start; font-size: 20px; margin-bottom: 16px; }
.steps .n {
  flex: 0 0 40px; height: 40px; border-radius: 50%; background: var(--naranja); color: #fff;
  font-weight: 800; display: flex; align-items: center; justify-content: center; font-size: 20px;
}
.share-ico { display: inline-block; border: 2px solid currentColor; border-radius: 4px; padding: 0 4px; font-size: 14px; }
.warn { background: #FFEDD5; border-radius: 14px; padding: 12px 14px; font-size: 16px; }
.warn p:last-child { margin: 0; }
.small-link { display: block; text-align: center; margin-top: 18px; font-size: 14px; color: var(--gris); }

.car-name { text-align: center; word-break: break-word; }
.qr-box { background: #fff; padding: 8px; border-radius: 12px; border: 2px solid #FED7AA; }
.qr-box img { display: block; width: 100%; height: auto; aspect-ratio: 1; }

.push-on { color: var(--verde); font-weight: 700; font-size: 19px; margin: 0; }
.push-help { font-size: 16px; color: var(--texto); }
.push-help ol { padding-left: 22px; margin: 6px 0 0; }

.alert-card { border: 2px solid #FED7AA; border-radius: 14px; padding: 14px; margin-bottom: 12px; }
.alert-card.pending { border-color: var(--rojo); background: #FEF2F2; }
.alert-card.done { border-color: #BBF7D0; background: #F0FDF4; }
.alert-head { display: flex; justify-content: space-between; gap: 8px; font-weight: 700; }
.alert-time { color: var(--gris); font-weight: 600; }
.alert-msg { margin: 8px 0 0; font-style: italic; word-break: break-word; }
.alert-card .btn { margin-top: 10px; background: var(--rojo); }
.empty { color: var(--gris); text-align: center; margin: 4px 0; }

.footer-actions { display: flex; flex-direction: column; align-items: center; gap: 6px; margin-top: 8px; }
.link-btn { background: none; border: 0; font: inherit; font-size: 15px; color: var(--gris); padding: 10px; cursor: pointer; }

/* Alarma */
.alarm {
  position: fixed; inset: 0; z-index: 100; background: var(--rojo); color: #fff;
  display: flex; align-items: center; justify-content: center; text-align: center;
  padding: calc(24px + env(safe-area-inset-top)) 20px calc(24px + env(safe-area-inset-bottom));
  animation: pulse 1s ease-in-out infinite alternate;
}
@keyframes pulse { from { background: var(--rojo); } to { background: #B91C1C; } }
.alarm-inner { width: 100%; max-width: 440px; }
.alarm-ico { font-size: 90px; line-height: 1; margin-bottom: 14px; }
.alarm h1 { font-size: 32px; margin-bottom: 12px; }
.alarm p { font-size: 20px; }
.alarm-msg { background: rgba(255,255,255,.18); border-radius: 14px; padding: 12px; font-style: italic; word-break: break-word; }
.alarm-btn {
  width: 100%; margin-top: 22px; padding: 26px 12px; border: 0; border-radius: 22px; background: #fff;
  color: var(--rojo); font: inherit; font-size: 34px; font-weight: 800; cursor: pointer;
  box-shadow: 0 8px 30px rgba(0,0,0,.25);
}
.alarm-mute { display: inline-block; margin-top: 22px; color: #fff; font-size: 17px; }
