/* Fuente única de verdad tipográfica para sitio público, micrositios y panel. */
@font-face {
  font-family: "Gelasio";
  src: url("../webfont/Gelasio-Variable.woff2") format("woff2");
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
}

@font-face {
  font-family: "Gelasio";
  src: url("../webfont/Gelasio-Italic-Variable.woff2") format("woff2");
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("../webfont/Inter-Variable.woff2") format("woff2");
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("../webfont/Inter-Italic-Variable.woff2") format("woff2");
  font-style: italic;
  font-weight: 400 500;
  font-display: swap;
}

/* Compatibilidad con el HTML histórico: los nombres heredados nunca cargan
   binarios anteriores; todos se resuelven a Gelasio o Inter. */
@font-face { font-family: "Publico-Roman"; src: url("../webfont/Gelasio-Variable.woff2") format("woff2"); font-style: normal; font-weight: 300 700; font-display: swap; }
@font-face { font-family: "Publico-light"; src: url("../webfont/Gelasio-Variable.woff2") format("woff2"); font-style: normal; font-weight: 300 700; font-display: swap; }
@font-face { font-family: "Publico-medium"; src: url("../webfont/Gelasio-Variable.woff2") format("woff2"); font-style: normal; font-weight: 300 700; font-display: swap; }
@font-face { font-family: "Geomanist-Book"; src: url("../webfont/Inter-Variable.woff2") format("woff2"); font-style: normal; font-weight: 400 500; font-display: swap; }
@font-face { font-family: "Geomanist-light"; src: url("../webfont/Inter-Variable.woff2") format("woff2"); font-style: normal; font-weight: 400 500; font-display: swap; }
@font-face { font-family: "Geomanist-regular"; src: url("../webfont/Inter-Variable.woff2") format("woff2"); font-style: normal; font-weight: 400 500; font-display: swap; }
@font-face { font-family: "OptimaLTStd"; src: url("../webfont/Inter-Variable.woff2") format("woff2"); font-style: normal; font-weight: 400 500; font-display: swap; }
@font-face { font-family: "OptimaLTStd-Bold"; src: url("../webfont/Inter-Variable.woff2") format("woff2"); font-style: normal; font-weight: 400 500; font-display: swap; }
:root {
  --font-title: "Gelasio", serif;
  --font-body: "Inter", sans-serif;
  --vw-font-editorial: var(--font-title);
  --vw-font-ui: var(--font-body);
  --vw-font-body: var(--font-body);
}

html,
body {
  font-family: var(--font-body);
  font-optical-sizing: auto;
  /* Nunca se sintetizan pesos inexistentes: Inter queda solo en 400 y 500. */
  font-synthesis: none;
}

/* El HTML histórico contiene <strong> y pesos inline. Conservamos la
   jerarquía semántica, pero Inter nunca supera Medium. */
:where(body) :where(strong, b) {
  font-weight: 500 !important;
}

/* Los controles y componentes heredados (incluido Slick) no deben reintroducir
   Arial u otra fuente de sistema mediante sus hojas de estilo internas. */
:where(button, input, textarea, select, option, label, code, pre, kbd, samp, table, th, td) {
  font-family: var(--font-body) !important;
}

/* La jerarquía editorial manda incluso cuando un HTML histórico conserva un
   style inline con el nombre de una familia anterior. */
:where(h1, h2, h3, h4, h5, h6),
:where(h1, h2, h3, h4, h5, h6) :where(span, a, strong, em),
.covid_title span {
  font-family: var(--font-title) !important;
}

/* Prácticas e Industrias dinámicas: Gelasio jerarquiza únicamente la
   introducción; el contenido completo se lee en Inter con párrafos reales. El
   atributo lo añade el renderer, por lo que las páginas históricas permanecen
   intactas. */
:is(.single[data-vw-content-kind="practice"], .single[data-vw-content-kind="industry"]) .single__content--intro,
:is(.single[data-vw-content-kind="practice"], .single[data-vw-content-kind="industry"]) .single__content--intro :where(p, span, a, strong, em, i) {
  color: #5f5f5f;
  font-family: var(--vw-font-editorial) !important;
  font-size: clamp(24px, 1.8vw, 28px);
  font-weight: 400;
  line-height: 1.34;
}

:is(.single[data-vw-content-kind="practice"], .single[data-vw-content-kind="industry"]) .single__content--intro {
  margin: 0 0 clamp(34px, 4vw, 54px);
}

:is(.single[data-vw-content-kind="practice"], .single[data-vw-content-kind="industry"]) .single__content--intro p {
  margin: 0;
}

