/* OFTALMOSERV V5 — índice de temas e guias, sem seletores globais. */
.ofs5-topics {
  padding: clamp(1rem, .7rem + 1vw, 1.5rem);
  margin-bottom: 2rem;
  border: 1px solid #d7e5ed;
  border-radius: 16px;
  background: #fff;
}
.ofs5-label {
  color: #0b3b5c;
  font-size: 1.125rem;
  font-weight: 750;
  line-height: 1.4;
  margin: 0 0 1rem;
}
.ofs5-topic-list {
  display: flex;
  flex-wrap: wrap;
  gap: .65rem;
  list-style: none;
  padding: 0;
  margin: 0;
}
.ofs5-topic-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  max-width: 100%;
  padding: .65rem .9rem;
  border: 1px solid #c6dce5;
  border-radius: 10px;
  background: #f2f8fa;
  color: #145267;
  font-size: .9375rem;
  font-weight: 650;
  line-height: 1.45;
  text-decoration: underline;
  text-underline-offset: .18em;
  overflow-wrap: anywhere;
}
.ofs5-topic-link:hover { background: #e5f1f5; color: #0b3b5c; }
.ofs5-topic-link:focus-visible,
.ofs5-guides-list a:focus-visible,
.ofs5-guide-link:focus-visible {
  outline: 3px solid #075985;
  outline-offset: 4px;
}
.ofs5-target { scroll-margin-top: 8rem; }
.ofs5-target:target { outline: 2px solid #147d92; outline-offset: 4px; }
.ofs5-guides-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .75rem;
  list-style: none;
  padding: 0;
  margin-top: 1.25rem;
}
.ofs5-guides-list > li {
  min-width: 0;
  border: 1px solid #d7e5ed;
  border-radius: 12px;
  background: #fff;
}
.ofs5-guides-list > li:first-child { grid-column: 1 / -1; background: #edf6f8; }
.ofs5-guides-list a {
  display: flex;
  align-items: center;
  min-height: 52px;
  padding: .9rem 1rem;
  color: #075985;
  font-size: 1rem;
  line-height: 1.65;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: .18em;
  overflow-wrap: anywhere;
}
.ofs5-guide-body { display: flex; flex-direction: column; padding: 1.3rem; }
.ofs5-guide-link {
  align-self: flex-start;
  margin-top: auto;
  padding-top: .5rem;
  min-height: 44px;
  color: #075985;
  text-decoration: underline !important;
  text-underline-offset: .18em;
}
@media (max-width: 575px) {
  .ofs5-guides-list { grid-template-columns: minmax(0, 1fr); }
  .ofs5-topic-list { gap: .5rem; }
  .ofs5-topic-list > li { max-width: 100%; }
  .ofs5-topic-link { font-size: .875rem; padding: .6rem .75rem; }
}
