/* ==========================================================================
   AI Image Editor — Modern Dark UI Design System
   Matches Muse.ai production artifact aesthetic
   ========================================================================== */

:root {
  --bg: #0b0d14;
  --surface: #121520;
  --surface-2: #181c2b;
  --surface-3: #1f2436;
  --border: #23283c;
  --border-subtle: #1c2132;
  --text: #f1f5f9;
  --text-muted: #8e99ac;
  --primary: #7c5cff;
  --primary-hover: #9074ff;
  --primary-glow: rgba(124, 92, 255, 0.3);
  --success: #10b981;
  --danger: #ef4444;
  --radius-sm: 6px;
  --radius: 12px;
  --radius-lg: 16px;
  --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

html[data-theme="light"] {
  --bg: #f8fafc;
  --surface: #ffffff;
  --surface-2: #f1f5f9;
  --surface-3: #e2e8f0;
  --border: #cbd5e1;
  --border-subtle: #e2e8f0;
  --text: #0f172a;
  --text-muted: #475569;
  --primary: #6366f1;
  --primary-hover: #4f46e5;
  --primary-glow: rgba(99, 102, 241, 0.2);
}

/* Light Theme Comprehensive Contrast & Polish */
html[data-theme="light"] body {
  background-color: #f8fafc;
  color: #0f172a;
}

html[data-theme="light"] .site-header {
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid #e2e8f0;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

html[data-theme="light"] .logo-wrapper {
  color: #0f172a;
}

html[data-theme="light"] .logo-title {
  color: #0f172a;
}

html[data-theme="light"] .logo-domain {
  color: #64748b;
}

html[data-theme="light"] .main-nav a {
  color: #334155;
}

html[data-theme="light"] .main-nav a:hover,
html[data-theme="light"] .main-nav a.active {
  color: var(--primary);
}

html[data-theme="light"] .nav-dropdown-toggle {
  color: #334155;
}

html[data-theme="light"] .nav-dropdown-menu {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.09);
}

html[data-theme="light"] .nav-dropdown-menu a {
  color: #334155;
}

html[data-theme="light"] .nav-dropdown-menu a:hover {
  background: #f1f5f9;
  color: var(--primary);
}

html[data-theme="light"] .nav-dropdown-divider {
  background: #e2e8f0;
}

html[data-theme="light"] .nav-dropdown-all {
  color: var(--primary) !important;
}

html[data-theme="light"] .theme-pill-btn {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  color: #0f172a;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

html[data-theme="light"] .theme-pill-btn:hover {
  background: #f1f5f9;
  border-color: var(--primary);
}

/* Light Theme Footer */
html[data-theme="light"] .site-footer {
  background: #ffffff;
  border-top: 1px solid #e2e8f0;
}

html[data-theme="light"] .footer-top-block {
  border-bottom: 1px solid #e2e8f0;
}

html[data-theme="light"] .footer-brand-title strong,
html[data-theme="light"] .footer-newsletter-title strong,
html[data-theme="light"] .footer-col h4 {
  color: #0f172a;
}

html[data-theme="light"] .footer-brand-col p,
html[data-theme="light"] .footer-newsletter-col p {
  color: #475569;
}

html[data-theme="light"] .footer-col nav a {
  color: #475569;
}

html[data-theme="light"] .footer-col nav a:hover {
  color: var(--primary);
}

html[data-theme="light"] .newsletter-input-row input {
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  color: #0f172a;
}

html[data-theme="light"] .newsletter-input-row input:focus {
  background: #ffffff;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

html[data-theme="light"] .footer-bottom-copy {
  color: #64748b;
}

/* Light Theme Cards & Blocks */
html[data-theme="light"] .guide-box-item,
html[data-theme="light"] .step-card-box,
html[data-theme="light"] .seo-block-card,
html[data-theme="light"] .tool-box-card,
html[data-theme="light"] .feed-card-box,
html[data-theme="light"] .comparison-box,
html[data-theme="light"] .faq-card-box,
html[data-theme="light"] .prompt-card,
html[data-theme="light"] .editor-banner-box {
  background: #ffffff;
  border-color: #e2e8f0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

/* Light Theme Global Headings Contrast (Eliminate all invisible headings) */
html[data-theme="light"] h1,
html[data-theme="light"] h2,
html[data-theme="light"] h3,
html[data-theme="light"] h4,
html[data-theme="light"] h5,
html[data-theme="light"] h6 {
  color: #0f172a !important;
}

html[data-theme="light"] .guide-box-item h3 a,
html[data-theme="light"] .step-card-box h3,
html[data-theme="light"] .seo-block-card h1,
html[data-theme="light"] .seo-block-card h2,
html[data-theme="light"] .seo-block-card h3,
html[data-theme="light"] .seo-block-card h4,
html[data-theme="light"] .tool-box-card h3,
html[data-theme="light"] .tool-box-card h4,
html[data-theme="light"] .faq-card-box h3,
html[data-theme="light"] .prompt-faq-question,
html[data-theme="light"] .advanced-summary {
  color: #0f172a !important;
}

html[data-theme="light"] .guide-box-item p,
html[data-theme="light"] .step-card-box p,
html[data-theme="light"] .seo-block-card p,
html[data-theme="light"] .seo-block-card ul,
html[data-theme="light"] .seo-block-card ol,
html[data-theme="light"] .seo-block-card li,
html[data-theme="light"] .tool-box-card p,
html[data-theme="light"] .faq-card-box p,
html[data-theme="light"] .prompt-faq-answer,
html[data-theme="light"] .advanced-box p {
  color: #334155 !important;
}

html[data-theme="light"] .seo-block-card strong,
html[data-theme="light"] .step-card-box strong,
html[data-theme="light"] p strong {
  color: #0f172a;
}

html[data-theme="light"] .seo-block-card code {
  background: #f1f5f9;
  color: #0f172a;
  border: 1px solid #cbd5e1;
}

html[data-theme="light"] .seo-block-card blockquote {
  border-left-color: var(--primary);
  background: #f8fafc;
  color: #475569;
}

html[data-theme="light"] .guide-tag-pill {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #334155;
}

/* Prompt Detail Elements Light Mode */
html[data-theme="light"] .prompt-faq-item {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

html[data-theme="light"] .prompt-seo-meta-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}
html[data-theme="light"] .prompt-seo-meta-label {
  color: #64748b;
}
html[data-theme="light"] .prompt-seo-meta-val {
  color: #0f172a;
}

html[data-theme="light"] pre#prompt-text,
html[data-theme="light"] .seo-block-card pre {
  background: #f8fafc !important;
  border: 1px solid #cbd5e1 !important;
  color: #0f172a !important;
}

html[data-theme="light"] .step-card-box {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04);
}
html[data-theme="light"] .step-num-circle {
  background: #6366f1;
  color: #ffffff;
}

html[data-theme="light"] .hero h1 {
  color: #0f172a !important;
}

html[data-theme="light"] .hero-sub {
  color: #475569 !important;
}

html[data-theme="light"] .nav-toggle {
  color: #0f172a;
  border-color: #cbd5e1;
}

/* Auth Gate Modal Light Mode */
html[data-theme="light"] .auth-gate-card {
  background: #ffffff;
  border-color: #e2e8f0;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.15), 0 0 30px rgba(99, 102, 241, 0.12);
}
html[data-theme="light"] .auth-gate-card h3 {
  color: #0f172a;
}
html[data-theme="light"] .auth-gate-card p {
  color: #475569;
}
html[data-theme="light"] .auth-gate-close {
  color: #64748b;
}
html[data-theme="light"] .auth-gate-close:hover {
  color: #0f172a;
}

/* Mobile responsive menu in Light Mode */
@media (max-width: 840px) {
  html[data-theme="light"] .header-panel {
    background: #ffffff;
    border-bottom: 1px solid #e2e8f0;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
  }
}


*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-family);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--primary-hover);
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover {
  text-decoration: underline;
}

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

.font-sm { font-size: 0.85rem; }
.font-xs { font-size: 0.78rem; }
.center-text { text-align: center; }

/* ==========================================================================
   Header Navigation
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(11, 13, 20, 0.94);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

html[data-theme="light"] .site-header {
  background: rgba(255, 255, 255, 0.94);
}

.header-inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.logo-wrapper {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text);
}
.logo-wrapper:hover {
  text-decoration: none;
}

.logo-badge {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, #7c5cff, #9b51e0);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.25rem;
  box-shadow: 0 2px 10px var(--primary-glow);
  flex-shrink: 0;
}

.logo-text {
  display: flex;
  flex-direction: column;
}

.logo-title {
  font-weight: 700;
  font-size: 1.15rem;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.logo-domain {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 400;
  margin-top: 1px;
}

.header-panel {
  display: flex;
  align-items: center;
  gap: 24px;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 20px;
}

.main-nav a {
  color: #cbd5e1;
  font-size: 0.92rem;
  font-weight: 500;
  text-decoration: none;
  padding: 4px 2px;
  transition: color 0.15s ease;
}

html[data-theme="light"] .main-nav a {
  color: #475569;
}

.main-nav a:hover {
  color: var(--primary-hover);
  text-decoration: none;
}

.nav-dropdown {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.nav-dropdown-toggle {
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.nav-dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--surface, #111422);
  border: 1px solid var(--border, rgba(255,255,255,0.12));
  border-radius: 12px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.5);
  padding: 8px;
  min-width: 250px;
  z-index: 1000;
  backdrop-filter: blur(16px);
}

.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.nav-dropdown-menu a {
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 0.88rem;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.nav-dropdown-menu a:hover {
  background: rgba(124, 92, 255, 0.15);
  color: #ffffff;
}

.nav-dropdown-divider {
  height: 1px;
  background: var(--border, rgba(255,255,255,0.08));
  margin: 4px 0;
}

.nav-dropdown-all {
  color: var(--accent, #7c5cff) !important;
  font-weight: 600 !important;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.theme-pill-btn {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s ease;
}
.theme-pill-btn:hover {
  border-color: var(--primary);
  background: var(--surface-3);
}

.nav-link {
  color: #cbd5e1;
  font-size: 0.92rem;
  font-weight: 500;
  text-decoration: none;
}
.nav-link:hover {
  color: #fff;
  text-decoration: none;
}

.btn-get-started {
  background: var(--primary);
  color: #fff;
  border: 1px solid var(--primary);
  border-radius: 8px;
  padding: 8px 18px;
  font-size: 0.92rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
  box-shadow: 0 2px 8px var(--primary-glow);
}
.btn-get-started:hover {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
  text-decoration: none;
  color: #fff;
}

.nav-toggle {
  display: none;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 1.25rem;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
}

/* ==========================================================================
   Buttons & Common UI
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--border);
  cursor: pointer;
  background: var(--surface-2);
  color: var(--text);
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.92rem;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.15s ease;
}

.btn:hover {
  text-decoration: none;
  border-color: var(--primary);
}

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

.btn-primary:hover {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
  color: #fff;
}

.btn-ghost {
  background: transparent;
  border-color: var(--border);
}
.btn-ghost:hover {
  background: var(--surface-2);
  border-color: var(--border);
}

.btn-lg {
  padding: 12px 24px;
  font-size: 1rem;
}

.btn-sm {
  padding: 5px 12px;
  font-size: 0.82rem;
}

.btn-block {
  width: 100%;
}

.btn-link {
  background: none;
  border: none;
  color: var(--primary-hover);
  cursor: pointer;
  padding: 0;
  font-size: 0.82rem;
  font-weight: 500;
  text-decoration: none;
}
.btn-link:hover {
  text-decoration: underline;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */

main {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 20px 80px;
}

.hero {
  text-align: center;
  padding: 48px 16px 28px;
}

.hero h1 {
  font-size: 2.85rem;
  line-height: 1.18;
  margin: 0 0 14px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #ffffff;
}

html[data-theme="light"] .hero h1 {
  color: #0f172a;
}

.hero-sub {
  color: var(--text-muted);
  max-width: 740px;
  margin: 0 auto;
  font-size: 1.05rem;
  line-height: 1.55;
}

/* ==========================================================================
   Two-Column Generator Workspace Layout
   ========================================================================== */

.workspace-grid {
  display: grid;
  grid-template-columns: minmax(360px, 42%) 1fr;
  gap: 28px;
  align-items: start;
  margin-top: 12px;
}

/* --- Left Column: Generator Form Card --- */
.gen-card-left {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.prompt-label-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.prompt-label-row label {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text);
}

.prompt-counter {
  color: var(--text-muted);
  font-size: 0.82rem;
}

.gen-textarea {
  width: 100%;
  background: #0f111a;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 14px;
  font-family: inherit;
  font-size: 0.92rem;
  line-height: 1.45;
  resize: vertical;
  min-height: 125px;
  outline: none;
  transition: border-color 0.15s ease;
}

html[data-theme="light"] .gen-textarea {
  background: #ffffff;
}

.gen-textarea:focus {
  border-color: var(--primary);
}

.prompt-subhint {
  font-size: 0.77rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin: 0;
}

.json-helper-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.btn-json-example {
  align-self: flex-start;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: #cbd5e1;
  border-radius: 6px;
  padding: 5px 12px;
  font-size: 0.82rem;
  cursor: pointer;
}
.btn-json-example:hover {
  border-color: var(--primary);
  color: #fff;
}

/* Reference image box */
.ref-box {
  background: #0f111a;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
html[data-theme="light"] .ref-box {
  background: #f8fafc;
}

.ref-box-title {
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--text);
}

.ref-file-status {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.btn-upload-ref {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 6px;
  padding: 8px 14px;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  transition: all 0.15s ease;
}
.btn-upload-ref:hover {
  border-color: var(--primary);
  background: var(--surface-3);
}

.ref-box-desc {
  font-size: 0.76rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin: 0;
}

/* Sample prompt pills */
.quick-prompt-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 4px 0;
}

.pill-prompt {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: #cbd5e1;
  border-radius: 999px;
  padding: 5px 13px;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.15s ease;
}
html[data-theme="light"] .pill-prompt {
  color: #334155;
}
.pill-prompt:hover {
  border-color: var(--primary);
  color: #fff;
  background: var(--surface-3);
}

/* 2x2 Dropdowns */
.controls-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 4px 0;
}

