/* ===== VARIÁVEIS ===== */
:root {
  --blue: #2f63e6;
  --blue-dark: #1d4ed8;
  --red: #c91c1c;
  --green: #0b6e4f;
  --text: #111827;
  --muted: #4b5563;
  --line: #e5e9f2;
  --card-bg: #ffffff;
  --bg-image: url("/assets/bg-consulta.jpg?v=forcefix1");
}

/* ===== RESET E BASE ===== */
* { box-sizing: border-box; }

html, body {
  min-height: 100%;
  margin: 0;
  padding: 0;
}

body {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, sans-serif;
  color: var(--text);
  background-color: #f4f7fc;
  background-image: var(--bg-image);
  background-size: cover;
  background-position: center center;
  background-attachment: fixed;
  position: relative;
}

body::after {
  content: none;
}

.screen {
  display: none;
  min-height: calc(100vh - 56px);
  position: relative;
  z-index: 1;
}
.screen.active { display: block; }

.page-container {
  max-width: 820px;
  margin: 0 auto;
  padding: 0 16px;
}

.consult-shell {
  max-width: 448px;
  padding: 0;
}

/* ===== HEADER ===== */
.topbar {
  height: 64px;
  background: #ffffff;
  border-bottom: 1px solid #e5e9f2;
  display: flex;
  align-items: center;
  position: relative;
  z-index: 100;
  width: 100%;
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  box-sizing: border-box;
}

.brand {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0;
}
.logo-slot {
  width: auto;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  text-decoration: none;
}
.logo-slot img {
  max-width: 160px;
  height: 44px;
  max-height: 44px;
  object-fit: contain;
}
.brand-text {
  padding-left: 17px;
  border-left: 1px solid #e5e9f2;
}
.brand-text strong {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: #111827;
}
.brand-text small {
  display: block;
  font-size: 12px;
  color: #374151;
  font-weight: 500;
}

.user-header {
  display: flex !important;
  align-items: center !important;
  gap: 14px !important;
}
.user-header.hidden { display: none !important; }
.bell { 
  color: #64748b !important; 
  display: flex !important;
  align-items: center !important;
}
.bell svg {
  width: 22px !important;
  height: 22px !important;
  stroke: #64748b !important;
}
.user-meta {
  text-align: right !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 2px !important;
}
.user-meta strong { 
  display: block !important; 
  font-size: 14.5px !important; 
  color: #0f172a !important;
  font-weight: 700 !important; 
  line-height: 1.2 !important;
}
.user-meta small { 
  color: #64748b !important; 
  font-size: 13px !important;
  font-weight: 500 !important;
  line-height: 1.2 !important;
}
.avatar {
  width: 42px !important;
  height: 42px !important;
  border-radius: 50% !important;
  background: #7c3aed !important;
  color: #ffffff !important;
  display: grid !important;
  place-items: center !important;
  font-weight: 700 !important;
  font-size: 15px !important;
  letter-spacing: 0.5px !important;
  box-shadow: 0 2px 6px rgba(124, 58, 237, 0.25) !important;
  flex-shrink: 0 !important;
}

/* ===== BREADCRUMB (full-width de ponta a ponta, igual referência) ===== */
.breadcrumb {
  /* full-bleed: quebra o max-width do .page-container e ocupa 100% da tela */
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  margin-bottom: 28px;
  height: 42px;
  background: #eef2f7;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #5a6b85;
  font-size: 13px;
  font-weight: 500;
  border-radius: 0;
  border-bottom: 1px solid #e2e8f0;
  box-sizing: border-box;
  padding: 0 16px;
  transform: none;
}

.breadcrumb span {
  transform: none;
}

/* "acesso ao sistema" em negrito mais preto */
.breadcrumb strong {
  color: #1e293b;                /* bem mais escuro / preto */
  font-weight: 700;
}

/* ===== CARD PRINCIPAL ===== */
.card {
  background: #ffffff;
  border: 1px solid #e5e9f2;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);
  overflow: hidden;
  margin-bottom: 16px;
}

.consult-card,
.loading-card {
  max-width: 448px;
  margin: 150px auto 24px;
}

.card-head {
  padding: 21px 21px 18px;
  border-bottom: 1px solid #f0f3f8;
}
.card-head h1 {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 700;
  color: #111827;
}
.card-head p {
  margin: 0;
  color: #5f6b7a;
  font-size: 13.5px;
}

/* ===== FORMULÁRIO ===== */
.form { padding: 20px 20px 21px; }
.form label:not(.checkline) {
  display: block;
  font-weight: 600;
  font-size: 13px;
  margin-bottom: 9px;
  color: #374151;
}
.form input[type="text"] {
  width: 100%;
  border: 1px solid #d1d9e8;
  border-radius: 5px;
  padding: 0 16px;
  height: 50px;
  font-size: 15px;
  color: var(--text);
  outline: none;
  transition: border 0.2s, box-shadow 0.2s;
  background: #ffffff;
}
.form input[type="text"]:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(47, 99, 230, 0.12);
  background: #fff;
}

.checkline {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: #5a6a8a;
  font-size: 13px;
  line-height: 1.45;
  margin: 18px 0 22px;
}
.checkline input { margin-top: 3px; }

.form button {
  background: #7f9ae8;
  color: white;
  border: 0;
  border-radius: 5px;
  margin-top: 22px;
  height: 48px;
  width: 100%;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  box-shadow: none;
}
.form button:hover {
  background: #6f8de1;
  transform: translateY(-1px);
}
.form button:disabled {
  background: #7f9ae8;
  opacity: 1;
  cursor: not-allowed;
}

.error {
  color: #c53030;
  font-size: 13px;
  margin: 12px 0 0;
}
.error.hidden { display: none; }

.terms {
  border-top: 1px solid var(--line);
  padding: 13px 18px 14px;
  color: var(--muted);
  text-align: center;
  font-size: 11.5px;
  line-height: 1.55;
}

/* ===== ETAPAS ===== */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  max-width: 448px;
  margin: 0 auto 16px;
}
.step {
  background: #ffffff;
  border: 1px solid #e5e9f2;
  border-radius: 6px;
  padding: 13px 10px 12px;
  text-align: center;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}
