/* ── Step Navigator Sidebar (desktop only) ── */
.step-nav {
  display: none; /* shown via JS on form start; desktop media query makes it flex */
  flex-direction: column;
  background: white;
  border-radius: 12px;
  overflow: hidden;
}
.sn-header {
  background: var(--blue);
  padding: 16px 18px;
  color: white;
  position: sticky;
  top: 0;
  z-index: 1;
  flex-shrink: 0;
}
.sn-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  opacity: 0.9;
}
.sn-subtitle {
  font-size: 11px;
  opacity: 0.72;
  margin-top: 3px;
}
.sn-list {
  padding: 6px 0;
  overflow-y: auto;
  flex: 1;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
.sn-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  border-left: 3px solid transparent;
  transition: background 0.15s, border-color 0.15s;
}
.sn-item.sn-current {
  background: var(--blue-light);
  border-left-color: var(--blue);
}
.sn-item.sn-visited { opacity: 0.65; }
.sn-num {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--border);
  color: var(--text-muted);
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.15s, color 0.15s;
}
.sn-item.sn-current .sn-num { background: var(--blue); color: white; }
.sn-body { flex: 1; min-width: 0; }
.sn-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sn-item.sn-current .sn-label { color: var(--blue); }
.sn-optional { font-size: 10px; color: var(--text-muted); font-style: italic; }
.sn-status {
  font-size: 13px;
  font-weight: 700;
  color: transparent;
  width: 16px;
  text-align: center;
  flex-shrink: 0;
  transition: color 0.2s;
}
.sn-status.sn-done { color: var(--green); }

/* ── Card body columns (used on desktop) ── */
.card-col-info { min-width: 0; }
.card-col-upload { min-width: 0; }

