/* Xceler™ - Custom Stylesheet */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800;900&family=JetBrains+Mono:wght@400;500;700&display=swap');

:root {
  --bg-main: #080808;
  --bg-card: #111111;
  --bg-card-hover: #1a1a1a;
  --border-color: rgba(245, 197, 24, 0.08);
  --border-color-strong: rgba(245, 197, 24, 0.15);
  --text-main: #f4f4f5;
  --text-muted: #a1a1aa;
  --text-dark: #71717a;
  
  --primary: #f5c518;
  --primary-glow: rgba(245, 197, 24, 0.15);
  --primary-gradient: linear-gradient(135deg, #f5c518 0%, #f59e0b 100%);
  --accent-cyan: #06b6d4;
  --accent-emerald: #10b981;
  --accent-amber: #f59e0b;
  --accent-rose: #f43f5e;
  
  --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-code: 'JetBrains Mono', 'Courier New', Courier, monospace;
  
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 32px;
  
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -4px rgba(0, 0, 0, 0.3);
  --shadow-glow: 0 0 30px rgba(245, 197, 24, 0.2);
  
  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s ease;
  --transition-slow: 0.4s ease;
}

/* Base Styles */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px; /* Offset for fixed header */
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.02em;
}

a {
  color: inherit;
  text-decoration: none;
}

/* Glassmorphism Classes */
.glass {
  background: rgba(24, 24, 27, 0.75);
  border: 1px solid var(--border-color);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.glass-panel {
  background: rgba(18, 18, 18, 0.6);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-radius: var(--radius-lg);
}

/* Scrollbar styling */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-main);
}
::-webkit-scrollbar-thumb {
  background: var(--border-color-strong);
  border-radius: var(--radius-sm);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--text-dark);
}

/* View Containers */
.view-container {
  display: none;
  min-height: 100vh;
  position: relative;
  overflow: hidden;
}
.view-container.active {
  display: block;
}

/* Navigation / Header */
.header-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2.5rem;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: rgba(9, 9, 11, 0.7);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
}

.logo-container {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.4rem;
  font-weight: 800;
  font-family: var(--font-heading);
}

.logo-badge {
  background: var(--primary-gradient);
  color: white;
  padding: 0.2rem 0.5rem;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 700;
}

.nav-links {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.nav-link {
  color: var(--text-muted);
  font-weight: 500;
  transition: var(--transition-fast);
}

.nav-link:hover {
  color: var(--text-main);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-weight: 600;
  font-family: var(--font-heading);
  padding: 0.6rem 1.2rem;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-primary {
  background: var(--primary-gradient);
  color: #080808;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(245, 197, 24, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(245, 197, 24, 0.45), var(--shadow-glow);
}

.btn-secondary {
  background: transparent;
  border: 1px solid var(--border-color-strong);
  color: var(--text-main);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--text-muted);
}

.btn-outline {
  border: 1px solid var(--primary);
  color: var(--primary);
  background: transparent;
}
.btn-outline:hover {
  background: rgba(245, 197, 24, 0.1);
}

/* ==========================================================================
   VIEW 1: LANDING & PORTAL
   ========================================================================== */
#view-portal {
  position: relative;
  background-color: var(--bg-main);
  padding-top: 8rem;
  padding-bottom: 5rem;
  overflow: visible;
}

/* Pulsing Honeycomb Yellow Hex Grid */
.view-container:not(#view-workspace)::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='56' height='100' viewBox='0 0 56 100'%3E%3Cpath d='M28 66L0 50L0 16L28 0L56 16L56 50L28 66zm0 34L0 84L0 50L28 66L56 50L56 84L28 100z' fill='none' stroke='%23f5c518' stroke-width='1.2' stroke-opacity='0.07'/%3E%3C/svg%3E");
  background-size: 56px 100px;
  background-position: center top;
  pointer-events: none;
  z-index: 1;
  animation: pulse-grid 8s ease-in-out infinite;
}

@keyframes pulse-grid {
  0%, 100% {
    opacity: 0.6;
    filter: drop-shadow(0 0 1px rgba(245, 197, 24, 0.05));
  }
  50% {
    opacity: 1.0;
    filter: drop-shadow(0 0 3px rgba(245, 197, 24, 0.2));
  }
}

