/* ═══════════════════════════════════════════════
   CSS CUSTOM PROPERTIES — REFINED DEEP NAVY THEME
═══════════════════════════════════════════════ */
:root {
  --void:       #03060f;
  --deep:       #060c1a;
  --surface:    #0b1526;
  --card:       #0f1c30;
  --card-hover: #132035;
  --border-xs:  rgba(80,140,255,0.07);
  --border-sm:  rgba(80,140,255,0.13);
  --border-md:  rgba(80,140,255,0.22);
  --border-lg:  rgba(80,140,255,0.35);
  --ibm:        #0f62fe;
  --ibm-lt:     #4589ff;
  --cyan:       #00b0ff;
  --teal:       #009d9a;
  --green:      #24a148;
  --purple:     #8a3ffc;
  --magenta:    #ee5396;
  --red:        #fa4d56;
  --amber:      #f1c21b;
  --text-1:     #eef3ff;
  --text-2:     #8daac8;
  --text-3:     #4d6a88;
  --mono:       'JetBrains Mono', monospace;
  --display:    'Outfit', sans-serif;
  --serif:      'Fraunces', serif;
  --body:       'Outfit', sans-serif;
  --r-xs:       4px;
  --r-sm:       8px;
  --r-md:       12px;
  --r-lg:       18px;
  --r-xl:       26px;
  --shadow-card: 0 4px 40px rgba(0,0,0,0.5), 0 1px 0 rgba(80,140,255,0.05);
  --t:          all 0.2s cubic-bezier(0.4,0,0.2,1);
}

/* ─── RESET ─── */
*,*::before,*::after { box-sizing: border-box; margin: 0; padding: 0 }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased }
body {
  background: var(--void);
  color: var(--text-1);
  font-family: var(--body);
  font-size: 15px;
  line-height: 1.65;
  min-height: 100vh;
  overflow-x: hidden;
}
::-webkit-scrollbar { width: 4px; height: 4px }
::-webkit-scrollbar-track { background: var(--deep) }
::-webkit-scrollbar-thumb { background: var(--border-md); border-radius: 99px }

/* ─── PAGE ROUTING SYSTEM ─── */
.page { display: none; min-height: 100vh }
.page.active { display: block }

/* ─── ANIMATIONS ─── */
@keyframes fadeUp   { from { opacity:0; transform:translateY(14px) } to { opacity:1; transform:translateY(0) } }
@keyframes fadeIn   { from { opacity:0 } to { opacity:1 } }
@keyframes scaleIn  { from { opacity:0; transform:scale(0.96) } to { opacity:1; transform:scale(1) } }
@keyframes pulse    { 0%,100% { opacity:1 } 50% { opacity:0.35 } }
@keyframes shimmer  { 0% { background-position:200% 0 } 100% { background-position:-200% 0 } }
@keyframes barRise  { from { transform:scaleY(0); transform-origin:bottom } to { transform:scaleY(1) } }
@keyframes typeBlink{ 0%,100% { opacity:1 } 50% { opacity:0 } }
@keyframes dotBounce{ 0%,80%,100% { transform:translateY(0) } 40% { transform:translateY(-6px) } }

.fade-up  { animation: fadeUp  0.45s cubic-bezier(0.4,0,0.2,1) both }
.fade-in  { animation: fadeIn  0.35s ease both }
.scale-in { animation: scaleIn 0.3s cubic-bezier(0.4,0,0.2,1) both }

.stagger > *  { animation: fadeUp 0.45s cubic-bezier(0.4,0,0.2,1) both }
.stagger > *:nth-child(1) { animation-delay: 0.04s }
.stagger > *:nth-child(2) { animation-delay: 0.1s }
.stagger > *:nth-child(3) { animation-delay: 0.16s }
.stagger > *:nth-child(4) { animation-delay: 0.22s }
.stagger > *:nth-child(5) { animation-delay: 0.28s }
.stagger > *:nth-child(6) { animation-delay: 0.34s }

/* ─── NAVBAR ─── */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  height: 62px;
  display: flex; align-items: center; padding: 0 28px;
  background: rgba(3,6,15,0.88);
  backdrop-filter: blur(24px) saturate(160%);
  border-bottom: 1px solid var(--border-xs);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  width: 100%; max-width: 1440px; margin: 0 auto;
}
.logo {
  display: flex; align-items: center; gap: 10px;
  cursor: pointer; text-decoration: none; user-select: none;
}
.logo-mark {
  width: 34px; height: 34px;
  background: linear-gradient(135deg, var(--ibm), var(--cyan));
  border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--mono); font-size: 12px; font-weight: 700; color: #fff;
  letter-spacing: -0.5px; flex-shrink: 0;
}
.logo-text {
  font-family: var(--display); font-size: 18px; font-weight: 800;
  color: var(--text-1); letter-spacing: -0.3px;
}
.logo-text span { color: var(--cyan) }
.nav-badge {
  font-size: 10px; padding: 2px 7px;
  background: rgba(0,176,255,0.12);
  color: var(--cyan); border-radius: 99px;
  border: 1px solid rgba(0,176,255,0.25);
  font-family: var(--mono); letter-spacing: 0.3px;
}
.nav-links { display: flex; align-items: center; gap: 2px }
.nav-link {
  padding: 7px 13px; border-radius: var(--r-sm);
  font-family: var(--body); font-size: 14px; font-weight: 500;
  color: var(--text-2); cursor: pointer;
  transition: var(--t); border: none; background: none; outline: none;
}
.nav-link:hover, .nav-link.active {
  color: var(--text-1); background: rgba(80,140,255,0.09);
}
.nav-link:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px }
.nav-right { display: flex; align-items: center; gap: 10px }
.btn-ghost {
  padding: 7px 15px; font-family: var(--body); font-size: 13px; font-weight: 500;
  color: var(--text-2); background: transparent;
  border: 1px solid var(--border-sm); border-radius: var(--r-sm);
  cursor: pointer; transition: var(--t);
}
.btn-ghost:hover { color: var(--text-1); border-color: var(--border-md) }
.btn-ghost:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px }
.nav-cta {
  padding: 7px 18px; border-radius: var(--r-sm);
  background: var(--ibm); color: #fff;
  font-family: var(--body); font-size: 14px; font-weight: 600;
  cursor: pointer; border: none; transition: var(--t);
}
.nav-cta:hover { background: var(--ibm-lt); transform: translateY(-1px) }
.nav-cta:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px }

