/* GUARDIANA Comunicaciones on the phone — the named components of the committee's spec
   (18 Oct 2026), written so the native apps can copy them one to one: every piece is a class
   with the `gc-` prefix, its sizes in px, its colours from the tokens below. componentes.js
   holds the little behaviour they need (the sheet, the gestures, the voice-note player, the
   keyboard). Dark identity only, the program's palette name for name (diseno.css): neutrals and
   one steel accent; red only for hanging up and for a confirmed problem, amber for attention,
   green for what was verified. No stickers, no reactions, no typing banners. */
:root {
  --gc-fondo: #06080C; --gc-tinta: #E8ECF1; --gc-suave: #A9B3BE; --gc-suave-2: #6F7B88;
  --gc-tarjeta: #0C1118; --gc-linea: #1E2631; --gc-campo: #10161E;
  --gc-acero: #9CC3E4; --gc-acero-tinta: #06080C;
  --gc-mia-fondo: rgba(156, 195, 228, .18); --gc-mia-borde: rgba(156, 195, 228, .35);
  --gc-suya-fondo: #0C1118; --gc-suya-borde: #1E2631;
  --gc-ok: #6CCBA5; --gc-aviso: #E0B66A; --gc-alerta: #E07A6C;
  --gc-texto: 'IBM Plex Sans', system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --gc-mono: 'IBM Plex Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  /* What the keyboard covers (componentes.js, where the browser does not resize by itself). */
  --gc-teclado: 0px;
  color-scheme: dark;
}
/* Every icon of these components: a 1.8 px stroke of the current colour (play and pause are filled). */
[class^="gc-"] svg, [class*=" gc-"] svg {
  fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}

/* ---------- Header: 56–60 px + the safe area ----------
   ‹ · avatar 36 with the initial · name · steel 12 px trust line · call · 16 px shield. */
