/* =====================================================
   AI TECH PAL - NEW THEME
   Clean, minimal design with Teal accent
   ===================================================== */

:root {
  /* Light Mode Colors */
  --bg-primary: #fafafa;
  --bg-sidebar: #ffffff;
  --bg-sidebar-hover: #f5f5f5;
  --bg-card: #ffffff;
  --bg-card-header: #f9f9f9;
  --text-primary: #0a0a0a;
  --text-muted: #525252;
  --accent: #0D9488;
  --accent-hover: #0f766e;
  --border: #e5e5e5;
  
  /* Sidebar */
  --sidebar-width: 220px;
  --sidebar-collapsed-width: 72px;
}

[data-theme="dark"] {
  --bg-primary: #0a0a0a;
  --bg-sidebar: #171717;
  --bg-sidebar-hover: #262626;
  --bg-card: #171717;
  --bg-card-header: #1f1f1f;
  --text-primary: #ffffff;
  --text-muted: #a3a3a3;
  --accent: #14B8A6;
  --accent-hover: #2dd4bf;
  --border: #262626;
}

/* =====================================================
   BASE STYLES
   ===================================================== */

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  transition: background-color 0.3s ease, color 0.3s ease;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  color: var(--accent-hover);
}

/* =====================================================
   LAYOUT
   ===================================================== */

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

/* =====================================================
   SIDEBAR
   ===================================================== */

.sidebar {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: var(--sidebar-width);
  background-color: var(--bg-sidebar);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  transition: width 0.3s ease;
  z-index: 100;
}

.sidebar.collapsed {
  width: var(--sidebar-collapsed-width);
}

.sidebar-header {
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--border);
}

.sidebar.collapsed .sidebar-header {
  justify-content: center;
  padding: 16px 12px;
}

.sidebar-logo {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}

.sidebar.collapsed .sidebar-logo {
  width: 36px;
  height: 36px;
}

.sidebar-title {
  color: var(--accent);
  font-weight: 700;
  font-size: 15px;
  white-space: nowrap;
}

.sidebar.collapsed .sidebar-title {
  display: none;
}

/* Navigation */
.sidebar-nav {
  flex: 1;
  padding: 8px 0;
  overflow-y: auto;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  color: var(--text-muted);
  text-decoration: none;
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
  cursor: pointer;
}

.sidebar.collapsed .nav-item {
  justify-content: center;
  padding: 12px;
}

.nav-item:hover {
  background-color: var(--bg-sidebar-hover);
  color: var(--text-primary);
}

.nav-item.active {
  background-color: var(--bg-sidebar-hover);
  color: var(--accent);
  border-left-color: var(--accent);
}

.nav-item-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.nav-item-icon svg {
  width: 20px;
  height: 20px;
}

.nav-item-label {
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
}

.sidebar.collapsed .nav-item-label {
  display: none;
}

/* Sidebar Footer */
.sidebar-footer {
  border-top: 1px solid var(--border);
  padding: 8px 0;
}

/* Collapse Toggle Button */
.sidebar-toggle {
  display: none;
}

@media (min-width: 1024px) {
  .sidebar-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    right: -12px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    background-color: var(--bg-sidebar);
    border: 1px solid var(--border);
    border-radius: 50%;
    cursor: pointer;
    color: var(--text-muted);
    transition: all 0.2s ease;
    z-index: 101;
  }
  
  .sidebar-toggle:hover {
    background-color: var(--bg-sidebar-hover);
    color: var(--accent);
  }
  
  .sidebar-toggle svg {
    width: 14px;
    height: 14px;
    transition: transform 0.3s ease;
  }
  
  .sidebar.collapsed .sidebar-toggle svg {
    transform: rotate(180deg);
  }
}

/* =====================================================
   MAIN CONTENT
   ===================================================== */

.main-content {
  flex: 1;
  margin-left: var(--sidebar-width);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  transition: margin-left 0.3s ease;
}

.sidebar.collapsed ~ .main-content {
  margin-left: var(--sidebar-collapsed-width);
}

.page-header {
  padding: 16px 24px;
  border-bottom: 1px solid var(--border);
}

.page-header h1 {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-primary);
}

.page-content {
  flex: 1;
  padding: 24px;
  overflow-y: auto;
}

.page-footer {
  text-align: center;
  padding: 12px;
  font-size: 12px;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
}

/* =====================================================
   CARDS
   ===================================================== */

.card {
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 16px;
}

.card-header {
  padding: 12px 16px;
  background-color: var(--bg-card-header);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 12px;
}

.card-header-accent {
  background-color: var(--accent);
  color: white;
  border-bottom: none;
}

.card-header h3,
.card-header span {
  font-size: 14px;
  font-weight: 600;
}

.card-body {
  padding: 16px;
}

.card-body p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-muted);
}

/* Agent Avatar */
.agent-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 700;
  font-size: 14px;
  flex-shrink: 0;
}