.step b {
  display: block;
  color: #1454d8;
  font-size: 12px;
  margin-bottom: 4px;
  font-weight: 700;
}
.step span {
  display: block;
  color: #4b5563;
  font-size: 11.5px;
}
.step.active {
  border-color: #e5e9f2;
  background: #ffffff;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}
.step.muted { 
  opacity: 0.55; 
  background: #f8fafc;
}

/* ===== BARRA DE SEGURANÇA ===== */
.security-note {
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 448px;
  margin: 0 auto;
  background: #eaf2ff;
  color: #0f4aa6;
  border-radius: 6px;
  padding: 13px 18px;
  font-size: 12.5px;
  line-height: 1.45;
  border: 1px solid #c8d9f0;
}
.security-note svg {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  color: #2f63e6;
}

/* ===== TELA DE RESULTADO ===== */
.result-screen {
  background: #f4f7fc;
  padding: 40px 0;
}
.result-wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 16px;
}
.result-title p {
  color: #1e40af;
  font-weight: 700;
  margin: 0 0 2px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}
.result-title h1 {
  margin: 0 0 12px;
  font-size: 22px;
  font-weight: 700;
  color: #111827;
  line-height: 1.1;
}

/* ===== CARD DE INFRAÇÃO (Tela de Detalhes) ===== */
.infraction-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 3px 12px rgba(0,0,0,0.05);
  overflow: hidden;
  margin-bottom: 20px;
}

.infraction-header {
  padding: 16px 22px;
  background: #f8fafc;
  border-bottom: 1px solid #e5e9f2;
}

.infraction-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px 16px;
  padding: 8px 24px 4px;
}
.infraction-row > div {
  background: #fff;
  border: 1px solid #e5e9f2;
  border-radius: 6px;
  padding: 8px 12px;
}
.infraction-row .label {
  font-size: 8px;
  font-weight: 600;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 2px;
  display: block;
}
.infraction-row .value {
  font-size: 13px;
  color: #1e293b;
  font-weight: 600;
}

.infraction-values {
  padding: 18px 22px 14px;
  border-bottom: 1px solid #e5e9f2;
}
.infraction-values h3 {
  margin: 0 0 12px;
  font-size: 14px;
  font-weight: 700;
  color: #111827;
}
.value-row {
  display: flex;
  justify-content: space-between;
  padding: 5px 0;
  font-size: 14px;
  color: #374151;
}
.value-row.total {
  border-top: 1px solid #e5e9f2;
  padding-top: 11px;
  margin-top: 6px;
  font-weight: 700;
  font-size: 14.5px;
  color: #111827;
}

.infraction-total-pix {
  background: #e0edff;
  padding: 14px 22px;
  text-align: center;
  border-bottom: 1px solid #c8d9f0;
}
.infraction-total-pix span {
  display: block;
  font-size: 11px;
  color: #1e40af;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}
.infraction-total-pix strong {
  display: block;
  font-size: 26px;
  color: #15803d;
  margin-top: 1px;
  font-weight: 700;
}

.infraction-warning {
  padding: 14px 22px;
  background: #fefce8;
  border-bottom: 1px solid #fde047;
}
.infraction-warning b {
  display: block;
  color: #854d0e;
  margin-bottom: 6px;
  font-size: 13px;
}
.infraction-warning ul {
  margin: 0;
  padding-left: 18px;
  color: #854d0e;
  font-size: 13px;
  line-height: 1.4;
}

.infraction-cta {
  display: block;
  width: calc(100% - 44px);
  margin: 14px auto 18px;
  border: 0;
  border-radius: 9px;
  background: #2f63e6;
  color: #fff;
  height: 48px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 2px 8px rgba(47, 99, 230, 0.25);
}
.infraction-cta:hover {
  background: #1d4ed8;
  transform: translateY(-1px);
}

.notice {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 12px 16px;
  display: grid;
  gap: 2px;
  color: #334155;
}
.notice b { font-size: 12.5px; }
.notice span { font-size: 12px; }

/* ===== LOADING ===== */
.loading-body {
  padding: 38px 32px 32px;
  text-align: center;
}
.spinner {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, rgba(37, 99, 235, 0) 0%, rgba(37, 99, 235, 0.15) 25%, rgba(37, 99, 235, 0.65) 70%, #2563eb 100%);
  mask: radial-gradient(farthest-side, transparent calc(100% - 5px), #000 0);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 5px), #000 0);
  animation: smoothConicSpin 0.9s linear infinite;
  margin: 0 auto 24px;
}

.loading-body h2 {
  font-size: 17px;
  margin: 0 0 8px;
  color: #1a2a4a;
}
.loading-body p {
  color: #5a6a8a;
  margin: 0;
  font-size: 14px;
}
.divider {
  height: 1px;
  background: var(--line);
  margin: 27px 0 16px;
}
.secure-dot {
  color: #5b6576;
  font-size: 12px;
}
.secure-dot::first-letter { color: var(--blue); }

/* ===== TELA DE LOADING DE PAGAMENTO ===== */
.payment-loading-screen {
  background: #f4f7fc;
  padding: 40px 0 60px;
}
.process-wrap {
  max-width: 820px;
  margin: 0 auto;
  padding: 0 16px;
  text-align: center;
}
.big-loader {
  width: 64px;
  height: 64px;
  margin: 0 auto 24px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, rgba(95, 66, 245, 0) 0%, rgba(95, 66, 245, 0.15) 25%, rgba(95, 66, 245, 0.6) 70%, #7c5cf5 100%);
  position: relative;
  animation: smoothConicSpin 0.9s linear infinite !important;
  /* Sem mask — anel completo com bolinha central */
}

.big-loader::before {
  content: '';
  position: absolute;
  top: 6px;
  left: 6px;
  right: 6px;
  bottom: 6px;
  border-radius: 50%;
  background: #eef0ff;
}

.big-loader span {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #5f42f5;
  display: block;
  box-shadow: 0 0 8px rgba(95, 66, 245, 0.4);
  z-index: 1;
}
.process-wrap h1 {
  font-size: clamp(28px, 4vw, 36px);
  margin: 0 0 10px;
}
.process-wrap > p {
  color: #7b8494;
  font-size: 18px;
  margin: 0 0 8px;
}
.process-wrap > small {
  color: #9aa3b3;
  font-size: 16px;
  display: block;
  margin-bottom: 28px;
}

.progress-line {
  width: min(420px, 80vw);
  height: 8px;
  margin: 0 auto 32px;
  background: #e2e8f0;
  border-radius: 999px;
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.06);
}
.progress-line span {
  display: block;
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #9333ea, #3b82f6, #06b6d4);
  border-radius: inherit;
  transition: width 0.08s linear;
}

.progress-percentage-label {
  display: none !important;
}

.process-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-bottom: 34px;
}
.process-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 28px 20px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.02);
}
.process-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  margin: 0 auto 18px;
  display: grid;
  place-items: center;
  font-size: 24px;
  font-weight: 900;
}
.process-icon.blue { background: #deebff; color: #2f63e6; }
.process-icon.purple { background: #f2e3ff; color: #9b4df0; }
.process-icon.green { background: #d9f8e6; color: #14a45f; }
.process-card h2 { margin: 0 0 12px; font-size: 18px; }
.process-card p { margin: 0; color: var(--muted); font-size: 15px; }

.step-status-tag {
  margin-top: 14px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13.5px;
  font-weight: 600;
  color: #854d0e;
  background: #fef9c3;
  padding: 4px 12px;
  border-radius: 20px;
  border: 1px solid #fef08a;
}

.yellow-dot-blinking {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #eab308;
  box-shadow: 0 0 0 2px rgba(234, 179, 8, 0.3);
  animation: pulseYellow 0.7s infinite alternate;
  display: inline-block;
  flex-shrink: 0;
}

@keyframes pulseYellow {
  0% { transform: scale(0.8); opacity: 0.5; }
  100% { transform: scale(1.3); opacity: 1; }
}

.process-card.completed-step .step-status-tag {
  color: #15803d;
  background: #dcfce7;
  border-color: #bbf7d0;
}

.process-safe {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 28px;
  color: #6b7484;
}
.process-safe b {
  display: block;
  color: #2f3745;
  font-size: 18px;
  margin-bottom: 12px;
}

/* ===== PAYWALL (TELA FINAL DO PIX 100% FIEL AO PRINT DE REFERÊNCIA) ===== */
body.screen-paywall,
.paywall-screen {
  background: #f3f6fb !important;
  padding: 0 0 60px !important;
  min-height: 100vh !important;
}

.paywall-screen .page-container {
  max-width: 860px !important;
  margin: 0 auto !important;
  padding: 0 16px !important;
}

.payment-timer-bar {
  height: 48px !important;
  background: #c91c1c !important;
  color: #ffffff !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 10px !important;
  font-size: 15px !important;
  font-weight: 700 !important;
  margin-bottom: 24px !important;
  width: 100% !important;
  box-shadow: 0 2px 6px rgba(201, 28, 28, 0.25) !important;
}

.checkout-summary {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 12px !important;
  padding: 22px 28px !important;
  display: grid !important;
  grid-template-columns: repeat(3, 1fr) !important;
  gap: 16px 24px !important;
  margin-bottom: 24px !important;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03) !important;
}

.summary-item {
  display: flex !important;
  flex-direction: column !important;
  gap: 4px !important;
  text-align: left !important;
}

.summary-item span {
  font-size: 13px !important;
  color: #64748b !important;
  font-weight: 500 !important;
}

.summary-item b {
  font-size: 15px !important;
  color: #1e293b !important;
  font-weight: 700 !important;
  word-break: break-word !important;
}

#paySummaryMulta {
  color: #2563eb !important;
}

#paySummaryValue {
  color: #16a34a !important;
  font-size: 20px !important;
  font-weight: 800 !important;
}