.gc-cabecera {
  display: flex; align-items: center; gap: 6px; flex: none;
  min-height: 58px; padding: env(safe-area-inset-top) 8px 0 4px; box-sizing: content-box;
  background: var(--gc-fondo); border-bottom: 1px solid var(--gc-linea); color: var(--gc-tinta);
}
.gc-atras, .gc-cab-boton {
  appearance: none; border: 0; background: transparent; color: var(--gc-tinta);
  width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; flex: none;
  cursor: pointer; touch-action: manipulation; padding: 0;
}
.gc-atras svg { width: 24px; height: 24px; }
.gc-cab-boton svg { width: 22px; height: 22px; }
.gc-cab-boton:disabled { opacity: .35; }
.gc-avatar {
  width: 36px; height: 36px; border-radius: 50%; flex: none; display: grid; place-items: center;
  background: #142231; color: var(--gc-acero); font: 600 15px/1 var(--gc-texto);
}
.gc-quien { flex: 1; min-width: 0; display: grid; gap: 1px; }
.gc-nombre { font: 600 16px/1.25 var(--gc-texto); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* The whole trust line is read, never cut: two lines when the name leaves no room for one. */
.gc-confianza { font: 400 12px/1.25 var(--gc-texto); color: var(--gc-acero); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.gc-confianza.gc-sin-verificar { color: var(--gc-aviso); }
.gc-escudo-boton { width: 32px; height: 44px; color: var(--gc-acero); }
.gc-escudo-boton svg { width: 16px; height: 16px; }

/* ---------- The list of messages ---------- */
.gc-mensajes {
  list-style: none; margin: 0; padding: 12px 12px 8px; flex: 1; min-height: 0; overflow-y: auto;
  display: flex; flex-direction: column; -webkit-overflow-scrolling: touch; overscroll-behavior: contain;
}
.gc-mensajes > li { margin-top: 10px; }
.gc-mensajes > li:first-child { margin-top: 0; }
.gc-mensajes > li.gc-sigue { margin-top: 2px; }
.gc-fecha {
  align-self: center; margin: 16px 0 4px !important; padding: 3px 10px; border-radius: 999px;
  border: 1px solid var(--gc-linea); color: var(--gc-suave); font: 500 12px/1.4 var(--gc-texto);
}
.gc-nota-sistema { align-self: center; max-width: 92%; text-align: center; color: var(--gc-suave); font: 400 12.5px/1.45 var(--gc-texto); }
.gc-linea-llamada {
  align-self: center; display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px;
  border: 1px solid var(--gc-linea); border-radius: 999px; color: var(--gc-suave); font: 400 13px/1.4 var(--gc-texto);
}
.gc-linea-llamada svg { width: 14px; height: 14px; }

/* ---------- Bubbles: own on the right (steel 18 % fill, steel 35 % border), the other
   person's on the left (#0C1118); at most 82 % wide, radius 16, 15 px, the time inside. ---------- */
.gc-burbuja {
  position: relative; max-width: 82%; padding: 7px 10px 6px 12px; border-radius: 16px;
  font: 400 15px/1.4 var(--gc-texto); color: var(--gc-tinta); overflow-wrap: anywhere;
  -webkit-user-select: none; user-select: none; -webkit-touch-callout: none;
  transition: transform .18s ease-out;
}
.gc-burbuja.gc-mia { align-self: flex-end; background: var(--gc-mia-fondo); border: 1px solid var(--gc-mia-borde); }
.gc-burbuja.gc-suya { align-self: flex-start; background: var(--gc-suya-fondo); border: 1px solid var(--gc-suya-borde); }
.gc-burbuja.gc-mia.gc-sigue { border-top-right-radius: 6px; }
.gc-burbuja.gc-suya.gc-sigue { border-top-left-radius: 6px; }
.gc-burbuja .gc-texto { white-space: pre-wrap; }
.gc-burbuja a { color: var(--gc-acero); }
/* The time sits inside, after the text, right-aligned; a space keeps it off the last word. */
.gc-meta {
  float: right; margin: 6px 0 -2px 10px; display: inline-flex; align-items: center; gap: 3px;
  font: 400 11px/1 var(--gc-mono); color: var(--gc-suave); white-space: nowrap;
}
.gc-burbuja::after { content: ""; display: block; clear: both; }
/* Ticks in steel, never blue: one sent, two delivered, two filled seen. */
.gc-ticks { display: inline-block; width: 16px; height: 11px; color: var(--gc-acero); }
.gc-ticks.gc-pendiente { color: var(--gc-suave-2); }
.gc-ticks svg { width: 16px; height: 11px; stroke-width: 1.6; }
.gc-burbuja .gc-de { display: block; font: 600 12px/1.3 var(--gc-texto); color: var(--gc-acero); margin-bottom: 2px; }
.gc-cita {
  display: block; border-left: 2px solid var(--gc-acero); padding: 3px 8px; margin: 1px 0 5px; border-radius: 6px;
  background: rgba(156, 195, 228, .08); color: var(--gc-suave); font-size: 13px; white-space: pre-wrap; max-height: 4.4em; overflow: hidden;
}
.gc-burbuja .gc-borrado { color: var(--gc-suave); font-style: italic; }
.gc-burbuja img, .gc-burbuja video { display: block; max-width: 100%; border-radius: 10px; margin-bottom: 4px; }
.gc-burbuja.gc-elegida { outline: 2px solid var(--gc-acero); outline-offset: 2px; }
/* Swipe to reply: the bubble follows the finger and the reply arrow shows behind it. */
.gc-flecha-respuesta {
  position: absolute; top: 50%; left: -34px; width: 26px; height: 26px; margin-top: -13px; border-radius: 50%;
  display: grid; place-items: center; background: var(--gc-campo); color: var(--gc-acero); opacity: 0; pointer-events: none;
}
.gc-flecha-respuesta svg { width: 15px; height: 15px; }

/* ---------- File card: icon, name, size, a thin progress line ---------- */
.gc-archivo { display: grid; grid-template-columns: 36px 1fr; gap: 2px 10px; align-items: center; min-width: 200px; padding: 2px 0; }
.gc-archivo-icono { grid-row: span 2; width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--gc-campo); color: var(--gc-acero); }
.gc-archivo-icono svg { width: 20px; height: 20px; }
.gc-archivo b { font: 500 14px/1.3 var(--gc-texto); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gc-archivo small { font: 400 12px/1.3 var(--gc-mono); color: var(--gc-suave); }
.gc-progreso { grid-column: 1 / -1; height: 2px; border-radius: 2px; background: var(--gc-linea); overflow: hidden; margin-top: 6px; }
.gc-progreso i { display: block; height: 100%; width: 0; background: var(--gc-acero); transition: width .2s linear; }
.gc-enviando { flex: none; margin: 0 12px 6px; padding: 8px 12px; border: 1px solid var(--gc-linea); border-radius: 12px; background: var(--gc-tarjeta); }

/* ---------- Voice note: play and a waveform ---------- */
.gc-nota { display: flex; align-items: center; gap: 10px; min-width: 220px; padding: 2px 0; }
.gc-nota-play {
  appearance: none; border: 0; width: 36px; height: 36px; border-radius: 50%; flex: none; display: grid; place-items: center;
  background: var(--gc-acero); color: var(--gc-acero-tinta); cursor: pointer; touch-action: manipulation; padding: 0;
}
.gc-nota-play svg { width: 16px; height: 16px; fill: currentColor; stroke: none; }
.gc-nota-play:disabled { opacity: .45; }
.gc-onda { flex: 1; display: flex; align-items: center; gap: 2px; height: 28px; }
.gc-onda i { flex: 1; min-width: 2px; border-radius: 2px; background: var(--gc-suave-2); }
.gc-onda i.gc-oido { background: var(--gc-acero); }
.gc-nota-tiempo { font: 400 11px/1 var(--gc-mono); color: var(--gc-suave); min-width: 30px; text-align: right; }
.gc-nota-etiqueta { display: block; font: 400 11.5px/1.3 var(--gc-texto); color: var(--gc-suave); margin-top: 2px; }

/* ---------- Composer: fixed 56 px over the keyboard + the safe area ----------
   «+» 44 · rounded field · mic or send 44. */
.gc-compositor {
  flex: none; display: flex; align-items: flex-end; gap: 6px;
  min-height: 56px; box-sizing: border-box; padding: 6px 8px calc(6px + env(safe-area-inset-bottom));
  margin-bottom: var(--gc-teclado);
  background: var(--gc-fondo); border-top: 1px solid var(--gc-linea);
}
.gc-redondo {
  appearance: none; width: 44px; height: 44px; border-radius: 50%; flex: none; display: grid; place-items: center;
  border: 0; background: transparent; color: var(--gc-tinta); cursor: pointer; touch-action: manipulation; padding: 0;
}
.gc-redondo svg { width: 22px; height: 22px; }
.gc-redondo.gc-principal { background: var(--gc-acero); color: var(--gc-acero-tinta); }
.gc-redondo.gc-grabando-ya { background: var(--gc-alerta); color: var(--gc-acero-tinta); }
.gc-redondo[hidden] { display: none; }
.gc-campo {
  flex: 1; min-width: 0; min-height: 44px; max-height: 120px; box-sizing: border-box; resize: none; overflow-y: auto;
  padding: 11px 16px; border-radius: 22px; border: 1px solid var(--gc-linea); background: var(--gc-campo);
  color: var(--gc-tinta); font: 400 16px/1.35 var(--gc-texto); -webkit-user-select: text; user-select: text; caret-color: var(--gc-acero);
}
.gc-campo:focus { outline: none; border-color: var(--gc-mia-borde); }
.gc-respondiendo {
  flex: none; display: flex; align-items: center; gap: 8px; margin: 0 8px 6px; padding: 6px 6px 6px 10px;
  border-left: 2px solid var(--gc-acero); border-radius: 8px; background: var(--gc-campo); color: var(--gc-suave); font: 400 13px/1.4 var(--gc-texto);
}
.gc-respondiendo span { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gc-respondiendo button { appearance: none; border: 0; background: transparent; color: var(--gc-suave); width: 32px; height: 32px; font-size: 20px; line-height: 1; }

/* ---------- Bottom sheet (the shield, the «+», a message's choices) ---------- */
.gc-hoja { position: fixed; inset: 0; z-index: 50; display: none; align-items: flex-end; background: rgba(6, 8, 12, .62); }
.gc-hoja.gc-abierta { display: flex; }
.gc-hoja-caja {
  width: 100%; max-height: 86dvh; overflow-y: auto; box-sizing: border-box;
  background: var(--gc-tarjeta); border: 1px solid var(--gc-linea); border-bottom: 0; border-radius: 20px 20px 0 0;
  padding: 8px 16px calc(16px + env(safe-area-inset-bottom)); color: var(--gc-tinta);
  animation: gc-sube .2s ease-out;
}
@keyframes gc-sube { from { transform: translateY(24px); opacity: .6; } }
@media (prefers-reduced-motion: reduce) { .gc-hoja-caja { animation: none; } .gc-burbuja { transition: none; } }
.gc-asa { width: 36px; height: 4px; border-radius: 2px; background: var(--gc-linea); margin: 0 auto 12px; }
.gc-hoja-titulo { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin: 0 0 10px; font: 600 16px/1.3 var(--gc-texto); }
.gc-hoja-titulo small { font: 400 12px/1.3 var(--gc-texto); color: var(--gc-suave); }
/* A sheet's choices: one per row, 52 px, the icon in steel; the dangerous one in red. */
.gc-opcion {
  appearance: none; width: 100%; min-height: 52px; display: flex; align-items: center; gap: 14px; padding: 0 6px;
  border: 0; border-bottom: 1px solid var(--gc-linea); background: transparent; color: var(--gc-tinta);
  font: 400 16px/1.3 var(--gc-texto); text-align: left; cursor: pointer; touch-action: manipulation;
}
.gc-opcion:last-child { border-bottom: 0; }
.gc-opcion svg { width: 20px; height: 20px; color: var(--gc-acero); flex: none; }
.gc-opcion.gc-peligro, .gc-opcion.gc-peligro svg { color: var(--gc-alerta); }
.gc-opcion small { display: block; font-size: 12.5px; color: var(--gc-suave); }
.gc-opcion[hidden] { display: none; }

/* ---------- The shield, live: every line a real check with its time ---------- */
.gc-escudo { list-style: none; margin: 0; padding: 0; }
.gc-escudo li { display: grid; grid-template-columns: 10px 1fr auto; gap: 2px 10px; align-items: start; padding: 10px 0; border-bottom: 1px solid var(--gc-linea); }
.gc-escudo li:last-child { border-bottom: 0; }
.gc-escudo i { width: 8px; height: 8px; border-radius: 50%; margin-top: 6px; background: var(--gc-suave-2); }
.gc-escudo li.gc-ok i { background: var(--gc-ok); }
.gc-escudo li.gc-aviso i { background: var(--gc-aviso); }
.gc-escudo li.gc-alerta i { background: var(--gc-alerta); }
.gc-escudo li.gc-info i { background: var(--gc-acero); }
.gc-escudo b { font: 600 14px/1.35 var(--gc-texto); }
.gc-escudo span { grid-column: 2; font: 400 13px/1.4 var(--gc-texto); color: var(--gc-suave); }
.gc-escudo time { grid-row: 1; grid-column: 3; font: 400 11px/1.6 var(--gc-mono); color: var(--gc-suave-2); }
.gc-limite { margin: 10px 0 0; font: 400 12px/1.45 var(--gc-texto); color: var(--gc-suave); }

/* ---------- The call, full screen ----------
   avatar 96 · name · duration · connection and quality word · Silenciar / Colgar / Altavoz
   (56–64 px) · «Volver al PC». */
.gc-llamada {
  position: fixed; inset: 0; z-index: 40; display: none; flex-direction: column; align-items: center;
  padding: calc(16px + env(safe-area-inset-top)) 24px calc(24px + env(safe-area-inset-bottom));
  background: radial-gradient(120% 70% at 50% 28%, #101A26 0%, var(--gc-fondo) 70%); color: var(--gc-tinta); text-align: center;
}
.gc-llamada.gc-abierta { display: flex; }
.gc-llamada-arriba { align-self: stretch; display: flex; justify-content: space-between; align-items: center; min-height: 44px; }
.gc-llamada-cifrado { display: inline-flex; align-items: center; gap: 6px; font: 400 12px/1.3 var(--gc-texto); color: var(--gc-acero); }
.gc-llamada-cifrado svg { width: 14px; height: 14px; }
.gc-llamada-centro { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; }
.gc-avatar-grande { width: 96px; height: 96px; border-radius: 50%; display: grid; place-items: center; background: #142231; color: var(--gc-acero); font: 600 38px/1 var(--gc-texto); margin-bottom: 8px; }
.gc-llamada-nombre { font: 600 24px/1.25 var(--gc-texto); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gc-llamada-tiempo { font: 400 17px/1.3 var(--gc-mono); color: var(--gc-tinta); font-variant-numeric: tabular-nums; }
.gc-llamada-estado { font: 400 13px/1.45 var(--gc-texto); color: var(--gc-suave); }
.gc-llamada-estado b { font-weight: 600; }
.gc-llamada-estado .gc-excelente, .gc-llamada-estado .gc-buena { color: var(--gc-ok); }
.gc-llamada-estado .gc-debil { color: var(--gc-aviso); }
.gc-llamada-paso { min-height: 20px; font: 400 13px/1.45 var(--gc-texto); color: var(--gc-acero); }
.gc-llamada-paso.gc-fallo { color: var(--gc-aviso); }
.gc-llamada-botones { display: flex; justify-content: center; align-items: flex-start; gap: 28px; margin: 18px 0 14px; }
.gc-llamada-boton { display: grid; justify-items: center; gap: 8px; font: 400 12.5px/1.2 var(--gc-texto); color: var(--gc-suave); }
.gc-llamada-boton button {
  appearance: none; width: 60px; height: 60px; border-radius: 50%; border: 1px solid var(--gc-linea); padding: 0;
  display: grid; place-items: center; background: rgba(232, 236, 241, .06); color: var(--gc-tinta); cursor: pointer; touch-action: manipulation;
}
.gc-llamada-boton button svg { width: 24px; height: 24px; }
.gc-llamada-boton button[aria-pressed="true"] { background: var(--gc-tinta); color: var(--gc-fondo); border-color: var(--gc-tinta); }
.gc-llamada-boton button:disabled { opacity: .4; }
.gc-llamada-boton.gc-colgar button { width: 64px; height: 64px; background: var(--gc-alerta); border-color: var(--gc-alerta); color: var(--gc-fondo); }
.gc-llamada-boton.gc-colgar button svg { width: 28px; height: 28px; }
.gc-texto-boton {
  appearance: none; border: 1px solid var(--gc-linea); background: transparent; color: var(--gc-tinta); min-height: 44px; padding: 0 20px;
  border-radius: 999px; font: 500 14px/1 var(--gc-texto); cursor: pointer; touch-action: manipulation;
}
.gc-texto-boton[hidden] { display: none; }
.gc-entrante .gc-llamada-botones { gap: 64px; }
.gc-entrante .gc-contestar button { width: 64px; height: 64px; background: var(--gc-ok); border-color: var(--gc-ok); color: var(--gc-fondo); }