.agent-avatar.kb { background-color: #6366f1; }
.agent-avatar.lola { background-color: #14B8A6; }
.agent-avatar.coordinator { background-color: #14B8A6; }
.agent-avatar.software { background-color: #f59e0b; }
.agent-avatar.hardware { background-color: #ef4444; }
.agent-avatar.network { background-color: #8b5cf6; }

/* =====================================================
   BUTTONS
   ===================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 1px solid transparent;
  text-decoration: none;
}

.btn-primary {
  background-color: var(--accent);
  color: white;
  border-color: var(--accent);
}

.btn-primary:hover {
  background-color: var(--accent-hover);
  color: white;
}

.btn-ghost {
  background-color: var(--bg-sidebar-hover);
  color: var(--text-primary);
  border-color: var(--border);
}

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

.btn svg {
  width: 16px;
  height: 16px;
}

/* =====================================================
   FORMS
   ===================================================== */

.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.form-input,
.form-textarea {
  width: 100%;
  padding: 12px;
  background-color: var(--bg-sidebar-hover);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 14px;
  transition: border-color 0.2s ease;
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.form-textarea {
  resize: vertical;
  min-height: 80px;
  font-family: inherit;
}

/* =====================================================
   ISSUE BANNER
   ===================================================== */

.issue-banner {
  background-color: var(--accent);
  color: white;
  padding: 16px;
  border-radius: 12px;
  margin-bottom: 24px;
}

.issue-banner p {
  font-weight: 500;
  color: white;
}

/* =====================================================
   UPLOAD AREA
   ===================================================== */

.upload-area {
  border: 2px dashed var(--border);
  border-radius: 8px;
  padding: 24px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.upload-area:hover {
  border-color: var(--accent);
  background-color: var(--bg-sidebar-hover);
}

.upload-area svg {
  width: 32px;
  height: 32px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.upload-area p {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 8px;
}

.upload-area.has-files {
  border-color: var(--accent);
  background-color: var(--bg-sidebar-hover);
}

/* ============================================
   HOME PAGE - Mind-Blowing Design
   ============================================ */

.home-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 1rem 1.5rem 2rem;
    position: relative;
    min-height: calc(100vh - 100px);
    overflow: hidden;
}

/* Animated Particles */
.particles {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    overflow: hidden;
}

.particle {
    position: absolute;
    width: 6px;
    height: 6px;
    background: var(--accent-color);
    border-radius: 50%;
    opacity: 0.3;
    animation: float-up 15s infinite;
}

.particle:nth-child(1) { left: 10%; animation-delay: 0s; animation-duration: 12s; }
.particle:nth-child(2) { left: 20%; animation-delay: 2s; animation-duration: 14s; }
.particle:nth-child(3) { left: 35%; animation-delay: 4s; animation-duration: 11s; }
.particle:nth-child(4) { left: 50%; animation-delay: 1s; animation-duration: 16s; }
.particle:nth-child(5) { left: 65%; animation-delay: 3s; animation-duration: 13s; }
.particle:nth-child(6) { left: 75%; animation-delay: 5s; animation-duration: 15s; }
.particle:nth-child(7) { left: 85%; animation-delay: 2.5s; animation-duration: 12s; }
.particle:nth-child(8) { left: 95%; animation-delay: 4.5s; animation-duration: 14s; }

@keyframes float-up {
    0% {
        transform: translateY(100vh) scale(0);
        opacity: 0;
    }
    10% {
        opacity: 0.4;
    }
    90% {
        opacity: 0.4;
    }
    100% {
        transform: translateY(-100px) scale(1);
        opacity: 0;
    }
}

/* Glowing Orbs */
.glow-orbs {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    overflow: hidden;
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.15;
    animation: orb-float 20s ease-in-out infinite;
}

.orb-1 {
    width: 300px;
    height: 300px;
    background: var(--accent-color);
    top: -100px;
    right: -50px;
    animation-delay: 0s;
}

.orb-2 {
    width: 200px;
    height: 200px;
    background: #8b5cf6;
    bottom: 100px;
    left: -50px;
    animation-delay: -5s;
}

.orb-3 {
    width: 150px;
    height: 150px;
    background: #06b6d4;
    top: 50%;
    right: 20%;
    animation-delay: -10s;
}

@keyframes orb-float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(30px, -30px) scale(1.1); }
    50% { transform: translate(-20px, 20px) scale(0.9); }
    75% { transform: translate(20px, 30px) scale(1.05); }
}

/* Hero Section */
.home-hero {
    text-align: center;
    margin-bottom: 2rem;
    position: relative;
    z-index: 1;
}

/* Robot Container */
.robot-container {
    position: relative;
    display: inline-block;
    margin-bottom: 1rem;
}

/* Robot Character */
.robot {
    position: relative;
    width: 120px;
    height: 160px;
    margin: 0 auto;
    animation: robot-hover 3s ease-in-out infinite;
}

@keyframes robot-hover {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

/* Antenna */
.antenna {
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 20px;
    background: linear-gradient(to bottom, var(--accent-color), #0d9488);
    border-radius: 2px;
}

.antenna-ball {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 14px;
    height: 14px;
    background: var(--accent-color);
    border-radius: 50%;
    animation: antenna-glow 1.5s ease-in-out infinite;
    box-shadow: 0 0 15px var(--accent-color);
}

@keyframes antenna-glow {
    0%, 100% { 
        box-shadow: 0 0 10px var(--accent-color);
        transform: translateX(-50%) scale(1);
    }
    50% { 
        box-shadow: 0 0 25px var(--accent-color), 0 0 40px var(--accent-color);
        transform: translateX(-50%) scale(1.2);
    }
}

/* Robot Head */
.robot-head {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 60px;
    background: linear-gradient(135deg, #374151, #1f2937);
    border-radius: 20px 20px 15px 15px;
    border: 3px solid var(--accent-color);
    box-shadow: 
        inset 0 -10px 20px rgba(0,0,0,0.3),
        0 5px 20px rgba(20, 184, 166, 0.3);
}

[data-theme="light"] .robot-head {
    background: linear-gradient(135deg, #e5e7eb, #d1d5db);
    border-color: var(--accent-color);
}

/* Eyes */
.eyes {
    display: flex;
    justify-content: center;
    gap: 15px;
    padding-top: 15px;
}

.eye {
    width: 20px;
    height: 24px;
    background: #1a1a2e;
    border-radius: 8px;
    position: relative;
    overflow: hidden;
    animation: blink 4s infinite;
}

[data-theme="light"] .eye {
    background: #374151;
}

@keyframes blink {
    0%, 45%, 55%, 100% { transform: scaleY(1); }
    50% { transform: scaleY(0.1); }
}

.pupil {
    position: absolute;
    bottom: 4px;
    left: 50%;
    transform: translateX(-50%);
    width: 10px;
    height: 10px;
    background: var(--accent-color);
    border-radius: 50%;
    animation: look-around 5s ease-in-out infinite;
    box-shadow: 0 0 10px var(--accent-color);
}

@keyframes look-around {
    0%, 100% { transform: translateX(-50%); }
    25% { transform: translateX(-80%); }
    50% { transform: translateX(-50%); }
    75% { transform: translateX(-20%); }
}

.eye-shine {
    position: absolute;
    top: 3px;
    right: 3px;
    width: 5px;
    height: 5px;
    background: white;
    border-radius: 50%;
    opacity: 0.7;
}

/* Winking animation for right eye */
.right-eye {
    animation: wink 4s infinite;
}

@keyframes wink {
    0%, 70%, 80%, 100% { transform: scaleY(1); }
    75% { transform: scaleY(0.1); }
}

/* Mouth */
.mouth {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 8px;
    overflow: hidden;
}

.mouth-line {
    width: 100%;
    height: 100%;
    border: 2px solid var(--accent-color);
    border-top: none;
    border-radius: 0 0 15px 15px;
    animation: smile 3s ease-in-out infinite;
}

@keyframes smile {
    0%, 100% { transform: scaleX(1); }
    50% { transform: scaleX(1.2); }
}

/* Cheeks */
.cheek {
    position: absolute;
    width: 10px;
    height: 6px;
    background: rgba(244, 114, 182, 0.5);
    border-radius: 50%;
    bottom: 15px;
}

.left-cheek { left: 8px; }
.right-cheek { right: 8px; }

/* Robot Body */
.robot-body {
    position: absolute;
    top: 65px;
    left: 50%;
    transform: translateX(-50%);
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #374151, #1f2937);
    border-radius: 15px;
    border: 3px solid var(--accent-color);
    box-shadow: 
        inset 0 -10px 20px rgba(0,0,0,0.3),
        0 5px 15px rgba(20, 184, 166, 0.2);
}

[data-theme="light"] .robot-body {
    background: linear-gradient(135deg, #e5e7eb, #d1d5db);
}

.chest-light {
    position: absolute;
    top: 15px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 20px;
    background: var(--accent-color);
    border-radius: 50%;
    animation: chest-pulse 2s ease-in-out infinite;
    box-shadow: 0 0 20px var(--accent-color);
}

@keyframes chest-pulse {
    0%, 100% { 
        opacity: 0.8;
        box-shadow: 0 0 15px var(--accent-color);
    }
    50% { 
        opacity: 1;
        box-shadow: 0 0 30px var(--accent-color), 0 0 50px var(--accent-color);
    }
}

.body-lines {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 5px;
}

.body-line {
    width: 8px;
    height: 3px;
    background: var(--accent-color);
    border-radius: 2px;
    opacity: 0.6;
}

/* Arms */
.arm {
    position: absolute;
    top: 75px;
    width: 20px;
    height: 50px;
    background: linear-gradient(135deg, #374151, #1f2937);
    border-radius: 10px;
    border: 2px solid var(--accent-color);
}

[data-theme="light"] .arm {
    background: linear-gradient(135deg, #e5e7eb, #d1d5db);
}

.left-arm {
    left: 5px;
    transform-origin: top center;
    animation: wave 2s ease-in-out infinite;
}

.right-arm {
    right: 5px;
}

@keyframes wave {
    0%, 100% { transform: rotate(-5deg); }
    25% { transform: rotate(15deg); }
    75% { transform: rotate(-15deg); }
}

.hand {
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 18px;
}

.left-arm .hand {
    animation: wave-hand 2s ease-in-out infinite;
}

@keyframes wave-hand {
    0%, 100% { transform: translateX(-50%) rotate(-10deg); }
    50% { transform: translateX(-50%) rotate(20deg); }
}

/* Speech Bubble */
.speech-bubble {
    position: absolute;
    top: -10px;
    right: -140px;
    background: var(--bg-secondary);
    border: 2px solid var(--accent-color);
    border-radius: 20px;
    padding: 10px 15px;
    font-size: 0.85rem;
    color: var(--text-primary);
    white-space: nowrap;
    animation: bubble-pop 0.5s ease-out;
    box-shadow: 0 5px 20px rgba(20, 184, 166, 0.2);
}

.speech-bubble::before {
    content: '';
    position: absolute;
    left: -10px;
    top: 50%;
    transform: translateY(-50%);
    border: 8px solid transparent;
    border-right-color: var(--accent-color);
}

.speech-bubble::after {
    content: '';
    position: absolute;
    left: -6px;
    top: 50%;
    transform: translateY(-50%);
    border: 6px solid transparent;
    border-right-color: var(--bg-secondary);
}

@keyframes bubble-pop {
    0% { transform: scale(0); opacity: 0; }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); opacity: 1; }
}

.typing-text {
    display: inline-block;
    overflow: hidden;
    border-right: 2px solid var(--accent-color);
    animation: typing 2s steps(20) forwards, cursor-blink 0.7s infinite;
}

@keyframes typing {
    from { width: 0; }
    to { width: 100%; }
}

@keyframes cursor-blink {
    50% { border-color: transparent; }
}

/* Title */
.home-title {
    font-size: 2.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    letter-spacing: -0.5px;
}

.greeting {
    color: var(--text-primary);
}

.gradient-text {
    background: linear-gradient(135deg, var(--accent-color), #06b6d4, #8b5cf6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 5s ease infinite;
    background-size: 200% 200%;
}

@keyframes gradient-shift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.home-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin: 0 0 1.5rem 0;
}

/* Agent Badges */
.agent-badges {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.agent-badge {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.75rem 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    transition: all 0.3s ease;
}

.agent-badge:hover {
    transform: translateY(-3px);
    border-color: var(--accent-color);
    box-shadow: 0 5px 20px rgba(20, 184, 166, 0.2);
}

.badge-icon {
    font-size: 1.5rem;
    margin-bottom: 0.25rem;
}

.badge-name {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.9rem;
}

.badge-role {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

/* Cards */
.home-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    position: relative;
    z-index: 1;
}

.home-card {
    position: relative;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 2rem 1.5rem;
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.card-glow {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.card-submit .card-glow {
    background: radial-gradient(circle at 50% 0%, rgba(20, 184, 166, 0.15), transparent 70%);
}

.card-kb .card-glow {
    background: radial-gradient(circle at 50% 0%, rgba(139, 92, 246, 0.15), transparent 70%);
}

.card-analytics .card-glow {
    background: radial-gradient(circle at 50% 0%, rgba(6, 182, 212, 0.15), transparent 70%);
}

.home-card:hover .card-glow {
    opacity: 1;
}

.home-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.card-submit::before {
    background: linear-gradient(90deg, var(--accent-color), #0d9488);
}

.card-kb::before {
    background: linear-gradient(90deg, #8b5cf6, #7c3aed);
}

.card-analytics::before {
    background: linear-gradient(90deg, #06b6d4, #0891b2);
}

.home-card:hover::before {
    transform: scaleX(1);
}

.home-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.home-card-icon {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.25rem;
    transition: all 0.4s ease;
}

.card-submit .home-card-icon {
    background: linear-gradient(135deg, rgba(20, 184, 166, 0.15), rgba(20, 184, 166, 0.05));
    color: var(--accent-color);
}

.card-kb .home-card-icon {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(139, 92, 246, 0.05));
    color: #8b5cf6;
}

.card-analytics .home-card-icon {
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.15), rgba(6, 182, 212, 0.05));
    color: #06b6d4;
}

.card-submit:hover .home-card-icon {
    background: linear-gradient(135deg, var(--accent-color), #0d9488);
    color: white;
    transform: scale(1.1) rotate(-5deg);
}

.card-kb:hover .home-card-icon {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    color: white;
    transform: scale(1.1) rotate(-5deg);
}

.card-analytics:hover .home-card-icon {
    background: linear-gradient(135deg, #06b6d4, #0891b2);
    color: white;
    transform: scale(1.1) rotate(-5deg);
}

.home-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0 0 0.5rem 0;
}

.home-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.5;
    flex-grow: 1;
}

.card-arrow {
    display: inline-block;
    margin-top: 1rem;
    font-size: 1.5rem;
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateX(-10px);
}

.card-submit .card-arrow { color: var(--accent-color); }
.card-kb .card-arrow { color: #8b5cf6; }
.card-analytics .card-arrow { color: #06b6d4; }

.home-card:hover .card-arrow {
    opacity: 1;
    transform: translateX(0);
}

/* Responsive */
@media (max-width: 900px) {
    .speech-bubble {
        display: none;
    }
}

@media (max-width: 768px) {
    .home-cards {
        grid-template-columns: 1fr;
    }
    
    .home-title {
        font-size: 1.75rem;
    }
    
    .agent-badges {
        gap: 0.5rem;
    }
    
    .agent-badge {
        padding: 0.5rem 0.75rem;
    }
    
    .robot {
        transform: scale(0.8);
    }
}

.quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-top: 24px;
}

.quick-action-btn {
  padding: 8px 16px;
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 24px;
  color: var(--text-muted);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.quick-action-btn:hover {
  background-color: var(--bg-sidebar-hover);
  color: var(--text-primary);
  border-color: var(--accent);
}

/* =====================================================
   MESSAGES / CONVERSATION
   ===================================================== */

.message-content {
  white-space: pre-line;
  line-height: 1.4;
}

.message-content strong {
  color: var(--text-primary);
}

.message-content ul,
.message-content ol {
  margin: 8px 0;
  padding-left: 20px;
}

.message-content li {
  margin-bottom: 4px;
}

/* =====================================================
   ACTION BUTTONS GROUP
   ===================================================== */

.action-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}

/* =====================================================
   MOBILE STYLES
   ===================================================== */

.mobile-header {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 56px;
  background-color: var(--bg-sidebar);
  border-bottom: 1px solid var(--border);
  padding: 0 16px;
  align-items: center;
  justify-content: space-between;
  z-index: 99;
}

.mobile-header-logo {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mobile-header-logo svg {
  width: 28px;
  height: 28px;
}

.mobile-header-logo span {
  color: var(--accent);
  font-weight: 700;
  font-size: 15px;
}

.mobile-menu-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 8px;
}

.mobile-menu-btn svg {
  width: 24px;
  height: 24px;
}

.mobile-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 99;
}

.mobile-overlay.active {
  display: block;
}

@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-100%);
    width: var(--sidebar-width);
  }
  
  .sidebar.mobile-open {
    transform: translateX(0);
  }
  
  .sidebar.collapsed {
    width: var(--sidebar-width);
  }
  
  .sidebar.collapsed .sidebar-title,
  .sidebar.collapsed .nav-item-label {
    display: block;
  }
  
  .sidebar.collapsed .sidebar-header {
    justify-content: flex-start;
    padding: 16px;
  }
  
  .sidebar.collapsed .nav-item {
    justify-content: flex-start;
    padding: 12px 16px;
  }
  
  .mobile-header {
    display: flex;
  }
  
  .main-content {
    margin-left: 0;
    padding-top: 56px;
  }
  
  .sidebar.collapsed ~ .main-content {
    margin-left: 0;
  }
  
  .page-content {
    padding: 16px;
  }
  
  .home-container {
    padding: 16px;
    min-height: calc(100vh - 250px);
  }
  
  .home-greeting h1 {
    font-size: 24px;
  }
  
  .action-buttons {
    flex-direction: column;
  }
  
  .action-buttons .btn {
    width: 100%;
    justify-content: center;
  }
}

/* =====================================================
   KNOWLEDGE BASE PAGE
   ===================================================== */

.kb-search {
  margin-bottom: 24px;
}

.kb-search .form-input {
  padding: 14px 16px;
  font-size: 15px;
}

.kb-entry {
  margin-bottom: 16px;
}

.kb-entry-header {
  cursor: pointer;
}

.kb-entry-title {
  font-weight: 600;
  color: var(--text-primary);
}

.kb-entry-meta {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* =====================================================
   ANALYTICS PAGE
   ===================================================== */

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  text-align: center;
}

.stat-value {
  font-size: 32px;
  font-weight: 700;
  color: var(--accent);
}

.stat-label {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* =====================================================
   PROFILE PAGE
   ===================================================== */

.profile-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.profile-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background-color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 24px;
  font-weight: 700;
}

.profile-info h2 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
}

.profile-info p {
  font-size: 14px;
  color: var(--text-muted);
}

/* =====================================================
   UTILITIES
   ===================================================== */

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

.mb-1 { margin-bottom: 4px; }
.mb-2 { margin-bottom: 8px; }
.mb-3 { margin-bottom: 12px; }
.mb-4 { margin-bottom: 16px; }
.mb-6 { margin-bottom: 24px; }

.mt-2 { margin-top: 8px; }
.mt-4 { margin-top: 16px; }

.flex { display: flex; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.gap-4 { gap: 16px; }

.w-full { width: 100%; }
.text-center { text-align: center; }
.text-sm { font-size: 14px; }
.text-xs { font-size: 12px; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }

.hidden { display: none; }

@media (min-width: 768px) {
  .md\:flex { display: flex; }
  .md\:hidden { display: none; }

  /* Conversation centering and styling */
.conversation {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.conversation .card {
    border-radius: 0 !important;
    border: none !important;
    border-bottom: 1px solid var(--border-color) !important;
    background: transparent !important;
    margin: 0 !important;
    margin-bottom: 0 !important;
}

.conversation .card:first-child {
    border-top: 1px solid var(--border-color) !important;
}

.conversation .card-header {
    background: transparent !important;
    padding: 1rem 1.25rem 0.5rem !important;
    border: none !important;
    border-bottom: none !important;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.conversation .card-body {
    padding: 0 1.25rem 1rem 3.25rem !important;
}

.conversation .agent-avatar {
    width: 32px;
    height: 32px;
    min-width: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.85rem;
    color: white;
}

.conversation .agent-avatar.kb { background: linear-gradient(135deg, #6366f1, #8b5cf6); }
.conversation .agent-avatar.lola { background: linear-gradient(135deg, #f59e0b, #f97316); }
.conversation .agent-avatar.software { background: linear-gradient(135deg, #f97316, #ef4444); }
.conversation .agent-avatar.hardware { background: linear-gradient(135deg, #10b981, #059669); }
.conversation .agent-avatar.network { background: linear-gradient(135deg, #3b82f6, #1d4ed8); }
.conversation .agent-avatar.coordinator { background: linear-gradient(135deg, #6b7280, #4b5563); }
.conversation .agent-avatar.user { background: linear-gradient(135deg, var(--accent-color), #0d9488); }

.conversation .card-header span.font-semibold {
    font-size: 0.95rem;
    color: var(--text-primary);
}

/* Message content tighter spacing */
.conversation .message-content {
    line-height: 1.5;
    color: var(--text-secondary);
}

.conversation .message-content p {
    margin: 0.4rem 0;
}

.conversation .message-content ol,
.conversation .message-content ul {
    margin: 0.4rem 0;
    padding-left: 1.25rem;
}

.conversation .message-content li {
    margin: 0.2rem 0;
}

/* Light mode adjustments */
[data-theme="light"] .conversation .card {
    border-bottom-color: #d1d5db !important;
}

[data-theme="light"] .conversation .card:first-child {
    border-top-color: #d1d5db !important;
}

.issue-banner {
    max-width: 800px;
    margin: 0 auto 1.5rem auto;
}

.card-header-accent {
    max-width: 800px;
    margin: 0 auto;
}

/* Center follow-up and resolution sections */
.mb-6 {
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

}/* Home page styles */
.home-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem 1rem;
    text-align: center;
}

.home-welcome {
    margin-bottom: 3rem;
}

.home-title {
    font-size: 2.5rem;
    font-weight: 300;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.home-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
}

.home-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.home-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.2s ease;
}

.home-card:hover {
    border-color: var(--accent-color);
    transform: translateY(-2px);
}

.home-card-icon {
    width: 60px;
    height: 60px;
    background: var(--accent-color);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    color: white;
}

.home-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.home-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0;
}/* Knowledge Base page styles */
.kb-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 1rem;
}

.page-title {
    font-size: 1.75rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.search-form .search-row {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.search-input {
    flex: 1;
    min-width: 200px;
}

.form-select {
    padding: 0.75rem 1rem;
    background-color: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    min-width: 150px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

.form-select option {
    background-color: #1a1a1a;
    color: #ffffff;
}

/* For webkit browsers (Chrome, Safari, Edge) */
.form-select::-webkit-scrollbar {
    background: var(--bg-tertiary);
}

/* Light mode dropdown fix */
[data-theme="light"] .form-select option {
    background-color: #ffffff;
    color: #1a1a1a;
}

.filter-clear {
    margin-top: 0.5rem;
}

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

.category-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1rem;
    text-align: center;
    text-decoration: none;
    transition: all 0.2s ease;
}

.category-card:hover {
    border-color: var(--accent-color);
    transform: translateY(-2px);
}

.category-name {
    display: block;
    font-weight: 600;
    color: var(--text-primary);
}

.category-count {
    display: block;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.search-results-info {
    background: var(--accent-color);
    color: white;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.kb-table-container {
    overflow-x: auto;
    margin-bottom: 1.5rem;
}

.kb-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
}

.kb-table th {
    padding: 1rem;
    text-align: left;
    background: var(--accent-color);
    color: white;
    font-weight: 600;
    border-bottom: 2px solid var(--border-color);
}

.kb-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}
.kb-table tbody tr {
    background: var(--bg-secondary);
}

.kb-table tbody tr:nth-child(even) {
    background: var(--bg-tertiary);
}

.kb-table tbody tr:hover {
    background: var(--border-color);
}

.kb-table tbody tr:hover {
    background: var(--bg-tertiary);
}

.kb-table tr:hover {
    background: var(--bg-secondary);
}

.issue-cell {
    max-width: 400px;
}

.categories-cell {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.category-badge {
    padding: 0.35rem 0.75rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 500;
}

.category-badge.category-general { background: #6b7280; color: white; }
.category-badge.category-network { background: #8b5cf6; color: white; }
.category-badge.category-hardware { background: #f59e0b; color: white; }
.category-badge.category-software { background: #10b981; color: white; }
.category-badge.category-email { background: #ef4444; color: white; }
.category-badge.category-mobile { background: #3b82f6; color: white; }

.sort-header {
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.sort-header:hover {
    color: #d0d0d0;
}

.sort-icon {
    font-size: 0.75rem;
    opacity: 0.7;
}

.empty-state {
    text-align: center;
    padding: 3rem;
    color: var(--text-secondary);
}

.page-actions {
    margin-top: 1.5rem;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}/* KB Entry page styles */
.kb-entry-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 1rem;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.breadcrumb a {
    color: var(--accent-color);
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.kb-entry-card {
    background: var(--bg-secondary);
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    overflow: hidden;
}

[data-theme="dark"] .kb-entry-card {
    border: 2px solid #3a3a3a;
}

.kb-entry-header {
    background: var(--accent-color) !important;
    padding: 1.25rem 1.5rem;
}

.kb-entry-header h2 {
    margin: 0;
    color: white;
    font-size: 1.5rem;
}

.kb-entry-body {
    padding: 1.5rem;
}

.kb-section {
    margin-bottom: 1.5rem;
}

.kb-section h4 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.kb-content-box {
    background: var(--bg-tertiary);
    padding: 1rem;
    border-radius: 8px;
    border: 2px solid #e0e0e0;
    line-height: 1.4;
}

[data-theme="dark"] .kb-content-box {
    border: 2px solid #3a3a3a;
}

.solution-box {
    white-space: pre-wrap;
}

.kb-meta {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.kb-meta-item h5 {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.kb-meta-item p {
    margin: 0;
    color: var(--text-secondary);
}

.kb-categories {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.kb-entry-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid var(--border-color);
    background: var(--bg-tertiary);
}

.btn-secondary {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--border-color);
}

/* Analytics page Bootstrap compatibility */
.row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -0.5rem;
}

.col-md-3 {
    flex: 0 0 25%;
    max-width: 25%;
    padding: 0 0.5rem;
}

.col-md-6 {
    flex: 0 0 50%;
    max-width: 50%;
    padding: 0 0.5rem;
}

.mb-4 {
    margin-bottom: 1.5rem;
}

.mb-0 {
    margin-bottom: 0;
}

.text-center {
    text-align: center;
}

.metric-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1.5rem;
}

.text-primary { color: #3b82f6; }
.text-success { color: #10b981; }
.text-info { color: #06b6d4; }
.text-warning { color: #f59e0b; }

.d-flex {
    display: flex;
}

.justify-content-between {
    justify-content: space-between;
}

.align-items-center {
    align-items: center;
}

/* Responsive for analytics */
@media (max-width: 768px) {
    .col-md-3, .col-md-6 {
        flex: 0 0 100%;
        max-width: 100%;
    }
}

/* Analytics page layout */
.analytics-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 1rem;
}

/* Make logo clickable */
.logo-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: var(--accent-color);
}

.logo-link:hover {
    opacity: 0.9;
}

/* ROI Calculator banner - use teal */
/* ROI Calculator - Consolidated */
.roi-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
}

.roi-card .card-header {
    background-color: #14b8a6 !important;
    color: #ffffff !important;
    padding: 1.25rem 2rem;
}

.roi-card .card-header h5 {
    color: #ffffff !important;
    margin: 0;
    font-size: 1.25rem;
}

.roi-card .card-body {
    padding: 2rem;
}

.roi-card h4 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.roi-card h6 {
    margin-bottom: 1rem;
}

.roi-card p {
    margin-bottom: 0.5rem;
}

.roi-card .row {
    margin-bottom: 1.5rem;
}

.roi-card .col-md-3,
.roi-card .col-md-4 {
    padding: 1rem;
}

.roi-card hr {
    margin: 1.5rem 0;
    border-color: var(--border-color);
}

.roi-card small {
    display: block;
    margin-top: 0.25rem;
    opacity: 0.7;
}

/* ROI header fix for light mode */
.roi-card .card-header {
    background-color: var(--accent-color) !important;
    color: white !important;
}

.roi-card .card-header h5 {
    color: white !important;
}

/* Profile Page */
.profile-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 1.5rem;
}

.profile-container .row {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}

.profile-container .col-md-8 {
    flex: 0 0 55%;
    max-width: 55%;
    padding: 0;
}

.profile-container .col-md-4 {
    flex: 0 0 40%;
    max-width: 40%;
    padding: 0;
}

.profile-container .card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.profile-container .card-header {
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 1.5rem;
}

.profile-container .card-header h5 {
    margin: 0;
    color: var(--text-primary);
}

.profile-container .card-body {
    padding: 1.5rem;
}

.profile-container .form-group {
    margin-bottom: 1rem;
}

.profile-container .form-control {
    width: 100%;
    padding: 0.75rem;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-primary);
}

@media (max-width: 768px) {
    .profile-container .row {
        flex-direction: column;
    }
    
    .profile-container .col-md-8,
    .profile-container .col-md-4 {
        flex: 0 0 100%;
        max-width: 100%;
    }
}

/* ============================================
   AUTHENTICATION PAGES (Login/Register)
   ============================================ */

.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
    overflow: hidden;
}
/* Auth card - Registration/Login */
.auth-card {
    background: #1e1e1e;
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 2.5rem;
    width: 100%;
    max-width: 560px;
    position: relative;
    z-index: 1;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

[data-theme="light"] .auth-card {
    background: #ffffff;
}

/* Mini Robot for Auth Pages */
.auth-robot {
    display: flex;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.mini-robot {
    position: relative;
    animation: robot-hover 3s ease-in-out infinite;
}

.mini-antenna {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 3px;
    height: 12px;
    background: linear-gradient(to bottom, var(--accent-color), #0d9488);
    border-radius: 2px;
}

.mini-antenna-ball {
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 10px;
    height: 10px;
    background: var(--accent-color);
    border-radius: 50%;
    animation: antenna-glow 1.5s ease-in-out infinite;
    box-shadow: 0 0 10px var(--accent-color);
}

.mini-head {
    width: 60px;
    height: 45px;
    background: linear-gradient(135deg, #374151, #1f2937);
    border-radius: 15px 15px 12px 12px;
    border: 2px solid var(--accent-color);
    position: relative;
    box-shadow: 0 5px 15px rgba(20, 184, 166, 0.2);
}

[data-theme="light"] .mini-head {
    background: linear-gradient(135deg, #e5e7eb, #d1d5db);
}

.mini-eyes {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding-top: 10px;
}

.mini-eye {
    width: 14px;
    height: 16px;
    background: #1a1a2e;
    border-radius: 5px;
    position: relative;
    animation: blink 4s infinite;
}

[data-theme="light"] .mini-eye {
    background: #374151;
}

.mini-pupil {
    position: absolute;
    bottom: 3px;
    left: 50%;
    transform: translateX(-50%);
    width: 7px;
    height: 7px;
    background: var(--accent-color);
    border-radius: 50%;
    box-shadow: 0 0 8px var(--accent-color);
}

.mini-mouth {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 6px;
    border: 2px solid var(--accent-color);
    border-top: none;
    border-radius: 0 0 10px 10px;
}

/* Auth Header */
.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-header h1 {
    font-size: 1.75rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 0.5rem 0;
}

.auth-header p {
    color: var(--text-secondary);
    margin: 0;
}

/* Auth Form */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.form-row {
    display: flex;
    gap: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group.half {
    flex: 1;
}

.auth-form label {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-primary);
}

.auth-form .form-control {
    padding: 0.875rem 1rem;
    background: var(--bg-primary);
    border: 2px solid #3a3a3a;
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 1rem;
    transition: all 0.3s ease;
}

[data-theme="light"] .auth-form .form-control {
    border: 2px solid #d0d0d0;
}

.auth-form .form-control:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.15);
}

.auth-form select.form-control {
    cursor: pointer;
}

.form-hint {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Submit Button */
.btn-submit {
    appearance: none;
    -webkit-appearance: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem;
    background: linear-gradient(135deg, var(--accent-color), #0d9488);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 0.5rem;
}

.auth-form .btn-submit span {
    color: white;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(20, 184, 166, 0.3);
}

.btn-submit svg {
    transition: transform 0.3s ease;
}

.btn-submit:hover svg {
    transform: translateX(4px);
}

/* Auth Footer */
.auth-footer {
    text-align: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
}

.auth-footer p {
    color: var(--text-secondary);
    margin: 0;
}

.auth-footer a {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 500;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* Alert Messages */
.auth-card .alert {
    padding: 0.875rem 1rem;
    border-radius: 10px;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.auth-card .alert-danger {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

.auth-card .alert-success {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #10b981;
}

/* Responsive */
@media (max-width: 480px) {
    .auth-card {
        padding: 1.5rem;
    }
    
    .form-row {
        flex-direction: column;
        gap: 1.25rem;
    }
    
    .auth-header h1 {
        font-size: 1.5rem;
    }

    /* Fix for btn-submit visibility in light mode */
button.btn-submit {
    appearance: none !important;
    -webkit-appearance: none !important;
    background: linear-gradient(135deg, #14B8A6, #0d9488) !important;
    color: white !important;
}

button.btn-submit span {
    color: white !important;
}

button.btn-submit svg {
    stroke: white !important;
}

/* Analytics Page */
.analytics-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.5rem;
}

.analytics-container h2 {
    color: var(--text-primary);
    margin-bottom: 1.5rem;
}

.analytics-container .card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
}

.analytics-container .card-header {
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border-color);
    color: var(--text-primary);
}

.analytics-container .card-body {
    color: var(--text-primary);
}

.analytics-container .metric-card h3 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.analytics-container .table {
    color: var(--text-primary);
}

.analytics-container .table th,
.analytics-container .table td {
    border-color: var(--border-color);
}

/* ROI Card - Teal header */
.analytics-container .card-header.bg-success {
    background-color: var(--accent-color) !important;
    color: white !important;
}

.analytics-container .card-header.bg-success h5 {
    color: white !important;
    margin: 0;
}

/* Google Sign-In Button for Auth Pages */
.auth-card .divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 1.5rem 0;
}

.auth-card .divider::before,
.auth-card .divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid var(--border-color);
}

.auth-card .divider span {
    padding: 0 15px;
    color: var(--text-muted);
    font-size: 14px;
}

.auth-card .btn-google {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 12px 20px;
    background-color: white;
    color: #757575;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-weight: 500;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s, box-shadow 0.3s;
    text-decoration: none;
}

.auth-card .btn-google:hover {
    background-color: #f8f9fa;
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
    text-decoration: none;
    color: #757575;
}

/* Code block styling for markdown */
.message-content {
    line-height: 1.4;
}

.message-content p {
    margin: 0.3rem 0;
}

.message-content ol,
.message-content ul {
    margin: 0.3rem 0;
    padding-left: 1.5rem;
}

.message-content li {
    margin: 0.15rem 0;
}

.message-content pre {
    background: #1a1a2e;
    border: 1px solid #3a3a5a;
    border-radius: 8px;
    padding: 1rem;
    overflow-x: auto;
    margin: 0.75rem 0;
}

.message-content pre code {
    color: #00ff88;
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 0.85rem;
    line-height: 1.4;
    white-space: pre;
}

.message-content code {
    background: rgba(0, 255, 136, 0.1);
    color: #00ff88;
    padding: 0.15rem 0.4rem;
    border-radius: 4px;
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 0.85em;
}

.message-content pre code {
    background: transparent;
    padding: 0;
}

/* Light mode */
[data-theme="light"] .message-content pre {
    background: #f8f8f8;
    border-color: #e0e0e0;
}

[data-theme="light"] .message-content pre code,
[data-theme="light"] .message-content code {
    color: #d63384;
}

[data-theme="light"] .message-content code {
    background: rgba(214, 51, 132, 0.1);
}

/* Light mode gradient text fix */
[data-theme="light"] .gradient-text {
    background: linear-gradient(135deg, #0d7377, #0891b2, #7c3aed);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* KB Entry header fix for light mode */
[data-theme="light"] .card-header.bg-primary {
    background: linear-gradient(135deg, #0d9488, #0891b2) !important;
    color: white !important;
}

[data-theme="light"] .card-header.bg-primary h3 {
    color: white !important;
}

/* KB Entry Header Light Mode Fix */
[data-theme="light"] .kb-entry-header {
    background: linear-gradient(135deg, #0d9488, #0891b2);
}

[data-theme="light"] .kb-entry-header h2 {
    color: white;
}

/* ============================================
   PRICING PAGE
   ============================================ */

.pricing-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.pricing-header {
    text-align: center;
    margin-bottom: 3rem;
}

.pricing-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.pricing-header p {
    font-size: 1.1rem;
    color: var(--text-secondary);
}

.trial-banner {
    display: inline-block;
    background: rgba(20, 184, 166, 0.15);
    border: 1px solid var(--accent-color);
    border-radius: 8px;
    padding: 0.75rem 1.5rem;
    margin-top: 1rem;
    color: var(--text-primary);
}

.trial-banner.expired {
    background: rgba(239, 68, 68, 0.15);
    border-color: #ef4444;
}

/* 3-column grid for pricing cards */
.pricing-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 3rem;
}

@media (max-width: 992px) {
    .pricing-cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .pricing-cards {
        grid-template-columns: 1fr;
    }
}

.pricing-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2rem;
    position: relative;
    display: flex;
    flex-direction: column;
}

[data-theme="light"] .pricing-card {
    border: 2px solid #e0e0e0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.pricing-card.featured {
    border: 2px solid var(--accent-color);
}

/* Most Popular badge - INSIDE the card */
.popular-badge {
    position: absolute;
    top: -1px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent-color);
    color: white;
    padding: 0.35rem 1rem;
    border-radius: 0 0 8px 8px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.plan-header {
    text-align: center;
    margin-bottom: 1.5rem;
    padding-top: 1rem;
}

.plan-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    color: var(--text-primary);
}

.plan-subtitle {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.plan-price {
    text-align: center;
    margin-bottom: 1rem;
}

.plan-price .price {
    font-size: 3rem;
    font-weight: 700;
    color: var(--text-primary);
}

.plan-price .period {
    font-size: 1rem;
    color: var(--text-secondary);
}

.plan-note {
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.plan-features {
    list-style: none;
    padding: 0;
    margin: 0 0 1.5rem 0;
    flex-grow: 1;
}

.plan-features li {
    padding: 0.5rem 0;
    color: var(--text-primary);
    font-size: 0.95rem;
}

[data-theme="light"] .plan-features li {
    color: #333;
}

.btn-plan {
    display: block;
    width: 100%;
    padding: 0.875rem;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    background: transparent;
    color: var(--text-primary);
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-plan:hover {
    border-color: var(--accent-color);
    color: var(--accent-color);
}

.btn-plan.featured {
    background: var(--accent-color);
    border-color: var(--accent-color);
    color: white;
}

.btn-plan.featured:hover {
    background: #0d9488;
    border-color: #0d9488;
    color: white;
}

.btn-plan.current {
    background: var(--bg-card-header);
    cursor: default;
    opacity: 0.7;
}

[data-theme="light"] .btn-plan {
    border-color: #ccc;
    color: #333;
}

[data-theme="light"] .btn-plan:hover {
    border-color: var(--accent-color);
    color: var(--accent-color);
}

/* FAQ Section */
.pricing-faq {
    margin-top: 3rem;
}

.pricing-faq h2 {
    text-align: center;
    font-size: 1.75rem;
    margin-bottom: 2rem;
    color: var(--text-primary);
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

@media (max-width: 768px) {
    .faq-grid {
        grid-template-columns: 1fr;
    }
}

.faq-item {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.5rem;
}

[data-theme="light"] .faq-item {
    border: 1px solid #e0e0e0;
}

.faq-item h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.faq-item p {
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.5;
    margin: 0;
}

[data-theme="light"] .faq-item h3 {
    color: #222;
}

[data-theme="light"] .faq-item p {
    color: #555;
}

/* Flash Messages */
.flash-message {
    margin: 1rem;
    padding: 1rem;
    border-radius: 8px;
    color: white;
}

.flash-success {
    background: #10b981;
}

.flash-error {
    background: #ef4444;
}

.flash-info {
    background: #3b82f6;
}

.flash-warning {
    background: #f59e0b;
}
}