/* Dot matrix overlay layer */
.dot-matrix-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: radial-gradient(rgba(255, 255, 255, 0.015) 1.5px, transparent 1.5px);
  background-size: 24px 24px;
  pointer-events: none;
  z-index: 1;
}

/* Floating blurred mesh gradient orbs */
.mesh-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(140px);
  opacity: 0.3;
  pointer-events: none;
  z-index: 0;
  mix-blend-mode: screen;
}

.mesh-glow-1 {
  top: -15%;
  left: 15%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(245, 197, 24, 0.35) 0%, rgba(245, 158, 11, 0.1) 70%, transparent 100%);
  animation: floatMesh1 25s infinite alternate ease-in-out;
}

.mesh-glow-2 {
  top: 25%;
  right: -5%;
  width: 700px;
  height: 700px;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.25) 0%, rgba(217, 119, 6, 0.05) 70%, transparent 100%);
  animation: floatMesh2 30s infinite alternate ease-in-out;
}

.mesh-glow-3 {
  bottom: -15%;
  left: 5%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(245, 197, 24, 0.20) 0%, rgba(254, 240, 138, 0.04) 70%, transparent 100%);
  animation: floatMesh3 22s infinite alternate ease-in-out;
}

@keyframes floatMesh1 {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(60px, 30px) scale(1.1); }
  100% { transform: translate(-30px, 60px) scale(0.95); }
}

@keyframes floatMesh2 {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-80px, 40px) scale(0.9); }
  100% { transform: translate(40px, -30px) scale(1.1); }
}

@keyframes floatMesh3 {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(40px, -60px) scale(1.15); }
  100% { transform: translate(-40px, 20px) scale(0.95); }
}

.hero-section {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 4rem auto;
  padding: 8.5rem 1.5rem 0 1.5rem; /* Pushes content down below fixed header */
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(99, 102, 241, 0.1);
  border: 1px solid rgba(99, 102, 241, 0.2);
  color: #a5b4fc;
  padding: 0.4rem 1rem;
  border-radius: var(--radius-xl);
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 1.5rem;
  animation: pulse 3s infinite alternate;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 1.5rem;
  background: linear-gradient(to right, #ffffff, #a3a3a3);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-title span {
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-desc {
  font-size: 1.25rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 2.5rem auto;
}

/* Prompt Console Widget */
.prompt-console {
  max-width: 780px;
  margin: 0 auto 5rem auto;
  padding: 1.25rem 1.25rem 1rem;
  border-radius: var(--radius-lg);
  position: relative;
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.45);
}

/* Attachment image strip */
.prompt-attachment-strip {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.6rem 0.75rem;
  margin-bottom: 0.75rem;
  background: rgba(99, 102, 241, 0.08);
  border: 1px solid rgba(99, 102, 241, 0.25);
  border-radius: var(--radius-md);
  animation: fadeInDown 0.2s ease;
}

.attachment-preview {
  position: relative;
  width: 48px;
  height: 48px;
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
}

.attachment-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.attachment-remove {
  position: absolute;
  top: -4px;
  right: -4px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: rgba(239, 68, 68, 0.9);
  border: none;
  color: #fff;
  font-size: 9px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

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

/* Main input row */
.prompt-input-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border-color);
  padding: 0.45rem 0.6rem;
  border-radius: var(--radius-md);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.prompt-input-row:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99,102,241,0.15);
}

/* Icon buttons (upload, mic) */
.prompt-icon-btn {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.prompt-icon-btn:hover {
  background: rgba(99,102,241,0.15);
  border-color: var(--primary);
  color: var(--primary-light);
}

.prompt-icon-btn.mic-active {
  background: rgba(239, 68, 68, 0.15);
  border-color: #ef4444;
  color: #ef4444;
  animation: micPulse 1.2s ease-in-out infinite;
}

@keyframes micPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(239,68,68,0.35); }
  50%       { box-shadow: 0 0 0 6px rgba(239,68,68,0); }
}

