/* =========================================================
   CIHF Oradores / Keynote Speakers
   ========================================================= */

.cihf-keynote-speakers,
.cihf-membros-conselho {
  width: 100%;
}

.cihf-membros-conselho__group {
  margin-bottom: 4rem;
}

.cihf-membros-conselho__group:last-child {
  margin-bottom: 0;
}

.cihf-membros-conselho__title {
  margin: 0 0 1.4rem;
  color: var(--cihf-text, #171717);
  font-size: 1.15rem;
  font-weight: 800;
  line-height: 1.2;
}

.cihf-keynote-speakers__grid {
  display: grid;
  grid-template-columns: repeat(4, 300px);
  gap: 28px;
}

.cihf-keynote-speaker {
  position: relative;
  overflow: hidden;
  width: 300px;
  height: 300px;
  background: var(--cihf-border, #e6e6e6);
  cursor: pointer;
}

.cihf-keynote-speaker__image,
.cihf-keynote-speaker__img {
  width: 100%;
  height: 100%;
}

.cihf-keynote-speaker__img {
  object-fit: cover;
  filter: grayscale(1);
  transition: transform 0.35s ease, filter 0.35s ease, opacity 0.35s ease;
}

.cihf-keynote-speaker__overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.4rem;
  opacity: 0;
  transition: opacity 0.25s ease, background 0.25s ease;
}

.cihf-keynote-speaker__name {
  margin: 0 0 0.25rem;
  color: var(--cihf-white, #ffffff);
  font-size: 1.15rem;
  font-weight: 800;
  line-height: 1.1;
}

.cihf-keynote-speaker__role {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.82rem;
  line-height: 1.35;
}

.cihf-keynote-speaker:hover .cihf-keynote-speaker__overlay,
.cihf-keynote-speaker:focus .cihf-keynote-speaker__overlay {
  opacity: 1;
  background:
    linear-gradient(
      180deg,
      rgba(0, 0, 0, 0) 35%,
      rgba(0, 0, 0, 0.46) 68%,
      rgba(0, 0, 0, 0.82) 100%
    );
}

.cihf-keynote-speaker:hover .cihf-keynote-speaker__img,
.cihf-keynote-speaker:focus .cihf-keynote-speaker__img {
  transform: scale(1.05);
  filter: grayscale(0);
  opacity: 0.92;
}

.cihf-keynote-speaker__name,
.cihf-keynote-speaker__role {
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.65);
}

/* =========================================================
   Modal Orador
   ========================================================= */

.cihf-speaker-modal,
.cihf-speaker-modal * {
  box-sizing: border-box;
}

.cihf-speaker-modal[hidden] {
  display: none !important;
}

.cihf-speaker-modal {
  position: fixed;
  inset: 0;
  z-index: 2147483647;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  overflow-x: hidden;
  overflow-y: auto;
}

.cihf-speaker-modal__overlay {
  position: fixed;
  inset: 0;
  background: rgba(5, 5, 5, 0.84);
}

.cihf-speaker-modal__dialog {
  position: relative;
  z-index: 2;
  width: min(100%, 1080px);
  max-width: calc(100vw - 48px);
  overflow: visible;
  background: #1a1a1a;
  color: #ffffff;
  border-radius: 0;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.5);
}

.cihf-speaker-modal__close {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 4;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0 !important;
  border-radius: 50%;
  background: transparent !important;
  color: transparent !important;
  font-size: 0 !important;
  line-height: 0 !important;
  cursor: pointer;
  box-shadow: none !important;
  transform: none;
}

.cihf-speaker-modal__close::before {
  content: "";
  display: block;
  width: 36px;
  height: 36px;
  background-image: url("/wp-content/uploads/2026/06/cross-circle-close.svg");
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  transform: none;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.cihf-speaker-modal__close:hover,
.cihf-speaker-modal__close:focus {
  background: transparent !important;
  color: transparent !important;
  outline: none;
}

.cihf-speaker-modal__close:hover::before,
.cihf-speaker-modal__close:focus::before {
  opacity: 0.82;
  transform: scale(1.08);
}

.cihf-speaker-modal__top {
  display: grid;
  grid-template-columns: 42% 58%;
  height: 500px;
  max-height: 500px;
  min-height: 0;
  overflow: hidden;
  background: #1a1a1a;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.cihf-speaker-modal__photo {
  position: relative;
  height: 500px;
  max-height: 500px;
  min-height: 0;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  background: var(--cihf-border, #e6e6e6);
  isolation: isolate;
}

.cihf-speaker-modal__photo::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: rgba(17, 17, 17, 0.34);
}

.cihf-speaker-modal__img {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center bottom;
  filter: grayscale(1);
  display: block;
}

.cihf-speaker-modal__info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 2.4rem 4rem 2.4rem 3.5rem;
  background: #1a1a1a;
}

.cihf-speaker-modal__name {
  order: 1;
  margin: 0 0 0.55rem;
  color: #ffffff;
  font-size: clamp(2rem, 3.2vw, 3.2rem);
  font-weight: 850;
  line-height: 1;
  letter-spacing: -0.045em;
}

