/* ==========================================================
   NOVA CREATOR STUDIO - COMPLETE STYLESHEET (ALL-IN-ONE)
   ========================================================== */

/* 1. RESET & BASE */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  width: 100%;
  min-height: 100vh;
  background-color: #080a12;
  color: #e2e8f0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 14px;
  line-height: 1.5;
}

/* 2. APP SHELL LAYOUT */
.nova-app {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  width: 260px;
  background: #0d101d;
  border-right: 1px solid #1a2035;
  padding: 24px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex-shrink: 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #fff;
  margin-bottom: 24px;
}

.brand-logo {
  width: 34px;
  height: 34px;
  background: #635bff;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 1.1rem;
}

.brand b { font-size: 1.1rem; letter-spacing: 0.05em; display: block; line-height: 1.1; }
.brand small { font-size: 0.65rem; color: #64748b; letter-spacing: 0.08em; display: block; }

.nav-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: #475569;
  margin: 12px 10px 4px 10px;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  color: #94a3b8;
  text-decoration: none;
  font-weight: 500;
  transition: all 0.15s;
}

.nav-link:hover {
  background: #141a2e;
  color: #fff;
}

.nav-link.active {
  background: #1b213b;
  color: #fff;
  font-weight: 600;
}

.nav-link i {
  font-style: normal;
  font-size: 0.65rem;
  background: #635bff;
  color: #fff;
  padding: 1px 5px;
  border-radius: 4px;
  margin-left: auto;
}

.sidebar-bottom {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 10px;
  background: #121629;
  border: 1px solid #1f2742;
  padding: 12px;
  border-radius: 10px;
}

