/* AI Affiliate Video Factory — Studio UI/UX Modern Theme */
:root {
  --studio-bg: #0b0f19;
  --studio-sidebar: #0f172a;
  --studio-sidebar-border: #1e293b;
  --studio-content-bg: #f8fafc;
  --studio-card-bg: #ffffff;
  --studio-border: #e2e8f0;
  --studio-border-focus: #3b82f6;
  --studio-primary: #2563eb;
  --studio-primary-hover: #1d4ed8;
  --studio-text-main: #0f172a;
  --studio-text-muted: #64748b;
  --studio-text-subtle: #94a3b8;
  --studio-success: #10b981;
  --studio-warning: #f59e0b;
  --studio-danger: #ef4444;
  --studio-info: #06b6d4;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 10px 25px rgba(0,0,0,0.12);
}

/* App Layout */
body {
  margin: 0;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: var(--studio-text-main);
  background: var(--studio-content-bg);
  min-height: 100vh;
}

.studio-container {
  display: flex;
  min-height: 100vh;
}

/* Sidebar */
.studio-sidebar {
  width: 260px;
  background: var(--studio-sidebar);
  color: #e2e8f0;
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--studio-sidebar-border);
  flex-shrink: 0;
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 100;
  transition: width 0.22s cubic-bezier(0.4, 0, 0.2, 1), transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
}

.sidebar-brand-box {
  padding: 18px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--studio-sidebar-border);
  gap: 8px;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #ffffff;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: -0.02em;
  white-space: nowrap;
  min-width: 0;
}

.brand-text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: opacity 0.15s ease;
}

.brand-badge {
  font-size: 10px;
  background: rgba(37, 99, 235, 0.2);
  color: #60a5fa;
  border: 1px solid rgba(37, 99, 235, 0.4);
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: 700;
  flex-shrink: 0;
  transition: opacity 0.15s ease;
}

.sidebar-collapse-toggle {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #94a3b8;
  border-radius: var(--radius-sm);
  width: 26px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
  padding: 0;
  flex-shrink: 0;
  margin-left: auto;
}

.sidebar-collapse-toggle:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.25);
}

.sidebar-collapse-toggle .toggle-icon {
  transition: transform 0.22s ease;
}

/* Sidebar Status Widget */
.sidebar-status-box {
  margin: 14px 16px;
  background: rgba(30, 41, 59, 0.6);
  border: 1px solid var(--studio-sidebar-border);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.status-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--studio-success);
  box-shadow: 0 0 6px rgba(16, 185, 129, 0.6);
  flex-shrink: 0;
}

.status-dot.offline {
  background: var(--studio-danger);
  box-shadow: 0 0 6px rgba(239, 68, 68, 0.6);
}

.status-meta {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.status-meta-title {
  font-size: 11px;
  color: var(--studio-text-subtle);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.status-meta-name {
  font-size: 12px;
  font-weight: 600;
  color: #f1f5f9;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.status-action-link {
  color: #94a3b8;
  text-decoration: none;
  font-size: 14px;
  padding: 4px 6px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
}

.status-action-link:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}

/* Sidebar Nav */
.sidebar-nav-scroll {
  flex: 1;
  overflow-y: auto;
  padding: 10px 12px;
}

.nav-group-title {
  font-size: 10px;
  font-weight: 700;
  color: #64748b;
  letter-spacing: 0.1em;
  padding: 14px 10px 6px;
  text-transform: uppercase;
}

.sidebar-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  color: #cbd5e1;
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  border-radius: var(--radius-md);
  margin-bottom: 2px;
  transition: all 0.15s ease;
}

.sidebar-nav-item:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #ffffff;
}

.sidebar-nav-item.active {
  background: var(--studio-primary);
  color: #ffffff;
  font-weight: 600;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.3);
}