/* ── Tire Background (decorative, fixed, desktop only) ── */
.tire-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.tire {
  position: absolute;
  border-radius: 50%;
  border: 8px solid var(--blue);
  opacity: 0.025;
  animation: float 20s infinite ease-in-out;
}
.tire::before,
.tire::after {
  content: '';
  position: absolute;
  background: var(--blue);
}
.tire::before {
  width: 40%;
  height: 8px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
.tire::after {
  width: 8px;
  height: 40%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
.tire:nth-child(1) { width: 200px; height: 200px; top: 10%;  left: 5%;   animation-delay: 0s;  animation-duration: 25s; }
.tire:nth-child(2) { width: 150px; height: 150px; top: 60%;  right: 10%; animation-delay: 5s;  animation-duration: 30s; }
.tire:nth-child(3) { width: 180px; height: 180px; bottom: 15%; left: 15%; animation-delay: 10s; animation-duration: 28s; }
.tire:nth-child(4) { width: 120px; height: 120px; top: 40%;  right: 25%; animation-delay: 15s; animation-duration: 22s; }

/* ── Intro instructions box (shown on step 0) ── */
.intro-instructions {
  background: linear-gradient(135deg, var(--surface) 0%, white 100%);
  border-left: 4px solid var(--blue);
  border-radius: var(--radius);
  padding: 18px;
  margin-bottom: 14px;
  box-shadow: var(--shadow);
}
.intro-instructions h3 {
  color: var(--blue);
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 14px;
}
.intro-list {
  display: grid;
  gap: 10px;
}
.intro-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 12px;
  background: white;
  border-radius: 8px;
  border: 1px solid rgba(0,61,165,0.07);
  transition: transform 0.2s, box-shadow 0.2s;
}
.intro-item:hover {
  transform: translateX(3px);
  box-shadow: 0 3px 10px rgba(0,61,165,0.10);
}
.intro-num {
  background: linear-gradient(135deg, var(--red) 0%, #d4154a 100%);
  color: white;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  flex-shrink: 0;
  box-shadow: 0 3px 10px rgba(200,16,46,0.30);
}
.intro-num-guide {
  background: linear-gradient(135deg, var(--blue) 0%, var(--blue-dark) 100%);
  box-shadow: 0 3px 10px rgba(0,61,165,0.30);
}
.intro-item p {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.65;
  margin: 0;
  align-self: center;
}
.intro-item-guide { background: linear-gradient(135deg, #eef2ff 0%, white 100%); border-color: rgba(0,61,165,0.15); }
.guide-link { color: var(--blue); text-decoration: underline; font-weight: 700; }
.guide-link:hover { color: var(--blue-dark); }

/* ── Floating Guide Button (FAB) ── */
/* bottom = 88px (nav-bar height) + env(safe-area-inset-bottom) for notched iOS devices */
.guide-fab {
  position: fixed;
  bottom: calc(88px + env(safe-area-inset-bottom, 0px));
  right: max(14px, env(safe-area-inset-right, 14px));
  z-index: 99;
  display: flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, var(--blue) 0%, var(--blue-dark) 100%);
  color: white;
  padding: 12px 18px;
  border-radius: 50px;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  box-shadow: 0 6px 24px rgba(0,61,165,0.35);
  transition: transform 0.25s, box-shadow 0.25s;
  letter-spacing: 0.2px;
  animation: fab-pulse 2.5s ease-in-out 3;
}
.guide-fab:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(0,61,165,0.45);
  animation: none;
}
.guide-fab svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
  flex-shrink: 0;
}

/* ── Step card ── */
.step-card {
  display: none;
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.step-card.active {
  display: block;
  animation: slideIn 0.25s ease forwards;
}
.card-header {
  background: var(--blue);
  padding: 16px 18px;
  color: white;
}
.card-header-top {
  display: flex;
  align-items: center;
  gap: 10px;
}
.card-icon   { font-size: 28px; flex-shrink: 0; }
.card-meta   { font-size: 11px; opacity: 0.75; font-weight: 600; text-transform: uppercase; letter-spacing: 0.4px; }
.card-title  { font-size: 20px; font-weight: 700; margin-top: 1px; }
.card-optional {
  display: inline-block;
  margin-top: 6px;
  font-size: 11px;
  background: rgba(255,255,255,0.18);
  padding: 2px 10px;
  border-radius: 99px;
  font-weight: 600;
}
.card-body { padding: 18px; }
.card-instructions {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 14px;
  padding: 10px 12px;
  background: var(--surface);
  border-radius: 6px;
  border-left: 3px solid var(--blue);
}

/* ── Instruction list ── */
.instr-list {
  margin: 0;
  padding-left: 18px;
  line-height: 1.75;
}
.instr-list li { font-size: 13px; color: var(--text-muted); margin-bottom: 2px; }

/* ── Shots section ── */
.shots-section { margin-bottom: 12px; }
.shots-label {
  font-size: 10px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}
.shots-wrap { display: flex; flex-wrap: wrap; gap: 5px; }
.shot-chip {
  font-size: 11px;
  font-weight: 700;
  background: var(--blue-light);
  color: var(--blue);
  border: 1px solid #c7d7f7;
  border-radius: 99px;
  padding: 3px 10px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

/* ── Points badge ── */
.points-badge {
  margin-left: auto;
  font-size: 12px;
  font-weight: 700;
  background: rgba(255,255,255,0.20);
  padding: 3px 11px;
  border-radius: 99px;
  white-space: nowrap;
  align-self: flex-start;
  flex-shrink: 0;
}

/* ── Upload zone ── */
.upload-zone {
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  padding: 26px 16px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  position: relative;
  background: var(--surface);
  user-select: none;
}
.upload-zone:hover {
  border-color: var(--blue);
  background: var(--blue-light);
}
.upload-zone.has-files {
  border-color: var(--green);
  background: var(--green-bg);
}
.upload-zone.required-error {
  border-color: var(--red);
  background: #fff5f5;
}
.upload-zone input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
}
.zone-icon  { font-size: 32px; margin-bottom: 6px; pointer-events: none; }
.zone-label {
  font-size: 15px;
  font-weight: 700;
  color: var(--blue);
  margin-bottom: 3px;
  pointer-events: none;
}
.zone-hint  { font-size: 12px; color: var(--text-muted); pointer-events: none; }

/* ── Video recording overlay ── */
.record-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.90);
  z-index: 9999;
  align-items: center;
  justify-content: center;
}
.record-overlay.active { display: flex; }
.record-card {
  background: #0f172a;
  border: 1px solid #1e293b;
  border-radius: 16px;
  padding: 32px 28px;
  text-align: center;
  width: min(320px, 90vw);
}
.record-area-label {
  font-size: 15px;
  font-weight: 700;
  color: #e2e8f0;
  margin-bottom: 20px;
}
.record-indicator {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 16px;
}
.record-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #ef4444;
  animation: rec-pulse 1s ease-in-out infinite;
}
@keyframes rec-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.4; transform: scale(0.8); }
}
.record-live {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  color: #ef4444;
}
.record-countdown {
  font-size: 80px;
  font-weight: 800;
  color: #f8fafc;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  margin-bottom: 4px;
  transition: color 0.3s;
}
.record-countdown.record-urgent { color: #ef4444; }
.record-seconds-label {
  font-size: 14px;
  color: #64748b;
  margin-bottom: 8px;
}
.record-min-hint {
  font-size: 12px;
  color: #475569;
  margin-bottom: 28px;
}
.record-stop-btn {
  width: 100%;
  padding: 13px;
  background: #1e293b;
  color: #cbd5e1;
  border: 1px solid #334155;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}
.record-stop-btn:active { background: #334155; }
.zone-count {
  margin-top: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--green);
  pointer-events: none;
}

/* ── File chips ── */
.file-list { margin-top: 12px; display: flex; flex-direction: column; gap: 7px; }
.file-chip {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  border-radius: 8px;
  padding: 9px 11px;
  font-size: 13px;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: background 0.2s;
}
.file-chip.uploading { background: #eff6ff; border-color: #bfdbfe; }
.file-chip.done      { background: var(--green-bg); border-color: #bbf7d0; }
.file-chip.error     { background: #fef2f2; border-color: #fecaca; }
.chip-icon   { font-size: 16px; flex-shrink: 0; }
.chip-name   { flex: 1; min-width: 0; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; line-height: 1.3; }
.chip-size   { font-size: 11px; color: var(--text-muted); flex-shrink: 0; white-space: nowrap; }
.chip-status { font-size: 16px; flex-shrink: 0; }
.spin        { display: inline-block; animation: spin 0.9s linear infinite; }

/* ── Chip upload progress bar (video multipart) ── */
.chip-prog {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
}
.chip-prog-bar {
  flex: 1;
  height: 4px;
  background: #dbeafe;
  border-radius: 2px;
  overflow: hidden;
}
.chip-prog-fill {
  height: 100%;
  background: var(--blue);
  border-radius: 2px;
  transition: width 0.4s ease;
}
.chip-prog-lbl {
  font-size: 10px;
  font-weight: 700;
  color: var(--blue);
  min-width: 28px;
  text-align: right;
}

/* ── Special screens ── */
.screen {
  display: none;
  flex-direction: column;
  align-items: center;
  padding: 32px 16px 120px;
  animation: slideIn 0.3s ease;
}
.screen.active { display: flex; }
.screen-card {
  background: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 36px 28px;
  max-width: 420px;
  width: 100%;
  text-align: center;
}
.screen-icon  { font-size: 60px; margin-bottom: 18px; }
.screen-title { font-size: 22px; font-weight: 700; margin-bottom: 10px; }
.screen-body  { font-size: 14px; color: var(--text-muted); line-height: 1.6; }
.screen-ref   { margin-top: 14px; font-size: 12px; color: var(--text-muted); }

/* ── Expired screen — proceed late button ── */
.proceed-late-btn {
  display: inline-block;
  margin-top: 20px;
  padding: 13px 28px;
  background: var(--blue);
  color: white;
  font-size: 15px;
  font-weight: 700;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-family: var(--font);
  transition: background 0.15s, transform 0.1s;
  width: 100%;
}
.proceed-late-btn:hover { background: var(--blue-dark); }
.proceed-late-btn:active { transform: scale(0.97); }

/* ── Completed overlay (already submitted) ── */
.screen-completed-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--green) 0%, #15803d 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 18px;
  box-shadow: 0 6px 20px rgba(22,163,74,0.25);
}
.screen-completed-icon svg {
  width: 38px;
  height: 38px;
  fill: white;
}
.screen-completed-branch {
  display: inline-block;
  background: var(--green-bg);
  color: var(--green);
  font-size: 12px;
  font-weight: 600;
  padding: 4px 14px;
  border-radius: 99px;
  margin-bottom: 14px;
  letter-spacing: 0.3px;
}
.late-tag {
  display: inline-block;
  background: #fef3c7;
  color: #b45309;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 12px;
  border-radius: 99px;
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ── Closed overlay (form unavailable) ── */
.screen-closed-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue) 0%, var(--blue-dark) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 18px;
  box-shadow: 0 6px 20px rgba(0,61,165,0.25);
}
.screen-closed-icon svg {
  width: 38px;
  height: 38px;
  fill: white;
}

/* ── Contact note (shared) ── */
.contact-note {
  margin-top: 16px;
  padding: 12px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ── Toast ── */
#toast {
  position: fixed;
  bottom: max(24px, calc(24px + env(safe-area-inset-bottom)));
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: #1a1a2e;
  color: #fff;
  padding: 10px 18px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
  z-index: 9999;
  opacity: 0;
  transition: opacity 0.25s, transform 0.25s;
  pointer-events: none;
  max-width: calc(100vw - 32px);
  text-align: center;
}
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
#toast.warn { border-left: 4px solid var(--red); }

/* ── Loading overlay ── */
.overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  z-index: 999;
  align-items: center;
  justify-content: center;
}
.overlay.active { display: flex; }
.overlay-box {
  background: white;
  border-radius: var(--radius);
  padding: 32px 40px;
  text-align: center;
  box-shadow: 0 8px 40px rgba(0,0,0,0.2);
}
.loader {
  width: 40px;
  height: 40px;
  border: 4px solid var(--border);
  border-top-color: var(--blue);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto;
}
.overlay-msg { margin-top: 14px; font-size: 15px; font-weight: 600; }

/* ── Consent block (LFPDPPP) ── */
.consent-block {
  display: none;
  background: var(--blue-light);
  border: 1.5px solid var(--blue);
  border-radius: var(--radius);
  padding: 16px;
  margin: 0 14px 10px;
  font-size: 13px;
  color: var(--text);
}
.consent-title {
  font-weight: 700;
  color: var(--blue);
  margin-bottom: 10px;
  font-size: 13px;
}
.consent-body {
  line-height: 1.5;
  margin-bottom: 12px;
}
.consent-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
}
.consent-checkbox {
  margin-top: 2px;
  width: 18px;
  height: 18px;
  accent-color: var(--blue);
  flex-shrink: 0;
}
.consent-error {
  display: none;
  margin-top: 8px;
  font-size: 12px;
  color: var(--red);
  font-weight: 600;
}

