:root {
  --ff-ai-primary: #2563eb;
  --ff-ai-primary-hover: #1d4ed8;
  --ff-ai-primary-light: rgba(37, 99, 235, 0.15);
  --ff-ai-primary-dark: #1e40af;
  --ff-ai-chat-bg: #f9fafb;
  --ff-ai-bg-light: #f9fafb;
  --ff-ai-bg-medium: #f3f4f6;
  --ff-ai-bg-dark: #e5e7eb;
  --ff-ai-bg-white: #ffffff;
  --ff-ai-text-dark: #111827;
  --ff-ai-text-medium: #374151;
  --ff-ai-text-gray: #6b7280;
  --ff-ai-text-light: #9ca3af;
  --ff-ai-text-lighter: #d1d5db;
  --ff-ai-border: #e5e7eb;
  --ff-ai-border-light: #f3f4f6;
  --ff-ai-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
  --ff-ai-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --ff-ai-radius: 0.5rem;
  --ff-ai-radius-lg: 0.75rem;
  --ff-ai-radius-xl: 1rem;
  --ff-ai-radius-full: 9999px;
  --ff-ai-msg-bg-color: #ffffff;
  --ff-ai-msg-text-color: #111827;
  --ff-human-msg-bg-color: #2563eb;
  --ff-human-msg-text-color: #ffffff;
  --ff-msg-font-size: 15px;
  --ff-msg-border-radius: 12px;
  --ff-msg-spacing: 16px;
  --ff-msg-padding: 16px;
  --ff-msg-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
  --ff-header-bg: #ffffff;
  --ff-header-text: #111827;
  --ff-input-bg: #ffffff;
  --ff-input-border: #e5e7eb;
  --ff-ai-transition-fast: 0.15s;
  --ff-ai-transition-normal: 0.3s;
  --ff-ai-transition-slow: 0.5s;
}

.ff-ai-chat-message {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  width: 100%;
}
.ff-ai-chat-message:last-child {
  margin-bottom: 0 !important;
}
.ff-ai-chat-message.ff-ai-chat-message-user {
  flex-direction: row-reverse;
}

.ff-ai-chat-message-avatar {
  flex-shrink: 0;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: var(--ff-ai-radius-full, 9999px);
  display: flex;
  align-items: center;
  justify-content: center;
  background: #1f2937;
  color: white;
}
.ff-ai-chat-message-avatar svg {
  width: 1.125rem;
  height: 1.125rem;
}
.ff-ai-chat-message-user .ff-ai-chat-message-avatar {
  background: var(--ff-ai-primary, #2563eb);
}

.ff-ai-chat-message-content {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}
.ff-ai-chat-message-user .ff-ai-chat-message-content {
  align-items: flex-end;
}
.ff-ai-chat-message-assistant .ff-ai-chat-message-content {
  align-items: flex-start;
}

.ff-ai-chat-message-label {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--ff-ai-text-gray, #6b7280);
  padding: 0 0.25rem;
}

.ff-ai-chat-message-bubble {
  padding: var(--ff-msg-padding, 0.75rem 1rem);
  line-height: 1.6;
  word-wrap: break-word;
  width: -moz-fit-content;
  width: fit-content;
}

:root {
  --ff-ai-settings-primary: #2563eb;
  --ff-ai-settings-primary-light: #3b82f6;
  --ff-ai-settings-primary-dark: #1d4ed8;
  --ff-ai-settings-bg: #f8fafc;
  --ff-ai-settings-card-bg: #ffffff;
  --ff-ai-settings-border: #e2e8f0;
  --ff-ai-settings-border-radius: 12px;
  --ff-ai-settings-shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);
  --ff-ai-settings-text-primary: #1e293b;
  --ff-ai-settings-text-secondary: #64748b;
  --ff-ai-settings-text-muted: #94a3b8;
  --ff-ai-settings-accent: #f0f9ff;
  --ff-ai-settings-success: #10b981;
  --ff-ai-settings-warning: #f59e0b;
  --ff-ai-settings-danger: #ef4444;
}

.ff_landing_page_items {
  margin-top: 0;
}

.ff_settings_form {
  max-width: 100%;
  margin: 0 auto;
}

.el-switch {
  --el-switch-on-color: var(--ff-ai-settings-primary);
  --el-switch-off-color: #dcdfe6;
}

.el-input,
.el-select,
.el-textarea {
  width: 100%;
}

.ff_ai_chat_select_full,
.el-form-item__content .ff_ai_chat_select_full,
.el-form-item__content .el-select {
  width: 100%;
}

.el-form-item .el-form-item__content {
  max-width: 100%;
}

.ff_type_radio_item {
  margin-bottom: 16px;
}

.ff_message_style_block {
  margin-bottom: 12px;
}

