/* ============================================================
   Portal participantes — estilos base
   Los colores se sobreescriben con CSS custom properties
   inyectadas desde PHP (client.php) en cada vista del portal.
   ============================================================ */

/* ── Defaults (se pisan desde PHP) ──────────────────────────── */
:root {
  --portal-body-bg:      linear-gradient(135deg, #14532d 0%, #15803d 100%);
  --portal-card-bg:      #15803d;
  --portal-card-text:    #ffffff;
  --portal-accent:       #15803d;
  --portal-accent-hover: #14532d;
  --portal-focus:        rgba(255,255,255,0.25);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; overflow-x: hidden; overflow-y: auto; }
/* Cubre el área de la barra de estado del SO (safe-area-inset-top) */
html { background: var(--portal-card-bg, #15803d); }

/* ── Canvas de animación ─────────────────────────────────────── */
#soccer-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

/* ── Luces de estadio ────────────────────────────────────────── */
.stadium-lights {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.stadium-lights::before,
.stadium-lights::after {
  content: '';
  position: absolute;
  top: -10%;
  width: 60vw;
  height: 100vh;
  animation: lightPulse 4s ease-in-out infinite alternate;
}
.stadium-lights::before {
  left: -15vw;
  background: linear-gradient(135deg, rgba(255,255,255,0.06) 0%, transparent 60%);
  animation-delay: 0s;
}
.stadium-lights::after {
  right: -15vw;
  background: linear-gradient(225deg, rgba(255,255,255,0.06) 0%, transparent 60%);
  animation-delay: 2s;
}
@keyframes lightPulse {
  from { opacity: 0.5; }
  to   { opacity: 1; }
}

/* ── Confetti ────────────────────────────────────────────────── */
.confetti-wrap {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.confetti-piece {
  position: absolute;
  top: -20px;
  opacity: 0;
  animation: confettiFall linear infinite;
}
@keyframes confettiFall {
  0%   { transform: translateY(0) rotate(0deg);       opacity: 0; }
  5%   { opacity: 0.85; }
  90%  { opacity: 0.6; }
  100% { transform: translateY(110vh) rotate(720deg); opacity: 0; }
}

/* ── Body ────────────────────────────────────────────────────── */
.portal-body {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  min-height: 100vh;
  padding: 32px 16px 64px;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--portal-body-bg);
  background-attachment: fixed;
  position: relative;
  overflow-x: hidden;
}

/* ── Card ────────────────────────────────────────────────────── */
.portal-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 440px;
  background: rgba(21, 128, 61, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: var(--portal-card-text);
  border-radius: 18px;
  padding: 2rem 2rem 1.5rem;
  box-shadow:
    0 32px 80px rgba(0,0,0,0.5),
    0 0 0 1px rgba(255,255,255,0.12);
}

/* ── Brand ───────────────────────────────────────────────────── */
.portal-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 1.1rem;
}
.portal-brand-logo {
  height: 64px;
  width: auto;
  margin-bottom: 0.6rem;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.3));
}
/* Logo horizontal con pelota+texto — portal participantes */
.portal-brand-logo-full {
  display: block;
  height: auto;
  width: 100%;
  max-width: 280px;
  margin: 0 auto 0.35rem;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.3));
}
.portal-brand-logos {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin-bottom: 0.4rem;
}
.portal-brand-logos > img {
  flex: 0 0 auto;
  height: 60px;
  max-width: 44%;
  object-fit: contain;
  margin: 0;
  display: block;
}
.portal-brand-logos > .portal-brand-logo-full {
  height: 80px;
}
.portal-brand-logos-sep {
  width: 1px;
  height: 36px;
  background: rgba(255,255,255,0.30);
  flex-shrink: 0;
  margin: 0 0.5rem;
}
.portal-brand-client-logo {
  filter: brightness(0) invert(1);
  opacity: 0.92;
}
.portal-brand-title {
  font-size: 1.2rem;
  font-weight: 900;
  color: #ffffff;
  letter-spacing: -0.3px;
}
.portal-brand-sub {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.7);
  margin-top: 2px;
  text-align: center;
}

