/* EON Work Intelligence Index WordPress Plugin CSS - Scoped */
.eon-work-intel-index {
  --ink: #1c3763;
  --purple: #8B86F7;
  --line: #DEE7F8;
  --surface: #ffffff;
  --surface-2: #fbfbfe;
  --shadow-hover: 0px 10px 25px rgba(0, 0, 0, 0.15);
  --radius: 12px;
}

/* Netflix Scroll Shelf */
.eon-work-intel-index .shelf-row {
  padding: 60px 0 20px;
  position: relative;
  width: 100%;
}
.eon-work-intel-index .shelf-row.alt {
  background-color: var(--surface-2);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.eon-work-intel-index .shelf-container {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 20px;
}
.eon-work-intel-index .shelf-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
.eon-work-intel-index .shelf-header h2 {
  margin: 0;
  font-family: "Poppins", sans-serif;
  font-size: 35px;
  font-weight: 600;
  line-height: 52px;
  color: var(--ink);
  letter-spacing: -.01em;
}
.eon-work-intel-index .shelf-header h2 span {
  color: var(--purple);
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
  text-transform: none;
  background: none;
  padding: 0;
  margin-left: 10px;
  letter-spacing: normal;
  display: inline;
}

/* Header Arrows */
.eon-work-intel-index .shelf-nav {
  display: flex !important;
  gap: 8px !important;
  flex-shrink: 0 !important;
}
.eon-work-intel-index .shelf-arrow {
  width: 36px !important;
  height: 36px !important;
  min-width: 36px !important;
  max-width: 36px !important;
  border-radius: 50% !important;
  border: 1px solid var(--purple) !important;
  background: var(--ink) !important;
  color: #ffffff !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-shrink: 0 !important;
  transition: all 0.2s ease !important;
  padding: 0 !important;
  box-sizing: border-box !important;
}
.eon-work-intel-index .shelf-arrow:hover:not([disabled]) {
  background: var(--purple) !important;
  border-color: var(--purple) !important;
  color: #ffffff !important;
  transform: scale(1.05) !important;
}
.eon-work-intel-index .shelf-arrow[disabled] {
  opacity: 0.35 !important;
  cursor: not-allowed !important;
}

.eon-work-intel-index .carousel-view {
  position: relative;
  overflow: hidden;
  margin: -20px -10px 0;
  padding: 20px 10px 30px;
}
.eon-work-intel-index .carousel-track {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scrollbar-width: none;
  padding: 20px 10px;
  margin: -20px -10px;
}
.eon-work-intel-index .carousel-track::-webkit-scrollbar {
  display: none;
}

/* Full Image Overlay Cards */
.eon-work-intel-index .subject-card {
  flex: 0 0 230px;
  height: 340px;
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  transition: transform .24s cubic-bezier(.2,.75,.25,1), box-shadow .24s ease;
}
.eon-work-intel-index .subject-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-hover);
}

.eon-work-intel-index .card-image-wrap {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  overflow: hidden;
  background: #07152f;
}
.eon-work-intel-index .card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .5s ease;
}
.eon-work-intel-index .subject-card:hover .card-image {
  transform: scale(1.06);
}

.eon-work-intel-index .card-image-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(7, 21, 47, 0) 25%, rgba(7, 21, 47, 0.65) 60%, rgba(7, 21, 47, 0.92) 100%);
  z-index: 2;
}