.prompt-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-main);
  font-size: 1rem;
  padding: 0.45rem 0.25rem;
  font-family: var(--font-body);
  min-width: 0;
}

.prompt-input::placeholder {
  color: var(--text-dark);
}

.prompt-generate-btn {
  flex-shrink: 0;
  white-space: nowrap;
}



.presets-container {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.presets-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  color: var(--text-dark);
  font-weight: 700;
  letter-spacing: 0.05em;
}

.presets-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.preset-btn {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.preset-btn:hover {
  background: rgba(99, 102, 241, 0.08);
  border-color: var(--primary);
  color: var(--text-main);
}

/* Pricing Grid */
.pricing-section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section-title {
  text-align: center;
  font-size: 2.2rem;
  margin-bottom: 3rem;
  font-family: var(--font-heading);
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.pricing-card {
  border-radius: var(--radius-lg);
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: transform var(--transition-normal), border-color var(--transition-normal);
}

.pricing-card:hover {
  transform: translateY(-5px);
  border-color: var(--border-color-strong);
}

.pricing-card.popular {
  border-color: var(--primary);
  background: linear-gradient(180deg, rgba(99, 102, 241, 0.05) 0%, rgba(24, 24, 27, 0.75) 100%);
  box-shadow: 0 10px 30px rgba(99, 102, 241, 0.1);
}

.card-badge {
  position: absolute;
  top: 1rem;
  right: 1.5rem;
  background: var(--primary);
  color: white;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-xl);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.pricing-title {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

.pricing-price {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  font-family: var(--font-heading);
}

.pricing-price span {
  font-size: 1rem;
  color: var(--text-muted);
  font-weight: 400;
}

.pricing-desc {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 2rem;
  min-height: 3rem;
}

.pricing-features {
  list-style: none;
  margin-bottom: 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.pricing-features li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.95rem;
}

.pricing-features li i {
  color: var(--accent-emerald);
}

.pricing-btn {
  margin-top: auto;
  width: 100%;
}

/* Saved Projects Shelf */
.projects-section {
  max-width: 1100px;
  margin: 6rem auto 0 auto;
  padding: 0 1.5rem;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.project-card {
  border-radius: var(--radius-md);
  padding: 1.5rem;
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  z-index: 10;
}

.project-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--text-muted);
  transform: translateY(-2px);
}

.project-info {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.project-icon {
  font-size: 2rem;
}

.project-name {
  font-weight: 700;
  font-size: 1.1rem;
}

.project-type {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ==========================================================================
   VIEW 2: COMPILING GENERATOR TERMINAL
   ========================================================================== */
#view-generator {
  position: relative;
  min-height: 100vh;
  background-color: var(--bg-main);
  padding: 2.5rem;
  overflow: visible;
}

.generator-layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 2rem;
  max-width: 1400px;
  margin: 0 auto;
  height: calc(100vh - 5rem);
}

/* Left panel: Build status checklist */
.build-status-card {
  padding: 2rem;
  display: flex;
  flex-direction: column;
}

.build-app-info {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-color);
}

.build-title-loading {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

.spinner {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255,255,255,0.1);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 1s infinite linear;
}

.build-checklist {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.checklist-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  color: var(--text-dark);
  font-weight: 500;
  transition: color var(--transition-normal);
}

.checklist-item.active {
  color: var(--primary);
}

.checklist-item.complete {
  color: var(--text-main);
}

.checklist-item.complete i {
  color: var(--accent-emerald);
}

.checklist-item i.fa-circle-notch {
  animation: spin 1.5s infinite linear;
}

.agent-avatars {
  display: none !important;
  margin-top: auto;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
}

.agent-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.agent-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.85rem;
}

.agent-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text-dark);
}
.agent-row.active .agent-indicator {
  background: var(--accent-emerald);
  box-shadow: 0 0 10px var(--accent-emerald);
}

/* Right panel: Live Terminal Logs */
.terminal-window {
  background: #050508;
  border: 1px solid #202024;
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,0.8);
}

.terminal-header {
  background: #0e0e11;
  padding: 0.85rem 1.25rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #1a1a20;
}