/* ── Divisor ─────────────────────────────────────────────────── */
.portal-card hr {
  border-color: rgba(255,255,255,0.2);
  margin: 0.75rem 0;
}

/* ── Tagline ─────────────────────────────────────────────────── */
.portal-tagline {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.8);
  text-align: center;
  margin-bottom: 0.85rem;
}

/* ── Campos ──────────────────────────────────────────────────── */
.portal-card .form-group { margin-bottom: 0.75rem; }

.portal-card .form-control,
.portal-card .form-select {
  background: rgba(255,255,255,0.14);
  border: 1px solid rgba(255,255,255,0.28);
  color: #ffffff;
  border-radius: 8px;
  padding: 0.65rem 0.9rem;
  font-size: 1rem;          /* 16px — evita zoom en iOS */
  transition: border-color 0.18s, box-shadow 0.18s, background 0.18s;
}
.portal-card .form-control::placeholder { color: rgba(255,255,255,0.45); }
.portal-card .form-select option         { background: #166534; color: #fff; }
.portal-card .form-control:focus,
.portal-card .form-select:focus {
  background: rgba(255,255,255,0.22);
  border-color: rgba(255,255,255,0.65);
  box-shadow: 0 0 0 3px rgba(255,255,255,0.12);
  color: #ffffff;
  outline: none;
}

/* Ícono nativo del datepicker — blanco sobre fondo vidrio */
.portal-card input[type="date"]::-webkit-calendar-picker-indicator {
  filter: invert(1) opacity(0.7);
  cursor: pointer;
}

/* Prefix de teléfono */
.portal-card .input-group-text {
  background: rgba(255,255,255,0.15);
  border: 1px solid rgba(255,255,255,0.3);
  border-right: none;
  color: #ffffff;
  font-size: 1rem;
  border-radius: 8px 0 0 8px;
}
.portal-card .input-group .form-control {
  border-radius: 0 8px 8px 0 !important;
}

/* ── Bases y condiciones ─────────────────────────────────────── */
details summary {
  list-style: none;
  outline: none;
  color: rgba(255,255,255,0.7);
  font-size: 0.8rem;
  cursor: pointer;
}
details summary::-webkit-details-marker { display: none; }

.terms-box {
  max-height: 120px;
  overflow-y: auto;
  font-size: 12px;
  background: rgba(255,255,255,0.92);
  color: #0f172a;
  border-radius: 6px;
  padding: 0.75rem !important;
  scrollbar-width: thin;
  scrollbar-color: #cbd5e1 transparent;
}
.terms-box::-webkit-scrollbar { width: 4px; }
.terms-box::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 4px; }

/* ── Checkbox términos ───────────────────────────────────────── */
.form-check-label {
  color: rgba(255,255,255,0.85);
  font-size: 0.85rem;
  cursor: pointer;
}
.form-check-input {
  background-color: rgba(255,255,255,0.15);
  border-color: rgba(255,255,255,0.5);
}
.form-check-input:checked {
  background-color: #ffffff;
  border-color: #ffffff;
  /* tick verde sobre fondo blanco */
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3e%3cpath fill='none' stroke='%2315803d' stroke-width='3' d='m6 10 3 3 5-5'/%3e%3c/svg%3e");
}

