/* Páginas «El doctor» y «LĀR CLINIC» (22-sep): complementos sobre la plantilla interior A.
   Revisión del squad (docs/reviews/paginas/): heros, ritmo, publicaciones, tarjetas, contraste, foco y movimiento. */

:root { --sage-deep: #56625A; } /* salvia un paso más oscura: 5,26:1 sobre marfil para texto pequeño */

/* ───────── Heros ───────── */
/* El doctor: texto a la izquierda, retrato real a la derecha; la altura la fija el diseño, no la foto. */
.a-hero--doctor { display: grid; grid-template-columns: minmax(0, 52%) minmax(0, 48%); grid-template-rows: minmax(0, 1fr); background: #171412; }
.treatment--a .a-hero--doctor { height: min(720px, calc(100svh - var(--header-h))); min-height: 0; }
.a-hero--doctor .a-hero-content { grid-column: 1; grid-row: 1; padding-block: 40px 48px; }
.a-hero-image--doctor { position: relative; grid-column: 2; grid-row: 1; inset: auto; width: 100%; height: 100%; min-height: 0; object-fit: cover; object-position: 50% 38%; filter: sepia(.18) saturate(.85) brightness(.9); }
.a-hero--doctor::before { content: ''; position: absolute; top: 0; bottom: 0; left: 52%; width: 16%; z-index: 1; background: linear-gradient(90deg, #171412, rgba(23, 20, 18, 0)); pointer-events: none; }
.a-hero--doctor::after { background: linear-gradient(90deg, rgba(23, 20, 18, 0) 60%, rgba(23, 20, 18, .38) 100%); pointer-events: none; }
.a-hero--doctor h1 strong { font-weight: 700; }
.treatment--a .a-hero--doctor .a-hero-down { position: static; margin-top: 22px; }

/* LĀR: logotipo como titular, con aire arriba y abajo. */
.a-hero-image--lar { object-position: center 62%; }
.a-hero--lar::after { background: linear-gradient(90deg, rgba(26, 23, 20, .8), rgba(26, 23, 20, .18) 62%), linear-gradient(0deg, rgba(26, 23, 20, .72), transparent 52%); }
.a-hero--lar .a-hero-content { padding-block: 48px 56px; }
.lar-hero-logo { display: block; width: clamp(220px, 21vw, 300px); height: auto; margin-bottom: 6px; }
.a-hero--lar h1 { max-width: none; }

/* ───────── Sistema: enlaces, foco, etiquetas ───────── */
.t-text-link--light { color: var(--ivory); }
.t-text-link--light:hover { color: #b9c5b5; }
.a-operation .a-two-copy .t-copy .t-text-link { margin-top: 12px; }
.a-operation :focus-visible { outline-color: var(--ivory); }
.page-doctor main :is(a, button), .page-lar main :is(a, button) { scroll-margin-top: calc(var(--header-h) + 24px); }
.page-doctor .t-text-link span, .page-lar .t-text-link span { transition: transform .35s var(--ease-out); }
.page-doctor .t-text-link:hover span, .page-lar .t-text-link:hover span { transform: translate(3px, -3px); }
.page-doctor .t-text-link:not(.t-text-link--light), .page-lar .t-text-link:not(.t-text-link--light) { transition: color .3s var(--ease-out); }
.page-doctor .t-text-link:not(.t-text-link--light):hover, .page-lar .t-text-link:not(.t-text-link--light):hover { color: var(--cacao); }
.page-doctor .a-index a, .page-lar .a-index a { transition: color .3s var(--ease-out); }
.page-doctor .a-index a:hover, .page-lar .a-index a:hover { color: var(--cacao); }
.page-doctor .a-index a > span:first-child, .page-lar .a-index a > span:first-child { color: var(--sage-deep); }
.treatment--a .t-crumb a { display: inline-block; padding: 12px 6px; margin: -12px -6px; }

/* ───────── El doctor · trayectoria ───────── */
.cv-list { list-style: none; margin: 8px 0 0; padding: 0; }
.cv-list li { display: grid; grid-template-columns: 168px 1fr; gap: 24px; padding: 24px 0; border-top: 1px solid #b4b6aa; }
.cv-list li:last-child { border-bottom: 1px solid #b4b6aa; }
.cv-list__label { font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--sage-deep); padding-top: 7px; }
.cv-list p { margin: 0; font-size: 18px; line-height: 1.65; color: var(--ink-70); }

.page-doctor .credentials { grid-column: 1 / -1; padding-block: 0 70px; }
.credentials h3 { margin-bottom: 24px; }
.credentials__grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.credentials__grid a { display: grid; gap: 14px; color: var(--ink); text-decoration: none; }
.credentials__grid img { width: 100%; height: 240px; object-fit: contain; background: var(--ivory); padding: 12px; }
.credentials__grid span { font-size: 15px; line-height: 1.5; text-decoration: underline; text-underline-offset: 4px; }
.credentials__grid a:focus-visible { outline: 2px solid var(--cacao); outline-offset: 6px; }
@media (max-width: 1100px) { .credentials__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 800px) { .credentials__grid { grid-template-columns: 1fr; } .page-doctor .credentials { padding-bottom: 48px; } }

/* ───────── El doctor · publicaciones (bandeja arena de la home) ───────── */
.pubs__list { list-style: none; margin: 0; padding: 24px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; align-self: start; background: #e0d9cf; }
.pubs__list li { display: grid; grid-template-rows: subgrid; grid-row: span 3; gap: 10px; }
.pubs__list img { width: 100%; height: auto; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 6px; background: #f5f0e8; box-shadow: 0 12px 24px rgba(47, 46, 44, .07); }
.pubs__list img.pubs__cover--wide { object-fit: contain; padding: 8%; }
.pubs__list span { font-size: 11px; font-weight: 500; letter-spacing: .14em; line-height: 1.5; text-transform: uppercase; color: var(--sage-deep); align-self: end; }
.pubs__list p { margin: 0; font-size: 15px; line-height: 1.4; letter-spacing: -.01em; color: var(--ink); }

/* ───────── El doctor · áreas (ritmo escalonado y flecha de la home) ───────── */
.practice { border-top: 0; }
.practice__head { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0; align-items: start; margin-bottom: 56px; }
.practice__head .t-kicker { margin-bottom: 28px; }
.practice__head h2 { margin-bottom: 26px; }
.practice__head .t-copy { max-width: 64ch; }
.area-cards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1.25fr .85fr .9fr; gap: clamp(22px, 3.5vw, 60px); align-items: start; }
.area-card { position: relative; display: grid; gap: 14px; }
.area-card:nth-child(2) { margin-top: 96px; }
.area-card:nth-child(3) { margin-top: 36px; }
.area-card__figure { position: relative; margin: 0; overflow: hidden; aspect-ratio: 4 / 5; background: var(--sand); }
.area-card:nth-child(2) .area-card__figure { aspect-ratio: .9; }
.area-card:nth-child(3) .area-card__figure { aspect-ratio: .95; }
.area-card__figure img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease-out); }
.area-card h3 { margin-top: 8px; }
.area-card__link { color: inherit; text-decoration: none; }
.area-card__link::after { content: ''; position: absolute; inset: 0; }
.area-card__link:focus-visible { outline: none; }
.area-card:has(.area-card__link:focus-visible) { outline: 2px solid var(--cacao); outline-offset: 6px; }
.area-card:hover .area-card__figure img { transform: scale(1.035); }
.area-card:hover .reading-card__arrow { transform: rotate(45deg); background: white; }
.area-card p { margin: 0; font-size: 16px; line-height: 1.65; color: #53514c; }
.area-card .t-text-link { margin-top: 6px; min-height: 48px; }
.area-card:hover .t-text-link { color: var(--cacao); }
.area-card:hover .t-text-link span { transform: translate(3px, -3px); }

/* ───────── LĀR · el espacio: fotos a toda la anchura de la franja ───────── */
.space { row-gap: 0; }
.space > div { display: contents; }
.space h2, .space .a-two-copy { grid-column: 2; }
.space__photos { grid-column: 1 / -1; display: grid; grid-template-columns: 1.6fr 1fr; gap: clamp(18px, 2vw, 28px); margin-top: 64px; align-items: end; }
.space__photo { margin: 0; overflow: hidden; background: var(--sand); }
.space__photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.space__photo--tall { aspect-ratio: 16 / 11; }
.space__photo--tall img { object-position: center 38%; }
.space__photo--wide { aspect-ratio: 4 / 5; margin-bottom: 8%; }
.space__photo--wide img { object-position: center 40%; }

/* ───────── LĀR · práctica, visita y dónde consultar ───────── */
.practice__links { display: flex; flex-wrap: wrap; gap: 0 36px; }
.practice__links .t-text-link { margin-top: 14px; }
.page-lar .a-operation-photo img { object-position: center 30%; }
.page-doctor .a-operation-photo { height: min(62vh, 640px); }
.page-doctor .a-operation-photo img { object-position: center 62%; }
.place .t-risks article .btn { margin-top: 26px; }
.place .t-text-link { margin-top: 18px; }

/* ───────── Aparición al hacer scroll (sin JavaScript nuevo) ───────── */
@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    .page-doctor [data-reveal], .page-lar [data-reveal] { animation: t-reveal linear both; animation-timeline: view(); animation-range: entry 0% entry 40%; }
    @keyframes t-reveal { from { opacity: 0; transform: translateY(26px); } to { opacity: 1; transform: none; } }
  }
}

/* ───────── Tablet ───────── */
@media (max-width: 1100px) {
  .pubs__list { gap: 14px; }
  .area-cards { gap: 22px; }
  .area-card:nth-child(2) { margin-top: 48px; }
  .area-card:nth-child(3) { margin-top: 16px; }
}

/* ───────── Móvil ───────── */
@media (max-width: 800px) {
  /* El doctor: retrato arriba a sangre y texto debajo sobre fondo sólido. */
  .a-hero--doctor { grid-template-columns: 1fr; grid-template-rows: auto auto; }
  .treatment--a .a-hero--doctor { height: auto; min-height: 0; }
  .a-hero--doctor::before { display: none; }
  .a-hero--doctor::after { background: linear-gradient(0deg, #171412 0, #171412 58%, rgba(23, 20, 18, .6) 66%, rgba(23, 20, 18, .06) 76%, transparent); }
  .a-hero-image--doctor { grid-column: 1; grid-row: 1; height: 118vw; max-height: 520px; object-position: 50% 18%; }
  .a-hero--doctor .a-hero-content { grid-row: 2; margin-top: -72px; padding-top: 0; }
  .a-hero--doctor .t-crumb { margin-bottom: 28px; }
  /* LĀR: la entradilla no pisa el travertino. */
  .a-hero--lar::after { background: linear-gradient(90deg, rgba(26, 23, 20, .85), rgba(26, 23, 20, .45) 70%), linear-gradient(0deg, rgba(26, 23, 20, .9), rgba(26, 23, 20, .6) 45%, transparent 80%); }
  .treatment--a .a-hero-down { min-height: 44px; }
  /* Índice de página: todo visible, sin desplazamiento lateral. */
  .page-doctor .a-index, .page-lar .a-index { flex-wrap: wrap; justify-content: flex-start; gap: 0 22px; overflow: visible; }

  .cv-list li { grid-template-columns: 1fr; gap: 6px; padding: 20px 0; }
  .cv-list__label { padding-top: 0; }

  .pubs__list { grid-template-columns: 1fr; gap: 22px; padding: 20px; }
  .pubs__list li { grid-template-rows: auto 1fr; grid-template-columns: 96px 1fr; grid-row: auto; column-gap: 16px; row-gap: 6px; align-items: start; }
  .pubs__list img { grid-row: 1 / 3; }
  .pubs__list span { align-self: start; }
  .pubs__list p { font-size: 15px; line-height: 1.5; }

  .practice__head { margin-bottom: 32px; }
  .area-cards { grid-template-columns: 1fr; gap: 28px; }
  .area-card:nth-child(2), .area-card:nth-child(3) { margin-top: 0; }
  .area-card__figure, .area-card:nth-child(2) .area-card__figure, .area-card:nth-child(3) .area-card__figure { aspect-ratio: 4 / 3; }
  .area-card__figure img { object-position: 50% 22%; }

  .space h2, .space .a-two-copy { grid-column: auto; }
  .space__photos { grid-column: auto; grid-template-columns: 1fr; gap: 12px; margin-top: 36px; }
  .space__photo--tall { aspect-ratio: 4 / 5; width: 100vw; margin-left: calc(-1 * var(--gutter)); }
  .space__photo--tall img { object-position: center 30%; }
  .space__photo--wide { aspect-ratio: 16 / 10; margin-bottom: 0; }
  .page-doctor .a-operation-photo { height: 330px; }
}

@media (prefers-reduced-motion: reduce) {
  .area-card__figure img, .reading-card__arrow, .page-doctor .t-text-link span, .page-lar .t-text-link span { transition: none; }
  .area-card:hover .area-card__figure img, .area-card:hover .reading-card__arrow, .area-card:hover .t-text-link span { transform: none; }
}

/* Preserve the highlighted words without forcing an unbroken mobile heading. */
@media (max-width: 800px) {
  .page-doctor main h2 .t-brush { white-space: normal; }
  html[lang="en-GB"] .page-lar #donde h2 .t-brush { white-space: normal; }
}

/* Fotos nuevas (GUS-52): en pantallas de 1920 px el hueco de «Una valoración antes de decidir» se vuelve casi cuadrado: se baja el encuadre para no cortar las manos. */
@media (min-width: 1800px) { .page-lar .a-consult-photo img { object-position: 50% 55%; } }

/* Títulos y certificaciones (el-doctor): aire sobre el título, tarjetas de la misma proporción con el diploma entero
   (object-fit: contain sobre fondo neutro, sin estirar), pie con qué es, quién lo emite y el año, y diploma ampliable. */
.page-doctor .credentials { grid-column: 1 / -1; padding-block: clamp(56px, 7vw, 104px) clamp(56px, 6vw, 88px); }
.credentials h3 { margin-bottom: clamp(24px, 3vw, 40px); font-size: clamp(26px, 2.6vw, 38px); font-weight: 300; letter-spacing: -.02em; line-height: 1.15; }
.credentials__grid { gap: clamp(28px, 3vw, 44px) clamp(20px, 2.4vw, 36px); }
.credentials__grid a { gap: 16px; align-content: start; cursor: zoom-in; }
.credentials__grid img { height: auto; aspect-ratio: 4 / 3; object-fit: contain; background: #efe8e1; padding: clamp(14px, 1.8vw, 26px); transition: background .3s var(--ease-out); }
.credentials__grid a:hover img { background: #f6f1eb; }
.credentials__grid span { font-size: 15px; line-height: 1.55; color: var(--ink-70); text-decoration: none; max-width: 38ch; }
.credentials__grid a:hover span { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.credentials-dialog { border: 0; padding: 0; background: transparent; width: min(1100px, 94vw); max-height: 94vh; overflow: visible; }
.credentials-dialog::backdrop { background: rgba(26, 23, 20, .84); }
.credentials-dialog img { display: block; max-width: 100%; max-height: 80vh; margin-inline: auto; background: #fff; }
.credentials-dialog p { margin: 14px 0 0; color: #efe8e1; font-size: 15px; line-height: 1.5; text-align: center; }
.credentials-dialog__close { position: absolute; top: -48px; right: 0; width: 44px; height: 44px; border: 0; border-radius: 50%; background: #efe8e1; color: var(--graphite); font-size: 28px; line-height: 1; cursor: pointer; }
.credentials-dialog__close:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