.sidebar-nav-item .nav-icon {
  font-size: 14px;
  width: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Sidebar Footer */
.sidebar-footer-box {
  padding: 14px 16px;
  border-top: 1px solid var(--studio-sidebar-border);
  font-size: 11px;
  color: #64748b;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

/* Main Content Area */
.studio-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.studio-topbar {
  background: #ffffff;
  border-bottom: 1px solid var(--studio-border);
  padding: 12px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  position: sticky;
  top: 0;
  z-index: 90;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.sidebar-topbar-toggle,
.mobile-menu-btn {
  background: #f8fafc;
  border: 1px solid var(--studio-border);
  color: var(--studio-text-main);
  border-radius: var(--radius-sm);
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
  padding: 0;
  flex-shrink: 0;
}

.sidebar-topbar-toggle:hover,
.mobile-menu-btn:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
  color: var(--studio-primary);
}

.topbar-title {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--studio-text-main);
  margin: 0;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-create-hero {
  background: var(--studio-primary);
  color: #ffffff;
  padding: 8px 16px;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.25);
  transition: all 0.15s ease;
}

.btn-create-hero:hover {
  background: var(--studio-primary-hover);
  transform: translateY(-1px);
}

.studio-body {
  padding: 24px 28px;
  flex: 1;
  max-width: 1440px;
  width: 100%;
  box-sizing: border-box;
}

/* Studio Metric KPI Cards */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.kpi-card {
  background: #ffffff;
  border: 1px solid var(--studio-border);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 8px;
}

.kpi-card .kpi-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--studio-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.kpi-card .kpi-value {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--studio-text-main);
}

.kpi-card .kpi-sub {
  font-size: 12px;
  color: var(--studio-text-subtle);
}

.kpi-card.highlight {
  border-color: #bfdbfe;
  background: linear-gradient(180deg, #f0f7ff 0%, #ffffff 100%);
}

.kpi-card.highlight .kpi-value {
  color: var(--studio-primary);
}

/* GFlow Balance Widget Card */
.gflow-balance-card {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  color: #ffffff;
  border-radius: var(--radius-lg);
  padding: 20px 22px;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  box-shadow: var(--shadow-md);
}

.gflow-balance-info {
  display: flex;
  align-items: center;
  gap: 16px;
}

.gflow-balance-icon {
  font-size: 32px;
  background: rgba(255, 255, 255, 0.1);
  width: 52px;
  height: 52px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gflow-balance-text h3 {
  margin: 0 0 4px;
  font-size: 15px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}

.gflow-balance-text p {
  margin: 0;
  font-size: 12px;
  color: #94a3b8;
}

.gflow-balance-badge {
  font-size: 24px;
  font-weight: 800;
  color: #38bdf8;
  letter-spacing: -0.02em;
}

.gflow-balance-badge small {
  font-size: 12px;
  color: #94a3b8;
  font-weight: 500;
  margin-left: 4px;
}

.gflow-balance-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-gflow-sync {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-md);
  padding: 8px 14px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-gflow-sync:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* Gallery Grid */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 20px;
  margin-top: 18px;
}

.gallery-card {
  background: #ffffff;
  border: 1px solid var(--studio-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: all 0.2s ease;
}

.gallery-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  border-color: #cbd5e1;
}

.gallery-thumb-wrap {
  position: relative;
  width: 100%;
  padding-top: 100%; /* 1:1 preview aspect */
  background: #0f172a;
  overflow: hidden;
  cursor: pointer;
}

.gallery-thumb-wrap img,
.gallery-thumb-wrap video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-thumb-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.gallery-card:hover .gallery-thumb-overlay {
  opacity: 1;
}

.play-icon-circle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: #0f172a;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.gallery-duration-pill {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(15, 23, 42, 0.85);
  color: #ffffff;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.gallery-content {
  padding: 14px 16px;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 10px;
}

.gallery-title-box h4 {
  margin: 0 0 4px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--studio-text-main);
}

.gallery-product-tag {
  font-size: 11px;
  color: var(--studio-primary);
  font-weight: 600;
  text-decoration: none;
}

.gallery-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  color: var(--studio-text-muted);
  border-top: 1px solid #f1f5f9;
  padding-top: 8px;
}

.gallery-actions-row {
  display: flex;
  gap: 8px;
  margin-top: 6px;
}

.btn-gallery-action {
  flex: 1;
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: 1px solid var(--studio-border);
  background: #ffffff;
  color: var(--studio-text-main);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-gallery-action:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.btn-gallery-action.primary {
  background: var(--studio-primary);
  border-color: var(--studio-primary);
  color: #ffffff;
}

.btn-gallery-action.primary:hover {
  background: var(--studio-primary-hover);
}

/* Prompt Manager Editor */
.editor-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 20px;
}

.editor-main-card {
  background: #ffffff;
  border: 1px solid var(--studio-border);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}

.editor-sidebar-card {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.variable-helper-box {
  background: #ffffff;
  border: 1px solid var(--studio-border);
  border-radius: var(--radius-lg);
  padding: 18px;
  box-shadow: var(--shadow-sm);
}

.variable-pills-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.var-pill-btn {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1d4ed8;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-family: monospace;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.var-pill-btn:hover {
  background: #dbeafe;
  border-color: #93c5fd;
  transform: translateY(-1px);
}

.preview-box {
  background: #ffffff;
  border: 1px solid var(--studio-border);
  border-radius: var(--radius-lg);
  padding: 18px;
  box-shadow: var(--shadow-sm);
}

.preview-rendered-text {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: var(--radius-md);
  padding: 14px;
  font-size: 12px;
  line-height: 1.5;
  white-space: pre-wrap;
  max-height: 350px;
  overflow-y: auto;
  color: #334155;
}

/* Video Modal Dialog */
.video-modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.8);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.video-modal-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.video-modal-dialog {
  background: #ffffff;
  border-radius: var(--radius-lg);
  width: 90%;
  max-width: 800px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.video-modal-header {
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--studio-border);
}

.video-modal-header h3 {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
}

.video-modal-close {
  background: transparent;
  border: 0;
  font-size: 20px;
  cursor: pointer;
  color: var(--studio-text-muted);
}

.video-modal-body {
  padding: 20px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.video-player-container {
  width: 100%;
  max-width: 380px; /* 9:16 vertical ratio */
  background: #000000;
  border-radius: var(--radius-md);
  overflow: hidden;
}

.video-player-container video {
  width: 100%;
  display: block;
}

/* Desktop Collapsed Sidebar Mode */
@media (min-width: 769px) {
  .sidebar-collapsed .studio-sidebar,
  .sidebar-is-collapsed .studio-sidebar {
    width: 68px;
  }

  .sidebar-collapsed .sidebar-brand-box,
  .sidebar-is-collapsed .sidebar-brand-box {
    padding: 16px 8px;
    justify-content: center;
  }

  .sidebar-collapsed .sidebar-brand-box .brand-link,
  .sidebar-is-collapsed .sidebar-brand-box .brand-link {
    justify-content: center;
    gap: 0;
  }

  .sidebar-collapsed .sidebar-brand-box .brand-text,
  .sidebar-collapsed .sidebar-brand-box .brand-badge,
  .sidebar-collapsed .sidebar-brand-box .sidebar-collapse-toggle,
  .sidebar-is-collapsed .sidebar-brand-box .brand-text,
  .sidebar-is-collapsed .sidebar-brand-box .brand-badge,
  .sidebar-is-collapsed .sidebar-brand-box .sidebar-collapse-toggle {
    display: none;
  }

  /* Status Box in Collapsed Mode */
  .sidebar-collapsed .sidebar-status-box,
  .sidebar-is-collapsed .sidebar-status-box {
    margin: 10px 8px;
    padding: 10px 0;
    justify-content: center;
  }

  .sidebar-collapsed .sidebar-status-box .status-meta,
  .sidebar-collapsed .sidebar-status-box .status-action-link,
  .sidebar-is-collapsed .sidebar-status-box .status-meta,
  .sidebar-is-collapsed .sidebar-status-box .status-action-link {
    display: none;
  }

  .sidebar-collapsed .status-left,
  .sidebar-is-collapsed .status-left {
    justify-content: center;
  }

  /* Nav Items in Collapsed Mode */
  .sidebar-collapsed .sidebar-nav-scroll,
  .sidebar-is-collapsed .sidebar-nav-scroll {
    padding: 8px 6px;
  }

  .sidebar-collapsed .nav-group-title,
  .sidebar-is-collapsed .nav-group-title {
    height: 1px;
    padding: 0;
    margin: 12px 6px;
    background: rgba(255, 255, 255, 0.08);
    overflow: hidden;
    color: transparent;
  }

  .sidebar-collapsed .sidebar-nav-item,
  .sidebar-is-collapsed .sidebar-nav-item {
    justify-content: center;
    padding: 10px 0;
    gap: 0;
    margin-bottom: 4px;
    border-radius: var(--radius-md);
  }

  .sidebar-collapsed .sidebar-nav-item span:not(.nav-icon),
  .sidebar-is-collapsed .sidebar-nav-item span:not(.nav-icon) {
    display: none;
  }

  .sidebar-collapsed .sidebar-nav-item .nav-icon,
  .sidebar-is-collapsed .sidebar-nav-item .nav-icon {
    font-size: 18px;
    width: auto;
    margin: 0;
  }

  /* Sidebar Footer in Collapsed Mode */
  .sidebar-collapsed .sidebar-footer-box,
  .sidebar-is-collapsed .sidebar-footer-box {
    display: none;
  }
}

/* Mobile Sidebar Backdrop */
.sidebar-backdrop {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(2px);
  z-index: 99;
  opacity: 0;
  transition: opacity 0.25s ease;
}

/* Mobile Sidebar Close Button (hidden on desktop) */
.sidebar-mobile-close {
  display: none;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #e2e8f0;
  border-radius: var(--radius-sm);
  width: 30px;
  height: 30px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  margin-left: auto;
}

/* Product Library Responsive Cards */
.product-library-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 16px;
}

.product-lib-card {
  padding: 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}

.product-lib-top {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  min-width: 0;
}

.product-lib-thumb {
  width: 72px;
  height: 72px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--studio-border);
  background: #f1f5f9;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

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

.product-lib-thumb-empty {
  font-size: 11px;
  color: #64748b;
  text-align: center;
}

.product-lib-info {
  flex: 1;
  min-width: 0;
}

.product-lib-badges {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}

.product-lib-title {
  margin: 0 0 4px;
  font-size: 15px;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.product-lib-title a {
  color: var(--studio-text-main);
  text-decoration: none;
}

.product-lib-title a:hover {
  color: var(--studio-primary);
}

.product-lib-sub {
  font-size: 11px;
  color: var(--studio-text-muted);
  overflow-wrap: anywhere;
}

.product-lib-meta {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 12px;
  color: #475569;
  padding-top: 8px;
  border-top: 1px solid #f1f5f9;
}

.product-lib-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

/* Responsive Breakpoints */
@media (max-width: 1024px) {
  .kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .editor-layout {
    grid-template-columns: 1fr !important;
  }
}

@media (max-width: 768px) {
  html, body {
    overflow-x: hidden;
    max-width: 100%;
  }
  .studio-main {
    overflow-x: hidden;
  }
  .studio-topbar {
    padding: 10px 14px;
    gap: 10px;
  }
  .topbar-left {
    min-width: 0;
    gap: 10px;
  }
  .topbar-title {
    font-size: 15px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .btn-create-hero {
    padding: 8px 12px;
    font-size: 12px;
    white-space: nowrap;
  }
  .studio-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 100;
    transform: translateX(-100%);
    box-shadow: 0 0 25px rgba(0, 0, 0, 0.5);
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  }
  .studio-sidebar.open,
  .studio-sidebar.mobile-open {
    transform: translateX(0);
  }
  .sidebar-backdrop.active {
    display: block;
    opacity: 1;
  }
  .sidebar-collapse-toggle {
    display: none;
  }
  .sidebar-mobile-close {
    display: inline-flex;
  }
  .sidebar-topbar-toggle,
  .mobile-menu-btn {
    display: inline-flex;
  }
  .kpi-grid {
    grid-template-columns: 1fr;
  }
  .gallery-grid,
  .product-library-grid {
    grid-template-columns: 1fr;
  }
  .studio-body {
    padding: 14px;
  }
  .gflow-balance-card {
    flex-direction: column;
    align-items: flex-start;
  }
  .editor-layout,
  .responsive-2col,
  .form-grid,
  .two-col {
    grid-template-columns: 1fr !important;
  }
  .wizard-step-body,
  .wizard-step-desc {
    margin-left: 0 !important;
  }
  .page-heading {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  .page-heading h1 {
    font-size: 24px;
  }
  .button,
  button,
  input,
  select,
  textarea {
    min-height: 38px;
    max-width: 100%;
    box-sizing: border-box;
  }
  .detail-grid {
    grid-template-columns: 1fr 1fr !important;
  }
}

@media (max-width: 480px) {
  .detail-grid {
    grid-template-columns: 1fr !important;
  }
  .studio-body {
    padding: 12px;
  }
  .card,
  .panel,
  .editor-main-card,
  .form-card {
    padding: 14px;
  }
}
