/* ========== CSS Variables ========== */
:root {
  --bg-primary: #1a3a4a;
  --bg-secondary: #1f4555;
  --bg-tertiary: #2d5a6a;
  --bg-card: #245060;
  --text-primary: #ffffff;
  --text-secondary: #e0e8ec;
  --text-muted: #c0d0d8;
  --accent-primary: #5ba3b5;
  --accent-secondary: #7dbdcc;
  --accent-gradient: #1a3a4a;
  --border-color: #3a6070;
  --success: #22c55e;
  --warning: #f59e0b;
  --error: #ef4444;
  --shadow-lg: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  --transition: all 0.3s ease;
  --nav-bg: #1a3a4a;
  --img-invert: 1;
}

/* Light Mode */
[data-theme="light"] {
  --bg-primary: #f0f2f4;
  --bg-secondary: #e8eaed;
  --bg-tertiary: #dfe2e6;
  --bg-card: #ffffff;
  --text-primary: #2c3e50;
  --text-secondary: #4a5568;
  --text-muted: #718096;
  --accent-primary: #1a3a4a;
  --accent-secondary: #2d5a6a;
  --accent-gradient: #1a3a4a;
  --border-color: #cbd5e0;
  --shadow-lg: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
  --nav-bg: #1a3a4a;
  --img-invert: 0;
}

/* ========== Reset & Base ========== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

/* ========== Navigation ========== */
.nav-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--nav-bg);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
}

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

.nav-logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: #ffffff;
  flex: 1;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 2rem;
  justify-content: center;
  flex: 2;
}

.nav-icons {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex: 1;
  justify-content: flex-end;
}

.nav-icon {
  color: rgba(255, 255, 255, 0.85);
  transition: var(--transition);
  display: flex;
  align-items: center;
}

.nav-icon:hover {
  color: #ffffff;
}

.nav-link {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: var(--transition);
  position: relative;
  padding: 0.5rem 0;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent-gradient);
  transition: var(--transition);
}

.nav-link:hover,
.nav-link.active {
  color: #ffffff;
}

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

/* Theme Toggle */
.theme-toggle {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 50px;
  padding: 0.5rem 0.75rem;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.theme-toggle:hover {
  background: var(--border-color);
}

.theme-icon-dark,
.theme-icon-light {
  font-size: 1rem;
  transition: var(--transition);
}

.theme-icon-light {
  display: none;
}

[data-theme="light"] .theme-icon-dark {
  display: none;
}

[data-theme="light"] .theme-icon-light {
  display: inline;
}

/* ========== Sections ========== */
.section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6rem 2rem 4rem;
}

.section-content {
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
}

.section-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  text-align: center;
}

.section-subtitle {
  color: var(--text-secondary);
  font-size: 1.1rem;
  text-align: center;
  margin-bottom: 3rem;
}

/* ========== Home Section ========== */
.section-home {
  background: radial-gradient(ellipse at top, var(--bg-secondary) 0%, var(--bg-primary) 70%);
  text-align: center;
}

.hero-title {
  font-size: 4rem;
  font-weight: 800;
  margin-bottom: 1rem;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.5rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
}

.hero-text {
  max-width: 700px;
  margin: 0 auto 2rem;
  color: var(--text-secondary);
  font-size: 1.1rem;
}

.hero-text p {
  margin-bottom: 1rem;
}

.cta-button {
  display: inline-block;
  padding: 1rem 2.5rem;
  background: var(--accent-gradient);
  color: white;
  text-decoration: none;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1.1rem;
  transition: var(--transition);
  box-shadow: 0 10px 30px rgba(99, 102, 241, 0.3);
}

.cta-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 40px rgba(99, 102, 241, 0.4);
}

/* ========== Teaser Section ========== */
.teaser-section {
  max-width: 1600px;
  margin: 3rem auto;
  padding: 0 2rem;
}

.teaser-flow {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  margin-bottom: 2rem;
}

/* Question Section */
.teaser-question {
  position: relative;
  text-align: center;
  padding: 1rem 0;
}

.question-text {
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.3;
  margin-bottom: 1.5rem;
  font-family: 'Caveat', cursive;
}

.question-visual {
  display: flex;
  justify-content: center;
  margin: 1.5rem 0;
}

.question-subtext {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 1.5rem auto 0;
  line-height: 1.6;
}

.floating-sketch {
  width: 100px;
  height: 100px;
  filter: invert(var(--img-invert));
  animation: float 3s ease-in-out infinite;
}

.sketch-baby {
  width: 120px;
  height: 120px;
}

.sketch-detector {
  width: 80px;
  height: 80px;
}

@keyframes float {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-15px);
  }
}