/* ── Botón principal ─────────────────────────────────────────── */
.btn-portal {
  display: block;
  width: 100%;
  background: #ffffff;
  border: none;
  color: var(--portal-card-bg);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.7rem;
  border-radius: 8px;
  transition: background 0.18s, color 0.18s, box-shadow 0.18s;
  cursor: pointer;
  margin-top: 0.5rem;
  text-align: center;
  text-decoration: none;
  box-shadow: 0 2px 12px rgba(0,0,0,0.15);
}
.btn-portal:hover:not(:disabled) {
  background: #f0fdf4;
  color: var(--portal-accent-hover);
  box-shadow: 0 4px 20px rgba(0,0,0,0.2);
}
.btn-portal:disabled {
  background: rgba(255,255,255,0.25) !important;
  color: rgba(255,255,255,0.5) !important;
  pointer-events: none;
}
.btn-portal--secondary {
  background: rgba(255,255,255,0.12);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.3);
  box-shadow: none;
  font-weight: 600;
}
.btn-portal--secondary:hover:not(:disabled) {
  background: rgba(255,255,255,0.2);
  color: #fff;
  box-shadow: none;
}

/* ── Texto de ayuda ──────────────────────────────────────────── */
.portal-hint {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.65);
  margin-top: 0.25rem;
}