.control-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.control-item label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #cbd5e1;
}
html[data-theme="light"] .control-item label {
  color: #334155;
}

.control-item select, .control-item input {
  background: #0f111a;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 10px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.85rem;
  outline: none;
}
html[data-theme="light"] .control-item select,
html[data-theme="light"] .control-item input {
  background: #ffffff;
  color: #0f172a;
  border-color: #cbd5e1;
}

.control-item select:focus,
.control-item input:focus {
  border-color: var(--primary);
}

/* Advanced collapsible */
.advanced-box {
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #0f111a;
  padding: 8px 12px;
  font-size: 0.85rem;
}
html[data-theme="light"] .advanced-box {
  background: #f8fafc;
}
.advanced-summary {
  cursor: pointer;
  font-weight: 600;
  color: #cbd5e1;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 6px;
  user-select: none;
}
.advanced-summary::-webkit-details-marker {
  display: none;
}
.advanced-summary::before {
  content: '▸';
  font-size: 0.85rem;
  display: inline-block;
  color: var(--primary);
  transition: transform 0.15s ease;
}
details[open] .advanced-summary::before {
  transform: rotate(90deg);
}
.advanced-content {
  margin-top: 10px;
}
.advanced-content input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 10px;
  color: var(--text);
  font: inherit;
  font-size: 0.85rem;
}