.summary-due-date,
#paySummaryDueDate {
  color: #dc2626 !important;
  font-weight: 700 !important;
}

.status-pill.pending {
  color: #d97706 !important;
  background: transparent !important;
  padding: 0 !important;
  font-weight: 700 !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  font-size: 15px !important;
}

.status-pill.pending .status-dot {
  width: 8px !important;
  height: 8px !important;
  border-radius: 50% !important;
  background: #f97316 !important;
  box-shadow: 0 0 0 2px rgba(249, 115, 22, 0.3) !important;
  display: inline-block !important;
  animation: pulseOrange 0.8s ease-in-out infinite alternate !important;
}

@keyframes pulseOrange {
  0% { transform: scale(0.85); opacity: 0.5; }
  100% { transform: scale(1.35); opacity: 1; }
}

.pix-card {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 14px !important;
  padding: 36px 40px !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.03) !important;
  text-align: center !important;
}

.pix-card h1 {
  margin: 0 0 6px !important;
  font-size: 22px !important;
  font-weight: 700 !important;
  color: #0f172a !important;
}

.pix-card > p {
  margin: 0 0 24px !important;
  color: #64748b !important;
  font-size: 14px !important;
}

.qr-frame {
  width: 210px !important;
  height: 210px !important;
  margin: 0 auto 26px !important;
  background: #eef2f6 !important;
  border-radius: 14px !important;
  padding: 14px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  position: relative !important;
}

.qr-frame img,
.qr-frame canvas,
.generated-local-qr img,
.generated-local-qr canvas,
.external-qr-img {
  width: 185px !important;
  height: 185px !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: contain !important;
  border-radius: 6px !important;
  display: block !important;
}

#qrPlaceholder,
.qr-frame .hidden {
  display: none !important;
}

.checkout-link,
.checkout-link.hidden {
  display: none !important;
}

.pix-card label {
  display: block !important;
  text-align: left !important;
  font-size: 13.5px !important;
  font-weight: 600 !important;
  color: #475569 !important;
  margin-bottom: 6px !important;
}

.pix-copy-row {
  display: flex !important;
  align-items: center !important;
  background: #f1f5f9 !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 8px !important;
  padding: 6px 14px !important;
  margin-bottom: 24px !important;
}

.pix-copy-row input {
  flex: 1 !important;
  border: none !important;
  background: transparent !important;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace !important;
  font-size: 13px !important;
  color: #334155 !important;
  outline: none !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  height: 36px !important;
}

.pix-copy-row button {
  border: none !important;
  background: transparent !important;
  color: #64748b !important;
  cursor: pointer !important;
  padding: 6px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: color 0.2s !important;
}

.pix-copy-row button:hover {
  color: #2563eb !important;
}

.howto {
  text-align: left !important;
  background: #fffbeb !important;
  border: 1px solid #fef08a !important;
  border-radius: 10px !important;
  padding: 18px 22px !important;
  margin-bottom: 28px !important;
}

.howto b {
  display: block !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  color: #b45309 !important;
  margin-bottom: 10px !important;
}

.howto ol {
  margin: 0 !important;
  padding-left: 20px !important;
  color: #b45309 !important;
  font-size: 13.5px !important;
  line-height: 1.65 !important;
}