:is(.single[data-vw-content-kind="practice"], .single[data-vw-content-kind="industry"]) .single__content--txt,
:is(.single[data-vw-content-kind="practice"], .single[data-vw-content-kind="industry"]) .single__content--txt :where(p, ul, ol, li, blockquote, table, tr, td, th, span, a, strong, em, i) {
  color: #666;
  font-family: var(--vw-font-body) !important;
  font-size: inherit;
  font-weight: 400;
  line-height: inherit;
}

:is(.single[data-vw-content-kind="practice"], .single[data-vw-content-kind="industry"]) .single__content--txt {
  font-size: clamp(17px, 1.25vw, 19px);
  line-height: 1.62;
  padding-bottom: clamp(56px, 7vw, 96px);
}

:is(.single[data-vw-content-kind="practice"], .single[data-vw-content-kind="industry"]) .single__content--txt p {
  margin: 0;
}

:is(.single[data-vw-content-kind="practice"], .single[data-vw-content-kind="industry"]) .single__content--txt p + p {
  margin-top: 1.35em;
}

:is(.single[data-vw-content-kind="practice"], .single[data-vw-content-kind="industry"]) .single__content--txt :where(ul, ol) {
  margin: 0 0 1.35em;
  padding-left: 1.25em;
}

/* Fichas dinámicas de abogados: el destacado conserva el acento editorial de
   Gelasio y la trayectoria se lee con Inter. Sólo afecta las fichas que el
   renderer marca como CMS, no las páginas históricas estáticas. */
.attorney[data-vw-content-kind="attorney"] .attorney__content--intro,
.attorney[data-vw-content-kind="attorney"] .attorney__content--intro :where(p, span, a, strong, em, i) {
  color: #5f5f5f;
  font-family: var(--vw-font-editorial) !important;
  font-size: clamp(24px, 1.8vw, 28px);
  font-weight: 400;
  line-height: 1.34;
}

.attorney[data-vw-content-kind="attorney"] .attorney__content--intro { margin: 0 0 clamp(34px, 4vw, 54px); }
.attorney[data-vw-content-kind="attorney"] .attorney__content--intro p,
.attorney[data-vw-content-kind="attorney"] .attorney__content--txt p { margin: 0; }

.attorney[data-vw-content-kind="attorney"] .attorney__content--txt,
.attorney[data-vw-content-kind="attorney"] .attorney__content--txt :where(p, ul, ol, li, blockquote, table, tr, td, th, span, a, strong, em, i) {
  color: #666;
  font-family: var(--vw-font-body) !important;
  font-size: inherit;
  font-weight: 400;
  line-height: inherit;
}

.attorney[data-vw-content-kind="attorney"] .attorney__content--txt { font-size: clamp(17px, 1.25vw, 19px); line-height: 1.62; padding-bottom: clamp(56px, 7vw, 96px); }
.attorney[data-vw-content-kind="attorney"] .attorney__content--txt p + p { margin-top: 1.35em; }
.attorney[data-vw-content-kind="attorney"] .attorney__content--txt :where(ul, ol) { margin: 0 0 1.35em; padding-left: 1.25em; }

/* --------------------------------------------------------------------------
   Ficha editorial de abogados
   --------------------------------------------------------------------------
   La introducción permanece disponible de inmediato. La trayectoria completa
   usa <details> nativo para que las publicaciones no queden al final de una
   biografía extensa y para que el perfil siga funcionando sin JavaScript.
   -------------------------------------------------------------------------- */
.attorney[data-vw-content-kind="attorney"] .attorney__content--intro {
  position: relative;
  margin: 0 0 20px;
}

/* La vista previa sugiere que hay trayectoria adicional sin sumar un segundo
   control. Al abrir <details>, la introducción vuelve a mostrarse completa. */
.attorney[data-vw-content-kind="attorney"] .attorney__content--intro:has(+ .attorney-bio-disclosure) {
  max-height: 7.2em;
  overflow: hidden;
}

.attorney[data-vw-content-kind="attorney"] .attorney__content--intro:has(+ .attorney-bio-disclosure)::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 2.25em;
  content: "";
  pointer-events: none;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0), #fff 88%);
}

.attorney[data-vw-content-kind="attorney"] .attorney__content:has(.attorney-bio-disclosure[open]) .attorney__content--intro {
  max-height: none;
  overflow: visible;
}

.attorney[data-vw-content-kind="attorney"] .attorney__content:has(.attorney-bio-disclosure[open]) .attorney__content--intro::after {
  display: none;
}

.attorney-bio-disclosure {
  margin: 0;
  border: 0;
  scroll-margin-top: 30px;
}

.attorney-bio-disclosure > summary {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0;
  padding: 0;
  color: #a91931;
  cursor: pointer;
  font-family: var(--vw-font-ui) !important;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.4;
  list-style: none;
}

.attorney-bio-disclosure > summary::-webkit-details-marker {
  display: none;
}

