/* ============================================
   Portail Villa Borghèse — Étape 2
   Hero éditorial centré + cartes pleine image
   ============================================ */

/* --- Hero --- */

.portal-hero {
  position: relative;
  min-height: clamp(520px, 82vh, 720px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: clamp(96px, 12vw, 140px) 1.25rem clamp(72px, 10vw, 100px);
  background: var(--white);
  overflow: hidden;
  text-align: center;
}

.portal-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse 70% 55% at 50% 18%,
    var(--blue-50) 0%,
    transparent 68%
  );
  pointer-events: none;
}

.portal-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  pointer-events: none;
}

.portal-hero__inner {
  position: relative;
  z-index: 1;
  max-width: 720px;
}

.portal-hero__logo {
  display: inline-block;
  margin-bottom: 1.25rem;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--blue-500);
}

.portal-hero__title {
  margin-bottom: 1rem;
}

.portal-hero__subtitle {
  font-size: clamp(1.05rem, 1.5vw, 1.25rem);
  color: var(--ink-soft);
  margin-bottom: 1.25rem;
}

.portal-hero__meta {
  font-size: 0.9rem;
  color: var(--ink-soft);
  line-height: 1.8;
}

.portal-hero__meta a {
  color: var(--ink);
  font-weight: 500;
  text-decoration: underline;
  text-decoration-color: var(--blue-200);
  text-underline-offset: 3px;
}

.portal-hero__meta a:hover {
  color: var(--blue-600);
  text-decoration-color: var(--blue-400);
}

.portal-hero__meta-sep {
  margin-inline: 0.35rem;
  color: var(--ink-soft);
}

.portal-hero__scroll {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.portal-hero__scroll-line {
  width: 1px;
  height: 48px;
  background: linear-gradient(to bottom, var(--blue-400), transparent);
  transform-origin: top center;
  animation: portal-scroll-pulse 2.4s var(--ease) infinite;
}

.portal-hero__scroll-label {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

@keyframes portal-scroll-pulse {
  0%,
  100% {
    opacity: 0.45;
    transform: scaleY(0.65);
  }

  50% {
    opacity: 1;
    transform: scaleY(1);
  }
}

/* --- Header portail --- */

.portal-header .site-nav a {
  font-size: 0.9rem;
}

.portal-header .btn-primary {
  font-size: 0.875rem;
  padding: 0.7rem 1.25rem;
}

/* --- Cartes pôles --- */

.portal-poles {
  padding-block: clamp(64px, 8vw, 120px);
}

.portal-poles__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.pole-card {
  position: relative;
  display: flex;
  flex-direction: column;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--blue-200);
  box-shadow: var(--shadow);
  background: var(--white);
  color: var(--ink);
  text-decoration: none;
  transition:
    transform var(--duration) var(--ease),
    box-shadow var(--duration) var(--ease),
    border-color var(--duration) var(--ease);
}

.pole-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
  color: var(--ink);
}

.pole-card:focus-visible {
  outline: 2px solid var(--blue-500);
  outline-offset: 3px;
}

.pole-card__media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  flex-shrink: 0;
}

.pole-card__photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pole-card__placeholder {
  width: 100%;
  height: 100%;
  background:
    linear-gradient(145deg, var(--pole-soft) 0%, var(--blue-50) 45%, var(--white) 100%);
}

.pole-card__duotone {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(242, 248, 255, 0.35) 0%,
    var(--pole-duotone-mid) 55%,
    var(--pole-duotone-strong) 100%
  );
  mix-blend-mode: multiply;
  transition: opacity var(--duration) var(--ease);
}

.pole-card:hover .pole-card__duotone {
  opacity: 0.55;
}

.pole-card__body {
  padding: 1.35rem 1.35rem 1.5rem;
  background: var(--white);
}

.pole-card__eyebrow {
  display: block;
  margin-bottom: 0.45rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--pole-accent);
}

.pole-card__title {
  font-family: var(--font-heading);
  font-size: clamp(1.35rem, 2vw, 1.65rem);
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 0.5rem;
  letter-spacing: -0.02em;
}

.pole-card__phrase {
  font-size: 0.95rem;
  color: var(--ink-soft);
  line-height: 1.55;
  margin-bottom: 0.85rem;
}

.pole-card__list {
  margin-bottom: 1.1rem;
}

.pole-card__list li {
  position: relative;
  padding-left: 1rem;
  font-size: 0.875rem;
  color: var(--ink);
  line-height: 1.5;
  margin-bottom: 0.25rem;
}

.pole-card__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--pole-accent);
}