.howto li {
  margin-bottom: 3px !important;
}

.pay-actions {
  display: grid !important;
  grid-template-columns: 1fr 1fr 1.3fr !important;
  gap: 12px !important;
  margin-bottom: 20px !important;
}

.pay-actions button {
  height: 44px !important;
  border-radius: 8px !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  border: none !important;
  transition: all 0.2s ease !important;
}

.pay-actions .secondary {
  background: #f1f5f9 !important;
  color: #475569 !important;
}

.pay-actions .secondary:hover {
  background: #e2e8f0 !important;
  color: #1e293b !important;
}

.pay-actions .primary {
  background: #2563eb !important;
  color: #ffffff !important;
}

.pay-actions .primary:hover {
  background: #1d4ed8 !important;
}

.payment-feedback {
  text-align: center !important;
  font-size: 13px !important;
  color: #64748b !important;
  margin-top: 16px !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 4px !important;
}

.payment-feedback p {
  font-size: 13px;
}

/* ===== RESPONSIVIDADE ===== */
@media (max-width: 768px) {
  /* Impede qualquer scroll horizontal no mobile */
  html, body {
    overflow-x: hidden !important;
    max-width: 100vw !important;
  }

  .topbar {
    padding: 0;
    height: 56px !important;
    width: 100% !important;
    max-width: 100vw !important;
  }
  .header-container {
    padding: 0 12px !important;
    max-width: 100% !important;
    overflow: hidden !important;
  }
  .brand {
    flex-shrink: 1 !important;
    min-width: 0 !important;
    gap: 8px !important;
  }
  .brand-text {
    display: block !important;
    padding-left: 8px !important;
    border-left: 1px solid #e5e9f2 !important;
    min-width: 0 !important;
    overflow: hidden !important;
  }
  .brand-text strong {
    font-size: 9.5px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    display: block !important;
  }
  .brand-text small {
    font-size: 8px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    display: block !important;
  }
  .logo-slot img {
    max-height: 28px !important;
    height: 28px !important;
  }
  .user-header {
    gap: 8px !important;
    min-width: 0 !important;
    flex-shrink: 1 !important;
    overflow: hidden !important;
  }
  .user-meta {
    min-width: 0 !important;
    overflow: hidden !important;
  }
  .user-meta strong {
    font-size: 12.5px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    max-width: 140px !important;
  }
  .user-meta small {
    font-size: 11px !important;
  }
  .avatar {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    min-height: 34px !important;
    font-size: 13px !important;
    flex-shrink: 0 !important;
  }
  .bell {
    display: flex !important;
    flex-shrink: 0 !important;
  }
  .bell svg {
    width: 20px !important;
    height: 20px !important;
  }

  /* Breadcrumb: parar de usar 100vw que causa scroll horizontal */
  .breadcrumb {
    width: 100% !important;
    left: 0 !important;
    right: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    margin-bottom: 16px !important;
    padding: 0 12px !important;
    height: 38px !important;
    font-size: 12px !important;
    transform: none !important;
  }

  /* Page container: centraliza conteúdo sem flex que quebra filhos */
  .page-container {
    max-width: 100% !important;
    width: 100% !important;
    padding: 0 12px !important;
    margin: 0 auto !important;
    box-sizing: border-box !important;
  }

  /* Consult shell: centraliza o formulário */
  .consult-shell {
    max-width: 100% !important;
    padding: 0 12px !important;
    margin: 0 auto !important;
  }

  .consult-card,
  .loading-card {
    max-width: 100% !important;
    width: 100% !important;
    margin: 20px auto 12px !important;
    padding: 24px 16px !important;
    box-sizing: border-box !important;
  }

  .steps {
    grid-template-columns: 1fr;
    gap: 8px;
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 auto !important;
    box-sizing: border-box !important;
  }

  .security-note {
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 auto 12px !important;
    box-sizing: border-box !important;
  }

  /* Resultado / Infração */
  .result-wrap {
    padding: 0 !important;
    margin: 0 auto !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }
  .infraction-card {
    margin: 0 auto !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .infraction-row {
    grid-template-columns: 1fr 1fr;
    gap: 4px 12px;
  }
  .infraction-row .label { font-size: 11px; }
  .infraction-row .value b { font-size: 13px; }

  /* Confirmação de dados (Infração) */
  .condutor-info-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 8px 12px !important;
  }
  .grid-divider {
    grid-column: span 2 !important;
  }
  .info-label {
    font-size: 9px !important;
  }
  .info-value {
    font-size: 12.5px !important;
  }

  /* Detalhes do Pagamento */
  .subcard-grid {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
  }

  .process-cards {
    grid-template-columns: 1fr;
  }

  /* Paywall / PIX */
  .payment-timer-bar {
    font-size: 13.5px !important;
    height: 40px !important;
    margin-bottom: 16px !important;
    padding: 0 12px !important;
    text-align: center !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }
  
  .checkout-summary {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px 14px !important;
    padding: 16px 18px !important;
    margin: 0 auto 16px !important;
    border-radius: 10px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }
  .summary-item b {
    font-size: 13.5px !important;
  }
  #paySummaryValue {
    font-size: 18px !important;
  }

  .pix-card {
    padding: 24px 16px !important;
    border-radius: 12px !important;
    margin: 0 auto !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }
  .pix-card h1 {
    font-size: 19px !important;
  }
  .pix-card > p {
    font-size: 13px !important;
    margin-bottom: 18px !important;
  }

  .qr-frame {
    width: 180px !important;
    height: 180px !important;
    padding: 10px !important;
    margin: 0 auto 20px !important;
  }
  .qr-frame img {
    width: 160px !important;
    height: 160px !important;
  }

  .pix-copy-row {
    padding: 4px 10px !important;
    height: 38px !important;
    margin-bottom: 18px !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }
  .pix-copy-row input {
    font-size: 11px !important;
    height: 32px !important;
    min-width: 0 !important;
  }

  .howto {
    padding: 14px 16px !important;
    margin-bottom: 20px !important;
    border-radius: 8px !important;
    box-sizing: border-box !important;
  }
  .howto b {
    font-size: 13px !important;
    margin-bottom: 6px !important;
  }
  .howto ol {
    padding-left: 18px !important;
    font-size: 12.5px !important;
    line-height: 1.55 !important;
  }

  .pay-actions {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
    margin-bottom: 16px !important;
  }
  .pay-actions button {
    height: 40px !important;
    font-size: 13.5px !important;
  }

  /* Loading screens centralizados */
  .minimal-loader-wrap {
    max-width: 100% !important;
    padding: 20px 16px !important;
    box-sizing: border-box !important;
  }

  /* Infraction details (heavy card) */
  .infraction-details {
    padding: 14px 16px !important;
    box-sizing: border-box !important;
  }
  .details-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 8px 12px !important;
  }

  /* Todas as tabelas e grids no mobile */
  .card {
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  /* Result screen padding */
  .result-screen {
    padding: 16px 0 32px !important;
  }

  /* Infraction card body e grid */
  .infraction-card-header {
    padding: 12px 14px !important;
  }
  .infraction-card-body {
    padding: 14px 14px !important;
    box-sizing: border-box !important;
  }
  .condutor-info-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 8px 12px !important;
  }
  .grid-divider {
    grid-column: span 2 !important;
  }
  .info-value {
    font-size: 12.5px !important;
    word-break: break-word !important;
  }

  /* Subcard detalhes */
  .subcard-detalhes {
    margin-top: 12px !important;
    box-sizing: border-box !important;
  }
  .subcard-body {
    padding: 10px !important;
  }
  .subcard-grid {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
  }
  .subcard-box {
    padding: 8px 10px !important;
  }

  /* Valor regularização faixa */
  .valor-regularizar-faixa {
    padding: 12px 14px !important;
    box-sizing: border-box !important;
  }
  .faixa-label {
    font-size: 10px !important;
  }
  .faixa-valor {
    font-size: 18px !important;
  }

  /* Consequences box */
  .consequences-box {
    margin: 12px 14px !important;
    padding: 12px 14px !important;
    box-sizing: border-box !important;
  }

  /* Botão regularizar */
  .regularizar-btn-principal {
    width: calc(100% - 28px) !important;
    margin: 0 14px 16px !important;
    box-sizing: border-box !important;
  }

  /* Infraction CTA */
  .infraction-cta {
    width: calc(100% - 28px) !important;
    margin: 12px 14px 16px !important;
  }

  /* Notice */
  .notice {
    margin: 0 14px 16px !important;
  }

  /* Detran system card (loaders oficiais) */
  .detran-system-card,
  .payment-system-card {
    max-width: 100% !important;
    margin: 20px 0 16px !important;
    box-sizing: border-box !important;
  }

  /* Checkout summary items */
  .summary-item {
    min-width: 0 !important;
    overflow: hidden !important;
  }
  .summary-item b {
    word-break: break-word !important;
  }

  /* Process wrap (tela de geração PIX) */
  .process-wrap {
    max-width: 100% !important;
    padding: 0 12px !important;
    box-sizing: border-box !important;
  }
  .process-wrap h1 {
    font-size: 20px !important;
  }
  .process-wrap > p {
    font-size: 14px !important;
  }
  .process-wrap > small {
    font-size: 13px !important;
  }
  .process-cards {
    grid-template-columns: 1fr !important;
    gap: 10px !important;
  }
  .process-card {
    padding: 16px 14px !important;
  }
  .process-card h2 {
    font-size: 15px !important;
  }
  .process-card p {
    font-size: 13px !important;
  }
  .process-safe {
    padding: 16px !important;
    box-sizing: border-box !important;
  }
  .process-safe b {
    font-size: 15px !important;
  }
  .process-safe span {
    font-size: 12.5px !important;
  }

  /* Paywall screen */
  .paywall-screen {
    padding: 0 0 32px !important;
  }
  .paywall-screen .page-container {
    max-width: 100% !important;
    padding: 0 12px !important;
    box-sizing: border-box !important;
  }
  .payment-timer-bar {
    width: 100% !important;
    box-sizing: border-box !important;
  }

  /* Payment details screen */
  .payment-details-screen .page-container {
    max-width: 100% !important;
    padding: 0 12px !important;
    box-sizing: border-box !important;
  }

  /* Segurança total: nenhum elemento pode ultrapassar a viewport */
  * {
    max-width: 100vw;
  }
}