.cihf-speaker-modal__cargo {
  order: 2;
  margin: 0 0 0.9rem;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.74rem;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.cihf-speaker-modal__info::after {
  order: 3;
  content: "";
  width: 76px;
  height: 1px;
  margin: 0 0 1.15rem;
  background: var(--cihf-border, #e6e6e6);
}

.cihf-speaker-modal__bio {
  order: 4;
  max-width: 620px;
  color: rgba(255, 255, 255, 0.76);
  font-size: 0.86rem;
  line-height: 1.55;
}

.cihf-speaker-modal__bio p {
  margin: 0 0 0.85rem;
  color: rgba(255, 255, 255, 0.76);
}

.cihf-speaker-modal__bio p:last-child {
  margin-bottom: 0;
}

.cihf-speaker-modal__more {
  display: none;
}

.cihf-speaker-modal__sessions {
  padding: 2.2rem 3.5rem 2.6rem;
  background: #1a1a1a;
}

.cihf-speaker-modal__sessions-title {
  position: relative;
  margin: 0 0 1.7rem;
  color: #ffffff;
  font-size: clamp(1.2rem, 1.7vw, 1.55rem);
  font-weight: 700;
  line-height: 1.2;
}

.cihf-speaker-modal__sessions-title::after {
  content: "";
  display: block;
  width: 76px;
  height: 1px;
  margin-top: 0.75rem;
  background: var(--cihf-border, #e6e6e6);
}

.cihf-speaker-modal__sessions-list {
  display: grid;
  gap: 0;
}

.cihf-speaker-modal__session {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.35rem;
  align-items: center;
  padding: 0.9rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.cihf-speaker-modal__session:first-child {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.cihf-speaker-modal__session-title {
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.35;
}

.cihf-speaker-modal__session-meta {
  color: rgba(255, 255, 255, 0.52);
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.4;
}

.cihf-speaker-modal__empty {
  margin: 0;
  color: rgba(255, 255, 255, 0.62);
  font-size: 0.95rem;
}

body.cihf-speaker-modal-open {
  overflow: hidden;
}

/* =========================================================
   Responsive
   ========================================================= */

@media (max-width: 1280px) {
  .cihf-keynote-speakers__grid {
    grid-template-columns: repeat(3, 300px);
  }
}

@media (max-width: 980px) {
  .cihf-keynote-speakers__grid {
    grid-template-columns: repeat(2, 300px);
  }

  .cihf-speaker-modal {
    align-items: flex-start;
    padding: 24px;
  }

  .cihf-speaker-modal__top {
    grid-template-columns: 1fr;
    height: auto;
    max-height: none;
  }

  .cihf-speaker-modal__photo {
    height: 360px;
    max-height: 360px;
  }

  .cihf-speaker-modal__info {
    padding: 2.4rem;
  }

  .cihf-speaker-modal__sessions {
    padding: 2.2rem 2.4rem 2.6rem;
  }
}

@media (max-width: 640px) {
  .cihf-keynote-speakers__grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .cihf-keynote-speaker {
    width: 100%;
    height: auto;
    aspect-ratio: 1 / 1;
  }

  .cihf-keynote-speaker__overlay {
    opacity: 1;
    background:
      linear-gradient(
        180deg,
        rgba(0, 0, 0, 0) 22%,
        rgba(0, 0, 0, 0.42) 58%,
        rgba(0, 0, 0, 0.82) 100%
      );
  }

  .cihf-keynote-speaker__name,
  .cihf-keynote-speaker__role {
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.65);
  }

  .cihf-speaker-modal {
    align-items: flex-start;
    padding: 14px;
  }

  .cihf-speaker-modal__dialog {
    max-width: calc(100vw - 28px);
    border-radius: 0;
    overflow: hidden;
  }

  .cihf-speaker-modal__close {
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
  }

  .cihf-speaker-modal__close::before {
    width: 32px;
    height: 32px;
  }

  .cihf-speaker-modal__photo {
    height: 260px;
    max-height: 260px;
    align-items: flex-start;
  }

  .cihf-speaker-modal__img {
    object-fit: contain !important;
    object-position: center top !important;
  }

  .cihf-speaker-modal__info {
    padding: 2rem 1.5rem;
  }

  .cihf-speaker-modal__name {
    font-size: clamp(2rem, 10vw, 2.8rem);
  }

  .cihf-speaker-modal__cargo {
    font-size: 0.74rem;
  }

  .cihf-speaker-modal__bio {
    display: flex;
    gap: 1rem;
    width: 100%;
    max-width: none;
    max-height: none;
    overflow-x: auto;
    overflow-y: hidden;
    position: relative;
    padding-bottom: 0.85rem;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
  }

  .cihf-speaker-modal__bio p {
    margin: 0;
    scroll-snap-align: start;
  }

  .cihf-speaker-modal__bio::-webkit-scrollbar {
    height: 4px;
  }

  .cihf-speaker-modal__bio::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.12);
  }

  .cihf-speaker-modal__bio::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.48);
  }

  .cihf-speaker-modal__more {
    display: none !important;
  }

  .cihf-speaker-modal__sessions {
    padding: 2rem 1.5rem 2.4rem;
  }

  .cihf-speaker-modal__session {
    grid-template-columns: 1fr;
    gap: 0.35rem;
  }

  .cihf-speaker-modal__session-meta {
    white-space: normal;
  }
}