/* ─── PRIMARY / SECONDARY BUTTONS ─── */
.btn-primary {
  padding: 13px 28px; background: var(--ibm); color: #fff;
  border: none; border-radius: var(--r-md);
  font-family: var(--body); font-size: 15px; font-weight: 600;
  cursor: pointer; transition: var(--t);
  display: inline-flex; align-items: center; gap: 8px;
}
.btn-primary:hover { background: var(--ibm-lt); transform: translateY(-2px); box-shadow: 0 8px 36px rgba(15,98,254,0.42) }
.btn-primary:active { transform: translateY(0) }
.btn-primary:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px }
.btn-secondary {
  padding: 13px 28px; background: transparent; color: var(--text-1);
  border: 1px solid var(--border-sm); border-radius: var(--r-md);
  font-family: var(--body); font-size: 15px; font-weight: 500;
  cursor: pointer; transition: var(--t);
}
.btn-secondary:hover { border-color: var(--border-md); background: rgba(80,140,255,0.07); transform: translateY(-2px) }
.btn-secondary:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px }
.btn-full {
  width: 100%; padding: 13px; background: var(--ibm); color: #fff;
  border: none; border-radius: var(--r-md);
  font-family: var(--body); font-size: 15px; font-weight: 600;
  cursor: pointer; transition: var(--t); margin-top: 8px;
}
.btn-full:hover { background: var(--ibm-lt); box-shadow: 0 8px 36px rgba(15,98,254,0.42) }
.btn-full:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px }
.btn-sm {
  padding: 7px 16px; border-radius: var(--r-sm);
  font-size: 13px; font-weight: 600; cursor: pointer;
  transition: var(--t); border: none;
  background: var(--ibm); color: #fff; font-family: var(--body);
}
.btn-sm:hover { background: var(--ibm-lt) }
.btn-sm:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px }

/* ─── HERO ─── */
.hero {
  padding-top: 130px; padding-bottom: 100px;
  position: relative; overflow: hidden;
}
.hero-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(80,140,255,0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(80,140,255,0.035) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse at 50% 30%, black 30%, transparent 75%);
}
.hero-glow-1 {
  position: absolute; top: -80px; left: 50%; transform: translateX(-50%);
  width: 900px; height: 450px;
  background: radial-gradient(ellipse, rgba(15,98,254,0.18) 0%, transparent 70%);
  pointer-events: none;
}
.hero-glow-2 {
  position: absolute; top: 250px; right: -80px;
  width: 500px; height: 500px;
  background: radial-gradient(ellipse, rgba(0,176,255,0.09) 0%, transparent 70%);
  pointer-events: none;
}
.hero-content {
  position: relative; max-width: 1200px; margin: 0 auto;
  padding: 0 28px; text-align: center;
}
.ibm-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 16px; border-radius: 99px;
  background: rgba(15,98,254,0.1); border: 1px solid rgba(15,98,254,0.28);
  margin-bottom: 36px; font-size: 13px; color: var(--cyan); font-family: var(--mono);
}
.ibm-badge::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%;
  background: var(--cyan); animation: pulse 2s infinite; flex-shrink: 0;
}
.hero h1 {
  font-family: var(--display);
  font-size: clamp(44px, 7vw, 92px);
  font-weight: 900; line-height: 1.02;
  letter-spacing: -3px; margin-bottom: 24px;
}
.hero h1 .line1 { display: block; color: var(--text-1) }
.hero h1 .line2 {
  display: block;
  background: linear-gradient(90deg, var(--ibm-lt), var(--cyan), var(--teal));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-sub {
  font-size: 18px; color: var(--text-2);
  max-width: 620px; margin: 0 auto 44px; line-height: 1.75;
}
.hero-actions {
  display: flex; align-items: center; justify-content: center;
  gap: 14px; flex-wrap: wrap; margin-bottom: 72px;
}
.hero-stats {
  display: flex; justify-content: center; gap: 56px; flex-wrap: wrap;
}
.hero-stat { text-align: center }
.hero-stat-num {
  font-family: var(--display); font-size: 34px; font-weight: 900;
  color: var(--text-1); letter-spacing: -1px;
}
.hero-stat-num span { color: var(--cyan) }
.hero-stat-label { font-size: 13px; color: var(--text-3); margin-top: 2px }

/* ─── DASHBOARD PREVIEW MOCKUP ─── */
.dashboard-preview {
  position: relative; max-width: 1100px; margin: 72px auto 0; padding: 0 28px;
}
.preview-frame {
  background: var(--surface); border: 1px solid var(--border-sm);
  border-radius: var(--r-xl); overflow: hidden;
  box-shadow: 0 40px 120px rgba(0,0,0,0.7), 0 0 0 1px var(--border-xs),
              inset 0 1px 0 rgba(255,255,255,0.04);
}
.preview-topbar {
  background: var(--card); border-bottom: 1px solid var(--border-xs);
  padding: 12px 18px; display: flex; align-items: center; gap: 10px;
}
.dot { width: 11px; height: 11px; border-radius: 50%; flex-shrink: 0 }
.dot-r { background: #ff5f57 }
.dot-y { background: #febc2e }
.dot-g { background: #28c840 }
.preview-url {
  margin-left: 8px; font-family: var(--mono); font-size: 12px;
  color: var(--text-3); background: var(--surface);
  padding: 3px 14px; border-radius: 99px; border: 1px solid var(--border-xs);
}
.preview-body { display: grid; grid-template-columns: 180px 1fr }
.preview-sidebar {
  background: var(--card); border-right: 1px solid var(--border-xs);
  padding: 14px 10px;
}
.preview-sidebar-item {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 10px; border-radius: var(--r-sm);
  font-size: 12px; color: var(--text-3); margin-bottom: 2px;
  cursor: default; transition: var(--t);
}
.preview-sidebar-item svg { width: 14px; height: 14px }
.preview-sidebar-item.active { background: rgba(15,98,254,0.12); color: var(--cyan) }
.preview-main { padding: 16px; display: flex; flex-direction: column; gap: 12px }
.preview-row { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px }
.preview-card {
  background: var(--card); border: 1px solid var(--border-xs);
  border-radius: var(--r-md); padding: 14px;
}
.preview-card-label {
  font-size: 10px; color: var(--text-3); font-family: var(--mono);
  margin-bottom: 6px; text-transform: uppercase; letter-spacing: 0.8px;
}
.preview-card-val { font-family: var(--display); font-size: 26px; font-weight: 800 }
.preview-card-delta { font-size: 11px; color: var(--green); margin-top: 2px }
.preview-ai-box {
  background: var(--card); border: 1px solid var(--border-sm);
  border-radius: var(--r-md); padding: 14px; position: relative; overflow: hidden;
}
.preview-ai-box::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--ibm), var(--cyan), var(--teal));
}
.ai-label {
  font-size: 10px; color: var(--cyan); font-family: var(--mono);
  margin-bottom: 8px; display: flex; align-items: center; gap: 6px;
}
.ai-label::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%;
  background: var(--cyan); animation: pulse 1.5s infinite; flex-shrink: 0;
}
.ai-text { font-size: 12px; color: var(--text-2); line-height: 1.65 }
.ai-text .hl { color: var(--cyan); font-family: var(--mono) }
.chart-bars { display: flex; align-items: flex-end; gap: 4px; height: 56px; margin-top: 10px }
.bar {
  flex: 1; background: linear-gradient(180deg, var(--ibm-lt), var(--ibm));
  border-radius: 3px 3px 0 0; opacity: 0.8;
  animation: barRise 1s ease-out both;
}

