/* MP Bot Portfolio - Main Styles */

/* CSS Custom Properties */
:root {
  /* Colors */
  --primary-color: #3b82f6;
  --primary-dark: #1e40af;
  --primary-light: #dbeafe;
  --secondary-color: #6366f1;
  --accent-color: #10b981;
  --warning-color: #f59e0b;
  --error-color: #ef4444;
  
  --bg-primary: #ffffff;
  --bg-secondary: #f8fafc;
  --bg-tertiary: #f1f5f9;
  --bg-dark: #0f172a;
  --bg-dark-secondary: #1e293b;
  
  --text-primary: #1e293b;
  --text-secondary: #64748b;
  --text-tertiary: #94a3b8;
  --text-light: #ffffff;
  
  /* Typography */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', 'SF Mono', Consolas, monospace;
  
  /* Spacing */
  --container-max-width: 1200px;
  --section-padding: 6rem 0;
  --card-padding: 2rem;
  
  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  
  /* Animations */
  --animation-fast: 0.2s ease;
  --animation-normal: 0.3s ease;
  --animation-slow: 0.5s ease;
  
  /* Border Radius */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
}

/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-sans);
  color: var(--text-primary);
  background-color: var(--bg-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: 1rem;
}

h1 { font-size: 3.5rem; }
h2 { font-size: 2.5rem; }
h3 { font-size: 2rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

p {
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color var(--animation-fast);
}

a:hover {
  color: var(--primary-dark);
}

/* Utility Classes */
.container {
  max-width: var(--container-max-width);
  margin: 0 auto;
  padding: 0 2rem;
}

.gradient-text {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

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

.hidden { display: none; }
.visible { display: block; }

/* Loading Screen */
.loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity var(--animation-slow), visibility var(--animation-slow);
}

.loading-screen.fade-out {
  opacity: 0;
  visibility: hidden;
}

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

.loading-spinner {
  width: 3rem;
  height: 3rem;
  border: 3px solid var(--primary-light);
  border-top: 3px solid var(--primary-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 1rem;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Navigation */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(226, 232, 240, 0.5);
  z-index: 1000;
  transition: transform var(--animation-normal);
}

.navbar.hidden {
  transform: translateY(-100%);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 2rem;
  max-width: var(--container-max-width);
  margin: 0 auto;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--text-primary);
}

.nav-brand i {
  font-size: 1.5rem;
  color: var(--primary-color);
}

.nav-menu {
  display: flex;
  gap: 2rem;
}

.nav-link {
  color: var(--text-secondary);
  font-weight: 500;
  transition: color var(--animation-fast);
  position: relative;
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary-color);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -0.5rem;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary-color);
  transition: width var(--animation-fast);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 0.25rem;
  cursor: pointer;
}

.nav-toggle span {
  width: 1.5rem;
  height: 2px;
  background: var(--text-primary);
  transition: transform var(--animation-fast);
}

.scroll-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
  transform-origin: left;
  transform: scaleX(0);
  transition: transform var(--animation-fast);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: var(--radius-md);
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: all var(--animation-fast);
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: var(--primary-color);
  color: var(--text-light);
}

.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-lg);
}

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

.btn-secondary:hover {
  background: var(--primary-color);
  color: var(--text-light);
  transform: translateY(-1px);
}

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
  color: var(--text-light);
}

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  opacity: 0.1;
}

.hero-particles {
  position: absolute;
  width: 100%;
  height: 100%;
  background-image: 
    radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.3) 1px, transparent 1px),
    radial-gradient(circle at 80% 50%, rgba(255, 255, 255, 0.3) 1px, transparent 1px),
    radial-gradient(circle at 40% 20%, rgba(255, 255, 255, 0.2) 1px, transparent 1px),
    radial-gradient(circle at 60% 80%, rgba(255, 255, 255, 0.2) 1px, transparent 1px);
  background-size: 100px 100px, 120px 120px, 80px 80px, 90px 90px;
  animation: float 20s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  33% { transform: translate(30px, -30px) rotate(120deg); }
  66% { transform: translate(-20px, 20px) rotate(240deg); }
}

.hero .container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  position: relative;
  z-index: 2;
}

.hero-content {
  animation: slideInLeft 0.8s ease-out;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-xl);
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 1.5rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.hero-title {
  font-size: 4rem;
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 1.5rem;
}

.hero-description {
  font-size: 1.25rem;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 2rem;
  line-height: 1.6;
}

.hero-stats {
  display: flex;
  gap: 2rem;
  margin-bottom: 2rem;
}