.pole-card__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.55rem 1.1rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--pole-accent);
  border: 1.5px solid var(--pole-accent);
  border-radius: 999px;
  transition:
    background-color var(--duration) var(--ease),
    color var(--duration) var(--ease),
    gap var(--duration) var(--ease);
}

.pole-card__arrow {
  display: inline-block;
  transition: transform var(--duration) var(--ease);
}

.pole-card:hover .pole-card__cta {
  background: var(--pole-accent);
  color: var(--white);
}

.pole-card:hover .pole-card__arrow {
  transform: translateX(4px);
}

/* Teintes par pôle */
.pole-card--ehpad {
  --pole-accent: #2d7fc4;
  --pole-soft: rgba(62, 146, 218, 0.18);
  --pole-duotone-mid: rgba(62, 146, 218, 0.42);
  --pole-duotone-strong: rgba(62, 146, 218, 0.62);
}

.pole-card--smr {
  --pole-accent: #1f6fb8;
  --pole-soft: rgba(31, 111, 184, 0.18);
  --pole-duotone-mid: rgba(31, 111, 184, 0.42);
  --pole-duotone-strong: rgba(31, 111, 184, 0.62);
}

.pole-card--maison {
  --pole-accent: #4a96c9;
  --pole-soft: rgba(111, 178, 232, 0.22);
  --pole-duotone-mid: rgba(111, 178, 232, 0.45);
  --pole-duotone-strong: rgba(111, 178, 232, 0.65);
}

/* Desktop : overlay pleine image 4:5 */
@media (min-width: 768px) {
  .pole-card {
    aspect-ratio: 4 / 5;
    display: block;
    border-left-width: 1px;
  }

  .pole-card:hover {
    border-color: var(--blue-200);
    border-left: 3px solid var(--pole-accent);
  }

  .pole-card__media {
    position: absolute;
    inset: 0;
    aspect-ratio: auto;
  }

  .pole-card__body {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;
    padding: 1.5rem 1.35rem 1.35rem;
    background: linear-gradient(
      to top,
      rgba(255, 255, 255, 0.98) 0%,
      rgba(255, 255, 255, 0.94) 42%,
      rgba(255, 255, 255, 0.78) 68%,
      rgba(255, 255, 255, 0) 100%
    );
  }
}

/* --- Valeurs --- */

.portal-values__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.portal-values__item {
  text-align: center;
  padding: 0 0.5rem;
}

.portal-values__item h3 {
  font-size: clamp(1.15rem, 1.5vw, 1.35rem);
  margin-bottom: 0.65rem;
}

.portal-values__item p {
  font-size: 0.95rem;
  color: var(--ink-soft);
  line-height: 1.6;
  max-width: 32ch;
  margin-inline: auto;
}

.portal-values__accent {
  width: 40px;
  height: 3px;
  margin: 0 auto 1rem;
  background: var(--ember);
  border-radius: 999px;
}

/* --- Localisation --- */

.portal-location__grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 2.5rem;
  align-items: start;
}

.portal-location__address {
  margin-bottom: 1.25rem;
  color: var(--ink-soft);
}

.portal-location__address strong {
  display: block;
  font-family: var(--font-heading);
  font-size: 1.35rem;
  color: var(--ink);
  margin-bottom: 0.35rem;
}

.portal-location__transports {
  margin-bottom: 1.5rem;
}

.portal-location__transports li {
  position: relative;
  padding-left: 1.1rem;
  font-size: 0.925rem;
  color: var(--ink-soft);
  margin-bottom: 0.4rem;
}

.portal-location__transports li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--blue-400);
}

.portal-location__map {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--blue-200);
  box-shadow: var(--shadow);
}

.portal-location__map iframe {
  width: 100%;
  height: 320px;
  border: 0;
  display: block;
}

/* --- Footer portail : réseaux mis en avant --- */

.portal-footer .site-footer__social-block {
  grid-column: 1 / -1;
  margin-top: 0.5rem;
  padding-top: 1.75rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.portal-footer .site-footer__social-heading {
  margin-bottom: 1rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.portal-footer .site-footer__social {
  gap: 1rem;
}

.portal-footer .site-footer__social a {
  padding: 0.7rem 1.35rem;
  font-size: 0.95rem;
}

/* --- Responsive --- */

@media (max-width: 900px) {
  .portal-poles__grid {
    grid-template-columns: 1fr;
    max-width: 480px;
    margin-inline: auto;
  }

  .portal-values__grid {
    grid-template-columns: 1fr;
    gap: 2.25rem;
    max-width: 420px;
    margin-inline: auto;
  }

  .portal-location__grid {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .portal-hero__scroll-line {
    animation: none;
    opacity: 0.6;
    transform: none;
  }

  .pole-card:hover .pole-card__arrow {
    transform: none;
  }
}
