/* =====================================================================
   PETRALINK WEB (petralink3.html)
   La misma red social, pero sin móvil: metida en la página como una
   aplicación web de tres columnas (menú · muro · sugerencias) y con
   la publicación ampliada en una ventana.
   Reutiliza de petralink.css: .pl-av, .pl-carrusel/.pl-tira/.pl-foto,
   .pl-actor, .pl-pose--*, .pl-acciones, .pl-pie, .pl-com, .pl-cform…
   ===================================================================== */

.plw-banda {
  background: var(--paper-2);
  border-top: 1px solid var(--paper-3);
  border-bottom: 1px solid var(--paper-3);
  padding: 32px 0 56px;
}
.plw-app {
  display: grid;
  grid-template-columns: 210px minmax(0, 470px) 300px;
  gap: 40px;
  justify-content: center;
  align-items: start;
}

/* ---------- Menú lateral ---------- */
.plw-rail { position: sticky; top: 104px; }
.plw-marca {
  display: flex; align-items: center; gap: 10px; margin: 0 0 22px; padding: 0 12px;
  font-family: var(--font-display); font-size: 1.75rem; letter-spacing: .03em; color: var(--ink);
}
.plw-marca svg { width: 28px; height: 28px; color: var(--slate); flex: none; }
.plw-rail ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 3px; }
.plw-rail a, .plw-rail button {
  display: flex; align-items: center; gap: 14px; width: 100%;
  padding: 10px 12px; border: 0; border-radius: 12px; background: none; cursor: pointer;
  color: var(--ink); font: 700 .97rem var(--font-body); text-align: left; text-decoration: none;
}
.plw-rail a:hover, .plw-rail button:hover { background: var(--paper-3); }
.plw-rail .on { font-weight: 800; background: var(--white); box-shadow: var(--shadow-sm); }
.plw-rail svg { width: 23px; height: 23px; flex: none; }
.plw-rail .pl-av { width: 24px; height: 24px; border-color: var(--ink-3); flex: none; }

/* ---------- Historias ---------- */
.plw-historias {
  background: var(--white); border: 1px solid var(--paper-3); border-radius: 16px;
  box-shadow: var(--shadow-sm); margin-bottom: 24px; overflow: hidden;
}
.plw-historias .pl-stories { border-bottom: 0; }

/* ---------- Tarjeta de publicación ---------- */
.plw-card {
  background: var(--white); border: 1px solid var(--paper-3); border-radius: 16px;
  box-shadow: var(--shadow-sm); margin-bottom: 26px; overflow: hidden;
}
.plw-chead { display: flex; align-items: center; gap: 11px; padding: 12px 14px; }
.plw-chead .pl-av { width: 38px; height: 38px; border-color: var(--paper-3); }
.plw-quien { flex: 1; min-width: 0; line-height: 1.25; }
.plw-quien b { font: 800 .9rem var(--font-title); display: inline-flex; align-items: center; gap: 5px; }
.plw-quien .pl-verif { width: 14px; height: 14px; color: var(--slate); flex: none; }
.plw-quien .pl-verif svg { width: 100%; height: 100%; display: block; }
.plw-quien i { font-style: normal; color: var(--ink-3); font-weight: 700; }
.plw-quien span { display: block; font-size: .76rem; color: var(--ink-2); }
.plw-seguir { border: 0; background: none; padding: 0 4px; cursor: pointer; color: var(--slate-dark); font: 800 .84rem var(--font-body); }
.plw-mas { border: 0; background: none; padding: 0; cursor: pointer; color: var(--ink-2); }
.plw-mas svg { width: 19px; height: 19px; display: block; }

.plw-card .pl-carrusel { border-top: 1px solid var(--paper-3); border-bottom: 1px solid var(--paper-3); }
.plw-card .pl-acciones { padding: 11px 14px 4px; gap: 16px; }
.plw-card .pl-pie { padding: 4px 14px 0; }
.plw-card .pl-cform { margin: 10px 0 0; padding: 10px 14px; border-top: 1px solid var(--paper-3); }

/* Vista previa de comentarios en la tarjeta */
.plw-previa { display: grid; gap: 3px; margin: 4px 0 2px; }
.plw-previa p { margin: 0; font-size: .85rem; line-height: 1.4; }
.plw-previa b { font-family: var(--font-title); }