/* ════════════════════════════════════════
   HD Resolution Badge — inside upload zone
════════════════════════════════════════ */
.zone-res-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 11px;
  border-radius: 20px;
  margin-top: 9px;
  letter-spacing: 0.15px;
  pointer-events: none; /* don't intercept clicks on zone overlay */
}
/* Image variant — green pill (auto resize, no action needed) */
.zone-res-image {
  background: #e8f5e9;
  color: #2e7d32;
  border: 1px solid #a5d6a7;
}
/* Video variant — amber pill (rejection if over limit) */
.zone-res-video {
  background: #fff3e0;
  color: #bf360c;
  border: 1px solid #ffcc80;
}

/* ── Intro HD item ── */
.intro-item-hd { border-left: 3px solid #f59e0b; padding-left: 4px; }
.intro-num-hd  { background: #f59e0b !important; font-size: 11px !important; letter-spacing: 0.5px; }

/* ════════════════════════════════════════
   HD Resolution Rejection Modal
════════════════════════════════════════ */
.res-modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  z-index: 1000; /* H-09: above loading overlay (999) so rejection message is always visible */
  align-items: center;
  justify-content: center;
  padding: 20px;
  padding-bottom: max(20px, env(safe-area-inset-bottom));
}
.res-modal-backdrop.active { display: flex; }

.res-modal-card {
  background: white;
  border-radius: 18px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.32);
  max-width: 420px;
  width: 100%;
  overflow: hidden;
  animation: slide-up 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Header — red gradient matching brand */
.res-modal-header {
  background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 100%);
  padding: 22px 24px 18px;
  text-align: center;
}
.res-modal-header-icon  { font-size: 38px; display: block; margin-bottom: 8px; }
.res-modal-header-title {
  color: white;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.25;
}