/* Generate Button */
.btn-generate-hero {
  background: linear-gradient(135deg, #7c5cff, #6366f1);
  border: none;
  color: #fff;
  border-radius: 8px;
  padding: 13px 20px;
  font-size: 1.05rem;
  font-weight: 700;
  cursor: pointer;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 16px var(--primary-glow);
  transition: all 0.15s ease;
  margin-top: 4px;
}

.btn-generate-hero:hover {
  background: linear-gradient(135deg, #8f73ff, #7c5cff);
  box-shadow: 0 6px 20px rgba(124, 92, 255, 0.45);
}

.btn-generate-hero:disabled {
  opacity: 0.6;
  cursor: wait;
}

.btn-sub-note {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-align: center;
  margin: 1px 0;
  line-height: 1.35;
}

.gen-status-msg {
  font-size: 0.88rem;
  margin: 4px 0 0;
  text-align: center;
}
.gen-error-msg {
  font-size: 0.88rem;
  color: #ff8589;
  margin: 4px 0 0;
  text-align: center;
}

/* Quality & capacity card */
.capacity-card {
  background: rgba(124, 92, 255, 0.04);
  border: 1px solid rgba(124, 92, 255, 0.18);
  border-radius: 10px;
  padding: 14px 16px;
  margin-top: 8px;
  font-size: 0.8rem;
  line-height: 1.45;
}

.capacity-card h4 {
  margin: 0 0 6px;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text);
}

.capacity-card p {
  margin: 0 0 8px;
  color: var(--text-muted);
}
.capacity-card p:last-child {
  margin-bottom: 0;
}
.capacity-card strong {
  color: var(--text);
}

/* ==========================================================================
   Right Column: Your Creations (15) Panel
   ========================================================================== */

.gen-panel-right {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.creations-title-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.creations-heading {
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0;
  color: var(--text);
}

.creations-count-meta {
  font-size: 0.84rem;
  color: var(--text-muted);
}

.creations-disclaimer {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin: 0;
}

/* Live generation output box */
.gen-live-output {
  background: #0f111a;
  border: 2px dashed var(--primary);
  border-radius: var(--radius);
  padding: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

/* 2-column Creations Cards Grid */
.creations-grid-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.creation-card-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.creation-card-item:hover {
  border-color: #3b4360;
}

.creation-card-img-wrap {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #000;
  overflow: hidden;
}

.creation-card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.creation-card-details {
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.creation-prompt-text {
  font-size: 0.82rem;
  line-height: 1.4;
  color: var(--text);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.creation-prompt-full-text {
  font-size: 0.82rem;
  line-height: 1.4;
  color: var(--text);
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
}

.btn-toggle-prompt {
  align-self: flex-start;
  color: var(--primary-hover);
  background: none;
  border: none;
  padding: 0;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
}
.btn-toggle-prompt:hover {
  text-decoration: underline;
}

.creation-specs-line {
  font-size: 0.74rem;
  color: var(--text-muted);
  line-height: 1.35;
  margin-top: 2px;
}

/* Card action buttons */
.card-btn-rows {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: auto;
  padding-top: 10px;
}

.card-btn-row {
  display: flex;
  gap: 6px;
  width: 100%;
}

.card-btn-row.row-2 > * {
  flex: 1 1 0;
}

.card-btn-row.row-3 > * {
  flex: 1 1 0;
}

.card-btn-row.row-1 > * {
  flex: 0 0 auto;
}

.btn-card-action {
  background: #181c2b;
  border: 1px solid #252b3e;
  color: #cbd5e1;
  border-radius: 6px;
  padding: 6px 8px;
  font-size: 0.76rem;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  transition: all 0.15s ease;
  white-space: nowrap;
}

html[data-theme="light"] .btn-card-action {
  color: #334155;
  background: #f1f5f9;
  border-color: #cbd5e1;
}

.btn-card-action:hover {
  background: #23293d;
  border-color: var(--primary);
  color: #fff;
  text-decoration: none;
}

.btn-show-more-creations {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 8px;
  padding: 10px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  margin-top: 4px;
}
.btn-show-more-creations:hover {
  background: var(--surface-2);
  border-color: var(--primary);
}

/* ==========================================================================
   Featured Studio Banner
   ========================================================================== */

.studio-banner-section {
  margin: 48px 0 32px;
}

.studio-banner-card {
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

.studio-banner-img {
  width: 100%;
  height: auto;
  display: block;
}

.studio-banner-body {
  padding: 24px 16px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 16px;
}

.studio-banner-text {
  font-size: 0.98rem;
  line-height: 1.6;
  color: var(--text-muted);
  max-width: 820px;
  margin: 0 auto;
}

.studio-banner-btns {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
}

/* ==========================================================================
   Latest from Creator Feed (4 Columns Showcase)
   ========================================================================== */

.feed-section-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.feed-section-header h2 {
  font-size: 1.85rem;
  font-weight: 700;
  margin: 0 0 6px;
  color: var(--text);
}

.feed-section-header p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin: 0;
}

.feed-cards-4col {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

figure {
  margin: 0;
}

.feed-item-card {
  margin: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.feed-item-card:hover {
  border-color: #3b4360;
  transform: translateY(-2px);
}

.feed-item-thumb {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #000;
  overflow: hidden;
}

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

.feed-item-content {
  padding: 14px 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.creator-info-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.avatar-badge {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #6366f1;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  flex-shrink: 0;
}

.creator-text-meta strong {
  display: block;
  font-size: 0.9rem;
  color: #ffffff;
  line-height: 1.2;
}

.creator-text-meta span {
  font-size: 0.74rem;
  color: #8b949e;
}

.feed-item-quote {
  font-size: 0.8rem;
  color: #d1d5db;
  line-height: 1.45;
  margin: 4px 0 0;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.feed-item-footer {
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
}

/* ==========================================================================
   AI Tools Ready Today Grid
   ========================================================================== */

.content-section {
  margin-top: 56px;
}

.content-section.wide {
  max-width: none;
}

.content-section h2 {
  font-size: 1.85rem;
  font-weight: 700;
  margin: 0 0 8px;
  color: var(--text);
}

.tools-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 18px;
  margin-top: 20px;
}

.tool-box-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  display: flex;
  flex-direction: column;
}

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

.tool-box-header h3 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
}

.badge-live-tag {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 0.74rem;
  font-weight: 600;
}

.tool-box-subtitle {
  font-size: 0.95rem;
  margin: 0 0 8px;
  color: var(--text);
  font-weight: 600;
}

.tool-box-desc {
  font-size: 0.88rem;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0 0 16px;
  flex: 1;
}

.tool-box-footer {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.84rem;
}

/* ==========================================================================
   Editor Highlight Card
   ========================================================================== */

.editor-banner-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px 24px;
  text-align: center;
  margin-top: 56px;
}

.editor-banner-box h2 {
  margin: 0 0 12px;
  font-size: 1.85rem;
}

.editor-banner-box p {
  max-width: 760px;
  margin: 0 auto 20px;
  color: var(--text-muted);
  font-size: 0.98rem;
  line-height: 1.6;
}

.editor-live-chips {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.chip-live-item {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 5px 16px;
  font-size: 0.85rem;
  color: var(--text);
}

.chip-live-item em {
  color: #10b981;
  font-style: normal;
  font-weight: 600;
  margin-left: 4px;
}

/* ==========================================================================
   Guides & Blog Cards
   ========================================================================== */

.guides-4col {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
  margin-top: 20px;
}

.guide-box-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  display: flex;
  flex-direction: column;
}

.guide-tag-pill {
  align-self: flex-start;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 0.76rem;
  color: var(--text-muted);
}

.guide-box-item h3 {
  margin: 10px 0 8px;
  font-size: 1.08rem;
  line-height: 1.35;
}

.guide-box-item h3 a {
  color: var(--text);
}

.guide-box-item p {
  margin: 0 0 16px;
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.5;
  flex: 1;
}

/* ==========================================================================
   Steps Grid
   ========================================================================== */

.steps-3col {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 20px;
}

.step-card-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

.step-num-circle {
  width: 32px;
  height: 32px;
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  margin-bottom: 12px;
}

.step-card-box h3 {
  margin: 0 0 8px;
  font-size: 1.15rem;
}

.step-card-box p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

/* ==========================================================================
   SEO Copy Blocks
   ========================================================================== */

.seo-block-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  margin-top: 56px;
}

.seo-block-card h2 {
  font-size: 1.85rem;
  margin: 0 0 10px;
}

.seo-lead-text {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-bottom: 28px;
}

.seo-article-part {
  margin-top: 24px;
}

.seo-article-part h3 {
  font-size: 1.2rem;
  margin: 0 0 8px;
  color: var(--text);
}

.seo-article-part p {
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.6;
  margin: 0 0 10px;
}

/* ==========================================================================
   Use Cases Grid
   ========================================================================== */

.usecases-3col {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 18px;
  margin-top: 20px;
}

.usecase-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  display: flex;
  flex-direction: column;
}

.usecase-box h3 {
  margin: 0 0 8px;
  font-size: 1.12rem;
}

.usecase-box p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.5;
  margin: 0 0 14px;
  flex: 1;
}

/* Popular tools */
.tools-quick-directory {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 10px;
  margin: 16px 0;
}

.tool-quick-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 16px;
  display: flex;
  flex-direction: column;
}

.tool-quick-item strong {
  font-size: 0.92rem;
  color: var(--text);
}

.tool-quick-item span {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Prompt layers */
.prompt-layers-5col {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
  margin: 16px 0 24px;
}

.layer-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px;
}

.layer-box strong {
  display: block;
  font-size: 0.92rem;
  color: var(--text);
  margin-bottom: 6px;
}

.layer-box p {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.45;
  margin: 0;
}

.comparison-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.comp-vague-card {
  background: rgba(239, 68, 68, 0.05);
  border: 1px solid rgba(239, 68, 68, 0.25);
  border-radius: var(--radius);
  padding: 22px;
}

.comp-layered-card {
  background: rgba(16, 185, 129, 0.05);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: var(--radius);
  padding: 22px;
}

.badge-vague {
  background: rgba(239, 68, 68, 0.2);
  color: #f87171;
  padding: 3px 12px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
}

.badge-layered {
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
  padding: 3px 12px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
}

.comparison-grid h4 {
  margin: 14px 0 8px;
  font-size: 0.98rem;
}

.comparison-grid p {
  color: var(--text-muted);
  font-size: 0.86rem;
  line-height: 1.5;
  margin: 0;
}

/* Styles grid */
.styles-grid-6col {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.style-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  display: flex;
  flex-direction: column;
}

.style-card h3 {
  margin: 0 0 6px;
  font-size: 1.1rem;
}

.style-card p {
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.5;
  margin: 0 0 14px;
  flex: 1;
}

/* Workflows & Sequences */
.seq-grid-4col {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
  margin-top: 20px;
}

.seq-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  display: flex;
  flex-direction: column;
}

