/* PuntoVigía GT · app de campo (mobile-first) */
:root {
  --ink: #10151c;
  --muted: #5b6674;
  --line: #e3e8ef;
  --bg: #f4f6f9;
  --card: #ffffff;
  --brand: #f59e0b;
  --brand-dark: #b45309;
  --ok: #16a34a;
  --bad: #dc2626;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(16,21,28,.06), 0 8px 24px rgba(16,21,28,.07);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html, body { width: 100%; max-width: 100%; overflow-x: hidden; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: "Segoe UI", system-ui, -apple-system, sans-serif;
  background: var(--bg); color: var(--ink); min-height: 100dvh;
}
button { font-family: inherit; }

/* ---------- top bar ---------- */
.top {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: calc(10px + env(safe-area-inset-top)) 14px 10px;
  background: linear-gradient(150deg, #12161d, #0c0f14);
  border-bottom: 3px solid var(--brand);
}
.brand { display: flex; align-items: center; gap: 10px; color: #fff; }
.brand svg, .brand img { width: 38px; height: 38px; flex: 0 0 auto; }
.brand b { font-size: 17px; letter-spacing: .35px; font-weight: 800; display: block; line-height: 1; white-space: nowrap; }
.brand b i { color: var(--brand); font-style: normal; }
.brand span { font-size: 10.5px; color: #9aa6b5; letter-spacing: 1px; text-transform: uppercase; }
.top-right { display: flex; align-items: center; gap: 8px; }
.pill {
  background: rgba(255,255,255,.09); color: #dfe6ee; border: 1px solid rgba(255,255,255,.14);
  padding: 5px 10px; border-radius: 999px; font-size: 12px; white-space: nowrap;
}
.pill b { color: var(--brand); }
.icon-btn {
  background: rgba(255,255,255,.09); color: #dfe6ee; border: 1px solid rgba(255,255,255,.14);
  width: 34px; height: 34px; border-radius: 10px; font-size: 15px; cursor: pointer;
}

/* ---------- screens ---------- */
.screen { max-width: 560px; margin: 0 auto; padding: 16px 14px calc(30px + env(safe-area-inset-bottom)); }
.hero { text-align: center; padding: 8px 0 4px; }
.hola { color: var(--muted); margin-bottom: 12px; font-size: 15px; }
.hola b { color: var(--ink); }
.big-cta {
  display: flex; align-items: center; gap: 14px; width: 100%;
  background: linear-gradient(135deg, #f59e0b, #d97706); color: #1a1206;
  border: 0; border-radius: 18px; padding: 18px; cursor: pointer; text-align: left;
  box-shadow: 0 14px 34px rgba(245,158,11,.35);
}
.big-cta:active { transform: scale(.99); }
.big-cta.no-surveys { filter: saturate(.55); }
.cta-ic {
  width: 46px; height: 46px; border-radius: 14px; background: rgba(0,0,0,.18);
  display: grid; place-items: center; font-size: 19px; flex: 0 0 auto;
}
.big-cta b { display: block; font-size: 19px; }
.big-cta small { font-size: 12.5px; opacity: .8; }
.cta-copy { min-width: 0; }
.cta-copy b, .cta-copy small { overflow: hidden; text-overflow: ellipsis; }
.net-chip { margin-top: 12px; display: inline-block; font-size: 12px; color: var(--ok); }
.net-chip.off { color: var(--bad); }
.guide-link {
  display: block; margin: 13px auto 0; border: 0; background: transparent; color: var(--brand-dark);
  font: inherit; font-size: 13px; font-weight: 800; cursor: pointer; text-decoration: underline; text-underline-offset: 3px;
}
.guide-link:focus-visible { outline: 3px solid rgba(245,158,11,.3); outline-offset: 4px; border-radius: 4px; }

.journey-card {
  margin-top: 16px; padding: 16px; text-align: left; border-radius: 18px;
  color: #e8eef6; background: radial-gradient(circle at 92% 8%, rgba(56,189,248,.2), transparent 35%), linear-gradient(145deg, #151b25, #0d1117);
  border: 1px solid rgba(255,255,255,.1); box-shadow: 0 12px 30px rgba(15,23,42,.18);
}
.journey-card.active { border-color: rgba(52,211,153,.65); box-shadow: 0 12px 34px rgba(16,185,129,.15); }
.journey-card.paused { border-color: rgba(251,191,36,.7); box-shadow: 0 12px 34px rgba(245,158,11,.15); }
.journey-card.completed { border-color: rgba(125,211,252,.42); }
.journey-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.journey-kicker { color: #7dd3fc; font-size: 10px; font-weight: 900; letter-spacing: 1.4px; text-transform: uppercase; }
.journey-card h2 { margin-top: 3px; font-size: 17px; }
.journey-card p { color: #aeb9c7; font-size: 12.5px; line-height: 1.45; margin-top: 9px; }
.journey-status { flex: 0 0 auto; padding: 5px 9px; border-radius: 999px; color: #cbd5e1; background: rgba(255,255,255,.08); font-size: 10.5px; font-weight: 800; }
.journey-card.active .journey-status { color: #6ee7b7; background: rgba(16,185,129,.14); }
.journey-card.paused .journey-status { color: #fde68a; background: rgba(245,158,11,.16); }
.journey-stats { display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; margin-top: 13px; }
.journey-stats span { padding: 9px; text-align: center; border-radius: 11px; background: rgba(255,255,255,.06); }
.journey-stats b, .journey-stats small { display: block; }
.journey-stats b { font-size: 14px; color: #fff; }
.journey-stats small { margin-top: 2px; color: #8f9baa; font-size: 9.5px; text-transform: uppercase; letter-spacing: .7px; }
.journey-tracker {
  position: relative; height: 252px; margin-top: 13px; overflow: hidden;
  border: 1px solid rgba(255,255,255,.13); border-radius: 15px; background: #121923;
}
.journey-map { position: absolute; inset: 0 0 37px; z-index: 1; background: #16202b; }
.journey-map::after {
  content: ""; position: absolute; inset: 0; z-index: 500; pointer-events: none;
  box-shadow: inset 0 0 34px rgba(3,7,18,.24);
}
.journey-map-empty {
  position: absolute; inset: 0 0 37px; z-index: 520; display: grid; place-content: center;
  justify-items: center; gap: 3px; padding: 18px; text-align: center; pointer-events: none;
  background: radial-gradient(circle at center, rgba(30,41,59,.72), rgba(15,23,42,.92));
}
.journey-map-empty[hidden] { display: none; }
.journey-map-empty > span { font-size: 29px; color: #38bdf8; }
.journey-map-empty b { color: #f8fafc; font-size: 12.5px; }
.journey-map-empty small { color: #94a3b8; font-size: 10.5px; }
.journey-live-badge {
  position: absolute; z-index: 600; top: 10px; left: 10px; padding: 6px 9px; border-radius: 999px;
  color: #d1fae5; background: rgba(6,78,59,.9); box-shadow: 0 4px 14px rgba(0,0,0,.25);
  font-size: 9.5px; font-weight: 950; letter-spacing: .8px;
}
.journey-card.completed .journey-live-badge { color: #dbeafe; background: rgba(30,64,175,.88); }
.journey-card.paused .journey-live-badge { color: #fef3c7; background: rgba(146,64,14,.92); }
.journey-recenter {
  position: absolute; z-index: 600; top: 10px; right: 10px; width: 38px; height: 38px;
  border: 1px solid rgba(15,23,42,.15); border-radius: 11px; color: #0f172a; background: rgba(255,255,255,.94);
  box-shadow: 0 4px 14px rgba(0,0,0,.2); font-size: 22px; font-weight: 900; cursor: pointer;
}
.journey-recenter:active { transform: scale(.96); }
.journey-map-foot {
  position: absolute; z-index: 610; inset: auto 0 0; min-height: 37px; display: flex; align-items: center;
  gap: 10px; padding: 0 10px; background: rgba(10,15,22,.96); white-space: nowrap;
}
.journey-map-foot span { display: inline-flex; align-items: center; gap: 4px; color: #aeb9c7; font-size: 9px; }
.journey-map-foot b { margin-left: auto; overflow: hidden; color: #e2e8f0; font-size: 9.5px; text-overflow: ellipsis; }
.journey-dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; }
.journey-dot.start { background: #f59e0b; }
.journey-dot.current { background: #22c55e; box-shadow: 0 0 0 3px rgba(34,197,94,.18); }
.journey-current-marker {
  width: 22px; height: 22px; border: 3px solid #fff; border-radius: 50%;
  background: #16a34a; box-shadow: 0 0 0 6px rgba(34,197,94,.25), 0 4px 13px rgba(0,0,0,.35);
}
.journey-card.active .journey-current-marker { animation: journey-pulse 1.8s ease-out infinite; }
.journey-card.paused .journey-current-marker { animation: none; background: #f59e0b; box-shadow: 0 0 0 6px rgba(245,158,11,.22), 0 4px 13px rgba(0,0,0,.35); }
@keyframes journey-pulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(34,197,94,.26), 0 4px 13px rgba(0,0,0,.35); }
  50% { box-shadow: 0 0 0 9px rgba(34,197,94,0), 0 4px 13px rgba(0,0,0,.35); }
}
.journey-start-marker {
  width: 16px; height: 16px; border: 3px solid #fff; border-radius: 50%;
  background: #f59e0b; box-shadow: 0 3px 10px rgba(0,0,0,.3);
}
.journey-tracker .leaflet-control-zoom { margin: 0 10px 47px 0; border: 0; box-shadow: 0 4px 14px rgba(0,0,0,.2); }
.journey-tracker .leaflet-control-zoom a { width: 30px; height: 30px; line-height: 30px; color: #0f172a; }
.journey-tracker .leaflet-control-attribution {
  margin-bottom: 37px !important; padding: 2px 5px !important; color: #475569; background: rgba(255,255,255,.78) !important;
  font-size: 7px !important;
}
.journey-actions { display: grid; grid-template-columns: minmax(0,.9fr) minmax(0,1.1fr); gap: 9px; margin-top: 13px; }
.journey-actions > button { min-height: 46px; margin: 0; }
.journey-pause-btn[hidden] + .journey-btn { grid-column: 1 / -1; }
.journey-btn { width: 100%; border: 0; border-radius: 12px; padding: 12px 15px; color: #07130f; background: linear-gradient(135deg,#34d399,#10b981); font: inherit; font-weight: 900; cursor: pointer; }
.journey-card.active .journey-btn { color: #fee2e2; background: rgba(239,68,68,.16); border: 1px solid rgba(248,113,113,.35); }
.journey-btn:disabled { opacity: .58; cursor: wait; }
.journey-pause-btn {
  border: 1px solid rgba(251,191,36,.42); border-radius: 12px; padding: 12px 10px;
  color: #fef3c7; background: rgba(245,158,11,.14); font: inherit; font-weight: 900; cursor: pointer;
}
.journey-pause-btn.resume { color: #d1fae5; border-color: rgba(52,211,153,.45); background: rgba(16,185,129,.18); }
.journey-pause-btn:disabled { opacity: .58; cursor: wait; }
.journey-privacy { font-size: 10.5px !important; color: #7f8b99 !important; }

.block { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px; margin-top: 16px; }
.block h2 { font-size: 14px; margin-bottom: 10px; }
.empty { color: var(--muted); font-size: 13.5px; }
.visit-row.myvisit { cursor: pointer; transition: background .12s, transform .12s; }
.visit-row.myvisit:hover { background: #fffbeb; }
.visit-row.myvisit:active { transform: scale(.995); }
.mylist .visit-row, #pendingList .visit-row {
  display: flex; justify-content: space-between; align-items: center; gap: 8px;
  border: 1px solid var(--line); border-radius: 11px; padding: 10px 12px; margin-bottom: 8px; background: #fbfcfe;
}
.visit-row .v-main { min-width: 0; }
.visit-row .v-suc { font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.visit-row .v-meta { color: var(--muted); font-size: 12px; }
.visit-row .v-survey { width: fit-content; max-width: 100%; margin: 4px 0 3px; padding: 2px 7px; border-radius: 999px; background: #fef3c7; color: #92400e; font-size: 10.5px; font-weight: 850; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.visit-row .v-tag { font-size: 11px; padding: 3px 8px; border-radius: 999px; white-space: nowrap; }
.v-tag.ok { background: #ecfdf5; color: #047857; border: 1px solid #a7f3d0; }
.v-tag.inc { background: #fef2f2; color: #b91c1c; border: 1px solid #fecaca; }
.v-tag.pend { background: #fffbeb; color: #92400e; border: 1px solid #fde68a; }
.ghost {
  background: #fff; border: 1.5px solid var(--line); color: var(--ink);
  border-radius: 11px; padding: 10px 14px; font-size: 14px; font-weight: 600; cursor: pointer;
}
.primary {
  background: linear-gradient(135deg, #f59e0b, #d97706); border: 0; color: #1a1206;
  border-radius: 11px; padding: 12px 18px; font-size: 15px; font-weight: 800; cursor: pointer;
  box-shadow: 0 6px 16px rgba(245,158,11,.3);
}
.primary:disabled, .ghost:disabled { opacity: .55; cursor: wait; }

.survey-picker { position: fixed; inset: 0; z-index: 900; display: grid; place-items: center; padding: 18px; }
.survey-picker-backdrop { position: absolute; inset: 0; background: rgba(8,12,18,.72); backdrop-filter: blur(5px); }
.survey-picker-card { position: relative; display: flex; flex-direction: column; width: min(560px,100%); max-height: 90dvh; overflow: hidden; padding: 23px 18px 18px; border-radius: 22px; background: var(--card); box-shadow: 0 24px 70px rgba(0,0,0,.32); }
.survey-picker-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin: 4px 40px 0 0; }
.survey-picker-heading h2 { margin: 0 0 5px; font-size: 22px; }
.survey-picker-heading p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.45; }
.survey-picker-count { flex: 0 0 auto; padding: 5px 9px; border: 1px solid #fde68a; border-radius: 999px; background: #fffbeb; color: #92400e; font-size: 11px; font-weight: 850; }
.survey-picker-kicker { color: var(--brand-dark); font-size: 10px; font-weight: 900; letter-spacing: 1.3px; text-transform: uppercase; }
.survey-picker-x { position: absolute; top: 13px; right: 13px; width: 36px; height: 36px; border: 1px solid var(--line); border-radius: 10px; background: #fff; font-size: 22px; cursor: pointer; }
.survey-picker-list { display: grid; gap: 10px; min-height: 0; margin-top: 17px; overflow-y: auto; overscroll-behavior: contain; padding: 2px; }
.survey-choice { width: 100%; display: grid; grid-template-columns: 46px minmax(0,1fr) 26px; align-items: center; gap: 11px; min-height: 86px; padding: 13px; border: 1.5px solid var(--line); border-radius: 15px; background: #fbfcfe; color: var(--ink); text-align: left; cursor: pointer; transition: border-color .14s, background .14s, box-shadow .14s, transform .1s; }
.survey-choice:hover { border-color: #fbbf24; background: #fffdf7; }
.survey-choice:active { transform: scale(.99); }
.survey-choice:focus-visible { outline: 3px solid rgba(245,158,11,.25); outline-offset: 2px; }
.survey-choice.selected { border-color: #d97706; background: #fffbeb; box-shadow: 0 0 0 3px rgba(245,158,11,.16); }
.survey-choice-icon { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 13px; background: #fef3c7; color: #92400e; font-size: 20px; font-weight: 950; }
.survey-choice b, .survey-choice small { display: block; }
.survey-choice b { font-size: 15px; }
.survey-choice small { margin-top: 3px; color: var(--muted); font-size: 12px; line-height: 1.35; }
.survey-choice-meta { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.survey-choice-meta em { padding: 3px 6px; border-radius: 6px; background: #eef2f7; color: #475569; font-size: 10px; font-style: normal; font-weight: 800; }
.survey-choice.selected .survey-choice-meta em { background: #fef3c7; color: #92400e; }
.survey-choice-check { display: grid; place-items: center; width: 24px; height: 24px; border: 2px solid #cbd5e1; border-radius: 999px; color: transparent; font-size: 13px; font-weight: 950; }
.survey-choice.selected .survey-choice-check { border-color: #d97706; background: #d97706; color: #fff; }
.survey-picker-confirm { flex: 0 0 auto; margin-top: 14px; padding-top: 13px; border-top: 1px solid var(--line); }
.survey-picker-selected { display: block; min-height: 18px; margin-bottom: 9px; color: var(--muted); font-size: 12px; }
.survey-picker-selected b { color: var(--ink); }
.survey-picker-start { width: 100%; min-height: 50px; }
.survey-picker-start:disabled { box-shadow: none; }
#dynamicWizard .icon-btn { background: #fff; color: var(--ink); border: 1.5px solid var(--line); }
.dynamic-step-head { padding-bottom: 13px; margin-bottom: 15px; border-bottom: 1px solid var(--line); }
.dynamic-step-head span { color: var(--brand-dark); font-size: 10px; font-weight: 900; letter-spacing: 1.2px; text-transform: uppercase; }
.dynamic-step-head h1 { margin-top: 3px; }
.dynamic-required { color: #b45309; }
.dynamic-choice { display: grid; gap: 8px; }
.dynamic-choice label { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 11px 12px; border: 1.5px solid var(--line); border-radius: 11px; background: #fbfcfe; font-size: 14px; font-weight: 650; }
.dynamic-choice input { width: 19px; height: 19px; accent-color: var(--brand); }
.dynamic-photo-optional { font-size: 10.5px; color: var(--muted); font-weight: 700; }
.dynamic-summary { display: grid; gap: 7px; padding: 13px; border-radius: 12px; background: #f8fafc; color: var(--muted); font-size: 13px; }
.dynamic-summary b { color: var(--ink); }

/* ---------- wizard ---------- */
.wiz-head {
  display: flex; align-items: center; gap: 12px; margin-bottom: 14px;
  position: sticky; top: calc(57px + env(safe-area-inset-top)); background: var(--bg); padding: 8px 0; z-index: 20;
}
#wizard .icon-btn { background: #fff; color: var(--ink); border: 1.5px solid var(--line); }
.wiz-progress { flex: 1; height: 8px; background: #e6ebf2; border-radius: 999px; overflow: hidden; }
.wiz-bar { height: 100%; width: 14%; background: linear-gradient(90deg, #f59e0b, #d97706); border-radius: 999px; transition: width .3s; }
.wiz-step-label { font-size: 12px; color: var(--muted); white-space: nowrap; }

.step { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 16px; }
.step h1 { font-size: 20px; margin-bottom: 4px; }
.hint { color: var(--muted); font-size: 13.5px; margin-bottom: 16px; }
.sub { font-weight: 800; font-size: 13px; color: var(--brand-dark); text-transform: uppercase; letter-spacing: .6px; margin: 14px 0 8px; }

.field { margin-bottom: 13px; }
.field label, .field-label { display: block; font-size: 12.5px; font-weight: 700; color: var(--muted); margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%; padding: 12px; font-size: 16px; border: 1.5px solid #dde3ea; border-radius: 11px;
  background: #fbfcfe; outline: none; color: var(--ink);
}
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(245,158,11,.15); }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.gps-chip {
  display: flex; align-items: center; padding: 12px; font-size: 13.5px;
  border: 1.5px dashed #dde3ea; border-radius: 11px; color: var(--muted); background: #fbfcfe; min-height: 47px;
}
.gps-chip.ok { border-style: solid; border-color: #a7f3d0; background: #ecfdf5; color: #047857; }

/* radio cards (permiso) */
.radio-cards { display: grid; gap: 10px; }
.radio-card {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left;
  border: 2px solid var(--line); background: #fbfcfe; border-radius: 13px; padding: 14px; cursor: pointer; font-size: 15px;
}
.radio-card .rc-ic { font-size: 22px; }
.radio-card b { display: block; font-size: 15px; }
.radio-card small { color: var(--muted); font-size: 12.5px; }
.radio-card.on { border-color: var(--brand); background: #fffbeb; box-shadow: 0 0 0 3px rgba(245,158,11,.12); }
.note { background: #fffbeb; border: 1px solid #fde68a; color: #92400e; border-radius: 10px; padding: 10px 12px; font-size: 13.5px; }

.material-flow { border: 1px solid var(--line); border-radius: 14px; padding: 13px; background: #fbfcfe; }
.flow-tip { margin: 2px 0 12px; padding: 9px 11px; border-left: 3px solid var(--brand); border-radius: 8px; background: #fffbeb; color: #78520b; font-size: 13px; line-height: 1.4; }
.selfie-slot { border-color: #f6c35b; background: #fffaf0; }

/* segmented sí/no */
.seg { display: flex; gap: 8px; flex-wrap: wrap; }
.seg button {
  flex: 1; min-width: 84px; padding: 12px 10px; border: 2px solid var(--line); border-radius: 11px;
  background: #fbfcfe; font-size: 14.5px; font-weight: 700; color: var(--muted); cursor: pointer;
}
.seg button.on { border-color: var(--brand); background: #fffbeb; color: var(--brand-dark); }

/* counters */
.counter { display: flex; align-items: center; justify-content: space-between; gap: 10px; border: 1.5px solid var(--line); border-radius: 12px; padding: 10px 12px; margin-bottom: 10px; background: #fbfcfe; }
.c-name { font-size: 14.5px; font-weight: 600; }
.c-ctrl { display: flex; align-items: center; gap: 6px; }
.c-ctrl button {
  width: 42px; height: 42px; border-radius: 11px; border: 1.5px solid var(--line); background: #fff;
  font-size: 20px; font-weight: 800; color: var(--brand-dark); cursor: pointer;
}
.c-ctrl input { width: 74px; text-align: center; font-size: 17px; font-weight: 700; padding: 9px 4px; border: 1.5px solid #dde3ea; border-radius: 10px; background: #fff; }
.total-line { font-size: 14px; color: var(--muted); margin: 4px 0 12px; }
.total-line b { color: var(--ink); font-size: 16px; }

/* foto slots */
.foto-slot { border: 1.5px dashed #d3dae3; border-radius: 13px; padding: 12px; margin-bottom: 12px; background: #fbfcfe; }
.foto-slot label { display: block; font-size: 13px; font-weight: 700; color: var(--muted); margin-bottom: 8px; }
.foto-slot label b { color: var(--brand-dark); }
.foto-btn {
  width: 100%; padding: 12px; border: 0; border-radius: 10px; background: #12161d; color: #fff;
  font-size: 14.5px; font-weight: 700; cursor: pointer;
}
.foto-actions { display: grid; gap: 8px; }
.foto-slot.done .foto-actions { grid-template-columns: minmax(0, 1fr) auto; }
.foto-delete {
  min-height: 44px; padding: 10px 13px; border: 1.5px solid #fecaca; border-radius: 10px;
  background: #fff; color: #b91c1c; font-size: 13.5px; font-weight: 800; cursor: pointer;
}
.foto-delete[hidden] { display: none; }
.foto-delete:hover, .foto-delete:focus-visible { border-color: #ef4444; background: #fff1f2; }
.foto-slot.done { border-style: solid; border-color: #a7f3d0; background: #f0fdf4; }
.foto-slot.done .foto-btn { background: #065f46; }
.foto-prev { width: 100%; max-height: 200px; object-fit: cover; border-radius: 10px; margin-top: 10px; }
/* justificación de foto no tomada */
.foto-skip { display: block; margin-top: 8px; background: none; border: 0; padding: 4px 0; color: var(--muted); font-size: 13px; text-decoration: underline; cursor: pointer; }
.foto-slot.done .foto-skip, .foto-slot.done .foto-motivo { display: none; }
.foto-motivo { margin-top: 6px; }
.foto-motivo label { font-size: 12.5px; margin-bottom: 4px; }
.foto-motivo-input { width: 100%; padding: 11px 12px; border: 1.5px solid #f2c94c; border-radius: 10px; background: #fffdf3; font-size: 14px; }
.foto-slot:has(.foto-motivo:not([hidden])) { border-color: #f2c94c; background: #fffcf0; }
@media (max-width: 420px) {
  .top { gap: 6px; padding-inline: 10px; }
  .brand { gap: 7px; }
  .brand svg, .brand img { width: 32px; height: 32px; }
  .brand b { font-size: 14.5px; }
  .brand span { font-size: 8.5px; letter-spacing: .6px; }
  .top-right { gap: 5px; }
  .pill { padding-inline: 7px; font-size: 11px; }
  .pill.user { max-width: 58px; overflow: hidden; text-overflow: ellipsis; }
  .journey-tracker { height: 232px; }
  .journey-actions { grid-template-columns: 1fr 1.25fr; }
  .journey-map-foot { gap: 7px; padding-inline: 8px; }
  .journey-map-foot span { font-size: 8px; }
  .journey-map-foot b { max-width: 112px; font-size: 8.5px; }
  .foto-slot.done .foto-actions { grid-template-columns: 1fr; }
  .survey-picker { align-items: end; padding: 0; }
  .survey-picker-card { width: 100%; max-height: 92dvh; padding: 21px 14px calc(14px + env(safe-area-inset-bottom)); border-radius: 23px 23px 0 0; }
  .survey-picker-heading { display: block; margin-right: 38px; }
  .survey-picker-count { display: inline-block; margin-top: 8px; }
  .survey-picker-list { margin-top: 13px; }
  .survey-choice { grid-template-columns: 42px minmax(0,1fr) 24px; gap: 9px; min-height: 82px; padding: 11px; }
  .survey-choice-icon { width: 42px; height: 42px; }
}
.toggle-line .chk { display: flex; align-items: center; gap: 10px; font-size: 14.5px; font-weight: 600; color: var(--ink); }
.toggle-line input { width: 20px; height: 20px; accent-color: var(--brand); }

/* monitoreo de competencia */
.competition-list { display: grid; gap: 14px; margin-top: 12px; }
.competition-card {
  border: 1px solid #dce3ec; border-radius: 16px; padding: 14px;
  background: linear-gradient(180deg, #fff, #fbfcfe); box-shadow: 0 6px 20px rgba(15, 23, 42, .05);
}
.competition-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.competition-head b { font-size: 15px; }
.competition-remove {
  border: 1px solid #fecaca; background: #fff; color: #b91c1c; border-radius: 9px;
  padding: 7px 10px; font-size: 12px; font-weight: 800; cursor: pointer;
}
.competition-question { margin-top: 12px; }
.competition-question > span { display: block; color: var(--muted); font-size: 12px; font-weight: 800; margin-bottom: 7px; }
.competition-options { display: flex; flex-wrap: wrap; gap: 7px; }
.competition-options button {
  border: 1.5px solid #d9e0e8; background: #fff; color: var(--ink); border-radius: 10px;
  padding: 9px 11px; font: inherit; font-size: 13px; font-weight: 750; cursor: pointer;
}
.competition-options button.on {
  border-color: var(--brand); background: #fff5d9; color: #7c4a00;
  box-shadow: 0 0 0 2px rgba(245, 158, 11, .12);
}
.competition-products:empty::after { content: "Elegí primero una marca"; color: var(--muted); font-size: 12.5px; }
.competition-price-grid { display: grid; grid-template-columns: 1fr 104px; gap: 8px; }
.competition-price-grid input,
.competition-notes,
.competition-photo-reason {
  width: 100%; border: 1.5px solid #d9e0e8; border-radius: 10px; background: #fff;
  padding: 11px 12px; font: inherit; font-size: 14px;
}
.competition-photo {
  margin-top: 13px; border: 1.5px dashed #d3dae3; border-radius: 12px;
  padding: 11px; background: #fbfcfe;
}
.competition-photo.done { border-style: solid; border-color: #a7f3d0; background: #f0fdf4; }
.competition-photo-actions { display: grid; grid-template-columns: minmax(0,1fr); gap: 8px; }
.competition-photo.done .competition-photo-actions { grid-template-columns: minmax(0,1fr) auto; }
.competition-photo-btn {
  width: 100%; border: 0; border-radius: 10px; background: #12161d; color: #fff;
  min-height: 44px; padding: 11px; font: inherit; font-size: 13.5px; font-weight: 800; cursor: pointer;
}
.competition-photo.done .competition-photo-btn { background: #065f46; }
.competition-photo-delete {
  min-height: 44px; border: 1px solid #fecaca; border-radius: 10px; padding: 9px 12px;
  color: #b91c1c; background: #fff; font: inherit; font-size: 12.5px; font-weight: 800; cursor: pointer;
}
.competition-photo-preview { width: 100%; max-height: 190px; object-fit: cover; border-radius: 9px; margin-top: 9px; }
.competition-photo-skip {
  display: block; margin-top: 8px; border: 0; background: none; color: var(--muted);
  text-decoration: underline; font-size: 12.5px; cursor: pointer;
}
.competition-photo-reason { margin-top: 8px; border-color: #f2c94c; background: #fffdf3; }
.competition-add { width: 100%; margin-top: 12px; padding: 12px; }
.competition-empty {
  margin-top: 12px; padding: 14px; border: 1px solid #fde68a; border-radius: 12px;
  background: #fffbeb; display: grid; gap: 3px; color: #854d0e;
}
.competition-empty span { font-size: 12.5px; line-height: 1.4; }
.competition-summary { border-left: 3px solid #f59e0b; padding-left: 8px; }

@media (max-width: 420px) {
  .competition-photo.done .competition-photo-actions { grid-template-columns: 1fr; }
  .competition-photo-delete { width: 100%; }
}

.resumen { border-top: 1px dashed var(--line); margin-top: 14px; padding-top: 12px; font-size: 13.5px; color: var(--muted); display: grid; gap: 4px; }
.resumen b { color: var(--ink); }

.wiz-nav {
  display: flex; gap: 10px; margin-top: 16px;
  padding-bottom: env(safe-area-inset-bottom);
}
.wiz-nav .ghost { flex: 1; padding: 14px; }
.wiz-nav .primary { flex: 2; padding: 14px; font-size: 16px; }

/* ---------- confirm + toast ---------- */
.confirm { position: fixed; inset: 0; background: rgba(10,13,18,.55); display: grid; place-items: end center; z-index: 60; }
.confirm-card {
  width: 100%; max-width: 560px; background: #fff; border-radius: 22px 22px 0 0; text-align: center;
  padding: 26px 22px calc(26px + env(safe-area-inset-bottom));
}
.confirm-ic { font-size: 46px; margin-bottom: 8px; }
.confirm-card h2 { font-size: 21px; margin-bottom: 6px; }
.confirm-card p { color: var(--muted); font-size: 14.5px; margin-bottom: 18px; }
.confirm-card .primary { width: 100%; }

/* salida segura: guardar el borrador antes de abandonar el wizard */
body.exit-draft-open { overflow: hidden; }
.exit-draft { position: fixed; inset: 0; z-index: 95; display: grid; place-items: end center; }
.exit-draft-backdrop { position: absolute; inset: 0; background: rgba(8,11,16,.72); backdrop-filter: blur(3px); }
.exit-draft-card {
  position: relative; width: min(100%, 520px); max-height: min(88dvh, 620px); overflow-y: auto;
  background: var(--card); border-radius: 22px 22px 0 0; padding: 24px 20px calc(22px + env(safe-area-inset-bottom));
  box-shadow: 0 -18px 55px rgba(0,0,0,.32); animation: intro-up .24s ease-out;
}
.exit-draft-card:focus { outline: none; }
.exit-draft-ic { width: 48px; height: 48px; display: grid; place-items: center; margin-bottom: 12px; border-radius: 14px; background: #fff4d6; font-size: 25px; }
.exit-draft-card h2 { font-size: 22px; margin-bottom: 7px; }
.exit-draft-card > p { color: var(--muted); font-size: 14.5px; line-height: 1.45; }
.exit-draft-step {
  margin: 15px 0; padding: 11px 12px; border: 1px solid #f6c35b; border-radius: 11px;
  background: #fffaf0; color: #704b08; font-size: 13.5px; font-weight: 800;
}
.exit-draft-actions { display: grid; gap: 9px; }
.exit-draft-actions .primary, .exit-draft-actions .ghost { width: 100%; min-height: 46px; }
.exit-draft-discard {
  min-height: 44px; border: 0; background: transparent; color: var(--bad); border-radius: 10px;
  font-size: 14px; font-weight: 750; cursor: pointer;
}
.exit-draft-discard:hover, .exit-draft-discard:focus-visible { background: #fef2f2; outline: 2px solid #fecaca; outline-offset: -2px; }

/* introducción operativa */
body.intro-open { overflow: hidden; }
.intro-modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: end center; }
.intro-backdrop { position: absolute; inset: 0; background: rgba(8,11,16,.72); backdrop-filter: blur(3px); }
.intro-card {
  position: relative; width: 100%; max-width: 600px; max-height: min(92dvh, 820px); overflow: auto;
  background: #fff; border-radius: 24px 24px 0 0; padding: 27px 20px calc(24px + env(safe-area-inset-bottom));
  box-shadow: 0 -22px 70px rgba(0,0,0,.35); animation: introUp .28s cubic-bezier(.2,.7,.2,1) both;
}
@keyframes introUp { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: none; } }
.intro-x {
  position: absolute; top: 14px; right: 14px; width: 36px; height: 36px; border-radius: 50%;
  border: 1px solid var(--line); background: #f6f8fb; color: var(--muted); cursor: pointer; font-size: 15px;
}
.intro-eyebrow { color: var(--brand-dark); font-size: 11px; font-weight: 900; letter-spacing: 1.4px; text-transform: uppercase; padding-right: 42px; }
.intro-card h2 { font-size: clamp(23px, 6vw, 30px); line-height: 1.08; margin: 7px 42px 9px 0; }
.intro-lead { color: var(--muted); font-size: 14px; line-height: 1.5; }
.intro-steps { list-style: none; counter-reset: steps; display: grid; gap: 8px; margin: 18px 0; }
.intro-steps li {
  counter-increment: steps; display: grid; grid-template-columns: 34px 1fr; column-gap: 9px; align-items: center;
  padding: 9px 10px; border: 1px solid var(--line); border-radius: 12px; background: #fbfcfe;
}
.intro-steps li::before {
  content: counter(steps); grid-row: 1 / span 2; display: grid; place-items: center; width: 30px; height: 30px;
  border-radius: 9px; background: #fff4d6; color: var(--brand-dark); font-size: 12px; font-weight: 900;
}
.intro-steps b { font-size: 13.5px; }
.intro-steps span { color: var(--muted); font-size: 12.5px; line-height: 1.35; }
.intro-note { padding: 11px 12px; border-left: 4px solid var(--brand); border-radius: 9px; background: #fffaf0; color: #704b08; font-size: 12.5px; line-height: 1.45; }
.intro-primary { width: 100%; margin-top: 17px; }
@media (prefers-reduced-motion: reduce) {
  .intro-card, .journey-card.active .journey-current-marker { animation: none; }
}

/* borrador + cola */
.draft-name { color: var(--muted); font-size: 13.5px; margin-bottom: 10px; }
.draft-name span { display: block; margin-top: 3px; color: var(--brand-dark); font-size: 12.5px; font-weight: 750; }
.btn-row2 { display: flex; gap: 10px; }
.btn-row2 .primary { flex: 2; }
.btn-row2 .ghost { flex: 1; }
.v-right { display: flex; align-items: center; gap: 8px; flex: 0 0 auto; }
.pend-del {
  background: #fff; border: 1.5px solid #fecaca; color: #b91c1c;
  border-radius: 9px; width: 36px; height: 36px; cursor: pointer; font-size: 14px;
}
.resumen .gps-warn { color: #b91c1c; font-weight: 700; }

/* ---------- cámara en la app ---------- */
.cam { position: fixed; inset: 0; background: #000; z-index: 90; display: flex; flex-direction: column; }
.cam video { flex: 1; width: 100%; object-fit: contain; background: #000; min-height: 0; }
.cam.front video { transform: scaleX(-1); }
.cam-actions {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 18px calc(16px + env(safe-area-inset-bottom));
  background: rgba(10, 12, 16, .92);
}
.cam-side {
  background: rgba(255,255,255,.1); color: #e6ebf1; border: 1px solid rgba(255,255,255,.2);
  border-radius: 11px; padding: 12px 14px; font-size: 14px; font-weight: 600; cursor: pointer; min-width: 96px;
}
.cam-shot {
  width: 74px; height: 74px; border-radius: 50%; border: 4px solid #fff; cursor: pointer;
  background: linear-gradient(135deg, #f59e0b, #d97706); font-size: 26px;
  box-shadow: 0 0 0 5px rgba(255,255,255,.18);
}
.cam-shot:active { transform: scale(.94); }

.toast {
  position: fixed; left: 50%; bottom: calc(22px + env(safe-area-inset-bottom)); transform: translateX(-50%);
  background: #12161d; color: #fff; padding: 11px 18px; border-radius: 999px; font-size: 14px;
  box-shadow: 0 10px 30px rgba(0,0,0,.35); z-index: 70; max-width: 92vw; text-align: center;
}

@media (min-width: 640px) {
  .screen { padding-top: 22px; }
}

/* ---------- identidad premium 2026 ---------- */
:root {
  --ink: #0f172a;
  --muted: #64748b;
  --line: #dde5f0;
  --bg: #f1f5fa;
  --card: #ffffff;
  --brand: #3157ee;
  --brand-dark: #1e40af;
  --accent: #11b8da;
  --ok: #0f9f78;
  --bad: #e34862;
  --radius: 17px;
  --shadow: 0 1px 2px rgba(15,23,42,.04), 0 13px 34px rgba(31,49,83,.08);
}
body {
  font-family: "Aptos","Segoe UI Variable","Segoe UI",system-ui,-apple-system,sans-serif;
  background:
    radial-gradient(520px 280px at 100% 0,rgba(49,87,238,.09),transparent 66%),
    radial-gradient(480px 260px at 0 92%,rgba(17,184,218,.07),transparent 68%),
    var(--bg);
}
.top {
  padding-block: calc(10px + env(safe-area-inset-top)) 10px;
  background:
    radial-gradient(280px 100px at 10% 0,rgba(91,92,246,.2),transparent 72%),
    linear-gradient(145deg,#101d34,#07111f 72%);
  border-bottom: 1px solid rgba(117,228,248,.24);
  box-shadow: 0 10px 34px rgba(7,17,31,.18);
}
.brand img { filter: drop-shadow(0 7px 13px rgba(49,87,238,.32)); }
.brand b { letter-spacing: -.25px; font-weight: 850; }
.brand b i { color: #75e4f8; }
.brand span { color: #91a3ba; }
.pill {
  border-color: rgba(168,181,255,.2);
  background: rgba(255,255,255,.07);
  color: #d8e1ed;
  backdrop-filter: blur(10px);
}
.pill b { color: #75e4f8; }
.icon-btn {
  border-color: rgba(168,181,255,.2);
  background: rgba(255,255,255,.07);
}
.screen { padding-top: 19px; }
.hero { padding-top: 3px; }
.big-cta {
  min-height: 91px;
  border: 1px solid rgba(255,255,255,.22);
  border-radius: 21px;
  color: #fff;
  background:
    radial-gradient(130px 90px at 95% 0,rgba(117,228,248,.38),transparent 70%),
    linear-gradient(135deg,#5b5cf6 0%,#3157ee 52%,#11b8da 100%);
  box-shadow: 0 18px 38px rgba(49,87,238,.28), inset 0 1px rgba(255,255,255,.25);
}
.big-cta:hover { box-shadow: 0 21px 43px rgba(49,87,238,.34), inset 0 1px rgba(255,255,255,.25); }
.cta-ic {
  border: 1px solid rgba(255,255,255,.2);
  background: rgba(7,17,31,.2);
  box-shadow: inset 0 1px rgba(255,255,255,.14);
}
.guide-link { color: var(--brand); text-decoration-color: rgba(49,87,238,.32); }
.guide-link:focus-visible { outline-color: rgba(49,87,238,.28); }
.journey-card {
  border-radius: 21px;
  background:
    radial-gradient(circle at 92% 8%,rgba(17,184,218,.22),transparent 34%),
    radial-gradient(circle at 4% 100%,rgba(91,92,246,.2),transparent 42%),
    linear-gradient(145deg,#111f35,#07111f);
  border-color: rgba(168,181,255,.16);
  box-shadow: 0 18px 42px rgba(7,17,31,.19);
}
.journey-kicker { color: #75e4f8; }
.block,.step {
  border-color: rgba(202,213,228,.86);
  box-shadow: var(--shadow);
}
.block { padding: 16px; }
.block h2 { letter-spacing: -.15px; }
.mylist .visit-row,#pendingList .visit-row {
  border-color: #e1e8f2;
  background: linear-gradient(180deg,#fff,#f8fafc);
}
.visit-row.myvisit:hover { border-color: #b8c8ff; background: #f5f7ff; }
.visit-row .v-survey { color: #3730a3; background: #eef2ff; }
.primary {
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 13px;
  color: #fff;
  background: linear-gradient(135deg,#5b5cf6,#3157ee 58%,#11a8cd);
  box-shadow: 0 10px 23px rgba(49,87,238,.24);
}
.primary:not(:disabled):hover { transform: translateY(-1px); box-shadow: 0 13px 27px rgba(49,87,238,.3); }
.ghost { border-color: #d9e2ee; border-radius: 13px; box-shadow: 0 2px 7px rgba(15,23,42,.025); }
.survey-picker-backdrop { background: rgba(5,13,26,.78); }
.survey-picker-card {
  border: 1px solid rgba(255,255,255,.76);
  border-radius: 25px;
  box-shadow: 0 32px 90px rgba(4,12,24,.42);
}
.survey-picker-kicker,.dynamic-step-head span,.sub { color: var(--brand); }
.survey-picker-count { border-color: #c7d2fe; color: #3730a3; background: #eef2ff; }
.survey-choice {
  border-color: #dfe7f1;
  background: linear-gradient(180deg,#fff,#f8fafc);
}
.survey-choice:hover { border-color: #9fb1ff; background: #f7f8ff; }
.survey-choice:focus-visible { outline-color: rgba(49,87,238,.24); }
.survey-choice.selected {
  border-color: var(--brand);
  background: linear-gradient(135deg,#eef2ff,#ecfeff);
  box-shadow: 0 0 0 4px rgba(49,87,238,.11);
}
.survey-choice-icon { color: #3157ee; background: linear-gradient(135deg,#e0e7ff,#cffafe); }
.survey-choice.selected .survey-choice-meta em { color: #3730a3; background: rgba(255,255,255,.72); }
.survey-choice.selected .survey-choice-check { border-color: var(--brand); background: var(--brand); }
.wiz-head { background: linear-gradient(180deg,var(--bg) 72%,rgba(241,245,250,0)); }
.wiz-progress { height: 9px; background: #dce5f1; }
.wiz-bar { background: linear-gradient(90deg,#5b5cf6,#3157ee 56%,#11b8da); }
.field input,.field select,.field textarea {
  border-color: #d8e1ed;
  background: #f8fafc;
}
.field input:focus,.field select:focus,.field textarea:focus {
  border-color: var(--brand);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(49,87,238,.12);
}
.radio-card,.dynamic-choice label,.seg button,.counter,.material-flow {
  border-color: #dfe7f1;
  background: #f8fafc;
}
.radio-card.on,.seg button.on {
  border-color: var(--brand);
  color: var(--brand-dark);
  background: #eef2ff;
  box-shadow: 0 0 0 3px rgba(49,87,238,.09);
}
.flow-tip { border-color: #11b8da; color: #155e75; background: #ecfeff; }
.selfie-slot { border-color: #a5b4fc; background: #f5f7ff; }
.foto-slot { border-color: #ccd8e7; background: #f8fafc; }
.foto-btn,.competition-photo-btn {
  background: linear-gradient(135deg,#14233a,#07111f);
  box-shadow: 0 7px 16px rgba(7,17,31,.14);
}
.competition-card {
  border-color: #dce5f0;
  background: linear-gradient(180deg,#fff,#f8fafc);
}
.competition-options button.on {
  border-color: #7c3aed;
  color: #5b21b6;
  background: #f5f3ff;
  box-shadow: 0 0 0 3px rgba(124,58,237,.09);
}
.competition-summary { border-left-color: #7c3aed; }
.cam-shot { background: linear-gradient(135deg,#5b5cf6,#3157ee,#11b8da); box-shadow: 0 0 0 5px rgba(255,255,255,.18),0 8px 25px rgba(49,87,238,.35); }
.toast { background: rgba(7,17,31,.96); border: 1px solid rgba(168,181,255,.16); box-shadow: 0 14px 38px rgba(3,9,18,.38); }
.intro-eyebrow,.draft-name span { color: var(--brand); }
.intro-steps li::before,.exit-draft-ic { color: #3730a3; background: #eef2ff; }
.intro-note { border-color: #11b8da; color: #155e75; background: #ecfeff; }
@media (max-width:420px) {
  .survey-picker-card { border-radius: 25px 25px 0 0; }
}
