/* Shared Assistant Settings controls (tone + response length)
   Copied from the chat page so other tools can look identical. */

/* Customization Section */
.customization-section {
  margin-bottom: 1.5rem;
}

.customization-section:last-child {
  margin-bottom: 0;
}

.customization-label {
  display: block;
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-primary);
  margin-bottom: 1rem;
}

/* Personality Options - Shoelace Radio Group */
.personality-options {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

/* Shoelace Radio Group Styling */
.personality-options sl-radio {
  display: block;
  font-size: 1rem;
  line-height: 1.6;
  padding: 4px 0;
  border-radius: 0.375rem;
  transition: background-color 0.2s ease;
  --sl-input-height-medium: auto;
  --sl-input-font-size-medium: 1rem;
  --sl-color-primary-600: var(--link-color, #3b82f6);
}

.personality-options sl-radio:hover {
  background-color: var(--bg-tertiary, rgba(0, 0, 0, 0.05));
}

.personality-options sl-radio::part(base) {
  /* Move the radio control (indicator) to the right */
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-direction: row-reverse;
  padding: 0.5rem;
  border-radius: 0.375rem;
}

.personality-options sl-radio::part(label) {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-primary);
  font-weight: 400;
  /* With row-reverse base, the spacing belongs on the right side of the label */
  padding-left: 0;
  padding-right: 0.5rem;
  flex: 1;
  min-width: 0;
}

.personality-options sl-radio[checked]::part(label) {
  font-weight: 600;
  color: var(--text-primary);
}

.personality-options sl-radio::part(control) {
  width: 1.25rem;
  height: 1.25rem;
  border-width: 2px;
}

.personality-options sl-radio[checked]::part(control) {
  border-color: var(--link-color, #3b82f6);
  background-color: var(--link-color, #3b82f6);
}

/* Personality option content (avatar + name/subtitle) */
.personality-option {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
}

.personality-avatar {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  border: 1px solid var(--border-color);
  background: var(--bg-primary);
  object-fit: contain;
  flex: 0 0 auto;
}

.personality-option-text {
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
  min-width: 0;
}

.personality-name {
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.2;
}

.personality-subtitle {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.2;
}

/* Response Length Control */
.response-length-control {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  width: 95%;
}

.response-length-control input[type="range"] {
  width: 100%;
  height: 0.5rem;
  border-radius: 0.25rem;
  background: var(--bg-tertiary);
  outline: none;
  -webkit-appearance: none;
  cursor: pointer;
}

.response-length-control input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 1rem;
  height: 1rem;
  border-radius: 50%;
  background: var(--button-bg);
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.response-length-control input[type="range"]::-webkit-slider-thumb:hover {
  background: var(--button-hover);
}

.response-length-control input[type="range"]::-moz-range-thumb {
  width: 1rem;
  height: 1rem;
  border-radius: 50%;
  background: var(--button-bg);
  cursor: pointer;
  border: none;
  transition: background-color 0.2s ease;
}

.response-length-control input[type="range"]::-moz-range-thumb:hover {
  background: var(--button-hover);
}

.response-length-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.875rem;
  color: var(--text-primary);
  margin-top: 0.5rem;
}

.response-length-label {
  flex: 1;
  text-align: center;
  font-weight: 500;
}

.response-length-value {
  text-align: center;
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-primary);
  padding: 0.5rem;
  background-color: var(--bg-tertiary);
  border-radius: 0.375rem;
  margin-top: 0.5rem;
}