/* ─── SECTIONS ─── */
.section { padding: 100px 28px; max-width: 1200px; margin: 0 auto }
.section-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 5px 13px; border-radius: 99px;
  background: rgba(0,176,255,0.08); border: 1px solid rgba(0,176,255,0.18);
  font-size: 11px; color: var(--cyan); font-family: var(--mono);
  margin-bottom: 20px; text-transform: uppercase; letter-spacing: 1.2px;
}
.section-title {
  font-family: var(--display); font-size: clamp(30px,4vw,50px);
  font-weight: 900; letter-spacing: -1.5px; margin-bottom: 16px;
}
.section-sub {
  font-size: 17px; color: var(--text-2); max-width: 560px;
  line-height: 1.75; margin-bottom: 60px;
}
.text-center { text-align: center }
.text-center .section-sub { margin-left: auto; margin-right: auto }
.gradient-text {
  background: linear-gradient(90deg, var(--ibm-lt), var(--cyan));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}

/* ─── FEATURES GRID ─── */
.features-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2px; background: var(--border-xs); border-radius: var(--r-xl); overflow: hidden;
}
.feature-card {
  background: var(--surface); padding: 38px;
  position: relative; overflow: hidden; transition: var(--t);
}
.feature-card:hover { background: var(--card-hover) }
.feature-card::after {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-md), transparent);
  opacity: 0; transition: var(--t);
}
.feature-card:hover::after { opacity: 1 }
.feature-icon {
  width: 50px; height: 50px; border-radius: var(--r-md);
  background: rgba(15,98,254,0.11); border: 1px solid rgba(15,98,254,0.18);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 22px; font-size: 23px;
}
.feature-title {
  font-family: var(--display); font-size: 18px; font-weight: 700;
  margin-bottom: 10px; letter-spacing: -0.3px;
}
.feature-desc { font-size: 14px; color: var(--text-2); line-height: 1.75 }
.feature-tag {
  margin-top: 18px; display: inline-flex; padding: 3px 9px;
  border-radius: var(--r-xs); background: rgba(0,176,255,0.08);
  color: var(--cyan); font-family: var(--mono); font-size: 11px;
}

/* ─── WORKFLOW ─── */
.workflow { display: flex; flex-direction: column }
.workflow-step {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 64px; align-items: center;
  padding: 64px 0; border-bottom: 1px solid var(--border-xs);
}
.workflow-step:last-child { border: none }
.workflow-step.reverse .workflow-visual { order: -1 }
.workflow-num { font-family: var(--mono); font-size: 13px; color: var(--cyan); margin-bottom: 12px }
.workflow-title { font-family: var(--display); font-size: 30px; font-weight: 800; margin-bottom: 16px; letter-spacing: -0.5px }
.workflow-desc { font-size: 15px; color: var(--text-2); line-height: 1.8; margin-bottom: 24px }
.workflow-bullets { list-style: none; display: flex; flex-direction: column; gap: 10px }
.workflow-bullets li {
  display: flex; align-items: flex-start; gap: 10px;
  font-size: 14px; color: var(--text-2);
}
.workflow-bullets li::before {
  content: '→'; color: var(--cyan); font-family: var(--mono); flex-shrink: 0; margin-top: 1px;
}
.workflow-visual {
  background: var(--surface); border: 1px solid var(--border-sm);
  border-radius: var(--r-xl); padding: 26px; min-height: 240px;
  display: flex; flex-direction: column; gap: 12px;
  position: relative; overflow: hidden;
}
.workflow-visual::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--ibm), var(--cyan));
}

