/* ================================================================
   usuario.css — SistemaBurger
   Estilos para: auth pages, user menu, perfil, direcciones, pedidos
   Usa las custom properties de styles.css como base.
   ================================================================ */

/* ── Auth Pages (login / signup / logout) ──────────────────────── */

.auth-page {
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid var(--border);
  border-radius: 28px;
  padding: 28px 24px 32px;
  box-shadow: 0 8px 48px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(16px);
}

.auth-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 20px;
  transition: color 0.15s;
}
.auth-back:hover { color: var(--fg); }

.auth-logo-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 16px;
}
.auth-logo {
  height: 80px;
  width: auto;
  filter: drop-shadow(0 0 20px rgba(200, 80, 255, 0.5));
}

.auth-title {
  text-align: center;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 24px;
  font-weight: 900;
  color: #fff;
  margin-bottom: 4px;
}

.auth-subtitle {
  text-align: center;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 24px;
}

.auth-alert {
  background: rgba(255, 60, 60, 0.15);
  border: 1px solid rgba(255, 60, 60, 0.3);
  border-radius: 12px;
  padding: 10px 14px;
  margin-bottom: 16px;
  font-size: 13px;
  color: #ff8080;
}

/* Social login */
.auth-social {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}

.btn-social {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.15s, transform 0.1s;
  border: none;
}
.btn-social:active { transform: scale(0.98); }

.btn-google {
  background: #fff;
  color: #333;
}
.btn-google:hover { opacity: 0.92; }

/* Divider */
.auth-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px 0;
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* Auth form fields */
.auth-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.auth-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.auth-field label {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.auth-field input {
  width: 100%;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--fg);
  font-size: 14px;
  outline: none;
  transition: border-color 0.15s;
}
.auth-field input:focus {
  border-color: var(--purple);
  background: rgba(139, 53, 200, 0.08);
}
.auth-field input:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.auth-field-error {
  font-size: 11px;
  color: #ff7070;
}

.btn-auth-primary {
  width: 100%;
  padding: 14px;
  border-radius: 14px;
  background: var(--purple);
  color: #fff;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: opacity 0.15s, transform 0.1s;
  margin-top: 4px;
}
.btn-auth-primary:hover   { opacity: 0.9; }
.btn-auth-primary:active  { transform: scale(0.98); }

.auth-footer-links {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
  font-size: 13px;
  color: var(--muted);
}
.auth-footer-links a       { color: var(--muted); transition: color 0.15s; }
.auth-footer-links a:hover { color: var(--fg); }

/* ── Header: login button & user avatar ────────────────────────── */

.btn-login-header {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 20px;
  background: rgba(139, 53, 200, 0.2);
  border: 1px solid var(--border-purple);
  font-size: 12px;
  font-weight: 600;
  color: var(--fg);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
  white-space: nowrap;
}
.btn-login-header:hover {
  background: rgba(139, 53, 200, 0.35);
  border-color: var(--purple);
}

.btn-user-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(139, 53, 200, 0.25);
  border: 1px solid var(--border-purple);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background 0.15s;
  padding: 0;
  overflow: hidden;
}
.btn-user-avatar:hover { background: rgba(139, 53, 200, 0.4); }

.user-avatar-img {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.user-avatar-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ── User Menu Dropdown ────────────────────────────────────────── */

.user-menu-overlay {
  position: fixed;
  inset: 0;
  z-index: 490;
  background: rgba(0, 0, 0, 0.4);
}
.user-menu-overlay.hidden { display: none; }

.user-menu-dropdown {
  position: fixed;
  top: 64px;
  right: 12px;
  z-index: 500;
  width: min(280px, calc(100vw - 24px));
  background: var(--sheet-bg);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6);
  overflow: hidden;
  animation: fadeSlideDown 0.18s ease;
}
.user-menu-dropdown.hidden { display: none; }

@keyframes fadeSlideDown {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.user-menu-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid var(--border);
}

.user-menu-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  overflow: hidden;
  background: rgba(139, 53, 200, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid var(--border-purple);
}
.user-menu-avatar img { width: 100%; height: 100%; object-fit: cover; }

.user-menu-info { min-width: 0; }
.user-menu-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--fg);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-menu-email {
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-menu-items { padding: 8px 0; }

.user-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  font-size: 14px;
  color: var(--fg);
  transition: background 0.1s;
}
.user-menu-item:hover { background: rgba(255, 255, 255, 0.06); }
.user-menu-item svg   { color: var(--muted); flex-shrink: 0; }

.user-menu-divider {
  margin: 4px 16px;
  border: none;
  border-top: 1px solid var(--border);
}