.eon-work-intel-index .card-body {
  position: relative;
  z-index: 3;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.eon-work-intel-index .card-body h3 {
  margin: 0 0 12px;
  font-family: "Poppins", sans-serif;
  font-size: 16px;
  font-weight: 600;
  line-height: 24px;
  color: #ffffff;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;  
  overflow: hidden;
}

.eon-work-intel-index .explore-btn,
.eon-work-intel-index .explore-btn:hover,
.eon-work-intel-index .explore-btn:focus,
.eon-work-intel-index .explore-btn:active {
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  outline: none !important;
  color: var(--purple) !important;
  font-family: "Open Sans", sans-serif;
  font-size: 14px;
  font-weight: 700;
  line-height: 24px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  margin-top: auto;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}
.eon-work-intel-index .explore-btn svg {
  width: 14px;
  height: 14px;
  color: var(--purple);
  transition: transform 0.2s ease;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.5;
}
.eon-work-intel-index .subject-card:hover .explore-btn svg {
  transform: translateX(4px);
}

/* Dots Styling */
.eon-work-intel-index .slider-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 20px;
}
.eon-work-intel-index .slider-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: #cccccc;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.2s ease;
}
.eon-work-intel-index .slider-dot.active {
  background-color: #000000;
  transform: scale(1.1);
}

/* Hide Desktop Arrows & Dots when card count is 5 or fewer */
@media (min-width: 1025px) {
  .eon-work-intel-index .shelf-row[data-count="1"] .shelf-nav,
  .eon-work-intel-index .shelf-row[data-count="2"] .shelf-nav,
  .eon-work-intel-index .shelf-row[data-count="3"] .shelf-nav,
  .eon-work-intel-index .shelf-row[data-count="4"] .shelf-nav,
  .eon-work-intel-index .shelf-row[data-count="5"] .shelf-nav,
  .eon-work-intel-index .shelf-row[data-count="1"] .slider-dots,
  .eon-work-intel-index .shelf-row[data-count="2"] .slider-dots,
  .eon-work-intel-index .shelf-row[data-count="3"] .slider-dots,
  .eon-work-intel-index .shelf-row[data-count="4"] .slider-dots,
  .eon-work-intel-index .shelf-row[data-count="5"] .slider-dots {
    display: none !important;
  }
}

/* Responsive / Mobile styling */
@media (max-width: 1024px) {
  .eon-work-intel-index .shelf-header {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
  }
  .eon-work-intel-index .shelf-header h2 {
    font-size: 24px !important;
    line-height: 34px !important;
  }
  .eon-work-intel-index .shelf-nav {
    display: flex !important;
    gap: 8px !important;
  }
  .eon-work-intel-index .subject-card {
    flex: 0 0 240px;
    height: 340px;
  }
}