/* Connector */
.realworld-connector {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin: 0.5rem 0;
  opacity: 0.8;
}

.connector-line {
  flex: 1;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent-primary), transparent);
}

.connector-text {
  text-align: center;
  white-space: nowrap;
}

.connector-text p {
  font-size: 1.1rem;
  color: var(--text-secondary);
  font-style: italic;
  margin: 0;
}

/* Applications Showcase */
.applications-showcase {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  flex-wrap: nowrap;
  padding: 0;
  max-width: 100%;
}

.app-item {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 1.5rem;
  padding: 0;
  background: transparent;
  border: none;
  transition: var(--transition);
  flex: 1;
  max-width: 80%;
}

.app-item:hover {
  transform: translateY(-5px);
}

.app-sketch {
  width: 500px;
  height: 200px;
  flex-shrink: 0;
  filter: invert(var(--img-invert));
  transition: var(--transition);
}

.app-item:hover .app-sketch {
  transform: scale(1.05);
}

.app-label {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  text-align: left;
  flex: 1;
  min-width: 300px;
  max-width: 450px;
}

.app-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-primary);
}

.app-desc {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.4;
}

.app-divider {
  color: var(--accent-primary);
  opacity: 0.5;
}

/* CTA Section */
.teaser-cta-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 1rem 0;
}

.cta-text {
  font-size: 1.3rem;
  color: var(--text-secondary);
  font-weight: 500;
  text-align: center;
  margin: 0;
}

/* ========== Fundamentals Section ========== */
.section-fundamentals {
  background: var(--bg-secondary);
}

/* Roundabout scroll transition */
.roundabout-container {
  perspective: 1500px;
  min-height: 700px;
  position: relative;
}

.roundabout-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
}

.roundabout-panel {
  width: 100%;
  backface-visibility: hidden;
  transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.8s ease;
}

.panel-intro {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.panel-intro.hidden {
  display: none;
}

.panel-game {
  opacity: 0;
  transform: rotateX(90deg);
  position: absolute;
  top: 0;
  left: 0;
}

.panel-game.active {
  opacity: 1;
  transform: rotateX(0deg);
  position: relative;
}

.panel-intro.active {
  opacity: 1;
  transform: rotateX(0deg);
}

.panel-intro.rotating-out {
  opacity: 0;
  transform: rotateX(-90deg);
  position: absolute;
}

.intro-gif {
  max-width: 95%;
  max-height: 85vh;
  width: 1400px;
  height: auto;
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
}

.scroll-hint {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
  color: var(--text-secondary);
  animation: bounce 2s infinite;
}

.scroll-hint span {
  font-size: 0.95rem;
  font-weight: 500;
}

.scroll-arrow {
  color: var(--accent-primary);
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(10px);
  }
  60% {
    transform: translateY(5px);
  }
}

.main-container {
  display: flex;
  gap: 2rem;
  background: var(--bg-card);
  border-radius: 20px;
  border: 1px solid var(--border-color);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  min-height: 600px;
}

.left-panel {
  width: 45%;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  border-right: 1px solid var(--border-color);
  overflow-y: auto;
}

.right-panel {
  width: 55%;
  padding: 2rem;
  overflow-y: auto;
  max-height: 700px;
}

/* ========== Characters ========== */
#baby-mother {
  display: flex;
  gap: 3rem;
  justify-content: center;
  align-items: flex-end;
  flex-wrap: wrap;
}

#baby-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

#mother-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

#baby-img {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  border: 3px solid var(--accent-primary);
  background: var(--bg-tertiary);
  padding: 10px;
  transition: var(--transition);
  filter: invert(var(--img-invert));
}

#mother-img {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  border: 3px solid var(--accent-secondary);
  background: var(--bg-tertiary);
  padding: 8px;
  transition: var(--transition);
  filter: invert(var(--img-invert));
}

#baby-img:hover,
#mother-img:hover {
  transform: scale(1.05);
  box-shadow: 0 0 30px rgba(99, 102, 241, 0.3);
}

.character-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.speech-bubble {
  font-size: 0.9rem;
  padding: 0.75rem 1rem;
  background: var(--bg-tertiary);
  border-radius: 12px;
  border: 1px solid var(--border-color);
  width: 200px;
  min-height: 4.5rem;
  text-align: center;
  color: var(--text-secondary);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

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

/* ========== Buttons ========== */
#controls {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  width: 100%;
}

.button-row {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  justify-content: center;
}

.btn {
  padding: 0.75rem 1.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
}

