/* ============================================
   ADMIN PANEL
   Settings panel - slide-out from right
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

/* ===== ADMIN COLOR SYSTEM =====
   Independent of site theme - always renders as a dark software UI.
   Overrides inherited CSS variables within admin scope. */
#admin-panel,
.onboarding-wizard,
.admin-toast,
.auth-modal {
  --bg-primary: #1E1E2E;
  --bg-secondary: #181825;
  --bg-tertiary: #252538;
  --bg-elevated: #2A2A3C;
  --text-primary: #CDD6F4;
  --text-secondary: #A6ADC8;
  --text-muted: #6C7086;
  --border-color: rgba(147, 153, 178, 0.12);
  --border-strong: rgba(147, 153, 178, 0.2);
  --accent: #3B82F6;
  --accent-hover: #2563EB;
  --accent-glow: rgba(59, 130, 246, 0.3);
  --accent-subtle: rgba(59, 130, 246, 0.12);
  --shadow-2xl: 0 25px 60px rgba(0, 0, 0, 0.5);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.3);
  --shadow-glow-sm: 0 0 12px rgba(59, 130, 246, 0.3);

  /* Lock border-radius to fixed values - admin panel should not be affected by corner style */
  --radius-sm: 0.375rem;
  --radius-base: 0.5rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --radius-2xl: 2rem;
  --radius-full: 9999px;

  color: var(--text-primary);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-display: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-heading: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* ===== ADMIN OVERLAY ===== */
/* Overlay - transparent so user can see live changes */
.admin-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: transparent;
  z-index: var(--z-overlay);
}

.admin-overlay.active {
  display: block;
}

/* Admin tab button - fixed to top-right edge (outside #admin-panel scope) */
.admin-fab {
  position: fixed;
  top: 28px;
  right: 0;
  padding: 8px 10px 8px 14px;
  border-radius: 8px 0 0 8px;
  background: #3B82F6;
  color: #fff;
  border: none;
  cursor: pointer;
  z-index: var(--z-fixed);
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  box-shadow: -2px 2px 12px rgba(0, 0, 0, 0.3);
  transition: background 0.2s ease;
  overflow: hidden;
}

.admin-fab span {
  max-width: 0;
  overflow: hidden;
  white-space: nowrap;
  opacity: 0;
  transition: max-width 0.25s ease, opacity 0.2s ease;
}

.admin-fab:hover {
  background: #2563EB;
}

.admin-fab:hover span {
  max-width: 40px;
  opacity: 1;
}

.admin-fab.hidden {
  display: none;
}

/* ===== ADMIN PANEL CONTAINER ===== */
#admin-panel {
  position: fixed;
  top: 0;
  right: -500px;
  width: 470px;
  height: 100vh;
  background: var(--bg-primary);
  border-left: var(--border-1) solid var(--border-strong);
  box-shadow: var(--shadow-2xl);
  z-index: var(--z-modal);
  transition: right var(--transition-base) var(--ease-smooth);
  overflow: hidden;
}

#admin-panel.active {
  right: 0;
}

.admin-panel-inner {
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* ===== ADMIN HEADER ===== */
.admin-header {
  padding: var(--space-6);
  border-bottom: var(--border-1) solid var(--border-color);
  display: flex;
  align-items: center;
  gap: var(--space-3);
  background: var(--bg-secondary);
  flex-shrink: 0;
}

.admin-header-logo {
  height: 26px;
  width: auto;
  flex: 1;
  object-fit: contain;
  object-position: left;
  filter: brightness(0) invert(1);
}

.admin-type-badge {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 4px;
  line-height: 1;
}
.admin-type-badge.studio {
  background: rgba(212, 175, 55, 0.15);
  color: #D4AF37;
}
.admin-type-badge.artist {
  background: rgba(244, 114, 182, 0.15);
  color: #F472B6;
}

.admin-help-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: var(--weight-bold);
  font-size: var(--text-sm);
  transition: color 0.2s ease, background 0.2s ease;
  border: var(--border-1) solid var(--border-color);
  flex-shrink: 0;
}

.admin-help-btn:hover {
  color: var(--accent);
  background: var(--bg-tertiary);
  border-color: var(--accent);
}

.admin-page-banner {
  padding: var(--space-3) var(--space-6);
  background: var(--accent-subtle);
  border-bottom: var(--border-1) solid var(--border-color);
  font-size: var(--text-sm);
  color: var(--text-secondary);
  flex-shrink: 0;
}

.admin-page-banner strong {
  color: var(--accent);
  font-weight: var(--weight-semibold);
}

.admin-close,
#admin-close-btn {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: var(--border-2) solid var(--border-color);
  border-radius: var(--radius-full);
  color: var(--text-secondary);
  font-size: var(--text-2xl);
  line-height: 1;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.admin-close:hover,
#admin-close-btn:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--text-primary);
  transform: rotate(90deg);
  box-shadow: var(--shadow-glow-sm);
}

