/* Atención Globality · páginas públicas (/pqrs, /pqrs/consulta). Primero celular (390 px).
   Foto real en el encabezado, tarjetas por paso, opciones con ícono y la consulta con su avance.
   Íconos del sprite pi-* (admin.shell.sprite). Sin emojis. */
:root {
  --paper: #F5F6FA; --surface: #FFFFFF; --surface-2: #F1F2F7; --line: #E2E4EE; --line-2: #ECEDF3;
  --ink: #0E1230; --fg-2: #3D4361; --muted: #6A7089;
  --green: #0E7F45; --green-2: #0B6A39; --green-soft: #E3F3EA; --green-grad: linear-gradient(135deg, #12965A 0%, #0E7F45 55%, #0B5E7A 130%);
  --red: #B42318; --red-soft: #FDECEA; --amber: #8A4B06; --amber-soft: #FFF3DC; --indigo: #2E3478; --indigo-soft: #E9EAF7;
  --sh-1: 0 1px 2px rgba(14, 18, 48, .05), 0 6px 20px -12px rgba(14, 18, 48, .18);
  --sh-2: 0 14px 34px -18px rgba(14, 18, 48, .35);
  --focus: 0 0 0 3px rgba(14, 127, 69, .3);
  --ff: "Schibsted Grotesk", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --ff-display: "Fraunces", Georgia, serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root { --paper: #0E1121; --surface: #171B30; --surface-2: #1E2340; --line: #2B3155; --line-2: #232846; --ink: #EEF0FA; --fg-2: #C5C9E4; --muted: #9AA0C2;
    --green: #39C27F; --green-2: #5AD496; --green-soft: #133A28; --red: #F27268; --red-soft: #431C1C; --amber: #F6C27F; --amber-soft: #3D2C12; --indigo: #A9AEF5; --indigo-soft: #23284F;
    --sh-1: 0 1px 2px rgba(0, 0, 0, .3); --sh-2: 0 14px 34px -18px rgba(0, 0, 0, .6); color-scheme: dark; }
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--ff); font-size: 16px; line-height: 1.55; -webkit-font-smoothing: antialiased; }
a { color: var(--green); }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: 8px; }
.crm-ico { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; vertical-align: middle; }
.pi-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

/* Barra superior */
.pq-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; max-width: 1100px; margin: 0 auto; }
.pq-brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 800; letter-spacing: -.01em; line-height: 1.1; }
.pq-brand img { width: 34px; height: 34px; border-radius: 10px; }
.pq-brand small { display: block; font-size: 12px; font-weight: 700; color: var(--green); }
.pq-link { display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 14px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); font-weight: 750; font-size: 14px; text-decoration: none; box-shadow: var(--sh-1); }
.pq-link .crm-ico { width: 16px; height: 16px; }