.ff_chat_design_tab .el-tabs {
  padding: 5px;
  background: #f2f2f2;
  border-radius: 5px;
  margin-bottom: 10px;
}
.ff_chat_design_tab .ff_message_style_block > * {
  margin-bottom: 12px;
}
.ff_chat_design_tab .ff_message_style_block > *:last-child {
  margin-bottom: 0;
}

.ff_fullscreen_message_style {
  margin-bottom: 16px;
}

.ff_screen_ai-chat-settings {
  padding: 0;
}

.ff-ai-chat-settings-card {
  padding-top: 0;
}

.ff_form_application_container {
  padding: 24px;
}

.ff-ai-chat-sticky-header {
  position: sticky;
  top: 32px;
  z-index: 100;
  background: var(--ff-ai-settings-card-bg);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  padding-top: 24px;
}
.ff-ai-chat-sticky-header .ff-ai-chat-header-left {
  flex: 1;
  min-width: 0;
}
.ff-ai-chat-sticky-header .ff-ai-chat-header-title-row {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}
.ff-ai-chat-sticky-header .ff-ai-chat-header-switch {
  flex-shrink: 0;
  margin-top: 2px;
}
.ff-ai-chat-sticky-header .ff-ai-chat-header-text {
  flex: 1;
  min-width: 0;
}
.ff-ai-chat-sticky-header .ff-ai-chat-header-text h5 {
  margin: 0 0 8px 0;
  font-size: 20px;
  font-weight: 600;
  color: var(--ff-ai-settings-text-primary);
}
.ff-ai-chat-sticky-header .ff-ai-chat-header-text p {
  margin: 0;
  font-size: 14px;
  color: var(--ff-ai-settings-text-secondary);
  line-height: 1.5;
}

.ff-ai-chat-form-wrapper {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.ff-ai-chat-form-wrapper .ff_input_width {
  width: 100%;
}

.ff-ai-chat-form .el-form-item {
  padding-bottom: 32px;
  border-bottom: 1px solid var(--ff-ai-settings-border);
}
.ff-ai-chat-form .el-form-item:last-child {
  margin-bottom: 0 !important;
  padding-bottom: 0;
  border-bottom: none;
}
.ff-ai-chat-form .el-form-item .el-form-item__label {
  text-align: left;
  padding: 8px 0;
  line-height: 1.6;
  font-size: 14px;
  font-weight: 500;
  color: var(--ff-ai-settings-text-primary);
  width: 50% !important;
  float: left;
}
.ff-ai-chat-form .el-form-item .el-form-item__label::before {
  display: none;
}
.ff-ai-chat-form .el-form-item .el-form-item__content {
  width: 50%;
  line-height: 1;
}

.ff-ai-chat-settings-layout {
  display: flex;
  gap: 24px;
  align-items: flex-start;
  min-height: 600px;
}
@media (max-width: 1200px) {
  .ff-ai-chat-settings-layout {
    flex-direction: column;
  }
}

.ff-ai-chat-sidebar,
.ffc_design_sidebar {
  width: 350px;
  flex: 0 0 350px;
  min-width: 0;
  background: var(--ff-ai-settings-card-bg);
  border: 1px solid var(--ff-ai-settings-border);
  border-radius: var(--ff-ai-settings-border-radius);
  overflow: hidden;
}
@media (max-width: 1200px) {
  .ff-ai-chat-sidebar,
  .ffc_design_sidebar {
    flex: 1 1 auto;
    width: 100%;
  }
}

.ff-ai-chat-sidebar .ff_tab,
.ffc_design_sidebar .ff_tab {
  display: flex;
  border-bottom: 1px solid #ececec;
}
.ff-ai-chat-sidebar .ff_tab .ff_tab_item:not(:last-child),
.ffc_design_sidebar .ff_tab .ff_tab_item:not(:last-child) {
  margin-right: 30px;
}
.ff-ai-chat-sidebar .ff_tab .ff_tab_item.active .ff_tab_link,
.ffc_design_sidebar .ff_tab .ff_tab_item.active .ff_tab_link {
  color: var(--ff-ai-settings-primary);
}
.ff-ai-chat-sidebar .ff_tab .ff_tab_item.active .ff_tab_link::after,
.ffc_design_sidebar .ff_tab .ff_tab_item.active .ff_tab_link::after {
  width: 100%;
}
.ff-ai-chat-sidebar .ff_tab .ff_tab_link,
.ffc_design_sidebar .ff_tab .ff_tab_link {
  padding-bottom: 16px;
  display: block;
  font-weight: 500;
  font-size: 16px;
  color: var(--ff-ai-settings-text-primary);
  position: relative;
}
.ff-ai-chat-sidebar .ff_tab .ff_tab_link::after,
.ffc_design_sidebar .ff_tab .ff_tab_link::after {
  position: absolute;
  content: "";
  bottom: -1px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--ff-ai-settings-primary);
  transition: 0.2s;
}
.ff-ai-chat-sidebar .ff_tab.ff_tab_center .ff_tab_item,
.ffc_design_sidebar .ff_tab.ff_tab_center .ff_tab_item {
  flex: 1;
  text-align: center;
}