.admin-undo-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 12px;
  font-size: var(--text-xs);
  font-weight: var(--weight-medium);
  color: var(--text-secondary);
  background: var(--bg-tertiary);
  border: var(--border-1) solid var(--border-color);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.admin-undo-btn:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-subtle);
}

/* ===== ADMIN TABS ===== */
.admin-tabs {
  display: flex;
  border-bottom: var(--border-1) solid var(--border-color);
  background: var(--bg-secondary);
  position: relative;
  flex-shrink: 0;
}

.admin-tab {
  flex: 1;
  padding: var(--space-4) var(--space-3);
  background: transparent;
  border: none;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wider);
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition-fast);
  position: relative;
}

.admin-tab:hover {
  color: var(--text-primary);
}

.admin-tab.active {
  color: var(--accent);
}

.admin-tab.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent);
}

/* ===== ADMIN CONTENT ===== */
.admin-content {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: var(--space-6);
  position: relative;
  scrollbar-width: thin;
  scrollbar-color: var(--accent) var(--bg-tertiary);
}

.admin-content::-webkit-scrollbar {
  width: 8px;
}

.admin-content::-webkit-scrollbar-track {
  background: var(--bg-tertiary);
}

.admin-content::-webkit-scrollbar-thumb {
  background: var(--accent);
  border-radius: var(--radius-full);
}

.admin-tab-content {
  display: none;
}

.admin-tab-content.active {
  display: block;
  animation: fadeIn 0.3s var(--ease-out);
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ===== ADMIN SECTIONS ===== */
.admin-section {
  margin-bottom: var(--space-8);
  padding-bottom: var(--space-6);
  border-bottom: var(--border-1) solid var(--border-color);
}

.admin-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

/* Collapsibles already have their own border, remove section border */
.admin-section.admin-collapsible {
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: var(--space-3);
}


.admin-section h4 {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: var(--weight-bold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
  color: var(--text-primary);
  margin-bottom: var(--space-5);
}

.admin-section-description {
  font-size: var(--text-sm);
  color: var(--text-muted);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-5);
}

/* ===== FORM CONTROLS ===== */
.admin-field {
  margin-bottom: var(--space-5);
}

/* Tighter spacing inside collapsibles and list items */
.admin-collapsible-content .admin-field,
.admin-list-item .admin-field {
  margin-bottom: var(--space-4);
}

.admin-field label {
  display: block;
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wider);
  color: var(--text-primary);
  margin-bottom: var(--space-2);
}

.admin-help-text {
  font-size: var(--text-xs);
  color: var(--text-muted);
  margin: 0 0 var(--space-2) 0;
}

.admin-field input[type="text"],
.admin-field input[type="email"],
.admin-field input[type="url"],
.admin-field input[type="tel"],
.admin-field input[type="color"],
.admin-field select,
.admin-field textarea,
.admin-collapsible-content input[type="text"],
.admin-collapsible-content textarea {
  width: 100%;
  padding: var(--space-3);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--text-primary);
  background: var(--bg-elevated);
  border: var(--border-1) solid var(--border-color);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
}

.admin-field input:focus,
.admin-field select:focus,
.admin-field textarea:focus,
.admin-collapsible-content input:focus,
.admin-collapsible-content textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-subtle);
  background: var(--bg-elevated);
}

.admin-field textarea,
.admin-collapsible-content textarea {
  min-height: 80px;
  resize: vertical;
}

.admin-field input[type="file"] {
  width: 100%;
  padding: var(--space-2);
  font-family: var(--font-body);
  font-size: var(--text-xs);
  color: var(--text-secondary);
  background: var(--bg-elevated);
  border: var(--border-1) dashed var(--border-color);
  border-radius: var(--radius-md);
  cursor: pointer;
}

.admin-field input[type="file"]::file-selector-button {
  padding: var(--space-1) var(--space-3);
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  color: var(--accent);
  background: var(--accent-subtle);
  border: var(--border-1) solid var(--accent);
  border-radius: var(--radius-base);
  cursor: pointer;
  margin-right: var(--space-2);
}

.admin-field input[type="color"] {
  height: 48px;
  padding: var(--space-2);
  cursor: pointer;
}

/* ===== THEME SWITCHER ===== */
.theme-switcher {
  display: flex;
  gap: var(--space-3);
}

.theme-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-4);
  background: var(--bg-elevated);
  border: var(--border-2) solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wider);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.theme-btn:hover {
  border-color: var(--accent);
  color: var(--text-primary);
}

.theme-btn.active {
  border-color: var(--accent);
  background: var(--accent-subtle);
  color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-subtle);
}

.theme-preview {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  border: var(--border-2) solid var(--border-color);
}