.btn-primary {
  background: var(--accent-gradient);
  color: white;
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

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

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

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

.btn-outline:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

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

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

.style-button {
  padding: 0.6rem 1rem;
  font-size: 0.85rem;
  font-weight: 500;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
}

.style-button:hover:not(:disabled) {
  background: var(--accent-primary);
  color: white;
  border-color: var(--accent-primary);
}

.style-button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.style-button.style-selected {
  background: var(--accent-primary);
  color: white;
  border-color: var(--accent-primary);
}

.style-button.style-trained {
  border-color: var(--success);
  position: relative;
}

.style-button.style-trained::after {
  content: '✓';
  position: absolute;
  top: -5px;
  right: -5px;
  background: var(--success);
  color: white;
  border-radius: 50%;
  width: 16px;
  height: 16px;
  font-size: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-active {
  background: var(--accent-gradient) !important;
  color: white !important;
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.4);
}

/* ========== Tutorial Hints ========== */
.style-buttons-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.hints-row {
  display: flex;
  justify-content: space-between;
  width: 100%;
  max-width: 450px;
  margin-top: 0.75rem;
}

.tutorial-hint {
  display: flex;
  align-items: flex-start;
  gap: 0.25rem;
  font-family: 'Caveat', cursive;
  font-size: 1.15rem;
  color: var(--accent-secondary);
  max-width: 200px;
}

.hint-left {
  flex-direction: row;
  align-items: flex-start;
}

.hint-right {
  flex-direction: row;
  align-items: flex-start;
  text-align: right;
}

.hint-arrow-svg {
  flex-shrink: 0;
  color: var(--accent-secondary);
}

.hint-text {
  font-weight: 500;
  line-height: 1.3;
}

.legend-checkmark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--success);
  color: white;
  border-radius: 50%;
  width: 16px;
  height: 16px;
  font-size: 10px;
  font-family: 'Inter', sans-serif;
  margin-right: 0.2rem;
  vertical-align: middle;
}

/* ========== Summary Box ========== */
#summary-box {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 0.75rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  row-gap: 0.25rem;
}

#summary-box h4 {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
  white-space: nowrap;
}

.summary-stats {
  display: flex;
  gap: 1.5rem;
}

.stat {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.stat-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.stat-value {
  font-size: 1.1rem;
  font-weight: 700;
}

.stat-value.correct {
  color: var(--success);
}

.stat-value.wrong {
  color: var(--error);
}

.stat-value.accuracy {
  color: var(--accent-primary);
}

.stat-hint {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-style: italic;
  text-align: center;
  width: 100%;
}

/* ========== Tech Info Box ========== */
#more-info-container {
  text-align: center;
  width: 100%;
}

#tech-info-box {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.25rem;
  margin-top: 1rem;
  text-align: left;
}

#tech-info-box h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--accent-primary);
  margin-bottom: 1rem;
}

#tech-info-box ul {
  list-style: none;
}

#tech-info-box li {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border-color);
  font-size: 0.9rem;
  color: var(--text-secondary);
}

#tech-info-box li:last-child {
  border-bottom: none;
}

#tech-info-box .term {
  color: var(--accent-secondary);
  font-weight: 500;
}

#tech-info-box strong {
  color: var(--text-primary);
}

/* ========== Image Panel ========== */
#image-panel {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: 0.75rem;
}

#image-panel img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border: 2px solid transparent;
  border-radius: 10px;
  cursor: pointer;
  transition: var(--transition);
}

#image-panel img:hover {
  border-color: var(--accent-primary);
  transform: scale(1.05);
}

.disabled-image {
  opacity: 0.4;
  cursor: not-allowed !important;
  transform: none !important;
}

.prediction-correct {
  border: 3px solid var(--success) !important;
}

.prediction-wrong {
  border: 3px solid var(--error) !important;
}

/* ========== Application Section ========== */
.section-application {
  background: var(--bg-primary);
}

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

.placeholder-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 2rem;
  transition: var(--transition);
}

.placeholder-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent-primary);
}

.placeholder-card h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--accent-primary);
}

.placeholder-card p {
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ========== Research Section ========== */
.section-research {
  background: var(--bg-secondary);
}

.application-slider,
.research-slider {
  position: relative;
}

.slider-nav {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.slider-nav-btn {
  padding: 0.75rem 1.5rem;
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-secondary);
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.95rem;
  font-weight: 500;
  transition: var(--transition);
}

.slider-nav-btn:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
}

.slider-nav-btn.active {
  background: var(--accent-gradient);
  color: white;
  border-color: transparent;
}

.slider-container {
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  box-shadow: var(--shadow-lg);
}

