/* Portal Repartidor (rapp) — estilos mobile-first */
body.portal-body { font-family: -apple-system, 'Segoe UI', Roboto, sans-serif; background: #f4f6f8; padding-bottom: 80px; min-height: 100vh; }
body.login-body { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: linear-gradient(160deg, #1F2370 0%, #161A55 100%); font-family: 'Segoe UI', system-ui, sans-serif; padding: 20px; }

.app-header { background: linear-gradient(160deg, #1F2370, #161A55); color: #fff; padding: 12px 16px; position: sticky; top: 0; z-index: 100; }
.app-header .logo { width: 30px; height: 30px; border-radius: 8px; }

/* Login */
.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: linear-gradient(160deg, #1F2370 0%, #161A55 100%); padding: 20px; }
.portal-card { width: 100%; max-width: 400px; background: rgba(255,255,255,0.97); border-radius: 24px; padding: 40px 32px; box-shadow: 0 25px 60px rgba(0,0,0,0.35); }
.portal-logo { width: 72px; height: 72px; margin: 0 auto 16px; border-radius: 20px; background: #1F2370; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.portal-logo img { width: 100%; height: 100%; object-fit: cover; }
.portal-empresa { text-align: center; font-size: 1.25rem; font-weight: 700; color: #1F2370; margin-bottom: 4px; }
.portal-sub { text-align: center; color: #64748b; font-size: 0.85rem; margin-bottom: 28px; }
.portal-label { font-size: 0.78rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; color: #475569; margin-bottom: 6px; }
.portal-input { width: 100%; border: 2px solid #e2e8f0; border-radius: 14px; padding: 14px 16px 14px 46px; font-size: 1rem; transition: border-color .15s, box-shadow .15s; }
.portal-input:focus { border-color: #0284c7; box-shadow: 0 0 0 4px rgba(2,132,199,.12); outline: none; }
.input-wrap { position: relative; margin-bottom: 18px; }
.input-wrap > i { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: #94a3b8; font-size: 1.1rem; }
.btn-portal { width: 100%; padding: 15px; border: none; border-radius: 14px; background: linear-gradient(135deg, #0284c7, #0369a1); color: #fff; font-size: 1rem; font-weight: 700; letter-spacing: 0.3px; transition: transform .15s, box-shadow .15s; }
.btn-portal:active { transform: scale(0.98); }
.btn-portal:hover { box-shadow: 0 10px 25px rgba(2,132,199,.4); }
.portal-footer { margin-top: 24px; text-align: center; font-size: 0.75rem; color: #94a3b8; }
.alert-portal { border-radius: 12px; font-size: 0.85rem; padding: 12px 14px; }

/* Paradas */
.parada-card { border-left: 4px solid #dee2e6; border-radius: 10px; background: #fff; }
.parada-card.entregada { border-left-color: #059669; }
.parada-card.parcial { border-left-color: #d97706; }
.parada-card.rechazada, .parada-card.no_entregada { border-left-color: #dc2626; }
.parada-card.pendiente { border-left-color: #0284C7; }
.parada-num { width: 34px; height: 34px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); background: #0284c7; color: #fff; font-weight: 700; display: flex; align-items: center; justify-content: center; flex: 0 0 34px; }
.parada-num span { transform: rotate(45deg); display: inline-block; }
.parada-num.entregada { background: #16a34a; }
.parada-num.parcial { background: #d97706; }
.parada-num.problema { background: #dc2626; }
.item-chip { font-size: .78rem; background: #f1f5f9; border-radius: 8px; padding: 3px 8px; }
.accion-btn { border-radius: 10px; font-size: .85rem; }
.empty-state { text-align: center; padding: 60px 20px; color: #64748b; }

/* Stats inicio */
.stat-card { background: #fff; border-radius: 14px; padding: 14px; box-shadow: 0 1px 4px rgba(15,23,42,.08); }
.stat-card .n { font-size: 1.35rem; font-weight: 800; color: #1F2370; }
.stat-card .l { font-size: .72rem; color: #64748b; text-transform: uppercase; letter-spacing: .4px; }

/* Bottom nav */
.bottom-nav { position: fixed; bottom: 0; left: 0; right: 0; background: #1F2370; display: flex; z-index: 100; }
.bottom-nav a { flex: 1; text-align: center; padding: 9px 2px; color: #94a3b8; text-decoration: none; font-size: 0.66rem; }
.bottom-nav a.active, .bottom-nav a:hover { color: #38bdf8; }
.bottom-nav i { display: block; font-size: 1.25rem; margin-bottom: 1px; }

/* GPS indicator */
.estado-badge { font-size: 0.7rem; }
.gps-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.gps-on { background: #22c55e; animation: pulse 1.5s infinite; }
.gps-off { background: #dc2626; }
@keyframes pulse { 0%,100% { opacity: 1 } 50% { opacity: .4 } }

/* Menu items */
.menu-item { display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: #fff; border-radius: 12px; text-decoration: none; color: #1F2370; margin-bottom: 10px; box-shadow: 0 1px 3px rgba(15,23,42,.07); }
.menu-item i { font-size: 1.2rem; color: #0284c7; width: 24px; text-align: center; }
.menu-item .chev { margin-left: auto; color: #94a3b8; }

/* Toggle lista/mapa */
.btn-navy { color: #94a3b8; background: #e2e8f0; border: 0; }
.btn-navy.active { color: #fff; background: #1F2370; }
.mapa-ruta { height: 55vh; width: 100%; border-radius: 14px; overflow: hidden; position: relative; z-index: 0; }
