/* ===========================
   LUXFIELD v2 — ESTILOS
   =========================== */

:root {
  --bg: #F7F9FC;
  --bg2: #FFFFFF;
  --bg3: #EEF2F7;
  --card: #FFFFFF;
  --border: rgba(0,0,0,0.08);
  --text: #1A2535;
  --text-sub: #6B7E97;
  --accent: #0F172A;
  --accent-mid: #1E293B;
  --success: #16A34A;
  --success-light: #DCFCE7;
  --warn: #D97706;
  --danger: #DC2626;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 2px 16px rgba(0,0,0,0.08);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { height: 100%; }
body {
  height: 100%; min-height: 100vh;
  font-family: 'Inter', sans-serif;
  background: #64748B;
  color: var(--text);
  display: flex; align-items: center; justify-content: center;
}

/* ── MOBILE SHELL ── */
#app-shell {
  position: relative;
  width: 100vw; height: 100vh;
  background: var(--bg);
  overflow: hidden;
}
@media (min-width: 500px) {
  #app-shell {
    width: 390px;
    height: min(844px, 95vh);
    border-radius: 40px;
    box-shadow: 0 8px 60px rgba(0,0,0,0.35);
  }
}

/* ── SCREENS ── */
.screen {
  position: absolute; inset: 0;
  display: none; flex-direction: column;
  background: var(--bg);
  opacity: 0; transform: translateX(30px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}
.screen.active { display: flex; opacity: 1; transform: translateX(0); }

/* ── LOGIN ── */
#screen-login { justify-content: flex-end; overflow: hidden; }
.login-bg { position: absolute; inset: 0; background: linear-gradient(145deg, #E2E8F0 0%, #F7F9FC 50%, #EFF6FF 100%); }
.login-orb { position: absolute; border-radius: 50%; filter: blur(80px); opacity: 0.4; }
.orb1 { width: 300px; height: 300px; background: radial-gradient(circle, #94A3B8 0%, transparent 70%); top: -80px; right: -60px; }
.orb2 { width: 250px; height: 250px; background: radial-gradient(circle, #BAE6FD 0%, transparent 70%); bottom: 200px; left: -80px; }
.login-content {
  position: relative; z-index: 2;
  padding: 32px 24px 40px;
  background: linear-gradient(to top, var(--bg2) 70%, transparent 100%);
}
.login-logo { display: flex; align-items: center; gap: 12px; margin-bottom: 28px; }
.logo-text { font-family: 'Plus Jakarta Sans', sans-serif; font-size: 26px; font-weight: 800; letter-spacing: -0.5px; color: var(--text); }
.login-title { font-family: 'Plus Jakarta Sans', sans-serif; font-size: 28px; font-weight: 700; line-height: 1.25; margin-bottom: 8px; letter-spacing: -0.4px; }
.login-sub { color: var(--text-sub); font-size: 14px; line-height: 1.6; margin-bottom: 28px; }
.login-form { display: flex; flex-direction: column; gap: 14px; }
.login-error {
  background: #FEE2E2; color: var(--danger);
  border: 1px solid rgba(220,38,38,0.2);
  border-radius: var(--radius-sm);
  padding: 10px 14px; font-size: 13px; display: none;
}

/* ── HEADER ── */
.app-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px 14px;
  background: var(--bg2);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.app-header.inner { padding: 16px 16px 14px; }
.header-left { display: flex; align-items: center; gap: 12px; }
.avatar {
  width: 40px; height: 40px;
  background: var(--accent); color: #fff;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 14px;
}
.header-name { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 15px; }
.header-sub { font-size: 12px; color: var(--text-sub); margin-top: 1px; }
.header-title { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 16px; }
.header-title-big { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 800; font-size: 22px; }
.sync-badge {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 12px;
  background: var(--bg3); border: 1px solid var(--border);
  border-radius: 20px; font-size: 12px; font-weight: 500; color: var(--text-sub);
  cursor: pointer; transition: all 0.2s;
}
.sync-badge.online { color: var(--success); border-color: rgba(22,163,74,0.3); background: var(--success-light); }
.sync-dot { width: 7px; height: 7px; background: var(--text-sub); border-radius: 50%; }
.sync-badge.online .sync-dot { background: var(--success); animation: pulse 2s infinite; }
.back-btn, .icon-btn {
  background: none; border: none; color: var(--text);
  padding: 8px; cursor: pointer; border-radius: 8px;
  display: flex; align-items: center; transition: background 0.2s;
}
.back-btn:hover, .icon-btn:hover { background: var(--bg3); }

/* ── HOME BODY ── */
.home-body { flex: 1; overflow-y: auto; padding: 16px 20px 90px; }
.date-strip {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 14px; font-size: 13px; color: var(--text-sub); font-weight: 500;
}
.orders-count { background: var(--bg3); padding: 4px 10px; border-radius: 20px; font-size: 12px; }

/* ── JORNADA CARD ── */
.jornada-card {
  background: linear-gradient(135deg, #0F172A 0%, #1E3A5F 100%);
  border-radius: var(--radius); padding: 16px 18px; margin-bottom: 18px; color: #fff;
}
.jornada-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 12px; }
.jornada-title { font-size: 10px; text-transform: uppercase; letter-spacing: 0.1em; opacity: 0.55; }
.jornada-frente { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 13px; text-align: right; max-width: 65%; color: #7DD3FC; }
.jornada-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.jornada-item { display: flex; flex-direction: column; gap: 2px; }
.ji-label { font-size: 10px; opacity: 0.5; text-transform: uppercase; letter-spacing: 0.06em; }
.ji-val { font-size: 13px; font-weight: 500; }

/* ── STATS ── */
.stats-row { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; margin-bottom: 20px; }
.stat-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 14px 12px; text-align: center; box-shadow: var(--shadow);
}
.stat-card.accent { border-color: rgba(15,23,42,0.15); background: #F1F5F9; }
.stat-card.warn   { border-color: rgba(220,38,38,0.15); background: #FEF2F2; }
.stat-num { font-family: 'Plus Jakarta Sans', sans-serif; font-size: 28px; font-weight: 800; line-height: 1; }
.stat-card.accent .stat-num { color: var(--accent); }
.stat-card.warn   .stat-num { color: var(--danger); }
.stat-label { font-size: 11px; color: var(--text-sub); margin-top: 4px; }

/* ── SECTION TITLE ── */
.section-title {
  font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 13px;
  color: var(--text-sub); text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 10px;
}

/* ── REPORT CARDS ── */
.orders-list { display: flex; flex-direction: column; gap: 10px; }
.order-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 16px;
  cursor: pointer; transition: all 0.2s;
  display: flex; gap: 14px; align-items: flex-start;
  animation: slideUp 0.3s ease both; box-shadow: var(--shadow);
}
.order-card:hover { border-color: rgba(15,23,42,0.25); box-shadow: 0 4px 20px rgba(0,0,0,0.1); }
.order-card.completado { border-left: 3px solid var(--success); }
.order-card.parcial    { border-left: 3px solid var(--warn); }
.order-card.pendiente  { border-left: 3px solid var(--danger); }
.order-icon { width: 42px; height: 42px; border-radius: 12px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 18px; background: #F1F5F9; }
.order-info { flex: 1; min-width: 0; }
.order-type { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 14px; margin-bottom: 2px; }
.order-address { font-size: 12px; color: var(--text-sub); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.order-time { font-size: 11px; color: var(--text-sub); margin-top: 4px; }
.order-status {
  font-size: 10px; font-weight: 600; padding: 3px 8px;
  border-radius: 20px; text-transform: uppercase; letter-spacing: 0.05em; flex-shrink: 0;
}
.order-status.completado { background: #DCFCE7; color: var(--success); }
.order-status.parcial    { background: #FEF3C7; color: var(--warn); }
.order-status.pendiente  { background: #FEE2E2; color: var(--danger); }
.order-status.sin-sync   { background: #F3F4F6; color: #6B7280; }
.empty-state { text-align: center; padding: 48px 24px; color: var(--text-sub); }
.empty-state svg { opacity: 0.3; margin-bottom: 12px; }
.empty-state p { font-size: 14px; line-height: 1.6; }

/* ── FAB ── */
.fab {
  position: absolute; bottom: 82px; right: 20px;
  width: 56px; height: 56px;
  background: var(--success); color: #fff;
  border: none; border-radius: 18px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; box-shadow: 0 4px 20px rgba(22,163,74,0.35);
  transition: all 0.2s; z-index: 10;
}
.fab:hover  { transform: scale(1.05); }
.fab:active { transform: scale(0.95); }

/* ── BOTTOM NAV ── */
.bottom-nav {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: var(--bg2); border-top: 1px solid var(--border);
  display: flex; padding: 8px 0 20px; z-index: 5;
  box-shadow: 0 -2px 12px rgba(0,0,0,0.06);
}
.nav-btn {
  flex: 1; background: none; border: none; color: var(--text-sub);
  font-size: 11px; font-family: 'Inter', sans-serif;
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  cursor: pointer; padding: 6px 0; transition: color 0.2s;
}
.nav-btn.active { color: var(--accent); }
.nav-btn svg { stroke: currentColor; }

/* ── FORMS ── */
.form-body { flex: 1; overflow-y: auto; padding: 16px 20px 40px; display: flex; flex-direction: column; gap: 4px; }
.form-section {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 18px; margin-bottom: 12px;
  display: flex; flex-direction: column; gap: 14px;
}
.form-section-title {
  font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 13px;
  color: var(--text-sub); text-transform: uppercase; letter-spacing: 0.08em;
}
.input-group { display: flex; flex-direction: column; gap: 6px; }
.input-group label { font-size: 13px; color: var(--text-sub); font-weight: 500; }
.input-group input,
.input-group textarea,
.input-group select {
  background: var(--bg3); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); color: var(--text);
  font-family: 'Inter', sans-serif; font-size: 14px;
  padding: 12px 14px; width: 100%; transition: border-color 0.2s; -webkit-appearance: none;
}
.input-group input:focus,
.input-group textarea:focus,
.input-group select:focus { outline: none; border-color: var(--accent); background: #fff; }
.input-group textarea { resize: none; }

/* ── REGLA INFO ── */
.regla-info {
  background: #F0F9FF; border: 1px solid rgba(15,23,42,0.12);
  border-radius: var(--radius-sm); padding: 14px;
  flex-direction: column; gap: 8px; display: none;
}
.ri-row { display: flex; gap: 8px; align-items: baseline; }
.ri-label { font-size: 11px; color: var(--text-sub); text-transform: uppercase; letter-spacing: 0.06em; min-width: 72px; flex-shrink: 0; }
.ri-val { font-size: 13px; font-weight: 600; color: var(--accent); line-height: 1.4; }

/* ── CHECKLIST ── */
.checklist-items { display: flex; flex-direction: column; gap: 8px; }
.checklist-item {
  display: flex; align-items: flex-start; gap: 10px;
  cursor: pointer; padding: 10px 12px;
  background: var(--bg3); border-radius: var(--radius-sm);
  border: 1.5px solid var(--border); transition: all 0.2s;
}
.checklist-item:has(input:checked) { background: var(--success-light); border-color: rgba(22,163,74,0.3); }
.checklist-item input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--success); flex-shrink: 0; margin-top: 1px; }
.checklist-item span { font-size: 13px; line-height: 1.45; }

/* ── 4 FOTOS ── */
.photos-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.photo-slot {
  aspect-ratio: 1; border-radius: var(--radius-sm); overflow: hidden;
  cursor: pointer; border: 1.5px dashed var(--border);
  background: var(--bg3); transition: all 0.2s;
  display: flex; align-items: center; justify-content: center;
}
.photo-slot:hover { border-color: var(--accent); }
.photo-slot-inner {
  width: 100%; height: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 6px; color: var(--text-sub); font-size: 12px; padding: 12px;
}
.photo-slot-label { font-size: 11px; font-weight: 500; text-transform: uppercase; letter-spacing: 0.06em; }

/* ── GPS ── */
.gps-result {
  font-size: 12px; color: var(--success);
  background: rgba(22,163,74,0.08); border: 1px solid rgba(22,163,74,0.2);
  border-radius: var(--radius-sm); padding: 10px 12px; line-height: 1.5;
}

/* ── BUTTONS ── */
.btn-primary {
  background: var(--accent); color: #fff; border: none;
  border-radius: var(--radius-sm);
  font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 15px;
  padding: 15px; width: 100%; cursor: pointer; transition: all 0.2s;
  box-shadow: 0 2px 12px rgba(15,23,42,0.25);
}
.btn-primary:hover  { background: var(--accent-mid); }
.btn-primary:active { transform: scale(0.98); }
.btn-primary:disabled { opacity: 0.6; cursor: not-allowed; }
.btn-secondary {
  background: var(--bg3); color: var(--text);
  border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif; font-size: 13px; font-weight: 500;
  padding: 11px 14px; width: 100%; cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  transition: all 0.2s;
}
.btn-secondary:hover { border-color: var(--success); color: var(--success); background: var(--success-light); }
.btn-secondary.danger { color: var(--danger); border-color: rgba(220,38,38,0.3); }
.btn-secondary.danger:hover { background: #FEE2E2; }

/* ── DETAIL ── */
.detail-body { flex: 1; overflow-y: auto; padding: 16px 20px 40px; }
.detail-hero {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 20px; margin-bottom: 12px;
}
.detail-type-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.detail-type { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 800; font-size: 20px; }
.detail-section {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 18px; margin-bottom: 12px;
}
.detail-label { font-size: 11px; color: var(--text-sub); text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 4px; }
.detail-val { font-size: 14px; line-height: 1.5; }

/* ── HISTORY ── */
.history-body { flex: 1; overflow-y: auto; padding: 0 20px 90px; }

/* ── PROFILE ── */
.profile-body { flex: 1; overflow-y: auto; padding: 20px 20px 90px; display: flex; flex-direction: column; gap: 16px; }
.profile-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 28px 20px;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
}
.profile-avatar {
  width: 72px; height: 72px; background: var(--accent); color: #fff;
  border-radius: 22px; display: flex; align-items: center; justify-content: center;
  font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 800; font-size: 24px; margin-bottom: 4px;
}
.profile-name { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 20px; }
.profile-id { font-size: 13px; color: var(--text-sub); }
.profile-stats { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; }
.pstat { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 14px; text-align: center; }
.pstat-num { font-family: 'Plus Jakarta Sans', sans-serif; font-size: 26px; font-weight: 800; color: var(--accent); }
.pstat-label { font-size: 11px; color: var(--text-sub); margin-top: 2px; }
.profile-info-section { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.pinfo-row { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--border); font-size: 13px; }
.pinfo-row:last-child { border-bottom: none; }
.pinfo-label { color: var(--text-sub); }
.pinfo-val { font-weight: 500; }

/* ── TOAST ── */
.toast {
  position: absolute; bottom: 90px; left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--text); color: #fff;
  padding: 12px 20px; border-radius: 30px;
  font-size: 13px; font-weight: 500;
  opacity: 0; transition: all 0.3s;
  pointer-events: none; z-index: 999; white-space: nowrap; box-shadow: var(--shadow);
}
.toast.show    { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast.success { background: var(--success); }
.toast.error   { background: var(--danger); }
.toast.warn    { background: var(--warn); color: #1a1a1a; }

/* ── ANIMACIONES ── */
@keyframes slideUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.4; }
}

::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--bg3); border-radius: 4px; }

/* ══════════════════════════════════════════
   PANEL PRINCIPAL — Home redesign
══════════════════════════════════════════ */
.panel-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px 12px;
  background: var(--bg2); border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.panel-title { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 800; font-size: 17px; }
.gps-badge {
  font-size: 11px; font-weight: 600; padding: 5px 10px;
  background: var(--bg3); border: 1px solid var(--border);
  border-radius: 20px; cursor: pointer; transition: color .2s;
}
.avatar.sm { width: 34px; height: 34px; border-radius: 10px; font-size: 12px; }

.home-scroll { flex: 1; overflow-y: auto; padding: 14px 14px 90px; display: flex; flex-direction: column; gap: 12px; }

/* Welcome card */
.welcome-card {
  background: linear-gradient(135deg, #0F172A 0%, #1E3A5F 100%);
  border-radius: var(--radius); padding: 16px 18px; color: #fff;
}
.wc-name { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 800; font-size: 18px; margin-bottom: 4px; }
.wc-loc  { font-size: 12px; opacity: .65; }

/* GPS warn */
.gps-warn-card {
  background: #FFFBEB; border: 1px solid rgba(217,119,6,.3);
  border-radius: var(--radius); padding: 14px 16px;
  display: flex; align-items: center; gap: 12px;
}
.btn-activar {
  background: var(--warn); color: #fff; border: none;
  border-radius: 10px; padding: 8px 18px;
  font-weight: 700; font-size: 13px; cursor: pointer; flex-shrink: 0;
}

/* Action cards */
.action-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.action-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 18px 14px;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  cursor: pointer; transition: all .2s; box-shadow: var(--shadow);
  position: relative; text-align: center;
}
.action-card:active { transform: scale(.97); }
.action-card.full { display: flex; flex-direction: row; justify-content: center; gap: 16px; }
.action-icon { font-size: 2rem; }
.action-title { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 800; font-size: 13px; letter-spacing: .02em; }
.action-sub   { font-size: 11px; color: var(--text-sub); }
.sync-card    { background: linear-gradient(135deg,#DCFCE7,#BBF7D0); border-color: rgba(22,163,74,.25); }
.action-badge {
  position: absolute; top: 8px; right: 8px;
  background: var(--danger); color: #fff;
  font-size: 10px; font-weight: 700;
  min-width: 20px; height: 20px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center; padding: 0 5px;
}

/* Stats */
.home-stats { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; }
.hstat { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 14px; text-align: center; box-shadow: var(--shadow); }
.hstat-num { font-family: 'Plus Jakarta Sans', sans-serif; font-size: 28px; font-weight: 800; }
.hstat-lbl { font-size: 11px; color: var(--text-sub); margin-top: 4px; }
.hstat.danger .hstat-num { color: var(--danger); }

/* Emergencia */
.btn-emergencia {
  background: var(--danger); color: #fff; border: none;
  border-radius: var(--radius-sm); padding: 16px;
  font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 800; font-size: 16px;
  width: 100%; cursor: pointer; letter-spacing: .05em;
  box-shadow: 0 4px 16px rgba(220,38,38,.35); transition: all .2s;
}
.btn-emergencia:active { transform: scale(.98); }

/* Nav badge */
.nav-badge {
  position: absolute; top: 4px; right: 18px;
  background: var(--danger); color: #fff;
  font-size: 9px; font-weight: 700;
  min-width: 16px; height: 16px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center; padding: 0 4px;
}
.nav-btn { position: relative; }

/* ══════════════════════════════════════════
   SCREEN TRABAJAR — flujo multi-paso
══════════════════════════════════════════ */
.scr-trabajar-body { flex: 1; overflow-y: auto; }

/* Paso 0 — alerta roja GPS lock */
.alerta-roja {
  min-height: 100%; background: linear-gradient(160deg,#7f1d1d 0%,#991b1b 100%);
  color: #fff; padding: 30px 20px 40px;
  display: flex; flex-direction: column; align-items: center;
}
.alerta-roja h1 { font-size: 1.15rem; font-weight: 800; text-align: center; line-height: 1.35; }

.gps-lock-box {
  background: rgba(0,0,0,.3); border: 1px solid rgba(255,255,255,.15);
  border-radius: 16px; padding: 18px 20px; width: 100%;
  margin: 20px 0; text-align: center;
}
.gps-coords { font-family: monospace; font-size: 1rem; font-weight: 700; color: #fbbf24; }
.gps-accuracy-bar { display: flex; justify-content: center; gap: 8px; margin-top: 12px; }
.gps-acc-dot { width: 16px; height: 16px; border-radius: 50%; background: rgba(255,255,255,.2); transition: background .4s; }
.gps-acc-dot.active-green  { background: #4ade80; box-shadow: 0 0 8px #4ade80; }
.gps-acc-dot.active-yellow { background: #fbbf24; box-shadow: 0 0 8px #fbbf24; }
.gps-acc-dot.active-red    { background: #f87171; box-shadow: 0 0 8px #f87171; }

/* Flow header */
.flow-header {
  display: flex; justify-content: space-between; align-items: flex-start;
  padding: 16px 16px 12px;
  background: var(--bg2); border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.flow-step-label { font-size: .7rem; color: var(--text-sub); font-weight: 600; letter-spacing: 1px; text-transform: uppercase; }
.flow-title { font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 800; font-size: 18px; margin-top: 2px; }
.step-indicator { display: flex; gap: 6px; align-items: center; padding-top: 6px; }
.step-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--bg3); border: 1.5px solid var(--border); }
.step-dot.done   { background: var(--accent); border-color: var(--accent); }
.step-dot.active { background: var(--success); border-color: var(--success); box-shadow: 0 0 0 3px rgba(22,163,74,.2); }

/* Info box GPS */
.info-box {
  background: #F0F9FF; border: 1px solid rgba(37,99,235,.15);
  border-radius: var(--radius-sm); padding: 12px 14px;
  display: flex; flex-direction: column; gap: 6px; margin: 14px 0;
}
.info-box-row { display: flex; gap: 10px; align-items: baseline; }
.ib-label     { font-size: 11px; color: var(--text-sub); min-width: 72px; }
.coords-text  { font-family: monospace; font-size: 12px; color: var(--accent); font-weight: 600; }

/* Campos del formulario dentro del flujo */
.field-label {
  font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 11px;
  color: var(--text-sub); text-transform: uppercase; letter-spacing: .08em;
  margin: 14px 0 6px;
}
.field-label:first-of-type { margin-top: 0; }
.req { color: var(--danger); }
.field-input {
  display: block; width: 100%;
  background: var(--bg3); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); color: var(--text);
  font-family: 'Inter', sans-serif; font-size: 14px;
  padding: 12px 14px; transition: border-color .2s; -webkit-appearance: none;
  margin-bottom: 0;
}
.field-input:focus { outline: none; border-color: var(--accent); background: #fff; }
textarea.field-input { resize: none; }

/* Partida cascada */
.partida-box-wrap {
  background: rgba(37,99,235,.05); border: 1px solid rgba(37,99,235,.18);
  border-radius: var(--radius-sm); padding: 14px 14px 16px;
  margin: 10px 0 4px;
}
.partida-titulo {
  font-size: .72rem; font-weight: 700; color: #1d4ed8;
  letter-spacing: 1px; text-transform: uppercase; margin-bottom: 12px;
}
.partida-resumen {
  background: rgba(37,99,235,.06); border: 1px solid rgba(37,99,235,.2);
  border-radius: var(--radius-sm); padding: 12px 16px; margin-bottom: 16px;
  display: flex; gap: 12px; align-items: center;
}

/* Foto box (pantalla completa, tappable) */
.photo-box {
  width: 100%; aspect-ratio: 4/3; border-radius: var(--radius-sm);
  border: 2px dashed var(--border); background: var(--bg3);
  cursor: pointer; overflow: hidden; transition: border-color .2s;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 4px;
}
.photo-box:hover { border-color: var(--accent); }
.photo-box-inner { display: flex; flex-direction: column; align-items: center; justify-content: center; }

/* Checklist */
.checklist-wrap { background: var(--bg3); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 4px 14px; margin-bottom: 4px; }
.checklist-item { display: flex; align-items: flex-start; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.checklist-item:last-child { border-bottom: none; }
.checklist-cb {
  width: 22px; height: 22px; border-radius: 6px; flex-shrink: 0;
  border: 2px solid var(--border); background: #fff;
  cursor: pointer; transition: all .2s; margin-top: 1px;
  display: flex; align-items: center; justify-content: center;
}
.checklist-cb.checked { background: var(--success); border-color: var(--success); }
.checklist-cb.checked::after { content: '✓'; color: #fff; font-size: 13px; font-weight: 700; }
.checklist-label { font-size: 13px; line-height: 1.45; }

/* Voz */
.voice-row { display: flex; gap: 10px; align-items: flex-start; }
.voice-row .field-input { flex: 1; }
.voice-btn {
  width: 52px; height: 52px; flex-shrink: 0; border-radius: 14px;
  background: var(--bg3); border: 1.5px solid var(--border);
  font-size: 1.4rem; cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: all .2s;
}
.voice-btn.recording { background: var(--danger); border-color: var(--danger); animation: pulse 1s infinite; }
.voice-hint { font-size: 11px; color: var(--text-sub); margin-top: 4px; }

/* Error */
.error-msg {
  background: #FEE2E2; color: var(--danger);
  border: 1px solid rgba(220,38,38,.2); border-radius: var(--radius-sm);
  padding: 10px 14px; font-size: 13px; display: none; margin-top: 8px;
}

/* Botones del flujo */
.btn {
  display: block; width: 100%; padding: 14px;
  border: none; border-radius: var(--radius-sm);
  font-family: 'Plus Jakarta Sans', sans-serif; font-weight: 700; font-size: 15px;
  cursor: pointer; transition: all .2s; text-align: center;
}
.btn-white  { background: #fff; color: #991b1b; }
.btn-ghost-red { background: rgba(255,255,255,.1); color: #fca5a5; }
.btn-ghost  { background: var(--bg3); color: var(--text-sub); border: 1.5px solid var(--border); }
.btn-success { background: var(--success); color: #fff; box-shadow: 0 2px 12px rgba(22,163,74,.3); }
.btn-success:active { transform: scale(.98); }
.mt16 { margin-top: 16px; }
.mt8  { margin-top: 8px; }