.ff_landing .ff_landing_sidebar .ffc_sidebar_body {
  padding: 16px 1px 0 0;
}

.ffc_sharing_settings .ff_card,
.ffc_sharing_settings .el-card {
  margin-bottom: 24px;
}

.ff-ai-chat-tab-content {
  padding: 0 8px;
}
.ff-ai-chat-tab-content.ff-ai-chat-tab-style .ff-ai-chat-form .el-form-item__label {
  width: 100% !important;
}
.ff-ai-chat-tab-content.ff-ai-chat-tab-style .ff-ai-chat-form .el-form-item__content {
  width: 100%;
}

.ff-ai-chat-layout-radio {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.ff-ai-chat-layout-radio .el-radio {
  display: flex;
  margin-right: 0;
  width: 100%;
}
.ff-ai-chat-layout-radio .el-radio .el-radio__label {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 12px 16px;
  border: 1px solid var(--ff-ai-settings-border);
  border-radius: 8px;
  background: var(--ff-ai-settings-card-bg);
  width: 100%;
}
.ff-ai-chat-layout-radio .ff-ai-chat-layout-option-title {
  font-weight: 500;
  color: var(--ff-ai-settings-text-primary);
  margin-bottom: 4px;
}
.ff-ai-chat-layout-radio .ff-ai-chat-layout-option-desc {
  font-size: 13px;
  color: var(--ff-ai-settings-text-secondary);
}

.ff-ai-chat-single-column {
  max-width: 640px;
  padding: 24px 0;
}

.ff-ai-chat-turn-on-message {
  margin: 0;
  font-size: 14px;
  color: var(--ff-ai-settings-text-secondary);
}

.ff-ai-chat-preview-column {
  position: relative;
}

.ff-form-item__content {
  width: 100%;
  max-width: 100%;
}

.ff-ai-chat-form-item .ff-ai-chat-label {
  display: flex;
  align-items: center;
  font-size: 14px;
  font-weight: 500;
  color: var(--ff-ai-settings-text-primary);
  line-height: 1.6;
}
.ff-ai-chat-form-item .ff-ai-chat-label .ff-icon {
  margin-left: 6px;
  color: var(--ff-ai-settings-text-muted);
  cursor: help;
}
.ff-ai-chat-form-item .ff-form-item__content > * {
  width: 100%;
}
.ff-ai-chat-form-item .el-input .el-input__inner,
.ff-ai-chat-form-item .el-input .el-textarea__inner,
.ff-ai-chat-form-item .el-select .el-input__inner,
.ff-ai-chat-form-item .el-select .el-textarea__inner,
.ff-ai-chat-form-item .el-textarea .el-input__inner,
.ff-ai-chat-form-item .el-textarea .el-textarea__inner {
  border-radius: 8px;
  border: 1px solid var(--ff-ai-settings-border);
}
.ff-ai-chat-form-item .el-input .el-input__inner:focus,
.ff-ai-chat-form-item .el-input .el-textarea__inner:focus,
.ff-ai-chat-form-item .el-select .el-input__inner:focus,
.ff-ai-chat-form-item .el-select .el-textarea__inner:focus,
.ff-ai-chat-form-item .el-textarea .el-input__inner:focus,
.ff-ai-chat-form-item .el-textarea .el-textarea__inner:focus {
  border-color: var(--ff-ai-settings-primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}
.ff-ai-chat-form-item .el-switch {
  margin-top: 4px;
}

.ff-ai-chat-conversation-style .el-radio {
  margin-right: 0;
  margin-bottom: 12px;
  width: 100%;
}
.ff-ai-chat-conversation-style .el-radio .el-radio__label {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 12px 16px;
  border: 1px solid var(--ff-ai-settings-border);
  border-radius: 8px;
  background: var(--ff-ai-settings-card-bg);
  transition: all 0.2s ease;
}
.ff-ai-chat-conversation-style .el-radio .el-radio__label .ff-ai-chat-style-name {
  font-weight: 500;
  color: var(--ff-ai-settings-text-primary);
  margin-bottom: 4px;
}
.ff-ai-chat-conversation-style .el-radio .el-radio__label .ff-ai-chat-style-description {
  font-size: 13px;
  color: var(--ff-ai-settings-text-secondary);
}
.ff-ai-chat-conversation-style .el-radio.is-checked .el-radio__label {
  border-color: var(--ff-ai-settings-primary);
  background: var(--ff-ai-settings-accent);
}

.ff-ai-chat-custom-prompt .el-textarea__inner {
  border-radius: 8px;
  border: 1px solid var(--ff-ai-settings-border);
  padding: 12px 16px;
  font-size: 14px;
  line-height: 1.5;
}
.ff-ai-chat-custom-prompt .el-textarea__inner:focus {
  border-color: var(--ff-ai-settings-primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.ff-ai-chat-embed-section {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.ff-ai-chat-embed-item {
  background: var(--ff-ai-settings-card-bg);
  border: 1px solid var(--ff-ai-settings-border);
  border-radius: 8px;
  padding: 16px;
}
.ff-ai-chat-embed-item .ff-ai-chat-embed-header {
  margin-bottom: 12px;
}
.ff-ai-chat-embed-item .ff-ai-chat-embed-header .ff-ai-chat-embed-title {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: var(--ff-ai-settings-text-primary);
  margin-bottom: 4px;
}
.ff-ai-chat-embed-item .ff-ai-chat-embed-header .ff-ai-chat-embed-subtitle {
  font-size: 13px;
  color: var(--ff-ai-settings-text-secondary);
}
.ff-ai-chat-embed-item .ff-ai-chat-embed-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}
.ff-ai-chat-embed-item .ff-ai-chat-embed-controls .ff-ai-chat-embed-btn {
  flex: 1;
  display: flex;
  align-items: center;
  padding: 10px 12px;
  background: var(--ff-ai-settings-bg);
  border: 1px solid var(--ff-ai-settings-border);
  border-radius: 6px;
  font-size: 13px;
  color: var(--ff-ai-settings-text-primary);
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ff-ai-chat-embed-item .ff-ai-chat-embed-controls .ff-ai-chat-embed-btn .el-icon {
  margin-right: 8px;
  color: var(--ff-ai-settings-text-muted);
}
.ff-ai-chat-embed-item .ff-ai-chat-embed-controls .ff-ai-chat-embed-btn .ff-ai-chat-embed-text {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ff-ai-chat-embed-item .ff-ai-chat-embed-controls .ff-ai-chat-embed-btn:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}
.ff-ai-chat-embed-item .ff-ai-chat-embed-controls .ff-ai-chat-embed-action .el-icon {
  margin-right: 6px;
}

.ff_ai_unsupported_notice {
  padding: 10px 12px;
  margin-bottom: 12px;
  font-size: 12px;
  line-height: 1.5;
  color: #946800;
  background: #fef9e7;
  border: 1px solid #f5e6b8;
  border-radius: 6px;
}
.ff_ai_unsupported_notice .el-icon-warning-outline {
  font-size: 14px;
  margin-right: 4px;
  vertical-align: -1px;
}

.ff_ai_unsupported_list {
  margin: 4px 0 0;
  padding: 0 0 0 20px;
  list-style: disc;
}
.ff_ai_unsupported_list li {
  font-weight: 500;
  font-size: 12px;
}

.ff-ai-chat-stats-container {
  background: var(--ff-ai-settings-card-bg);
  border: 1px solid var(--ff-ai-settings-border);
  border-radius: 8px;
  padding: 20px;
}

.ff-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 0;
}

.ff-ai-chat-stat-item {
  background: var(--ff-ai-settings-bg);
  border: 1px solid var(--ff-ai-settings-border);
  border-radius: 8px;
  padding: 16px;
  text-align: center;
  transition: all 0.2s ease;
}
.ff-ai-chat-stat-item:hover {
  border-color: var(--ff-ai-settings-primary);
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.1);
  transform: translateY(-2px);
}
.ff-ai-chat-stat-item .ff-ai-chat-stat-icon-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin: 0 auto 12px;
  background: var(--ff-ai-settings-accent);
  border-radius: 50%;
}
.ff-ai-chat-stat-item .ff-ai-chat-stat-icon-wrapper .el-icon {
  font-size: 20px;
  color: var(--ff-ai-settings-primary);
}
.ff-ai-chat-stat-item .ff-ai-chat-stat-value {
  font-size: 24px;
  font-weight: 600;
  color: var(--ff-ai-settings-text-primary);
  line-height: 1.2;
  margin-bottom: 6px;
}
.ff-ai-chat-stat-item .ff-ai-chat-stat-label {
  font-size: 13px;
  color: var(--ff-ai-settings-text-secondary);
  margin-top: 0;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 500;
}

.ff-ai-chat-stats-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  color: var(--ff-ai-settings-text-muted);
}
.ff-ai-chat-stats-loading .ff-ai-chat-stats-loading-spinner {
  width: 32px;
  height: 32px;
  border: 3px solid var(--ff-ai-settings-border);
  border-top-color: var(--ff-ai-settings-primary);
  border-radius: 50%;
  animation: ff-ai-chat-spin 1s linear infinite;
  margin-bottom: 12px;
}

.ff-ai-chat-cleanup-info {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--ff-ai-settings-border);
  font-size: 13px;
  color: var(--ff-ai-settings-text-secondary);
  line-height: 1.6;
}
.ff-ai-chat-cleanup-info .ff-ai-chat-cleanup-info-icon {
  flex-shrink: 0;
  margin-top: 2px;
}
.ff-ai-chat-cleanup-info .ff-ai-chat-cleanup-info-icon .el-icon {
  color: var(--ff-ai-settings-primary);
  font-size: 16px;
}
.ff-ai-chat-cleanup-info .ff-ai-chat-cleanup-info-text {
  flex: 1;
}

