/* ============================================
   FixItIA - Styles
   Premium Automation & AI Website
   ============================================ */

/* ============================================
   CSS Variables & Design Tokens
   ============================================ */
:root {
  /* Colors */
  --bg-primary: #0a0f1c;
  --bg-secondary: #0d1528;
  --bg-tertiary: #1a2744;
  --primary: #00d4ff;
  --primary-dark: #00a8cc;
  --secondary: #1e3a5f;
  --accent: #4facfe;
  --accent-purple: #667eea;
  --text-primary: #ffffff;
  --text-secondary: #b8c5d6;
  --text-muted: #6b7a8f;
  --success: #00d26a;
  --warning: #ffc107;

  /* Gradients */
  --gradient-primary: linear-gradient(135deg, #00d4ff 0%, #4facfe 50%, #667eea 100%);
  --gradient-dark: linear-gradient(180deg, #0a0f1c 0%, #1a2744 100%);
  --gradient-card: linear-gradient(145deg, rgba(30, 58, 95, 0.4) 0%, rgba(13, 21, 40, 0.6) 100%);

  /* Glassmorphism */
  --glass-bg: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.1);
  --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);

  /* Typography */
  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-heading: 'Inter', sans-serif;

  /* Spacing */
  --section-padding: 100px 0;
  --container-width: 1200px;

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;

  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
}

/* ============================================
   Reset & Base Styles
   ============================================ */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-primary);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition-normal);
}

ul,
ol {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ============================================
   Utility Classes
   ============================================ */
.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: var(--section-padding);
  position: relative;
}

.text-gradient {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 32px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  border: none;
  transition: var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: var(--gradient-primary);
  color: var(--bg-primary);
  box-shadow: 0 4px 20px rgba(0, 212, 255, 0.3);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(0, 212, 255, 0.5);
}

.btn-secondary {
  background: transparent;
  color: var(--primary);
  border: 2px solid var(--primary);
}

.btn-secondary:hover {
  background: rgba(0, 212, 255, 0.1);
  transform: translateY(-3px);
}

.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 60px;
}

.section-title {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 700;
  margin-bottom: 20px;
  letter-spacing: -0.02em;
}

.section-subtitle {
  font-size: 1.125rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ============================================
   Animations
   ============================================ */
@keyframes float {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-20px);
  }
}

@keyframes pulse-glow {

  0%,
  100% {
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.3);
  }

  50% {
    box-shadow: 0 0 40px rgba(0, 212, 255, 0.6);
  }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(40px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes gradient-shift {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

.animate-on-scroll {
  opacity: 0;
  transform: translateY(40px);
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   Header & Navigation
   ============================================ */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 20px 0;
  transition: var(--transition-normal);
}

.header.scrolled {
  background: rgba(10, 15, 28, 0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--glass-border);
  padding: 15px 0;
}

.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo img {
  height: 50px;
  width: auto;
}

.logo-text {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.nav {
  display: flex;
  align-items: center;
  gap: 40px;
}

.nav-links {
  display: flex;
  gap: 32px;
}

.nav-link {
  font-weight: 500;
  color: var(--text-secondary);
  position: relative;
  padding: 8px 0;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient-primary);
  transition: var(--transition-normal);
}

.nav-link:hover {
  color: var(--text-primary);
}

.nav-link:hover::after {
  width: 100%;
}

.nav-cta .btn {
  padding: 12px 24px;
  font-size: 0.9rem;
}

.mobile-menu-btn {
  display: none;
  flex-direction: column;
  gap: 6px;
  cursor: pointer;
  padding: 10px;
}

.mobile-menu-btn span {
  width: 28px;
  height: 2px;
  background: var(--text-primary);
  transition: var(--transition-normal);
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding-top: 100px;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
}

.hero-gradient {
  position: absolute;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.3;
  animation: float 8s ease-in-out infinite;
}

.hero-gradient-1 {
  background: var(--primary);
  top: -200px;
  right: -100px;
}

.hero-gradient-2 {
  background: var(--accent-purple);
  bottom: -200px;
  left: -100px;
  animation-delay: -4s;
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0, 212, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 212, 255, 0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse at center, black 20%, transparent 70%);
}

.hero .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.hero-content {
  animation: slideUp 1s ease-out;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 50px;
  font-size: 0.875rem;
  color: var(--primary);
  margin-bottom: 24px;
}

.hero-badge-dot {
  width: 8px;
  height: 8px;
  background: var(--success);
  border-radius: 50%;
  animation: pulse-glow 2s infinite;
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 24px;
  letter-spacing: -0.03em;
}

.hero-description {
  font-size: 1.25rem;
  color: var(--text-secondary);
  margin-bottom: 40px;
  max-width: 500px;
  line-height: 1.7;
}

.hero-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-stats {
  display: flex;
  gap: 40px;
  margin-top: 60px;
  padding-top: 40px;
  border-top: 1px solid var(--glass-border);
}

.hero-stat {
  text-align: left;
}

.hero-stat-value {
  font-size: 2.5rem;
  font-weight: 700;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-stat-label {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  animation: fadeIn 1.2s ease-out;
}

.hero-image {
  width: 100%;
  max-width: 500px;
  animation: float 6s ease-in-out infinite;
}

.hero-image img {
  width: 100%;
  filter: drop-shadow(0 20px 60px rgba(0, 212, 255, 0.3));
}

/* ============================================
   Benefits Section
   ============================================ */
.benefits {
  background: var(--bg-secondary);
  position: relative;
}

.benefits::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1px;
  height: 100px;
  background: linear-gradient(to bottom, transparent, var(--primary));
}

.benefits-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}

