/* Button and action item fixes */
/* This stylesheet contains fixes for button alignment and other UI elements */

.action-button, 
.btn, 
button[type="submit"],
input[type="submit"] {
  display: inline-block;
  padding: 8px 16px;
  margin: 5px 0;
  background-color: var(--primary-color);
  color: var(--light-text);
  border: none;
  border-radius: 4px;
  cursor: pointer;
  text-align: center;
  transition: background-color 0.3s ease;
  font-size: 14px;
  line-height: 1.5;
  text-decoration: none;
  vertical-align: middle;
}

.action-button:hover,
.btn:hover,
button[type="submit"]:hover,
input[type="submit"]:hover {
  background-color: var(--secondary-color);
  color: var(--light-text);
  text-decoration: none;
}

.action-button.secondary,
.btn.secondary {
  background-color: #6c757d;
}

.action-button.secondary:hover,
.btn.secondary:hover {
  background-color: #5a6268;
}

.action-button.danger,
.btn.danger {
  background-color: var(--danger-color);
}

.action-button.danger:hover,
.btn.danger:hover {
  background-color: #c0392b;
}

/* Button group alignment fix */
.button-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin: 10px 0;
}

/* Action buttons specific fixes */
.action-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 80px;
  height: 36px;
}

.action-button i {
  margin-right: 5px;
}

/* Fix for adjacent buttons */
.action-buttons-container {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 10px 0;
}

/* Form controls alignment fix */
.form-group {
  margin-bottom: 15px;
  width: 100%;
}

.form-control {
  display: block;
  width: 100%;
  padding: 8px 12px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-color);
  background-color: #fff;
  background-clip: padding-box;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  transition: border-color 0.15s ease-in-out;
}

.form-control:focus {
  border-color: var(--primary-color);
  outline: 0;
  box-shadow: 0 0 0 0.2rem rgba(100, 65, 165, 0.25);
}

/* Table cell alignment fixes */
td.actions {
  white-space: nowrap;
  text-align: right;
}

/* Card element fixes */
.card {
  margin-bottom: 20px;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  background-color: white;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  background-color: #f8f9fa;
  border-bottom: 1px solid var(--border-color);
}

.card-header h1,
.card-header h2,
.card-header h3 {
  margin: 0;
}

.card-body {
  padding: 20px;
}

.card-header .button-group {
  margin: 0;
}

/* Settings form specific fixes */
.settings-form {
  max-width: 600px;
  margin: 0 auto;
}

.settings-form .form-group {
  margin-bottom: 20px;
}

.settings-form .form-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: 500;
}

.settings-form .form-control {
  width: 100%;
}

.settings-section {
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 20px;
  margin-bottom: 20px;
}

.settings-section:last-child {
  border-bottom: none;
}

.settings-section h3 {
  margin-bottom: 15px;
}

/* API Documentation Tab fixes */
.api-tab-links {
  position: relative;
  z-index: 2;
  display: flex;
  border-bottom: 1px solid #ddd;
  margin-bottom: 0 !important;
}

.api-tab-links li {
  margin-right: 5px;
  margin-bottom: -1px;
}

.api-tab-links li a {
  position: relative;
  z-index: 1;
  padding: 10px 15px;
  border: 1px solid transparent;
  border-radius: 4px 4px 0 0;
  display: block;
  text-decoration: none;
}

.api-tab-links li a.active {
  background-color: white;
  border-color: #ddd;
  border-bottom-color: white;
  color: var(--primary-color);
}

.api-tab-content {
  position: relative;
  z-index: 0;
  background-color: white;
  border: 1px solid #ddd;
  border-top: none;
  padding: 15px;
}

.api-tab-content:not(.active) {
  display: none;
}
