/**
 * Naseem Sticky List — two columns, sticky list with images (theme tokens).
 *
 * Sticky needs: (1) grid row align-items stretch so both columns match row height,
 * (2) no overflow:hidden on Elementor widget wrappers, (3) no overflow on the sticky node itself.
 *
 * @package Naseem
 */

.elementor-widget-naseem-sticky-list .elementor-widget-container,
.elementor-element.elementor-widget-naseem-sticky-list {
  overflow: visible;
}

/* Parent column can clip sticky descendants */
.elementor-column:has(.elementor-widget-naseem-sticky-list) {
  overflow: visible;
}

.naseem-sticky-list {
  width: 100%;
}

.naseem-sticky-list__row {
  display: grid;
  grid-template-columns: minmax(0, 48%) minmax(0, 1fr);
  align-items: stretch;
  column-gap: var(--space-10, 2.5rem);
  min-width: 0;
}

.naseem-sticky-list__col--main,
.naseem-sticky-list__col--aside {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.naseem-sticky-list__sticky-main {
  display: flex;
  flex-direction: column;
  gap: 0;
  position: -webkit-sticky;
  position: sticky;
  top: 1.5rem;
  min-width: 0;
  flex: 0 0 auto;
  align-self: flex-start;
  width: 100%;
  max-width: 100%;
}

.naseem-sticky-list__heading-wrap .naseem-sticky-list__heading {
  margin: 0;
}

.naseem-sticky-list__heading a {
  text-decoration: inherit;
}

.naseem-sticky-list__text {
  color: var(--color-text-muted, #3f4f46);
}

.naseem-sticky-list__text > :first-child {
  margin-top: 0;
}

.naseem-sticky-list__text > :last-child {
  margin-bottom: 0;
}

/*
 * Left column image: use :where() so specificity stays 0 — Elementor panel styles
 * ({{WRAPPER}} …) always win over this file when both target the same property.
 */
:where(.naseem-sticky-list__left-image) {
  margin: 0;
  max-width: 100%;
}

:where(.naseem-sticky-list__left-image-inner) {
  display: inline-block;
  max-width: 100%;
  vertical-align: top;
}

:where(.naseem-sticky-list__left-image-inner a) {
  display: block;
}

.naseem-sticky-list__img-reveal-frame {
  width: 100%;
  max-width: 100%;
}

:where(.naseem-sticky-list__left-image-img) {
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
}

:where(.naseem-sticky-list__left-image-caption) {
  margin: 0;
  font-size: 0.875em;
  line-height: 1.4;
  color: inherit;
}

.naseem-sticky-list__btn-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  column-gap: var(--space-3, 0.75rem);
  row-gap: var(--space-2, 0.5rem);
}

.naseem-sticky-list__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-weight: 600;
  line-height: 1.2;
  border: 1px solid transparent;
  transition:
    color 0.2s ease,
    background-color 0.2s ease,
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.naseem-sticky-list__btn--primary {
  color: var(--color-inverse, #ffffff);
  background-color: var(--color-primary, #22c55e);
}

.naseem-sticky-list__btn--primary:hover,
.naseem-sticky-list__btn--primary:focus-visible {
  color: var(--color-inverse, #ffffff);
  background-color: var(--color-primary-dark, #0a3d2f);
}

.naseem-sticky-list__btn--secondary {
  background-color: transparent;
  color: var(--color-primary, #22c55e);
  border-color: currentColor;
}

.naseem-sticky-list__btn--secondary:hover,
.naseem-sticky-list__btn--secondary:focus-visible {
  background-color: rgba(34, 197, 94, 0.08);
  color: var(--color-primary-dark, #0a3d2f);
}

.naseem-sticky-list__right-text {
  color: var(--color-text-muted, #3f4f46);
}

.naseem-sticky-list__right-text > :first-child {
  margin-top: 0;
}

.naseem-sticky-list__right-text > :last-child {
  margin-bottom: 0;
}

.naseem-sticky-list__sticky {
  position: -webkit-sticky;
  position: sticky;
  top: 1.5rem;
  flex: 0 0 auto;
  align-self: flex-start;
  width: 100%;
  max-width: 100%;
}

.naseem-sticky-list__sticky-inner {
  min-width: 0;
  overflow: visible;
  -webkit-overflow-scrolling: touch;
}

:where(.naseem-sticky-list__list) {
  display: flex;
  flex-direction: column;
  gap: var(--space-3, 0.75rem);
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Per-item fade-up reveal (each card animates when it enters the viewport) */
.naseem-sticky-list__list .naseem-sticky-list__item {
  opacity: 0;
  transform: translate3d(0, 2.25rem, 0) scale(0.97);
  contain: layout style;
  transition:
    opacity 0.88s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.88s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.25s ease,
    border-color 0.25s ease;
}

.naseem-sticky-list__list .naseem-sticky-list__item.naseem-sticky-list__item--visible {
  opacity: 1;
  transform: translate3d(0, 0, 0) scale(1);
}

@media (prefers-reduced-motion: reduce) {
  .naseem-sticky-list__list .naseem-sticky-list__item {
    opacity: 1;
    transform: none;
    transition:
      box-shadow 0.25s ease,
      border-color 0.25s ease;
  }
}

.naseem-sticky-list__item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-4, 1rem);
  margin: 0;
  border: 1px solid var(--color-border, #cfe8d9);
  background: var(--color-surface, #ffffff);
  border-radius: var(--radius-md, 18px);
  box-shadow:
    0 1px 2px rgba(15, 23, 42, 0.05),
    0 12px 36px rgba(5, 34, 26, 0.06);
}

.naseem-sticky-list__list .naseem-sticky-list__item--visible:hover {
  border-color: rgba(34, 197, 94, 0.28);
  box-shadow:
    0 2px 6px rgba(15, 23, 42, 0.06),
    0 18px 44px rgba(5, 34, 26, 0.1);
  transform: translate3d(0, -2px, 0) scale(1);
}

@media (prefers-reduced-motion: reduce) {
  .naseem-sticky-list__list .naseem-sticky-list__item--visible:hover {
    transform: none;
  }
}

.naseem-sticky-list__media {
  flex-shrink: 0;
  width: 72px;
  height: 72px;
  border-radius: var(--radius-sm, 12px);
  overflow: hidden;
  background: var(--chrome-surface, #f1f5f9);
}

.naseem-sticky-list__media-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.naseem-sticky-list__item-body {
  min-width: 0;
  flex: 1;
}

.naseem-sticky-list__item-title {
  margin: 0 0 var(--space-2, 0.5rem);
  font-family: var(--font-display, "Poppins", system-ui, sans-serif);
  font-weight: 600;
  font-size: clamp(1rem, 1.5vw, 1.125rem);
  line-height: 1.25;
  color: var(--color-text, #0f172a);
}

.naseem-sticky-list__item-text {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--color-text-muted, #3f4f46);
}

@media (max-width: 767px) {
  .naseem-sticky-list__row {
    grid-template-columns: 1fr !important;
    row-gap: var(--space-8, 2rem);
  }

  .naseem-sticky-list__sticky-main,
  .naseem-sticky-list__sticky {
    position: relative;
    top: auto !important;
  }
}