.user-menu-logout { color: #ff7070; }
.user-menu-logout svg { color: #ff7070; }

/* ── User Area Pages (perfil, direcciones, pedidos) ────────────── */

.user-area-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: rgba(10, 3, 25, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.user-area-back {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.07);
  color: var(--fg);
  transition: background 0.15s;
}
.user-area-back:hover { background: rgba(255, 255, 255, 0.12); }

.user-area-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--fg);
}

.user-area-action {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(139, 53, 200, 0.2);
  border: 1px solid var(--border-purple);
  color: var(--fg);
  cursor: pointer;
  transition: background 0.15s;
}
.user-area-action:hover { background: rgba(139, 53, 200, 0.35); }

/* Nav de usuario */
.user-area-nav {
  display: flex;
  background: rgba(0, 0, 0, 0.3);
  border-bottom: 1px solid var(--border);
}

.user-nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 10px 4px;
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  transition: color 0.15s;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.user-nav-item svg { flex-shrink: 0; }
.user-nav-item.active { color: var(--yellow); }
.user-nav-item.active svg { stroke: var(--yellow); }
.user-nav-item:not(.active):hover { color: var(--fg); }

/* Body de las páginas de usuario */
.user-area-body {
  max-width: 480px;
  margin: 0 auto;
  padding: 20px 16px 80px;
}

/* Perfil: avatar */
.perfil-avatar-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-bottom: 24px;
}

.perfil-avatar {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  overflow: hidden;
  background: rgba(139, 53, 200, 0.15);
  border: 2px solid var(--border-purple);
  display: flex;
  align-items: center;
  justify-content: center;
}
.perfil-avatar img { width: 100%; height: 100%; object-fit: cover; }

.btn-change-avatar {
  font-size: 12px;
  font-weight: 600;
  color: var(--purple);
  cursor: pointer;
  padding: 4px 12px;
  border-radius: 20px;
  border: 1px solid var(--border-purple);
  transition: background 0.15s;
}
.btn-change-avatar:hover { background: rgba(139, 53, 200, 0.15); }

/* Formularios de usuario */
.user-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.user-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.user-field label {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.user-field input[type=text],
.user-field input[type=tel],
.user-field input[type=email] {
  width: 100%;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--fg);
  font-size: 14px;
  outline: none;
  transition: border-color 0.15s;
}
.user-field input:focus {
  border-color: var(--purple);
  background: rgba(139, 53, 200, 0.08);
}
.user-field input:disabled { opacity: 0.5; cursor: not-allowed; }

.user-field-checkbox label {
  display: flex;
  align-items: center;
  gap: 8px;
  text-transform: none;
  letter-spacing: 0;
  font-size: 13px;
  font-weight: 500;
  color: var(--fg);
  cursor: pointer;
}
.user-field-checkbox input[type=checkbox] {
  width: 18px;
  height: 18px;
  accent-color: var(--purple);
}

/* Botones */
.btn-user-primary {
  display: block;
  width: 100%;
  padding: 13px 16px;
  border-radius: 14px;
  background: var(--purple);
  color: #fff;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 14px;
  font-weight: 700;
  text-align: center;
  cursor: pointer;
  transition: opacity 0.15s, transform 0.1s;
  border: none;
  margin-top: 4px;
}
.btn-user-primary:hover  { opacity: 0.9; }
.btn-user-primary:active { transform: scale(0.98); }
.btn-user-primary:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-user-secondary {
  display: block;
  width: 100%;
  padding: 12px 16px;
  border-radius: 14px;
  background: transparent;
  border: 1px solid var(--border-purple);
  color: var(--fg);
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  transition: background 0.15s;
}
.btn-user-secondary:hover { background: rgba(139, 53, 200, 0.12); }