/* Encabezado con foto */
.pq-hero { position: relative; isolation: isolate; overflow: hidden; margin: 0 12px; border-radius: 24px; color: #fff; min-height: 300px; display: flex; align-items: flex-end; box-shadow: var(--sh-2); }
.pq-hero img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; z-index: -2; }
.pq-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(8, 30, 30, .1) 0%, rgba(8, 40, 32, .55) 45%, rgba(6, 28, 26, .92) 100%); }
.pq-hero--plano { min-height: 0; background: var(--green-grad); }
.pq-hero--plano::after { display: none; }
.pq-hero__in { width: 100%; max-width: 760px; margin: 0 auto; padding: 26px 20px 24px; }
.pq-hero .pq-eyebrow { color: #B9F3D3; }
.pq-hero .pq-lead { color: rgba(255, 255, 255, .9); margin-bottom: 0; }
@media (min-width: 900px) {
  .pq-hero { max-width: 1076px; margin: 0 auto; min-height: 360px; }
  .pq-hero::after { background: linear-gradient(100deg, rgba(6, 40, 30, .92) 0%, rgba(8, 50, 38, .7) 45%, rgba(8, 30, 30, .1) 100%); }
  .pq-hero__in { margin: 0; padding: 40px 44px; max-width: 620px; }
}
.pq-eyebrow { font-size: 12.5px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; color: var(--green); }
.pq-eyebrow--oscuro { color: var(--muted); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .02em; }
.pq-h1 { font-family: var(--ff-display); font-style: italic; font-weight: 600; font-size: clamp(30px, 7vw, 46px); line-height: 1.05; margin: 6px 0 10px; letter-spacing: -.02em; }
.pq-lead { color: var(--fg-2); margin: 0 0 20px; font-size: 16.5px; }
.pq-confianza { list-style: none; margin: 16px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.pq-confianza li { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; border-radius: 999px; background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .25); font-size: 13px; font-weight: 700; backdrop-filter: blur(8px); }
.pq-confianza .crm-ico { width: 15px; height: 15px; }

/* Contenido */
.pq-main { max-width: 760px; margin: 0 auto; padding: 18px 16px 48px; }
.pq-card { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 18px; margin-bottom: 16px; box-shadow: var(--sh-1); }
@media (min-width: 620px) { .pq-card { padding: 24px; } }
.pq-card h2 { font-size: 18px; margin: 0; letter-spacing: -.01em; }
.pq-card__head { display: flex; gap: 12px; align-items: center; margin-bottom: 14px; }
.pq-card__head > b { width: 40px; height: 40px; flex: none; border-radius: 13px; display: grid; place-items: center; background: var(--green-grad); color: #fff; font-size: 17px; box-shadow: 0 8px 18px -10px rgba(14, 127, 69, .8); }
.pq-card__head > b .crm-ico { width: 18px; height: 18px; }
.pq-sub { color: var(--muted); font-size: 14px; margin: 2px 0 0; }
.pq-grid { display: grid; gap: 10px; }
@media (min-width: 620px) { .pq-grid--2 { grid-template-columns: 1fr 1fr; } }

/* Opciones con ícono */
.pq-opt { position: relative; display: block; cursor: pointer; }
.pq-opt input { position: absolute; opacity: 0; pointer-events: none; }
.pq-opt > span { display: flex; gap: 12px; align-items: flex-start; height: 100%; padding: 13px 14px; border: 1.5px solid var(--line); border-radius: 16px; background: var(--surface); transition: border-color .15s, background .15s, transform .15s; }
.pq-opt:hover > span { border-color: color-mix(in srgb, var(--green) 45%, var(--line)); }
.pq-opt__ico { width: 38px; height: 38px; flex: none; border-radius: 12px; display: grid; place-items: center; background: var(--surface-2); color: var(--fg-2); font-style: normal; transition: background .15s, color .15s; }
.pq-opt strong { display: block; font-size: 15.5px; line-height: 1.3; }
.pq-opt small { display: block; color: var(--muted); font-size: 13.5px; line-height: 1.4; margin-top: 2px; }
.pq-opt input:checked + span { border-color: var(--green); background: var(--green-soft); }
.pq-opt input:checked + span .pq-opt__ico { background: var(--green); color: #fff; }
.pq-opt input:focus-visible + span { box-shadow: var(--focus); }

.pq-rel { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 6px 0 14px; }
.pq-rel label { position: relative; cursor: pointer; }
.pq-rel input { position: absolute; opacity: 0; pointer-events: none; }
.pq-rel span { display: grid; justify-items: center; gap: 4px; padding: 10px 6px; border: 1.5px solid var(--line); border-radius: 14px; font-size: 13px; font-weight: 700; text-align: center; color: var(--fg-2); }
.pq-rel span .crm-ico { width: 20px; height: 20px; }
.pq-rel input:checked + span { border-color: var(--green); background: var(--green-soft); color: var(--green-2); }
.pq-rel input:focus-visible + span { box-shadow: var(--focus); }
@media (min-width: 620px) { .pq-rel { grid-template-columns: repeat(6, minmax(0, 1fr)); } }

/* Campos */
.pq-field { display: grid; gap: 6px; margin-bottom: 14px; }
.pq-label { font-weight: 700; font-size: 15px; }
.pq-opc { font-weight: 600; font-size: 12.5px; color: var(--muted); margin-left: 4px; }
.pq-hint { color: var(--muted); font-size: 13.5px; margin: 0; }
.pq-input, .pq-select, .pq-textarea { width: 100%; min-height: 52px; padding: 12px 14px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; font-size: 16px; }
.pq-input--mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .03em; text-transform: uppercase; }
.pq-textarea { min-height: 150px; resize: vertical; }
.pq-input:focus, .pq-select:focus, .pq-textarea:focus { outline: none; border-color: var(--green); box-shadow: var(--focus); }
.pq-archivo { position: relative; display: flex; gap: 12px; align-items: center; padding: 14px; border: 1.5px dashed var(--line); border-radius: 16px; cursor: pointer; color: var(--fg-2); margin-bottom: 14px; }
.pq-archivo .crm-ico { width: 22px; height: 22px; color: var(--green); }
.pq-archivo b { display: block; font-size: 14.5px; }
.pq-archivo small { display: block; font-size: 12.5px; color: var(--muted); }
.pq-archivo input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.pq-archivo.is-on { border-style: solid; border-color: var(--green); background: var(--green-soft); }
.pq-check { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; padding: 12px 14px; border-radius: 14px; background: var(--surface-2); }
.pq-check input { margin-top: 4px; width: 18px; height: 18px; accent-color: var(--green); flex: none; }

/* Botones */
.pq-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 56px; padding: 0 22px; border-radius: 16px; border: 0; background: var(--green-grad); color: #fff; font: inherit; font-weight: 800; font-size: 16.5px; cursor: pointer; text-decoration: none; width: 100%; box-shadow: 0 12px 26px -14px rgba(14, 127, 69, .9); transition: transform .15s, box-shadow .15s; }
.pq-btn:hover { transform: translateY(-1px); box-shadow: 0 16px 30px -14px rgba(14, 127, 69, .9); }
.pq-btn.is-busy { opacity: .6; pointer-events: none; }
.pq-enviar { padding: 4px 0 8px; display: grid; gap: 8px; text-align: center; }

/* Avisos */
.pq-alert { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 14px; margin-bottom: 14px; font-size: 15px; }
.pq-alert .crm-ico { margin-top: 2px; }
.pq-alert--err { background: var(--red-soft); color: var(--red); }
.pq-alert--ok { background: var(--green-soft); color: var(--green-2); }
.pq-alert--warn { background: var(--amber-soft); color: var(--amber); }
.pq-alert--info { background: var(--indigo-soft); color: var(--indigo); }

/* Radicada: la boleta */
.pq-listo { text-align: center; padding: 10px 0 6px; }
.pq-listo__ico { width: 76px; height: 76px; margin: 0 auto 6px; border-radius: 50%; display: grid; place-items: center; background: var(--green-grad); color: #fff; box-shadow: 0 0 0 10px var(--green-soft), 0 18px 34px -16px rgba(14, 127, 69, .9); animation: pq-pop .45s cubic-bezier(.2, .9, .3, 1.3); }
.pq-listo__ico .crm-ico { width: 36px; height: 36px; stroke-width: 3; }
@keyframes pq-pop { from { transform: scale(.4); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.pq-boleta { position: relative; background: var(--surface); border-radius: 22px; padding: 20px; margin-bottom: 14px; box-shadow: var(--sh-2); border: 1px solid var(--line); }
.pq-boleta::before, .pq-boleta::after { content: ""; position: absolute; top: 118px; width: 22px; height: 22px; border-radius: 50%; background: var(--paper); }
.pq-boleta::before { left: -11px; } .pq-boleta::after { right: -11px; }
.pq-boleta hr { border: 0; border-top: 2px dashed var(--line); margin: 16px 0; }
.pq-boleta__fila { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 2px 10px; padding: 6px 0; }
.pq-boleta__fila > span { grid-column: 1 / -1; font-size: 12.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.pq-big { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 24px; font-weight: 800; letter-spacing: .02em; overflow-wrap: anywhere; }
.pq-copiar { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); font: inherit; font-size: 13px; font-weight: 750; cursor: pointer; }
.pq-copiar .crm-ico { width: 15px; height: 15px; }
.pq-copiar.is-ok { background: var(--green-soft); border-color: var(--green); color: var(--green-2); }
.pq-kv { display: grid; grid-template-columns: auto 1fr; gap: 8px 14px; font-size: 15px; margin: 0; }
.pq-kv dt { color: var(--muted); }
.pq-kv dd { margin: 0; font-weight: 700; }
.pq-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.pq-steps li { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; }
.pq-steps b { flex: none; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--green-soft); color: var(--green-2); font-size: 13px; }

/* Consulta: estado y avance */
.pq-estado { padding: 6px 2px 4px; }
.pq-pasos { list-style: none; margin: 4px 0 18px; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); position: relative; }
.pq-pasos li { position: relative; display: grid; justify-items: center; gap: 6px; text-align: center; font-size: 12.5px; font-weight: 700; color: var(--muted); }
.pq-pasos li::before { content: ""; position: absolute; top: 17px; left: calc(-50% + 20px); right: calc(50% + 20px); height: 3px; border-radius: 3px; background: var(--line); }
.pq-pasos li:first-child::before { display: none; }
.pq-pasos li span { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); border: 2px solid var(--line); font-weight: 800; position: relative; z-index: 1; }
.pq-pasos li span .crm-ico { width: 17px; height: 17px; stroke-width: 3; }
.pq-pasos li.is-hecho { color: var(--green-2); }
.pq-pasos li.is-hecho span { background: var(--green); border-color: var(--green); color: #fff; }
.pq-pasos li.is-hecho::before, .pq-pasos li.is-ahora::before { background: var(--green); }
.pq-pasos li.is-ahora { color: var(--ink); }
.pq-pasos li.is-ahora span { border-color: var(--green); color: var(--green-2); box-shadow: 0 0 0 5px var(--green-soft); }
.pq-hilo { display: grid; gap: 10px; }
.pq-msg { max-width: 88%; padding: 12px 14px; border-radius: 18px 18px 18px 6px; background: var(--surface-2); white-space: pre-wrap; justify-self: start; font-size: 15px; }
.pq-msg--inst { justify-self: end; border-radius: 18px 18px 6px 18px; background: var(--green-soft); }
.pq-msg small { display: block; color: var(--muted); font-size: 12px; font-weight: 700; margin-bottom: 4px; white-space: normal; }
.pq-msg__file { display: flex; align-items: center; gap: 6px; margin-top: 8px; font-size: 13px; font-weight: 700; color: var(--fg-2); }
.pq-msg__file .crm-ico { width: 15px; height: 15px; }

/* Calificación con estrellas (de derecha a izquierda para pintar las anteriores) */
.pq-stars { display: inline-flex; flex-direction: row-reverse; gap: 4px; }
.pq-stars input { position: absolute; opacity: 0; pointer-events: none; }
.pq-stars label { cursor: pointer; width: 50px; height: 50px; display: grid; place-items: center; border-radius: 14px; color: var(--line); transition: color .12s, transform .12s; }
.pq-stars label .crm-ico { width: 34px; height: 34px; }
.pq-stars label:hover, .pq-stars label:hover ~ label, .pq-stars input:checked ~ label { color: #F59E0B; }
.pq-stars label:hover .crm-ico, .pq-stars label:hover ~ label .crm-ico, .pq-stars input:checked ~ label .crm-ico { fill: #F59E0B; }
.pq-stars input:focus-visible + label { box-shadow: var(--focus); }

.pq-chip { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 13px; font-weight: 800; background: var(--surface-2); vertical-align: middle; }
.pq-chip--ok { background: var(--green-soft); color: var(--green-2); }
.pq-chip--warn { background: var(--amber-soft); color: var(--amber); }
.pq-chip--info { background: var(--indigo-soft); color: var(--indigo); }
.pq-foot { max-width: 760px; margin: 0 auto; padding: 8px 16px 32px; color: var(--muted); font-size: 13px; display: grid; gap: 8px; }
.pq-foot span { display: flex; gap: 8px; align-items: flex-start; }
.pq-foot .crm-ico { width: 15px; height: 15px; margin-top: 3px; }
.pq-hp { position: absolute; left: -5000px; width: 1px; height: 1px; overflow: hidden; }