@keyframes ff-ai-chat-spin {
  to {
    transform: rotate(360deg);
  }
}
.ff-ai-chat-style-section {
  padding: 0;
}
.ff-ai-chat-style-section .ff-ai-chat-style-header {
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--ff-ai-settings-border);
}
.ff-ai-chat-style-section .ff-ai-chat-style-header .ff-ai-chat-style-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--ff-ai-settings-text-primary);
  margin: 0;
}
.ff-ai-chat-style-section .ff-control-content .ff-control-field {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  overflow: visible;
  clear: both;
}
.ff-ai-chat-style-section .ff-control-content .ff-control-field:last-child {
  margin-bottom: 0;
}
.ff-ai-chat-style-section .ff-control-content .ff-control-title {
  width: auto;
  float: none;
  display: inline-block;
  margin-bottom: 0;
  margin-right: 16px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ff-ai-settings-text-primary);
  flex-shrink: 0;
}
.ff-ai-chat-style-section .ff-control-content .ff-control-input-wrapper {
  width: auto;
  float: none;
  display: flex;
  align-items: center;
  text-align: right;
  flex: 1;
  justify-content: flex-end;
}
.ff-ai-chat-style-section > *:not(.ff-ai-chat-style-header) {
  margin-bottom: 16px;
}
.ff-ai-chat-style-section > *:not(.ff-ai-chat-style-header):last-child {
  margin-bottom: 0;
}