/* ─── CODE BLOCK ─── */
.code-block {
  background: var(--void); border: 1px solid var(--border-xs);
  border-radius: var(--r-md); padding: 18px;
  font-family: var(--mono); font-size: 12.5px; line-height: 1.85;
  overflow-x: auto; white-space: pre;
}
.kw  { color: #c792ea }
.fn  { color: #82aaff }
.str { color: #c3e88d }
.cm  { color: #546e7a }
.num { color: #f78c6c }
.op  { color: var(--cyan) }

/* ─── TESTIMONIALS ─── */
.testimonials-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 20px }
.testimonial-card {
  background: var(--surface); border: 1px solid var(--border-xs);
  border-radius: var(--r-xl); padding: 30px; transition: var(--t);
}
.testimonial-card:hover { border-color: var(--border-sm); transform: translateY(-4px) }
.testimonial-text { font-size: 15px; color: var(--text-2); line-height: 1.8; margin-bottom: 22px; font-style: italic }
.testimonial-author { display: flex; align-items: center; gap: 12px }
.author-name { font-weight: 600; font-size: 14px }
.author-role { font-size: 12px; color: var(--text-3) }
.stars { color: #f5c518; font-size: 13px; margin-bottom: 14px; letter-spacing: 1px }

/* ─── PRICING ─── */
.pricing-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 20px; margin-top: 60px }
.pricing-card {
  background: var(--surface); border: 1px solid var(--border-xs);
  border-radius: var(--r-xl); padding: 38px; position: relative; transition: var(--t);
}
.pricing-card.featured {
  border-color: var(--ibm); background: var(--card);
  box-shadow: 0 0 64px rgba(15,98,254,0.12);
}
.pricing-card.featured::before {
  content: 'Most Popular'; position: absolute;
  top: -13px; left: 50%; transform: translateX(-50%);
  background: var(--ibm); color: #fff;
  font-size: 11px; font-weight: 700; padding: 4px 16px;
  border-radius: 99px; font-family: var(--mono); white-space: nowrap;
}
.pricing-tier { font-family: var(--mono); font-size: 12px; color: var(--cyan); text-transform: uppercase; letter-spacing: 1.2px; margin-bottom: 12px }
.pricing-price { font-family: var(--display); font-size: 52px; font-weight: 900; margin-bottom: 4px; line-height: 1; letter-spacing: -2px }
.pricing-price sup { font-size: 24px; font-weight: 500; vertical-align: super }
.pricing-period { font-size: 13px; color: var(--text-3); margin-bottom: 26px }
.pricing-features { list-style: none; display: flex; flex-direction: column; gap: 12px; margin-bottom: 34px }
.pricing-features li { font-size: 14px; color: var(--text-2); display: flex; align-items: flex-start; gap: 10px }
.pricing-features li::before { content: '✓'; color: var(--green); font-weight: 700; flex-shrink: 0 }
.btn-pricing {
  width: 100%; padding: 12px; border-radius: var(--r-md);
  font-family: var(--body); font-size: 15px; font-weight: 600;
  cursor: pointer; transition: var(--t);
  border: 1px solid var(--border-sm);
  background: transparent; color: var(--text-1);
}
.btn-pricing:hover { background: rgba(80,140,255,0.08); border-color: var(--border-md) }
.featured .btn-pricing { background: var(--ibm); border-color: var(--ibm); color: #fff }
.featured .btn-pricing:hover { background: var(--ibm-lt) }

/* ─── CTA SECTION ─── */
.cta-section { padding: 100px 28px; text-align: center; position: relative; overflow: hidden }
.cta-box {
  max-width: 820px; margin: 0 auto;
  background: linear-gradient(135deg, rgba(15,98,254,0.1), rgba(0,176,255,0.05));
  border: 1px solid rgba(15,98,254,0.2);
  border-radius: var(--r-xl); padding: 78px;
  position: relative; overflow: hidden;
}
.cta-box::before {
  content: ''; position: absolute; top: -100px; right: -100px;
  width: 400px; height: 400px;
  background: radial-gradient(ellipse, rgba(15,98,254,0.15), transparent 70%);
}
.cta-title {
  font-family: var(--display); font-size: clamp(32px,5vw,58px);
  font-weight: 900; letter-spacing: -2px; margin-bottom: 20px;
}
.cta-sub { font-size: 17px; color: var(--text-2); margin-bottom: 42px }
.cta-actions { display: flex; justify-content: center; gap: 14px; flex-wrap: wrap }

/* ─── FOOTER ─── */
footer {
  background: var(--deep); border-top: 1px solid var(--border-xs);
  padding: 64px 28px 44px;
}
.footer-inner {
  max-width: 1200px; margin: 0 auto;
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 52px;
}
.footer-brand .logo-text { font-family: var(--display); font-size: 20px; font-weight: 900; display: block; margin-bottom: 14px }
.footer-brand p { font-size: 14px; color: var(--text-3); line-height: 1.8; margin-bottom: 24px }
.footer-col h4 {
  font-size: 11px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 1.5px; color: var(--text-3); margin-bottom: 16px; font-family: var(--mono);
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px }
.footer-col ul li a { color: var(--text-2); font-size: 14px; text-decoration: none; transition: var(--t) }
.footer-col ul li a:hover { color: var(--cyan) }
.footer-bottom {
  max-width: 1200px; margin: 44px auto 0;
  padding-top: 26px; border-top: 1px solid var(--border-xs);
  display: flex; justify-content: space-between; align-items: center;
  font-size: 13px; color: var(--text-3);
}
.ibm-credit { display: flex; align-items: center; gap: 8px; font-family: var(--mono) }
.ibm-logo { background: var(--ibm); color: #fff; padding: 2px 7px; border-radius: 3px; font-weight: 700; font-size: 11px }

/* ─── AUTH ─── */
.auth-page {
  min-height: 100vh; display: flex; align-items: center;
  justify-content: center; padding: 90px 28px;
  background: var(--void); position: relative; overflow: hidden;
}
.auth-glow {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
  width: 700px; height: 700px;
  background: radial-gradient(ellipse, rgba(15,98,254,0.11), transparent 70%);
  pointer-events: none;
}
.auth-card {
  background: var(--surface); border: 1px solid var(--border-sm);
  border-radius: var(--r-xl); padding: 52px;
  width: 100%; max-width: 450px; position: relative;
}
.auth-card::before {
  content: ''; position: absolute; top: 0; left: 20%; right: 20%; height: 1px;
  background: linear-gradient(90deg, transparent, var(--ibm), transparent);
}
.auth-logo { text-align: center; margin-bottom: 38px }
.auth-title { font-family: var(--display); font-size: 30px; font-weight: 900; text-align: center; margin-bottom: 8px; letter-spacing: -0.5px }
.auth-sub { font-size: 14px; color: var(--text-3); text-align: center; margin-bottom: 34px }
.oauth-btn {
  width: 100%; padding: 12px 18px; border-radius: var(--r-md);
  border: 1px solid var(--border-sm); background: var(--card);
  color: var(--text-1); font-family: var(--body); font-size: 14px; font-weight: 500;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  gap: 10px; margin-bottom: 12px; transition: var(--t);
}
.oauth-btn:hover { border-color: var(--border-md); background: var(--card-hover) }
.divider {
  display: flex; align-items: center; gap: 12px;
  margin: 24px 0; color: var(--text-3); font-size: 13px;
}
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: var(--border-xs) }
.form-group { margin-bottom: 18px }
.form-label {
  display: block; font-size: 13px; font-weight: 500;
  color: var(--text-2); margin-bottom: 8px; font-family: var(--mono);
}
.form-input {
  width: 100%; padding: 11px 15px;
  background: var(--card); border: 1px solid var(--border-xs);
  border-radius: var(--r-md); color: var(--text-1);
  font-family: var(--body); font-size: 14px; transition: var(--t); outline: none;
}
.form-input:focus { border-color: var(--ibm); box-shadow: 0 0 0 3px rgba(15,98,254,0.14) }
.form-input::placeholder { color: var(--text-3) }
.auth-footer { text-align: center; margin-top: 26px; font-size: 14px; color: var(--text-3) }
.link { color: var(--cyan); cursor: pointer; text-decoration: none }
.link:hover { text-decoration: underline }

/* ─── APP LAYOUT (sidebar pages) ─── */
.app-layout {
  display: grid; grid-template-columns: 240px 1fr;
  min-height: 100vh; padding-top: 62px;
}
.sidebar {
  background: var(--deep); border-right: 1px solid var(--border-xs);
  position: fixed; top: 62px; left: 0;
  width: 240px; height: calc(100vh - 62px);
  overflow-y: auto; display: flex; flex-direction: column;
}
.sidebar-section {
  padding: 20px 14px 8px;
  font-size: 11px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 1.5px; color: var(--text-3); font-family: var(--mono);
}
.sidebar-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; border-radius: var(--r-sm);
  font-size: 14px; color: var(--text-2);
  cursor: pointer; transition: var(--t);
  margin: 2px 8px; position: relative;
}
.sidebar-item:hover { background: rgba(80,140,255,0.07); color: var(--text-1) }
.sidebar-item.active {
  background: rgba(15,98,254,0.11); color: var(--cyan);
  border: 1px solid rgba(15,98,254,0.18);
}
.sidebar-item svg { width: 16px; height: 16px; flex-shrink: 0 }
.sidebar-badge {
  margin-left: auto; background: var(--ibm); color: #fff;
  font-size: 10px; padding: 1px 6px; border-radius: 99px; font-family: var(--mono);
}
.sidebar-badge.green { background: rgba(36,161,72,0.2); color: var(--green) }
.sidebar-footer {
  margin-top: auto; padding: 16px;
  border-top: 1px solid var(--border-xs);
}
.user-chip { display: flex; align-items: center; gap: 10px }
.avatar {
  width: 34px; height: 34px; border-radius: 50%;
  background: linear-gradient(135deg, var(--ibm), var(--purple));
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; color: #fff; flex-shrink: 0;
}
.user-name { font-size: 13px; font-weight: 600 }
.user-role { font-size: 11px; color: var(--text-3) }
.main-content { margin-left: 240px; padding: 34px; background: var(--void) }

/* ─── PAGE TOPBAR ─── */
.page-topbar {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 34px;
}
.page-title { font-family: var(--display); font-size: 27px; font-weight: 800; letter-spacing: -0.5px }
.page-title-sub { font-size: 14px; color: var(--text-3); margin-top: 3px }
.topbar-actions { display: flex; align-items: center; gap: 10px }
.icon-btn {
  width: 38px; height: 38px; border-radius: var(--r-md);
  border: 1px solid var(--border-xs); background: var(--surface);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: var(--t); color: var(--text-2);
}
.icon-btn:hover { border-color: var(--border-sm); color: var(--text-1) }
.notification-dot {
  position: absolute; top: -3px; right: -3px;
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--ibm-lt); border: 2px solid var(--void);
}

/* ─── DASHBOARD METRICS ─── */
.metrics-row { display: grid; grid-template-columns: repeat(4,1fr); gap: 16px; margin-bottom: 26px }
.metric-card {
  background: var(--surface); border: 1px solid var(--border-xs);
  border-radius: var(--r-lg); padding: 24px; transition: var(--t);
}
.metric-card:hover { border-color: var(--border-sm); transform: translateY(-2px) }
.metric-label {
  font-size: 12px; color: var(--text-3); font-family: var(--mono);
  text-transform: uppercase; letter-spacing: 0.5px;
  margin-bottom: 12px; display: flex; align-items: center; gap: 8px;
}
.metric-label svg { width: 14px; height: 14px }
.metric-value { font-family: var(--display); font-size: 34px; font-weight: 900; margin-bottom: 6px; letter-spacing: -1px }
.metric-delta { font-size: 12px }
.delta-up { color: var(--green) }
.delta-down { color: var(--red) }
.dash-grid { display: grid; grid-template-columns: 1fr 380px; gap: 22px; margin-bottom: 22px }
.card {
  background: var(--surface); border: 1px solid var(--border-xs);
  border-radius: var(--r-lg); padding: 26px;
}
.card-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 22px }
.card-title { font-family: var(--display); font-size: 15px; font-weight: 700 }
.card-badge {
  font-size: 11px; padding: 3px 9px; border-radius: 99px;
  background: rgba(0,176,255,0.1); color: var(--cyan); font-family: var(--mono);
}

/* ─── PROJECT CARDS ─── */
.project-list { display: flex; flex-direction: column; gap: 12px }
.project-item {
  display: flex; align-items: center; gap: 14px;
  padding: 14px; background: var(--card);
  border: 1px solid var(--border-xs); border-radius: var(--r-md);
  cursor: pointer; transition: var(--t);
}
.project-item:hover { border-color: var(--border-sm); background: var(--card-hover) }
.project-icon {
  width: 38px; height: 38px; border-radius: var(--r-sm);
  background: linear-gradient(135deg, var(--ibm), var(--purple));
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; color: #fff; font-family: var(--mono); font-weight: 700; flex-shrink: 0;
}
.project-name { font-size: 14px; font-weight: 600; margin-bottom: 3px }
.project-meta { font-size: 12px; color: var(--text-3); display: flex; align-items: center; gap: 8px }
.project-status { margin-left: auto; display: flex; align-items: center; gap: 8px }
.status-dot { width: 7px; height: 7px; border-radius: 50% }
.status-dot.green { background: var(--green) }
.status-dot.blue  { background: var(--ibm-lt) }
.status-dot.amber { background: var(--amber) }
.progress-bar { width: 80px; height: 4px; background: var(--border-xs); border-radius: 99px; overflow: hidden }
.progress-fill { height: 100%; background: linear-gradient(90deg, var(--ibm), var(--cyan)); border-radius: 99px }

/* ─── ACTIVITY ─── */
.activity-list { display: flex; flex-direction: column; gap: 0 }
.activity-item {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 16px 0; border-bottom: 1px solid var(--border-xs);
}
.activity-item:last-child { border: none; padding-bottom: 0 }
.activity-icon {
  width: 32px; height: 32px; border-radius: var(--r-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; flex-shrink: 0; margin-top: 1px;
}
.activity-icon.blue   { background: rgba(15,98,254,0.15) }
.activity-icon.green  { background: rgba(36,161,72,0.15) }
.activity-icon.purple { background: rgba(138,63,252,0.15) }
.activity-icon.cyan   { background: rgba(0,176,255,0.15) }
.activity-text { font-size: 14px; color: var(--text-2); line-height: 1.55 }
.activity-text strong { color: var(--text-1); font-weight: 600 }
.activity-time { font-size: 12px; color: var(--text-3); margin-top: 4px; font-family: var(--mono) }

/* ─── AI PANEL (dashboard) ─── */
.ai-panel {
  background: var(--card); border: 1px solid var(--border-sm);
  border-radius: var(--r-lg); display: flex; flex-direction: column;
  height: 100%; min-height: 500px; overflow: hidden; position: relative;
}
.ai-panel::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--ibm), var(--cyan), var(--teal));
}
.ai-panel-header {
  padding: 16px 20px; border-bottom: 1px solid var(--border-xs);
  display: flex; align-items: center; gap: 10px; flex-shrink: 0;
}
.ai-panel-title { font-size: 14px; font-weight: 700 }
.ai-status {
  font-size: 11px; color: var(--green); font-family: var(--mono);
  display: flex; align-items: center; gap: 5px; margin-left: auto;
}
.ai-status::before {
  content: ''; width: 5px; height: 5px; border-radius: 50%;
  background: var(--green); display: inline-block; animation: pulse 1.5s infinite;
}
.ai-chips { padding: 10px 16px; display: flex; flex-wrap: wrap; gap: 6px; border-bottom: 1px solid var(--border-xs); flex-shrink: 0 }
.ai-chip {
  padding: 4px 11px; border-radius: 99px;
  background: rgba(80,140,255,0.08); border: 1px solid var(--border-xs);
  font-size: 12px; color: var(--text-2); cursor: pointer; transition: var(--t);
}
.ai-chip:hover { background: rgba(15,98,254,0.15); color: var(--text-1); border-color: rgba(15,98,254,0.3) }
.ai-messages { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 14px }
.msg { display: flex; align-items: flex-start; gap: 10px }
.msg.user { flex-direction: row-reverse }
.msg-avatar {
  width: 28px; height: 28px; border-radius: 8px;
  background: linear-gradient(135deg, var(--ibm), var(--cyan));
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700; color: #fff; flex-shrink: 0;
}
.msg-avatar.user { background: linear-gradient(135deg, var(--purple), var(--magenta)) }
.msg-bubble {
  background: var(--surface); border: 1px solid var(--border-xs);
  border-radius: 10px; padding: 10px 14px;
  font-size: 13px; color: var(--text-2); line-height: 1.6; max-width: 85%;
}
.msg.user .msg-bubble {
  background: rgba(15,98,254,0.1); border-color: rgba(15,98,254,0.2); color: var(--text-1);
}
.ai-input-row {
  padding: 14px 16px; border-top: 1px solid var(--border-xs);
  display: flex; gap: 8px; flex-shrink: 0;
}
.ai-input {
  flex: 1; padding: 9px 13px;
  background: var(--surface); border: 1px solid var(--border-xs);
  border-radius: var(--r-sm); color: var(--text-1);
  font-family: var(--body); font-size: 13px; outline: none; transition: var(--t);
}
.ai-input:focus { border-color: var(--ibm); box-shadow: 0 0 0 2px rgba(15,98,254,0.14) }
.ai-input::placeholder { color: var(--text-3) }
.ai-send {
  width: 36px; height: 36px; border-radius: var(--r-sm);
  background: var(--ibm); border: none; color: #fff;
  font-size: 16px; cursor: pointer; transition: var(--t);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.ai-send:hover { background: var(--ibm-lt) }

/* ═══════════════════════════════════════════════
   AI ASSISTANT PAGE — FIXED LAYOUT
   The bug: grid had 3 columns but history sidebar
   was hidden at <1024px, leaving an empty column.
   Fix: use grid-template-areas so the chat area
   always fills available space correctly.
═══════════════════════════════════════════════ */
.ai-page-layout {
  display: grid;
  grid-template-columns: 240px 280px 1fr;
  grid-template-areas: "sidebar history chat";
  height: 100vh;
  padding-top: 62px;
}

.ai-sidebar-main {
  grid-area: sidebar;
  background: var(--deep);
  border-right: 1px solid var(--border-xs);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  /* Fixed positioning to sit under the navbar */
  position: fixed;
  top: 62px;
  left: 0;
  width: 240px;
  height: calc(100vh - 62px);
}

.ai-sidebar-history {
  grid-area: history;
  background: var(--void);
  border-right: 1px solid var(--border-xs);
  padding: 18px;
  overflow-y: auto;
  /* Fixed positioning next to the sidebar */
  position: fixed;
  top: 62px;
  left: 240px;
  width: 280px;
  height: calc(100vh - 62px);
}

.ai-chat-area {
  grid-area: chat;
  display: flex;
  flex-direction: column;
  background: var(--deep);
  overflow: hidden;
  /* Push right of both fixed sidebars */
  margin-left: 520px; /* 240px sidebar + 280px history */
  height: calc(100vh - 62px);
  position: fixed;
  top: 62px;
  left: 520px;
  right: 0;
}

.ai-history-section {
  font-size: 11px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 1.2px; color: var(--text-3); font-family: var(--mono);
  padding: 8px 4px; margin-bottom: 8px;
}
.ai-history-section:not(:first-child) { margin-top: 20px }
.ai-history-item {
  padding: 10px 12px; border-radius: var(--r-sm);
  cursor: pointer; transition: var(--t); margin-bottom: 3px;
}
.ai-history-item:hover { background: rgba(80,140,255,0.07) }
.ai-history-item.active { background: rgba(15,98,254,0.11); border: 1px solid rgba(15,98,254,0.18) }
.ai-history-title { font-size: 13px; font-weight: 500; color: var(--text-1); margin-bottom: 3px }
.ai-history-meta { font-size: 11px; color: var(--text-3); font-family: var(--mono) }
.chat-header {
  padding: 16px 26px; border-bottom: 1px solid var(--border-xs);
  display: flex; align-items: center; gap: 13px;
  background: var(--deep); flex-shrink: 0;
}
.chat-messages {
  flex: 1; overflow-y: auto;
  padding: 30px 50px; display: flex; flex-direction: column; gap: 28px;
}
.chat-msg { display: flex; align-items: flex-start; gap: 13px }
.chat-msg.user-msg { flex-direction: row-reverse }
.chat-avatar {
  width: 34px; height: 34px; border-radius: 10px;
  background: linear-gradient(135deg, var(--ibm), var(--cyan));
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 700; color: #fff; flex-shrink: 0;
}
.chat-avatar.user { background: linear-gradient(135deg, var(--purple), var(--magenta)) }
.chat-content { flex: 1; max-width: 75% }
.chat-sender {
  font-size: 12px; font-weight: 700; color: var(--text-3);
  font-family: var(--mono); margin-bottom: 8px;
}
.chat-msg.user-msg .chat-sender { text-align: right }
.chat-text {
  background: var(--surface); border: 1px solid var(--border-xs);
  border-radius: 14px; padding: 14px 18px;
  font-size: 14px; color: var(--text-2); line-height: 1.7;
}
.chat-msg.user-msg .chat-text {
  background: rgba(15,98,254,0.1); border-color: rgba(15,98,254,0.2);
  color: var(--text-1); border-radius: 14px 14px 3px 14px;
}
.chat-code {
  margin-top: 12px; background: var(--void);
  border: 1px solid var(--border-xs); border-radius: var(--r-md);
  overflow: hidden;
}
.chat-code-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 14px; background: var(--card); border-bottom: 1px solid var(--border-xs);
  font-family: var(--mono); font-size: 11px; color: var(--text-3);
}
.chat-code-header span:last-child { cursor: pointer; color: var(--cyan); transition: var(--t) }
.chat-code-header span:last-child:hover { color: var(--text-1) }
.chat-code pre {
  padding: 16px; font-family: var(--mono); font-size: 12.5px;
  line-height: 1.85; overflow-x: auto; color: var(--text-2);
}
.action-chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 12px }
.action-chip {
  padding: 6px 13px; border-radius: 99px;
  background: rgba(80,140,255,0.08); border: 1px solid var(--border-xs);
  font-size: 12px; color: var(--text-2); cursor: pointer; transition: var(--t);
}
.action-chip:hover { background: rgba(15,98,254,0.15); color: var(--text-1); border-color: rgba(15,98,254,0.3) }
.typing-indicator { display: flex; gap: 4px; align-items: center; padding: 4px 0 }
.typing-dot {
  width: 7px; height: 7px; border-radius: 50%; background: var(--text-3);
  animation: dotBounce 1.2s infinite;
}
.typing-dot:nth-child(2) { animation-delay: 0.15s }
.typing-dot:nth-child(3) { animation-delay: 0.3s }
.chat-input-area {
  padding: 20px 50px; border-top: 1px solid var(--border-xs);
  background: var(--deep); flex-shrink: 0;
}
.shortcut-bar { display: flex; gap: 7px; flex-wrap: wrap; margin-bottom: 12px }
.shortcut-btn {
  padding: 6px 12px; border-radius: 99px;
  background: var(--surface); border: 1px solid var(--border-xs);
  color: var(--text-2); font-size: 12px; cursor: pointer; transition: var(--t);
  font-family: var(--body);
}
.shortcut-btn:hover { background: var(--card); color: var(--text-1); border-color: var(--border-sm) }
.ai-input-box {
  background: var(--surface); border: 1px solid var(--border-sm);
  border-radius: var(--r-lg); overflow: hidden; transition: var(--t);
}
.ai-input-box:focus-within { border-color: var(--ibm); box-shadow: 0 0 0 3px rgba(15,98,254,0.12) }
.ai-textarea {
  width: 100%; padding: 14px 18px;
  background: transparent; border: none; outline: none;
  color: var(--text-1); font-family: var(--body); font-size: 14px;
  line-height: 1.6; resize: none;
}
.ai-textarea::placeholder { color: var(--text-3) }
.ai-input-footer {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 14px; border-top: 1px solid var(--border-xs);
}
.ai-submit {
  padding: 8px 18px; background: var(--ibm); border: none;
  border-radius: var(--r-sm); color: #fff;
  font-family: var(--body); font-size: 13px; font-weight: 600;
  cursor: pointer; transition: var(--t);
  display: flex; align-items: center; gap: 6px;
}
.ai-submit:hover { background: var(--ibm-lt) }