.user-danger-zone {
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.btn-user-logout {
  display: block;
  width: 100%;
  padding: 12px 16px;
  border-radius: 14px;
  background: rgba(255, 60, 60, 0.08);
  border: 1px solid rgba(255, 60, 60, 0.2);
  color: #ff7070;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  transition: background 0.15s;
}
.btn-user-logout:hover { background: rgba(255, 60, 60, 0.15); }

/* Toast */
.user-toast {
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 16px;
  text-align: center;
}
.user-toast.ok     { background: rgba(37, 211, 102, 0.15); border: 1px solid rgba(37,211,102,0.3); color: #25D366; }
.user-toast.error  { background: rgba(255, 60, 60, 0.12);  border: 1px solid rgba(255,60,60,0.3);  color: #ff7070; }
.user-toast.hidden { display: none; }

/* Estado vacío */
.user-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 40px 20px;
  color: var(--muted);
  font-size: 14px;
  text-align: center;
}

/* ── Direcciones ───────────────────────────────────────────────── */

.direcciones-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.direccion-card {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 14px 16px;
  transition: border-color 0.15s;
}
.direccion-card.es-default {
  border-color: rgba(255, 215, 0, 0.35);
  background: rgba(255, 215, 0, 0.04);
}

.dir-card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 8px;
}

.dir-alias {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  color: var(--fg);
}
.dir-alias svg { color: var(--purple); flex-shrink: 0; }

.dir-badge-default {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 20px;
  background: rgba(255, 215, 0, 0.12);
  border: 1px solid rgba(255, 215, 0, 0.3);
  color: var(--yellow);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.dir-actions {
  display: flex;
  gap: 6px;
}

.btn-dir-edit,
.btn-dir-delete {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background 0.15s;
}
.btn-dir-edit   { background: rgba(139,53,200,0.12); color: var(--purple); }
.btn-dir-edit:hover { background: rgba(139,53,200,0.25); }
.btn-dir-delete { background: rgba(255,60,60,0.1);  color: #ff7070; }
.btn-dir-delete:hover { background: rgba(255,60,60,0.2); }

.dir-calle {
  font-size: 14px;
  color: var(--fg);
  margin-bottom: 4px;
}

.dir-meta {
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

/* Dir sheet actions */
.sheet-dir-actions {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}
.sheet-dir-actions .btn-user-secondary { flex: 1; }
.sheet-dir-actions .btn-user-primary   { flex: 2; margin-top: 0; }

/* Sheet open state (usamos la misma lógica de bottom-sheet de styles.css) */
#dir-sheet.open { transform: translateY(0) !important; }
#dir-sheet-overlay.visible {
  opacity: 1 !important;
  pointer-events: auto !important;
}

/* ── Pedidos ───────────────────────────────────────────────────── */

.pedidos-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.pedido-card-inner {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 14px 16px;
  transition: background 0.15s, border-color 0.15s, transform 0.1s;
}
button.pedido-card:hover  .pedido-card-inner { background: rgba(0,0,0,0.55); border-color: rgba(255,255,255,0.12); }
button.pedido-card:active .pedido-card-inner { transform: scale(0.99); }

/* Pedido RECIBIDO destacado */
.pedido-card--activo .pedido-card-inner {
  border-color: rgba(255,215,0,0.35);
  background: rgba(255,215,0,0.04);
}
.pedido-card--activo:hover  .pedido-card-inner { border-color: rgba(255,215,0,0.55); }

.pedido-card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 8px;
}

.pedido-numero {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: var(--fg);
  letter-spacing: 0.02em;
  word-break: break-all;
}

.pedido-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
  flex-shrink: 0;
}

.estado-recibido   { background: rgba(255,215,0,0.12);  border: 1px solid rgba(255,215,0,0.35);  color: var(--yellow); }
.estado-reserva    { background: rgba(127,230,255,0.12);border: 1px solid rgba(127,230,255,0.35);color: #7fe6ff; }
.estado-en_proceso { background: rgba(139,53,200,0.15); border: 1px solid rgba(139,53,200,0.4);  color: #c07fff; }
.estado-retirado   { background: rgba(37,211,102,0.1);  border: 1px solid rgba(37,211,102,0.3);  color: #25D366; }
.estado-finalizado { background: rgba(255,255,255,0.05);border: 1px solid rgba(255,255,255,0.12);color: rgba(255,255,255,0.45); }
.estado-cancelado  { background: rgba(255,60,60,0.07);  border: 1px solid rgba(255,60,60,0.2);   color: rgba(255,60,60,0.7); }

.pedido-card-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.pedido-fecha  { font-size: 12px; color: var(--muted); }
.pedido-total  { font-size: 14px; font-weight: 700; color: var(--yellow); font-family: 'Space Grotesk', sans-serif; }

.pedido-tipo {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  color: var(--muted);
}

.pedido-card-cta {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 700;
  color: var(--yellow);
  margin-top: 2px;
}

/* ── Hero de detalle pedido (reutilizado en sheet de mis-pedidos) ── */

.detalle-hero {
  border-radius: 16px;
  border: 1px solid;
  padding: 18px 16px;
  text-align: center;
  margin-bottom: 14px;
}
.detalle-hero-icono  { font-size: 34px; margin-bottom: 10px; }
.detalle-hero-titulo {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 16px;
  font-weight: 800;
  margin-bottom: 8px;
  line-height: 1.3;
}
.detalle-hero-texto {
  font-size: 13px;
  color: rgba(255,255,255,0.6);
  line-height: 1.6;
}

/* ── Address Picker (en el cart sheet para logueados) ───────────── */

.addr-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
}

.addr-option {
  width: 100%;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
  text-align: left;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.addr-option:hover        { background: rgba(255,255,255,0.07); }
.addr-option.active       { background: rgba(255,215,0,0.07); border-color: rgba(255,215,0,0.4); }

.addr-option-radio {
  font-size: 16px;
  color: var(--muted);
  flex-shrink: 0;
  margin-top: 1px;
  line-height: 1;
}
.addr-option.active .addr-option-radio { color: var(--yellow); }

.addr-option-body { flex: 1; min-width: 0; }

.addr-option-alias {
  font-size: 13px;
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 2px;
}
.addr-option.active .addr-option-alias { color: var(--yellow); }

.addr-option-calle {
  font-size: 12px;
  color: rgba(255,255,255,0.55);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.addr-option-ref {
  font-size: 11px;
  color: var(--muted);
  margin-top: 2px;
}

.addr-other-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  padding: 11px 14px;
  border-radius: 12px;
  background: transparent;
  border: 1px dashed rgba(139,53,200,0.4);
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.addr-other-btn:hover {
  background: rgba(139,53,200,0.1);
  border-color: var(--purple);
  color: var(--fg);
}

/* ── Banner sucursal cerrada ─────────────────────────────────────── */

.sucursal-cerrada-banner {
  position: sticky;
  top: 0;
  z-index: 90;
  max-width: 448px;
  margin: 0 auto;
  background: #c0392b;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  text-align: center;
  padding: 8px 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  letter-spacing: .2px;
  border-radius: 0 0 8px 8px;
}

/* ── Banner de pedido activo (pendiente de confirmación) ────────── */

.pedido-activo-banner {
  position: sticky;
  top: 0;
  z-index: 35;
  max-width: 448px;
  margin: 0 auto;
  border-bottom: 2px solid;
  border-radius: 0 0 8px 8px;
  box-shadow: 0 2px 20px rgba(0,0,0,0.4);
  animation: slideDown 0.3s ease;
  transition: background 0.4s ease, border-color 0.4s ease;
}
.pedido-activo-banner.hidden { display: none; }

/* Wrapper centrado — mismo max-width que el header de la carta */
.pab-inner {
  width: 100%;
  padding: 9px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
}

@keyframes slideDown {
  from { transform: translateY(-100%); opacity: 0; }
  to   { transform: translateY(0);     opacity: 1; }
}

.pab-pulse {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  animation: pab-blink 1.5s ease-in-out infinite;
  transition: background 0.4s;
}
@keyframes pab-blink {
  0%, 100% { opacity: 1; transform: scale(1);   }
  50%       { opacity: 0.5; transform: scale(0.8); }
}

.pab-text {
  flex: 1;
  min-width: 0;
}

.pab-titulo {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color 0.4s;
}

.pab-numero {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 12px;
  font-weight: 700;
  color: rgba(255,255,255,0.75);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pab-sub {
  font-size: 10px;
  color: rgba(255,255,255,0.5);
  margin-top: 1px;
}
.pab-sub.hidden { display: none; }

.pab-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.pab-total {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 14px;
  font-weight: 800;
  color: #fff;
}

.pab-btn {
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  border: none;
  transition: opacity 0.15s, transform 0.1s, background 0.4s;
  white-space: nowrap;
}
.pab-btn:hover  { opacity: 0.88; }
.pab-btn:active { transform: scale(0.96); }

/* ── Sheet de pedido activo ─────────────────────────────────────── */

.pab-sheet-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 14px;
}
.pab-sheet-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 20px;
  font-weight: 900;
  color: #fff;
  margin-bottom: 4px;
}
.pab-sheet-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  background: rgba(255,215,0,0.12);
  border: 1px solid rgba(255,215,0,0.3);
  color: var(--yellow);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.pab-sheet-expira {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 10px;
  background: rgba(255, 150, 0, 0.1);
  border: 1px solid rgba(255, 150, 0, 0.25);
  color: rgba(255, 200, 80, 0.9);
  font-size: 12px;
  margin-bottom: 10px;
}

.pab-sheet-dir {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 10px;
  padding: 0 2px;
}

.pab-sheet-items {
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 4px;
}

.pab-sheet-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 14px;
  font-size: 13px;
  color: var(--fg);
  border-bottom: 1px solid var(--border);
}
.pab-sheet-item:last-child { border-bottom: none; }

.pab-item-name  { font-weight: 600; }
.pab-item-size  {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  padding: 1px 7px;
  border-radius: 20px;
  background: rgba(139,53,200,0.2);
  border: 1px solid rgba(139,53,200,0.3);
  color: #c07fff;
  margin-left: 4px;
  vertical-align: middle;
}
.pab-item-det   { margin-top: 3px; padding-left: 4px; list-style: none; font-size: 11px; color: rgba(255,255,255,0.5); }
.pab-item-precio { flex-shrink: 0; font-weight: 700; font-family: 'Space Grotesk', sans-serif; }

.pab-sheet-total {
  display: flex;
  justify-content: space-between;
  padding: 12px 14px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 16px;
  font-weight: 800;
  border-top: 1px solid var(--border);
  margin-bottom: 14px;
}

/* Hero de estado */
.pab-hero {
  border-radius: 16px;
  border: 1px solid;
  padding: 16px;
  text-align: center;
  margin-bottom: 14px;
}
.pab-hero-icono  { font-size: 32px; margin-bottom: 8px; }
.pab-hero-titulo { font-family: 'Space Grotesk', sans-serif; font-size: 16px; font-weight: 800; margin-bottom: 8px; }
.pab-hero-texto  { font-size: 13px; color: rgba(255,255,255,0.65); line-height: 1.5; }

.pab-sheet-actions {
  display: flex;
  gap: 10px;
}

.pab-btn-editar {
  flex: 2;
  padding: 13px;
  border-radius: 14px;
  background: var(--yellow);
  color: var(--ink);
  font-family: 'Space Grotesk', sans-serif;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  border: none;
  transition: opacity 0.15s, transform 0.1s;
}
.pab-btn-editar:hover  { opacity: 0.9; }
.pab-btn-editar:active { transform: scale(0.98); }
.pab-btn-editar:disabled { opacity: 0.5; cursor: not-allowed; }

.pab-btn-cancelar {
  flex: 1;
  padding: 13px;
  border-radius: 14px;
  background: rgba(255, 60, 60, 0.1);
  border: 1px solid rgba(255, 60, 60, 0.25);
  color: #ff7070;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s;
}
.pab-btn-cancelar:hover { background: rgba(255, 60, 60, 0.2); }
.pab-btn-cancelar:disabled { opacity: 0.5; cursor: not-allowed; }

/* El sheet de pedido activo debe quedar por encima del banner (z-index 35) */
#pedido-activo-overlay { z-index: 62; }
#pedido-activo-sheet   { z-index: 63; }

/* ── Modal de seguridad (ban, pedido pendiente) ─────────────────── */

.modal-seg-overlay {
  position: fixed;
  inset: 0;
  z-index: 600;
  background: rgba(0,0,0,0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}
.modal-seg-overlay.visible {
  opacity: 1;
  pointer-events: auto;
}

.modal-seg-panel {
  background: var(--sheet-bg);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 28px 24px;
  width: 100%;
  max-width: 360px;
  animation: fadeSlideDown 0.2s ease;
}

.modal-seg-titulo {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 20px;
  font-weight: 900;
  color: #fff;
  margin-bottom: 10px;
  text-align: center;
}

.modal-seg-body {
  font-size: 14px;
  color: rgba(255,255,255,0.65);
  line-height: 1.6;
  text-align: center;
  margin-bottom: 20px;
}
.modal-seg-body strong { color: var(--yellow); }

.modal-seg-actions {
  display: flex;
  gap: 10px;
}

/* ── Toast global ───────────────────────────────────────────────── */

.global-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  z-index: 9999;
  background: rgba(20, 8, 40, 0.95);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 12px 22px;
  font-size: 13px;
  font-weight: 600;
  color: var(--fg);
  box-shadow: 0 4px 24px rgba(0,0,0,0.5);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
  white-space: nowrap;
  max-width: calc(100vw - 32px);
}
.global-toast.visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ── Cart: botón pedir registrado & login banner ───────────────── */

.btn-pedir-registrado {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 16px;
  border-radius: 16px;
  background: var(--yellow);
  color: var(--ink);
  font-family: 'Space Grotesk', sans-serif;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  transition: opacity 0.15s, transform 0.1s;
  border: none;
}
.btn-pedir-registrado:hover  { opacity: 0.92; }
.btn-pedir-registrado:active { transform: scale(0.98); }

.cart-login-banner {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 10px;
  background: rgba(255, 215, 0, 0.06);
  border: 1px solid rgba(255, 215, 0, 0.15);
  font-size: 12px;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 2px;
}
.cart-login-banner svg { flex-shrink: 0; color: rgba(255,255,255,0.4); }