.ff-ai-chat-shadow-header {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--ff-ai-settings-border);
}
.ff-ai-chat-shadow-header .ff-ai-chat-switch {
  margin-right: 12px;
}
.ff-ai-chat-shadow-header .ff-ai-chat-shadow-label {
  font-size: 15px;
  font-weight: 600;
  color: var(--ff-ai-settings-text-primary);
  margin: 0;
}

.ff-ai-chat-shadow-content {
  margin-top: 16px;
}
.ff-ai-chat-shadow-content .ff_each_style {
  background: var(--ff-ai-settings-card-bg);
  border: 1px solid var(--ff-ai-settings-border);
  border-radius: 8px;
  padding: 16px;
}

.ff_type_settings .ff-type-control {
  padding: 0 2px;
}
.ff_type_settings .ff-type-control .el-slider__input {
  clear: both;
}
.ff_type_settings .ff-type-control .ff-type-value {
  width: 130px !important;
}

.ff-control-content .ff-control-field {
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  overflow: visible;
  clear: both;
}
.ff-control-content .ff-control-field:last-child {
  margin-bottom: 0;
}
.ff-control-content .ff-control-title {
  display: inline-block;
  width: auto;
  float: none;
  font-size: 14px;
  color: var(--ff-ai-settings-text-primary);
  font-weight: 500;
  margin-bottom: 0;
  margin-right: 16px;
  flex-shrink: 0;
}

.ff-type-control {
  margin-bottom: 15px;
}
.ff-type-control:last-child {
  margin-bottom: 0;
}
.ff-type-control .ff-type-value {
  display: flex;
  align-items: center;
  gap: 8px;
}
.ff-type-control .ff-type-slider {
  margin-top: 10px;
}
.ff-type-control .ff-type-custom {
  width: 100%;
}

.ff_border_config .ff_section_title {
  font-size: 14px;
  font-weight: 500;
  color: #303133;
  margin-bottom: 16px;
  margin-top: 0;
}
.ff_border_config .ff-control-content .ff-control-field.ff_input_wrapper_full {
  margin-bottom: 15px;
}
.ff_border_config .ff-control-content .ff-control-field.ff_each_style {
  margin-top: 15px;
}