.terminal-title {
  font-family: var(--font-code);
  font-size: 0.8rem;
  color: var(--text-muted);
}

.terminal-body {
  flex: 1;
  padding: 1.5rem;
  font-family: var(--font-code);
  font-size: 0.9rem;
  color: #38bdf8; /* cyan */
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.log-line {
  line-height: 1.4;
  white-space: pre-wrap;
  word-break: break-all;
}

.log-line.system { color: #f43f5e; }
.log-line.agent-claude { color: #e0f2fe; }
.log-line.agent-gpt { color: #ecfdf5; }
.log-line.success { color: #4ade80; }
.log-line.cmd { color: #fef08a; }

.cursor {
  display: inline-block;
  width: 8px;
  height: 15px;
  background: #38bdf8;
  animation: blink 0.8s infinite;
  vertical-align: middle;
}

/* ==========================================================================
   VIEW 3: BUSINESS WORKSPACE DASHBOARD
   ========================================================================== */
#view-workspace {
  background: #0b0b0f;
}

.workspace-shell {
  display: grid;
  grid-template-rows: 64px 1fr;
  height: 100vh;
}

.workspace-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  background: #0f0f13;
  border-bottom: 1px solid var(--border-color);
}

.workspace-identity {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.workspace-title {
  font-size: 1.2rem;
  font-family: var(--font-heading);
}

.workspace-status-badge {
  background: rgba(16, 185, 129, 0.1);
  color: var(--accent-emerald);
  border: 1px solid rgba(16, 185, 129, 0.2);
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 600;
}

.workspace-tabs {
  display: flex;
  gap: 0.5rem;
}

.tab-btn {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-muted);
  font-size: 0.9rem;
  font-family: var(--font-heading);
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: all var(--transition-fast);
}

.tab-btn:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.05);
}

.tab-btn.active {
  color: var(--primary);
  background: rgba(99, 102, 241, 0.1);
}

.workspace-body {
  display: grid;
  grid-template-columns: 1fr 340px;
  height: calc(100vh - 64px);
  overflow: hidden;
}

.workspace-active-panel-wrapper {
  height: 100%;
  overflow: hidden;
  position: relative;
}

.panel-container {
  display: none;
  height: 100%;
}
.panel-container.active {
  display: block;
}

/* --------------------------------------------------------------------------
   PANEL 1: LANDING PAGE VISUALIZER
   -------------------------------------------------------------------------- */
.landing-panel {
  display: block;
  height: 100%;
}

.landing-preview-frame {
  background: #09090b; /* Match dashboard theme to look unified */
  overflow-y: auto;
  padding: 4rem 2rem;
  color: #0f172a;
  height: 100%;
}

/* Theme Classes for Generated Mockup */
.custom-landing-site.theme-light {
  --l-bg-main: #ffffff;
  --l-bg-sec: #f8fafc;
  --l-bg-card: #ffffff;
  --l-text-main: #0f172a;
  --l-text-muted: #64748b;
  --l-border: #e2e8f0;
  --l-nav-text: #475569;
  --l-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
}

.custom-landing-site.theme-dark {
  --l-bg-main: #09090b;
  --l-bg-sec: #18181b;
  --l-bg-card: rgba(255, 255, 255, 0.03);
  --l-text-main: #f8fafc;
  --l-text-muted: #a1a1aa;
  --l-border: rgba(255, 255, 255, 0.08);
  --l-nav-text: #a1a1aa;
  --l-shadow: none;
}

.custom-landing-site.theme-dark-blue {
  --l-bg-main: #020617;
  --l-bg-sec: #0f172a;
  --l-bg-card: rgba(255, 255, 255, 0.03);
  --l-text-main: #f8fafc;
  --l-text-muted: #94a3b8;
  --l-border: rgba(255, 255, 255, 0.08);
  --l-nav-text: #94a3b8;
  --l-shadow: none;
}

.custom-landing-site.theme-dark-purple {
  --l-bg-main: #0b090f;
  --l-bg-sec: #14101f;
  --l-bg-card: rgba(255, 255, 255, 0.03);
  --l-text-main: #f8fafc;
  --l-text-muted: #b4b0be;
  --l-border: rgba(255, 255, 255, 0.08);
  --l-nav-text: #b4b0be;
  --l-shadow: none;
}

.custom-landing-site {
  max-width: 1000px;
  margin: 0 auto;
  background: var(--l-bg-main);
  border-radius: var(--radius-lg);
  box-shadow: var(--l-shadow);
  overflow: hidden;
  font-family: var(--font-body);
  transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease;
  border: 1px solid var(--l-border);
  color: var(--l-text-main);
}

/* Generated Business Mock Landing CSS context */
.l-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 3rem;
  border-bottom: 1px solid var(--l-border);
  background: var(--l-bg-main);
  transition: background-color 0.3s ease, border-color 0.3s ease;
}
.l-logo {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--l-text-main);
}
.l-hero {
  text-align: center;
  padding: 5.5rem 3rem;
  background: var(--l-hero-glow, radial-gradient(circle at top, rgba(14, 165, 233, 0.04), transparent));
  transition: background 0.3s ease;
}
.l-hero-title {
  font-size: 2.75rem;
  line-height: 1.2;
  font-family: var(--font-heading);
  margin-bottom: 1rem;
  color: var(--l-text-main);
  font-weight: 800;
  letter-spacing: -0.02em;
}
.l-hero-sub {
  color: var(--l-text-muted);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto 2rem auto;
  line-height: 1.6;
  transition: color 0.3s ease;
}
.l-btn {
  padding: 0.75rem 1.75rem;
  background: #0ea5e9;
  color: white;
  font-weight: 600;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
}
.l-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(14, 165, 233, 0.2);
  filter: brightness(1.1);
}
.l-features {
  padding: 5rem 3rem;
  background: var(--l-bg-sec);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  border-top: 1px solid var(--l-border);
  border-bottom: 1px solid var(--l-border);
  transition: background-color 0.3s ease, border-color 0.3s ease;
}
.l-feature-card {
  background: var(--l-bg-card);
  padding: 2.25rem 1.75rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--l-border);
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.25s ease, box-shadow 0.25s ease;
}
.l-feature-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.05);
}
.l-feature-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: #f0f9ff;
  color: #0ea5e9;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  margin-bottom: 1.25rem;
  transition: all 0.2s ease;
}
.l-feature-card:hover .l-feature-icon {
  transform: scale(1.05);
}
.l-feature-title {
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
  color: var(--l-text-main);
  font-weight: 700;
}
.l-feature-desc {
  color: var(--l-text-muted);
  font-size: 0.9rem;
  line-height: 1.5;
  transition: color 0.3s ease;
}
.l-testimonial {
  padding: 5.5rem 3rem;
  text-align: center;
  background: var(--l-bg-main);
  transition: background-color 0.3s ease;
}
.l-testimonial-quote {
  font-size: 1.25rem;
  font-style: italic;
  max-width: 700px;
  margin: 0 auto 1.5rem auto;
  line-height: 1.6;
  color: var(--l-text-main);
}
.l-testimonial-author {
  font-weight: 700;
  color: var(--l-text-main);
}
.l-testimonial-clinic {
  color: var(--l-text-muted);
  font-size: 0.85rem;
  margin-top: 0.25rem;
  transition: color 0.3s ease;
}