.stat {
  text-align: center;
}

.stat-number {
  display: block;
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-light);
}

.stat-label {
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.8);
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.hero-visual {
  animation: slideInRight 0.8s ease-out;
}

.chat-preview {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(20px);
  border-radius: var(--radius-xl);
  border: 1px solid rgba(255, 255, 255, 0.2);
  overflow: hidden;
  max-width: 400px;
  margin-left: auto;
}

.chat-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  font-weight: 500;
  font-size: 0.875rem;
}

.chat-dots {
  display: flex;
  gap: 0.25rem;
}

.chat-dots span {
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
}

.chat-dots span:nth-child(1) { background: #ff5f56; }
.chat-dots span:nth-child(2) { background: #ffbd2e; }
.chat-dots span:nth-child(3) { background: #27ca3f; }

.chat-messages {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.message {
  padding: 0.75rem 1rem;
  border-radius: var(--radius-lg);
  max-width: 80%;
  font-size: 0.875rem;
}

.user-message {
  background: rgba(59, 130, 246, 0.8);
  margin-left: auto;
}

.bot-message {
  background: rgba(255, 255, 255, 0.1);
  position: relative;
}

.typing-indicator {
  display: flex;
  gap: 0.25rem;
  margin-bottom: 0.5rem;
}

.typing-indicator span {
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.6);
  animation: typing 1.4s ease-in-out infinite;
}

.typing-indicator span:nth-child(2) { animation-delay: 0.2s; }
.typing-indicator span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typing {
  0%, 60%, 100% { transform: scale(1); opacity: 0.5; }
  30% { transform: scale(1.2); opacity: 1; }
}

.typing-text {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.7);
  font-style: italic;
}

/* Section Styles */
.section-header {
  text-align: center;
  margin-bottom: 4rem;
}

.section-title {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.section-subtitle {
  font-size: 1.25rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
}

/* Demo Section */
.demo-section {
  padding: var(--section-padding);
  background: var(--bg-secondary);
}

.demo-content {
  margin-bottom: 4rem;
}

.video-container {
  margin-bottom: 3rem;
}

.video-placeholder {
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, var(--bg-dark), var(--bg-dark-secondary));
  border-radius: var(--radius-xl);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  cursor: pointer;
  transition: transform var(--animation-normal);
  position: relative;
  overflow: hidden;
}

.video-placeholder video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
}

.video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
  z-index: 2;
  cursor: pointer;
  transition: opacity var(--animation-normal);
}

.video-overlay.hidden {
  opacity: 0;
  pointer-events: none;
}

.video-overlay .fa-play-circle,
.video-overlay h3,
.video-overlay p {
  background: rgba(0, 0, 0, 0.3);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-md);
  margin: 0.25rem 0;
  color: var(--text-light);
}

.video-placeholder:hover {
  transform: scale(1.02);
}

.video-placeholder i {
  font-size: 4rem;
  margin-bottom: 1rem;
  color: var(--primary-color);
  position: relative;
  z-index: 2;
  text-shadow: 0 0 10px rgba(0, 0, 0, 0.8);
}

.video-placeholder h3 {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

.video-placeholder p {
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 1.5rem;
}



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

.feature-card {
  background: var(--bg-primary);
  padding: var(--card-padding);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  text-align: center;
  transition: transform var(--animation-normal), box-shadow var(--animation-normal);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}

.feature-icon {
  width: 4rem;
  height: 4rem;
  margin: 0 auto 1rem;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  font-size: 1.5rem;
}

.screenshots-carousel h3 {
  text-align: center;
  margin-bottom: 2rem;
}

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

.screenshot-placeholder {
  position: relative;
  aspect-ratio: 16 / 10;
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: pointer;
  transition: transform var(--animation-normal);
}

.screenshot-placeholder:hover {
  transform: scale(1.05);
}

.screenshot-placeholder img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: linear-gradient(135deg, var(--primary-light), var(--bg-tertiary));
}

.screenshot-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  opacity: 0;
  transition: opacity var(--animation-fast);
}

.screenshot-placeholder:hover .screenshot-overlay {
  opacity: 1;
}

.screenshot-overlay i {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

/* Overview Section */
.overview-section {
  padding: var(--section-padding);
}

.overview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2rem;
  margin-bottom: 4rem;
}

.overview-card {
  background: var(--bg-primary);
  padding: var(--card-padding);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  border-left: 4px solid var(--primary-color);
  transition: transform var(--animation-normal), box-shadow var(--animation-normal);
}