.seq-box h3 {
  margin: 0 0 8px;
  font-size: 1.1rem;
}

.seq-box p {
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.5;
  margin: 0 0 14px;
  flex: 1;
}

.seq-links-col {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.86rem;
}

/* Aspect ratios */
.aspect-grid-6col {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.aspect-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  display: flex;
  flex-direction: column;
}

.aspect-box h3 {
  margin: 0 0 4px;
  font-size: 0.98rem;
}

.aspect-ratio-pill {
  align-self: flex-start;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--primary-hover);
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.78rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.aspect-box p {
  color: var(--text-muted);
  font-size: 0.82rem;
  line-height: 1.45;
  margin: 0 0 12px;
  flex: 1;
}

/* FAQ */
.faq-box-area details {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px 18px;
  margin-bottom: 10px;
  transition: all 0.15s ease;
}

.faq-box-area summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 0.98rem;
  color: var(--text);
  outline: none;
}

.faq-box-area details p {
  margin: 10px 0 0;
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.55;
}

/* CTA */
.hero-cta-banner {
  text-align: center;
  background: linear-gradient(180deg, var(--surface), var(--surface-2));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 56px 24px;
  margin-top: 64px;
}

.hero-cta-banner h2 {
  margin: 0 0 12px;
  font-size: 2.2rem;
  font-weight: 800;
}