.theme-preview.dark {
  background: linear-gradient(135deg, #0A0A0A 0%, #1A1A1A 100%);
}

.theme-preview.light {
  background: linear-gradient(135deg, #FFFFFF 0%, #F5F5F5 100%);
}

/* Corner style buttons reuse theme-btn styles */
.corner-style-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-4);
  background: var(--bg-elevated);
  border: var(--border-2) solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wider);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.corner-style-btn:hover {
  border-color: var(--accent);
  color: var(--text-primary);
}

.corner-style-btn.active {
  border-color: var(--accent);
  background: var(--accent-subtle);
  color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-subtle);
}

.corner-preview {
  width: 40px;
  height: 40px;
  background: var(--bg-primary);
  border: var(--border-2) solid var(--border-strong);
}

.corner-preview.square {
  border-radius: 0;
}

.corner-preview.rounded {
  border-radius: 8px;
}

.corner-preview.pill {
  border-radius: 9999px;
}

/* ===== COLOR PRESETS ===== */
.color-presets {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 5px;
  margin-bottom: var(--space-4);
}

.color-preset,
.color-preset-secondary {
  height: 28px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--border-color);
  cursor: pointer;
  transition: all var(--transition-fast);
  position: relative;
}

.color-preset:hover,
.color-preset-secondary:hover {
  transform: scale(1.1);
  box-shadow: var(--shadow-md);
  z-index: 1;
}

.color-preset.active,
.color-preset-secondary.active {
  border-color: #FFFFFF;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.5), var(--shadow-md);
}

.color-preset.active::after,
.color-preset-secondary.active::after {
  content: '\2713';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #FFFFFF;
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
}

/* ===== COLOR PICKER ===== */
.color-picker-wrapper {
  display: flex;
  gap: var(--space-4);
  align-items: flex-start;
  margin-top: var(--space-2);
}

#color-wheel {
  border-radius: var(--radius-full);
  cursor: crosshair;
  flex-shrink: 0;
  width: 140px;
  height: 140px;
}

.color-picker-controls {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  min-width: 0;
}

.color-picker-preview-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.color-picker-preview {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  border: 2px solid var(--border-color);
  flex-shrink: 0;
}

.color-picker-preview-row input {
  flex: 1;
  min-width: 0;
}

.color-picker-slider-row {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.color-picker-slider-row label {
  font-size: var(--text-xs);
  color: var(--text-muted);
  margin: 0;
}

.color-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: linear-gradient(to right, #000, #888, #FFF);
  outline: none;
  cursor: pointer;
}

.color-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 16px;
  height: 16px;
  border-radius: var(--radius-full);
  background: #FFF;
  border: 2px solid var(--border-strong);
  cursor: pointer;
  box-shadow: var(--shadow-sm);
}

.color-slider::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border-radius: var(--radius-full);
  background: #FFF;
  border: 2px solid var(--border-strong);
  cursor: pointer;
  box-shadow: var(--shadow-sm);
}

/* ===== TOGGLE SWITCH ===== */
.toggle-switch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-4);
  background: var(--bg-tertiary);
  border: var(--border-1) solid var(--border-color);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-3);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.toggle-switch:hover {
  border-color: var(--accent);
  background: var(--bg-elevated);
}

.toggle-switch-label {
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--text-primary);
}

.toggle-input {
  position: relative;
  width: 48px;
  height: 24px;
  background: var(--bg-tertiary);
  border: var(--border-2) solid var(--border-color);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.toggle-input::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  background: var(--text-muted);
  border-radius: var(--radius-full);
  transition: all var(--transition-fast);
}

.toggle-switch.active .toggle-input {
  background: var(--accent);
  border-color: var(--accent);
}

.toggle-switch.active .toggle-input::after {
  left: 26px;
  background: var(--text-primary);
}

/* ===== FILE UPLOAD ===== */
.file-upload {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.file-upload-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-5);
  background: var(--bg-elevated);
  border: var(--border-2) solid var(--accent);
  border-radius: var(--radius-md);
  color: var(--accent);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wider);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.file-upload-btn:hover {
  background: var(--accent);
  color: var(--text-primary);
  box-shadow: var(--shadow-glow-sm);
}

.file-upload input[type="file"] {
  display: none;
}

.file-upload-preview {
  max-width: 100%;
  max-height: 120px;
  border-radius: var(--radius-md);
  border: var(--border-1) solid var(--border-color);
}

/* ===== COLLAPSIBLE SECTIONS ===== */
.admin-collapsible {
  margin-bottom: var(--space-3);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--bg-tertiary);
}

.admin-collapsible-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-4);
  margin: 0;
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  color: var(--text-primary);
  cursor: pointer;
  user-select: none;
  transition: background var(--transition-fast);
}

.admin-collapsible-header:hover {
  background: var(--bg-elevated);
}

/* Override admin-section h4 margin inside collapsibles */
h4.admin-collapsible-header {
  margin-bottom: 0;
}