.attorney-bio-disclosure > summary::marker {
  content: "";
}

.attorney-bio-disclosure__hide {
  display: none;
}

.attorney-bio-disclosure[open] .attorney-bio-disclosure__show {
  display: none;
}

.attorney-bio-disclosure[open] .attorney-bio-disclosure__hide {
  display: inline;
}

.attorney-bio-disclosure__chevron {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
  transition: transform .2s ease;
}

.attorney-bio-disclosure[open] .attorney-bio-disclosure__chevron {
  transform: rotate(225deg) translate(-2px, -1px);
}

.attorney-bio-disclosure > summary:focus-visible,
.attorney-related-insights a:focus-visible {
  outline: 2px solid #a91931;
  outline-offset: 4px;
}

.attorney-bio-disclosure__content {
  display: grid;
  grid-template-rows: 0fr;
  margin-top: 0;
  padding-top: 0;
  overflow: hidden;
  border-top: 1px solid transparent;
  opacity: 0;
  transition: grid-template-rows .48s cubic-bezier(.22, 1, .36, 1), margin-top .36s ease, padding-top .36s ease, border-color .22s ease, opacity .24s ease;
}

.attorney-bio-disclosure__content > .attorney__content--txt {
  min-height: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
}

.attorney-bio-disclosure[open] .attorney-bio-disclosure__content {
  grid-template-rows: 1fr;
  margin-top: 30px;
  padding-top: 30px;
  border-color: #d4d4d0;
  opacity: 1;
}

.attorney[data-vw-content-kind="attorney"] .attorney-related-insights {
  clear: none;
  margin: 44px 0 clamp(64px, 7vw, 104px);
  padding: 0;
  border-top: 0;
  color: #5f5f5f;
  scroll-margin-top: 30px;
}

.attorney[data-vw-content-kind="attorney"] .attorney-related-insights__header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 7px 24px;
  margin-bottom: 21px;
}

.attorney[data-vw-content-kind="attorney"] .attorney-related-insights h2 {
  grid-column: 1;
  margin: 0;
  color: #5f5f5f;
  font-size: clamp(19px, 1.4vw, 22px);
  line-height: 1.2;
}

.attorney[data-vw-content-kind="attorney"] .attorney-related-insights__description {
  grid-column: 1;
  margin: 0;
}

.attorney[data-vw-content-kind="attorney"] .attorney-related-insights__more {
  grid-column: 2;
  grid-row: 1;
  align-self: center;
  padding: 0;
  border: 0;
  color: #5f5f5f;
  font-size: 10px;
  letter-spacing: .08em;
  text-transform: none;
}

.attorney[data-vw-content-kind="attorney"] .attorney-related-insights__grid {
  display: grid;
  grid-auto-columns: auto;
  grid-auto-flow: row;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
  overflow: visible;
  border: 0;
  scroll-snap-type: none;
}

.attorney[data-vw-content-kind="attorney"] .attorney-related-insights__item,
.attorney[data-vw-content-kind="attorney"] .attorney-related-insights__item:nth-child(even) {
  display: flex;
  min-width: 0;
  max-width: 100%;
  min-height: 280px;
  height: auto;
  aspect-ratio: auto;
  padding: 20px;
  background: #fff;
  border: 1px solid #d4d4d0;
  border-radius: 3px;
  transition: border-color .2s ease, transform .2s ease;
}

.attorney[data-vw-content-kind="attorney"] .attorney-related-insights__item:hover,
.attorney[data-vw-content-kind="attorney"] .attorney-related-insights__item:focus-within {
  border-color: #aaa9a4;
  transform: translateY(-2px);
}

.attorney[data-vw-content-kind="attorney"] .attorney-related-insights__body {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  min-width: 0;
  max-width: 100%;
}

.attorney[data-vw-content-kind="attorney"] .attorney-related-insights h3 {
  min-width: 0;
  overflow-wrap: anywhere;
  hyphens: auto;
  font-size: clamp(16px, 1.25vw, 19px);
  line-height: 1.2;
}

.attorney[data-vw-content-kind="attorney"] .attorney-related-insights h3 a {
  display: block;
  overflow-wrap: anywhere;
}

.attorney[data-vw-content-kind="attorney"] .attorney-related-insights__meta,
.attorney[data-vw-content-kind="attorney"] .attorney-related-insights__excerpt {
  min-width: 0;
  overflow-wrap: anywhere;
  hyphens: auto;
}

.attorney[data-vw-content-kind="attorney"] .attorney-related-insights__meta {
  color: #737373;
}