.hero-cta-banner p {
  max-width: 640px;
  margin: 0 auto 24px;
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.6;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  margin-top: 64px;
  padding: 48px 20px 32px;
  background: var(--surface);
  transition: background 0.2s ease, border-color 0.2s ease;
}

.footer-top-block {
  max-width: 1320px;
  margin: 0 auto 40px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 36px;
}

.footer-brand-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.footer-newsletter-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 6px;
}

.newsletter-input-row {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.newsletter-input-row input {
  flex: 1;
  max-width: 320px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 14px;
  color: var(--text);
  font: inherit;
  font-size: 0.9rem;
}

.footer-nav-4col {
  max-width: 1320px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}

.footer-col h4 {
  margin: 0 0 14px;
  font-size: 0.95rem;
  color: var(--text);
  font-weight: 700;
}

.footer-col nav {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.footer-col nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.88rem;
}
.footer-col nav a:hover {
  color: var(--text);
}

.footer-bottom-copy {
  text-align: center;
  color: var(--text-muted);
  margin-top: 44px;
  font-size: 0.85rem;
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */

@media (max-width: 1100px) {
  .workspace-grid {
    grid-template-columns: 1fr;
  }
  .feed-cards-4col {
    grid-template-columns: repeat(2, 1fr);
  }
  .studio-banner-body {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 840px) {
  .nav-toggle { display: block; }
  .header-panel {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 16px 20px 24px;
    gap: 16px;
  }
  .header-panel.open { display: flex; }
  .main-nav {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
  .header-actions {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .creations-grid-2col {
    grid-template-columns: 1fr;
  }
  .steps-3col {
    grid-template-columns: 1fr;
  }
  .comparison-grid {
    grid-template-columns: 1fr;
  }
  .footer-top-block {
    grid-template-columns: 1fr;
  }
  .footer-nav-4col {
    grid-template-columns: repeat(2, 1fr);
  }
  .hero h1 {
    font-size: 2.1rem;
  }
}

@media (max-width: 520px) {
  .feed-cards-4col {
    grid-template-columns: 1fr;
  }
  .controls-grid {
    grid-template-columns: 1fr;
  }
  .footer-nav-4col {
    grid-template-columns: 1fr;
  }
}


/* ==========================================================================
   AI Image Editor — Dedicated Admin Console UI
   Matches media_1791635057812_85b98638.png
   ========================================================================== */

.admin-body {
  margin: 0;
  padding: 0;
  background-color: #07090e !important;
  color: #f1f5f9;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  overflow-x: hidden;
}

.admin-shell {
  display: flex;
  min-height: 100vh;
  background-color: #07090e;
}

.admin-sidebar {
  width: 250px;
  flex-shrink: 0;
  background: #0b0d14;
  border-right: 1px solid #1a1e2c;
  height: 100vh;
  position: fixed;
  top: 0;
  left: 0;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  z-index: 100;
  padding: 18px 14px 14px;
}

.admin-logo-box {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 2px 6px 14px;
  border-bottom: 1px solid #1a1e2c;
  margin-bottom: 14px;
}

.admin-logo-spark {
  width: 32px;
  height: 32px;
  background: #6e56cf;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  color: #ffffff;
  flex-shrink: 0;
}

.admin-logo-title {
  display: block;
  font-size: 13.5px;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.2;
}

.admin-logo-sub {
  display: block;
  font-size: 10.5px;
  color: #7e8b9f;
}

.admin-user-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #121520;
  border: 1px solid #1a1e2c;
  border-radius: 8px;
  padding: 8px 10px;
  margin-bottom: 16px;
}

.admin-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #6e56cf;
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  flex-shrink: 0;
}

.admin-online-dot {
  width: 7px;
  height: 7px;
  background: #10b981;
  border: 1.5px solid #0b0d14;
  border-radius: 50%;
  position: absolute;
  bottom: -1px;
  right: -1px;
}

.admin-user-meta {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.admin-user-email {
  font-size: 11.5px;
  font-weight: 600;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.admin-user-status {
  font-size: 10px;
  color: #10b981;
  display: flex;
  align-items: center;
  gap: 4px;
}

.status-dot {
  width: 5px;
  height: 5px;
  background: #10b981;
  border-radius: 50%;
  display: inline-block;
}

.admin-nav-section {
  margin-bottom: 14px;
}

.admin-nav-header {
  font-size: 9.5px;
  font-weight: 700;
  color: #556277;
  letter-spacing: 0.8px;
  margin: 0 10px 5px;
}

.admin-nav-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 6.5px 11px;
  border-radius: 7px;
  color: #9aa7bc;
  font-size: 12.5px;
  text-decoration: none;
  font-weight: 500;
  transition: all 0.15s ease;
  margin-bottom: 2px;
}

.admin-nav-item:hover {
  color: #ffffff;
  background: #141724;
}

.admin-nav-item.active {
  background: #6e56cf;
  color: #ffffff;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(110, 86, 207, 0.35);
}

.admin-nav-item .nav-icon {
  font-size: 13px;
  opacity: 0.9;
  width: 16px;
  text-align: center;
}

.admin-nav-item .nav-badge {
  margin-left: auto;
  background: #1c2132;
  color: #9aa7bc;
  font-size: 10px;
  font-weight: 600;
  padding: 1px 6px;
  border-radius: 10px;
}

.admin-sidebar-footer {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid #1a1e2c;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.admin-footer-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 9px;
  font-size: 11.5px;
  color: #7e8b9f;
  text-decoration: none;
  border-radius: 6px;
  transition: color 0.15s;
}

.admin-footer-link:hover {
  color: #ffffff;
  background: #141724;
}

.admin-main {
  margin-left: 250px;
  flex: 1;
  padding: 24px 32px 60px;
  min-height: 100vh;
  max-width: calc(100vw - 250px);
}

.admin-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
}

.admin-page-title {
  font-size: 22px;
  font-weight: 700;
  color: #ffffff;
  margin: 0;
  line-height: 1.2;
}

.admin-page-sub {
  font-size: 11.5px;
  color: #7e8b9f;
  margin: 3px 0 0;
}

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

.admin-bell-btn {
  width: 32px;
  height: 32px;
  border-radius: 7px;
  background: #121520;
  border: 1px solid #1e2436;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
}

.admin-bell-dot {
  width: 6px;
  height: 6px;
  background: #eab308;
  border-radius: 50%;
  position: absolute;
  top: 6px;
  right: 6px;
}

.admin-top-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 13px;
  background: #121520;
  border: 1px solid #1e2436;
  color: #e2e8f0;
  border-radius: 7px;
  font-size: 11.5px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s;
}

.admin-top-action-btn:hover {
  background: #1c2132;
  color: #ffffff;
}

.admin-metrics-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
  margin-bottom: 12px;
}

.admin-metric-card {
  background: #121520;
  border: 1px solid #1a1e2c;
  border-radius: 10px;
  padding: 13px 15px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 74px;
  position: relative;
}

.admin-metric-val {
  font-size: 21px;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.1;
  margin-bottom: 4px;
}

.admin-metric-label {
  font-size: 11px;
  color: #7e8b9f;
  font-weight: 500;
}

.admin-metric-icon {
  position: absolute;
  top: 13px;
  right: 14px;
  font-size: 13px;
  opacity: 0.55;
  color: #9aa7bc;
}

.admin-shortcuts-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-top: 14px;
  margin-bottom: 26px;
}

