/* ActionCard - Accessible workflow card component */

.udp-action-card {
  /* Layout */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-04);

  /* Sizing - removed height: 100% to fix grid alignment */
  padding: var(--spacing-06);
  width: 100%;
  min-height: 200px;

  /* Appearance - no border by default */
  background-color: #ffffff;
  border: 2px solid transparent;
  border-radius: var(--border-radius);
  box-shadow: var(--elevation-02);

  /* Text */
  text-align: center;
  text-decoration: none;
  color: inherit;

  /* Transitions */
  transition: transform var(--animation-duration) var(--animation-easing),
              box-shadow var(--animation-duration) var(--animation-easing),
              border-color var(--animation-duration) var(--animation-easing);

  /* Remove default button/link styles */
  cursor: pointer;
  font-family: var(--font-family);
  border-style: solid;
}

/* Remove button-specific default styles */
.udp-action-card:is(button) {
  background: #ffffff;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

/* Hover state - show border with icon color */
.udp-action-card:hover {
  transform: scale(1.03);
  box-shadow: var(--elevation-04);
  border-color: var(--card-border-color, var(--gray-04));
}

/* Focus state - accessibility with colored border */
.udp-action-card:focus {
  outline: none;
  transform: scale(1.03);
  box-shadow: var(--elevation-04);
  border-color: var(--card-border-color, var(--primary-color));
}

/* Active state */
.udp-action-card:active {
  transform: scale(1.01);
  box-shadow: var(--elevation-03);
  border-color: var(--card-border-color, var(--gray-04));
}

/* Icon container */
.udp-action-card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--card-border-color, var(--info-color-main));
  flex-shrink: 0;
  width: 48px;
  height: 48px;
}

/* Ensure SVG icons are centered and properly sized */
.udp-action-card__icon > * {
  display: flex;
  align-items: center;
  justify-content: center;
}

.udp-action-card__icon svg {
  display: block;
  margin: auto;
}

/* Content container */
.udp-action-card__content {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-02);
  width: 100%;
}

/* Primary text */
.udp-action-card__primary-text {
  font-size: var(--h4-font-size);
  font-weight: var(--h4-font-weight);
  line-height: var(--h4-line-height);
  color: var(--text-main);
  margin: 0;
}

/* Secondary text */
.udp-action-card__secondary-text {
  font-size: var(--body2-font-size);
  font-weight: var(--body2-font-weight);
  line-height: var(--body2-line-height);
  color: var(--text-secondary);
  margin: 0;
}

/* Disabled state */
.udp-action-card:disabled,
.udp-action-card[aria-disabled="true"] {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  .udp-action-card {
    border-width: 3px;
  }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
  .udp-action-card {
    transition: none;
  }

  .udp-action-card:hover,
  .udp-action-card:focus {
    transform: none;
  }
}
