/* Mòbil de Laia: estética Android (Material 3) con las apps evocadas del prototipo validado (A12).
   Medidas del prototipo: 390 × 844. En un móvil ocupa toda la pantalla; en un ordenador, un marco. */

:root {
  --uinp-fondo: #0A1128;
  --uinp-panel: #16224A;
  --uinp-borde: #253A7A;
  --uinp-acento: #6C6FC2;
  --uinp-suave: #B9B0E6;
  --uinp-texto: #E9E7F5;
  --xat: #008069;
  --xat-fondo: #EFEAE2;
  --m3-fondo: #F8F9FF;
  --m3-texto: #1B1B1F;
  --m3-sec: #44474F;
  --m3-primario: #445E91;
  --morado: #4A2DA8;
  --ease: cubic-bezier(0.05, 0.7, 0.1, 1);
  color-scheme: light;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; background: #05070F; overflow: hidden; }
body { font-family: 'Roboto', system-ui, sans-serif; color: var(--m3-texto); overscroll-behavior: none; }
button { font: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }

.movil { position: relative; width: 100vw; height: 100dvh; overflow: hidden; background: #000; }
@media (min-width: 560px) and (min-height: 700px) {
  body { display: flex; align-items: center; justify-content: center; }
  .movil { width: 390px; height: min(844px, 96dvh); border-radius: 36px; box-shadow: 0 0 0 10px #1C1D24, 0 24px 60px rgba(0,0,0,0.6); }
}

.pantalla { position: absolute; inset: 0; }
.app { position: absolute; inset: 0; display: flex; flex-direction: column; overflow: hidden; }
.abrir { animation: abrir 380ms var(--ease) both; }
.entrar { animation: entrar 340ms var(--ease) both; }
@keyframes abrir { from { opacity: 0; transform: scale(0.9); } to { opacity: 1; transform: none; } }
@keyframes entrar { from { opacity: 0; transform: translateX(48px); } to { opacity: 1; transform: none; } }
@keyframes caer { from { opacity: 0; transform: translateY(-40px); } to { opacity: 1; transform: none; } }
@keyframes temblar { 0%,100% { transform: translateX(0); } 20% { transform: translateX(-10px); } 40% { transform: translateX(9px); } 60% { transform: translateX(-6px); } 80% { transform: translateX(4px); } }
@media (prefers-reduced-motion: reduce) { .abrir, .entrar, .caer { animation: none !important; } }

.scroll { flex: 1; min-height: 0; overflow-y: auto; scrollbar-width: none; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.scroll::-webkit-scrollbar { display: none; }

/* ── Barras del sistema ─────────────────────────────────────────────────────────────────────────── */

.barra-estado { flex-shrink: 0; height: 32px; padding: 0 20px; display: flex; align-items: center; justify-content: space-between;
  font: 500 14px 'Roboto', sans-serif; color: #FFF; position: relative; z-index: 5; user-select: none; cursor: pointer; }
.barra-estado.oscura { color: var(--m3-texto); }
.barra-estado .lado { display: flex; align-items: center; gap: 7px; }
.barra-estado svg { display: block; }
.bateria { display: flex; align-items: center; gap: 3px; font-size: 12px; }

.barra-nav { flex-shrink: 0; height: 48px; display: grid; grid-template-columns: repeat(3, 1fr); align-items: center; justify-items: center; padding: 0 40px; padding-bottom: env(safe-area-inset-bottom); }
.barra-nav button { width: 64px; height: 40px; border: 0; border-radius: 20px; background: transparent; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.barra-nav button:active { background: rgba(128,128,128,0.25); }

.avisos { position: absolute; left: 10px; right: 10px; top: 36px; z-index: 50; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
.aviso { pointer-events: auto; background: #FFF; border-radius: 20px; box-shadow: 0 4px 14px rgba(0,0,0,0.25); padding: 12px 14px; display: flex; gap: 12px; align-items: flex-start;
  animation: caer 380ms var(--ease) both; cursor: pointer; touch-action: pan-y; transition: transform 200ms, opacity 200ms; }
.aviso .meta { font-size: 12px; color: var(--m3-sec); }
.aviso .titulo { font-size: 15px; font-weight: 500; color: var(--m3-texto); }
.aviso .texto { font-size: 14px; color: var(--m3-texto); overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.aviso.uinp { background: var(--uinp-panel); color: var(--uinp-texto); }
.aviso.uinp .titulo, .aviso.uinp .texto { color: var(--uinp-texto); }
.aviso.uinp .meta { color: var(--uinp-suave); }

.capa { position: absolute; inset: 0; z-index: 60; pointer-events: none; }
.capa.activa { pointer-events: auto; }
.velo { position: absolute; inset: 0; background: rgba(0,0,0,0.45); animation: fundido 250ms both; }
@keyframes fundido { from { opacity: 0; } }
.cortina { position: absolute; left: 0; right: 0; top: 0; max-height: 88%; background: #1C1B20; color: #E6E0E9; border-radius: 0 0 32px 32px; padding: 18px 16px 12px;
  display: flex; flex-direction: column; gap: 12px; animation: bajar 420ms var(--ease) both; }
@keyframes bajar { from { transform: translateY(-100%); } }
.cortina .hora { font-size: 40px; line-height: 1; }
.cortina .fecha { font-size: 14px; color: #CAC4D0; }
.cortina .lista { display: flex; flex-direction: column; gap: 4px; overflow-y: auto; }
.cortina .notif { display: flex; gap: 12px; background: #2B2930; border-radius: 6px; padding: 12px 14px; cursor: pointer; }
.cortina .notif:first-child { border-radius: 20px 20px 6px 6px; }
.cortina .notif:last-child { border-radius: 6px 6px 20px 20px; }
.cortina .notif:only-child { border-radius: 20px; }
.cortina .notif .meta { font-size: 12px; color: #CAC4D0; }
.cortina .notif .titulo { font-size: 14px; font-weight: 500; }
.cortina .notif .texto { font-size: 13px; color: #CAC4D0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cortina .asa { align-self: center; width: 36px; height: 4px; border-radius: 2px; background: #938F99; border: 0; padding: 0; margin: 6px; cursor: pointer; }
.cortina .vacio { color: #CAC4D0; font-size: 14px; padding: 12px 6px; }

.toast { position: absolute; left: 50%; bottom: 72px; transform: translateX(-50%); background: #313033; color: #F4EFF4; font-size: 14px; padding: 12px 18px; border-radius: 8px;
  z-index: 70; animation: fundido 200ms both; max-width: 86%; text-align: center; }

.dialogo { position: absolute; left: 24px; right: 24px; top: 50%; transform: translateY(-50%); background: #ECE6F0; border-radius: 28px; padding: 24px; display: flex; flex-direction: column; gap: 14px; animation: abrir 300ms var(--ease) both; }
.dialogo h2 { margin: 0; font-size: 22px; font-weight: 400; }
.dialogo p { margin: 0; font-size: 14px; color: #49454F; line-height: 1.5; }
.dialogo input { height: 52px; border-radius: 6px; border: 1px solid #79747E; padding: 0 14px; font-size: 18px; letter-spacing: 0.3em; background: transparent; }
.dialogo .botones { display: flex; justify-content: flex-end; gap: 8px; flex-wrap: wrap; }

.btn { height: 40px; padding: 0 22px; border-radius: 20px; border: 0; font-weight: 500; font-size: 14px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.btn.lleno { background: #6750A4; color: #FFF; }
.btn.texto { background: transparent; color: #6750A4; }
.btn.borde { background: transparent; border: 1px solid #74777F; color: var(--m3-primario); height: 44px; }
.btn.tonal { background: #DCE2F9; color: #001A41; height: 44px; }
.btn:active { filter: brightness(0.92); }

/* ── Acceso, bloqueo e inicio ───────────────────────────────────────────────────────────────────── */

.acceso { background: var(--uinp-fondo); color: var(--uinp-texto); padding: 56px 28px calc(28px + env(safe-area-inset-bottom)); gap: 24px; }
.acceso .emblema { display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.acceso .unitat { font-family: 'Archivo', sans-serif; font-stretch: 112%; font-weight: 800; font-size: 15px; letter-spacing: 0.14em; line-height: 1.35; }
.acceso .ficha { background: var(--uinp-panel); border: 1px solid var(--uinp-borde); border-radius: 16px; padding: 20px; display: flex; flex-direction: column; gap: 12px; }
.acceso .exp { font-family: 'Archivo', sans-serif; font-weight: 700; font-size: 13px; letter-spacing: 0.08em; color: var(--uinp-suave); display: flex; justify-content: space-between; align-items: center; }
.acceso .equipo { background: #3D57A8; color: #FFF; font: 500 12px 'Roboto', sans-serif; letter-spacing: 0; padding: 4px 10px; border-radius: 99px; }
.acceso h1 { margin: 0; font-family: 'Archivo', sans-serif; font-weight: 700; font-size: 24px; line-height: 1.2; color: #FFF; }
.acceso .ficha p { margin: 0; font-size: 14px; line-height: 1.5; color: var(--uinp-suave); }
.acceso .abrir-btn { height: 56px; border-radius: 28px; background: var(--uinp-texto); color: var(--uinp-fondo); font: 700 16px 'Roboto', sans-serif; border: 0; cursor: pointer; }
.acceso .pie { font-size: 12px; line-height: 1.5; color: #9C8FD6; text-align: center; }
.acceso .espacio { flex: 1; }

.bloqueo { background: linear-gradient(170deg, #2B2350 0%, #1B1A3A 45%, #0E1024 100%); color: #FFF; }
.bloqueo .arriba { display: flex; flex-direction: column; align-items: center; padding: 40px 24px 0; }
.bloqueo .reloj { font-weight: 300; font-size: 84px; line-height: 1; letter-spacing: -2px; }
.bloqueo .dia { font-size: 16px; margin-top: 10px; color: #D9D6F0; }
.bloqueo .notis { width: 100%; margin-top: 24px; display: flex; flex-direction: column; gap: 8px; }
.bloqueo .noti { background: rgba(255,255,255,0.12); border-radius: 20px; padding: 12px 16px; display: flex; gap: 12px; align-items: center; font-size: 14px; color: #E9E7F5; }
.bloqueo .abajo { margin-top: auto; display: flex; flex-direction: column; align-items: center; padding-bottom: 12px; }
.patron { position: relative; width: 270px; height: 270px; touch-action: none; user-select: none; }
.patron svg { position: absolute; inset: 0; pointer-events: none; }
.patron .punto { position: absolute; width: 64px; height: 64px; display: flex; align-items: center; justify-content: center; }
.patron .punto span { display: block; width: 14px; height: 14px; border-radius: 50%; background: rgba(255,255,255,0.55); transition: width 160ms, height 160ms, background 160ms; }
.patron .punto.on span { width: 22px; height: 22px; background: #FFF; }
.patron.error .punto.on span { background: #FFB4AB; }
.patron.error { animation: temblar 400ms; }
.bloqueo .mensaje { height: 56px; display: flex; align-items: center; justify-content: center; font-size: 15px; color: #D9D6F0; }
.bloqueo .mensaje.error { color: #FFB4AB; font-weight: 500; }

.inicio { background: linear-gradient(165deg, #6C6FC2 0%, #4B4FA6 30%, #2B2350 70%, #1B1A3A 100%); color: #FFF; }
.inicio .cuerpo { flex: 1; display: flex; flex-direction: column; padding: 28px 20px 0; min-height: 0; }
.inicio .fecha { font-size: 22px; padding: 0 8px; }
.inicio .tiempo { font-size: 15px; color: #E9E7F5; padding: 4px 8px; }
.inicio .rejilla { margin-top: auto; display: grid; grid-template-columns: repeat(4, 1fr); row-gap: 18px; column-gap: 8px; }
.inicio .dock { display: grid; grid-template-columns: repeat(4, 1fr); column-gap: 8px; justify-items: center; margin-top: 22px; }
.app-btn { display: flex; flex-direction: column; align-items: center; gap: 6px; border: 0; background: transparent; padding: 0; cursor: pointer; color: #FFF; font-size: 12px; text-shadow: 0 1px 2px rgba(0,0,0,0.4); }
.app-btn .ic { position: relative; width: 58px; height: 58px; transition: transform 140ms; }
.app-btn:active .ic { transform: scale(0.9); }
.app-btn .cand { position: absolute; right: -3px; bottom: -3px; width: 22px; height: 22px; border-radius: 11px; background: #1B1A3A; border: 2px solid #E9E7F5; display: flex; align-items: center; justify-content: center; }
.app-btn .globo { position: absolute; right: -4px; top: -4px; min-width: 20px; height: 20px; border-radius: 10px; background: #E53935; color: #FFF; font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center; padding: 0 5px; text-shadow: none; }
.inicio .cerca { margin: 18px 0 10px; height: 52px; border-radius: 26px; background: rgba(255,255,255,0.88); display: flex; align-items: center; gap: 12px; padding: 0 18px; color: #3C4043; font-size: 15px; }

/* ── App bloqueada (teclado) ────────────────────────────────────────────────────────────────────── */

.codigo { background: #F7F2FA; }
.codigo .cab { padding: 4px 8px 0; }
.codigo .info { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 12px 32px 0; text-align: center; }
.codigo .info h1 { margin: 0; font-size: 24px; font-weight: 500; }
.codigo .info p { margin: 0; font-size: 15px; line-height: 1.5; color: #49454F; }
.codigo .pista { display: inline-flex; align-items: center; gap: 6px; background: #E8DEF8; color: #21005D; border-radius: 8px; padding: 6px 12px; font-size: 13px; }
.codigo .huecos { display: flex; justify-content: center; gap: 18px; margin-top: 28px; }
.codigo .huecos span { width: 16px; height: 16px; border-radius: 8px; border: 2px solid var(--morado); }
.codigo .huecos span.lleno { background: var(--morado); }
.codigo .huecos.error { animation: temblar 400ms; }
.codigo .huecos.error span { border-color: #B3261E; }
.codigo .estado { height: 40px; display: flex; align-items: center; justify-content: center; font-size: 14px; color: #B3261E; }
.teclado { margin-top: auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; padding: 0 40px 12px; }
.teclado button { height: 64px; border-radius: 32px; border: 0; background: #E8DEF8; font-size: 28px; cursor: pointer; transition: border-radius 160ms, background 120ms; }
.teclado button:active { background: #CBB8EC; border-radius: 20px; }
.teclado .nada { visibility: hidden; }

/* ── Cabeceras genéricas de apps (Material 3) ───────────────────────────────────────────────────── */

.m3 { background: var(--m3-fondo); }
.cab-m3 { display: flex; align-items: center; gap: 4px; padding: 4px 8px 0 4px; min-height: 56px; }
.cab-m3 h1 { margin: 0; font-size: 22px; font-weight: 400; flex: 1; }
.titulo-grande { padding: 4px 24px 16px; font-size: 32px; font-weight: 400; }
.icon-btn { width: 48px; height: 48px; border-radius: 24px; border: 0; background: transparent; display: flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0; }
.icon-btn:active { background: rgba(0,0,0,0.12); }
.seccion { padding: 20px 24px 8px; font-size: 14px; font-weight: 500; color: var(--m3-primario); }
.tarjeta { margin: 0 16px; background: #FFF; border-radius: 24px; padding: 6px 20px; }
.fila { display: flex; align-items: center; gap: 14px; padding: 12px 0; width: 100%; border: 0; background: transparent; text-align: left; cursor: pointer; }
.fila + .fila { border-top: 1px solid #EEF0F6; }
.fila .txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.fila .t1 { font-size: 16px; color: var(--m3-texto); }
.fila .t2 { font-size: 14px; color: var(--m3-sec); }
.fila.muda { cursor: default; opacity: 0.55; }
.avatar { width: 44px; height: 44px; border-radius: 22px; color: #FFF; display: flex; align-items: center; justify-content: center; font-weight: 500; font-size: 18px; flex-shrink: 0; }

/* ── Xat ─────────────────────────────────────────────────────────────────────────────────────────── */

.xat { background: #FFF; }
.xat .cab { background: var(--xat); color: #FFF; flex-shrink: 0; }
.xat .cab .fila-cab { display: flex; align-items: center; height: 56px; padding: 0 8px 0 18px; }
.xat .cab .fila-cab h1 { flex: 1; margin: 0; font-size: 21px; font-weight: 500; }
.xat .pestanas { display: grid; grid-template-columns: repeat(3, 1fr); text-align: center; font-size: 14px; font-weight: 500; letter-spacing: 0.04em; }
.xat .pestanas div { padding: 12px 0 10px; color: #B3D9D2; }
.xat .pestanas .on { color: #FFF; border-bottom: 3px solid #FFF; }
.chat-fila { display: flex; gap: 14px; align-items: center; padding: 10px 16px; width: 100%; border: 0; background: #FFF; text-align: left; cursor: pointer; }
.chat-fila:active { background: #E9EDEF; }
.chat-fila .avatar { width: 50px; height: 50px; border-radius: 25px; font-size: 19px; }
.chat-fila .txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; border-bottom: 1px solid #E9EDEF; padding-bottom: 10px; }
.chat-fila .l1, .chat-fila .l2 { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.chat-fila .nombre { font-size: 17px; font-weight: 500; color: #111B21; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-fila .hora { font-size: 12px; color: #667781; flex-shrink: 0; }
.chat-fila .hora.nuevo { color: #25D366; }
.chat-fila .ultimo { font-size: 14px; color: #54656F; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-fila .contador { min-width: 22px; height: 22px; border-radius: 11px; background: #25D366; color: #FFF; font-size: 12px; font-weight: 700; display: flex; align-items: center; justify-content: center; padding: 0 6px; }

.conversa { background: var(--xat-fondo); }
.conversa .cab { background: var(--xat); color: #FFF; display: flex; align-items: center; gap: 6px; padding: 0 4px 6px 0; flex-shrink: 0; box-shadow: 0 1px 3px rgba(0,0,0,0.18); }
.conversa .cab .icon-btn:active { background: rgba(255,255,255,0.2); }
.conversa .cab .avatar { width: 40px; height: 40px; font-size: 17px; }
.conversa .cab .quien { flex: 1; display: flex; flex-direction: column; gap: 2px; margin-left: 6px; min-width: 0; }
.conversa .cab .quien b { font-size: 17px; font-weight: 500; }
.conversa .cab .quien span { font-size: 13px; color: #D1F4CC; }
.conversa .fijados { background: #FFF; display: flex; align-items: center; gap: 10px; padding: 8px 16px; font-size: 14px; color: #3B4A54; border: 0; width: 100%; text-align: left; cursor: pointer; border-bottom: 1px solid #E9EDEF; flex-shrink: 0; }
.conversa .fijados b { color: var(--xat); }
.mensajes { min-height: 100%; display: flex; flex-direction: column; justify-content: flex-end; gap: 4px; padding: 10px 12px; }
.cifrado { align-self: center; max-width: 86%; background: #FFEECD; color: #54656F; font-size: 12px; line-height: 1.4; text-align: center; padding: 7px 12px; border-radius: 8px; margin: 4px 0 8px; }
.sep-dia { align-self: center; background: #FFF; color: #54656F; font-size: 12px; font-weight: 500; padding: 5px 12px; border-radius: 8px; margin: 8px 0 4px; box-shadow: 0 1px 0.5px rgba(11,20,26,0.13); }
.sep-sis { align-self: center; background: #E1F2FB; color: #3B4A54; font-size: 12.5px; padding: 6px 12px; border-radius: 8px; margin: 4px 0; text-align: center; max-width: 90%; }
.bocadillo { max-width: 80%; border-radius: 10px; padding: 6px 9px 5px; box-shadow: 0 1px 0.5px rgba(11,20,26,0.13); display: flex; flex-direction: column; gap: 2px; font-size: 15px; line-height: 1.35; overflow-wrap: anywhere; }
.bocadillo.in { align-self: flex-start; background: #FFF; border-top-left-radius: 0; }
.bocadillo.out { align-self: flex-end; background: #D9FDD3; border-top-right-radius: 0; }
.bocadillo .autor { font-size: 13px; font-weight: 500; color: #C2185B; }
.bocadillo .pie { align-self: flex-end; display: flex; align-items: center; gap: 4px; font-size: 11px; color: #667781; }
.bocadillo.borrado { color: #667781; font-style: italic; font-size: 14px; }
.bocadillo.fijado-on { outline: 2px solid #25D366; }
.bocadillo .foto { width: 250px; border-radius: 6px; overflow: hidden; cursor: zoom-in; }
.bocadillo .foto .tique-mano { padding: 12px 14px 18px; }
.bocadillo .foto .tique { font-size: 9.5px; padding: 10px; }
.escribiendo { align-self: flex-start; background: #FFF; border-radius: 0 10px 10px 10px; padding: 10px 14px; display: flex; gap: 4px; }
.escribiendo i { width: 7px; height: 7px; border-radius: 4px; background: #8696A0; animation: punto 1s infinite; }
.escribiendo i:nth-child(2) { animation-delay: 0.15s; } .escribiendo i:nth-child(3) { animation-delay: 0.3s; }
@keyframes punto { 0%,60%,100% { opacity: 0.3; transform: none; } 30% { opacity: 1; transform: translateY(-3px); } }
.aparece { animation: caer 300ms var(--ease) both; }
.redactar { display: flex; align-items: center; gap: 8px; padding: 6px 8px; flex-shrink: 0; }
.redactar .caja { flex: 1; height: 48px; border-radius: 24px; background: #FFF; display: flex; align-items: center; padding: 0 16px; font-size: 16px; color: #8696A0; }
.redactar .mic { width: 48px; height: 48px; border-radius: 24px; background: #00A884; display: flex; align-items: center; justify-content: center; }

/* ── Tique (P4) ──────────────────────────────────────────────────────────────────────────────────── */

.tique { background: #FBF8F1; color: #2B2B2B; font-family: 'Courier New', monospace; font-size: 11px; line-height: 1.45; padding: 14px 14px 12px; position: relative; }
.tique .centro { text-align: center; }
.tique .gran { font-size: 13px; font-weight: 700; letter-spacing: 0.08em; }
.tique .linea { border-top: 1px dashed #999; margin: 6px 0; }
.tique .fila-t { display: flex; justify-content: space-between; }
.tique .promo { margin-top: 8px; border: 1px solid #C13584; border-radius: 6px; padding: 6px 8px; display: flex; align-items: center; gap: 8px; font-family: 'Roboto', sans-serif; font-size: 12px; color: #333; }
.tique .promo b { font-size: 16px; letter-spacing: 0.12em; font-family: 'Courier New', monospace; }
.tique-mano { background: linear-gradient(160deg, #C9A88A, #8D6E63); padding: 18px 26px 26px; position: relative; }
.tique-mano .polsera { position: absolute; left: -6px; right: -6px; bottom: 5px; height: 5px; background: #C62828; border-radius: 3px; transform: rotate(-3deg); opacity: 0.9; }

/* ── Visor de fotos y fotos de relleno ──────────────────────────────────────────────────────────── */

.foto-relleno { display: flex; align-items: flex-end; padding: 8px; color: #FFF; font-size: 12px; font-weight: 500; text-shadow: 0 1px 2px rgba(0,0,0,0.5); aspect-ratio: 1; background-size: cover; background-position: center; }
.visor { background: #000; color: #FFF; }
.visor .marco { flex: 1; display: flex; align-items: center; justify-content: center; padding: 16px; min-height: 0; overflow: auto; }

/* ── Moments ─────────────────────────────────────────────────────────────────────────────────────── */

.moments { background: #FFF; color: #000; }
.moments .cab { display: flex; align-items: center; gap: 4px; padding: 0 4px 0 12px; height: 52px; flex-shrink: 0; }
.moments .cab h1 { flex: 1; margin: 0; font-size: 20px; font-weight: 700; display: flex; align-items: center; gap: 6px; }
.moments .perfil { display: flex; align-items: center; gap: 20px; padding: 4px 16px 10px; }
.moments .perfil .foto-p { width: 86px; height: 86px; border-radius: 43px; padding: 3px; background: linear-gradient(45deg, #FDC468, #F56040, #C13584, #5851DB); flex-shrink: 0; }
.moments .perfil .foto-p div { width: 100%; height: 100%; border-radius: 50%; border: 3px solid #FFF; background: #D9D6F0; display: flex; align-items: center; justify-content: center; font-size: 30px; color: #4B4FA6; font-weight: 700; }
.moments .cifras { flex: 1; display: grid; grid-template-columns: repeat(3, 1fr); text-align: center; font-size: 13px; }
.moments .cifras b { display: block; font-size: 17px; }
.moments .bio { padding: 0 16px 10px; font-size: 14px; line-height: 1.4; }
.moments .acciones { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 0 16px 12px; }
.moments .acciones button { height: 34px; border-radius: 8px; border: 0; background: #EFEFEF; font-weight: 500; font-size: 14px; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 6px; }
.moments .mes { padding: 10px 16px 6px; font-size: 13px; font-weight: 700; color: #737373; text-transform: uppercase; letter-spacing: 0.06em; }
.moments .grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; }
.moments .grid button { border: 0; padding: 0; cursor: pointer; position: relative; }
.moments .post-cab { display: flex; align-items: center; gap: 10px; padding: 10px 14px; }
.moments .post-cab .mini { width: 34px; height: 34px; border-radius: 17px; background: #D9D6F0; display: flex; align-items: center; justify-content: center; font-weight: 700; color: #4B4FA6; }
.moments .post-pie { padding: 10px 14px; display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.moments .post-pie .iconos { display: flex; gap: 14px; }
.moments .coment { font-size: 14px; }
.moments .coment b { margin-right: 6px; }
.moments .archivada { display: inline-flex; align-items: center; gap: 6px; background: #FFF3E0; color: #8D4E00; border-radius: 8px; padding: 4px 10px; font-size: 13px; font-weight: 500; }
.marca-arx { position: absolute; right: 6px; top: 6px; width: 24px; height: 24px; border-radius: 12px; background: rgba(0,0,0,0.55); display: flex; align-items: center; justify-content: center; }

/* ── Ubica't ─────────────────────────────────────────────────────────────────────────────────────── */

.ubicat { background: #ECEFE6; }
.ubicat .mapa { position: absolute; left: 0; right: 0; top: 0; height: 46%; }
.ubicat .flotante { position: relative; z-index: 2; display: flex; flex-direction: column; gap: 8px; padding: 6px 12px 0; }
.ubicat .circulo { display: flex; align-items: center; gap: 8px; }
.ubicat .circulo div { flex: 1; height: 44px; border-radius: 22px; background: #FFF; display: flex; align-items: center; padding: 0 16px; font-size: 15px; font-weight: 500; box-shadow: 0 1px 4px rgba(0,0,0,0.2); }
.ubicat .circulo .icon-btn { background: #FFF; box-shadow: 0 1px 4px rgba(0,0,0,0.2); width: 44px; height: 44px; }
.ubicat .banner { background: var(--morado); color: #FFF; border-radius: 14px; padding: 10px 14px; font-size: 14px; line-height: 1.4; display: flex; gap: 10px; align-items: center; }
.ubicat .hoja { position: relative; z-index: 2; margin-top: auto; height: 60%; background: #FFF; border-radius: 28px 28px 0 0; box-shadow: 0 -2px 10px rgba(0,0,0,0.12); padding: 10px 0 0; display: flex; flex-direction: column; }
.ubicat .hoja .asa { align-self: center; width: 36px; height: 4px; border-radius: 2px; background: #CAC4D0; }
.ubicat .yo { display: flex; align-items: center; gap: 12px; padding: 10px 20px; }
.ubicat .zonas { display: flex; gap: 8px; overflow-x: auto; padding: 4px 16px 10px; scrollbar-width: none; flex-shrink: 0; }
.ubicat .zonas::-webkit-scrollbar { display: none; }
.ubicat .zonas button { flex-shrink: 0; height: 34px; padding: 0 14px; border-radius: 8px; border: 1px solid #79747E; background: #FFF; font-size: 14px; font-weight: 500; color: #49454F; cursor: pointer; }
.ubicat .zonas button.on { background: #E8DEF8; border-color: #E8DEF8; color: #21005D; }
.ubicat .reg { display: flex; gap: 12px; padding: 10px 20px; border-bottom: 1px solid #EEE8F4; align-items: center; }
.ubicat .reg .lugar { font-size: 15px; font-weight: 500; }
.ubicat .reg .cuando { font-size: 13px; color: #49454F; }
.ubicat .reg .consultas { margin-left: auto; display: flex; align-items: center; gap: 4px; font-size: 13px; color: var(--morado); font-weight: 500; white-space: nowrap; }

/* ── Correu, formulario UINP ────────────────────────────────────────────────────────────────────── */

.correu { background: #F8FAFD; }
.correu .busca { margin: 6px 16px 10px; height: 52px; border-radius: 26px; background: #E9EEF6; display: flex; align-items: center; gap: 12px; padding: 0 6px 0 16px; font-size: 16px; color: #444746; flex-shrink: 0; }
.correu .carpetas { display: flex; gap: 8px; padding: 0 16px 8px; flex-shrink: 0; }
.correu .carpetas button { height: 32px; padding: 0 14px; border-radius: 8px; border: 1px solid #C4C7C5; background: transparent; font-size: 13px; font-weight: 500; cursor: pointer; }
.correu .carpetas button.on { background: #C2E7FF; border-color: #C2E7FF; color: #001D35; }
.correu-fila { display: flex; gap: 14px; padding: 12px 16px; width: 100%; border: 0; background: transparent; text-align: left; cursor: pointer; }
.correu-fila:active { background: #E9EEF6; }
.correu-fila .txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.correu-fila .l1 { display: flex; justify-content: space-between; font-size: 16px; color: #1F1F1F; }
.correu-fila .l1 span:last-child { font-size: 12px; color: #444746; }
.correu-fila .asunto { font-size: 14px; color: #1F1F1F; }
.correu-fila .prev { font-size: 14px; color: #444746; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.correu-fila .borr { color: #B3261E; }
.lectura { padding: 8px 20px 24px; display: flex; flex-direction: column; gap: 14px; }
.lectura h2 { margin: 0; font-size: 22px; font-weight: 400; color: #1F1F1F; }
.lectura .de { display: flex; gap: 12px; align-items: center; font-size: 14px; color: #444746; }
.lectura .cuerpo { font-size: 15px; line-height: 1.6; color: #1F1F1F; white-space: pre-wrap; }
.lectura .tachado { text-decoration: line-through; color: #5F6368; }
.lectura .marc { background: #FCE8E6; color: #A50E0E; border-left: 4px solid #D93025; padding: 10px 12px; font-weight: 700; border-radius: 4px; }
.lectura .cambio { display: flex; align-items: center; gap: 8px; background: #FEF7E0; color: #7A4F01; border-radius: 8px; padding: 8px 12px; font-size: 13px; }
.lectura .enlace { display: flex; align-items: center; gap: 10px; border: 1px solid #C4C7C5; border-radius: 12px; padding: 12px 14px; color: #0B57D0; font-weight: 500; font-size: 15px; background: #FFF; cursor: pointer; width: 100%; text-align: left; }

.uinp { background: #F3F4F8; }
.uinp .cab-u { background: var(--uinp-fondo); color: var(--uinp-texto); display: flex; align-items: center; gap: 10px; padding: 8px 12px 12px 4px; flex-shrink: 0; }
.uinp .cab-u .marca { font-family: 'Archivo', sans-serif; font-stretch: 110%; font-weight: 800; font-size: 13px; letter-spacing: 0.12em; line-height: 1.3; }
.uinp .url { background: #FFF; color: #444746; font-size: 13px; padding: 6px 14px; display: flex; align-items: center; gap: 6px; flex-shrink: 0; border-bottom: 1px solid #E0E2EC; }
.uinp form, .uinp .bloque { padding: 18px 20px 24px; display: flex; flex-direction: column; gap: 16px; }
.uinp h2 { margin: 0; font-family: 'Archivo', sans-serif; font-size: 20px; color: var(--uinp-fondo); }
.uinp label { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 500; color: #1F2A44; }
.uinp input[type=date], .uinp input[type=time], .uinp input[type=text], .uinp input[inputmode=numeric] { height: 50px; border-radius: 8px; border: 1px solid #A5ABBD; padding: 0 12px; font-size: 16px; background: #FFF; color: #1B1B1F; }
.uinp .fijo { background: #E8EAF2; border-radius: 8px; padding: 10px 12px; font-size: 14px; color: #44474F; display: flex; flex-direction: column; gap: 4px; }
.uinp .check { flex-direction: row; align-items: center; gap: 10px; font-weight: 400; }
.uinp .check input { width: 22px; height: 22px; }
.uinp .error { color: #B3261E; font-size: 13px; font-weight: 500; }
.uinp .enviar { height: 52px; border-radius: 26px; border: 0; background: var(--uinp-panel); color: #FFF; font-size: 16px; font-weight: 700; cursor: pointer; }
.uinp .resultado { background: #FFF; border: 2px solid #2E7D32; border-radius: 16px; padding: 18px; display: flex; flex-direction: column; gap: 10px; text-align: center; }
.uinp .expediente { font-family: 'Courier New', monospace; font-size: 26px; font-weight: 700; letter-spacing: 0.08em; color: var(--uinp-fondo); }
.uinp .expediente .suyo { background: #FFF59D; border-radius: 4px; padding: 0 4px; }

/* ── Calendari, Navegador, Galeria, Telèfon, Missatges, Configuració ─────────────────────────────── */

.cal-dia { display: flex; gap: 14px; padding: 6px 16px; }
.cal-dia .num { width: 44px; text-align: center; flex-shrink: 0; }
.cal-dia .num small { display: block; font-size: 12px; color: #444746; }
.cal-dia .num b { font-size: 22px; font-weight: 400; }
.cal-dia .evs { flex: 1; display: flex; flex-direction: column; gap: 6px; }
.evento { border-radius: 8px; padding: 8px 12px; color: #FFF; font-size: 15px; font-weight: 500; text-align: left; border: 0; cursor: pointer; display: flex; flex-direction: column; gap: 2px; }
.evento small { font-weight: 400; font-size: 13px; opacity: 0.9; }
.evento.cancelado { background: #F1F3F4 !important; color: #5F6368; }
.evento.cancelado span { text-decoration: line-through; }
.detalle-ev { padding: 8px 24px 24px; display: flex; flex-direction: column; gap: 18px; }
.detalle-ev .titulo-ev { display: flex; gap: 14px; align-items: flex-start; }
.detalle-ev .cuadro { width: 18px; height: 18px; border-radius: 4px; margin-top: 8px; flex-shrink: 0; }
.detalle-ev h2 { margin: 0; font-size: 26px; font-weight: 400; }
.detalle-ev .dato { display: flex; gap: 14px; align-items: center; font-size: 15px; color: #1F1F1F; }
.detalle-ev .emoji { font-size: 44px; line-height: 1; }
.detalle-ev .canc { color: #B3261E; font-weight: 500; }

.nav-barra { margin: 6px 12px; height: 48px; border-radius: 24px; background: #EEF0F8; display: flex; align-items: center; gap: 10px; padding: 0 16px; font-size: 15px; color: #444746; flex-shrink: 0; }
.hist-fila { display: flex; gap: 14px; align-items: center; padding: 12px 20px; width: 100%; border: 0; background: transparent; text-align: left; cursor: pointer; font-size: 15px; color: #1F1F1F; }
.hist-fila small { color: #5F6368; font-size: 12px; display: block; }
.hist-fila.muda { cursor: default; }
.hilo { padding: 16px 20px; display: flex; flex-direction: column; gap: 14px; }
.hilo .foro { font-size: 13px; color: #5F6368; display: flex; align-items: center; gap: 8px; }
.hilo h2 { margin: 0; font-size: 20px; font-weight: 500; }
.hilo .post { background: #FFF; border: 1px solid #E0E2EC; border-radius: 12px; padding: 14px; font-size: 16px; line-height: 1.55; }
.hilo .guardado { font-size: 13px; color: #0B57D0; font-weight: 500; }

.galeria-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; }
.galeria-grid button { border: 0; padding: 0; cursor: pointer; }
.galeria-grid .foto-relleno { font-size: 10px; padding: 4px; }

.llamada { display: flex; gap: 14px; align-items: center; padding: 10px 16px; }
.llamada .txt { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.llamada .nom { font-size: 16px; }
.llamada .nom.perdida { color: #B3261E; }
.llamada .det { font-size: 13px; color: #44474F; display: flex; align-items: center; gap: 4px; }

.sms-fila { display: flex; gap: 14px; align-items: center; padding: 12px 16px; width: 100%; border: 0; background: transparent; text-align: left; cursor: pointer; }
.sms-fila .txt { flex: 1; min-width: 0; }
.sms-fila .l1 { display: flex; justify-content: space-between; font-size: 16px; }
.sms-fila .l1 small { font-size: 12px; color: #44474F; }
.sms-fila .prev { font-size: 14px; color: #44474F; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sms-fila.nuevo .l1, .sms-fila.nuevo .prev { font-weight: 700; color: #1B1B1F; }
.sms-burbuja { align-self: flex-start; max-width: 82%; background: #E9E7F1; border-radius: 18px 18px 18px 4px; padding: 10px 14px; font-size: 15px; line-height: 1.45; margin: 8px 16px; }

.interruptor { width: 52px; height: 32px; border-radius: 16px; background: var(--m3-primario); display: flex; align-items: center; justify-content: flex-end; padding: 0 4px; flex-shrink: 0; }
.interruptor span { width: 24px; height: 24px; border-radius: 12px; background: #FFF; }
.alerta { color: #B3261E; }