.admin-collapse-icon {
  font-size: var(--text-sm);
  color: var(--text-muted);
  transition: transform var(--transition-base);
}

.admin-collapsible.open .admin-collapse-icon {
  transform: rotate(180deg);
}

.admin-collapsible-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  padding: 0 var(--space-4);
  border-top: var(--border-1) solid transparent;
}

.admin-collapsible.open .admin-collapsible-content {
  border-top-color: var(--border-color);
}

.admin-collapsible-content > :first-child {
  margin-top: var(--space-4);
}

.admin-collapsible-content > :last-child {
  margin-bottom: var(--space-4);
}

/* ===== ADMIN BUTTONS ===== */
.admin-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  width: 100%;
  padding: var(--space-4);
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: var(--weight-bold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wider);
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.admin-btn-primary {
  background: var(--accent);
  color: var(--text-primary);
}

.admin-btn-primary:hover {
  background: var(--accent-hover);
  box-shadow: var(--shadow-glow-sm);
  transform: translateY(-2px);
}

.admin-btn-secondary {
  background: var(--bg-elevated);
  border: var(--border-2) solid var(--border-color);
  color: var(--text-primary);
}

.admin-btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.admin-btn-danger {
  background: transparent;
  border: var(--border-2) solid #DC2626;
  color: #DC2626;
}

.admin-btn-danger:hover {
  background: #DC2626;
  color: var(--text-primary);
}

.admin-btn + .admin-btn {
  margin-top: var(--space-3);
}

/* ===== LIST EDITOR ===== */
.admin-list-item {
  padding: var(--space-4);
  background: var(--bg-elevated);
  border: var(--border-1) solid var(--border-color);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-3);
}

.admin-list-item .admin-field:last-of-type {
  margin-bottom: var(--space-2);
}

.admin-list-item hr {
  display: none;
}

.list-editor {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.list-item {
  padding: var(--space-4);
  background: var(--bg-tertiary);
  border: var(--border-1) solid var(--border-color);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  transition: border-color var(--transition-fast);
}

.list-item:hover {
  border-color: var(--accent);
}

.list-item-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.list-item-title {
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  color: var(--text-primary);
}

.list-item-actions {
  display: flex;
  gap: var(--space-2);
}

.list-item-btn {
  padding: var(--space-1) var(--space-2);
  background: transparent;
  border: var(--border-1) solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-size: var(--text-xs);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.list-item-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.list-item-btn.delete:hover {
  border-color: #DC2626;
  color: #DC2626;
}

/* ===== ONBOARDING WIZARD ===== */
.onboarding-wizard {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: calc(var(--z-modal) + 1);
  align-items: center;
  justify-content: center;
}

.onboarding-wizard.active {
  display: flex;
  animation: fadeIn 0.3s var(--ease-out);
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.onboarding-modal {
  width: 90%;
  max-width: 540px;
  max-height: 90vh;
  background: var(--bg-primary);
  border: var(--border-1) solid var(--border-strong);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-2xl);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: modalSlideUp 0.4s var(--ease-out);
}

@keyframes modalSlideUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Step indicator dots */
.onboarding-header {
  padding: var(--space-5) var(--space-6);
  background: var(--bg-secondary);
  border-bottom: var(--border-1) solid var(--border-color);
}

.onboarding-step-indicator {
  display: flex;
  gap: var(--space-2);
  justify-content: center;
}

.step-dot {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  background: var(--bg-tertiary);
  transition: all var(--transition-fast);
}

.step-dot.active {
  background: var(--accent);
  box-shadow: 0 0 6px var(--accent-glow);
}

.step-dot.completed {
  background: var(--accent);
}

/* Step content area */
.onboarding-content {
  flex: 1;
  padding: var(--space-8);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.onboarding-step {
  text-align: center;
}

.onboarding-step h2 {
  font-family: var(--font-body);
  font-size: var(--text-2xl);
  font-weight: var(--weight-bold);
  color: var(--text-primary);
  text-transform: none;
  letter-spacing: normal;
  margin-bottom: var(--space-3);
}

.onboarding-step p {
  color: var(--text-secondary);
  font-size: var(--text-sm);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-6);
}

.onboarding-icon {
  font-size: 48px;
  margin-bottom: var(--space-4);
  line-height: 1;
}

/* Feature checklist */
.onboarding-features {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  text-align: left;
  max-width: 320px;
  margin: 0 auto;
}

.feature-item {
  padding: var(--space-3) var(--space-4);
  background: var(--bg-tertiary);
  border-radius: var(--radius-base);
  color: var(--text-secondary);
  font-size: var(--text-sm);
}

/* Form fields */
.onboarding-field {
  text-align: left;
  margin-bottom: var(--space-4);
}

.onboarding-field label {
  display: block;
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--text-secondary);
  margin-bottom: var(--space-2);
}

.onboarding-field input {
  width: 100%;
  padding: var(--space-3);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--text-primary);
  background: var(--bg-elevated);
  border: var(--border-1) solid var(--border-color);
  border-radius: var(--radius-base);
  transition: border-color var(--transition-fast);
}