@media (max-width: 480px) {
  .topbar { height: 56px !important; }
  .screen { min-height: calc(100vh - 56px); }
  .card-head h1 { font-size: 18px; }
  .form button { font-size: 14px; }
  .qr-frame { width: 160px !important; height: 160px !important; }
  .qr-frame img { width: 140px !important; height: 140px !important; }
  .user-meta strong { max-width: 110px !important; }
}

/* ===== NOVOS ESTILOS DO HEAVY (para o card de Confirmação de Dados do Condutor) ===== */
.infraction-details {
  padding: 16px 22px;
  border-bottom: 1px solid #e5e9f2;
  background: #fff;
}

.details-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  color: #854d0e;
  font-size: 14px;
}

.warning-icon {
  font-size: 16px;
}

.infraction-text {
  margin: 0 0 12px 0;
  font-size: 13.5px;
  color: #374151;
  line-height: 1.4;
}

.details-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 20px;
}

.detail-item .label {
  font-size: 10px;
  font-weight: 700;
  color: #4b5563;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  display: block;
  margin-bottom: 2px;
}

.detail-item .value {
  font-size: 14px;
  color: #111827;
  font-weight: 600;
}

.status-vencida {
  color: #c53030;
  font-weight: 700;
}

.value-regularizacao {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #e0edff;
  padding: 14px 22px;
  border-bottom: 1px solid #c8d9f0;
}

.value-regularizacao span {
  font-size: 11px;
  color: #1e40af;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.value-regularizacao strong {
  font-size: 26px;
  color: #15803d;
  font-weight: 700;
}

/* Melhorias para ficar mais próximo da referência */
.infraction-card {
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
  border: 1px solid #e5e9f2;
}

.infraction-header {
  padding: 18px 24px 12px;
  background: #f8fafc;
}

.infraction-row {
  gap: 14px 20px;
  padding: 8px 0;
}

.infraction-row .label {
  font-size: 9.5px;
  letter-spacing: 0.5px;
}

.infraction-row .value {
  font-size: 14.5px;
}

.infraction-details {
  background: #f8fafc;
  padding: 16px 24px;
  border-bottom: 1px solid #e5e9f2;
}

.details-header {
  font-size: 13.5px;
  color: #854d0e;
}

.infraction-text {
  font-size: 13px;
  color: #374151;
}

.details-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 24px;
  margin-top: 8px;
}

.detail-item {
  background: #fff;
  padding: 8px 12px;
  border-radius: 6px;
  border: 1px solid #e5e9f2;
}