.slider-track {
  display: flex;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.slider-slide {
  min-width: 100%;
  min-height: 600px;
  padding: 2rem;
  display: flex;
  flex-direction: column;
}

.slide-content {
  max-width: 100%;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  flex: 1;
  height: 100%;
}

.slide-content h3 {
  font-size: 1.75rem;
  margin-bottom: 1.5rem;
  color: var(--text-primary);
}

.slide-intro {
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: 2rem;
}

.placeholder-text {
  color: var(--text-muted);
  font-style: italic;
  text-align: center;
  padding: 4rem 2rem;
}

/* ========== Paper Cards ========== */
.paper-cards {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 1rem;
}

.paper-card {
  display: flex;
  align-items: stretch;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
  transition: var(--transition);
}

.paper-card:hover {
  transform: translateX(4px);
  border-color: var(--accent-primary);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.paper-year {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 70px;
  padding: 1rem;
  background: var(--accent-primary);
  color: white;
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.paper-body {
  padding: 1rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.paper-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.4;
}

.paper-authors {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.paper-venue {
  font-size: 0.85rem;
  font-style: italic;
  color: var(--accent-secondary);
}

.research-gifs {
  display: flex;
  gap: 2rem;
  justify-content: center;
  flex-wrap: wrap;
}

.research-gif {
  max-width: 100%;
  width: 700px;
  height: auto;
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
}

.slider-arrows {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-top: 1.5rem;
}

.slider-arrow {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.slider-arrow:hover {
  background: var(--accent-primary);
  color: white;
  border-color: var(--accent-primary);
}

.slider-arrow:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.slider-arrow:disabled:hover {
  background: var(--bg-card);
  color: var(--text-secondary);
  border-color: var(--border-color);
}

/* ========== Footer ========== */
.footer {
  background: var(--bg-tertiary);
  border-top: 1px solid var(--border-color);
  padding: 2rem;
}

.footer-content {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-content p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

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

.footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.9rem;
  transition: var(--transition);
}

.footer-links a:hover {
  color: var(--accent-primary);
}

/* ========== Responsive ========== */
@media (max-width: 900px) {
  .main-container {
    flex-direction: column;
  }

  .app-sketch {
    width: 300px;
  }

  .app-item{
    flex-direction: column;
  }

  .left-panel,
  .right-panel {
    width: 100%;
    border-right: none;
  }
  
  .left-panel {
    border-bottom: 1px solid var(--border-color);
  }
  
  .hero-title {
    font-size: 2.5rem;
  }
  
  .nav-links {
    gap: 1rem;
  }
  
  .nav-link {
    font-size: 0.85rem;
  }

  .teaser-section {
    margin: 2rem auto;
  }

  .teaser-flow {
    gap: 2rem;
  }

  .question-text {
    font-size: 1.8rem;
  }

  .applications-showcase {
    flex-direction: column;
    gap: 1.5rem;
  }

  .app-item {
    max-width: 100%;
  }

  .connector-text p {
    font-size: 1rem;
  }
}

@media (max-width: 600px) {
  .nav-container {
    flex-direction: column;
    gap: 1rem;
  }
  
  .hero-title {
    font-size: 2rem;
  }
  
  .section {
    padding: 5rem 1rem 3rem;
  }
  
  #baby-mother {
    gap: 1.5rem;
  }
  
  #baby-img {
    width: 100px;
    height: 100px;
  }
  
  #mother-img {
    width: 70px;
    height: 70px;
  }
}

/* ========== Loading Animation ========== */
#loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.8);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  backdrop-filter: blur(5px);
}

.loading-content {
  text-align: center;
  padding: 3rem;
  background: var(--bg-card);
  border-radius: 20px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-lg);
}

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

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

.loading-text {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.loading-subtext {
  font-size: 1rem;
  color: var(--text-secondary);
}

/* ========== Retrain Prompt ========== */
#retrain-prompt {
  background: var(--bg-tertiary);
  border: 2px solid var(--warning);
  border-radius: 12px;
  padding: 1rem 1.5rem;
  margin-top: 1rem;
  text-align: center;
  animation: pulse-border 2s ease-in-out infinite;
}

@keyframes pulse-border {
  0%, 100% { border-color: var(--warning); }
  50% { border-color: var(--error); }
}

#retrain-prompt p {
  color: var(--text-primary);
  font-weight: 500;
  margin-bottom: 0.75rem;
}

#retrain-prompt .btn {
  margin-top: 0.5rem;
}

/* ========== Shine Animation for Predictions ========== */
@keyframes shine-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(91, 163, 181, 0.4);
  }
  50% {
    box-shadow: 0 0 15px 3px rgba(91, 163, 181, 0.6);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(91, 163, 181, 0);
  }
}

.speech-bubble.shine {
  animation: shine-pulse 0.8s ease-out;
}