/* Reels de EduDesk (28-10-2026): la plantilla 2 (aspecto de Instagram) de los vídeos de redes.
   Se llega desde el icono de redes de la cabecera pública. */
/* Mismos colores que la portada (landing-2026.css): gris de día, oscuro de noche; el tema lo pone
   components/_preferencias_cabeza.html en <html data-theme> antes de pintar. */
:root { --fondo: #DCE5EC; --hover: #CFDAE3; --tarjeta: #F3F6F9; --tinta: #13202B; --suave: #3C4C5A; --linea: #B5C3CF; color-scheme: light; --oro: #E8A317; --coral: #f08a3c; --rosa: #e0457b; }
:root[data-theme="dark"] { --fondo: #0D1520; --hover: #131E2B; --tarjeta: #152131; --tinta: #E6EDF3; --suave: #A9B7C4; --linea: #2A3A4B; color-scheme: dark; }
* { box-sizing: border-box; margin: 0; }
html, body { height: 100%; background: var(--fondo); color: var(--tinta); font-family: "Google Sans", system-ui, sans-serif; overflow: hidden; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

.barra { position: fixed; left: 0; top: 0; bottom: 0; width: 240px; border-right: 1px solid var(--linea); padding: 28px 14px; display: flex; flex-direction: column; gap: 6px; background: var(--fondo); z-index: 3; }
.barra .marca { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 20px; padding: 0 10px 26px; }
.barra .marca img { width: 36px; height: 36px; border-radius: 10px; }
.barra button, .barra a { display: flex; align-items: center; gap: 14px; padding: 12px; border-radius: 12px; font-size: 15px; text-decoration: none; color: var(--tinta); }
.barra button:hover, .barra a:hover { background: var(--hover); }
.barra button.on { font-weight: 700; }
.barra .abajo { margin-top: auto; color: var(--suave); font-size: 12.5px; line-height: 1.5; padding: 12px; }

#feed { position: fixed; left: 240px; right: 0; top: 0; bottom: 0; overflow-y: scroll; scroll-snap-type: y mandatory; scrollbar-width: none; overscroll-behavior: contain; }
#feed::-webkit-scrollbar { display: none; }
.diapo { height: 100dvh; scroll-snap-align: start; scroll-snap-stop: always; display: flex; align-items: center; justify-content: center; gap: 18px; padding: 3vh 0; }
.tarjeta { position: relative; height: 94dvh; aspect-ratio: 9 / 16; border-radius: 10px; overflow: hidden; background: #0b1628; box-shadow: 0 10px 40px rgba(21,40,68,.18); }
.tarjeta video { width: 100%; height: 100%; object-fit: cover; display: block; }
.tarjeta::after { content: ''; position: absolute; inset: auto 0 0 0; height: 38%; background: linear-gradient(transparent, rgba(5,10,20,.72)); pointer-events: none; }
.icono-pausa { position: absolute; inset: 0; margin: auto; width: 76px; height: 76px; color: #fff; opacity: 0; transition: opacity .2s; pointer-events: none; z-index: 2; }
.diapo.pausa .icono-pausa { opacity: .9; }
.sonido-dentro { position: absolute; right: 12px; bottom: 14px; z-index: 2; width: 34px; height: 34px; padding: 8px; border-radius: 50%; background: rgba(0,0,0,.5); color: #fff; }

.texto { position: absolute; left: 14px; right: 58px; bottom: 16px; z-index: 2; color: #fff; }
.cabeza { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 14px; }
.anillo { width: 38px; height: 38px; border-radius: 50%; padding: 2px; background: conic-gradient(var(--oro), var(--coral), var(--rosa), var(--oro)); }
.anillo img { width: 100%; height: 100%; border-radius: 50%; border: 2px solid #fff; display: block; background: #fff; }
.seguir { border: 1px solid rgba(255,255,255,.8); border-radius: 8px; padding: 3px 10px; font-size: 13px; font-weight: 600; color: #fff; text-decoration: none; }
.texto p { font-size: 13.5px; line-height: 1.45; margin-top: 8px; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; cursor: pointer; }
.texto p.abierto { -webkit-line-clamp: unset; }
.texto p b { font-weight: 700; }

.acciones { display: flex; flex-direction: column; gap: 22px; align-self: flex-end; padding-bottom: 6vh; }
.acciones button, .acciones a { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 12px; color: var(--tinta); text-decoration: none; }

.acciones [data-compartir].copiado small { color: #2f7d5d; }
.progreso { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; z-index: 3; }
.progreso i { display: block; height: 100%; width: 0; background: var(--oro); }

/* Iconos del proyecto ({% icon %}) */
.reels .cole-icon { display: block; flex: none; }
.barra .cole-icon, .tabs-movil .cole-icon { width: 26px; height: 26px; }
.acciones .cole-icon { width: 30px; height: 30px; transition: transform .15s; }
.acciones button:active .cole-icon { transform: scale(.85); }
.icono-pausa .cole-icon { width: 100%; height: 100%; }
.ico-gustado, .ico-sonido, body.con-sonido .ico-mudo, [data-gusta].on .ico-gusta { display: none !important; }
[data-gusta].on .ico-gustado, body.con-sonido .ico-sonido { display: block !important; color: var(--rosa); }
body.con-sonido .ico-sonido { color: #fff; }
.diapo[hidden] { display: none; }
.texto p { cursor: pointer; }

.tabs-movil { display: none; }
@media (max-width: 900px) {
  .barra { display: none; }
  #feed { left: 0; }
  .diapo { padding: 0; gap: 0; position: relative; }
  .tarjeta { height: 100dvh; width: 100%; aspect-ratio: auto; border-radius: 0; }
  .acciones { position: absolute; right: 10px; bottom: 90px; padding: 0; z-index: 3; }
  .acciones button, .acciones a { color: #fff; }
  .texto { bottom: 76px; }
  .sonido-dentro { top: max(14px, env(safe-area-inset-top)); bottom: auto; }
  .titulo-movil { position: fixed; top: 0; left: 0; z-index: 4; padding: 14px 16px; padding-top: max(14px, env(safe-area-inset-top)); font-weight: 700; font-size: 22px; color: #fff; }
  .tabs-movil { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 4; justify-content: space-around; background: var(--tarjeta); border-top: 1px solid var(--linea); padding: 8px 0 max(8px, env(safe-area-inset-bottom)); }
  .tabs-movil button, .tabs-movil a { display: flex; flex-direction: column; align-items: center; font-size: 11px; color: var(--suave); text-decoration: none; }
  .tabs-movil .on { color: var(--tinta); font-weight: 700; }
  #feed { bottom: 58px; }
  .diapo { height: calc(100dvh - 58px); }
  .tarjeta { height: 100%; }
}
@media (min-width: 901px) { .titulo-movil { display: none; } }
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }

