/* ==========================================================================
   LenzuraArt Studio - Professional AR Creator Stylesheet
   ========================================================================== */

:root {
  --lenzura-bg: #f8fafc;
  --lenzura-canvas-bg: #bcc2cb;
  --lenzura-sidebar-bg: #ffffff;
  --lenzura-header-bg: #ffffff;
  --lenzura-border: #e2e8f0;
  --lenzura-border-dark: #cbd5e1;
  --lenzura-text-main: #0f172a;
  --lenzura-text-muted: #64748b;
  --lenzura-text-dim: #94a3b8;
  --lenzura-primary: #1e293b;
  --lenzura-primary-hover: #0f172a;
  --lenzura-accent-blue: #3b82f6;
  --lenzura-accent-cyan: #06b6d4;
  --lenzura-accent-gold: #f59e0b;
  --lenzura-accent-green: #10b981;
  --lenzura-banner-blue: #5ba4cf;

  /* Backward compatible aliases */
  --artivive-bg: var(--lenzura-bg);
  --artivive-canvas-bg: var(--lenzura-canvas-bg);
  --artivive-sidebar-bg: var(--lenzura-sidebar-bg);
  --artivive-header-bg: var(--lenzura-header-bg);
  --artivive-border: var(--lenzura-border);
  --artivive-border-dark: var(--lenzura-border-dark);
  --artivive-text-main: var(--lenzura-text-main);
  --artivive-text-muted: var(--lenzura-text-muted);
  --artivive-text-dim: var(--lenzura-text-dim);
  --artivive-primary: var(--lenzura-primary);
  --artivive-primary-hover: var(--lenzura-primary-hover);
  --artivive-accent-blue: var(--lenzura-accent-blue);
  --artivive-accent-cyan: var(--lenzura-accent-cyan);
  --artivive-accent-gold: var(--lenzura-accent-gold);
  --artivive-accent-green: var(--lenzura-accent-green);
  --artivive-banner-blue: var(--lenzura-banner-blue);
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-heading: 'Outfit', 'Inter', sans-serif;
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-full: 9999px;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--font-family);
  background-color: var(--artivive-canvas-bg);
  color: var(--artivive-text-main);
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* --------------------------------------------------------------------------
   Top Announcement Banner
   -------------------------------------------------------------------------- */
#top-announcement-banner {
  background: var(--artivive-banner-blue);
  color: #ffffff;
  padding: 6px 16px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 12.5px;
  font-weight: 500;
  position: relative;
  z-index: 600;
}

.banner-content {
  display: flex;
  align-items: center;
  gap: 10px;
}

.banner-link {
  color: #ffffff;
  text-decoration: underline;
  cursor: pointer;
  font-weight: 600;
}

.banner-close {
  position: absolute;
  right: 14px;
  background: none;
  border: none;
  color: #ffffff;
  cursor: pointer;
  font-size: 14px;
  opacity: 0.8;
}

.banner-close:hover {
  opacity: 1;
}

/* --------------------------------------------------------------------------
   Main App Container
   -------------------------------------------------------------------------- */
#app-container {
  flex: 1;
  display: flex;
  flex-direction: column;
  height: calc(100vh - 32px);
  position: relative;
}

/* --------------------------------------------------------------------------
   Top Navigation Header
   -------------------------------------------------------------------------- */
#main-header {
  height: 52px;
  background: #ffffff;
  border-bottom: 1px solid var(--artivive-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 16px;
  z-index: 50;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-icon-btn {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background: transparent;
  border: none;
  color: var(--artivive-text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  transition: all 0.15s ease;
}

.header-icon-btn:hover {
  background: #f1f5f9;
  color: var(--artivive-text-main);
}

.project-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--artivive-text-main);
}

.breadcrumb-home {
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: var(--radius-sm);
}

.breadcrumb-home:hover {
  background: #f1f5f9;
}

.breadcrumb-separator {
  color: var(--artivive-text-dim);
}

.project-name-display {
  font-weight: 500;
  outline: none;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  border: 1px dashed transparent;
}

.project-name-display:hover, .project-name-display:focus {
  border-color: var(--artivive-border-dark);
  background: #f8fafc;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 14px;
}

/* WebAR Toggle Switch */
.webar-toggle-group {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--artivive-text-main);
  font-weight: 500;
}

.info-tip {
  color: var(--artivive-text-dim);
  cursor: pointer;
}

.toggle-switch {
  position: relative;
  display: inline-block;
  width: 36px;
  height: 20px;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #cbd5e1;
  transition: .25s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: var(--radius-full);
}

.toggle-slider:before {
  position: absolute;
  content: "";
  height: 14px;
  width: 14px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: .25s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

input:checked + .toggle-slider {
  background-color: #1e293b;
}

input:checked + .toggle-slider:before {
  transform: translateX(16px);
}

.toggle-switch.small {
  width: 30px;
  height: 16px;
}

.toggle-switch.small .toggle-slider:before {
  height: 10px;
  width: 10px;
  left: 3px;
  bottom: 3px;
}

.toggle-switch.small input:checked + .toggle-slider:before {
  transform: translateX(14px);
}

/* Action Buttons */
.btn-publish {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #1e293b;
  color: #ffffff;
  border: none;
  padding: 8px 18px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease;
}

.btn-publish:hover {
  background: #0f172a;
}

.btn-discover {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #000000;
  color: #ffffff;
  text-decoration: none;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
}

.btn-discover i {
  color: #10b981;
}

.user-avatar-btn {
  font-size: 22px;
  color: var(--artivive-text-muted);
  cursor: pointer;
}

/* --------------------------------------------------------------------------
   Sub-Header Toolbar
   -------------------------------------------------------------------------- */
#sub-header-toolbar {
  height: 38px;
  background: #ffffff;
  border-bottom: 1px solid var(--artivive-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 16px;
  z-index: 40;
}

.sub-left, .sub-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.tool-btn {
  background: transparent;
  border: none;
  color: var(--artivive-text-muted);
  cursor: pointer;
  font-size: 13px;
  padding: 4px;
  border-radius: 4px;
}

.tool-btn:hover {
  color: var(--artivive-text-main);
  background: #f1f5f9;
}

.tool-btn.active {
  color: var(--artivive-accent-blue);
  background: #eff6ff;
}

.tool-divider {
  width: 1px;
  height: 16px;
  background: var(--artivive-border);
}

.storage-gauge {
  background: #f1f5f9;
  border: 1px solid var(--artivive-border-dark);
  padding: 3px 10px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 600;
  color: var(--artivive-text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-artwork-info {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #ffffff;
  border: 1px solid var(--artivive-border-dark);
  padding: 4px 12px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
  color: var(--artivive-text-main);
  cursor: pointer;
}

.btn-artwork-info:hover {
  background: #f8fafc;
}

/* --------------------------------------------------------------------------
   Editor Body Layout
   -------------------------------------------------------------------------- */
#editor-body {
  flex: 1;
  display: flex;
  position: relative;
  overflow: hidden;
}

/* Left Icon Toolbar */
#left-icon-toolbar {
  width: 60px;
  background: #ffffff;
  border-right: 1px solid var(--artivive-border);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 0;
  gap: 8px;
  z-index: 30;
}

.icon-tool-btn {
  width: 52px;
  height: 52px;
  background: transparent;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  color: var(--artivive-text-muted);
  font-size: 10px;
  font-weight: 600;
  cursor: pointer;
  border-radius: var(--radius-sm);
  transition: all 0.15s ease;
}

.icon-tool-btn i {
  font-size: 18px;
}

.icon-tool-btn:hover {
  background: #f8fafc;
  color: var(--artivive-text-main);
}

.icon-tool-btn.active {
  background: #f1f5f9;
  color: var(--artivive-text-main);
  box-shadow: inset 2px 0 0 #000000;
}

.toolbar-spacer {
  flex: 1;
}

.bug-report-btn {
  background: #000000;
  color: #ffffff;
  border: none;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 8.5px;
  cursor: pointer;
}

.bug-report-btn i {
  font-size: 16px;
  margin-bottom: 2px;
  color: #06b6d4;
}

/* Flyout Drawer */
.flyout-drawer {
  width: 250px;
  background: #ffffff;
  border-right: 1px solid var(--artivive-border);
  display: flex;
  flex-direction: column;
  z-index: 25;
  transition: width 0.2s ease;
  overflow-y: auto;
}

.flyout-drawer.collapsed {
  width: 0;
  border-right: none;
  overflow: hidden;
}

.drawer-panel {
  display: none;
  padding: 16px;
}

.drawer-panel.active {
  display: block;
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.panel-header h3 {
  font-size: 15px;
  font-weight: 700;
  color: var(--artivive-text-main);
}

.btn-close-drawer {
  background: none;
  border: none;
  color: var(--artivive-text-dim);
  cursor: pointer;
  font-size: 14px;
}

.btn-close-drawer:hover {
  color: var(--artivive-text-main);
}

/* Layer Types List */
.layer-types-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.layer-type-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid var(--artivive-border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.15s ease;
}

.layer-type-card:hover {
  border-color: var(--artivive-border-dark);
  background: #f8fafc;
}

.layer-type-card.active {
  border-color: var(--artivive-border-dark);
  background: #f1f5f9;
}

.layer-type-icon {
  font-size: 20px;
  color: var(--artivive-text-muted);
  width: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.layer-type-info h4 {
  font-size: 13px;
  font-weight: 600;
  color: var(--artivive-text-main);
}

.layer-type-info span {
  font-size: 10px;
  color: var(--artivive-text-dim);
  display: block;
  margin-top: 1px;
}

/* Settings Panel Controls */
.layer-summary-card {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 8px;
  border: 1px solid var(--artivive-border);
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
}

.summary-thumb-box {
  position: relative;
  width: 54px;
  height: 38px;
  border-radius: 2px;
  overflow: hidden;
  background: #000;
}

.summary-thumb-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.thumb-edit-btn {
  position: absolute;
  bottom: 2px;
  right: 2px;
  background: rgba(0,0,0,0.6);
  color: #fff;
  border: none;
  border-radius: 2px;
  font-size: 8px;
  padding: 2px;
  cursor: pointer;
}

.summary-details {
  flex: 1;
}

.layer-name-tag {
  display: block;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 130px;
}

.summary-actions {
  display: flex;
  gap: 8px;
}

.summary-actions button {
  background: none;
  border: none;
  color: var(--artivive-text-muted);
  font-size: 13px;
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 2px;
}

.summary-actions button:hover {
  color: var(--artivive-text-main);
  background: #f1f5f9;
}

.summary-actions button#btn-layer-delete:hover {
  color: #ef4444;
  background: #fee2e2;
}

.accordion-group {
  border-bottom: 1px solid var(--artivive-border);
  padding: 10px 0;
}

.accordion-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
}

.accordion-title-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
}

.accordion-header i {
  font-size: 10px;
  color: var(--artivive-text-dim);
  transition: transform 0.2s ease;
}

.accordion-header.active i {
  transform: rotate(180deg);
}

.accordion-body {
  padding-top: 10px;
  display: none;
}

.accordion-header.active + .accordion-body {
  display: block;
}

.stepper-row {
  display: flex;
  gap: 8px;
}

.stepper-input {
  flex: 1;
  display: flex;
  align-items: center;
  background: #f8fafc;
  border: 1px solid var(--artivive-border);
  border-radius: var(--radius-sm);
  padding: 4px 8px;
}

.stepper-label {
  font-size: 11px;
  color: var(--artivive-text-muted);
  margin-right: 6px;
}

.stepper-input input {
  width: 100%;
  border: none;
  background: transparent;
  font-size: 12px;
  outline: none;
  font-weight: 500;
}

.btn-block-action {
  width: 100%;
  padding: 8px;
  background: #ffffff;
  border: 1px solid var(--artivive-border-dark);
  border-radius: var(--radius-sm);
  font-size: 11.5px;
  font-weight: 600;
  color: var(--artivive-text-main);
  cursor: pointer;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.btn-block-action:hover {
  background: #f8fafc;
}

.button-dual-row {
  display: flex;
  gap: 6px;
}

.btn-sub-action {
  flex: 1;
  padding: 6px;
  background: #ffffff;
  border: 1px solid var(--artivive-border);
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 600;
  color: var(--artivive-text-muted);
  cursor: pointer;
}

.btn-sub-action:hover {
  background: #f8fafc;
  color: var(--artivive-text-main);
}

.artivive-select {
  width: 100%;
  padding: 6px 8px;
  border: 1px solid var(--artivive-border);
  border-radius: var(--radius-sm);
  font-size: 12px;
  background: #ffffff;
  outline: none;
}

.artivive-input {
  width: 100%;
  padding: 6px 8px;
  border: 1px solid var(--artivive-border);
  border-radius: var(--radius-sm);
  font-size: 12px;
  outline: none;
}

.switch-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  font-size: 12.5px;
  font-weight: 600;
}

.chroma-details {
  background: #f8fafc;
  border: 1px solid var(--artivive-border);
  border-radius: var(--radius-sm);
  padding: 8px;
  margin-top: 6px;
}

.setting-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11.5px;
  margin-bottom: 8px;
}

.setting-row input[type="color"] {
  border: none;
  background: none;
  width: 24px;
  height: 20px;
  cursor: pointer;
}

.slider-row input[type="range"] {
  width: 100%;
  accent-color: #1e293b;
}

.slider-meta {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--artivive-text-muted);
  margin-bottom: 2px;
}

/* 3D Preset Grid */
.models-preset-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
  margin-bottom: 12px;
}

.model-preset-card {
  border: 1.5px solid var(--artivive-border);
  border-radius: var(--radius-md);
  padding: 14px 10px;
  text-align: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.model-preset-card:hover {
  border-color: var(--artivive-accent-blue);
  background: #f8fafc;
}

.model-preset-card.active {
  border-color: var(--artivive-accent-blue);
  background: #eff6ff;
}

.model-preset-card h4 {
  font-size: 11.5px;
  font-weight: 700;
  margin: 6px 0 2px 0;
}

.model-preset-card span {
  font-size: 9.5px;
  color: var(--artivive-text-muted);
}

/* Elements & Templates Panels (Matching Inspected Artivive Bridge UI) */
.panel-search-box {
  position: relative;
  margin-bottom: 12px;
}

.panel-search-box i {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 12px;
  color: var(--lenzura-text-dim);
}

.panel-search-input {
  width: 100%;
  padding: 8px 12px 8px 30px;
  background: #f8fafc;
  border: 1px solid var(--lenzura-border);
  border-radius: var(--radius-sm);
  font-size: 12px;
  outline: none;
  transition: all 0.15s ease;
}

.panel-search-input:focus {
  background: #ffffff;
  border-color: var(--lenzura-border-dark);
}

.panel-filter-tabs {
  display: flex;
  gap: 12px;
  border-bottom: 1px solid var(--lenzura-border);
  padding-bottom: 6px;
  margin-bottom: 10px;
  overflow-x: auto;
}

.filter-tab {
  font-size: 12px;
  font-weight: 600;
  color: var(--lenzura-text-muted);
  cursor: pointer;
  padding-bottom: 4px;
  border-bottom: 2px solid transparent;
  white-space: nowrap;
}

.filter-tab:hover {
  color: var(--lenzura-text-main);
}

.filter-tab.active {
  color: var(--lenzura-text-main);
  border-bottom-color: var(--lenzura-text-main);
}

.panel-tag-pills {
  display: flex;
  gap: 6px;
  margin-bottom: 14px;
  overflow-x: auto;
}

.tag-pill {
  font-size: 10.5px;
  font-weight: 600;
  padding: 3px 8px;
  background: #f1f5f9;
  border: 1px solid var(--lenzura-border);
  border-radius: var(--radius-full);
  color: var(--lenzura-text-muted);
  cursor: pointer;
  white-space: nowrap;
}

.tag-pill:hover, .tag-pill.active {
  background: #1e293b;
  color: #ffffff;
  border-color: #1e293b;
}

.element-section {
  margin-bottom: 16px;
}

.element-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.element-section-header h4 {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--lenzura-text-main);
}

.element-section-header a {
  font-size: 11px;
  color: var(--lenzura-text-dim);
  text-decoration: none;
  font-weight: 500;
}

.element-section-header a:hover {
  color: var(--lenzura-text-main);
}

.element-cards-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.element-card-item {
  border: 1px solid var(--lenzura-border);
  border-radius: var(--radius-sm);
  padding: 8px;
  background: #f8fafc;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.element-card-item:hover {
  border-color: var(--lenzura-accent-blue);
  background: #ffffff;
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.element-thumb-box {
  width: 100%;
  height: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
  overflow: hidden;
  border-radius: 2px;
}

.element-thumb-box img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.element-thumb-box i {
  font-size: 26px;
  color: var(--lenzura-text-muted);
}

.element-card-item span {
  font-size: 10.5px;
  font-weight: 600;
  color: var(--lenzura-text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 90px;
}

/* Templates Cards */
.template-cards-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.template-card-box {
  border: 1px solid var(--lenzura-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: #ffffff;
  cursor: pointer;
  transition: all 0.15s ease;
}

.template-card-box:hover {
  border-color: var(--lenzura-accent-blue);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.template-card-img {
  width: 100%;
  height: 100px;
  background: #0f172a;
  overflow: hidden;
}

.template-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.template-card-meta {
  padding: 8px 10px;
}

.template-card-meta h4 {
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 2px;
}

.template-card-meta p {
  font-size: 10px;
  color: var(--lenzura-text-muted);
}

/* --------------------------------------------------------------------------
   Main Canvas Stage
   -------------------------------------------------------------------------- */
#canvas-stage {
  flex: 1;
  position: relative;
  background-color: var(--artivive-canvas-bg);
  background-image: 
    linear-gradient(rgba(255, 255, 255, 0.15) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.15) 1px, transparent 1px);
  background-size: 24px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* Top-Left Gizmo Tools */
.canvas-top-left-tools {
  position: absolute;
  top: 14px;
  left: 14px;
  display: flex;
  background: #ffffff;
  border: 1px solid var(--artivive-border-dark);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
  z-index: 20;
}

.gizmo-btn {
  width: 32px;
  height: 32px;
  background: transparent;
  border: none;
  color: var(--artivive-text-muted);
  font-size: 13px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gizmo-btn:hover {
  background: #f1f5f9;
  color: var(--artivive-text-main);
}

.gizmo-btn.active {
  background: #1e293b;
  color: #ffffff;
}

/* Top-Right Artivive-Matching Vertical Layer Stack */
.canvas-top-right-tools {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 25;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.layer-stack-header-row {
  display: flex;
  justify-content: flex-end;
  width: 100%;
}

.layer-stack-expand-btn {
  width: 28px;
  height: 28px;
  background: #ffffff;
  border: 1px solid var(--artivive-border-dark);
  border-radius: 50%;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--artivive-text-muted);
  font-size: 11px;
  transition: all 0.15s ease;
}

.layer-stack-expand-btn:hover {
  background: #f8fafc;
  color: var(--artivive-text-main);
  transform: scale(1.05);
}

.artivive-vertical-layer-stack {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 460px;
  overflow-y: auto;
  padding-right: 2px;
}

.artivive-vertical-layer-stack.collapsed {
  display: none !important;
}

.artivive-layer-card-item {
  background: #ffffff;
  border: 1.5px solid #d1d5db;
  border-radius: 6px;
  width: 190px;
  height: 38px;
  padding: 6px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.artivive-layer-card-item:hover {
  border-color: #94a3b8;
  background: #f8fafc;
}

.artivive-layer-card-item.active {
  border-color: #06b6d4;
  background: #f0fdfa;
  box-shadow: 0 0 0 2px rgba(6, 182, 212, 0.2);
}

.artivive-layer-card-title {
  font-size: 12px;
  font-weight: 600;
  color: #1e293b;
  max-width: 110px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.artivive-layer-card-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.layer-drag-handle {
  color: #94a3b8;
  font-size: 11px;
}

.artivive-layer-card-icon-slot {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.layer-stack-footer-row {
  display: flex;
  justify-content: flex-end;
  width: 100%;
}

.btn-stack-delete-layer {
  width: 28px;
  height: 28px;
  background: #ffffff;
  border: 1px solid var(--artivive-border-dark);
  border-radius: 50%;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #64748b;
  font-size: 12px;
  transition: all 0.15s ease;
}

.btn-stack-delete-layer:hover {
  background: #fee2e2;
  color: #ef4444;
  border-color: #fca5a5;
  transform: scale(1.05);
}

/* Viewport Containers (2D, 3D, Preview) */
#canvas-viewport-container {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.canvas-view {
  display: none;
  width: 100%;
  height: 100%;
}

.canvas-view.active {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* 2D Canvas Target Frame & Transform Box */
.art-target-frame {
  position: relative;
  max-width: 80%;
  max-height: 75%;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.25);
  background: #ffffff;
}

#canvas-target-img {
  display: block;
  max-width: 520px;
  max-height: 400px;
  width: auto;
  height: auto;
}

.canvas-overlay-box {
  position: absolute;
  top: 10%;
  left: 10%;
  width: 80%;
  height: 80%;
  border: 1.5px solid var(--artivive-accent-blue);
  cursor: move;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.15s ease;
}

.canvas-overlay-box.hidden {
  display: none !important;
}

.canvas-overlay-box video, .canvas-overlay-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

/* 3D Model Badge inside 2D View */
.model-3d-badge-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(8px);
  width: 100%;
  height: 100%;
  color: #ffffff;
  text-align: center;
  padding: 16px;
}

.model-3d-icon {
  font-size: 38px;
  color: #06b6d4;
  animation: float-badge 2s infinite ease-in-out;
}

@keyframes float-badge {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.btn-jump-3d {
  background: var(--artivive-accent-blue);
  color: #fff;
  border: none;
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  margin-top: 4px;
}

/* Audio Badge inside 2D View */
.audio-badge-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(8px);
  width: 100%;
  height: 100%;
  color: #ffffff;
  text-align: center;
  padding: 16px;
}

.audio-pulse-icon {
  font-size: 32px;
  color: #a855f7;
}

.audio-waveform-mini {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 20px;
}

.audio-waveform-mini span {
  width: 3px;
  height: 100%;
  background: #a855f7;
  border-radius: 2px;
  animation: wave 1.2s infinite ease-in-out;
}

.audio-waveform-mini span:nth-child(2) { animation-delay: 0.2s; height: 70%; }
.audio-waveform-mini span:nth-child(3) { animation-delay: 0.4s; height: 100%; }
.audio-waveform-mini span:nth-child(4) { animation-delay: 0.1s; height: 60%; }
.audio-waveform-mini span:nth-child(5) { animation-delay: 0.3s; height: 80%; }

@keyframes wave {
  0%, 100% { transform: scaleY(0.3); }
  50% { transform: scaleY(1); }
}

/* Floating Quick Actions Bar */
.floating-quick-bar {
  position: absolute;
  top: -38px;
  left: 50%;
  transform: translateX(-50%);
  background: #ffffff;
  border: 1px solid var(--artivive-border-dark);
  border-radius: var(--radius-sm);
  padding: 4px 6px;
  display: flex;
  gap: 8px;
  box-shadow: var(--shadow-md);
  z-index: 15;
}

.floating-quick-bar button {
  background: none;
  border: none;
  color: var(--artivive-text-muted);
  font-size: 13px;
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 2px;
}

.floating-quick-bar button:hover {
  color: var(--artivive-text-main);
  background: #f1f5f9;
}

.floating-quick-bar button#btn-quick-delete:hover {
  color: #ef4444;
  background: #fee2e2;
}

/* 4 Corner Resize Handles */
.handle {
  position: absolute;
  width: 10px;
  height: 10px;
  background: #ffffff;
  border: 2px solid var(--artivive-accent-blue);
  border-radius: 50%;
}

.handle-tl { top: -6px; left: -6px; cursor: nwse-resize; }
.handle-tr { top: -6px; right: -6px; cursor: nesw-resize; }
.handle-bl { bottom: -6px; left: -6px; cursor: nesw-resize; }
.handle-br { bottom: -6px; right: -6px; cursor: nwse-resize; }

/* Rotation Handle */
.rotate-handle {
  position: absolute;
  bottom: -32px;
  left: 50%;
  transform: translateX(-50%);
  width: 22px;
  height: 22px;
  background: #ffffff;
  border: 1px solid var(--artivive-border-dark);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  color: var(--artivive-text-muted);
  cursor: grab;
  box-shadow: var(--shadow-sm);
}

/* 3D View */
#three-staging-container {
  width: 100%;
  height: 100%;
  cursor: grab;
}

#three-staging-container:active {
  cursor: grabbing;
}

/* Preview View Mockup */
.preview-mockup-frame {
  position: relative;
  width: 320px;
  height: 520px;
  background: #000000;
  border-radius: 36px;
  border: 6px solid #1e293b;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0,0,0,0.4);
}

.phone-notch {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  width: 90px;
  height: 18px;
  background: #1e293b;
  border-radius: 12px;
  z-index: 10;
}

.preview-camera-sim {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, #1e293b 0%, #090d16 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.preview-target-wrapper {
  position: relative;
  width: 240px;
  height: auto;
  box-shadow: 0 10px 30px rgba(0,0,0,0.6);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}

#preview-target-img {
  width: 100%;
  height: auto;
  border-radius: 4px;
  display: block;
}

.preview-overlay-holder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

#preview-video-element {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 4px;
  display: block;
}

#preview-image-element {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 4px;
}

/* Reticle Corner Box in Phone Preview */
.preview-reticle-box {
  position: absolute;
  width: 260px;
  height: 200px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.preview-reticle-corner {
  position: absolute;
  width: 20px;
  height: 20px;
  border: 3px solid #10b981;
}

.preview-reticle-corner.tl { top: 0; left: 0; border-right: none; border-bottom: none; border-top-left-radius: 6px; }
.preview-reticle-corner.tr { top: 0; right: 0; border-left: none; border-bottom: none; border-top-right-radius: 6px; }
.preview-reticle-corner.bl { bottom: 0; left: 0; border-right: none; border-top: none; border-bottom-left-radius: 6px; }
.preview-reticle-corner.br { bottom: 0; right: 0; border-left: none; border-top: none; border-bottom-right-radius: 6px; }

.preview-ar-badge {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  padding: 6px 14px;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(16, 185, 129, 0.4);
  border-radius: var(--radius-full);
  color: #10b981;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
  z-index: 10;
  box-shadow: 0 4px 15px rgba(0,0,0,0.5);
  white-space: nowrap;
}

/* Canvas Bottom-Left: Trigger Pill */
.canvas-bottom-left {
  position: absolute;
  bottom: 16px;
  left: 16px;
  z-index: 20;
}

.trigger-image-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  border: 1px solid var(--artivive-border-dark);
  border-radius: var(--radius-sm);
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
}

.trigger-image-pill img {
  width: 22px;
  height: 22px;
  object-fit: cover;
  border-radius: 2px;
}

/* Canvas Bottom-Center: Mode Switcher */
.canvas-bottom-center {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
}

.mode-switcher-pill {
  display: flex;
  background: #ffffff;
  border: 1px solid var(--artivive-border-dark);
  border-radius: var(--radius-sm);
  padding: 3px;
  gap: 2px;
  box-shadow: var(--shadow-sm);
}

.mode-btn {
  padding: 6px 16px;
  background: transparent;
  border: none;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--artivive-text-muted);
  cursor: pointer;
  border-radius: var(--radius-sm);
}

.mode-btn:hover {
  color: var(--artivive-text-main);
}

.mode-btn.active {
  background: #1e293b;
  color: #ffffff;
}

/* --------------------------------------------------------------------------
   Bottom Timeline Bar
   -------------------------------------------------------------------------- */
#editor-timeline-bar {
  height: 52px;
  background: #ffffff;
  border-top: 1px solid var(--artivive-border);
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 40;
  transition: height 0.25s ease;
}

.timeline-collapse-tag {
  position: absolute;
  top: -24px;
  left: 50%;
  transform: translateX(-50%);
  background: #64748b;
  color: #ffffff;
  padding: 3px 14px;
  border-top-left-radius: 4px;
  border-top-right-radius: 4px;
  font-size: 10.5px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

.timeline-controls-row {
  flex: 1;
  display: flex;
  align-items: center;
  padding: 0 16px;
  gap: 16px;
}

.timeline-help-btn {
  background: none;
  border: none;
  color: var(--artivive-text-dim);
  font-size: 14px;
  cursor: pointer;
}

.playback-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.playback-btn {
  background: none;
  border: none;
  color: var(--artivive-text-main);
  font-size: 13px;
  cursor: pointer;
  padding: 4px;
}

.timeline-timecode {
  font-family: monospace;
  font-size: 12px;
  font-weight: 600;
  color: var(--artivive-text-muted);
  margin-left: 6px;
}

.timeline-track-area {
  flex: 1;
  height: 24px;
  background: #f1f5f9;
  border-radius: var(--radius-sm);
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.timeline-ruler {
  width: 100%;
  height: 100%;
  position: relative;
  background-image: repeating-linear-gradient(90deg, var(--artivive-border) 0px, var(--artivive-border) 1px, transparent 1px, transparent 20px);
}

.timeline-playhead {
  position: absolute;
  top: 0;
  left: 0;
  width: 2px;
  height: 100%;
  background: #ef4444;
}

.timeline-duration {
  font-size: 12px;
  color: var(--artivive-text-dim);
  display: flex;
  gap: 4px;
}

.duration-val {
  font-weight: 600;
  color: var(--artivive-text-muted);
}

/* --------------------------------------------------------------------------
   ARTIVIVE MODAL DIALOGS
   -------------------------------------------------------------------------- */
.artivive-modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 200;
}

.artivive-modal-backdrop.hidden {
  display: none;
}

/* Trigger Image Modal */
.modal-card-trigger {
  width: min(90vw, 440px);
  background: #ffffff;
  border-radius: var(--radius-lg);
  padding: 32px;
  text-align: center;
  box-shadow: var(--shadow-lg);
  position: relative;
}

.modal-card-header h2 {
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 800;
  color: var(--artivive-text-main);
  margin-bottom: 10px;
}

.modal-card-header p {
  font-size: 13px;
  color: var(--artivive-text-muted);
  line-height: 1.5;
  margin-bottom: 24px;
}

.trigger-illustration-box {
  width: 100%;
  height: 180px;
  background: #f8fafc;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  overflow: hidden;
}

.phone-hand-graphic {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 54px;
  color: var(--artivive-primary);
}

.art-flower-icon {
  color: #ec4899;
}

.trigger-upload-dropzone {
  border: 1.5px dashed var(--artivive-border-dark);
  border-radius: var(--radius-md);
  padding: 16px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.trigger-upload-dropzone:hover {
  border-color: #000;
  background: #f8fafc;
}

.supported-types {
  display: block;
  font-size: 12px;
  color: var(--artivive-text-muted);
  margin-bottom: 4px;
}

.drag-text {
  font-size: 11px;
  color: var(--artivive-text-dim);
}

/* Target Trackability Analyzer Box */
.trigger-analysis-box {
  margin-top: 14px;
  padding: 12px 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: var(--radius-md);
  text-align: left;
}

.analysis-stars-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}

.analysis-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--artivive-text-main);
}

.stars-container {
  display: flex;
  gap: 3px;
}

.star-item {
  font-size: 14px;
  color: #cbd5e1;
  transition: color 0.2s ease;
}

.star-item.active {
  color: #f59e0b;
  filter: drop-shadow(0 0 4px rgba(245, 158, 11, 0.4));
}

.score-badge {
  font-size: 11px;
  font-weight: 700;
  background: #ecfdf5;
  color: #059669;
  padding: 2px 8px;
  border-radius: 9999px;
  border: 1px solid #a7f3d0;
}

.analysis-desc {
  font-size: 11px;
  color: var(--artivive-text-muted);
  line-height: 1.4;
  display: flex;
  align-items: flex-start;
  gap: 6px;
  margin: 0;
}

.modal-close-corner {
  position: absolute;
  top: 14px;
  right: 14px;
  background: none;
  border: none;
  color: var(--artivive-text-dim);
  font-size: 16px;
  cursor: pointer;
}

.modal-close-corner:hover {
  color: var(--artivive-text-main);
}

/* Artwork Info Modal */
.modal-card-info {
  width: min(90vw, 440px);
  background: #ffffff;
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-lg);
  position: relative;
}

.modal-info-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.modal-info-header h3 {
  font-size: 17px;
  font-weight: 700;
}

.modal-close-btn {
  background: none;
  border: none;
  font-size: 16px;
  color: var(--artivive-text-dim);
  cursor: pointer;
}

.form-field {
  margin-bottom: 14px;
}

.form-field label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--artivive-text-muted);
  margin-bottom: 4px;
}

.artivive-textarea {
  width: 100%;
  padding: 8px;
  border: 1px solid var(--artivive-border);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 12px;
  outline: none;
}

.trackability-meter-box {
  background: #f8fafc;
  border: 1px solid var(--artivive-border);
  border-radius: var(--radius-sm);
  padding: 10px;
  margin-top: 10px;
}

.meter-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  font-weight: 600;
}

.stars-row i {
  color: #cbd5e1;
  font-size: 12px;
}

.stars-row i.active {
  color: var(--artivive-accent-gold);
}

.meter-note {
  font-size: 11px;
  color: var(--artivive-accent-green);
  margin-top: 4px;
  line-height: 1.3;
}

.modal-info-footer {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 20px;
}

.btn-modal-cancel {
  padding: 8px 14px;
  background: #ffffff;
  border: 1px solid var(--artivive-border-dark);
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}

.btn-modal-save {
  padding: 8px 16px;
  background: #1e293b;
  color: #ffffff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}

/* Dual-Column "Your WebAR Experience is Enabled!" Modal */
.modal-card-publish-exact {
  width: min(94vw, 780px);
  background: #ffffff;
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  position: relative;
}

.publish-exact-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--lenzura-border);
}

.publish-exact-top-row h2 {
  font-size: 20px;
  font-weight: 800;
  color: var(--lenzura-text-main);
  font-family: var(--font-heading);
}

.btn-disable-webar {
  background: #ffffff;
  border: 1px solid #ef4444;
  color: #ef4444;
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-disable-webar:hover {
  background: #fef2f2;
}

.publish-exact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 16px;
}

.publish-qr-card {
  border: 1px solid var(--lenzura-border);
  border-radius: var(--radius-md);
  padding: 16px;
  background: #ffffff;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.publish-qr-card p {
  font-size: 12px;
  color: var(--lenzura-text-muted);
  margin-bottom: 10px;
  line-height: 1.4;
}

.qr-image-wrapper {
  position: relative;
  width: 170px;
  height: 170px;
  background: #ffffff;
  border: 1px solid var(--lenzura-border-dark);
  border-radius: var(--radius-sm);
  padding: 6px;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

#publish-qr-container {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

#publish-qr-container canvas,
#publish-qr-container img {
  width: 154px !important;
  height: 154px !important;
  object-fit: contain;
}

.qr-image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.qr-download-btn {
  position: absolute;
  bottom: 6px;
  right: 6px;
  background: rgba(15, 23, 42, 0.85);
  color: #ffffff;
  border: none;
  border-radius: 4px;
  padding: 4px 6px;
  font-size: 11px;
  cursor: pointer;
}

.url-box-exact {
  width: 100%;
  text-align: left;
  margin-top: 4px;
}

.url-box-exact label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: var(--lenzura-text-muted);
  margin-bottom: 4px;
}

.url-input-action-row {
  display: flex;
  gap: 6px;
}

.url-input-action-row input {
  flex: 1;
  padding: 6px 10px;
  background: #f8fafc;
  border: 1px solid var(--lenzura-border);
  border-radius: var(--radius-sm);
  font-size: 11px;
  outline: none;
}

.btn-copy-exact {
  background: #3b82f6;
  color: #ffffff;
  border: none;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

.publish-target-card {
  border: 1px solid var(--lenzura-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: #000000;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 275px;
}

.publish-target-card img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.publish-footer-banner {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: var(--radius-md);
  padding: 10px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: #166534;
}

.publish-footer-banner .banner-text {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
}

.btn-open-scanner-modal {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #1e293b;
  color: #ffffff;
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-size: 11.5px;
  font-weight: 700;
}

/* "Adding your Artwork" Loading Transition Screen */
#overlay-loading-artwork {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(10, 15, 26, 0.96);
  backdrop-filter: blur(8px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 500;
  color: #ffffff;
  transition: opacity 0.3s ease;
}

#overlay-loading-artwork.hidden {
  opacity: 0;
  pointer-events: none;
  display: none !important;
}

.loading-spinner-arc {
  width: 72px;
  height: 72px;
  border: 4px solid rgba(255, 255, 255, 0.1);
  border-top-color: #ffffff;
  border-radius: 50%;
  animation: spin 0.9s infinite linear;
  margin-bottom: 24px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loading-artwork-title {
  font-family: var(--font-heading);
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.loading-artwork-tip {
  position: absolute;
  bottom: 32px;
  font-size: 13px;
  color: #94a3b8;
  display: flex;
  align-items: center;
  gap: 6px;
  max-width: 500px;
  text-align: center;
  line-height: 1.5;
}

.loading-artwork-tip i {
  color: #06b6d4;
}

.hidden {
  display: none !important;
}

/* ==========================================================================
   Creator Authentication Portal (Login & Signup)
   ========================================================================== */
#studio-auth-overlay {
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at 50% 30%, #1e293b 0%, #090d16 100%);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  backdrop-filter: blur(20px);
}

.auth-card-glass {
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 24px;
  padding: 40px 36px;
  max-width: 440px;
  width: 100%;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.7), 0 0 30px rgba(6, 182, 212, 0.15);
  text-align: center;
  animation: auth-card-pop 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes auth-card-pop {
  0% { transform: scale(0.92) translateY(20px); opacity: 0; }
  100% { transform: scale(1) translateY(0); opacity: 1; }
}

.auth-brand-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}

.auth-brand-logo .logo-boxed-icon {
  background: linear-gradient(135deg, #0284c7, #3b82f6);
  color: #fff;
  font-family: var(--font-heading);
  font-weight: 900;
  font-size: 14px;
  padding: 6px 12px;
  border-radius: 8px;
  letter-spacing: 0.06em;
}

.auth-brand-logo .brand-name-text {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 15px;
  color: #94a3b8;
  letter-spacing: 0.08em;
}

#auth-heading {
  font-family: var(--font-heading);
  font-size: 24px;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 8px;
}

.auth-subtitle {
  color: #94a3b8;
  font-size: 13.5px;
  line-height: 1.5;
  margin-bottom: 24px;
}

.auth-tabs {
  display: flex;
  background: rgba(30, 41, 59, 0.8);
  border-radius: var(--radius-full);
  padding: 4px;
  margin-bottom: 24px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.auth-tab-btn {
  flex: 1;
  padding: 10px 16px;
  border-radius: var(--radius-full);
  border: none;
  background: transparent;
  color: #94a3b8;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 13.5px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.auth-tab-btn.active {
  background: linear-gradient(135deg, #0284c7, #2563eb);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.4);
}

.auth-field {
  text-align: left;
  margin-bottom: 18px;
}

.auth-field label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  color: #cbd5e1;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.auth-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.auth-input-wrap i {
  position: absolute;
  left: 14px;
  color: #64748b;
  font-size: 14px;
}

.auth-input-wrap input {
  width: 100%;
  padding: 12px 14px 12px 38px;
  background: rgba(30, 41, 59, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  color: #ffffff;
  font-family: var(--font-family);
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.auth-input-wrap input:focus {
  border-color: #06b6d4;
  box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.2);
}

.btn-toggle-pw {
  position: absolute;
  right: 12px;
  background: none;
  border: none;
  color: #64748b;
  cursor: pointer;
  font-size: 14px;
  padding: 4px;
}

.btn-toggle-pw:hover {
  color: #cbd5e1;
}

.auth-error-msg {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #f87171;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 12.5px;
  margin-bottom: 18px;
  text-align: left;
}

.btn-auth-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 14px 20px;
  background: linear-gradient(135deg, #0284c7, #2563eb);
  border: none;
  border-radius: 12px;
  color: #ffffff;
  font-family: var(--font-heading);
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 8px 25px rgba(37, 99, 235, 0.4);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  margin-top: 10px;
}

.btn-auth-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(37, 99, 235, 0.6);
}

.auth-credentials-hint {
  margin-top: 20px;
  padding: 10px 12px;
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.25);
  border-radius: 10px;
  font-size: 11.5px;
  color: #38bdf8;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

/* ==========================================================================
   Artist Dashboard & Project Hub (Studio Design System Alignment)
   ========================================================================== */
#studio-projects-dashboard {
  position: fixed;
  inset: 0;
  background: var(--artivive-bg);
  color: var(--artivive-text-main);
  z-index: 500;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.dashboard-navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  height: 56px;
  background: #ffffff;
  border-bottom: 1px solid var(--lenzura-border);
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.dash-nav-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.dash-current-page-title {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 14px;
  color: var(--lenzura-text-main);
}

.dash-nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.dash-nav-right .header-storage-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  background: #f1f5f9;
  border: 1px solid var(--lenzura-border);
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
  color: var(--lenzura-text-muted);
}

.dash-nav-right .header-storage-pill i {
  color: var(--lenzura-text-dim);
  font-size: 11px;
}

.artist-profile-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: #f8fafc;
  border: 1px solid var(--lenzura-border);
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 500;
  color: var(--lenzura-text-main);
}