.admin-shortcut-card {
  background: #121520;
  border: 1px solid #1a1e2c;
  border-radius: 10px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  transition: transform 0.15s, border-color 0.15s, background 0.15s;
  cursor: pointer;
}

.admin-shortcut-card:hover {
  border-color: #313952;
  background: #151928;
  transform: translateY(-1px);
}

.admin-shortcut-icon {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: #1a1e2d;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  color: #cbd5e1;
  flex-shrink: 0;
}

.admin-shortcut-title {
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  color: #ffffff;
  margin-bottom: 2px;
}

.admin-shortcut-sub {
  display: block;
  font-size: 11px;
  color: #7e8b9f;
}

.admin-columns-layout {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 22px;
  align-items: start;
}

.admin-section-header {
  margin-bottom: 14px;
}

.admin-section-title {
  font-size: 16px;
  font-weight: 700;
  color: #ffffff;
  margin: 0 0 3px;
}

.admin-section-sub {
  font-size: 11px;
  color: #7e8b9f;
  margin: 0;
}

.admin-recent-gens-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.admin-gen-card {
  background: #121520;
  border: 1px solid #1a1e2c;
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.admin-gen-img-wrap {
  width: 100%;
  aspect-ratio: 16 / 11;
  max-height: 235px;
  overflow: hidden;
  background: #0b0d14;
  position: relative;
}

.admin-gen-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.admin-gen-content {
  padding: 12px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.admin-gen-prompt-snippet {
  font-size: 11px;
  color: #cbd5e1;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 5px;
}

.admin-gen-prompt-toggle {
  font-size: 11px;
  color: #7c5cff;
  text-decoration: none;
  cursor: pointer;
  display: inline-block;
  margin-bottom: 7px;
  font-weight: 500;
  border: none;
  background: none;
  padding: 0;
  text-align: left;
}

.admin-gen-prompt-toggle:hover {
  text-decoration: underline;
}

.admin-gen-specs {
  font-size: 10px;
  color: #7e8b9f;
  line-height: 1.4;
  margin-bottom: 10px;
  border-bottom: 1px solid #1a1e2c;
  padding-bottom: 9px;
}

.admin-gen-actions-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5px;
  margin-top: auto;
}

.admin-card-btn {
  background: #181c2b;
  border: 1px solid #23283c;
  color: #cbd5e1;
  border-radius: 6px;
  padding: 5px 6px;
  font-size: 10px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.15s;
}

.admin-card-btn:hover {
  background: #23283c;
  color: #ffffff;
  border-color: #3b4360;
}

.admin-contacts-stack {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin-bottom: 18px;
}

.admin-contact-item {
  background: #101222;
  border: 1px solid #282444;
  border-radius: 9px;
  padding: 11px 13px;
  position: relative;
}

.admin-contact-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
}

.admin-contact-subject {
  font-size: 12px;
  font-weight: 600;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.admin-plan-badge {
  background: #6e56cf;
  color: #ffffff;
  font-size: 9px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 9999px;
  flex-shrink: 0;
}

.admin-contact-meta {
  font-size: 10.5px;
  color: #7e8b9f;
}

.admin-readiness-card {
  background: #121520;
  border: 1px solid #1a1e2c;
  border-radius: 10px;
  padding: 13px 15px;
}

.admin-readiness-title {
  font-size: 12.5px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 6px;
}

.admin-readiness-text {
  font-size: 10.5px;
  color: #7e8b9f;
  line-height: 1.6;
  margin: 0;
}

/* Prompt Modal */
.admin-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.admin-modal-backdrop.open {
  display: flex;
}

.admin-modal-card {
  background: #121520;
  border: 1px solid #282e42;
  border-radius: 12px;
  max-width: 640px;
  width: 100%;
  padding: 24px;
  position: relative;
  box-shadow: 0 10px 40px rgba(0,0,0,0.6);
}

.admin-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  background: none;
  border: none;
  color: #8e9cb2;
  font-size: 20px;
  cursor: pointer;
}

@media (max-width: 1100px) {
  .admin-metrics-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .admin-shortcuts-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .admin-columns-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .admin-sidebar {
    display: none;
  }
  .admin-main {
    margin-left: 0;
    max-width: 100vw;
    padding: 16px;
  }
  .admin-metrics-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .admin-recent-gens-grid {
    grid-template-columns: 1fr;
  }
}


/* ==========================================================================
   WordPress-Style Rich Text Editor & Interactive Admin Components
   ========================================================================== */

.admin-editor-box {
  background: #121520;
  border: 1px solid #1e2436;
  border-radius: 12px;
  overflow: hidden;
  margin-top: 16px;
}

.admin-editor-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  background: #0e101a;
  border-bottom: 1px solid #1e2436;
  padding: 8px 12px;
}

.admin-editor-btn {
  background: transparent;
  border: 1px solid transparent;
  border-radius: 5px;
  color: #cbd5e1;
  font-size: 13px;
  font-weight: 600;
  padding: 5px 9px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  min-width: 28px;
  height: 28px;
}

.admin-editor-btn:hover {
  background: #1e2436;
  color: #ffffff;
  border-color: #2b334d;
}

.admin-editor-btn.active {
  background: #6e56cf;
  color: #ffffff;
}

.admin-editor-select {
  background: #161926;
  border: 1px solid #232a3e;
  border-radius: 5px;
  color: #cbd5e1;
  font-size: 12px;
  padding: 4px 8px;
  cursor: pointer;
  height: 28px;
}

.admin-toolbar-divider {
  width: 1px;
  height: 18px;
  background: #232a3e;
  margin: 0 4px;
}

.admin-editor-canvas {
  min-height: 280px;
  max-height: 520px;
  overflow-y: auto;
  padding: 18px 22px;
  color: #f1f5f9;
  font-size: 15px;
  line-height: 1.7;
  outline: none;
  background: #0b0d14;
}

.admin-editor-canvas:focus {
  background: #0d0f17;
}

.admin-editor-canvas h1, .admin-editor-canvas h2, .admin-editor-canvas h3 {
  color: #ffffff;
  margin: 18px 0 10px;
  line-height: 1.3;
}

.admin-editor-canvas p {
  margin: 0 0 14px;
  color: #cbd5e1;
}

.admin-editor-canvas blockquote {
  border-left: 3px solid #6e56cf;
  margin: 14px 0;
  padding: 8px 16px;
  background: #131627;
  border-radius: 0 8px 8px 0;
  color: #a78bfa;
}

.admin-editor-canvas ul, .admin-editor-canvas ol {
  padding-left: 24px;
  margin: 0 0 14px;
  color: #cbd5e1;
}

.admin-editor-canvas a {
  color: #7c5cff;
  text-decoration: underline;
}

.admin-editor-canvas code {
  background: #1a1e2d;
  color: #f472b6;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 13px;
}