.benefit-card {
  background: var(--gradient-card);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 40px 30px;
  transition: var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.benefit-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-primary);
  transform: scaleX(0);
  transform-origin: left;
  transition: var(--transition-normal);
}

.benefit-card:hover {
  transform: translateY(-8px);
  border-color: rgba(0, 212, 255, 0.3);
}

.benefit-card:hover::before {
  transform: scaleX(1);
}

.benefit-icon {
  width: 70px;
  height: 70px;
  background: linear-gradient(135deg, rgba(0, 212, 255, 0.2), rgba(102, 126, 234, 0.2));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  font-size: 2rem;
}

.benefit-title {
  font-size: 1.375rem;
  font-weight: 600;
  margin-bottom: 12px;
}

.benefit-description {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.7;
}

/* ============================================
   How It Works Section
   ============================================ */
.how-it-works {
  position: relative;
}

.timeline {
  max-width: 800px;
  margin: 0 auto;
  position: relative;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--primary), var(--accent-purple));
  transform: translateX(-50%);
}

.timeline-item {
  display: flex;
  align-items: center;
  margin-bottom: 60px;
  position: relative;
}

.timeline-item:nth-child(odd) {
  flex-direction: row-reverse;
}

.timeline-item:nth-child(odd) .timeline-content {
  text-align: right;
  padding-right: 80px;
  padding-left: 0;
}

.timeline-item:nth-child(even) .timeline-content {
  padding-left: 80px;
}

.timeline-number {
  width: 60px;
  height: 60px;
  background: var(--gradient-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--bg-primary);
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  box-shadow: 0 0 30px rgba(0, 212, 255, 0.4);
}

.timeline-content {
  flex: 1;
  position: relative;
  z-index: 1;
  max-width: calc(50% - 50px);
}

.timeline-title {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 12px;
}

.timeline-description {
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ============================================
   Videos Section
   ============================================ */
.videos {
  background: var(--bg-secondary);
}

.videos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 30px;
}

.video-card {
  background: var(--gradient-card);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: var(--transition-normal);
}

.video-card:hover {
  transform: translateY(-5px);
  border-color: rgba(0, 212, 255, 0.3);
}

.video-wrapper {
  position: relative;
  padding-bottom: 56.25%;
  /* 16:9 aspect ratio */
  height: 0;
  overflow: hidden;
}

.video-wrapper iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.video-placeholder {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--secondary), var(--bg-tertiary));
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.video-play-btn {
  width: 80px;
  height: 80px;
  background: var(--gradient-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-normal);
}