.overview-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}

.overview-card.problem {
  border-left-color: var(--warning-color);
  padding: 1rem;
  margin-bottom: 1rem;
}

.overview-card.solution {
  border-left-color: var(--primary-color);
}

.overview-card.impact {
  border-left-color: var(--accent-color);
}

.card-icon {
  width: 3rem;
  height: 3rem;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.overview-card.problem .card-icon {
  background: linear-gradient(135deg, var(--warning-color), #f97316);
}

.overview-card.impact .card-icon {
  background: linear-gradient(135deg, var(--accent-color), #059669);
}

.overview-card ul {
  list-style: none;
  margin-top: 1rem;
}

.overview-card li {
  padding: 0.5rem 0;
  padding-left: 1.5rem;
  position: relative;
  color: var(--text-secondary);
}

.overview-card li::before {
  content: '•';
  position: absolute;
  left: 0;
  color: var(--primary-color);
  font-weight: bold;
}

.key-features h3 {
  text-align: center;
  margin-bottom: 2rem;
}

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

.feature-item {
  text-align: center;
  padding: 1.5rem;
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  transition: transform var(--animation-normal);
}

.feature-item:hover {
  transform: translateY(-2px);
}

.feature-item i {
  font-size: 2rem;
  color: var(--primary-color);
  margin-bottom: 1rem;
}

.feature-item h4 {
  margin-bottom: 0.5rem;
}

.feature-item p {
  font-size: 0.875rem;
}

/* Technical Section */
.technical-section {
  padding: var(--section-padding);
  background: var(--bg-secondary);
}

.architecture-diagram {
  margin-bottom: 4rem;
  text-align: center;
}

.diagram-container {
  margin: 2rem 0;
}

.diagram-placeholder {
  position: relative;
  margin: 0 auto;
  max-width: 800px;
  aspect-ratio: 16 / 10;
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: pointer;
  transition: transform var(--animation-normal);
  display: flex;
  align-items: center;
  justify-content: center;
  background: white;
  padding: 1rem;
  box-sizing: border-box;
}

.diagram-placeholder:hover {
  transform: scale(1.02);
}

.diagram-placeholder img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  background: white;
}

.diagram-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  opacity: 0;
  transition: opacity var(--animation-fast);
}

.diagram-placeholder:hover .diagram-overlay {
  opacity: 1;
}

.diagram-overlay i {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.diagram-description {
  max-width: 600px;
  margin: 0 auto;
  color: var(--text-secondary);
  font-style: italic;
}

.technical-achievements {
  display: flex;
  flex-direction: column;
  gap: 3rem;
  margin-bottom: 4rem;
}

.achievement-card {
  background: var(--bg-primary);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  transition: transform var(--animation-normal), box-shadow var(--animation-normal);
}

.achievement-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}

.achievement-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem;
  background: linear-gradient(135deg, var(--primary-light), var(--bg-tertiary));
  border-bottom: 1px solid var(--primary-light);
}

.achievement-header h3 {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.achievement-icon {
  width: 3rem;
  height: 3rem;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  font-size: 1.25rem;
}

.difficulty-badge {
  background: var(--accent-color);
  color: var(--text-light);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-md);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.achievement-content {
  padding: 1.5rem;
}

.achievement-content p {
  margin-bottom: 1rem;
}

.challenge {
  padding: 1rem;
  background: rgba(239, 68, 68, 0.1);
  border-left: 4px solid var(--error-color);
  border-radius: var(--radius-md);
  margin-bottom: 1rem;
}

.solution {
  padding: 1rem;
  background: rgba(59, 130, 246, 0.1);
  border-left: 4px solid var(--primary-color);
  border-radius: var(--radius-md);
  margin-bottom: 1rem;
}

.impact {
  padding: 1rem;
  background: rgba(16, 185, 129, 0.1);
  border-left: 4px solid var(--accent-color);
  border-radius: var(--radius-md);
  margin-bottom: 1rem;
}

.code-block {
  margin: 1.5rem 0;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--bg-dark);
  transition: all var(--animation-normal);
}

.code-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  background: var(--bg-dark-secondary);
  color: var(--text-light);
  font-size: 0.875rem;
  cursor: pointer;
  position: relative;
}

.code-header:hover {
  background: rgba(71, 85, 105, 0.9);
}