/* ─── WORKSPACE / KANBAN ─── */
.kanban-board { display: grid; grid-template-columns: repeat(4,1fr); gap: 18px }
.kanban-col {
  background: var(--surface); border: 1px solid var(--border-xs);
  border-radius: var(--r-lg); padding: 18px;
  display: flex; flex-direction: column; gap: 10px; min-height: 420px;
}
.kanban-col-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px }
.kanban-col-title { font-size: 13px; font-weight: 700 }
.kanban-count {
  font-size: 11px; padding: 1px 7px;
  background: rgba(80,140,255,0.1); color: var(--text-3);
  border-radius: 99px; font-family: var(--mono);
}
.kanban-card {
  background: var(--card); border: 1px solid var(--border-xs);
  border-radius: var(--r-md); padding: 14px; cursor: pointer; transition: var(--t);
}
.kanban-card:hover { border-color: var(--border-sm); transform: translateY(-2px) }
.kanban-card-title { font-size: 13px; font-weight: 500; color: var(--text-1); line-height: 1.5; margin-bottom: 10px }
.kanban-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 10px }
.kanban-tag {
  padding: 2px 7px; border-radius: 3px; font-size: 10px; font-family: var(--mono);
}
.tag-red    { background: rgba(250,77,86,0.15);   color: var(--red) }
.tag-blue   { background: rgba(15,98,254,0.12);   color: var(--ibm-lt) }
.tag-cyan   { background: rgba(0,176,255,0.12);   color: var(--cyan) }
.tag-green  { background: rgba(36,161,72,0.12);   color: var(--green) }
.tag-purple { background: rgba(138,63,252,0.12);  color: var(--purple) }
.kanban-card-footer { display: flex; align-items: center; justify-content: space-between }
.kanban-priority { width: 8px; height: 8px; border-radius: 50% }
.kanban-assignee {
  width: 22px; height: 22px; border-radius: 50%;
  background: linear-gradient(135deg, var(--ibm), var(--purple));
  display: flex; align-items: center; justify-content: center;
  font-size: 10px; font-weight: 700; color: #fff; font-family: var(--mono);
}
.add-card-btn {
  width: 100%; padding: 9px; margin-top: 4px;
  background: transparent; border: 1px dashed var(--border-xs);
  border-radius: var(--r-sm); color: var(--text-3); font-size: 12px;
  cursor: pointer; transition: var(--t); font-family: var(--body);
}
.add-card-btn:hover { background: rgba(80,140,255,0.05); border-color: var(--border-sm); color: var(--text-2) }

