/*
 * LogikLabor Studio Component Library
 * A collection of reusable UI components following the design brief
 */

/*
 * ======================
 * Card Components
 * ======================
 */

/* Base Card */
.component-card {
  border: 0;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-base);
  background-color: white;
  padding: 1.5rem;
  height: 100%;
}

.component-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* Status Card */
.status-card {
  border: 0;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-base);
  padding: 1rem;
  height: 100%;
  text-align: center;
}

.status-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.status-card.active-card {
  border: 2px solid var(--primary-color);
  box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.status-card .card-title {
  font-size: var(--fs-xl);
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.status-card .card-text {
  font-size: var(--fs-base);
  margin-bottom: 0;
}

/* Info Card */
.info-card {
  display: flex;
  align-items: flex-start;
  padding: 1.5rem;
  border: 0;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-base);
}

.info-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.info-card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 8px;
  margin-right: 1rem;
  font-size: 1.5rem;
}

.info-card-content {
  flex: 1;
}

.info-card-title {
  font-size: var(--fs-lg);
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.info-card-text {
  font-size: var(--fs-base);
  color: var(--secondary-color);
  margin-bottom: 0;
}

/*
 * ======================
 * Badge Components
 * ======================
 */

/* Status Badge */
.status-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 0.75rem;
  font-size: var(--fs-sm);
  font-weight: 500;
  border-radius: 50rem;
  white-space: nowrap;
}

.status-badge i {
  margin-right: 0.35rem;
  font-size: 0.75rem;
}

/* Type Badge */
.type-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.6rem;
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: 50rem;
  white-space: nowrap;
}

.type-badge i {
  margin-right: 0.25rem;
  font-size: 0.7rem;
}

/*
 * ======================
 * Button Components
 * ======================
 */

/* Action Button */
.action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 80px;
  padding: 0.375rem 0.75rem;
  font-size: var(--fs-sm);
  font-weight: 500;
  border-radius: var(--border-radius);
  transition: var(--transition-base);
}

.action-btn i {
  margin-right: 0.35rem;
}

.action-btn:hover {
  transform: translateY(-1px);
}

/* Icon Button */
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--border-radius);
  transition: var(--transition-base);
  padding: 0;
}

.icon-btn:hover {
  transform: translateY(-1px);
}

/*
 * ======================
 * Form Components
 * ======================
 */

/* Filter Form */
.filter-form {
  background-color: white;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  padding: 1.5rem;
}

.filter-form .form-label {
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: var(--text-dark);
}

.filter-form .form-select,
.filter-form .form-control {
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 0.5rem 0.75rem;
  transition: var(--transition-base);
}

.filter-form .form-select:focus,
.filter-form .form-control:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.25rem var(--primary-light);
}

/*
 * ======================
 * Table Components
 * ======================
 */

/* Data Table */
.data-table {
  border-collapse: separate;
  border-spacing: 0;
  width: 100%;
}

.data-table th {
  font-weight: 600;
  color: var(--text-dark);
  border-bottom: 2px solid var(--border-color);
  padding: 0.75rem 1rem;
}

.data-table td {
  padding: 1rem;
  vertical-align: middle;
  border-bottom: 1px solid var(--border-color);
}

.data-table tr:hover {
  background-color: rgba(0, 0, 0, 0.02);
}

/*
 * ======================
 * Utility Classes
 * ======================
 */

/* Background Colors */
.bg-success-light {
  background-color: var(--success-light);
  color: var(--success-color);
}

.bg-info-light {
  background-color: var(--info-light);
  color: var(--info-color);
}

.bg-warning-light {
  background-color: var(--warning-light);
  color: var(--warning-color);
}

.bg-danger-light {
  background-color: var(--danger-light);
  color: var(--danger-color);
}

.bg-secondary-light {
  background-color: var(--secondary-light);
  color: var(--secondary-color);
}

.bg-primary-light {
  background-color: var(--primary-light);
  color: var(--primary-color);
}

/* Cursor Pointer */
.cursor-pointer {
  cursor: pointer;
  transition: transform 0.2s;
}

.cursor-pointer:hover {
  transform: translateY(-2px);
}

/* Shadow Hover */
.shadow-hover {
  transition: var(--transition-base);
}

.shadow-hover:hover {
  box-shadow: var(--shadow-md);
}

/*
 * ======================
 * Responsive Adjustments
 * ======================
 */

@media (max-width: 767.98px) {
  .status-card {
    padding: 0.75rem;
  }

  .status-card .card-title {
    font-size: var(--fs-lg);
  }

  .info-card {
    padding: 1rem;
  }

  .info-card-icon {
    width: 40px;
    height: 40px;
    font-size: 1.25rem;
  }

  .action-btn {
    min-width: 40px;
    padding: 0.25rem 0.5rem;
  }

  .status-badge {
    padding: 0.35rem 0.5rem;
    font-size: 0.75rem;
  }

  .filter-form {
    padding: 1rem;
  }
}