.onboarding-field input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-subtle);
}

.onboarding-field input::placeholder {
  color: var(--text-muted);
}

/* Theme picker */
.onboarding-theme-picker {
  display: flex;
  gap: var(--space-4);
  justify-content: center;
}

.onboarding-theme-option {
  flex: 1;
  max-width: 180px;
  padding: var(--space-4);
  background: var(--bg-tertiary);
  border: var(--border-2) solid var(--border-color);
  border-radius: var(--radius-md);
  cursor: pointer;
  text-align: center;
  transition: all var(--transition-fast);
  color: var(--text-secondary);
}

.onboarding-theme-option:hover {
  border-color: var(--text-muted);
}

.onboarding-theme-option.active {
  border-color: var(--accent);
  background: var(--accent-subtle);
}

.onboarding-theme-option span {
  display: block;
  font-weight: var(--weight-semibold);
  color: var(--text-primary);
  margin-top: var(--space-2);
}

.onboarding-theme-option p {
  font-size: var(--text-xs);
  margin-bottom: 0;
  margin-top: var(--space-1);
}

.theme-preview-box {
  height: 60px;
  border-radius: var(--radius-sm);
  margin-bottom: var(--space-2);
}

.theme-preview-box.dark {
  background: linear-gradient(135deg, #0A0A0A 0%, #1A1A1A 100%);
}

.theme-preview-box.light {
  background: linear-gradient(135deg, #FFFFFF 0%, #F0F0F0 100%);
  border: 1px solid rgba(0, 0, 0, 0.1);
}

/* Color picker grid */
.onboarding-color-grid {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 5px;
  max-width: 400px;
  margin: 0 auto;
}

.onboarding-color-option {
  height: 36px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--border-color);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
  position: relative;
}

.onboarding-color-option:hover {
  transform: scale(1.08);
}

.onboarding-color-option.active {
  border-color: #FFFFFF;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.5);
}

.color-check {
  font-size: 18px;
  opacity: 0;
  transition: opacity var(--transition-fast);
}

.onboarding-color-option.active .color-check {
  opacity: 1;
}

.color-name {
  font-size: 10px;
  font-weight: var(--weight-semibold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wider);
}

/* Footer with navigation buttons */
.onboarding-footer {
  padding: var(--space-4) var(--space-6);
  background: var(--bg-secondary);
  border-top: var(--border-1) solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Wizard buttons */
.btn-admin {
  padding: var(--space-2) var(--space-4);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: var(--weight-medium);
  color: var(--text-secondary);
  background: transparent;
  border: var(--border-1) solid var(--border-color);
  border-radius: var(--radius-base);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-admin:hover {
  color: var(--text-primary);
  border-color: var(--text-muted);
}

.btn-admin.btn-accent {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.btn-admin.btn-accent:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
}

/* Small inline buttons (save, add, apply, remove) */
.btn-small {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: var(--space-2) var(--space-3);
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  color: var(--text-secondary);
  background: var(--bg-elevated);
  border: var(--border-1) solid var(--border-color);
  border-radius: var(--radius-base);
  cursor: pointer;
  transition: all var(--transition-fast);
  margin-top: var(--space-1);
}

.btn-small:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-subtle);
}

.btn-small.btn-accent {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.btn-small.btn-accent:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
}

.btn-admin.btn-danger,
.btn-small.btn-danger {
  color: #DC2626;
  border-color: rgba(220, 38, 38, 0.3);
  background: transparent;
}

.btn-admin.btn-danger:hover,
.btn-small.btn-danger:hover {
  background: #DC2626;
  border-color: #DC2626;
  color: #fff;
}

/* ===== MOBILE ADMIN PANEL ===== */
@media (max-width: 1280px) {
  /* Move admin fab below header so it doesn't overlap mobile nav toggle */
  .admin-fab {
    top: 80px;
  }

  #admin-panel {
    width: 100%;
    right: -100%;
  }

  /* Larger close button tap target (44px minimum) */
  .admin-close,
  #admin-close-btn {
    width: 44px;
    height: 44px;
    font-size: 18px;
  }

  /* Scrollable tab bar for small screens */
  .admin-tabs {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .admin-tabs::-webkit-scrollbar {
    display: none;
  }
  .admin-tab {
    white-space: nowrap;
    min-width: auto;
    padding: var(--space-3) var(--space-2);
    font-size: 11px;
  }

  /* Smooth scrolling for content area */
  .admin-content {
    -webkit-overflow-scrolling: touch;
    padding: var(--space-4);
  }

  /* Prevent iOS zoom on input focus (must be >= 16px) */
  .admin-field input[type="text"],
  .admin-field input[type="email"],
  .admin-field input[type="url"],
  .admin-field input[type="tel"],
  .admin-field select,
  .admin-field textarea,
  .onboarding-field input {
    font-size: 16px;
  }

  /* Section headers tighter on mobile */
  .admin-section-title {
    font-size: var(--text-base);
  }

  /* Editor item controls stack better */
  .editor-item-actions {
    flex-wrap: wrap;
    gap: var(--space-2);
  }

  /* Onboarding wizard mobile */
  .onboarding-modal {
    width: 95%;
    max-width: none;
    max-height: 90vh;
    margin: var(--space-4);
  }

  .onboarding-content {
    padding: var(--space-4);
  }

  .onboarding-footer {
    padding: var(--space-3) var(--space-4);
  }

  .onboarding-theme-picker {
    flex-direction: column;
  }

  .onboarding-color-grid {
    grid-template-columns: repeat(6, 1fr);
  }
}

