/* ==========================================================================
   OORA CLEAN - LIVE IN-LINE WYSIWYG & CMS SYSTEM
   Interactive In-Browser Visual Editor
   ========================================================================== */

/* Mode Active State */
body.cms-edit-mode [data-cms-key] {
  outline: 2px dashed rgba(0, 180, 216, 0.6) !important;
  outline-offset: 4px;
  cursor: text;
  transition: outline-color 0.2s ease, background-color 0.2s ease;
  position: relative;
}

body.cms-edit-mode [data-cms-key]:hover {
  outline-color: var(--color-primary) !important;
  background-color: rgba(0, 180, 216, 0.06);
}

body.cms-edit-mode [data-cms-key]:focus {
  outline: 2px solid var(--color-primary) !important;
  background-color: rgba(0, 180, 216, 0.1);
}

/* Floating Bottom CMS Control Bar */
.wysiwyg-floating-bar {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(120%);
  background: rgba(15, 23, 42, 0.94);
  color: #ffffff;
  padding: 0.75rem 1.4rem;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  gap: 1.25rem;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(16px);
  z-index: 10000;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.wysiwyg-floating-bar.active {
  transform: translateX(-50%) translateY(0);
}

.wysiwyg-bar-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: #ffffff;
}

.wysiwyg-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-accent-green);
  box-shadow: 0 0 10px var(--color-accent-green);
}

.wysiwyg-btn-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.wysiwyg-btn {
  background: rgba(255, 255, 255, 0.12);
  border: none;
  color: #ffffff;
  padding: 0.45rem 0.9rem;
  border-radius: var(--radius-full);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: all 0.2s ease;
}

.wysiwyg-btn:hover {
  background: rgba(255, 255, 255, 0.24);
  transform: translateY(-1px);
}

.wysiwyg-btn-primary {
  background: var(--color-primary);
}

.wysiwyg-btn-primary:hover {
  background: var(--color-primary-light);
}

.wysiwyg-btn-success {
  background: var(--color-accent-green);
  color: #064e3b;
}

.wysiwyg-btn-success:hover {
  background: #22c55e;
}

/* Floating Rich Text Selection Toolbar */
#wysiwygSelectionToolbar {
  position: absolute;
  display: none;
  background: #0f172a;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 10px 25px rgba(0,0,0,0.35);
  border-radius: 8px;
  padding: 4px;
  z-index: 10005;
  gap: 4px;
  align-items: center;
}

.wysiwyg-tool-btn {
  background: transparent;
  border: none;
  color: #ffffff;
  width: 30px;
  height: 30px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}

.wysiwyg-tool-btn:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* Toast Notifications */
.cms-toast {
  position: fixed;
  top: 25px;
  right: 25px;
  background: #0f172a;
  color: #ffffff;
  padding: 0.9rem 1.4rem;
  border-radius: var(--radius-md);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.9rem;
  font-weight: 600;
  z-index: 11000;
  transform: translateY(-50px);
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  border-left: 4px solid var(--color-accent-green);
}

.cms-toast.show {
  transform: translateY(0);
  opacity: 1;
}
