/**
 * Estilo das caixas "Leia também" / "Continue lendo" injetadas pelo
 * IBETP_SEO_Link_Injector. Usado no front-end (single post) e no preview do editor.
 *
 * Design system IBETP: Sora + DM Sans, cantos arredondados, sombra suave,
 * cores de marca em OKLCH com fallback HEX.
 */

.ibetp-related-box {
  margin: 32px 0;
  padding: 22px 24px;
  background: linear-gradient(135deg, #f7f9fc 0%, #eef2f8 100%);
  border-left: 4px solid #2563eb;
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.04), 0 1px 3px rgba(15, 23, 42, 0.06);
  font-family: 'DM Sans', system-ui, -apple-system, sans-serif;
}

.ibetp-related-box.ibetp-related-end {
  background: linear-gradient(135deg, #fef9f5 0%, #fff5e6 100%);
  border-left-color: #f59e0b;
}

.ibetp-related-heading {
  margin: 0 0 16px 0 !important;
  font-family: 'Sora', system-ui, sans-serif;
  font-size: 1.15em;
  font-weight: 700;
  color: #0f172a;
  letter-spacing: -0.01em;
}

.ibetp-related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}

.ibetp-related-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px;
  background: #ffffff;
  border-radius: 10px;
  text-decoration: none;
  color: inherit;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03);
}

.ibetp-related-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
  border-color: #2563eb;
  text-decoration: none;
}

.ibetp-related-end .ibetp-related-card:hover {
  border-color: #f59e0b;
}

.ibetp-related-thumb {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #f1f5f9;
  border-radius: 6px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6em;
}

.ibetp-related-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ibetp-related-no-thumb {
  font-size: 2.4em;
  opacity: 0.4;
}

.ibetp-related-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ibetp-related-title {
  font-size: 0.97em;
  font-weight: 600;
  line-height: 1.35;
  color: #0f172a;
  display: block;
}

.ibetp-related-excerpt {
  font-size: 0.82em;
  line-height: 1.45;
  color: #64748b;
  display: block;
}

/* Internal-link injetado pelo Orphan Fighter — só destaca se hover */
a.ibetp-internal-link {
  border-bottom: 1px solid currentColor;
}

/* Mobile */
@media (max-width: 600px) {
  .ibetp-related-box {
    padding: 18px;
    margin: 24px 0;
  }
  .ibetp-related-grid {
    grid-template-columns: 1fr;
  }
}