.code-header-left {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.code-header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.collapse-btn {
  background: var(--primary-color);
  border: none;
  color: var(--text-light);
  cursor: pointer;
  padding: 0.375rem 0.75rem;
  border-radius: var(--radius-md);
  transition: all var(--animation-fast);
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.75rem;
  font-weight: 500;
}

.collapse-btn:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(59, 130, 246, 0.3);
}

.collapse-btn i {
  transition: transform var(--animation-fast);
}

.code-block.collapsed .collapse-btn i {
  transform: rotate(-90deg);
}

.copy-btn {
  background: transparent;
  border: none;
  color: var(--text-light);
  cursor: pointer;
  padding: 0.25rem;
  border-radius: var(--radius-sm);
  transition: background var(--animation-fast);
}

.copy-btn:hover {
  background: rgba(255, 255, 255, 0.1);
}

.code-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--animation-normal) ease-out;
}

.code-block.collapsed .code-content {
  max-height: 0;
}

.code-block.expanded .code-content {
  max-height: 5000px; /* Very large value to accommodate any code block */
  overflow: visible;
}

.code-block pre {
  margin: 0;
  padding: 1rem;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 0.875rem;
  line-height: 1.5;
}

.code-block code {
  color: #e2e8f0;
}

.code-preview {
  padding: 1rem;
  background: var(--bg-dark);
  font-family: var(--font-mono);
  font-size: 0.875rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  line-height: 1.5;
}

.code-preview code {
  color: #e2e8f0;
  font-family: var(--font-mono);
  white-space: pre;
  display: block;
}

.code-block.collapsed .code-preview {
  display: block;
}

.code-block.expanded .code-preview {
  display: none;
}

.tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0;
}

.tech-tag {
  background: var(--primary-light);
  color: var(--primary-dark);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-md);
  font-size: 0.75rem;
  font-weight: 500;
}

.integration-flow h3 {
  text-align: center;
}

/* Stack Section */
.stack-section {
  padding: var(--section-padding);
}

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

.stack-category {
  background: var(--bg-primary);
  padding: var(--card-padding);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  transition: transform var(--animation-normal), box-shadow var(--animation-normal);
}

.stack-category:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}

.stack-category h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  color: var(--primary-color);
}

.tech-items {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.tech-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--animation-fast);
  position: relative;
}

.tech-item:hover {
  background: var(--primary-light);
  transform: translateX(4px);
}

.tech-item img,
.tech-item i {
  width: 2rem;
  height: 2rem;
  object-fit: contain;
  background: var(--bg-primary);
  padding: 0.25rem;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
}

.tech-item span {
  font-weight: 500;
}

.database-architecture {
  margin-bottom: 4rem;
  text-align: center;
}

.database-architecture h3 {
  margin-bottom: 2rem;
}

.database-diagram-placeholder {
  border-radius: var(--radius-lg);
  border: 1px solid lightgray;
}

.database-diagram-placeholder img {
  object-fit: contain;
}

.stack-highlights h3 {
  text-align: center;
  margin-bottom: 2rem;
}

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

.highlight-item {
  text-align: center;
  padding: 2rem;
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  transition: transform var(--animation-normal);
}

.highlight-item:hover {
  transform: translateY(-4px);
}

.highlight-item i {
  font-size: 2.5rem;
  color: var(--primary-color);
  margin-bottom: 1rem;
}

.highlight-item h4 {
  margin-bottom: 0.5rem;
}

.highlight-item p {
  font-size: 0.875rem;
}

/* Process Section */
.process-section {
  padding: var(--section-padding);
  background: var(--bg-secondary);
}

.timeline {
  position: relative;
  max-width: 800px;
  margin: 0 auto 4rem;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 2rem;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--primary-color);
}

.timeline-item {
  position: relative;
  margin-bottom: 3rem;
  padding-left: 5rem;
}