.detail-item .label {
  font-size: 9.5px;
  color: #4b5563;
  text-transform: uppercase;
  font-weight: 700;
  margin-bottom: 2px;
}

.detail-item .value {
  font-size: 14px;
  color: #111827;
  font-weight: 600;
}

.infraction-warning {
  background: #fefce8;
  border-color: #fde047;
  padding: 16px 24px;
}

.infraction-warning b {
  font-size: 13px;
  color: #854d0e;
}

.infraction-warning ul {
  font-size: 13px;
  color: #854d0e;
}

.infraction-cta {
  height: 50px;
  font-size: 15.5px;
  border-radius: 8px;
  margin: 16px 24px 20px;
  width: calc(100% - 48px);
}

.notice {
  margin: 0 24px 20px;
  font-size: 12px;
}


/* === ETAPA 2 - Ajustes para espelhar a referência === */
.result-title,
.steps.compact,
.notice,
.result-screen .steps,
.result-screen .steps .step,
.infraction-title-main {
  display: none !important;
}

.result-screen {
  background-color: #f4f7fc !important;
  padding: 32px 0 48px !important;
  min-height: calc(100vh - 56px);
}

.result-wrap {
  max-width: 680px !important;
  margin: 0 auto !important;
}

/* Card Principal da Infração */
.infraction-card {
  background: #ffffff !important;
  border: 1px solid #e5e9f2 !important;
  border-radius: 6px !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05) !important;
  overflow: hidden !important;
  width: 100% !important;
  margin: 0 auto !important;
}

/* Cabeçalho do Card */
.infraction-card-header {
  background: #f8fafc !important;
  padding: 12px 20px !important;
  border-bottom: 1px solid #e5e9f2 !important;
}

.infraction-card-header h2 {
  margin: 0;
  font-size: 14.5px;
  font-weight: 700;
  color: #1e293b;
}

/* Corpo do Card */
.infraction-card-body {
  padding: 16px 20px !important;
}

/* Grid de Dados do Condutor */
.condutor-info-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 10px 16px;
  padding: 4px 0 12px;
}

.info-field {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.info-label {
  font-size: 9.5px;
  font-weight: 700;
  color: #64748b;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.info-value {
  font-size: 13.5px;
  font-weight: 600;
  color: #1e293b;
  line-height: 1.3;
}

.status-laranja {
  color: #b45309 !important;
  font-weight: 700 !important;
}

.grid-divider {
  grid-column: span 3;
  height: 1px;
  background-color: #f1f5f9;
  margin: 6px 0;
}

/* Seção de Detalhes (Subcard) */
.subcard-detalhes {
  border: 1px solid #e5e9f2;
  border-radius: 6px;
  overflow: hidden;
  margin-top: 16px;
  background: #ffffff;
}

.subcard-header {
  background: #fffbeb;
  border-bottom: 1px solid #fde047;
  padding: 8px 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  color: #b45309;
}

.warning-svg {
  width: 14px;
  height: 14px;
  color: #d97706;
}

.subcard-header span {
  font-size: 12.5px;
  font-weight: 700;
}

.subcard-body {
  padding: 12px;
}

.subcard-desc {
  margin: 0 0 10px 0;
  font-size: 12.5px;
  color: #4b5563;
}

.subcard-desc strong {
  color: #111827;
  font-weight: 700;
}

.subcard-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.subcard-box {
  background: #f8fafc;
  border: 1px solid #e5e9f2;
  border-radius: 6px;
  padding: 8px 12px;
}

.box-row {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 4px 0;
}

.border-top-sutil {
  border-top: 1px solid #f1f5f9;
  padding-top: 6px;
  margin-top: 4px;
}

.box-label {
  font-size: 9.5px;
  font-weight: 600;
  color: #64748b;
}

.box-value {
  font-size: 12.5px;
  font-weight: 600;
  color: #1e293b;
}

/* Faixa do Valor de Regularização */
.valor-regularizar-faixa {
  background: #eff6ff;
  border-top: 1px solid #bfdbfe;
  border-bottom: 1px solid #bfdbfe;
  padding: 12px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 8px;
}

.faixa-label {
  font-size: 11px;
  font-weight: 700;
  color: #1d4ed8;
  letter-spacing: 0.5px;
}

.faixa-valor {
  font-size: 20px;
  font-weight: 800;
  color: #1e293b;
}

/* Caixa de Consequências do Não Pagamento */
.consequences-box {
  background: #fffbeb;
  border: 1px solid #fef3c7;
  border-radius: 6px;
  padding: 14px 18px;
  margin: 16px 20px;
}

.consequences-box h3 {
  margin: 0 0 6px 0;
  font-size: 13px;
  font-weight: 700;
  color: #b45309;
}

.consequences-box ul {
  margin: 0;
  padding-left: 18px;
  color: #b45309;
  font-size: 12.5px;
  line-height: 1.5;
}

.consequences-box li {
  margin-bottom: 3px;
}

/* Botão Regularizar */
.regularizar-btn-principal {
  display: block;
  width: calc(100% - 40px);
  margin: 0 auto 20px;
  background: #2563eb;
  color: #ffffff;
  border: none;
  border-radius: 6px;
  height: 46px;
  font-size: 14.5px;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.2s;
}

.regularizar-btn-principal:hover {
  background: #1d4ed8;
}

/* ===== SISTEMA OFICIAL DETRAN — ESTILOS DE CARREGAMENTO ===== */

.detran-system-card,
.payment-system-card {
  max-width: 580px;
  margin: 40px auto 24px;
  border-radius: 8px;
  border: 1px solid #cbd5e1;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.06);
  background: #ffffff;
  overflow: hidden;
}

.detran-card-header {
  background: #0f172a;
  color: #ffffff;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  border-bottom: 3px solid #1d4ed8;
  text-align: left;
}

.gov-flag-icon {
  width: 36px;
  height: 36px;
  border-radius: 6px;
  background: #1e293b;
  border: 1px solid #334155;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #3b82f6;
  flex-shrink: 0;
}

.detran-card-header h1 {
  margin: 0;
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: 0.6px;
  color: #f8fafc;
  text-transform: uppercase;
}

.detran-card-header .protocol-text {
  margin: 2px 0 0;
  font-size: 11.5px;
  color: #94a3b8;
}

.detran-card-header .protocol-text strong {
  color: #60a5fa;
  font-weight: 600;
}

/* Spinner Oficial DETRAN */
.official-spinner-wrapper {
  position: relative;
  width: 56px;
  height: 56px;
  margin: 10px auto 20px;
}

.official-spinner {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 3px solid #e2e8f0;
  border-top-color: #1d4ed8;
  border-right-color: #2563eb;
  animation: spinOfficial 0.8s linear infinite;
}

@keyframes spinOfficial {
  to { transform: rotate(360deg); }
}

/* Barra de Progresso Oficial */
.system-progress-container {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  padding: 12px 16px;
  margin-bottom: 20px;
}

.system-progress-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.system-progress-label {
  font-size: 11px;
  font-weight: 700;
  color: #475569;
  letter-spacing: 0.5px;
}

.system-progress-percent {
  font-size: 14px;
  font-weight: 800;
  color: #1d4ed8;
  font-family: monospace;
}

.system-progress-bar {
  height: 6px;
  background: #e2e8f0;
  border-radius: 99px;
  overflow: hidden;
}

.system-progress-fill {
  height: 100%;
  width: 0%;
  background: #1d4ed8;
  border-radius: 99px;
  transition: width 0.25s linear;
}

/* Status Titulo */
.status-live-container h2 {
  font-size: 15.5px;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 4px;
}

.status-live-container p {
  font-size: 13px;
  color: #64748b;
  margin: 0 0 18px;
}

/* Caixa de Etapas Oficial */
.official-steps-box {
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 18px;
  text-align: left;
}

.steps-box-header {
  background: #f1f5f9;
  padding: 8px 14px;
  font-size: 10.5px;
  font-weight: 700;
  color: #475569;
  letter-spacing: 0.6px;
  border-bottom: 1px solid #e2e8f0;
}

.official-steps-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.official-step-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-bottom: 1px solid #f1f5f9;
  font-size: 12.5px;
  color: #64748b;
  transition: all 0.2s ease;
}