.ff_each_style {
  position: relative;
  padding: 0px 0px 15px;
}
.ff_each_style:last-child {
  padding-bottom: 0 !important;
}
.ff_each_style .ff-control-title {
  width: 50%;
  float: left;
  font-size: 14px;
  font-weight: 500;
}
.ff_each_style .ff-control-title-auto {
  width: auto;
}
.ff_each_style .ff-control-dimensions {
  overflow: hidden;
  margin: 0;
  padding: 0;
}
.ff_each_style .ff-control-dimensions li {
  float: left;
  width: 20%;
  list-style: none;
  margin: 0;
  padding: 0;
}
.ff_each_style .ff-control-dimensions li:first-child input {
  border-left: 1px solid #d5dadf;
  border-radius: 3px 0 0 3px;
}
.ff_each_style .ff-control-dimensions li input {
  display: block;
  text-align: center;
  width: 100%;
  border-color: #d5dadf;
  height: 27px;
  padding: 4px 0;
  border-radius: 0;
}
.ff_each_style .ff-control-dimensions li input:focus {
  border-color: #a4afb7;
  margin-left: 0;
  width: 100%;
  outline: 0;
}
.ff_each_style .ff-control-dimensions li label {
  display: block;
  text-align: center;
  color: #989898;
  font-size: 9px;
  text-transform: uppercase;
  padding-top: 0px;
}
.ff_each_style .ff-control-dimensions li .ff_item_linkable {
  border: 1px solid #d5dadf;
  padding: 3px 16px;
  height: 30px;
  display: inline-block;
  font-size: 10px;
  vertical-align: top;
  border-top-right-radius: 3px;
  border-bottom-right-radius: 3px;
}
.ff_each_style .ff-control-dimensions li .ff_item_linkable.ff_item_linked {
  background-color: #606266;
  border-color: #606266;
  color: #ffffff;
}
.ff_each_style .ff-control-dimensions li .ff_item_linkable span {
  font-size: 17px;
  margin-top: 4px;
}
.ff_each_style .ff-linked {
  cursor: pointer;
}
.ff_each_style .ff_section_title {
  font-size: 18px;
  font-weight: 500;
  margin-bottom: 10px;
  margin-top: 10px;
}

.ff_type_settings {
  width: 100%;
}
.ff_type_settings .ff-type-control {
  margin-bottom: 10px;
  overflow: hidden;
  display: block;
}
.ff_type_settings .ff-type-control .ff-control-title,
.ff_type_settings .ff-type-control .ff-type-value {
  display: inline-block;
  color: #808184;
  font-size: 12px;
}
.ff_type_settings .ff-type-control .ff-type-value {
  float: right;
  width: 110px;
}
.ff_type_settings .ff-type-control.ff-type-full {
  width: 100%;
}
.ff_type_settings .ff-type-control.ff-type-full .ff-type-value {
  width: 100%;
  float: none;
}

.ff_fullscreen_visuals_section {
  margin-bottom: 20px;
}
.ff_fullscreen_visuals_section .ff_fullscreen_visuals_title {
  margin-bottom: 12px;
  font-size: 15px;
  color: #1E1F21;
  display: flex;
  align-items: center;
  font-weight: 500;
}
.ff_fullscreen_visuals_section .ff_fullscreen_visuals_actions {
  margin-bottom: 12px;
}
.ff_fullscreen_visuals_section .ff_fullscreen_media_pool {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 12px;
  max-height: 280px;
  overflow-y: auto;
}
.ff_fullscreen_visuals_section .ff_fullscreen_media_pool_item {
  position: relative;
  aspect-ratio: 1;
  border: 1px solid #dcdfe6;
  border-radius: 4px;
  overflow: hidden;
  background: #f5f7fa;
  transition: border-color 0.2s, box-shadow 0.2s, z-index 0s;
}
.ff_fullscreen_visuals_section .ff_fullscreen_media_pool_item:hover {
  z-index: 10;
  border-color: #409eff;
  box-shadow: 0 4px 12px rgba(64, 158, 255, 0.35);
}
.ff_fullscreen_visuals_section .ff_fullscreen_media_pool_item.ff_fullscreen_media_pool_item_draggable {
  cursor: grab;
}
.ff_fullscreen_visuals_section .ff_fullscreen_media_pool_item.ff_fullscreen_media_pool_item_draggable:active {
  cursor: grabbing;
}
.ff_fullscreen_visuals_section .ff_fullscreen_media_pool_item .ff_fullscreen_media_thumb {
  width: 100%;
  height: 100%;
  -o-object-fit: cover;
     object-fit: cover;
  border-radius: 3px;
  display: block;
}
.ff_fullscreen_visuals_section .ff_fullscreen_media_pool_item .ff_fullscreen_media_pool_drag_icon {
  position: absolute;
  bottom: 4px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  border-radius: 4px;
  padding: 2px 6px;
  opacity: 0;
  transition: opacity 0.2s;
  pointer-events: none;
  z-index: 1;
}
.ff_fullscreen_visuals_section .ff_fullscreen_media_pool_item .ff_fullscreen_media_pool_drag_icon .dashicons {
  font-size: 16px;
  width: 16px;
  height: 16px;
}
.ff_fullscreen_visuals_section .ff_fullscreen_media_pool_item.ff_fullscreen_media_pool_item_draggable:hover .ff_fullscreen_media_pool_drag_icon {
  opacity: 1;
}
.ff_fullscreen_visuals_section .ff_fullscreen_media_pool_item .ff_fullscreen_media_placeholder {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #909399;
}
.ff_fullscreen_visuals_section .ff_fullscreen_media_pool_item .ff_fullscreen_media_remove {
  position: absolute;
  top: 2px;
  right: 4px;
  cursor: pointer;
  color: #909399;
  font-size: 16px;
  line-height: 1;
  z-index: 2;
}
.ff_fullscreen_visuals_section .ff_fullscreen_media_pool_item .ff_fullscreen_media_remove:hover {
  color: #f56c6c;
}
.ff_fullscreen_visuals_section .ff_fullscreen_media_pool_item .ff_fullscreen_media_url_input {
  position: absolute;
  inset: 0;
}
.ff_fullscreen_visuals_section .ff_fullscreen_media_pool_item .ff_fullscreen_media_url_input .el-input__inner {
  font-size: 11px;
  padding: 2px 20px 2px 4px;
  height: 100%;
}