.video-play-btn::after {
  content: '';
  width: 0;
  height: 0;
  border-left: 24px solid var(--bg-primary);
  border-top: 14px solid transparent;
  border-bottom: 14px solid transparent;
  margin-left: 6px;
}

.video-placeholder:hover .video-play-btn {
  transform: scale(1.1);
  box-shadow: 0 0 40px rgba(0, 212, 255, 0.5);
}

.video-info {
  padding: 24px;
}

.video-title {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.video-description {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* ============================================
   Use Cases Section
   ============================================ */
.use-cases {
  position: relative;
}

.use-cases-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}

.use-case-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.use-case-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--gradient-primary);
  opacity: 0;
  transition: var(--transition-normal);
  z-index: -1;
}

.use-case-card:hover {
  transform: translateY(-5px) scale(1.02);
  border-color: var(--primary);
}

.use-case-icon {
  font-size: 2.5rem;
  margin-bottom: 20px;
}

.use-case-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 12px;
}

.use-case-description {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.7;
}

.use-case-tag {
  display: inline-block;
  margin-top: 16px;
  padding: 6px 14px;
  background: rgba(0, 212, 255, 0.1);
  border: 1px solid rgba(0, 212, 255, 0.2);
  border-radius: 50px;
  font-size: 0.8rem;
  color: var(--primary);
}

/* ============================================
   CTA Section
   ============================================ */
.cta {
  background: var(--bg-secondary);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.cta-gradient {
  position: absolute;
  width: 100%;
  height: 100%;
  background: radial-gradient(ellipse at center, rgba(0, 212, 255, 0.15) 0%, transparent 70%);
}

.cta .container {
  position: relative;
  z-index: 1;
}

.cta-box {
  background: var(--gradient-card);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
  padding: 80px 60px;
  max-width: 800px;
  margin: 0 auto;
  position: relative;
  overflow: hidden;
}

.cta-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-primary);
}

.cta-title {
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 700;
  margin-bottom: 20px;
  letter-spacing: -0.02em;
}