.admin-editor-canvas pre {
  background: #141724;
  padding: 12px 16px;
  border-radius: 8px;
  overflow-x: auto;
  border: 1px solid #1e2436;
}

.admin-editor-html-source {
  width: 100%;
  min-height: 280px;
  padding: 18px 22px;
  background: #090a10;
  color: #4ade80;
  font-family: monospace;
  font-size: 13px;
  border: none;
  outline: none;
  display: none;
  box-sizing: border-box;
  resize: vertical;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
  background: #0c0e14;
  border: 1px solid #1a1e2c;
  border-radius: 10px;
  overflow: hidden;
}

.admin-table th {
  padding: 11px 14px;
  text-align: left;
  border-bottom: 1px solid #1a1e2c;
  color: #8e9cb2;
  font-weight: 600;
  background: #131724;
}

.admin-table td {
  padding: 10px 14px;
  border-bottom: 1px solid #161a27;
  color: #cbd5e1;
  vertical-align: middle;
}

.admin-table tr:hover td {
  background: #111420;
}

.admin-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  border-radius: 7px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.15s;
  text-decoration: none;
}

.admin-btn-primary {
  background: #6e56cf;
  color: #ffffff;
}

.admin-btn-primary:hover {
  background: #7c5cff;
}

.admin-btn-ghost {
  background: #141724;
  color: #cbd5e1;
  border-color: #1e2436;
}

.admin-btn-ghost:hover {
  background: #1c2132;
  color: #ffffff;
}

.admin-btn-danger {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border-color: rgba(239, 68, 68, 0.3);
}

.admin-btn-danger:hover {
  background: #ef4444;
  color: #ffffff;
}

.admin-btn-success {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border-color: rgba(16, 185, 129, 0.3);
}

.admin-btn-success:hover {
  background: #10b981;
  color: #ffffff;
}

.admin-pagination-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 16px;
  padding: 10px 0;
  border-top: 1px solid #1a1e2c;
}

.admin-pagination-btn {
  background: #141724;
  border: 1px solid #1e2436;
  color: #cbd5e1;
  padding: 5px 12px;
  border-radius: 6px;
  font-size: 12px;
  cursor: pointer;
}

.admin-pagination-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.admin-search-input {
  background: #10131f;
  border: 1px solid #1e2436;
  border-radius: 8px;
  padding: 7px 14px;
  color: #ffffff;
  font-size: 12.5px;
  outline: none;
  min-width: 220px;
}

.admin-search-input:focus {
  border-color: #6e56cf;
}

/* ==========================================================================
   Modern Masonry Feed Page (Lexica / Pinterest Style)
   ========================================================================== */
.feed-header-section {
  padding: 32px 0 20px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.feed-controls-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.feed-search-box {
  position: relative;
  flex: 1;
  max-width: 440px;
  min-width: 260px;
}
.feed-search-box input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 11px 20px 11px 42px;
  color: var(--text);
  font-size: 0.94rem;
  outline: none;
  transition: all 0.2s ease;
}
.feed-search-box input:focus {
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.18);
}
.feed-search-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 1rem;
  pointer-events: none;
}
.feed-filter-pills {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  overflow-x: auto;
  padding-bottom: 4px;
}
.feed-pill-btn {
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
  user-select: none;
}
.feed-pill-btn:hover {
  border-color: #6366f1;
  color: var(--text);
}
.feed-pill-btn.active {
  background: #6366f1;
  border-color: #6366f1;
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.35);
}

.feed-masonry {
  column-count: 5;
  column-gap: 16px;
  width: 100%;
  margin: 0 auto 60px;
}
@media (max-width: 1440px) {
  .feed-masonry { column-count: 4; column-gap: 14px; }
}
@media (max-width: 1080px) {
  .feed-masonry { column-count: 3; column-gap: 14px; }
}
@media (max-width: 720px) {
  .feed-masonry { column-count: 2; column-gap: 10px; }
}
@media (max-width: 480px) {
  .feed-masonry { column-count: 1; }
}

.feed-masonry-item {
  break-inside: avoid;
  margin-bottom: 16px;
  background: #0d0f18;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  overflow: hidden;
  position: relative;
  display: block;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.2s ease;
}
.feed-masonry-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.65);
  border-color: rgba(99, 102, 241, 0.45);
}
.feed-masonry-thumb {
  position: relative;
  width: 100%;
  background: #07080d;
}
.feed-masonry-thumb img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  transition: transform 0.35s ease;
}
.feed-masonry-item:hover .feed-masonry-thumb img {
  transform: scale(1.025);
}

.feed-masonry-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(13, 15, 24, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #c7d2fe;
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  z-index: 2;
}

.feed-masonry-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(7, 8, 13, 0.95) 0%, rgba(7, 8, 13, 0.65) 45%, rgba(7, 8, 13, 0.05) 100%);
  opacity: 0;
  transition: opacity 0.22s ease;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 14px;
  pointer-events: none;
  z-index: 3;
}
.feed-masonry-item:hover .feed-masonry-overlay,
.feed-masonry-item:focus-within .feed-masonry-overlay {
  opacity: 1;
  pointer-events: auto;
}

.feed-overlay-prompt {
  color: #f8fafc;
  font-size: 0.83rem;
  line-height: 1.4;
  margin: 0 0 10px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.85);
}

.feed-overlay-actions {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
}
.feed-overlay-actions .btn {
  font-size: 0.76rem;
  padding: 5px 10px;
  border-radius: 6px;
  line-height: 1.2;
}

/* Prompt SEO Details Styling */
.prompt-seo-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin: 18px 0;
}
.prompt-seo-meta-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 14px;
}
.prompt-seo-meta-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  display: block;
  margin-bottom: 4px;
}
.prompt-seo-meta-val {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text);
}
.prompt-faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 16px;
}
.prompt-faq-item {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px 18px;
}
.prompt-faq-question {
  margin: 0 0 8px;
  font-size: 1.02rem;
  font-weight: 600;
  color: #f1f5f9;
}
.prompt-faq-answer {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ==========================================================================
   Dense Feed Grid (Gap-Free, Modern Card Architecture)
   ========================================================================== */
.feed-grid-dense {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  width: 100%;
  margin: 0 auto 60px;
}

.feed-card-dense {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
  position: relative;
}

.feed-card-dense:hover {
  transform: translateY(-4px);
  border-color: #6366f1;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.45);
}

.feed-card-dense-thumb {
  width: 100%;
  aspect-ratio: 4 / 5;
  background: #090a10;
  position: relative;
  overflow: hidden;
}

.feed-card-dense-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
  pointer-events: none;
  -webkit-user-drag: none;
  user-select: none;
}

.feed-card-dense:hover .feed-card-dense-thumb img {
  transform: scale(1.04);
}

.feed-card-dense-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(15, 17, 26, 0.85);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  z-index: 2;
}

.feed-card-dense-body {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 12px;
}

.feed-card-dense-prompt {
  font-size: 0.84rem;
  color: #cbd5e1;
  line-height: 1.5;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}