/* Body */
.res-modal-body { padding: 18px 22px 10px; }

.res-modal-detected {
  font-size: 13px;
  font-weight: 700;
  color: var(--red);
  background: #fff0f2;
  border: 1px solid #fecaca;
  border-radius: 8px;
  padding: 10px 14px;
  text-align: center;
  margin-bottom: 14px;
}
.res-modal-filename {
  font-size: 11px;
  color: var(--text-muted);
  text-align: center;
  margin: -8px 0 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.res-modal-desc {
  font-size: 13px;
  color: #444;
  line-height: 1.65;
  margin-bottom: 14px;
}

/* How-to steps */
.res-modal-steps-label {
  font-size: 11px;
  font-weight: 700;
  color: #888;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  margin-bottom: 9px;
}
.res-modal-step {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background: #f8f9fb;
  border-radius: 10px;
  padding: 11px 13px;
  margin-bottom: 8px;
  font-size: 12.5px;
  line-height: 1.55;
  color: #333;
}
.res-modal-step-os {
  font-size: 22px;
  flex-shrink: 0;
  line-height: 1.2;
}

/* Footer buttons */
.res-modal-footer {
  padding: 8px 22px 20px;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.res-modal-btn-retry {
  background: var(--blue);
  color: white;
  border: none;
  border-radius: 10px;
  padding: 14px;
  font-size: 14px;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  width: 100%;
  transition: background 0.18s, transform 0.1s;
}
.res-modal-btn-retry:hover  { background: var(--blue-dark); }
.res-modal-btn-retry:active { transform: scale(0.98); }
.res-modal-btn-dismiss {
  background: none;
  color: var(--text-muted);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 11px;
  font-size: 13px;
  font-family: var(--font);
  cursor: pointer;
  width: 100%;
  transition: background 0.18s;
}
.res-modal-btn-dismiss:hover { background: #f5f7fa; }

/* ════════════════════════════════════════════════════════════════════════════
   PICTURE-BOOK STEP CARD — 2026-08-08 (Avante Phase-2 feedback)

   Brief, in the client's own words: "es literal como enseñarles a niños chiquitos
   — con letras grandes, que te dice lo básico."

   So the card is a page of a picture book. Three beats, no prose:
     ¿dónde estoy?  big icon, big title, 12 dots
     ¿qué hago?     boxes you fill, or a dial + a tolerance band
     ¿cómo?         one giant button

   COLOUR — Avante brand identity manual, nothing else. Every value below resolves
   to a token already declared in base.css: --blue / --blue-dark / --blue-light for
   chrome and action, --green / --green-bg / --amber / --red for state. No new hue
   is introduced and no token is redefined. Scale, weight, contrast and whitespace
   do the work that colour is not allowed to do here.
════════════════════════════════════════════════════════════════════════════ */

/* ── 1 · Header ─────────────────────────────────────────────────────────── */
/* Background comes from .card-header (var(--blue)) — deliberately not overridden. */
.card-header-kid {
  position: relative;
  padding: 20px 18px 16px;
  text-align: center;
}
.kid-step {
  position: absolute;
  top: 14px;
  left: 16px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  border: 2px solid rgba(255, 255, 255, 0.55);
  color: #fff;
  font-size: 17px;
  font-weight: 800;
  line-height: 30px;
  font-variant-numeric: tabular-nums;
}
.kid-emoji {
  font-size: 46px;
  line-height: 1.1;
  margin-bottom: 2px;
}
.kid-title {
  font-size: 27px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.6px;
  color: #fff;
  margin: 0;
}
.kid-meta {
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.82);
  margin-top: 5px;
}
.kid-optional {
  display: inline-block;
  margin-top: 8px;
  font-size: 11px;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
  padding: 3px 12px;
  border-radius: 99px;
}
.kid-dots {
  display: flex;
  justify-content: center;
  gap: 5px;
  margin-top: 13px;
}
.kid-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.32);
}
.kid-dot-past { background: rgba(255, 255, 255, 0.7); }
.kid-dot-now {
  width: 20px;
  border-radius: 99px;
  background: #fff;
}