/* ---------- Columna derecha ---------- */
.plw-side { position: sticky; top: 104px; display: grid; gap: 22px; }
.plw-yo { display: flex; align-items: center; gap: 12px; }
.plw-yo .pl-av { width: 50px; height: 50px; border-color: var(--paper-3); }
.plw-yo b { display: block; font-family: var(--font-title); }
.plw-yo span { font-size: .8rem; color: var(--ink-2); }
.plw-side h4 { margin: 0 0 12px; font-size: .85rem; color: var(--ink-2); font-family: var(--font-title); }
.plw-etiquetas { display: flex; flex-wrap: wrap; gap: 8px; }
.plw-etiquetas a {
  background: var(--white); border: 1px solid var(--paper-3); border-radius: 999px;
  padding: 5px 12px; font: 700 .8rem var(--font-body); color: var(--slate-dark); text-decoration: none;
}
.plw-etiquetas a:hover { background: var(--paper-3); }
.plw-legal { font-size: .74rem; line-height: 1.7; color: var(--ink-3); }
.plw-legal a { color: var(--ink-3); }

/* ---------- Publicación ampliada ---------- */
.plw-modal { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 24px; }
.plw-modal[hidden] { display: none; }
.plw-fondo { position: fixed; inset: 0; align-self: stretch; justify-self: stretch; background: rgba(20, 16, 12, .84); }
.plw-caja {
  position: relative; display: flex; overflow: hidden;
  height: min(84vh, 660px); max-width: calc(100vw - 48px);
  background: var(--white); border-radius: 16px; box-shadow: 0 30px 70px rgba(0, 0, 0, .45);
}
.plw-caja .pl-carrusel { height: 100%; aspect-ratio: 1 / 1; flex: none; }
.plw-caja .pl-tira { height: 100%; }
.plw-caja .pl-foto { aspect-ratio: auto; height: 100%; }
.plw-lado { display: flex; flex-direction: column; width: 360px; flex: none; border-left: 1px solid var(--paper-3); }
.plw-lado .plw-chead { border-bottom: 1px solid var(--paper-3); }
.plw-scroll { flex: 1; overflow-y: auto; padding: 14px; display: grid; gap: 12px; align-content: start; }
.plw-scroll .pl-com .pl-av { width: 30px; height: 30px; border-color: var(--paper-3); }
.plw-lado .pl-acciones { border-top: 1px solid var(--paper-3); padding: 10px 14px 2px; }
.plw-lado .pl-pie { padding: 2px 14px 10px; }
.plw-lado .pl-cform { margin: 0; padding: 10px 14px; border-top: 1px solid var(--paper-3); }

.plw-cerrar, .plw-nav {
  position: absolute; z-index: 3; border: 0; cursor: pointer;
  background: rgba(251, 249, 244, .9); color: var(--ink);
  border-radius: 50%; display: grid; place-items: center;
}
.plw-cerrar { top: 16px; right: 20px; width: 36px; height: 36px; }
.plw-cerrar svg { width: 18px; height: 18px; }
.plw-nav { top: 50%; transform: translateY(-50%); width: 42px; height: 42px; }
.plw-nav svg { width: 20px; height: 20px; }
.plw-nav--prev { left: 20px; }
.plw-nav--next { right: 20px; }
.plw-cerrar:hover, .plw-nav:hover { background: #fff; }
body.plw-abierto { overflow: hidden; }
/* la cabecera del sitio es sticky y con backdrop-filter: se aparta mientras la ventana está abierta */
body.plw-abierto .site-header { visibility: hidden; }

/* ---------- Responsive ---------- */
@media (max-width: 1140px) {
  .plw-app { grid-template-columns: 200px minmax(0, 470px); gap: 32px; }
  .plw-side { display: none; }
}
@media (max-width: 820px) {
  .plw-app { grid-template-columns: minmax(0, 470px); }
  .plw-rail { position: static; margin-bottom: 18px; }
  .plw-marca { display: none; }
  .plw-rail ul { grid-auto-flow: column; justify-content: center; gap: 4px; }
  .plw-rail .plw-txt { display: none; }
  .plw-rail a, .plw-rail button { justify-content: center; padding: 11px; }
}
@media (max-width: 900px) {
  .plw-modal { padding: 12px; }
  .plw-caja { flex-direction: column; width: min(480px, 100%); height: auto; max-height: 88vh; }
  .plw-caja .pl-carrusel { width: 100%; height: auto; aspect-ratio: 1 / 1; }
  .plw-caja .pl-foto { aspect-ratio: 1 / 1; height: auto; }
  .plw-lado { width: 100%; border-left: 0; border-top: 1px solid var(--paper-3); min-height: 0; }
  .plw-scroll { max-height: 30vh; }
  .plw-nav { display: none; }
}