/* ─── ANALYTICS ─── */
.analytics-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px }
.chart-placeholder {
  display: flex; align-items: flex-end; gap: 5px;
  height: 180px; padding: 0 4px; margin-top: 12px;
}
.chart-bar-item {
  flex: 1; background: linear-gradient(180deg, var(--ibm-lt), var(--ibm));
  border-radius: 4px 4px 0 0; opacity: 0.75;
  animation: barRise 1s ease-out both;
}

/* ─── DEPLOY ─── */
.pipeline-steps { display: flex; flex-direction: column; gap: 12px }
.pipeline-step {
  display: flex; align-items: center; gap: 14px;
  padding: 14px 16px; background: var(--card);
  border: 1px solid var(--border-xs); border-radius: var(--r-md);
}
.pipeline-step-icon {
  width: 34px; height: 34px; border-radius: var(--r-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; flex-shrink: 0;
}

/* ─── SETTINGS ─── */
.settings-layout { display: grid; grid-template-columns: 180px 1fr; gap: 24px }
.settings-nav { display: flex; flex-direction: column; gap: 2px }
.settings-nav-item {
  padding: 9px 13px; border-radius: var(--r-sm);
  font-size: 14px; color: var(--text-2); cursor: pointer; transition: var(--t);
}
.settings-nav-item:hover { background: rgba(80,140,255,0.07); color: var(--text-1) }
.settings-nav-item.active { background: rgba(15,98,254,0.11); color: var(--cyan) }
.settings-section {
  background: var(--surface); border: 1px solid var(--border-xs);
  border-radius: var(--r-lg); padding: 30px; margin-bottom: 20px;
}
.settings-section-title { font-family: var(--display); font-size: 17px; font-weight: 700; margin-bottom: 6px }
.settings-section-sub { font-size: 14px; color: var(--text-3); margin-bottom: 26px }
.settings-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 0; border-bottom: 1px solid var(--border-xs);
}
.settings-row:last-child { border: none; padding-bottom: 0 }
.settings-row-label { font-size: 14px; font-weight: 500 }
.settings-row-desc { font-size: 13px; color: var(--text-3); margin-top: 3px }
.toggle {
  width: 46px; height: 25px; background: var(--ibm);
  border-radius: 99px; position: relative; cursor: pointer;
  flex-shrink: 0; border: none; transition: var(--t);
}
.toggle::after {
  content: ''; position: absolute; top: 3px; right: 3px;
  width: 19px; height: 19px; background: #fff; border-radius: 50%; transition: var(--t);
}
.toggle.off { background: var(--card); border: 1px solid var(--border-sm) }
.toggle.off::after { right: auto; left: 3px }
.api-key-box {
  display: flex; align-items: center; gap: 10px;
  background: var(--deep); border: 1px solid var(--border-xs);
  border-radius: var(--r-md); padding: 10px 15px;
}
.api-key-val { flex: 1; font-family: var(--mono); font-size: 13px; color: var(--text-2); letter-spacing: 2px }
.copy-btn {
  padding: 5px 12px; border: 1px solid var(--border-xs);
  border-radius: var(--r-xs); background: var(--card);
  color: var(--text-3); font-size: 12px; cursor: pointer; font-family: var(--mono);
  transition: var(--t);
}
.copy-btn:hover { color: var(--text-1); border-color: var(--border-sm) }

