/* Profile Panel Components */

/* Profile Panel */
.profile-panel {
  position: fixed;
  top: 0;
  right: -400px; /* Hidden off-screen by default */
  width: 400px;
  height: 100vh;
  background: #fff;
  border-left: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: -4px 0 20px rgba(0, 0, 0, 0.15);
  z-index: 2000;
  transition: right 0.3s ease;
  overflow-y: auto;
}

.profile-panel--open {
  right: 0; /* Slide in from right */
}

/* Profile Panel Content */
.profile-panel__content {
  padding: 20px;
  height: 100%;
  display: flex;
  flex-direction: column;
}

/* Profile Header */
.profile-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 1px solid #e9ecef;
}

.profile-header h2 {
  margin: 0;
  font-size: 18px;
  color: #333;
}

/* Profile Sections */
.profile-section {
  margin-bottom: 25px;
}

.profile-section h3 {
  margin: 0 0 12px 0;
  font-size: 16px;
  color: #555;
  font-weight: 600;
}

.profile-section p {
  margin: 0 0 15px 0;
  font-size: 14px;
  color: #666;
  line-height: 1.4;
}

/* Profile Form Elements */
.profile-form {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.profile-form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.profile-form-group label {
  font-size: 14px;
  font-weight: 500;
  color: #333;
}

.profile-form-group select,
.profile-form-group input {
  padding: 10px 12px;
  border: 1px solid #e9ecef;
  border-radius: 6px;
  font-size: 14px;
  background: #fff;
  transition: border-color 0.2s;
}

.profile-form-group select:focus,
.profile-form-group input:focus {
  outline: none;
  border-color: #007bff;
  box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

/* Profile Buttons */
.profile-actions {
  margin-top: auto;
  padding-top: 20px;
  border-top: 1px solid #e9ecef;
  display: flex;
  gap: 10px;
}

.profile-actions button {
  flex: 1;
  padding: 12px 16px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.profile-actions .btn-primary {
  background: #007bff;
  color: white;
}

.profile-actions .btn-primary:hover {
  background: #0056b3;
}

.profile-actions .btn-secondary {
  background: #6c757d;
  color: white;
}

.profile-actions .btn-secondary:hover {
  background: #545b62;
}

/* Profile Close Button */
.btn-icon-small {
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 50%;
  background: #f8f9fa;
  color: #666;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.btn-icon-small:hover {
  background: #e9ecef;
  color: #333;
}

/* Profile Backdrop */
.profile-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1999;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.profile-backdrop--active {
  opacity: 1;
  visibility: visible;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .profile-panel {
    width: 100vw;
    right: -100vw;
  }
  
  .profile-panel__content {
    padding: 16px;
  }
  
  .profile-header h2 {
    font-size: 16px;
  }
  
  .profile-section h3 {
    font-size: 15px;
  }
}

/* Profile Status Indicators */
.profile-status {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 500;
  margin-left: 8px;
}

.profile-status--active {
  background: #d4edda;
  color: #155724;
}

.profile-status--inactive {
  background: #f8d7da;
  color: #721c24;
}

/* Profile Toggles */
.profile-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid #f0f2f5;
}

.profile-toggle:last-child {
  border-bottom: none;
}

.profile-toggle-label {
  font-size: 14px;
  color: #333;
  flex: 1;
}

.profile-toggle-switch {
  position: relative;
  width: 44px;
  height: 24px;
  background: #ccc;
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.2s;
}

.profile-toggle-switch.active {
  background: #007bff;
}

.profile-toggle-switch::before {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  background: white;
  border-radius: 50%;
  transition: transform 0.2s;
}

.profile-toggle-switch.active::before {
  transform: translateX(20px);
}