/* ===== ADMIN ACTIONS (button groups) ===== */
.admin-actions {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.admin-actions .btn-admin {
  width: 100%;
  justify-content: center;
}

/* ===== ADMIN HELP TEXT ===== */
.admin-help {
  font-size: var(--text-xs);
  color: var(--text-muted);
  line-height: var(--leading-relaxed);
  margin-top: var(--space-2);
}

.admin-help code {
  padding: 2px 6px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-sm);
  color: var(--accent);
  font-size: var(--text-xs);
}

/* ===== SAVE TOAST NOTIFICATION ===== */
.admin-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  padding: 12px 20px;
  border-radius: var(--radius-base);
  font-size: var(--text-sm);
  font-family: var(--font-body);
  font-weight: 500;
  z-index: 10001;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  pointer-events: none;
}

.admin-toast.visible {
  opacity: 1;
  transform: translateY(0);
}

.admin-toast.success {
  background: #10b981;
  color: #fff;
}

.admin-toast.error {
  background: #ef4444;
  color: #fff;
}

/* ===== ADMIN CONTEXT NOTE ===== */
.admin-context-note {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  padding: var(--space-4);
  background: var(--bg-tertiary);
  border: var(--border-1) solid var(--border-color);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius-base);
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-6);
}

.admin-context-note .note-icon {
  flex-shrink: 0;
  font-size: 16px;
}

.admin-context-note strong {
  color: var(--text-primary);
  font-weight: var(--weight-semibold);
}

/* ===== PORTFOLIO IMAGE UPLOADER ===== */

.portfolio-upload-area {
  border: 2px dashed var(--border-strong);
  border-radius: 8px;
  padding: 16px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  margin-top: 8px;
}

.portfolio-upload-area:hover {
  border-color: var(--accent);
}

.portfolio-upload-area.dragover {
  border-color: var(--accent);
  background: var(--accent-subtle);
}

.portfolio-upload-area p {
  margin: 4px 0 0;
  font-size: 13px;
  color: var(--text-secondary);
}

.portfolio-upload-area small {
  color: var(--text-muted);
  font-size: 11px;
}

.portfolio-upload-area svg {
  width: 28px;
  height: 28px;
  color: var(--text-muted);
}

.portfolio-image-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.portfolio-image-thumb {
  position: relative;
  width: 70px;
  height: 70px;
  border-radius: 6px;
  overflow: hidden;
  background: var(--bg-tertiary);
}

.portfolio-image-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.portfolio-image-thumb .thumb-remove {
  position: absolute;
  top: 3px;
  right: 3px;
  background: rgba(220, 53, 69, 0.9);
  color: white;
  border: none;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  line-height: 1;
  padding: 0;
}

.portfolio-image-thumb:hover .thumb-remove {
  display: flex;
}

.portfolio-image-thumb .thumb-remove:hover {
  background: rgba(220, 53, 69, 1);
  transform: scale(1.1);
}

.portfolio-image-thumb.dragging {
  opacity: 0.4;
}

.portfolio-image-thumb.drag-over {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}

.portfolio-image-count {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 6px;
}

/* ===== ICON PICKER ===== */

/* Field wrapper: preview + choose button */
.icon-field-wrapper {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.icon-field-preview {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-elevated);
  border: var(--border-1) solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 20px;
  color: var(--accent);
  flex-shrink: 0;
}

.icon-field-btn {
  flex: 1;
  padding: var(--space-2) var(--space-4);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--text-primary);
  background: var(--bg-elevated);
  border: var(--border-1) solid var(--border-color);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
  text-align: left;
}

.icon-field-btn:hover {
  border-color: var(--accent);
  background: var(--bg-tertiary);
}

/* Floating picker panel */
.icon-picker {
  position: absolute;
  z-index: 9999;
  background: var(--bg-primary);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-2xl);
  display: none;
  flex-direction: column;
  max-height: 380px;
  overflow: hidden;
}

.icon-picker.open {
  display: flex;
}

/* Search */
.icon-picker-search-wrap {
  padding: 10px 10px 6px;
}

