// Card Customizations - SDGA Custom Enhancements
// Following Bootstrap 5.3 recommended practices

// ============================================
// CARD ICON VARIANTS - Using Sass map and @each loop
// ============================================



// ============================================
// CARD BASE STYLES
// ============================================

.card {
  transition: transform 0.3s ease;
  width: 100%;

  &:focus-visible {
    border-radius: $radius-lg !important;
  }

  &.expanded {
    .card-expanded-icon {
      transform: rotate(180deg);
    }
  }
  .card-expanded-content {
    animation: slideDown 0.3s ease-out;
    border-top: 1px solid #e5e7eb;
    padding-top: 1rem;
  }

  @keyframes slideDown {
    from {
      opacity: 0;
      transform: translateY(-10px) scaleY(0);
      transform-origin: top;
    }
    to {
      opacity: 1;
      transform: translateY(0) scaleY(1);
      transform-origin: top;
    }
  }

  .card-title {
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
  }

  
  &.disabled {
    background-color: $gray-200;
    cursor: not-allowed;
  }

  .card-title-checked {
    margin-inline-start: auto;
    margin-inline-end: 1rem;
    margin-top: 1rem;
    margin-bottom: 1rem;
  }

  .card-text {
    margin: 0;
  }

  .card-footer {
    margin-top: auto;
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: flex-start;

    // Footer variants
    &.card-footer-center {
      justify-content: center;
    }

    &.card-footer-start {
      justify-content: flex-start;
    }

    &.card-footer-between {
      justify-content: space-between;
    }

    .card-expanded-icon {
      margin-inline-start: auto;
      cursor: pointer;
      transition: transform 0.3s ease;

      &:hover {
        opacity: 0.7;
      }
    }
  }
}