.attorney[data-vw-content-kind="attorney"] .attorney-related-insights__excerpt {
  display: -webkit-box;
  overflow: hidden;
  margin-top: 13px;
  color: #696969;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.attorney-related-insights__arrow {
  display: inline-block;
  margin-top: auto;
  color: #737373;
  font-family: var(--vw-font-ui) !important;
  font-size: 20px;
  font-weight: 400;
  line-height: 1;
  text-decoration: none;
}

/* Contenido relacionado de una publicación: a diferencia de la selección
   breve de la ficha de abogado, una nota puede tener hasta seis sugerencias.
   Nunca se presentan como un carrusel recortado: la retícula baja a otra fila
   y cada tarjeta deja que título y resumen fluyan de manera continua. */
.single > .news-related-insights {
  min-width: 0;
}

.single > .news-related-insights .news-related-insights__wrap {
  width: 100%;
  min-width: 0;
}

.single > .news-related-insights .news-related-insights__grid {
  display: grid;
  grid-auto-columns: auto;
  grid-auto-flow: row;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 14px;
  overflow: visible;
  border: 0;
  scroll-snap-type: none;
}

.single > .news-related-insights .news-related-insights__item,
.single > .news-related-insights .news-related-insights__item:first-child {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  max-width: 100%;
  padding: 20px;
  background: #fff;
  border: 1px solid #d4d4d0;
  border-radius: 3px;
}

.single > .news-related-insights .news-related-insights__body {
  min-width: 0;
  max-width: 100%;
}

.single > .news-related-insights .news-related-insights__meta,
.single > .news-related-insights h3,
.single > .news-related-insights h3 a,
.single > .news-related-insights .news-related-insights__excerpt {
  overflow-wrap: anywhere;
  hyphens: auto;
}

.single > .news-related-insights h3 a {
  color: #5f5f5f;
}

.single > .news-related-insights .news-related-insights__excerpt {
  margin-top: 13px;
}

@media (max-width: 780px) {
  .attorney[data-vw-content-kind="attorney"] .attorney__meta {
    padding-bottom: 42px;
  }

  .attorney[data-vw-content-kind="attorney"] .attorney-related-insights__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .single > .news-related-insights .news-related-insights__item,
  .single > .news-related-insights .news-related-insights__item:first-child {
    padding: 18px;
  }

}

@media (max-width: 640px) {
  .attorney[data-vw-content-kind="attorney"] .attorney-related-insights h2 {
    font-size: 19px;
  }

  .attorney[data-vw-content-kind="attorney"] .attorney-related-insights__header {
    grid-template-columns: 1fr;
    gap: 13px;
  }

  .attorney[data-vw-content-kind="attorney"] .attorney-related-insights__more {
    grid-column: 1;
    grid-row: auto;
    justify-self: start;
  }

  .attorney[data-vw-content-kind="attorney"] .attorney-related-insights__grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .attorney[data-vw-content-kind="attorney"] .attorney-related-insights__item,
  .attorney[data-vw-content-kind="attorney"] .attorney-related-insights__item:nth-child(even),
  .attorney[data-vw-content-kind="attorney"] .attorney-related-insights__item:nth-child(odd) {
    min-height: 0;
    padding: 20px;
    border: 1px solid #d4d4d0;
  }
}

@media print {
  .attorney[data-vw-content-kind="attorney"] .attorney__content--intro:has(+ .attorney-bio-disclosure) {
    max-height: none;
    overflow: visible;
  }

  .attorney[data-vw-content-kind="attorney"] .attorney__content--intro:has(+ .attorney-bio-disclosure)::after {
    display: none;
  }

  .attorney-bio-disclosure > summary,
  .attorney-related-insights {
    display: none !important;
  }

  .attorney-bio-disclosure__content {
    display: block !important;
    margin-top: 30px;
    padding-top: 30px;
    overflow: visible;
    border-color: #d4d4d0;
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .attorney-bio-disclosure__chevron,
  .attorney-bio-disclosure__content,
  .attorney[data-vw-content-kind="attorney"] .attorney-related-insights__item {
    transition: none;
  }

  .attorney[data-vw-content-kind="attorney"] .attorney-related-insights__item:hover,
  .attorney[data-vw-content-kind="attorney"] .attorney-related-insights__item:focus-within {
    transform: none;
  }
}

/* Elecciones explícitas desde CMS. `auto` no deja atributo y, por tanto,
   conserva exactamente la jerarquía heredada. Estos selectores llegan después
   de la tipografía de las plantillas para que una elección consciente pueda
   cambiar incluso un título, sin cargar ni aceptar ninguna fuente externa. */
:where([data-vw-font="gelasio"], [data-vw-font="gelasio"] *) {
  font-family: var(--vw-font-editorial) !important;
}

:where([data-vw-font="inter"], [data-vw-font="inter"] *) {
  font-family: var(--vw-font-body) !important;
}