.cta-description {
  font-size: 1.125rem;
  color: var(--text-secondary);
  margin-bottom: 40px;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

.cta-buttons {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

/* ============================================
   Footer
   ============================================ */
.footer {
  background: var(--bg-primary);
  padding: 60px 0 30px;
  border-top: 1px solid var(--glass-border);
}

.footer-content {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 60px;
  margin-bottom: 60px;
}

.footer-brand {
  max-width: 300px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.footer-logo img {
  height: 45px;
}

.footer-description {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 24px;
}

.footer-social {
  display: flex;
  gap: 12px;
}

.social-link {
  width: 44px;
  height: 44px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  transition: var(--transition-normal);
}

.social-link:hover {
  background: var(--primary);
  color: var(--bg-primary);
  transform: translateY(-3px);
}

.footer-column h4 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 24px;
  color: var(--text-primary);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-link {
  color: var(--text-secondary);
  font-size: 0.9rem;
  transition: var(--transition-normal);
}

.footer-link:hover {
  color: var(--primary);
  padding-left: 8px;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 30px;
  border-top: 1px solid var(--glass-border);
}

.footer-copyright {
  color: var(--text-muted);
  font-size: 0.875rem;
}

.footer-legal {
  display: flex;
  gap: 24px;
}

.footer-legal a {
  color: var(--text-muted);
  font-size: 0.875rem;
}

.footer-legal a:hover {
  color: var(--primary);
}

/* ============================================
   Mobile Navigation
   ============================================ */
.mobile-nav {
  position: fixed;
  top: 0;
  right: -100%;
  width: 100%;
  max-width: 400px;
  height: 100vh;
  background: rgba(10, 15, 28, 0.98);
  backdrop-filter: blur(20px);
  z-index: 999;
  padding: 100px 40px 40px;
  transition: var(--transition-normal);
}

.mobile-nav.active {
  right: 0;
}

.mobile-nav-links {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.mobile-nav-link {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-primary);
  transition: var(--transition-normal);
}

.mobile-nav-link:hover {
  color: var(--primary);
  padding-left: 16px;
}

.mobile-nav-close {
  position: absolute;
  top: 30px;
  right: 30px;
  font-size: 2rem;
  cursor: pointer;
  color: var(--text-primary);
}

.mobile-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 998;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition-normal);
}

.mobile-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* ============================================
   Responsive Design
   ============================================ */
@media (max-width: 1024px) {
  .hero .container {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-content {
    order: 1;
  }

  .hero-visual {
    order: 0;
    margin-bottom: 40px;
  }

  .hero-description {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-buttons {
    justify-content: center;
  }

  .hero-stats {
    justify-content: center;
  }

  .footer-content {
    grid-template-columns: 1fr 1fr;
    gap: 40px;
  }
}

@media (max-width: 768px) {

  .nav-links,
  .nav-cta {
    display: none;
  }

  .mobile-menu-btn {
    display: flex;
  }

  .hero-title {
    font-size: 2.25rem;
  }

  .hero-stats {
    flex-direction: column;
    gap: 20px;
    align-items: center;
  }

  .timeline::before {
    left: 30px;
  }

  .timeline-number {
    left: 30px;
    width: 50px;
    height: 50px;
    font-size: 1.25rem;
  }

  .timeline-item,
  .timeline-item:nth-child(odd) {
    flex-direction: column;
    padding-left: 80px;
  }

  .timeline-item:nth-child(odd) .timeline-content,
  .timeline-item:nth-child(even) .timeline-content {
    text-align: left;
    padding: 0;
  }

  .footer-content {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer-brand {
    max-width: 100%;
  }

  .footer-social {
    justify-content: center;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }

  .cta-box {
    padding: 50px 30px;
  }

  .videos-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .section {
    padding: 60px 0;
  }

  .hero {
    min-height: auto;
    padding: 120px 0 60px;
  }

  .btn {
    width: 100%;
    justify-content: center;
  }

  .hero-buttons {
    flex-direction: column;
  }

  .benefits-grid,
  .use-cases-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================
   Chat Widget Styles
   ============================================ */
.chat-widget {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  font-family: var(--font-primary);
}

/* Chat Bubble */
.chat-bubble {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--gradient-primary);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(0, 212, 255, 0.4);
  transition: var(--transition-normal);
  position: relative;
}

.chat-bubble:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 30px rgba(0, 212, 255, 0.6);
}

.chat-bubble svg {
  width: 28px;
  height: 28px;
  color: var(--bg-primary);
  transition: var(--transition-normal);
}

.chat-bubble-icon {
  opacity: 1;
}

.chat-bubble-close {
  position: absolute;
  opacity: 0;
}

.chat-widget.open .chat-bubble-icon {
  opacity: 0;
}

.chat-widget.open .chat-bubble-close {
  opacity: 1;
}

/* Chat Window */
.chat-window {
  position: absolute;
  bottom: 80px;
  right: 0;
  width: 380px;
  height: 500px;
  background: var(--bg-secondary);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px) scale(0.95);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
}

.chat-widget.open .chat-window {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

/* Chat Header */
.chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  background: linear-gradient(135deg, rgba(0, 212, 255, 0.15), rgba(102, 126, 234, 0.15));
  border-bottom: 1px solid var(--glass-border);
}

.chat-header-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.chat-header-avatar {
  width: 40px;
  height: 40px;
  background: var(--gradient-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
}

.chat-header-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.chat-header-subtitle {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin: 2px 0 0 0;
}

.chat-close {
  width: 32px;
  height: 32px;
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: var(--transition-fast);
}

.chat-close:hover {
  background: rgba(255, 255, 255, 0.1);
}

.chat-close svg {
  width: 18px;
  height: 18px;
  color: var(--text-secondary);
}

/* Chat Messages */
.chat-messages {
  flex: 1;
  padding: 16px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.chat-messages::-webkit-scrollbar {
  width: 6px;
}

.chat-messages::-webkit-scrollbar-track {
  background: var(--bg-tertiary);
  border-radius: 3px;
}

.chat-messages::-webkit-scrollbar-thumb {
  background: var(--secondary);
  border-radius: 3px;
}

.chat-message {
  display: flex;
  flex-direction: column;
  max-width: 85%;
  animation: slideUp 0.3s ease-out;
}

.chat-message-user {
  align-self: flex-end;
  align-items: flex-end;
}

.chat-message-assistant {
  align-self: flex-start;
  align-items: flex-start;
}

.chat-message-bubble {
  padding: 12px 16px;
  border-radius: 16px;
  font-size: 0.9rem;
  line-height: 1.5;
  word-wrap: break-word;
}

.chat-message-user .chat-message-bubble {
  background: var(--gradient-primary);
  color: var(--bg-primary);
  border-bottom-right-radius: 4px;
}

.chat-message-assistant .chat-message-bubble {
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border-bottom-left-radius: 4px;
}

.chat-message-time {
  font-size: 0.65rem;
  color: var(--text-muted);
  margin-top: 4px;
  padding: 0 4px;
}

/* Typing Indicator */
.chat-typing {
  display: flex;
  gap: 4px;
  padding: 12px 16px;
  background: var(--bg-tertiary);
  border-radius: 16px;
  border-bottom-left-radius: 4px;
  width: fit-content;
}

.chat-typing-dot {
  width: 8px;
  height: 8px;
  background: var(--text-muted);
  border-radius: 50%;
  animation: typingBounce 1.4s infinite ease-in-out;
}

.chat-typing-dot:nth-child(1) {
  animation-delay: 0s;
}

.chat-typing-dot:nth-child(2) {
  animation-delay: 0.2s;
}

.chat-typing-dot:nth-child(3) {
  animation-delay: 0.4s;
}

@keyframes typingBounce {

  0%,
  80%,
  100% {
    transform: translateY(0);
  }

  40% {
    transform: translateY(-6px);
  }
}

/* Chat Input */
.chat-input-container {
  padding: 12px 16px;
  background: var(--bg-primary);
  border-top: 1px solid var(--glass-border);
}

.chat-input-wrapper {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  background: var(--bg-tertiary);
  border-radius: 24px;
  padding: 8px 12px;
  border: 1px solid var(--glass-border);
  transition: var(--transition-fast);
}

.chat-input-wrapper:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(0, 212, 255, 0.2);
}

.chat-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 0.9rem;
  font-family: var(--font-primary);
  resize: none;
  max-height: 100px;
  line-height: 1.5;
  padding: 4px 0;
}

.chat-input::placeholder {
  color: var(--text-muted);
}

.chat-send {
  width: 36px;
  height: 36px;
  background: var(--gradient-primary);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-fast);
  flex-shrink: 0;
}

.chat-send:hover:not(:disabled) {
  transform: scale(1.1);
}

.chat-send:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.chat-send svg {
  width: 18px;
  height: 18px;
  color: var(--bg-primary);
}

/* Error Message */
.chat-message-error .chat-message-bubble {
  background: rgba(255, 82, 82, 0.2);
  color: #ff5252;
  border: 1px solid rgba(255, 82, 82, 0.3);
}

/* Mobile Styles */
@media (max-width: 480px) {
  .chat-widget {
    bottom: 16px;
    right: 16px;
  }

  .chat-bubble {
    width: 56px;
    height: 56px;
  }

  .chat-window {
    position: fixed;
    bottom: 0;
    right: 0;
    left: 0;
    width: 100%;
    height: 85vh;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    transform: translateY(100%);
  }

  .chat-widget.open .chat-window {
    transform: translateY(0);
  }

  .chat-widget.open .chat-bubble {
    opacity: 0;
    pointer-events: none;
  }
}

/* Chat Header Actions */
.chat-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.chat-new-btn {
  width: 32px;
  height: 32px;
  background: rgba(0, 212, 255, 0.2);
  border: 1px solid rgba(0, 212, 255, 0.4);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-fast);
  font-size: 14px;
}

.chat-new-btn:hover {
  background: rgba(0, 212, 255, 0.4);
  border-color: var(--primary);
  transform: rotate(180deg);
}