/* ── 2 · "¿Qué hago?" ───────────────────────────────────────────────────── */
.do-label {
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1.4px;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 12px;
}

/* Photo areas — one box per required shot, filled as photos land. */
.shot-slots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 9px;
}
.shot-slots[data-count="1"] { grid-template-columns: 1fr; }
.shot-slots[data-count="2"] { grid-template-columns: repeat(2, 1fr); }
.shot-slots[data-count="4"] { grid-template-columns: repeat(2, 1fr); }
.shot-slot {
  position: relative;
  border: 2.5px dashed var(--border);
  border-radius: 14px;
  background: var(--surface);
  padding: 15px 6px 11px;
  text-align: center;
  transition: background 0.2s, border-color 0.2s;
}
.shot-slot-badge {
  position: absolute;
  top: -9px;
  left: 50%;
  transform: translateX(-50%);
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--text-muted);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  line-height: 20px;
}
.shot-slot-cam {
  width: 30px;
  height: 30px;
  fill: var(--text-muted);
  opacity: 0.42;
}
.shot-slot-check {
  width: 30px;
  height: 30px;
  fill: var(--green);
  display: none;
}
.shot-slot-name {
  margin-top: 5px;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.3px;
  color: var(--text-muted);
  line-height: 1.25;
  word-break: break-word;
}
.shot-slot.slot-done {
  border-style: solid;
  border-color: var(--green);
  background: var(--green-bg);
}
.shot-slot.slot-done .shot-slot-badge { background: var(--green); }
.shot-slot.slot-done .shot-slot-cam { display: none; }
.shot-slot.slot-done .shot-slot-check { display: inline-block; }
.shot-slot.slot-done .shot-slot-name { color: var(--green); }
.shot-slots-hint {
  margin-top: 11px;
  text-align: center;
  font-size: 14px;
  color: var(--text-muted);
}
.shot-slots-hint strong { color: var(--text); font-weight: 800; }