.icon-picker-search {
  width: 100%;
  padding: 8px 12px;
  font-family: var(--font-body);
  font-size: 13px;
  color: var(--text-primary);
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  outline: none;
  box-sizing: border-box;
}

.icon-picker-search:focus {
  border-color: var(--accent);
}

.icon-picker-search::placeholder {
  color: var(--text-muted);
}

/* Category tabs */
.icon-picker-tabs {
  display: flex;
  gap: 2px;
  padding: 0 10px 6px;
  overflow-x: auto;
  flex-shrink: 0;
}

.icon-picker-tab {
  padding: 4px 10px;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  background: none;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.icon-picker-tab:hover {
  color: var(--text-primary);
  background: var(--bg-tertiary);
}

.icon-picker-tab.active {
  color: var(--accent);
  background: var(--accent-subtle);
}

/* Icon grid */
.icon-picker-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(42px, 1fr));
  gap: 4px;
  padding: 6px 10px 10px;
  overflow-y: auto;
  flex: 1;
}

.icon-picker-item {
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: var(--text-secondary);
  background: none;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.icon-picker-item:hover {
  color: var(--accent);
  background: var(--accent-subtle);
  border-color: var(--accent);
}

.icon-picker-item.selected {
  color: var(--accent);
  background: var(--accent-subtle);
  border-color: var(--accent);
}

/* Empty state */
.icon-picker-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: var(--space-6);
  color: var(--text-muted);
  font-size: var(--text-sm);
}

/* ============================================
   AUTH UI
   Sign-in modal, auth button, save status
   ============================================ */

/* Auth button in admin header */
.admin-auth-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text-secondary);
  font-size: 12px;
  font-family: var(--font-body);
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.admin-auth-btn:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border-color: var(--border-strong);
}

.admin-auth-btn.signed-in {
  color: var(--accent);
  border-color: var(--accent-subtle);
}

.admin-auth-btn.signed-in:hover {
  background: var(--accent-subtle);
}

/* Save status indicator */
.admin-save-status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: var(--text-muted);
  padding: 0 8px;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.admin-save-status.visible {
  opacity: 1;
}

.admin-save-status.saving {
  color: var(--text-secondary);
}

.admin-save-status.saved {
  color: #22c55e;
}

.admin-save-status.error {
  color: #ef4444;
}

/* Sign-in modal overlay */
.auth-modal {
  position: fixed;
  inset: 0;
  z-index: 100001;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.auth-modal.open {
  opacity: 1;
  visibility: visible;
}

/* Modal card */
.auth-modal-content {
  width: 100%;
  max-width: 400px;
  margin: 16px;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-2xl);
  padding: 32px;
  color: var(--text-primary);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  transform: translateY(8px);
  transition: transform 0.2s ease;
}

.auth-modal.open .auth-modal-content {
  transform: translateY(0);
}

.auth-modal-header {
  text-align: center;
  margin-bottom: 24px;
}

.auth-modal-logo {
  display: block;
  height: 28px;
  width: auto;
  margin: 0 auto 16px;
  filter: brightness(0) invert(1);
}

.auth-modal-header p {
  font-size: 13px;
  color: var(--text-secondary);
  margin: 0;
}

/* Auth form inputs */
.auth-field {
  margin-bottom: 16px;
}

.auth-field label {
  display: block;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.auth-input {
  width: 100%;
  padding: 10px 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 14px;
  font-family: var(--font-body);
  outline: none;
  transition: border-color 0.15s ease;
  box-sizing: border-box;
}

.auth-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-subtle);
}

.auth-input::placeholder {
  color: var(--text-muted);
}

/* Auth submit button */
.auth-btn {
  width: 100%;
  padding: 10px 16px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  font-family: var(--font-body);
  cursor: pointer;
  transition: background 0.15s ease;
  margin-top: 8px;
}

.auth-btn:hover {
  background: var(--accent-hover);
}

.auth-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Auth error message */
.auth-error {
  display: none;
  padding: 8px 12px;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-radius: var(--radius-sm);
  color: #ef4444;
  font-size: 13px;
  margin-bottom: 16px;
}

.auth-error.visible {
  display: block;
}

/* Auth footer link */
.auth-footer {
  text-align: center;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border-color);
}

.auth-footer a {
  color: var(--accent);
  text-decoration: none;
  font-size: 13px;
}

.auth-footer a:hover {
  text-decoration: underline;
}

/* Close button for modal */
.auth-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 18px;
  cursor: pointer;
  border-radius: var(--radius-sm);
}

.auth-close:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

/* Demo CTA card in Data tab */
.demo-cta-card {
  background: linear-gradient(135deg, var(--bg-tertiary), var(--bg-elevated));
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  padding: 24px;
  text-align: center;
  margin-bottom: 16px;
}

.demo-cta-card h3 {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0 0 8px 0;
}