/* ── Alertas ─────────────────────────────────────────────────── */
.portal-alert {
  border-radius: 8px;
  padding: 0.6rem 0.85rem;
  font-size: 0.82rem;
  text-align: center;
  margin-bottom: 0.75rem;
}
.portal-alert.error   { background: rgba(254,242,242,0.95); border: 1px solid #fca5a5; color: #dc2626; }
.portal-alert.success { background: rgba(240,253,244,0.95); border: 1px solid #86efac; color: #15803d; }

/* ── Texto readonly en postRegistration ─────────────────────── */
.portal-card .form-control[readonly] {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.85);
  cursor: default;
}

/* ── Texto de éxito ──────────────────────────────────────────── */
.portal-success-title {
  font-size: 1rem;
  font-weight: 700;
  color: #ffffff;
  text-align: center;
  margin-bottom: 0.25rem;
}
.portal-success-sub {
  font-size: 0.83rem;
  color: rgba(255,255,255,0.75);
  text-align: center;
  margin-bottom: 0;
}

/* ── Footer de la card ───────────────────────────────────────── */
.portal-footer {
  margin-top: 1.25rem;
  text-align: center;
  border-top: 1px solid rgba(255,255,255,0.15);
  padding-top: 0.85rem;
  font-size: 0.7rem;
  color: rgba(255,255,255,0.4);
}

/* ── WhatsApp FAB ────────────────────────────────────────────── */
.whatsapp-fab {
  position: fixed;
  width: 52px;
  height: 52px;
  bottom: 28px;
  right: 28px;
  background: #ffffff;
  border-radius: 50%;
  z-index: 100;
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s;
  text-decoration: none;
}
.whatsapp-fab:hover { transform: scale(1.08); }
.whatsapp-fab svg { width: 30px; height: 30px; fill: #25d366; }

/* ── Responsive móvil ────────────────────────────────────────── */
@media (max-width: 576px) {
  .portal-body { padding: 16px 10px 64px; }

  .portal-card {
    border-radius: 14px;
    padding: 1.5rem 1.1rem 1.25rem;
  }

  .portal-brand-logo { height: 52px; }

  /* 16px explícito previene zoom automático en iOS/Safari */
  .portal-card .form-control,
  .portal-card .input-group-text { font-size: 16px !important; }

  .whatsapp-fab { width: 46px; height: 46px; bottom: 16px; right: 14px; }
  .whatsapp-fab svg { width: 24px; height: 24px; }
}

/* ══════════════════════════════════════════════════════════════
   App Shell — main.php (dashboard personal del participante)
   ══════════════════════════════════════════════════════════════ */

/* Fondo de la página — sin scroll propio, shell lo maneja */
.p-app {
  background: var(--portal-body-bg);
  background-attachment: fixed;
  font-family: Arial, Helvetica, sans-serif;
}

/* Contenedor principal en columna — fixed para cubrir exactamente
   el viewport (incluyendo la zona de la barra de estado del SO) */
.p-shell {
  position: fixed;
  inset: 0;            /* top:0 right:0 bottom:0 left:0 */
  display: flex;
  flex-direction: column;
  z-index: 1;
  /* sin overflow — necesario para que el FAB sobresalga de la barra inferior */
}

/* ── Header fijo ─────────────────────────────────────────────── */
.p-header {
  flex-shrink: 0;
  height: calc(60px + env(safe-area-inset-top, 0px));
  padding-top: calc(0.15rem + env(safe-area-inset-top, 0px));
  padding-bottom: 0.15rem;
  background: rgba(0,0,0,0.30);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255,255,255,0.12);
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  padding-left: 1rem;
  padding-right: 1rem;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.p-header-logo {
  height: 54px;
  width: auto;
  flex-shrink: 0;
}
.p-header-brand-sep {
  width: 1px;
  height: 28px;
  background: rgba(255,255,255,0.30);
  flex-shrink: 0;
}
.p-header-client-logo {
  height: 38px;
  width: auto;
  max-width: 110px;
  flex-shrink: 0;
  object-fit: contain;
  filter: brightness(0) invert(1);
  opacity: 0.92;
}
.topbar-rolling-ball {
  position: absolute;
  bottom: 5px;
  width: 26px;
  height: 26px;
  pointer-events: none;
  animation: topbarBallRoll 22s linear infinite;
  will-change: transform, left;
}
.tb-ball-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.tb-ball-pattern {
  mix-blend-mode: multiply;
  opacity: 0.85;
}
@keyframes topbarBallRoll {
  0%   { left: -2rem; transform: rotate(0deg);    opacity: 0; }
  4%   { opacity: 0.5; }
  96%  { opacity: 0.5; }
  100% { left: 102%;   transform: rotate(6120deg); opacity: 0; }
}
/* Botón "Nueva venta" en el header */
.p-add-btn {
  flex-shrink: 0;
  background: #ffffff;
  color: var(--portal-card-bg);
  border-radius: 22px;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.4rem 0.9rem;
  font-size: 0.82rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 2px 10px rgba(0,0,0,0.25);
  transition: transform 0.18s, box-shadow 0.18s;
}
.p-add-btn:hover { transform: scale(1.04); color: var(--portal-card-bg); box-shadow: 0 4px 16px rgba(0,0,0,0.3); }

/* ── Área de contenido desplazable ───────────────────────────── */
.p-content {
  flex: 1;
  min-height: 0;   /* evita overflow en Safari/Firefox */
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 1.1rem;
}

/* Secciones: una sola visible a la vez */
.p-section          { display: none; }
.p-section.active   { display: block; }

/* ── Barra de navegación inferior ───────────────────────────── */
.p-bottom-nav {
  flex-shrink: 0;
  height: 62px;
  height: calc(62px + env(safe-area-inset-bottom, 0px));
  padding-bottom: env(safe-area-inset-bottom, 0px);
  background: rgba(0,0,0,0.40);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid rgba(255,255,255,0.12);
  display: flex;
  align-items: stretch;
  overflow: visible; /* permite que el FAB sobresalga */
  position: relative;
  z-index: 10;
}
.p-nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  background: none;
  border: none;
  color: rgba(255,255,255,0.45);
  font-size: 0.62rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  cursor: pointer;
  transition: color 0.18s;
  padding: 0.3rem 0;
}
.p-nav-item i             { font-size: 1.25rem; transition: transform 0.18s; line-height: 1; }
.p-nav-item.active        { color: #fff; }
.p-nav-item.active i      { transform: scale(1.1); }
.p-nav-item:not(.active):hover { color: rgba(255,255,255,0.75); }

/* ── Grupos laterales (izq/der del FAB) ──────────────────────── */
/* Cada grupo tiene 2 ítems → flex:2; FAB tiene flex:1 → 5 partes iguales */
.p-nav-group {
  flex: 2;
  display: flex;
  align-items: stretch;
}

/* ── FAB central en la nav inferior ─────────────────────────── */
.p-nav-fab {
  flex: 1;              /* misma fracción que cada ítem → 5 partes iguales */
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding-bottom: 6px;
  text-decoration: none;
  overflow: visible;
  background: none;
  border: none;
  cursor: default;
}
.p-nav-fab-circle {
  position: absolute;   /* relativo a .p-bottom-nav (position:relative) */
  top: -22px;
  left: 50%;            /* centrado exacto en todo el ancho de la nav */
  transform: translateX(-50%);
  width: 52px;
  height: 52px;
  background: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 -4px 20px rgba(0,0,0,0.45), 0 2px 8px rgba(0,0,0,0.2);
  color: var(--portal-card-bg, #15803d);
  font-size: 1.5rem;
  transition: box-shadow 0.18s;
  border: 3px solid rgba(255,255,255,0.15);
}
.p-nav-fab:hover .p-nav-fab-circle,
.p-nav-fab:active .p-nav-fab-circle {
  box-shadow: 0 -6px 28px rgba(0,0,0,0.55), 0 2px 10px rgba(0,0,0,0.25);
}
.p-nav-fab-label {
  position: absolute;   /* centrado exacto en todo el ancho de la nav */
  bottom: 6px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.58rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: rgba(255,255,255,0.55);
  line-height: 1;
  white-space: nowrap;
}

/* ── Menú "Más" flotante sobre la nav ────────────────────────── */
.p-nav-more-wrap {
  position: relative;
  flex: 1;
  display: flex;
  align-items: stretch;
}
.p-nav-more-menu {
  position: absolute;
  bottom: calc(100% + 10px);
  right: 4px;
  background: rgba(15,23,42,0.97);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 14px;
  overflow: hidden;
  display: none;
  z-index: 50;
  min-width: 200px;
  box-shadow: 0 -8px 32px rgba(0,0,0,0.45);
}
.p-nav-more-menu.open { display: block; }
.p-nav-more-identity {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.85rem 1rem;
}
.p-nav-more-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  border: 1.5px solid rgba(255,255,255,0.30);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.88rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
  letter-spacing: 0.5px;
}
.p-nav-more-identity-info {
  min-width: 0;
}
.p-nav-more-identity-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.25;
}
.p-nav-more-identity-pos {
  font-size: 0.68rem;
  color: rgba(255,255,255,0.50);
  margin-top: 0.1rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.p-nav-more-identity-pos i { font-size: 0.62rem; }
.p-nav-more-divider {
  height: 1px;
  background: rgba(255,255,255,0.10);
  margin: 0;
}
.p-nav-more-item {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.75rem 1.1rem;
  color: rgba(255,255,255,0.75);
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  transition: background 0.15s, color 0.15s;
}
.p-nav-more-item:last-child { border-bottom: none; }
.p-nav-more-item i { font-size: 1.1rem; }
.p-nav-more-item:hover,
.p-nav-more-item.active { background: rgba(255,255,255,0.08); color: #fff; }
.p-nav-more-item--danger { color: #fca5a5; }
.p-nav-more-item--danger:hover { background: rgba(239,68,68,0.15); color: #fca5a5; }

/* ── Encabezados de sección ──────────────────────────────────── */
.p-section-head {
  font-size: 0.7rem;
  font-weight: 700;
  color: rgba(255,255,255,0.55);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  margin-bottom: 0.6rem;
  padding-bottom: 0.3rem;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

/* ── Filtros pill ────────────────────────────────────────────── */
.filter-pills {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-bottom: 0.85rem;
}
.filter-pill {
  padding: 0.25rem 0.7rem;
  border-radius: 20px;
  border: 1px solid rgba(255,255,255,0.22);
  background: rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.6);
  font-size: 0.73rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.filter-pill.active {
  background: rgba(255,255,255,0.22);
  color: #fff;
  border-color: rgba(255,255,255,0.45);
}

/* ── Tarjetas de venta ───────────────────────────────────────── */
.sale-card {
  background: rgba(255,255,255,0.10);
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 10px;
  margin-bottom: 0.65rem;
  overflow: hidden;
}
.sale-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0.85rem;
  background: rgba(0,0,0,0.18);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  gap: 0.5rem;
}
.sale-card-meta {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.65);
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.sale-card-meta strong { color: #fff; font-size: 0.83rem; }
.sale-card-actions     { display: flex; align-items: center; gap: 0.4rem; flex-shrink: 0; }
.sale-card-body        { padding: 0.5rem 0.85rem; }
.sale-item-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.8);
  padding: 0.18rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.sale-item-row:last-child { border-bottom: none; }
.sale-total {
  font-size: 0.78rem;
  font-weight: 700;
  color: #fff;
  text-align: right;
  padding-top: 0.35rem;
  margin-top: 0.28rem;
  border-top: 1px solid rgba(255,255,255,0.12);
}
/* Badges de estado */
.sale-badge {
  font-size: 0.73rem;
  font-weight: 600;
  padding: 0.18rem 0.55rem;
  border-radius: 20px;
  white-space: nowrap;
}
.sale-badge-pending  { background: rgba(253,230,138,0.15); color: #fde68a; border: 1px solid rgba(253,230,138,0.28); }
.sale-badge-verified { background: rgba(134,239,172,0.15); color: #86efac; border: 1px solid rgba(134,239,172,0.28); }
.sale-badge-rejected { background: rgba(252,165,165,0.15); color: #fca5a5; border: 1px solid rgba(252,165,165,0.28); }
/* Icono info motivo rechazo */
.sale-rejection-reason { color: #fca5a5; font-size: 0.85rem; cursor: help; margin-left: 0.3rem; }
/* Bloque motivo de rechazo */
.sale-rejection-box {
  margin: 0 0.85rem 0.65rem;
  padding: 0.5rem 0.7rem;
  background: rgba(252,165,165,0.08);
  border: 1px solid rgba(252,165,165,0.22);
  border-radius: 8px;
  font-size: 0.8rem;
  color: #fca5a5;
  display: flex;
  gap: 0.45rem;
  align-items: flex-start;
}
.sale-rejection-box i { flex-shrink: 0; margin-top: 0.1rem; }
.sale-rejection-box--clickable { cursor: pointer; }
.sale-rejection-box--clickable:hover { background: rgba(252,165,165,0.14); border-color: rgba(252,165,165,0.4); }
/* Botón editar */
.sale-edit-btn {
  font-size: 0.78rem;
  padding: 0.18rem 0.5rem;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,0.22);
  background: rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.8);
  cursor: pointer;
  transition: background 0.15s;
}
.sale-edit-btn:hover { background: rgba(255,255,255,0.18); }
.sale-delete-btn {
  font-size: 0.78rem;
  padding: 0.18rem 0.5rem;
  border-radius: 6px;
  border: 1px solid rgba(220,53,69,0.4);
  background: rgba(220,53,69,0.12);
  color: rgba(255,130,130,0.9);
  cursor: pointer;
  transition: background 0.15s;
}
.sale-delete-btn:hover { background: rgba(220,53,69,0.28); }

/* ── Perfil: tarjeta de identidad ───────────────────────────── */
.p-profile-card {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  background: rgba(255,255,255,0.10);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 14px;
  padding: 0.9rem 1rem;
  margin-bottom: 1rem;
}
.p-profile-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255,255,255,0.20);
  border: 2px solid rgba(255,255,255,0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
  letter-spacing: 0.5px;
}
.p-profile-card-info {
  min-width: 0;
}
.p-profile-fullname {
  font-size: 0.92rem;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.25;
}
.p-profile-pos-name {
  font-size: 0.74rem;
  color: rgba(255,255,255,0.55);
  margin-top: 0.15rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Perfil: campos readonly ─────────────────────────────────── */
.perfil-field-label {
  font-size: 0.68rem;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
  letter-spacing: 0.4px;
  margin-bottom: 0.12rem;
}
.perfil-field-value {
  font-size: 0.9rem;
  color: #fff;
  font-weight: 500;
}

/* ── Selects dentro del modal de edición ────────────────────── */
/* background-color solo (no background) para conservar la flecha SVG de Bootstrap */
.portal-modal .form-select {
  background-color: #252d3c;
  border: 1px solid rgba(255,255,255,0.20);
  color: #fff;
  border-radius: 8px;
  color-scheme: dark;
}
.portal-modal .form-select:focus {
  background-color: #2e3a4e;
  border-color: rgba(255,255,255,0.40);
  color: #fff;
  box-shadow: 0 0 0 3px rgba(255,255,255,0.12);
}
.portal-modal .form-select option { background: #252d3c; color: #fff; }

/* ── Editor de ítems en modal de edición de venta ───────────── */
.edit-item-row {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 10px;
  padding: 0.65rem 0.7rem;
  margin-bottom: 0.5rem;
}

/* ── Perfil: campos editables ───────────────────────────────── */
.perfil-input {
  width: 100%;
  background: rgba(255,255,255,0.10);
  border: 1px solid rgba(255,255,255,0.20);
  color: #fff;
  border-radius: 8px;
  padding: 0.4rem 0.65rem;
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.15s, background 0.15s;
}
.perfil-input:focus {
  background: rgba(255,255,255,0.16);
  border-color: rgba(255,255,255,0.45);
}
.perfil-input::placeholder { color: rgba(255,255,255,0.3); }

/* ── Estado vacío ────────────────────────────────────────────── */
.p-empty {
  text-align: center;
  padding: 2rem 1rem;
  color: rgba(255,255,255,0.4);
  font-size: 0.85rem;
}
.p-empty i { font-size: 2rem; display: block; margin-bottom: 0.5rem; }

/* ── Premios: grid de productos ──────────────────────────────── */
.premios-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}
.premio-card {
  background: rgba(255,255,255,0.09);
  border: 1px solid rgba(255,255,255,0.13);
  border-radius: 12px;
  padding: 1rem 0.75rem 0.85rem;
  text-align: center;
  position: relative;
}
.premio-card-icon {
  font-size: 2rem;
  line-height: 1;
  margin-bottom: 0.45rem;
}
.premio-card-img-wrap {
  width: calc(100% + 1.5rem);
  margin: -1rem -0.75rem 0.65rem;
  border-radius: 12px 12px 0 0;
  overflow: hidden;
  background: rgba(0,0,0,0.25);
}
.premio-card-img {
  width: 100%;
  display: block;
  object-fit: contain;
}
.premio-card-name {
  font-size: 0.8rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.25rem;
  line-height: 1.2;
}
.premio-card-points {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  margin-bottom: 0.5rem;
}
.premio-card-points-num {
  font-size: 1.1rem;
  font-weight: 700;
  color: #fde68a;
  letter-spacing: 0.01em;
  line-height: 1.2;
}
.premio-card-points-label {
  font-size: 0.65rem;
  font-weight: 500;
  color: rgba(253,230,138,0.65);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  line-height: 1.2;
}
.premio-card-badge {
  display: inline-block;
  font-size: 0.62rem;
  font-weight: 600;
  background: rgba(253,230,138,0.15);
  color: #fde68a;
  border: 1px solid rgba(253,230,138,0.3);
  border-radius: 20px;
  padding: 0.15rem 0.5rem;
  white-space: nowrap;
}

/* Premio card: clickeable */
.premio-card {
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}
.premio-card:active { transform: scale(0.96); }
.premio-card:hover  { box-shadow: 0 4px 20px rgba(0,0,0,0.3); }

/* ── Modal de detalle de premio ───────────────────────────────── */
.premio-foto-main {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 0.6rem;
  cursor: zoom-in;
  background: rgba(255,255,255,0.06);
}
.premio-foto-main.empty {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3.5rem;
  cursor: default;
}
.premio-thumbs {
  display: flex;
  gap: 0.4rem;
  overflow-x: auto;
  padding-bottom: 0.2rem;
  scrollbar-width: none;
}
.premio-thumbs::-webkit-scrollbar { display: none; }
.premio-thumb {
  flex-shrink: 0;
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 7px;
  cursor: zoom-in;
  border: 2px solid transparent;
  transition: border-color 0.15s, opacity 0.15s;
  opacity: 0.65;
}
.premio-thumb.active, .premio-thumb:hover {
  border-color: #4ade80;
  opacity: 1;
}
.premio-desc {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.75);
  line-height: 1.55;
  margin-top: 0.75rem;
}
.premio-points-big {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  background: rgba(253,230,138,0.18);
  border: 1px solid rgba(253,230,138,0.5);
  border-radius: 20px;
  padding: 0.4rem 1.2rem;
  margin-bottom: 0.75rem;
}
.premio-points-big #premioPointsNum {
  color: #fde68a;
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  line-height: 1.2;
}
.premio-points-big-label {
  font-size: 0.65rem;
  font-weight: 500;
  color: rgba(253,230,138,0.65);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  line-height: 1.3;
}

/* ── Contacto: tarjeta de soporte ─────────────────────────────── */
.contacto-card {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.13);
  border-radius: 14px;
  padding: 1.75rem 1.25rem 1.5rem;
  text-align: center;
}
.contacto-card-icon {
  font-size: 2.5rem;
  margin-bottom: 0.6rem;
}
.contacto-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.3rem;
}
.contacto-card-subtitle {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.55);
  margin-bottom: 1.1rem;
}
.contacto-wa-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: #25d366;
  color: #fff;
  font-weight: 700;
  font-size: 0.9rem;
  border: none;
  border-radius: 50px;
  padding: 0.65rem 1.4rem;
  text-decoration: none;
  margin-bottom: 0.75rem;
  transition: background 0.15s;
}
.contacto-wa-btn:hover { background: #1fba59; color: #fff; }
.contacto-email-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  color: rgba(255,255,255,0.6);
  font-size: 0.82rem;
  text-decoration: none;
  padding: 0.3rem;
}
.contacto-email-btn:hover { color: rgba(255,255,255,0.9); }

/* ══════════════════════════════════════════════════════════════
   Mobile — Header en 2 filas: branding arriba, nombre abajo
   ══════════════════════════════════════════════════════════════ */
@media (max-width: 576px) {

  /* Logos en mobile — ligeramente más chicos que base */
  .p-header-logo {
    height: 52px;
  }
  .p-header-client-logo {
    height: 36px;
    max-width: 108px;
  }
}

/* ══════════════════════════════════════════════════════════════
   Desktop — App Shell como card centrado
   ══════════════════════════════════════════════════════════════ */
@media (min-width: 768px) {

  /* El fondo ocupa toda la pantalla */
  .p-app {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
  }

  /* El shell pasa de fixed-fullscreen a card centrado */
  .p-shell {
    position: relative;
    inset: auto;
    width: 100%;
    max-width: 460px;
    height: 90vh;
    max-height: 900px;
    border-radius: 28px;
    overflow: hidden;
    box-shadow:
      0 40px 100px rgba(0,0,0,0.6),
      0 0 0 1px rgba(255,255,255,0.10);
  }

  /* El canvas de fondo cubre toda la ventana, no el card */
  #soccer-canvas {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    pointer-events: none;
  }

  /* El confetti también fuera del card */
  .confetti-wrap,
  .stadium-lights {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
  }

  /* El header no necesita safe-area en desktop */
  .p-header {
    height: 60px;
    padding-top: 0.15rem;
    padding-bottom: 0.15rem;
    flex-direction: row;
    justify-content: space-between;
  }

  /* La nav inferior tampoco necesita safe-area en desktop */
  .p-bottom-nav {
    height: 60px;
    padding-bottom: 0;
  }
}

/* Stage badge — inactive state */
.badge-stage-inactive {
  text-decoration: line-through !important;
  opacity: 0.65;
}