.ff_fullscreen_fields_section {
  margin-bottom: 20px;
}
.ff_fullscreen_fields_section .ff_fullscreen_fields_list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 12px;
}
.ff_fullscreen_fields_section .ff_fullscreen_field_row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border: 1px solid transparent;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}
.ff_fullscreen_fields_section .ff_fullscreen_field_row:hover {
  background: #f5f7fa;
}
.ff_fullscreen_fields_section .ff_fullscreen_field_row.ff_fullscreen_field_row_active {
  background: #fff;
  border-color: #dcdfe6;
}
.ff_fullscreen_fields_section .ff_fullscreen_field_thumb {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border: 1px solid #dcdfe6;
  border-radius: 4px;
  overflow: hidden;
  background: #f5f7fa;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.2s, background 0.2s;
}
.ff_fullscreen_fields_section .ff_fullscreen_field_thumb.ff_fullscreen_field_thumb_drop_over {
  border-color: #409eff;
  background: #ecf5ff;
}
.ff_fullscreen_fields_section .ff_fullscreen_field_thumb.ff_fullscreen_field_thumb_color {
  min-height: 40px;
}
.ff_fullscreen_fields_section .ff_fullscreen_field_thumb img {
  width: 100%;
  height: 100%;
  -o-object-fit: cover;
     object-fit: cover;
}
.ff_fullscreen_fields_section .ff_fullscreen_field_thumb .ff_fullscreen_field_placeholder {
  color: #c0c4cc;
  font-size: 20px;
}
.ff_fullscreen_fields_section .ff_fullscreen_field_label {
  flex: 1;
  font-size: 13px;
  min-width: 0;
}
.ff_fullscreen_fields_section .ff_fullscreen_field_row_active .ff_fullscreen_field_label {
  font-weight: 600;
}
.ff_fullscreen_fields_section .ff_fullscreen_field_position_icon {
  flex-shrink: 0;
  color: #606266;
  cursor: pointer;
  padding: 4px;
}
.ff_fullscreen_fields_section .ff_fullscreen_field_position_icon i {
  font-size: 18px;
}
.ff_fullscreen_fields_section .ff_fullscreen_no_fields {
  font-size: 13px;
  color: #909399;
  margin: 12px 0 0;
}

.ff_fullscreen_pool_picker_popover {
  max-width: 320px;
}

.ff_fullscreen_pool_picker_panel {
  padding: 8px 0;
}
.ff_fullscreen_pool_picker_panel .ff_fullscreen_pool_picker_title {
  font-weight: 600;
  font-size: 13px;
  margin-bottom: 10px;
  padding: 0 4px;
}
.ff_fullscreen_pool_picker_panel .ff_fullscreen_pool_picker_list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  max-height: 200px;
  overflow-y: auto;
  margin-bottom: 10px;
  padding: 0 4px;
}
.ff_fullscreen_pool_picker_panel .ff_fullscreen_pool_picker_item {
  position: relative;
  z-index: 1;
  aspect-ratio: 1;
  border: 1px solid #dcdfe6;
  border-radius: 4px;
  overflow: hidden;
  cursor: pointer;
  background: #f5f7fa;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.ff_fullscreen_pool_picker_panel .ff_fullscreen_pool_picker_item:hover {
  z-index: 2;
  border-color: #409eff;
  box-shadow: 0 0 0 2px rgba(64, 158, 255, 0.2);
}
.ff_fullscreen_pool_picker_panel .ff_fullscreen_pool_picker_item img {
  width: 100%;
  height: 100%;
  -o-object-fit: cover;
     object-fit: cover;
  display: block;
}
.ff_fullscreen_pool_picker_panel .ff_fullscreen_pool_picker_empty {
  font-size: 12px;
  color: #909399;
  margin: 0 0 10px;
  padding: 0 4px;
}
.ff_fullscreen_pool_picker_panel .el-button {
  padding: 0 4px;
}