.official-step-item:last-child {
  border-bottom: none;
}

.step-indicator {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #e2e8f0;
  color: #475569;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.step-desc {
  flex-grow: 1;
}

.step-status {
  font-size: 10.5px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 4px;
  background: #f1f5f9;
  color: #64748b;
  letter-spacing: 0.4px;
}

.official-step-item.active {
  background: #eff6ff;
  color: #1e40af;
  font-weight: 600;
}

.official-step-item.active .step-indicator {
  background: #1d4ed8;
  color: #ffffff;
}

.official-step-item.active .step-status {
  background: #dbeafe;
  color: #1e40af;
}

.official-step-item.completed {
  background: #ffffff;
  color: #15803d;
}

.official-step-item.completed .step-indicator {
  background: #16a34a;
  color: #ffffff;
}

.official-step-item.completed .step-status {
  background: #dcfce7;
  color: #15803d;
}

.detran-footer-note {
  font-size: 11px;
  color: #94a3b8;
  padding-top: 10px;
  border-top: 1px solid #f1f5f9;
}

/* Processamento PIX Oficial */
.official-payment-title {
  font-size: 16px;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 4px;
}

.official-payment-sub {
  font-size: 13px;
  color: #64748b;
  margin: 0 0 18px;
}

.official-process-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: left;
  margin-top: 16px;
}

.official-process-item {
  display: flex;
  align-items: center;
  gap: 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  padding: 12px 16px;
  transition: all 0.2s ease;
}

.process-num {
  font-size: 13px;
  font-weight: 800;
  color: #94a3b8;
  font-family: monospace;
}

.process-info {
  flex-grow: 1;
}

.process-info strong {
  display: block;
  font-size: 13px;
  color: #1e293b;
}

.process-info span {
  display: block;
  font-size: 11.5px;
  color: #64748b;
}

.process-state-badge {
  font-size: 10.5px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  background: #e2e8f0;
  color: #64748b;
}

.official-process-item.active-step {
  border-color: #3b82f6;
  background: #eff6ff;
}
.official-process-item.active-step .process-num {
  color: #1d4ed8;
}
.official-process-item.active-step .process-state-badge {
  background: #dbeafe;
  color: #1e40af;
}

.official-process-item.completed-step {
  border-color: #bbf7d0;
  background: #f0fdf4;
}
.official-process-item.completed-step .process-num {
  color: #16a34a;
}
.official-process-item.completed-step .process-state-badge {
  background: #dcfce7;
  color: #15803d;
}

/* ===== LOADER MINIMALISTA CENTRO DA TELA (Imagem 1) ===== */
.loading-screen.active,
.payment-loading-screen.active {
  background: #ffffff !important;
  background-image: none !important;
  min-height: calc(100vh - 70px) !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: flex-start !important;
  padding-top: 90px !important;
  margin: 0 !important;
}