.demo-cta-card p {
  font-size: 13px;
  color: var(--text-secondary);
  margin: 0 0 16px 0;
  line-height: 1.5;
}

.demo-cta-card .btn-cta {
  display: inline-block;
  padding: 10px 24px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease;
}

.demo-cta-card .btn-cta:hover {
  background: var(--accent-hover);
  color: #fff;
}

/* Mini pricing cards */
.demo-pricing-card {
  flex: 1;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px 12px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  transition: border-color 0.15s ease;
}

.demo-pricing-card:hover {
  border-color: var(--border-strong);
}

.demo-pricing-badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

.demo-pricing-badge.artist {
  color: #fb7185;
  background: rgba(244, 63, 94, 0.12);
}

.demo-pricing-badge.studio {
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.12);
}

.demo-pricing-price {
  font-size: 28px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1;
}

.demo-pricing-desc {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.3;
}

.demo-pricing-btn {
  display: block;
  width: 100%;
  margin-top: 4px;
  padding: 7px 0;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  transition: background 0.15s ease;
}

.demo-pricing-btn:hover {
  background: var(--accent-hover);
  color: #fff;
}

/* ===== Preset Cards ===== */
.preset-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.preset-card-wrapper {
  min-width: 0;
}

.preset-card {
  width: 100%;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0;
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
  overflow: hidden;
  text-align: left;
  display: flex;
  flex-direction: column;
  font-family: var(--font-body);
}

.preset-card:hover {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent);
}

.preset-preview {
  height: 48px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.preset-preview-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
}

.preset-preview-heading {
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  opacity: 0.9;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  padding: 0 8px;
}

.preset-info {
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.preset-name {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.preset-desc {
  font-size: 10px;
  color: var(--text-muted);
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.preset-dots {
  display: flex;
  gap: 4px;
  margin-top: 4px;
}

.preset-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.preset-dot.dark {
  background: #1a1a2e;
  border-color: rgba(255, 255, 255, 0.2);
}

.preset-dot.light {
  background: #f5f5f5;
  border-color: rgba(0, 0, 0, 0.15);
}

.preset-card-wrapper {
  position: relative;
}

.preset-delete {
  position: absolute;
  top: 4px;
  right: 4px;
  z-index: 2;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: none;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.15s ease;
  padding: 0;
}

.preset-card-wrapper:hover .preset-delete {
  opacity: 1;
}

.preset-delete:hover {
  background: rgba(220, 38, 38, 0.8);
}

/* Example cards in presets tab */
.example-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.example-card,
.example-card:link,
.example-card:visited {
  display: flex;
  flex-direction: column;
  align-items: center;
  border-radius: 8px;
  overflow: hidden;
  text-decoration: none !important;
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  position: relative;
}

.example-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.example-card-bar {
  width: 100%;
  height: 4px;
}

.example-card-name {
  padding: 10px 8px 16px;
  font-size: 11px;
  color: #e0e0e0;
  text-align: center;
  line-height: 1.2;
  letter-spacing: 0.3px;
}

.example-card-badge {
  position: absolute;
  bottom: 4px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 9px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  font-weight: 600;
  opacity: 0.5;
}

.example-card-badge-studio {
  color: #D4AF37;
}

.example-card-badge-artist {
  color: #F472B6;
}

/* Purchase required card */
.purchase-required-card {
  background: var(--bg-tertiary);
  border: 1px solid rgba(245, 158, 11, 0.2);
  border-radius: var(--radius-md);
  padding: 24px;
  text-align: center;
  margin-bottom: 16px;
}

.purchase-required-card h3 {
  font-size: 16px;
  font-weight: 600;
  color: #f59e0b;
  margin: 0 0 8px 0;
}

.purchase-required-card p {
  font-size: 13px;
  color: var(--text-secondary);
  margin: 0 0 16px 0;
  line-height: 1.5;
}

/* Demo mode banner */
.demo-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 99998;
  background: linear-gradient(135deg, #0a0a0b 0%, #1a1a1b 100%);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3);
}

.demo-banner-text {
  color: #a0a0a0 !important;
  font-size: 14px;
}

.demo-banner-text strong {
  color: #fff !important;
}

.demo-banner-cta,
.demo-banner-cta:link,
.demo-banner-cta:visited {
  display: inline-block;
  background: #D4AF37 !important;
  color: #0a0a0b !important;
  padding: 8px 20px;
  border-radius: 8px;
  text-decoration: none !important;
  font-size: 14px;
  font-weight: 600;
  transition: transform 0.2s, box-shadow 0.2s;
}

.demo-banner-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(212, 175, 55, 0.4);
  color: #0a0a0b !important;
}

.demo-banner-close {
  background: none;
  border: none;
  color: #666;
  cursor: pointer;
  padding: 4px 8px;
  font-size: 18px;
  line-height: 1;
}

.demo-banner-close:hover {
  color: #999;
}