/* Modal Styling */
.eon-research-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 999999;
  background: rgba(10,18,42,.52);
  backdrop-filter: blur(7px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  transition: opacity .2s ease;
}
.eon-research-modal-backdrop.open {
  display: flex;
  opacity: 1;
}
.eon-research-modal-backdrop .resource-modal {
  width: min(570px, 100%) !important;
  border-radius: 18px !important;
  background: #ffffff !important;
  border: 1px solid rgba(255,255,255,.7) !important;
  box-shadow: 0 32px 90px rgba(4,15,44,.28) !important;
  transform: translateY(12px) scale(.98);
  transition: transform .22s cubic-bezier(.2,.8,.2,1);
  overflow: hidden !important;
}
.eon-research-modal-backdrop.open .resource-modal {
  transform: translateY(0) scale(1);
}
.eon-research-modal-backdrop .modal-head {
  padding: 24px 26px 18px !important;
  display: flex !important;
  align-items: flex-start !important;
  gap: 16px !important;
  border-bottom: 1px solid #eceef6 !important;
  background: linear-gradient(135deg, #fff, #f5f3ff) !important;
}
.eon-research-modal-backdrop .modal-head-copy {
  min-width: 0 !important;
  flex: 1 !important;
}
.eon-research-modal-backdrop .modal-label {
  margin: 0 0 6px !important;
  color: var(--purple) !important;
  font-family: "Poppins", sans-serif !important;
  font-size: 12px !important;
  font-weight: 700 !important;
  letter-spacing: .06em !important;
  text-transform: uppercase !important;
  display: block !important;
}
.eon-research-modal-backdrop .modal-title {
  margin: 0 !important;
  font-family: "Poppins", sans-serif !important;
  font-size: 22px !important;
  line-height: 1.35 !important;
  letter-spacing: -.02em !important;
  color: #8B86F7 !important;
}
.eon-research-modal-backdrop .modal-subtitle {
  margin: 8px 0 0 !important;
  color: #64748b !important;
  font-family: "Open Sans", sans-serif !important;
  font-size: 13.5px !important;
  line-height: 1.5 !important;
}
.eon-research-modal-backdrop .close-modal {
  width: 38px !important;
  height: 38px !important;
  border: 1px solid #dfe3f0 !important;
  border-radius: 50% !important;
  background: #fff !important;
  color: var(--ink) !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: border-color .2s ease, color .2s ease, background .2s ease !important;
  padding: 0 !important;
}
.eon-research-modal-backdrop .close-modal:hover {
  background: #f6f5ff !important;
  border-color: var(--purple) !important;
  color: var(--purple) !important;
  transform: none !important;
}
.eon-research-modal-backdrop .resource-grid {
  padding: 22px 26px 27px !important;
  display: grid !important;
  grid-template-columns: repeat(2,1fr) !important;
  gap: 13px !important;
}
.eon-research-modal-backdrop .resource-link {
  min-height: 96px !important;
  border: 1px solid #dde2f0 !important;
  border-radius: 12px !important;
  padding: 16px !important;
  display: flex !important;
  align-items: center !important;
  gap: 14px !important;
  text-decoration: none !important;
  background: #fff !important;
  box-shadow: none !important;
  transform: none !important;
  transition: border-color 0.2s ease, background-color 0.2s ease !important;
}
.eon-research-modal-backdrop .resource-link:hover, 
.eon-research-modal-backdrop .resource-link:focus-visible {
  border-color: #8B86F7 !important;
  background: #ffffff !important;
  box-shadow: none !important;
  transform: none !important;
  outline: none !important;
}
.eon-research-modal-backdrop .resource-link.disabled {
  opacity: 0.45 !important;
  pointer-events: none !important;
  cursor: not-allowed !important;
  background: #ffffff !important;
  border-color: #dfe4f2 !important;
}
.eon-research-modal-backdrop .resource-link.disabled .resource-icon {
  background: #fbfbfe !important;
  color: #a0aec0 !important;
}
.eon-research-modal-backdrop .resource-link.disabled .resource-icon svg {
  color: #a0aec0 !important;
  stroke: #a0aec0 !important;
}
.eon-research-modal-backdrop .resource-link.disabled .resource-text strong {
  color: #718096 !important;
}
.eon-research-modal-backdrop .resource-link.disabled .resource-text span {
  color: #a0aec0 !important;
}
.eon-research-modal-backdrop .resource-icon {
  flex: 0 0 48px !important;
  width: 48px !important;
  height: 48px !important;
  border-radius: 12px !important;
  background: #f0eeff !important;
  color: #8B86F7 !important;
  display: grid !important;
  place-items: center !important;
}
.eon-research-modal-backdrop .resource-icon svg {
  width: 25px !important;
  height: 25px !important;
  color: #8B86F7 !important;
  stroke: #8B86F7 !important;
}
.eon-research-modal-backdrop .resource-text strong {
  display: block !important;
  font-family: "Poppins", sans-serif !important;
  font-size: 15px !important;
  font-weight: 600 !important;
  color: #102650 !important;
}
.eon-research-modal-backdrop .resource-text span {
  display: block !important;
  margin-top: 4px !important;
  color: #607090 !important;
  font-family: "Open Sans", sans-serif !important;
  font-size: 12px !important;
}

body.modal-open {
  overflow: hidden;
}

@media (max-width: 720px) {
  .eon-research-modal-backdrop .resource-grid {
    grid-template-columns: 1fr !important;
  }
}
