// =============================================================================
// Card (glass morphism)
// =============================================================================

@use '../variables' as *;
@use '../mixins' as *;

.card {
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: $radius-lg;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);

  .dark & {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.08);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
  }
}

.card__header {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);

  .dark & {
    border-color: rgba(255, 255, 255, 0.08);
  }
}

.card__body {
  padding: 1.25rem;
}

.card__footer {
  padding: 1rem 1.25rem;
  border-top: 1px solid rgba(0, 0, 0, 0.06);

  .dark & {
    border-color: rgba(255, 255, 255, 0.08);
  }
}

// Variants
.card--shadow {
  box-shadow: $shadow-sm;
}

.card--hover {
  @include transition-fast(box-shadow, border-color);

  &:hover {
    box-shadow: $shadow-md;
    border-color: rgba($primary-500, 0.3);
  }
}