.timeline-marker {
  position: absolute;
  left: 1.25rem;
  top: 0;
  width: 1.5rem;
  height: 1.5rem;
  background: var(--primary-color);
  color: var(--text-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.875rem;
  z-index: 2;
}

.timeline-content {
  background: var(--bg-primary);
  padding: 1.5rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  position: relative;
}

.timeline-content::before {
  content: '';
  position: absolute;
  left: -0.5rem;
  top: 1rem;
  width: 0;
  height: 0;
  border-top: 0.5rem solid transparent;
  border-bottom: 0.5rem solid transparent;
  border-right: 0.5rem solid var(--bg-primary);
}

.timeline-content h3 {
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

.timeline-tech {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.timeline-tech span {
  background: var(--primary-light);
  color: var(--primary-dark);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-md);
  font-size: 0.75rem;
  font-weight: 500;
}

.challenges-overcome h3 {
  text-align: center;
  margin-bottom: 2rem;
}

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

.challenge-card {
  background: var(--bg-primary);
  padding: 1.5rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  text-align: center;
  transition: transform var(--animation-normal), box-shadow var(--animation-normal);
}

.challenge-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}

.challenge-icon {
  width: 4rem;
  height: 4rem;
  margin: 0 auto 1rem;
  background: linear-gradient(135deg, var(--warning-color), #f97316);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  font-size: 1.5rem;
}

.solution-badge {
  background: var(--accent-color);
  color: var(--text-light);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-md);
  font-size: 0.75rem;
  font-weight: 600;
  margin-top: 1rem;
  display: inline-block;
}

/* Results Section */
.results-section {
  padding: var(--section-padding);
}

.results-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-bottom: 4rem;
}

.result-card {
  background: var(--bg-primary);
  padding: 2rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: transform var(--animation-normal), box-shadow var(--animation-normal);
}

.result-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}

.result-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
}

.result-icon {
  width: 4rem;
  height: 4rem;
  margin: 0 auto 1rem;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  font-size: 1.5rem;
}

.result-number {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
}

.result-label {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 1rem;
}

.result-description {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.learning-outcomes h3,
.future-improvements h3 {
  text-align: center;
  margin-bottom: 2rem;
}

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

.learning-item,
.improvement-card {
  background: var(--bg-secondary);
  padding: 1.5rem;
  border-radius: var(--radius-lg);
  transition: transform var(--animation-normal);
}

.learning-item:hover,
.improvement-card:hover {
  transform: translateY(-2px);
}

.learning-item h4,
.improvement-card h4 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

.learning-item i,
.improvement-icon i {
  font-size: 1.25rem;
}

.improvement-icon {
  width: 3rem;
  height: 3rem;
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  margin-bottom: 1rem;
}

/* Footer */
.footer {
  background: var(--bg-dark);
  color: var(--text-light);
  padding: 3rem 0 1rem;
}

.footer-content {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 3rem;
  margin-bottom: 2rem;
}

.footer-brand {
  max-width: 400px;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.brand-logo i {
  font-size: 2rem;
  color: var(--primary-color);
}

.footer-brand p {
  color: rgba(255, 255, 255, 0.8);
}

.footer-links {
  display: flex;
  gap: 3rem;
}

.link-group h4 {
  margin-bottom: 1rem;
  color: var(--text-light);
}

.link-group a {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 0.5rem;
  transition: color var(--animation-fast);
}

.link-group a:hover {
  color: var(--primary-color);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.footer-attribution {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.875rem;
}

.footer-attribution p {
  margin-bottom: 0.25rem;
}

.footer-copyright {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.875rem;
}

/* Lightbox */
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 10000;
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  position: relative;
  max-width: 90vw;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2rem 1rem 1rem 1rem;
  box-sizing: border-box;
}

.lightbox-image {
  max-width: 100%;
  max-height: calc(85vh - 6rem);
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: var(--radius-lg);
  flex-shrink: 1;
  background: white;
  padding: 1rem;
  box-sizing: border-box;
}

.lightbox-close {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  color: var(--text-light);
  font-size: 2rem;
  cursor: pointer;
  transition: color var(--animation-fast);
  background: rgba(0, 0, 0, 0.7);
  border-radius: 50%;
  width: 3rem;
  height: 3rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-close:hover {
  color: var(--primary-color);
  background: rgba(0, 0, 0, 0.9);
}

.lightbox-caption {
  text-align: center;
  color: var(--text-light);
  margin-top: 1rem;
  font-size: 1rem;
  flex-shrink: 0;
  max-height: 3rem;
  overflow: hidden;
}

/* Back to Top */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 3rem;
  height: 3rem;
  background: var(--primary-color);
  color: var(--text-light);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: all var(--animation-fast);
  z-index: 1000;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
}

/* Tech Tooltip */
.tech-tooltip {
  position: absolute;
  background: var(--bg-dark);
  color: var(--text-light);
  padding: 0.75rem;
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  max-width: 250px;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: all var(--animation-fast);
  pointer-events: none;
}

.tech-tooltip.visible {
  opacity: 1;
  visibility: visible;
}

/* Animations */
@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-2rem);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(2rem);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(2rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in-up {
  animation: fadeInUp 0.6s ease-out;
}

/* Utility Classes for Animation */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(2rem);
  transition: all 0.6s ease-out;
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
} 