/* firmas.css — Tarjeta de autor para entradas del blog (Arhol76)
   Se adapta al tema del blog: hereda tipografía y color de texto.
   Para personalizar, define estas variables en tu CSS del blog (opcional):
   :root { --firma-acento: #b3472f; --firma-radio: 12px; --firma-foto: 120px; } */

.tarjeta {
  --firma-acento: currentColor;
  --firma-borde: color-mix(in srgb, currentColor 18%, transparent);
  --firma-fondo: color-mix(in srgb, currentColor 4%, transparent);
  --firma-radio: 12px;
  --firma-foto: 120px;

  display: flex;
  align-items: center;
  gap: 1.5rem;
  box-sizing: border-box;
  max-width: 100%;
  margin: 3rem 0 1.5rem;
  padding: 1.25rem;
  border: 1px solid var(--firma-borde);
  border-radius: var(--firma-radio);
  background: var(--firma-fondo);
  font-family: inherit;
  color: inherit;
  text-align: left;
}

.tarjeta *,
.tarjeta *::before,
.tarjeta *::after { box-sizing: border-box; }

.tarjeta-imagen {
  flex: 0 0 var(--firma-foto);
  width: var(--firma-foto);
  height: var(--firma-foto);
  border-radius: 25%;
  overflow: hidden;
  display: block;
  outline-offset: 3px;
}

.tarjeta-imagen img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  margin: 0;
  max-width: none;
  border-radius: 0;
}

.tarjeta-contenido {
  flex: 1 1 auto;
  min-width: 0; /* evita desbordes con textos largos */
}

.tarjeta .tarjeta-titulo {
  margin: 0 0 .4rem;
  padding: 0;
  font-size: 1.2rem;
  line-height: 1.25;
  font-weight: 700;
  border: 0;
}

.tarjeta .tarjeta-titulo a {
  color: inherit;
  text-decoration: none;

}

.tarjeta .tarjeta-titulo a:hover,
.tarjeta .tarjeta-titulo a:focus-visible { opacity: .75; }

.tarjeta .tarjeta-descripcion {
  margin: 0;
  max-width: 62ch;
  font-size: .95rem;
  line-height: 1.6;
  opacity: .88;
}

.tarjeta a:focus-visible { outline: 2px solid var(--firma-acento); }

/* Visor de imagen ampliada (lo crea firmas.js) */
.firma-visor {
  padding: 0;
  border: 0;
  background: transparent;
  max-width: 94vw;
  max-height: 94vh;
  overflow: visible;
}
.firma-visor::backdrop { background: rgba(0, 0, 0, .8); }
.firma-visor img {
  display: block;
  max-width: 94vw;
  max-height: 90vh;
  border-radius: 8px;
  cursor: zoom-out;
}

/* Celular y tableta vertical */
@media (max-width: 600px) {
  .tarjeta {
    flex-direction: column;
    text-align: center;
    gap: 1rem;
    padding: 1.25rem 1rem;
    margin-top: 2rem;
  }
  .tarjeta { --firma-foto: 104px; }
  .tarjeta .tarjeta-descripcion { margin-inline: auto; }
}

@media (prefers-reduced-motion: no-preference) {
  .tarjeta .tarjeta-titulo a { transition: opacity .15s ease; }
}