.artist-profile-badge i {
  color: var(--lenzura-accent-blue);
  font-size: 15px;
}

.btn-dash-new {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  background: var(--lenzura-primary);
  border: none;
  border-radius: var(--radius-full);
  color: #ffffff;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.15);
  transition: all 0.2s ease;
}

.btn-dash-new:hover {
  background: var(--lenzura-primary-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.25);
}

.btn-dash-logout {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: var(--radius-full);
  color: #ef4444;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-dash-logout:hover {
  background: #fee2e2;
  color: #dc2626;
}

.dashboard-main-content {
  max-width: 1280px;
  width: 100%;
  margin: 0 auto;
  padding: 36px 28px;
}

.dash-header-banner {
  margin-bottom: 32px;
}

.dash-title-group h1 {
  font-family: var(--font-heading);
  font-size: 28px;
  font-weight: 800;
  color: var(--lenzura-text-main);
  margin-bottom: 6px;
}

.dash-title-group p {
  color: var(--lenzura-text-muted);
  font-size: 14.5px;
  margin-bottom: 24px;
}

.dash-stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

.stat-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
  background: #ffffff;
  border: 1px solid var(--lenzura-border);
  border-radius: 14px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.stat-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
  border-color: var(--lenzura-border-dark);
}

.stat-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

.stat-icon.published {
  background: #eff6ff;
  color: #2563eb;
}

.stat-icon.views {
  background: #ecfeff;
  color: #0891b2;
}

.stat-icon.likes {
  background: #fdf2f8;
  color: #db2777;
}

.stat-icon.storage {
  background: #f0fdf4;
  color: #16a34a;
}

.stat-info {
  display: flex;
  flex-direction: column;
}

.stat-value {
  font-family: var(--font-heading);
  font-size: 24px;
  font-weight: 800;
  color: var(--lenzura-text-main);
}

.stat-label {
  font-size: 12.5px;
  color: var(--lenzura-text-muted);
  font-weight: 500;
}

.dash-projects-section {
  margin-top: 10px;
}

.section-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.section-title-row h2 {
  font-family: var(--font-heading);
  font-size: 20px;
  font-weight: 800;
  color: var(--lenzura-text-main);
}

.projects-count-tag {
  font-size: 12px;
  font-weight: 600;
  background: #e2e8f0;
  color: #475569;
  padding: 4px 12px;
  border-radius: var(--radius-full);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
}

.project-card {
  background: #ffffff;
  border: 1px solid var(--lenzura-border);
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.project-card:hover {
  transform: translateY(-4px);
  border-color: var(--lenzura-border-dark);
  box-shadow: 0 16px 32px -4px rgba(0, 0, 0, 0.08);
}

.project-thumbnail-box {
  position: relative;
  width: 100%;
  height: 190px;
  background: #f1f5f9;
  overflow: hidden;
}

.project-thumbnail-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.project-card:hover .project-thumbnail-box img {
  transform: scale(1.03);
}

.project-webar-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #059669;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.project-card-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.project-card-title {
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 700;
  color: var(--lenzura-text-main);
  margin-bottom: 4px;
}

.project-card-date {
  font-size: 12.5px;
  color: var(--lenzura-text-muted);
  margin-bottom: 14px;
}

.project-analytics-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 9px 14px;
  background: #f8fafc;
  border: 1px solid var(--lenzura-border);
  border-radius: 10px;
  margin-bottom: 18px;
}

.analytics-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  font-weight: 600;
  color: #334155;
}

.analytics-item i {
  font-size: 13px;
}

.project-card-actions {
  display: flex;
  gap: 8px;
  margin-top: auto;
}

.btn-card-edit {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 14px;
  background: var(--lenzura-primary);
  border: none;
  border-radius: 10px;
  color: #ffffff;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-card-edit:hover {
  background: var(--lenzura-primary-hover);
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.2);
}

.btn-card-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px solid var(--lenzura-border);
  color: var(--lenzura-text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-card-icon:hover {
  background: #f1f5f9;
  color: var(--lenzura-text-main);
  border-color: var(--lenzura-border-dark);
}

.btn-card-icon.delete:hover {
  background: #fef2f2;
  border-color: #fecaca;
  color: #ef4444;
}

/* Dotted Add New Project Card */
.project-card-new {
  border: 2px dashed #cbd5e1;
  background: rgba(255, 255, 255, 0.6);
  border-radius: 16px;
  min-height: 330px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.25s ease;
  text-align: center;
  padding: 24px;
}

.project-card-new:hover {
  border-color: #2563eb;
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(37, 99, 235, 0.08);
  transform: translateY(-4px);
}

.project-card-new .new-icon-circle {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-full);
  background: #eff6ff;
  color: #2563eb;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  transition: transform 0.2s ease;
}

.project-card-new:hover .new-icon-circle {
  transform: scale(1.1);
}

.project-card-new h3 {
  font-family: var(--font-heading);
  font-size: 16px;
  font-weight: 700;
  color: var(--lenzura-text-main);
  margin-bottom: 4px;
}

.project-card-new p {
  font-size: 12.5px;
  color: var(--lenzura-text-muted);
}

