/* Modal Comunidad Checkit */

.c-header-subnav__links .c-header-subnav__trigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  font-size: 12px;
  line-height: inherit;
  cursor: pointer;
  color: var(--s-color-header-text);
  opacity: 0.85;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.c-header-subnav__links .c-header-subnav__trigger:hover {
  color: var(--checkit-sky-deep);
  opacity: 1;
}

.c-comunidad-modal {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: grid;
  place-items: center;
  padding: 20px 16px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.28s ease, visibility 0.28s ease;
}

.c-comunidad-modal.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.c-comunidad-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 8, 23, 0.78);
  backdrop-filter: blur(8px);
}

.c-comunidad-modal__dialog {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 40% minmax(0, 1fr);
  width: min(1080px, 94vw);
  min-height: min(540px, 82vh);
  max-height: min(640px, 88vh);
  overflow: hidden;
  border-radius: 20px;
  border: 1px solid rgba(56, 189, 248, 0.2);
  background: #07111f;
  box-shadow:
    0 32px 90px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(255, 255, 255, 0.05) inset;
  transform: translateY(14px) scale(0.988);
  transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

.c-comunidad-modal.is-open .c-comunidad-modal__dialog {
  transform: translateY(0) scale(1);
}

.c-comunidad-modal__close {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 5;
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.88);
  color: #e2e8f0;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.c-comunidad-modal__close:hover {
  background: rgba(30, 41, 59, 0.95);
  border-color: rgba(56, 189, 248, 0.45);
}

.c-comunidad-modal__visual {
  position: relative;
  grid-column: 1;
  grid-row: 1;
  width: 100%;
  height: 100%;
  min-height: 100%;
  margin: 0;
  overflow: hidden;
  border: 0;
  border-radius: 0;
}

.c-comunidad-modal__visual img {
  width: 100%;
  height: 100%;
  min-height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
}

.c-comunidad-modal__visual::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(7, 17, 31, 0.04) 70%, rgba(7, 17, 31, 0.88) 100%);
  pointer-events: none;
}

.c-comunidad-modal__content {
  grid-column: 2;
  grid-row: 1;
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
  min-height: 0;
  height: 100%;
  padding: 24px 26px 20px 22px;
  box-sizing: border-box;
  background: linear-gradient(155deg, #0a1628 0%, #07111f 52%, #050b14 100%);
}

.c-comunidad-modal__head {
  padding-right: 34px;
}

.c-comunidad-modal__eyebrow {
  margin: 0 0 4px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #38bdf8;
}

.c-comunidad-modal__title {
  margin: 0 0 4px;
  font-family: 'Syne', 'Segoe UI', sans-serif;
  font-size: clamp(1.15rem, 1.8vw, 1.38rem);
  font-weight: 700;
  line-height: 1.22;
  color: #f8fafc;
}

.c-comunidad-modal__subtitle {
  margin: 0;
  font-size: 0.86rem;
  line-height: 1.45;
  color: rgba(203, 213, 225, 0.86);
}

.c-comunidad-modal__profiles {
  flex: 1 1 auto;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  align-items: stretch;
  min-height: 0;
}

.c-comunidad-profile-card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  min-height: 0;
  min-width: 0;
  padding: 14px 12px 12px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(15, 23, 42, 0.55);
  text-decoration: none;
  color: inherit;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.c-comunidad-profile-card:hover {
  border-color: rgba(56, 189, 248, 0.32);
  background: rgba(15, 23, 42, 0.72);
  transform: translateY(-1px);
}

.c-comunidad-profile-card__icon {
  width: 42px;
  height: 42px;
  margin-bottom: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: linear-gradient(145deg, rgba(14, 116, 144, 0.28), rgba(59, 130, 246, 0.14));
  border: 1px solid rgba(56, 189, 248, 0.18);
  color: #7dd3fc;
  font-size: 1.05rem;
}

.c-comunidad-profile-card__title {
  margin: 0 0 6px;
  font-family: 'Syne', 'Segoe UI', sans-serif;
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.25;
  color: #f1f5f9;
}

.c-comunidad-profile-card__text {
  flex: 1 1 auto;
  margin: 0 0 12px;
  font-size: 0.76rem;
  line-height: 1.48;
  color: rgba(203, 213, 225, 0.88);
}

.c-comunidad-profile-card__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 36px;
  margin-top: auto;
  padding: 8px 10px;
  border-radius: 999px;
  background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%);
  color: #fff;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  box-shadow: 0 6px 16px rgba(14, 165, 233, 0.22);
  pointer-events: none;
}

.c-comunidad-profile-card:hover .c-comunidad-profile-card__btn {
  filter: brightness(1.06);
}

body.comunidad-modal-open {
  overflow: hidden;
}

.c-comunidad-modal__foot {
  flex-shrink: 0;
  padding-top: 2px;
}

.c-comunidad-modal__note {
  margin: 0 0 10px;
  font-size: 0.72rem;
  line-height: 1.45;
  color: rgba(203, 213, 225, 0.78);
}

.c-comunidad-modal__note strong {
  color: #bae6fd;
  font-weight: 600;
}

.c-comunidad-modal__foot-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}

.c-comunidad-modal__foot-link {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(56, 189, 248, 0.24);
  background: rgba(14, 165, 233, 0.08);
  color: #e0f2fe;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
}

.c-comunidad-modal__foot-link:hover {
  background: rgba(14, 165, 233, 0.16);
}

.c-comunidad-modal__foot-link--muted {
  border-color: transparent;
  background: transparent;
  color: rgba(203, 213, 225, 0.86);
  font-weight: 500;
  padding-left: 0;
}

.c-comunidad-modal__foot-link--muted:hover {
  color: #fff;
  background: transparent;
}

@media (max-width: 960px) {
  .c-comunidad-modal__dialog {
    grid-template-columns: 1fr;
    width: min(720px, 94vw);
    min-height: 0;
    max-height: 92vh;
    overflow: auto;
  }

  .c-comunidad-modal__visual {
    width: 100%;
    height: 190px;
    min-height: 190px;
  }

  .c-comunidad-modal__visual::after {
    background: linear-gradient(180deg, rgba(7, 17, 31, 0.08) 40%, rgba(7, 17, 31, 0.92) 100%);
  }

  .c-comunidad-modal__content {
    grid-column: 1;
    height: auto;
    padding: 18px 16px 16px;
  }

  .c-comunidad-modal__profiles {
    grid-template-columns: 1fr;
  }
}