/* Video areas — the number, then a picture of the rule. */
.timer-dial {
  border: 3px solid var(--blue-light);
  border-radius: 18px;
  padding: 16px 12px 14px;
  text-align: center;
  background: #fff;
}
.timer-dial-icon {
  width: 30px;
  height: 30px;
  display: block;
  margin: 0 auto 2px;
  fill: var(--blue);
}
.timer-dial-num {
  font-size: 62px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -3px;
  font-variant-numeric: tabular-nums;
  color: var(--blue);
}
.timer-dial-dash { font-weight: 400; opacity: 0.45; margin: 0 2px; }
.timer-dial-unit {
  margin-top: 5px;
  font-size: 14px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--text-muted);
}
/* The band is the whole rule in one image: short is rejected, a bit long is fine. */
.timer-band { margin-top: 11px; }
.timer-band-track {
  display: grid;
  grid-template-columns: 1.1fr 1.6fr 1fr;
  gap: 3px;
}
.tb-seg {
  border-radius: 6px;
  padding: 7px 2px;
  text-align: center;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  line-height: 1.2;
}
/* State colours only — the same --red / --green the form already uses for
   required-error and captured. No new hue. */
.tb-short { background: #fff5f5; color: var(--red); }
.tb-good  { background: var(--green); color: #fff; }
.tb-over  { background: var(--green-bg); color: var(--green); }
.timer-band-legend {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-top: 8px;
  font-size: 12px;
  font-weight: 600;
}
.tb-l-bad { color: var(--red); }
.tb-l-ok  { color: var(--green); }

/* ── 3 · The criteria door ──────────────────────────────────────────────── */
.criteria-mega {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  margin-top: 16px;
  background: #fff;
  border: 2.5px solid var(--blue);
  border-radius: 16px;
  padding: 14px 15px;
  font-family: var(--font);
  text-align: left;
  cursor: pointer;
  transition: background 0.18s, transform 0.1s;
}
.criteria-mega:hover  { background: var(--surface); }
.criteria-mega:active { transform: scale(0.99); }
.cm-icon {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--blue);
  color: #fff;
  font-size: 22px;
  font-weight: 800;
  line-height: 38px;
  text-align: center;
  flex-shrink: 0;
}
.cm-text { flex: 1; min-width: 0; }
.cm-text b {
  display: block;
  font-size: 17px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.2;
}
.cm-sub {
  display: block;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.3;
  margin-top: 1px;
}
.cm-chev { font-size: 30px; line-height: 1; flex-shrink: 0; color: var(--blue); }

/* ── 4 · One giant button ───────────────────────────────────────────────── */
/* Keeps .upload-zone so refreshZone()'s .has-files / .required-error still apply. */
.upload-zone.big-capture {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 82px;
  margin-top: 18px;
  padding: 18px 16px;
  border: 0;
  border-radius: 16px;
  background: var(--blue);
  color: #fff;
  transition: background 0.18s, transform 0.1s;
}
.upload-zone.big-capture:hover  { background: var(--blue-dark); }
.upload-zone.big-capture:active { transform: scale(0.99); }
.bc-icon { width: 34px; height: 34px; fill: #fff; flex-shrink: 0; pointer-events: none; }
.bc-text {
  font-size: 21px;
  font-weight: 800;
  letter-spacing: 0.5px;
  pointer-events: none;
}
/* Captured → the button goes green, so "done" is a state colour, not a sentence.
   Same --green / --red the form already uses on .upload-zone.has-files and
   .upload-zone.required-error — the semantics carry over, only the fill changes. */
.upload-zone.big-capture.has-files { background: var(--green); }
.upload-zone.big-capture.has-files:hover { filter: brightness(0.93); }
.upload-zone.big-capture.required-error { background: var(--red); }
.upload-zone.big-capture.required-error:hover { background: var(--red-dark); }

.zone-count {
  margin-top: 10px;
  text-align: center;
  font-size: 15px;
  font-weight: 800;
}
.zone-count-part { color: var(--amber); }
.zone-count-done { color: var(--green); }

.zone-res-badge { margin: 10px auto 0; }

/* ── 5 · Criteria modal ─────────────────────────────────────────────────── */
/* The .res-modal-* shell's header is red because its only caller so far was a
   rejection dialog. This modal is informational, so it takes the brand blue —
   red on an instruction sheet reads as "you did something wrong". Same gradient
   pair the rest of the form uses for primary surfaces. */
.criteria-modal .res-modal-header {
  background: linear-gradient(135deg, var(--blue) 0%, var(--blue-dark) 100%);
}
.criteria-modal .res-modal-header-icon { font-size: 34px; }
.criteria-modal .res-modal-header-title { font-size: 21px; }
.criteria-modal-req {
  font-size: 16px;
  color: var(--text);
  background: var(--surface);
  border-radius: 10px;
  padding: 12px 14px;
  margin-bottom: 13px;
  text-align: center;
}
.criteria-modal-req strong { font-weight: 800; }
.criteria-modal-shots { margin-bottom: 15px; }
.criteria-modal-shots .shots-label {
  font-size: 10px;
  font-weight: 800;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 7px;
}
.criteria-modal-shots .shots-wrap { display: flex; flex-wrap: wrap; gap: 5px; }
.criteria-modal-list .instr-list { padding-left: 20px; }
.criteria-modal-list .instr-list li {
  font-size: 14px;
  color: var(--text);
  margin-bottom: 9px;
  line-height: 1.5;
}

/* ── 6 · Paso 00 — the gate ─────────────────────────────────────────────── */
/* Single column even on desktop: this page is read, not operated. */
.gate-card { display: block; }
.gate-body { display: block !important; max-width: 620px; margin: 0 auto; }

.rule-list { display: grid; gap: 10px; }
.rule-item {
  display: flex;
  align-items: flex-start;
  gap: 13px;
  padding: 14px 15px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 14px;
}
.rule-num {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  border-radius: 10px;
  background: var(--blue);
  color: #fff;
  font-size: 17px;
  font-weight: 800;
  line-height: 36px;
  text-align: center;
}
.rule-num-hd { font-size: 14px; letter-spacing: -0.3px; }
.rule-num-guide { display: flex; align-items: center; justify-content: center; }
.rule-num-guide svg { width: 19px; height: 19px; fill: #fff; }
.rule-item p {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.5;
  color: var(--text-muted);
  align-self: center;
}
.rule-item p strong { color: var(--text); font-weight: 700; }

/* The Guía Visual card — the one reference that answers everything a branch might
   ask, so it is the only element on the gate that leaves the brand blue. --red is
   the Avante accent (#C8102E), already declared in base.css; no new colour. The
   whole card is an <a>, so the tap target is the full width, not four words. */
a.rule-item-guide {
  border-width: 2.5px;
  border-color: var(--red);
  background: #fff5f5;
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.18s, transform 0.1s;
}
a.rule-item-guide:hover  { background: #fdeaee; }
a.rule-item-guide:active { transform: scale(0.995); }
a.rule-item-guide .rule-num-guide { background: var(--red); }
a.rule-item-guide p strong { color: var(--red); text-decoration: underline; }
.rule-guide-chev {
  align-self: center;
  flex-shrink: 0;
  font-size: 30px;
  line-height: 1;
  color: var(--red);
}

.gate-privacy-label { margin-top: 24px; }
.gate-privacy {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 14px 15px;
}
.gate-privacy .consent-body {
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--text-muted);
  margin: 0;
}
.gate-privacy a { color: var(--blue); }

/* The two acknowledgements. Big hit area — these get tapped on a tablet. */
.gate-check {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 12px;
  padding: 14px 15px;
  background: #fff;
  border: 2px solid var(--border);
  border-radius: 14px;
  font-size: 14px;
  line-height: 1.45;
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.18s, background 0.18s;
}
.gate-check:hover { border-color: var(--blue); }
.gate-check:has(input:checked) { border-color: var(--green); background: var(--green-bg); }
.gate-check .consent-checkbox { width: 24px; height: 24px; margin-top: 0; }

.gate-start-btn {
  display: block;
  width: 100%;
  margin-top: 20px;
  padding: 21px 16px;
  border: 0;
  border-radius: 16px;
  background: var(--blue);
  color: #fff;
  font-family: var(--font);
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0.6px;
  cursor: pointer;
  transition: background 0.18s, transform 0.1s;
}
.gate-start-btn:hover:not(:disabled)  { background: var(--blue-dark); }
.gate-start-btn:active:not(:disabled) { transform: scale(0.99); }
.gate-start-btn:disabled {
  background: var(--border);
  color: var(--text-muted);
  cursor: not-allowed;
}
.gate-body .consent-error { margin-top: 10px; text-align: center; }

/* ── Narrow phones ──────────────────────────────────────────────────────── */
@media (max-width: 400px) {
  .kid-emoji { font-size: 40px; }
  .kid-title { font-size: 24px; }
  .timer-dial-num { font-size: 54px; }
  .shot-slot-name { font-size: 9.5px; }
  .bc-text { font-size: 19px; }
  .cm-text b { font-size: 16px; }
  .rule-item p { font-size: 13.5px; }
  .gate-check { font-size: 13px; }
  .gate-start-btn { font-size: 18px; padding: 19px 12px; }
}
