/* Scheda partner (popup) - colori e font del sito: oro #deb63a, blu #1f242c, Host Grotesk / Inter */

.team_part.mp-apribile {
  cursor: pointer;
}

.team_part.mp-apribile:focus-visible {
  outline: 3px solid var(--gcid-primary-color, #deb63a);
  outline-offset: 3px;
}

html.mp-scheda-aperta,
html.mp-scheda-aperta body {
  overflow: hidden;
}

.mp-scheda {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.mp-scheda[hidden] {
  display: none;
}

.mp-scheda__overlay {
  position: absolute;
  inset: 0;
  background: rgba(31, 36, 44, 0.88);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.mp-scheda__box {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 380px) minmax(0, 1fr);
  align-items: stretch;
  width: 100%;
  max-width: 1040px;
  background: #ffffff;
  border-top: 4px solid var(--gcid-primary-color, #deb63a);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.mp-scheda.is-aperta .mp-scheda__overlay,
.mp-scheda.is-aperta .mp-scheda__box {
  opacity: 1;
  transform: none;
}

.mp-scheda__foto {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--gcid-secondary-color, #1f242c);
  overflow: hidden;
}

/* colonna sotto la foto: sede e logo */
.mp-scheda__lato {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 26px;
  padding: 30px 32px 32px;
}

.mp-scheda__sede[hidden] {
  display: none;
}

.mp-scheda__sede-label {
  display: block;
  margin-bottom: 6px;
  color: var(--gcid-primary-color, #deb63a);
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.mp-scheda__sede-val {
  display: block;
  color: #ffffff;
  font-family: 'Host Grotesk', Helvetica, Arial, sans-serif;
  font-size: 17px;
  font-weight: 600;
  line-height: 1.4;
}

.mp-scheda__firma {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: auto;
  padding-top: 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

/* simbolo M&P: il PNG bianco fa da maschera, il colore e' quello del brand */
.mp-scheda__logo {
  display: block;
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
  background-color: var(--gcid-primary-color, #deb63a);
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-size: contain;
  mask-size: contain;
  -webkit-mask-position: center;
  mask-position: center;
}

.mp-scheda__firma-testo {
  color: #ffffff;
  font-family: 'Host Grotesk', Helvetica, Arial, sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.25;
}

.mp-scheda__firma small {
  display: block;
  color: var(--gcid-primary-color, #deb63a);
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* foto nelle sue proporzioni, mai ingrandita: le originali sono piccole (428 px) */
.mp-scheda__foto > img {
  display: block;
  width: 100%;
  max-width: 428px;
  height: auto;
  margin: 0 auto;
}

.mp-scheda__info {
  min-height: 420px;
  max-height: min(680px, calc(100vh - 52px));
  padding: 48px 48px 44px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: var(--gcid-primary-color, #deb63a) transparent;
}

.mp-scheda__info:focus {
  outline: none;
}

.mp-scheda__info:focus-visible {
  box-shadow: inset 0 0 0 2px var(--gcid-primary-color, #deb63a);
}

.mp-scheda__area {
  display: inline-block;
  padding: 4px 16px;
  background: var(--gcid-secondary-color, #1f242c);
  color: #ffffff;
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.6;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.mp-scheda__nome {
  margin: 16px 0 0;
  padding: 0;
  color: var(--gcid-heading-color, #1f242c);
  font-family: 'Host Grotesk', Helvetica, Arial, sans-serif;
  font-size: 32px;
  font-weight: 700;
  line-height: 1.2;
}

.mp-scheda__linea {
  display: block;
  width: 60px;
  height: 3px;
  margin: 18px 0 22px;
  background: var(--gcid-primary-color, #deb63a);
}

.mp-scheda__testo {
  color: var(--gcid-body-color, #5e5e5e);
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  line-height: 1.7;
}

.mp-scheda__testo strong,
.mp-scheda__testo b {
  color: var(--gcid-heading-color, #1f242c);
  font-weight: 600;
}

.mp-scheda__testo ul,
.mp-scheda__testo ol {
  margin: 8px 0 16px;
  padding: 0;
  list-style: none;
}

.mp-scheda__testo li {
  position: relative;
  margin: 0 0 10px;
  padding-left: 20px;
}

.mp-scheda__testo li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 7px;
  height: 7px;
  background: var(--gcid-primary-color, #deb63a);
}

.mp-scheda__chiudi {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 0;
  background: var(--gcid-primary-color, #deb63a);
  color: #ffffff;
  font-size: 30px;
  line-height: 1;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.mp-scheda__chiudi:hover,
.mp-scheda__chiudi:focus-visible {
  background: var(--gcid-secondary-color, #1f242c);
  outline: none;
}

@media (max-width: 767px) {
  .mp-scheda {
    padding: 12px;
  }

  .mp-scheda__box {
    display: block;
    max-height: calc(100vh - 24px);
    overflow-y: auto;
    overscroll-behavior: contain;
  }

  .mp-scheda__foto > img {
    max-width: 100%;
  }

  .mp-scheda__info {
    min-height: 0;
    max-height: none;
    padding: 26px 22px 30px;
    overflow: visible;
  }

  .mp-scheda__nome {
    font-size: 26px;
  }

  .mp-scheda__testo {
    font-size: 14px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mp-scheda__overlay,
  .mp-scheda__box {
    transition: none;
  }
}

/* icona "apri scheda" sulle card del team: come l'overlay delle case study (ETmodules e02b su quadrato oro) */
.team_part {
  position: relative;
}

.team_part .team_social {
  display: none !important;
}

.mp-scheda-apri {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 5;
  width: 35px;
  height: 35px;
  background-color: var(--gcid-primary-color, #deb63a);
  color: #ffffff;
  font-family: ETmodules !important;
  font-size: 16px;
  font-weight: 400;
  line-height: 35px;
  text-align: center;
  opacity: 0;
  transition: opacity 0.3s, background-color 0.3s;
  pointer-events: none;
}

.mp-scheda-apri::before {
  content: '\e02b';
}

.team_part:hover .mp-scheda-apri,
.team_part:focus-visible .mp-scheda-apri {
  opacity: 1;
}

@media (hover: none) {
  .mp-scheda-apri {
    opacity: 1;
  }
}

.mp-scheda-apri {
  border-radius: 50%;
}

.mp-scheda-apri {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  font-size: 22px;
  line-height: 1;
}

.mp-scheda-apri::before {
  display: block;
  line-height: 1;
}

.mp-scheda-apri::before {
  font-size: 22px !important;
  width: 22px;
  height: 22px;
  text-align: center;
}