/* ─── BADGES / MISC ─── */
.badge { display: inline-flex; padding: 2px 9px; border-radius: 99px; font-size: 11px; font-family: var(--mono) }
.badge-blue   { background: rgba(15,98,254,0.12);  color: var(--ibm-lt) }
.badge-green  { background: rgba(36,161,72,0.12);  color: var(--green) }
.badge-purple { background: rgba(138,63,252,0.12); color: var(--purple) }
.badge-cyan   { background: rgba(0,176,255,0.12);  color: var(--cyan) }

/* ─── RESPONSIVE ─── */
@media (max-width: 1200px) {
  .ai-page-layout {
    grid-template-columns: 220px 240px 1fr;
  }
  .ai-sidebar-main { width: 220px }
  .ai-sidebar-history { left: 220px; width: 240px }
  .ai-chat-area { left: 460px }
}

@media (max-width: 1024px) {
  .pricing-grid { grid-template-columns: 1fr }
  .testimonials-grid { grid-template-columns: 1fr }
  .metrics-row { grid-template-columns: 1fr 1fr }
  .footer-inner { grid-template-columns: 1fr 1fr }
  .workflow-step { grid-template-columns: 1fr }
  .workflow-step.reverse .workflow-visual { order: 0 }
  .kanban-board { grid-template-columns: 1fr 1fr }
  .analytics-grid { grid-template-columns: 1fr }

  /* At 1024px: hide history sidebar, chat fills remaining space */
  .ai-page-layout {
    grid-template-columns: 200px 1fr;
    grid-template-areas: "sidebar chat";
  }
  .ai-sidebar-history { display: none }
  .ai-sidebar-main { width: 200px }
  .ai-chat-area {
    left: 200px;
  }
}