.sidebar-bottom b { font-size: 0.8rem; display: block; color: #f1f5f9; }
.sidebar-bottom small { font-size: 0.7rem; color: #64748b; display: block; }

.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
}

/* 3. MAIN WORKSPACE */
.main {
  flex-grow: 1;
  padding: 32px 48px;
  max-width: 1400px;
  margin: 0 auto;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 28px;
  padding-bottom: 16px;
  border-bottom: 1px solid #161b2e;
}

.crumb {
  font-size: 0.75rem;
  color: #64748b;
  font-weight: 600;
  margin-bottom: 4px;
}

.crumb span { color: #334155; margin: 0 4px; }

.nova-pill {
  font-size: 0.7rem;
  background: #635bff;
  color: #fff;
  padding: 2px 8px;
  border-radius: 20px;
  vertical-align: middle;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.top-right {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.82rem;
  color: #94a3b8;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #635bff;
}

.hero {
  margin-bottom: 32px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #818cf8;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  margin-bottom: 10px;
}

.hero h1 {
  font-size: 2.2rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.25;
  margin-bottom: 8px;
}

.hero h1 span {
  background: linear-gradient(90deg, #818cf8, #c084fc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero p {
  color: #94a3b8;
  font-size: 1.05rem;
}

/* 4. PANELS & FORMS */
.workspace-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 32px;
}

.panel {
  background: #0f1322;
  border: 1px solid #1c233a;
  border-radius: 16px;
  padding: 24px;
}

.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
}

.step-label {
  font-size: 0.7rem;
  font-weight: 800;
  color: #635bff;
  letter-spacing: 0.1em;
  margin-bottom: 4px;
}

.panel-head h3 {
  font-size: 1.2rem;
  font-weight: 700;
  color: #ffffff;
}

.panel-head p {
  font-size: 0.85rem;
  color: #64748b;
}

.panel-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}
.panel-icon.purple { background: rgba(99, 91, 255, 0.15); color: #818cf8; }
.panel-icon.mint { background: rgba(16, 185, 129, 0.15); color: #34d399; }

label {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #94a3b8;
  margin-bottom: 8px;
}

textarea, select, input[type="text"] {
  width: 100%;
  background: #080a14;
  border: 1px solid #222b48;
  border-radius: 8px;
  padding: 12px 14px;
  color: #ffffff;
  font-family: inherit;
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.15s;
}

textarea:focus, select:focus, input[type="text"]:focus {
  border-color: #635bff;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 16px 0;
}

/* BUTTONS */
.primary-btn {
  width: 100%;
  background: #635bff;
  color: #ffffff;
  border: none;
  padding: 14px 20px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background 0.15s;
}

.primary-btn:hover { background: #5146e5; }
.primary-btn.compact { width: auto; padding: 8px 16px; font-size: 0.85rem; }

.ghost-btn {
  background: transparent;
  border: 1px solid #222b48;
  color: #94a3b8;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
}
.ghost-btn:hover { background: #141a2e; color: #fff; }

.outline-btn {
  background: #141a2e;
  border: 1px solid #2b3558;
  color: #cbd5e1;
  padding: 8px 16px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
}
.outline-btn:hover { background: #1c243f; color: #fff; }

/* METRICS */
.metric-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}

.metric {
  background: #080a14;
  border: 1px solid #1a2035;
  border-radius: 10px;
  padding: 14px;
}

.metric span { font-size: 0.72rem; color: #64748b; font-weight: 600; display: block; margin-bottom: 4px; }
.metric strong { font-size: 1.4rem; color: #fff; display: block; line-height: 1.1; margin-bottom: 4px; }
.metric small { font-size: 0.7rem; color: #475569; display: block; }

.signal-note {
  display: flex;
  gap: 12px;
  background: rgba(99, 91, 255, 0.08);
  border: 1px solid rgba(99, 91, 255, 0.2);
  padding: 14px;
  border-radius: 10px;
}

.signal-icon { color: #818cf8; font-size: 1.1rem; }
.signal-note b { font-size: 0.85rem; color: #fff; display: block; }
.signal-note p { font-size: 0.78rem; color: #94a3b8; margin-top: 2px; }

/* 5. TABS & RESEARCH RESULTS */
.hidden { display: none !important; }
.results { margin-bottom: 32px; }
.results-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}
.results-head h2 { font-size: 1.4rem; color: #fff; font-weight: 700; }
.results-head p { font-size: 0.85rem; color: #64748b; }

.tabs {
  display: flex;
  gap: 8px;
  border-bottom: 1px solid #1c233a;
  padding-bottom: 12px;
  margin-bottom: 16px;
  overflow-x: auto;
}

.tab {
  background: #0f1322;
  border: 1px solid #1c233a;
  color: #94a3b8;
  padding: 8px 14px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
}

.tab.active {
  background: #635bff;
  border-color: #635bff;
  color: #fff;
}

.tab-content {
  background: #0f1322;
  border: 1px solid #1c233a;
  border-radius: 12px;
  padding: 20px;
  min-height: 120px;
  margin-bottom: 20px;
}

.generate-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: linear-gradient(90deg, #13172c 0%, #171d38 100%);
  border: 1px solid #283354;
  padding: 24px;
  border-radius: 14px;
}

.generate-bar h3 { font-size: 1.2rem; color: #fff; font-weight: 700; }
.generate-bar p { font-size: 0.85rem; color: #94a3b8; }

.generate-btn {
  background: #10b981;
  color: #fff;
  border: none;
  padding: 14px 24px;
  border-radius: 10px;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: background 0.15s;
}

.generate-btn:hover { background: #059669; }

/* 6. STUDIO TITLE & METADATA SECTION */
.package-panel {
  margin-bottom: 40px;
}

.package-actions {
  display: flex;
  gap: 10px;
}

.studio-card {
  background: #0f1322;
  border: 1px solid #1c233a;
  border-radius: 14px;
  padding: 22px;
  margin-bottom: 20px;
}

.primary-title-card {
  border-left: 4px solid #635bff;
  background: linear-gradient(180deg, #13172c 0%, #0d101d 100%);
}

.output-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.studio-label {
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  font-weight: 700;
  text-transform: uppercase;
  color: #94a3b8;
}

.studio-sublabel {
  font-size: 0.75rem;
  color: #64748b;
  margin-left: 8px;
}

.studio-title-input {
  width: 100%;
  font-size: 1.25rem !important;
  font-weight: 700 !important;
  line-height: 1.4 !important;
  color: #ffffff !important;
  background: #080a14 !important;
  border: 1px solid #222b48 !important;
  border-radius: 10px;
  padding: 14px 16px;
  resize: vertical;
}

.field-foot-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 8px;
  font-size: 0.8rem;
}

.badge-char {
  background: #1e2540;
  color: #a5b4fc;
  padding: 2px 8px;
  border-radius: 4px;
  font-weight: 600;
}

.hint-text { color: #64748b; }

/* TITLE STUDIO CARDS */
.title-cards-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 14px;
}

.title-card-item {
  background: #080a14;
  border: 1px solid #1a2035;
  border-radius: 12px;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  transition: all 0.2s ease;
}

.title-card-item:hover {
  background: #0f1324;
  border-color: #313c63;
}

.title-card-left {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-grow: 1;
}

.title-card-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.72rem;
}

.title-num {
  font-family: monospace;
  color: #64748b;
  font-weight: bold;
}

.badge-intent {
  padding: 2px 7px;
  border-radius: 4px;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.68rem;
}

.intent-search { background: rgba(59, 130, 246, 0.15); color: #60a5fa; }
.intent-ctr { background: rgba(239, 68, 68, 0.15); color: #f87171; }
.intent-news { background: rgba(16, 185, 129, 0.15); color: #34d399; }
.intent-curiosity { background: rgba(245, 158, 11, 0.15); color: #fbbf24; }

.badge-score {
  color: #10b981;
  font-weight: 700;
}

.title-text-body {
  font-size: 1.05rem;
  font-weight: 600;
  color: #f1f5f9;
  line-height: 1.35;
}

.title-card-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.btn-card-use {
  background: #635bff;
  color: #ffffff;
  border: none;
  padding: 7px 13px;
  border-radius: 7px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
}
.btn-card-use:hover { background: #5046e5; }

.btn-card-copy {
  background: #1a2035;
  color: #cbd5e1;
  border: 1px solid #2b3558;
  padding: 6px 12px;
  border-radius: 7px;
  font-size: 0.8rem;
  cursor: pointer;
}
.btn-card-copy:hover { background: #252e4d; color: #fff; }

.generate-more-wrapper {
  margin-top: 16px;
  display: flex;
  justify-content: center;
}

.generate-more-btn {
  background: #0d101d;
  border: 1px dashed #283354;
  color: #94a3b8;
  padding: 12px 24px;
  border-radius: 9px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.generate-more-btn:hover { background: #141a2e; border-color: #635bff; color: #fff; }

/* 7. METADATA GRIDS & TEXTAREAS */
.studio-grid-two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.studio-textarea {
  width: 100%;
  background: #080a14;
  border: 1px solid #1e253e;
  border-radius: 8px;
  padding: 12px;
  color: #e2e8f0;
  font-family: inherit;
  font-size: 0.9rem;
  line-height: 1.5;
  resize: vertical;
}

.studio-desc {
  font-size: 0.95rem;
  line-height: 1.6;
}

.btn-copy-action {
  background: #1c223a;
  border: 1px solid #283354;
  color: #94a3b8;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
}
.btn-copy-action:hover { background: #252e4e; color: #ffffff; }

.field-foot {
  font-size: 0.75rem;
  color: #64748b;
  margin-top: 6px;
}

footer {
  text-align: center;
  color: #475569;
  font-size: 0.8rem;
  padding: 24px 0;
  border-top: 1px solid #161b2e;
}

/* RESPONSIVE */
@media (max-width: 900px) {
  .nova-app { flex-direction: column; }
  .sidebar { width: 100%; }
  .main { padding: 20px; }
  .workspace-grid, .studio-grid-two { grid-template-columns: 1fr; }
  .title-card-item { flex-direction: column; align-items: flex-start; }
  .title-card-actions { width: 100%; justify-content: flex-end; }
}