/* Landing Customizer Tools Panel */
.landing-customizer-panel {
  background: #0e0e12;
  border-left: 1px solid var(--border-color);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  overflow-y: auto;
  height: 100%;
}

.customizer-header {
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 1rem;
}
.customizer-title {
  font-size: 1.1rem;
}
.customizer-subtitle {
  font-size: 0.8rem;
  color: var(--text-muted);
}
.customizer-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.customizer-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  color: var(--text-dark);
  font-weight: 700;
  letter-spacing: 0.05em;
}
.customizer-input {
  background: var(--bg-main);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 0.6rem 0.85rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  outline: none;
}
.customizer-input:focus {
  border-color: var(--primary);
}

.color-swatch-list {
  display: flex;
  gap: 0.5rem;
}
.swatch-btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  transition: border-color var(--transition-fast);
}
.swatch-btn.active {
  border-color: white;
}

/* --------------------------------------------------------------------------
   PANEL 2: ADMIN WEB DASHBOARD
   ========================================================================== */
.admin-panel {
  padding: 2rem;
  background: #0c0a0f;
  min-height: 100%;
}

.admin-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}

.admin-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.admin-stat-card {
  padding: 1.5rem;
  border-radius: var(--radius-md);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.admin-stat-info {
  display: flex;
  flex-direction: column;
}
.admin-stat-lbl {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}
.admin-stat-val {
  font-size: 1.75rem;
  font-weight: 800;
  font-family: var(--font-heading);
  margin-top: 0.25rem;
}
.admin-stat-icon {
  font-size: 1.75rem;
  opacity: 0.85;
}

.admin-content-layout {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 1.5rem;
}

.admin-table-card {
  padding: 1.5rem;
  border-radius: var(--radius-md);
}

.table-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.admin-table th {
  padding: 0.75rem 1rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  color: var(--text-dark);
  font-weight: 700;
  border-bottom: 1px solid var(--border-color);
}

.admin-table td {
  padding: 0.85rem 1rem;
  font-size: 0.9rem;
  border-bottom: 1px solid var(--border-color);
}

.badge-status {
  padding: 0.15rem 0.5rem;
  font-size: 0.75rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
}
.badge-status.active {
  background: rgba(16, 185, 129, 0.1);
  color: var(--accent-emerald);
}
.badge-status.inactive {
  background: rgba(244, 63, 94, 0.1);
  color: var(--accent-rose);
}

/* --------------------------------------------------------------------------
   PANEL 3: FLUTTER APP MOBILE SIMULATOR
   ========================================================================== */
.simulator-panel {
  display: flex;
  height: 100%;
}

.simulator-viewer {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  background: #0d0c11;
  padding: 2rem;
}

/* iPhone Device Shell */
.phone-device {
  width: 375px;
  height: 760px;
  background: #000;
  border: 12px solid #27272a;
  border-radius: 48px;
  position: relative;
  box-shadow: 0 25px 50px -12px rgba(0,0,0,0.8);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.phone-island {
  position: absolute;
  top: 15px;
  left: 50%;
  transform: translateX(-50%);
  width: 110px;
  height: 25px;
  background: #000;
  border-radius: 20px;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
}

.phone-island::after {
  content: "";
  width: 8px;
  height: 8px;
  background: #0f172a;
  border-radius: 50%;
  position: absolute;
  right: 15px;
}

.phone-screen {
  flex: 1;
  background: #ffffff;
  color: #0f172a;
  display: flex;
  flex-direction: column;
  margin-top: 5px;
  overflow: hidden;
  border-radius: 36px;
  position: relative;
}

.phone-appbar {
  background: #0ea5e9;
  color: white;
  padding: 2.2rem 1rem 0.85rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.phone-appbar-title {
  font-weight: 700;
  font-size: 1.15rem;
}
.phone-content {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
}
.phone-bottom-bar {
  height: 60px;
  border-top: 1px solid #e2e8f0;
  display: flex;
  justify-content: space-around;
  align-items: center;
  background: #f8fafc;
}
.phone-tab-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size: 0.7rem;
  color: #64748b;
  cursor: pointer;
}
.phone-tab-btn.active {
  color: #0ea5e9;
}
.phone-tab-btn i {
  font-size: 1.2rem;
  margin-bottom: 0.15rem;
}

/* Flutter Code Inspector */
.simulator-code-inspector {
  width: 50%;
  background: #0f0f13;
  border-left: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.code-inspector-header {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--border-color);
  background: #15151a;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.code-file-tabs {
  display: flex;
  gap: 0.5rem;
}

.code-tab {
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 0.8rem;
  font-family: var(--font-code);
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
}
.code-tab.active {
  background: rgba(99, 102, 241, 0.1);
  color: var(--primary);
  border-color: rgba(99, 102, 241, 0.3);
}

.code-viewer-body {
  flex: 1;
  padding: 1.5rem;
  overflow-y: auto;
  font-family: var(--font-code);
  font-size: 0.85rem;
  line-height: 1.5;
  color: #e2e8f0;
  background: #09090b;
}

/* --------------------------------------------------------------------------
   PANEL 4: DATABASE SCHEMA EXPLORER
   ========================================================================== */
.schema-panel {
  display: grid;
  grid-template-columns: 1fr 360px;
  height: 100%;
}

.schema-canvas {
  background: radial-gradient(circle, rgba(255,255,255,0.01) 1px, transparent 1px);
  background-size: 20px 20px;
  padding: 3rem;
  overflow: auto;
  display: flex;
  gap: 3rem;
  align-items: flex-start;
}

.schema-node {
  width: 280px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.node-header {
  background: var(--primary);
  padding: 0.75rem 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.node-title {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.95rem;
}
.node-body {
  background: var(--bg-card);
  padding: 0.5rem 0;
}
.node-field {
  padding: 0.4rem 1rem;
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  font-family: var(--font-code);
  border-bottom: 1px solid rgba(255, 255, 255, 0.02);
}
.node-field-name {
  color: var(--text-main);
}
.node-field-type {
  color: var(--text-muted);
}
.node-field.pk .node-field-name::before {
  content: "🔑 ";
}

.schema-sql-panel {
  background: #0f0f13;
  border-left: 1px solid var(--border-color);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* --------------------------------------------------------------------------
   PANELS 5 & 6: SPECIFICATIONS, LEGAL & STORE
   ========================================================================== */
.doc-panel {
  max-width: 800px;
  margin: 0 auto;
  padding: 4rem 2rem;
  line-height: 1.6;
}

.doc-panel h1, .doc-panel h2, .doc-panel h3 {
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
  color: var(--text-main);
}
.doc-panel h1 { font-size: 2.25rem; }
.doc-panel h2 { font-size: 1.5rem; border-bottom: 1px solid var(--border-color); padding-bottom: 0.5rem; }
.doc-panel h3 { font-size: 1.15rem; }

.doc-panel p, .doc-panel ul {
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}
.doc-panel ul {
  padding-left: 1.5rem;
}

/* Store Preview */
.store-preview-card {
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  max-width: 720px;
  margin: 0 auto;
  margin-bottom: 3rem;
}

.store-meta-grid {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.store-app-icon {
  width: 100px;
  height: 100px;
  background: var(--primary-gradient);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
}

.store-info-box {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.store-title {
  font-size: 1.8rem;
  line-height: 1.2;
}

.store-subtitle {
  color: var(--text-muted);
  font-size: 1rem;
}

.store-badge-row {
  display: flex;
  gap: 1rem;
  margin-top: 0.5rem;
}

.store-badge {
  background: rgba(255,255,255,0.05);
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  color: var(--text-muted);
}

.store-details {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.store-detail-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

/* ==========================================================================
   ANIMATIONS
   ========================================================================== */
@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

@keyframes pulse {
  0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.4); }
  70% { transform: scale(1.02); box-shadow: 0 0 0 10px rgba(99, 102, 241, 0); }
  100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(99, 102, 241, 0); }
}

/* Toast Notification Styles */
#toast-container {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  z-index: 1000;
}

.toast {
  background: #18181b;
  border: 1px solid var(--border-color-strong);
  color: var(--text-main);
  padding: 1rem 1.5rem;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 280px;
  animation: slideIn 0.25s forwards;
}

@keyframes slideIn {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* AI Copilot Chat Styles */
.chat-msg {
  margin-bottom: 0.5rem;
  line-height: 1.4;
  word-wrap: break-word;
}
.chat-msg.user {
  background: rgba(99, 102, 241, 0.1);
  padding: 0.6rem 0.85rem;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  align-self: flex-end;
  border-right: 3px solid var(--primary);
  max-width: 90%;
}
.chat-msg.bot {
  align-self: flex-start;
  max-width: 90%;
  animation: fadeIn 0.2s ease-in-out;
}
.suggested-prompt-btn:hover {
  background: rgba(99, 102, 241, 0.1) !important;
  border-color: var(--primary) !important;
  color: var(--text-main) !important;
}
.btn-xs {
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
  border-radius: var(--radius-sm);
}

/* Modal Overlay & Styling */
.modal-overlay {
  animation: modalFadeIn 0.3s ease-out;
}

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

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

/* ==========================================================================
   User Auth Modal & Header State Styling
   ========================================================================== */

.auth-tab-btn:not(.active-tab):hover {
  color: var(--text-main) !important;
  background: rgba(255, 255, 255, 0.04) !important;
}

/* Profile Menu */
.profile-menu-container {
  position: relative;
  display: inline-block;
}

.profile-badge-btn {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  padding: 0.38rem 0.85rem;
  border-radius: 9999px;
  color: var(--text-main);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  outline: none;
}

.profile-badge-btn:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--border-color-strong);
}

.profile-avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--primary-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

.profile-dropdown {
  position: absolute;
  top: calc(100% + 0.6rem);
  right: 0;
  width: 220px;
  background: rgba(10, 10, 15, 0.95);
  border: 1px solid var(--border-color-strong);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: 0.75rem;
  display: none;
  flex-direction: column;
  gap: 0.4rem;
  z-index: 1000;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  animation: fadeIn 0.15s ease-out;
}

.profile-dropdown.active {
  display: flex;
}

.dropdown-header {
  padding-bottom: 0.5rem;
  margin-bottom: 0.25rem;
  border-bottom: 1px solid var(--border-color);
}

.dropdown-name {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dropdown-email {
  font-size: 0.7rem;
  color: var(--text-dark);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dropdown-plan-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.65rem;
  background: rgba(16, 185, 129, 0.1);
  color: var(--accent-emerald);
  padding: 0.12rem 0.45rem;
  border-radius: 9999px;
  font-weight: 700;
  margin-top: 0.35rem;
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.6rem;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-size: 0.78rem;
  cursor: pointer;
  transition: all 0.2s;
  background: transparent;
  border: none;
  width: 100%;
  text-align: left;
}

.dropdown-item:hover {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-main);
}

.dropdown-item.logout {
  border-top: 1px solid var(--border-color);
  padding-top: 0.6rem;
  margin-top: 0.2rem;
  color: #f43f5e;
}

.dropdown-item.logout:hover {
  background: rgba(244, 63, 94, 0.08);
  color: #f43f5e;
}

/* Mobile Responsive Overrides */
@media (max-width: 768px) {
  .header-nav {
    padding: 0.75rem 1rem !important;
  }
  .nav-links {
    gap: 0.75rem !important;
  }
  #nav-link-features,
  #nav-link-pricing,
  #btn-cta-nav {
    display: none !important;
  }
  #nav-link-projects {
    font-size: 0.85rem !important;
  }
  .profile-badge-btn span,
  .profile-badge-btn i {
    display: none !important;
  }
  .profile-badge-btn {
    padding: 0.25rem !important;
    background: transparent !important;
    border: none !important;
  }
  
  .hero-title {
    font-size: 2.2rem !important;
  }
  .hero-desc {
    font-size: 1rem !important;
    padding: 0 1rem;
  }
}

/* Site Footer Styles */
.site-footer {
  background: rgba(8, 8, 8, 0.9);
  padding: 3rem 1.5rem 4rem 1.5rem;
  text-align: center;
  border-top: 1px solid var(--border-color);
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

.footer-powered {
  font-size: 0.95rem;
  color: var(--text-muted);
  font-weight: 500;
}

.footer-logo {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--primary);
  margin-left: 0.4rem;
  transition: text-shadow var(--transition-fast);
}

.footer-logo:hover {
  text-shadow: 0 0 12px rgba(245, 197, 24, 0.5);
}

.text-metallic {
  background: linear-gradient(to right, #f5c518, #d4a017, #f5c518);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent;
}

.footer-copy {
  font-size: 0.8rem;
  color: var(--text-dark);
}

/* Hide footer on workspace and generator views */
#view-workspace.active ~ .site-footer,
#view-generator.active ~ .site-footer {
  display: none !important;
}