@media (max-width: 768px) {
  .app-layout { grid-template-columns: 1fr }
  .sidebar { display: none }
  .main-content { margin-left: 0; padding: 20px }
  .dash-grid { grid-template-columns: 1fr }
  .metrics-row { grid-template-columns: 1fr 1fr }
  .hero h1 { font-size: 38px }
  .hero-stats { gap: 28px }
  .nav-links { display: none }
  .kanban-board { grid-template-columns: 1fr }
  .settings-layout { grid-template-columns: 1fr }

  /* At 768px: hide app sidebar, chat fills full width */
  .ai-page-layout {
    grid-template-columns: 1fr;
    grid-template-areas: "chat";
  }
  .ai-sidebar-main { display: none }
  .ai-sidebar-history { display: none }
  .ai-chat-area {
    left: 0;
  }
  .chat-messages { padding: 20px 20px }
  .chat-input-area { padding: 16px 20px }
}

@media (max-width: 480px) {
  nav { padding: 0 16px }
  .hero { padding-top: 100px; padding-bottom: 60px }
  .hero h1 { font-size: 32px; letter-spacing: -1.5px }
  .hero-sub { font-size: 16px }
  .hero-actions { flex-direction: column; width: 100% }
  .btn-primary, .btn-secondary { width: 100%; justify-content: center }
  .metrics-row { grid-template-columns: 1fr }
  .section { padding: 60px 18px }
  .cta-box { padding: 44px 24px }
  .footer-inner { grid-template-columns: 1fr; gap: 32px }
  .auth-card { padding: 34px 24px }
  .features-grid { grid-template-columns: 1fr }
}