body.editing .edmya-controls {
  pointer-events: none !important;
  opacity: .25;
}

.edmya-wrapper {
  position: relative;
  padding-top: 16px;
}

.edmya-controls {
  position: absolute;
  top: -50px;
  right: 8px;
  display: flex;
  gap: 6px;
  z-index: 2;
}

.edmya-btn {
  background: var(--cardbg);
  font-size: 1.2rem;
  color: var(--cardcolor);
  border: 1px solid var(--cardborder);
  border-radius: 10px;
  padding: 4px 12px;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(0,0,0,.06);
}

.edmya-btn:disabled {
  opacity: .5;
  cursor: default;
}

.edmya-viewport {
  overflow: hidden;
}

.edmya-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 36px) / 4);
  gap: 12px;
  transition: transform .25s ease;
}

.edmya-card {
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: transparent;
}

.edmya-card.is-not-enrolled {
  opacity: .58;
  filter: saturate(.85);
  transition: opacity .2s ease, filter .2s ease, transform .2s ease;
}

.edmya-card.is-not-enrolled:hover {
  opacity: .9;
  filter: saturate(1);
  transform: translateY(-2px);
}

.edmya-card.is-enrolled {
  opacity: 1;
}

.edmya-card.is-completed .edmya-media {
  box-shadow: 0 0 0 1px rgba(16, 185, 129, .28);
}

.edmya-status.available {
  background: rgba(224, 242, 254, .92);
  color: #075985;
}

.edmya-status.completed {
  background: rgba(220, 252, 231, .92);
  color: #065f46;
}

.edmya-actions {
  margin-top: .55rem;
}

.edmya-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: .45rem .9rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, .06);
  color: var(--cardcolor);
  text-decoration: none;
  font-size: .88rem;
  font-weight: 700;
  transition: all .2s ease;
}

.edmya-cta:hover {
  text-decoration: none;
  background: rgba(15, 23, 42, .12);
}

.edmya-media {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  min-height: 240px;
  border-radius: 1rem;
  overflow: hidden;
  background: #f3f4f6;
}

.edmya-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.edmya-status {
  display: inline-flex;
  align-items: center;
  font-size: .78rem;
  font-weight: 700;
  min-height: 32px;
  padding: .35rem .75rem;
  border-radius: 999px;
}

.edmya-status--overlay {
  position: absolute;
  top: .85rem;
  left: .85rem;
  z-index: 2;
  backdrop-filter: blur(8px);
}

.edmya-status.inprogress {
  background: rgba(220, 252, 231, .92);
  color: #065f46;
}

.edmya-status.enroll {
  background: rgba(224, 242, 254, .92);
  color: #075985;
}

.edmya-badge {
  position: absolute;
  right: .85rem;
  top: .85rem;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: .35rem .75rem;
  border-radius: 999px;
  font-size: .78rem;
  font-weight: 700;
  background: rgba(59,130,246,.12);
  color: rgba(29,78,216,.95);
  backdrop-filter: blur(8px);
}

.edmya-body {
  padding: .85rem .15rem 0;
}

.edmya-title {
  display: block;
  font-weight: 700;
  color: var(--cardcolor);
  text-decoration: none;
  line-height: 1.25;
}

.edmya-title:hover {
  text-decoration: underline;
}

.edmya-meta {
  margin-top: .35rem;
  font-size: .88rem;
  opacity: .72;
}

.edmya-empty {
  padding: 12px;
  color: #6b7280;
}

@media (max-width: 1199.98px) {
  .edmya-track {
    grid-auto-columns: calc((100% - 24px) / 3);
  }
}

@media (max-width: 780px) {
  .edmya-track {
    grid-auto-columns: 100%;
  }
}