/* ==========================================================
   REDE PINHALMED — cartões das outras clínicas (3D + brilho)
   Squad Digital · pm-clinicas-v1.css
   Secção colocada logo abaixo de #contactos.
   ========================================================== */

.pmcl {
  position: relative;
  padding: 6rem 1.25rem 7rem;
  background:
    radial-gradient(120% 90% at 8% -10%, #eef7fb 0%, rgba(238, 247, 251, 0) 58%),
    radial-gradient(90% 80% at 100% 0%, #f2fbf6 0%, rgba(242, 251, 246, 0) 55%),
    #ffffff;
  overflow: hidden;
}

@media (min-width: 640px) { .pmcl { padding-left: 2rem; padding-right: 2rem; } }
@media (min-width: 1024px) { .pmcl { padding: 8rem 3rem; } }

.pmcl-inner {
  max-width: 1260px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.pmcl-head { margin-bottom: 3.25rem; }

/* ---------- grelha ---------- */

.pmcl-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.65rem;
  perspective: 1400px;
}

@media (min-width: 680px) {
  .pmcl-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1080px) {
  .pmcl-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.85rem; }
}

/* ---------- cartão ---------- */

.pmcl-card {
  --rx: 0deg;
  --ry: 0deg;
  --mx: 50%;
  --my: 0%;
  --lift: 0px;
  position: relative;
  display: flex;
  flex-direction: column;
  border-radius: 1.75rem;
  background: #ffffff;
  border: 1px solid #d9e6ec;
  box-shadow: 0 14px 38px rgba(16, 54, 84, .08);
  overflow: hidden;
  isolation: isolate;
  transform: perspective(1400px) rotateX(var(--rx)) rotateY(var(--ry)) translate3d(0, var(--lift), 0);
  transition: transform .45s cubic-bezier(.22, .68, .36, 1),
              box-shadow .45s cubic-bezier(.22, .68, .36, 1),
              border-color .45s ease;
  will-change: transform;
}

.pmcl-card.is-active {
  border-color: #b6dcea;
  box-shadow:
    0 34px 70px rgba(11, 103, 174, .20),
    0 0 0 1px rgba(11, 103, 174, .10),
    0 0 46px rgba(0, 191, 99, .12);
  transition: transform .12s ease-out, box-shadow .3s ease, border-color .3s ease;
}

/* brilho que segue o rato */
.pmcl-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  border-radius: inherit;
  opacity: 0;
  transition: opacity .35s ease;
  background: radial-gradient(
    46% 46% at var(--mx) var(--my),
    rgba(255, 255, 255, .55) 0%,
    rgba(160, 219, 255, .22) 38%,
    rgba(255, 255, 255, 0) 72%
  );
  mix-blend-mode: soft-light;
}

.pmcl-card.is-active::after { opacity: 1; }

/* aro luminoso */
.pmcl-card::before {
  content: "";
  position: absolute;
  inset: -1px;
  z-index: 4;
  pointer-events: none;
  border-radius: inherit;
  padding: 1px;
  opacity: 0;
  transition: opacity .35s ease;
  background: linear-gradient(135deg, rgba(11, 103, 174, .75), rgba(0, 191, 99, .55), rgba(11, 103, 174, 0) 70%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
          mask-composite: exclude;
}

.pmcl-card.is-active::before { opacity: 1; }

/* ---------- foto ---------- */

.pmcl-media {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #e7eff3;
}

.pmcl-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: scale(1.02);
  transition: transform .7s cubic-bezier(.22, .68, .36, 1);
}

.pmcl-card.is-active .pmcl-media img { transform: scale(1.08); }

.pmcl-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(9, 45, 72, 0) 42%, rgba(9, 45, 72, .55) 100%);
}

.pmcl-tag {
  position: absolute;
  z-index: 2;
  left: 1rem;
  top: 1rem;
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  padding: .42rem .78rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, .92);
  color: #0b67ae;
  font-size: .64rem;
  font-weight: 800;
  letter-spacing: .13em;
  text-transform: uppercase;
  backdrop-filter: blur(6px);
  box-shadow: 0 6px 18px rgba(9, 45, 72, .16);
}

.pmcl-tag i {
  width: .42rem;
  height: .42rem;
  border-radius: 50%;
  background: #00bf63;
  display: inline-block;
}

/* ---------- corpo ---------- */

.pmcl-body {
  display: flex;
  flex-direction: column;
  gap: .9rem;
  padding: 1.55rem 1.6rem 1.7rem;
  flex: 1 1 auto;
}

.pmcl-name {
  margin: 0;
  font-size: 1.38rem;
  font-weight: 800;
  letter-spacing: -.035em;
  color: #173d5a;
  line-height: 1.15;
}

.pmcl-name a {
  color: inherit;
  text-decoration: none;
  transition: color .3s ease;
}

.pmcl-card.is-active .pmcl-name a { color: #0b67ae; }

/* a ligação do título cobre o cartão inteiro */
.pmcl-name a::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
}

.pmcl-address {
  margin: 0;
  font-size: .92rem;
  line-height: 1.6;
  color: #638096;
}

.pmcl-actions {
  position: relative;
  z-index: 2;
  margin-top: auto;
  padding-top: 1.05rem;
  border-top: 1px solid #e6eef1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .55rem;
}

.pmcl-btn {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  padding: .52rem .85rem;
  border-radius: 999px;
  font-size: .82rem;
  font-weight: 700;
  text-decoration: none;
  transition: background-color .3s ease, color .3s ease, transform .3s ease;
}

.pmcl-btn svg { width: .95rem; height: .95rem; flex: none; }

.pmcl-btn-tel {
  background: #eaf4fb;
  color: #0b67ae;
}

.pmcl-btn-tel:hover { background: #0b67ae; color: #fff; transform: translateY(-1px); }

.pmcl-btn-map {
  background: #edf7f1;
  color: #0b7a49;
}

.pmcl-btn-map:hover { background: #00bf63; color: #fff; transform: translateY(-1px); }

.pmcl-visit {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  margin-left: auto;
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .04em;
  color: #8aa2b3;
  transition: color .3s ease, gap .3s ease;
}

.pmcl-card.is-active .pmcl-visit { color: #0b67ae; gap: .62rem; }

.pmcl-note {
  margin: 2.4rem 0 0;
  font-size: .78rem;
  color: #8aa2b3;
}

/* ---------- acessibilidade / suportes ---------- */

.pmcl-card a:focus-visible {
  outline: 3px solid #0b67ae;
  outline-offset: 3px;
  border-radius: .55rem;
}

@media (hover: none), (pointer: coarse) {
  .pmcl-card { transform: none; }
  .pmcl-card::after, .pmcl-card::before { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .pmcl-card,
  .pmcl-media img,
  .pmcl-btn,
  .pmcl-visit { transition: none !important; }
  .pmcl-card { transform: none !important; }
}