.feed-card-dense-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: auto;
}

/* ==========================================================================
   Image Right-Click & Drag Protection
   ========================================================================== */
img, .feed-masonry-thumb, .prompt-card-img, .feed-item-thumb, .creation-card-img-wrap, .feed-card-dense-thumb {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-user-drag: none;
  -khtml-user-drag: none;
  -moz-user-drag: none;
  -o-user-drag: none;
  -webkit-touch-callout: none;
}

/* ==========================================================================
   Auth Gate Modal (Copy & Download Gate)
   ========================================================================== */
.auth-gate-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.auth-gate-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(8px);
}

.auth-gate-card {
  position: relative;
  z-index: 2;
  background: #0f121d;
  border: 1px solid rgba(124, 92, 255, 0.35);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.7), 0 0 40px rgba(124, 92, 255, 0.2);
  border-radius: 18px;
  padding: 32px 28px;
  max-width: 440px;
  width: 100%;
  text-align: center;
  animation: authModalPop 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes authModalPop {
  0% { transform: scale(0.92); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

.auth-gate-close {
  position: absolute;
  top: 14px;
  right: 16px;
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 4px;
  line-height: 1;
  transition: color 0.15s ease;
}
.auth-gate-close:hover {
  color: #ffffff;
}

.auth-gate-icon {
  font-size: 2.4rem;
  margin-bottom: 12px;
  display: inline-block;
  background: rgba(124, 92, 255, 0.15);
  width: 64px;
  height: 64px;
  line-height: 64px;
  border-radius: 50%;
  border: 1px solid rgba(124, 92, 255, 0.3);
}

/* ==========================================================================
   Specialized Tool Studio Interfaces (Background Remover, Upscaler, Anime, etc.)
   ========================================================================== */
.studio-custom-shell {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 28px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}
@media (max-width: 960px) {
  .studio-custom-shell {
    grid-template-columns: 1fr;
    padding: 18px;
  }
}

.studio-custom-left {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.studio-custom-right {
  display: flex;
  flex-direction: column;
  gap: 16px;
  background: #090b12;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px;
}

.studio-dropzone {
  border: 2px dashed rgba(124, 92, 255, 0.4);
  background: rgba(124, 92, 255, 0.04);
  border-radius: 14px;
  padding: 32px 20px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}
.studio-dropzone:hover {
  border-color: #7c5cff;
  background: rgba(124, 92, 255, 0.08);
}

.studio-dropzone-icon {
  font-size: 2.2rem;
  margin-bottom: 8px;
  display: block;
}

.studio-preset-pills {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.studio-preset-pill {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  color: var(--text-muted);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 0.84rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease;
}
.studio-preset-pill:hover {
  border-color: #7c5cff;
  color: #ffffff;
}
.studio-preset-pill.active {
  background: #7c5cff;
  border-color: #7c5cff;
  color: #ffffff;
  font-weight: 600;
  box-shadow: 0 2px 10px rgba(124, 92, 255, 0.35);
}

.studio-color-swatches {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.studio-color-swatch {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 2px solid var(--border);
  cursor: pointer;
  transition: all 0.15s ease;
  position: relative;
}
.studio-color-swatch.active {
  border-color: #7c5cff;
  transform: scale(1.1);
  box-shadow: 0 0 10px rgba(124, 92, 255, 0.5);
}

.studio-checker-pattern {
  background-color: #121520;
  background-image: 
    linear-gradient(45deg, #1b2030 25%, transparent 25%), 
    linear-gradient(-45deg, #1b2030 25%, transparent 25%), 
    linear-gradient(45deg, transparent 75%, #1b2030 75%), 
    linear-gradient(-45deg, transparent 75%, #1b2030 75%);
  background-size: 20px 20px;
  background-position: 0 0, 0 10px, 10px -10px, -10px 0px;
}

.studio-preview-box {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  position: relative;
}

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

/* ==========================================================================
   Single Article Layout & Sidebar (Clean Responsive 2-Column Design)
   ========================================================================== */
.article-layout-container {
  max-width: 1240px;
  margin: 16px auto 48px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 32px;
  align-items: start;
  padding: 0 16px;
}

.article-main-content {
  min-width: 0;
}

.article-sidebar {
  position: sticky;
  top: 84px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.sidebar-widget-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 22px 20px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.15);
}

.sidebar-widget-title {
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0 0 14px;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 10px;
}

.sidebar-tool-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 9px;
  text-decoration: none;
  color: var(--text);
  background: var(--surface-2);
  border: 1px solid var(--border-subtle);
  transition: all 0.18s ease;
}

.sidebar-tool-link:hover {
  background: var(--surface-3);
  border-color: var(--primary);
  transform: translateX(3px);
}

.sidebar-article-item {
  display: block;
  text-decoration: none;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--surface-2);
  border: 1px solid var(--border-subtle);
  transition: all 0.18s ease;
}

.sidebar-article-item:hover {
  background: var(--surface-3);
  border-color: var(--primary);
  transform: translateX(3px);
}

.sidebar-article-item strong {
  display: block;
  font-size: 0.88rem;
  line-height: 1.35;
  color: var(--text);
  margin-bottom: 4px;
}

.sidebar-article-item span {
  font-size: 0.76rem;
  color: var(--text-muted);
}

/* Light Mode Overrides for Article & Sidebar */
html[data-theme="light"] .sidebar-widget-card {
  background: #ffffff;
  border-color: #e2e8f0;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.04);
}

html[data-theme="light"] .sidebar-widget-title {
  color: #0f172a;
  border-bottom-color: #e2e8f0;
}

html[data-theme="light"] .sidebar-tool-link,
html[data-theme="light"] .sidebar-article-item {
  background: #f8fafc;
  border-color: #e2e8f0;
  color: #0f172a;
}

html[data-theme="light"] .sidebar-tool-link:hover,
html[data-theme="light"] .sidebar-article-item:hover {
  background: #f1f5f9;
  border-color: var(--primary);
}

html[data-theme="light"] .sidebar-article-item strong {
  color: #0f172a;
}

/* Responsive breakpoint for Mobile & Tablet */
@media (max-width: 960px) {
  .article-layout-container {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 0 12px;
  }
  
  .article-sidebar {
    position: static;
    margin-top: 10px;
  }
}

/* Comments Section Light Mode & Responsiveness */
html[data-theme="light"] .article-comments-section {
  background: #ffffff;
  border-color: #e2e8f0;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
}

html[data-theme="light"] #comments-list > div {
  background: #f8fafc;
  border-color: #e2e8f0;
}

html[data-theme="light"] #comment-form input,
html[data-theme="light"] #comment-form textarea {
  background: #ffffff !important;
  border-color: #cbd5e1 !important;
  color: #0f172a !important;
}

html[data-theme="light"] #comment-form input:focus,
html[data-theme="light"] #comment-form textarea:focus {
  border-color: var(--primary) !important;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12);
}

@media (max-width: 640px) {
  .comment-inputs-row {
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }
  .article-comments-section {
    padding: 20px 16px !important;
  }
}