.ff_fullscreen_image_position_panel .ff_fullscreen_image_position_title,
.ff_fullscreen_image_position_panel .ff_fullscreen_image_placement_title,
.ff_fullscreen_image_placement_panel .ff_fullscreen_image_position_title,
.ff_fullscreen_image_placement_panel .ff_fullscreen_image_placement_title {
  margin-bottom: 12px;
}
.ff_fullscreen_image_position_panel .ff_fullscreen_opacity_form_item,
.ff_fullscreen_image_placement_panel .ff_fullscreen_opacity_form_item {
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.ff_fullscreen_image_position_panel .ff_fullscreen_opacity_form_item .el-form-item__label,
.ff_fullscreen_image_placement_panel .ff_fullscreen_opacity_form_item .el-form-item__label {
  text-align: left;
}

.ff-styling-preview-area {
  background: var(--ff-ai-settings-card-bg);
  border: 1px solid var(--ff-ai-settings-border);
  border-radius: var(--ff-ai-settings-border-radius);
  box-shadow: var(--ff-ai-settings-shadow);
  overflow: hidden;
}
@media (max-width: 1200px) {
  .ff-styling-preview-area {
    position: relative;
    top: 0;
    margin-top: 20px;
  }
}

.ff-ai-chat-sticky-preview {
  position: sticky;
  top: 136px;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
}

.ff-preview-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--ff-ai-settings-border);
  background: var(--ff-ai-settings-bg);
  position: sticky;
  top: 0;
  z-index: 10;
}
.ff-preview-header h4 {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: var(--ff-ai-settings-text-primary);
}

.ff-preview-messages {
  display: flex;
  flex-direction: column;
  background: var(--ff-ai-bg-light, #f9fafb);
  padding: 20px;
  min-height: 300px;
}

.fcc_design_preview .ff_browser {
  width: 100%;
}
.fcc_design_preview .browser-frame {
  border-radius: 10px;
  box-shadow: 0 0 3px #E6ECEF;
  overflow: hidden;
  max-width: 100%;
}
.fcc_design_preview .browser-controls {
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: space-around;
  background: #E6ECEF;
  color: #BEC4C6;
}
.fcc_design_preview .window-controls {
  flex: 0 0 60px;
  margin: 0 2%;
}
.fcc_design_preview .window-controls span {
  display: inline-block;
  width: 15px;
  height: 15px;
  border-radius: 50px;
  background: #FF8585;
}
.fcc_design_preview .window-controls span.minimise {
  background: #FFD071;
}
.fcc_design_preview .window-controls span.maximise {
  background: #74ED94;
}
.fcc_design_preview .page-controls {
  flex: 0 0 70px;
  margin-right: 2%;
}
.fcc_design_preview .page-controls span {
  display: inline-block;
  width: 30px;
  text-align: center;
  padding-top: 5px;
  height: 20px;
  font-size: 13px;
  line-height: 11px;
}
.fcc_design_preview .url-bar {
  flex-grow: 1;
  margin-right: 2%;
  padding: 5px 5px 0 10px;
  font-family: monospace;
  font-size: 13px;
  color: rgb(135.6557377049, 146.6721311475, 150.3442622951);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.fcc_design_preview .white-container {
  height: 25px;
  min-width: 30px;
  border-radius: 3px;
  background: white;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}
.fcc_design_preview #ff_ai_chat_preview_iframe_holder {
  min-height: 600px;
  background: #fff;
  border-bottom-left-radius: 8px;
  border-bottom-right-radius: 8px;
}
.fcc_design_preview .browser-frame.ffc_browser_mobile {
  max-width: 375px;
  margin: 0 auto;
}
.fcc_design_preview .fcc_device_switcher {
  text-align: center;
  margin-top: 20px;
}

@media (max-width: 1024px) {
  .ff-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 768px) {
  .ff-chat-styling-container {
    width: 100%;
    max-width: 100%;
  }
  .ff-ai-chat-form .el-form-item .el-form-item__label {
    width: 100% !important;
    float: none;
    padding: 0 0 8px 0;
  }
  .ff-ai-chat-form .el-form-item .el-form-item__content {
    width: 100%;
    margin-left: 0 !important;
  }
  .ff-ai-chat-sticky-header {
    position: relative;
    top: auto;
  }
  .ff-ai-chat-sticky-preview {
    position: relative;
    top: 0;
    max-height: none;
  }
  #ff_ai_chat_settings_app {
    padding: 16px 16px 0;
  }
  .ff-ai-chat-embed-section .ff-ai-chat-embed-controls {
    flex-direction: column;
  }
  .ff-ai-chat-embed-section .ff-ai-chat-embed-controls .ff-ai-chat-embed-action {
    margin-top: 10px;
    width: 100%;
  }
  .ff-stats-grid {
    grid-template-columns: 1fr;
  }
  .ff-ai-chat-form .el-form-item {
    margin-bottom: 24px !important;
  }
}