.loading-screen.active .page-container,
.payment-loading-screen.active .page-container {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.minimal-loader-wrap {
  max-width: 480px;
  width: 100%;
  margin: 0 auto;
  text-align: center;
  padding: 20px;
}

.clean-blue-spinner {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, rgba(37, 99, 235, 0) 0%, rgba(37, 99, 235, 0.15) 25%, rgba(37, 99, 235, 0.65) 70%, #2563eb 100%);
  mask: radial-gradient(farthest-side, transparent calc(100% - 5px), #000 0);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 5px), #000 0);
  animation: smoothConicSpin 0.9s linear infinite;
  margin: 0 auto;
}

@keyframes smoothConicSpin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loader-title {
  font-size: 19px;
  font-weight: 500;
  color: #1e293b;
  margin: 20px 0 6px;
}

.loader-sub {
  font-size: 14.5px;
  color: #94a3b8;
  margin: 0;
  font-weight: 400;
}

/* ===== CAIXA DE FRASE ÚNICA COM BOLINHA AZUL PISCANDO ===== */
.loader-phrase-box {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 14px;
  font-size: 14.5px;
  color: #94a3b8;
  font-weight: 400;
  text-align: center;
}

.phrase-dot-blinking {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #2563eb;
  position: relative;
  display: inline-block;
  flex-shrink: 0;
  box-shadow: 0 0 8px rgba(37, 99, 235, 0.5);
  margin-right: 2px;
}

.phrase-dot-blinking::after {
  content: '';
  position: absolute;
  top: -3px;
  left: -3px;
  right: -3px;
  bottom: -3px;
  border-radius: 50%;
  border: 1.5px solid rgba(37, 99, 235, 0.6);
  animation: liveRipple 1.6s ease-out infinite;
}

@keyframes liveRipple {
  0% { transform: scale(0.7); opacity: 1; }
  100% { transform: scale(1.8); opacity: 0; }
}

/* Estilo de Link Azul Permanente para Termos em Destaque */
.phrase-link,
.loader-phrase-box a {
  color: #2563eb !important;
  text-decoration: underline !important;
  font-weight: 700 !important;
  cursor: pointer;
}

/* Transição Suave de Desaparecimento e Entrada das Frases */
.loader-phrase-box .phrase-text {
  display: inline-block;
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.25s cubic-bezier(0.4, 0, 0.2, 1), transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.loader-phrase-box .phrase-text.phrase-fade-out {
  opacity: 0;
  transform: translateY(-6px);
}

/* ===== DETALHES DO PAGAMENTO (Imagem 3) ===== */
.payment-details-screen {
  background: #f4f7fc;
  padding: 40px 0;
}

.subcard-header-clean {
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 700;
  color: #334155;
}

.composicao-body {
  padding: 14px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.composicao-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13.5px;
  color: #475569;
}

.composicao-row strong {
  color: #1e293b;
  font-weight: 600;
}

.composicao-row.total-row {
  border-top: 1px solid #e2e8f0;
  padding-top: 10px;
  margin-top: 4px;
}

.composicao-row.total-row strong {
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
}

.composicao-row.total-row .total-val {
  font-size: 17px;
  font-weight: 800;
  color: #0f172a;
}

.yellow-atencao-box {
  background: #fffbeb;
  border: 1px solid #fef08a;
}

.doc-code-footer {
  text-align: center;
  font-size: 12px;
  color: #94a3b8;
  margin-top: 14px;
  margin-bottom: 24px;
}

/* ===== TEMA ESCURO (DARK MODE) ===== */
body.dark-theme,
body.dark-theme .screen,
body.dark-theme .result-screen,
body.dark-theme .paywall-screen,
body.dark-theme .payment-details-screen {
  background-color: #0f172a !important;
  color: #e2e8f0 !important;
}

body.dark-theme .topbar,
body.dark-theme .card,
body.dark-theme .consult-card,
body.dark-theme .loading-card,
body.dark-theme .infraction-card,
body.dark-theme .infraction-card-header,
body.dark-theme .subcard-detalhes,
body.dark-theme .subcard-box,
body.dark-theme .process-card,
body.dark-theme .process-safe,
body.dark-theme .pix-card,
body.dark-theme .breadcrumb,
body.dark-theme .official-process-item,
body.dark-theme .detran-system-card,
body.dark-theme .payment-system-card,
body.dark-theme .detran-card-header,
body.dark-theme .infraction-details,
body.dark-theme .detail-item {
  background-color: #1e293b !important;
  border-color: #334155 !important;
  color: #f1f5f9 !important;
}

body.dark-theme .card-head h1,
body.dark-theme .brand-text strong,
body.dark-theme .user-meta strong,
body.dark-theme .info-value,
body.dark-theme .box-value,
body.dark-theme .faixa-valor,
body.dark-theme .loader-title,
body.dark-theme .process-wrap h1,
body.dark-theme .pix-card h1,
body.dark-theme .detran-card-header h1,
body.dark-theme .official-payment-title,
body.dark-theme .summary-item b,
body.dark-theme .infraction-card-header h2,
body.dark-theme .detail-item .value {
  color: #f8fafc !important;
}

body.dark-theme .card-head p,
body.dark-theme .brand-text small,
body.dark-theme .user-meta small,
body.dark-theme .info-label,
body.dark-theme .box-label,
body.dark-theme .faixa-label,
body.dark-theme .loader-sub,
body.dark-theme .process-wrap > p,
body.dark-theme .process-wrap > small,
body.dark-theme .howto b,
body.dark-theme .payment-feedback,
body.dark-theme .step-desc span,
body.dark-theme .detail-item .label,
body.dark-theme .infraction-text {
  color: #94a3b8 !important;
}

body.dark-theme input {
  background-color: #0f172a !important;
  border-color: #334155 !important;
  color: #f8fafc !important;
}

body.dark-theme .valor-regularizar-faixa,
body.dark-theme .official-step-item.active {
  background-color: #0f2942 !important;
  border-color: #0c3e60 !important;
}
body.dark-theme .faixa-valor { color: #38bdf8 !important; }
body.dark-theme .faixa-label { color: #7dd3fc !important; }

body.dark-theme .consequences-box,
body.dark-theme .subcard-header,
body.dark-theme .infraction-warning {
  background-color: #422006 !important;
  border-color: #78350f !important;
  color: #fde047 !important;
}
body.dark-theme .consequences-box h3,
body.dark-theme .consequences-box ul,
body.dark-theme .subcard-header span,
body.dark-theme .infraction-warning b,
body.dark-theme .infraction-warning ul {
  color: #fef08a !important;
}

body.dark-theme .step-status-tag {
  background: #422006 !important;
  border-color: #78350f !important;
  color: #fde047 !important;
}

body.dark-theme .grid-divider,
body.dark-theme .border-top-sutil,
body.dark-theme .infraction-row {
  background-color: #334155 !important;
  border-color: #334155 !important;
}

body.dark-theme .pix-copy-row {
  background: #0f172a !important;
  border-color: #334155 !important;
}
body.dark-theme .pix-copy-row input {
  color: #cbd5e1 !important;
}

body.dark-theme .step-status {
  background: #334155 !important;
  color: #94a3b8 !important;
}
body.dark-theme .official-step-item.active .step-status {
  background: #0ea5e9 !important;
  color: #f0f9ff !important;
}
body.dark-theme .official-step-item.completed {
  background: #1e293b !important;
  color: #4ade80 !important;
}

/* Fixes extras para Dark Mode na tabela PIX e checkout */
body.dark-theme .composicao-row strong { color: #f8fafc !important; }
body.dark-theme .composicao-row.total-row { border-top-color: #334155 !important; }
body.dark-theme .composicao-row.total-row strong { color: #f1f5f9 !important; }
body.dark-theme .composicao-row.total-row .total-val { color: #f8fafc !important; }
body.dark-theme .checkout-summary { border-color: #334155 !important; }

/* Botão Tema */
body.dark-theme .theme-toggle-btn { color: #94a3b8 !important; }
body.dark-theme .theme-toggle-btn:hover { background: #334155 !important; color: #f8fafc !important; }
