/* ========================================================
   DUOFIT • Duolingo Design System
   ======================================================== */

:root {
  /* Duolingo Authentic Color Palette */
  --duo-green: #58cc02;
  --duo-green-dark: #46a302;
  --duo-green-light: #d7ffb8;
  --duo-green-pale: #f0fdf0;

  --duo-blue: #1cb0f6;
  --duo-blue-dark: #1899d6;
  --duo-blue-light: #ddf4ff;

  --duo-orange: #ff9600;
  --duo-orange-dark: #e07a00;
  --duo-orange-light: #ffe8ba;

  --duo-red: #ff4b4b;
  --duo-red-dark: #ea2b2b;
  --duo-red-light: #ffe5e5;

  --duo-purple: #ce82ff;
  --duo-purple-dark: #aa4fed;
  --duo-purple-light: #f7e8ff;

  --duo-yellow: #ffc800;
  --duo-yellow-dark: #e5a800;

  --duo-gray-100: #f7f7f7;
  --duo-gray-200: #e5e5e5;
  --duo-gray-300: #cecece;
  --duo-gray-400: #afafaf;
  --duo-gray-500: #777777;
  --duo-gray-800: #3c3c3c;
  --duo-gray-900: #1b1b1b;

  --font-family: 'Nunito', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --sidebar-width: 256px;
  --right-panel-width: 330px;
  --border-radius-base: 16px;
  --border-radius-lg: 24px;
}

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

body {
  font-family: var(--font-family);
  background-color: #ffffff;
  color: var(--duo-gray-800);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ========================================================
   MAIN DUOLINGO 3-COLUMN LAYOUT
   ======================================================== */
.duo-layout {
  display: flex;
  min-height: 100vh;
  position: relative;
  background-color: #ffffff;
}

/* ========================================================
   LEFT SIDEBAR
   ======================================================== */
.duo-sidebar {
  width: var(--sidebar-width);
  border-right: 2px solid var(--duo-gray-200);
  padding: 24px 16px;
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  background: #ffffff;
  z-index: 100;
  flex-shrink: 0;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 12px 28px 12px;
  border-bottom: 2px solid var(--duo-gray-200);
}

.brand-icon {
  font-size: 32px;
  animation: duoBounce 3s infinite ease-in-out;
}

.brand-name {
  font-size: 26px;
  font-weight: 900;
  color: var(--duo-green);
  letter-spacing: 1px;
}

.sidebar-nav {
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 16px;
  border-radius: var(--border-radius-base);
  border: 2px solid transparent;
  background: transparent;
  color: var(--duo-gray-500);
  font-family: var(--font-family);
  font-size: 15px;
  font-weight: 800;
  text-align: left;
  cursor: pointer;
  letter-spacing: 0.5px;
  transition: all 0.15s ease;
}

.nav-item:hover {
  background-color: var(--duo-gray-100);
  color: var(--duo-gray-900);
}

.nav-item.active {
  background-color: var(--duo-blue-light);
  border-color: var(--duo-blue);
  color: var(--duo-blue-dark);
}

.nav-icon {
  font-size: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sidebar-footer {
  margin-top: auto;
  padding-top: 16px;
  border-top: 2px solid var(--duo-gray-200);
}

.mascot-mini-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--duo-green-pale);
  padding: 10px 12px;
  border-radius: var(--border-radius-base);
  border: 2px solid var(--duo-green-light);
}

.mascot-mini-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--duo-green);
}

.mascot-mini-text strong {
  display: block;
  font-size: 13px;
  color: var(--duo-green-dark);
}

.mascot-mini-text span {
  display: block;
  font-size: 11px;
  color: var(--duo-gray-500);
}

/* ========================================================
   MAIN CONTENT WRAPPER & TOP BAR
   ======================================================== */
.main-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
  max-width: 820px;
  margin: 0 auto;
}

.duo-topbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 16px 24px;
  position: sticky;
  top: 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  z-index: 90;
  border-bottom: 2px solid var(--duo-gray-200);
}

.mobile-menu-btn {
  display: none;
  font-size: 24px;
  background: none;
  border: none;
  cursor: pointer;
  margin-right: auto;
}

.topbar-metrics {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

/* Duolingo Pill Counters */
.metric-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 15px;
  border: 2px solid transparent;
  cursor: pointer;
  user-select: none;
  transition: transform 0.1s ease;
}

.metric-pill:hover {
  transform: translateY(-2px);
}

.streak-pill {
  color: var(--duo-orange-dark);
  background: var(--duo-orange-light);
  border-color: #ffd187;
}

.streak-pill .flame-icon {
  animation: flameFlicker 1.8s infinite ease-in-out;
  display: inline-block;
}

.gems-pill {
  color: var(--duo-blue-dark);
  background: var(--duo-blue-light);
  border-color: #bce5fd;
}

.xp-pill {
  color: #c98800;
  background: #fff8d6;
  border-color: #ffe68a;
}

.weight-pill {
  color: #3b7405;
  background: #edfbe5;
  border-color: #c8f5b4;
}

.bmi-badge-pill {
  font-size: 11px;
  padding: 2px 8px;
  background: #ffffff;
  border-radius: 999px;
  border: 1px solid var(--duo-green);
  color: var(--duo-green-dark);
  font-weight: 900;
}

.sound-toggle-btn {
  background: var(--duo-gray-100);
  border: 2px solid var(--duo-gray-200);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s ease;
}

.sound-toggle-btn:hover {
  background: var(--duo-gray-200);
}

/* ========================================================
   RIGHT PANEL (Duolingo Style: Streaks & Duo Mascot)
   ======================================================== */
.duo-right-panel {
  width: var(--right-panel-width);
  padding: 24px 20px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  border-left: 2px solid var(--duo-gray-200);
  display: flex;
  flex-direction: column;
  gap: 20px;
  flex-shrink: 0;
}

.widget-card {
  border: 2px solid var(--duo-gray-200);
  border-radius: var(--border-radius-base);
  padding: 18px;
  background: #ffffff;
  box-shadow: 0 4px 0 var(--duo-gray-200);
}

.widget-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.widget-title {
  font-size: 14px;
  font-weight: 900;
  color: var(--duo-gray-500);
  letter-spacing: 0.8px;
}

.widget-sub {
  font-size: 13px;
  color: var(--duo-gray-500);
  margin-bottom: 14px;
}

.streak-badge-count {
  background: var(--duo-orange);
  color: #ffffff;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 900;
}

.streak-days-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 16px;
}

.streak-day-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.day-letter {
  font-size: 12px;
  font-weight: 800;
  color: var(--duo-gray-400);
}

.day-flame-circle {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--duo-gray-100);
  border: 2px solid var(--duo-gray-200);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: var(--duo-gray-300);
  transition: all 0.2s ease;
}

.day-flame-circle.active {
  background: var(--duo-orange-light);
  border-color: var(--duo-orange);
  color: var(--duo-orange-dark);
  box-shadow: 0 0 10px rgba(255, 150, 0, 0.4);
  transform: scale(1.05);
}

.streak-freeze-box {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--duo-blue-light);
  border: 2px solid #bde6fd;
  border-radius: 12px;
  padding: 8px 12px;
}

.freeze-icon {
  font-size: 22px;
}

.freeze-info strong {
  display: block;
  font-size: 12px;
  color: var(--duo-blue-dark);
}

.freeze-info span {
  display: block;
  font-size: 11px;
  color: var(--duo-gray-500);
}

.duo-card {
  text-align: center;
  background: var(--duo-green-pale);
  border-color: var(--duo-green-light);
}

.duo-side-mascot {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--duo-green);
  margin: 0 auto 10px auto;
  display: block;
  box-shadow: 0 4px 12px rgba(88, 204, 2, 0.25);
  animation: duoFloat 4s ease-in-out infinite;
}

.duo-side-text h4 {
  font-size: 15px;
  font-weight: 800;
  color: var(--duo-green-dark);
  margin-bottom: 4px;
}

.duo-side-text p {
  font-size: 13px;
  color: var(--duo-gray-800);
  margin-bottom: 12px;
  font-style: italic;
}

.quick-stat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--duo-gray-200);
  font-size: 13px;
}

.quick-stat-row:last-child {
  border-bottom: none;
}

.quick-stat-row strong {
  color: var(--duo-gray-900);
  font-weight: 800;
}

/* ========================================================
   CONTENT SECTIONS & TABS
   ======================================================== */
.duo-content {
  padding: 24px;
  flex: 1;
}

.tab-pane {
  display: none;
  animation: fadeIn 0.2s ease-in-out;
}

.tab-pane.active {
  display: block;
}

/* ========================================================
   DUOLINGO TACTILE 3D BUTTONS
   ======================================================== */
.duo-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-family);
  font-size: 15px;
  font-weight: 800;
  padding: 12px 24px;
  border-radius: var(--border-radius-base);
  border: none;
  cursor: pointer;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  transition: transform 0.08s ease, box-shadow 0.08s ease, background 0.15s ease;
  user-select: none;
}

.duo-btn-primary {
  background-color: var(--duo-green);
  color: #ffffff;
  box-shadow: 0 4px 0 var(--duo-green-dark);
}

.duo-btn-primary:hover {
  background-color: #61db05;
}

.duo-btn-primary:active {
  transform: translateY(4px);
  box-shadow: 0 0 0 var(--duo-green-dark);
}

.duo-btn-secondary {
  background-color: #ffffff;
  color: var(--duo-blue-dark);
  border: 2px solid var(--duo-gray-200);
  box-shadow: 0 4px 0 var(--duo-gray-200);
}

.duo-btn-secondary:hover {
  background-color: var(--duo-gray-100);
}

.duo-btn-secondary:active {
  transform: translateY(4px);
  box-shadow: 0 0 0 var(--duo-gray-200);
}

.duo-btn-danger {
  background-color: #ffffff;
  color: var(--duo-red-dark);
  border: 2px solid #ffd5d5;
  box-shadow: 0 4px 0 #ffd5d5;
}

.duo-btn-danger:hover {
  background-color: var(--duo-red-light);
}

.duo-btn-danger:active {
  transform: translateY(4px);
  box-shadow: 0 0 0 #ffd5d5;
}

.duo-btn-sm {
  padding: 8px 16px;
  font-size: 13px;
  border-radius: 12px;
  box-shadow: 0 3px 0 var(--duo-gray-200);
}

.duo-btn-sm:active {
  transform: translateY(3px);
  box-shadow: 0 0 0 transparent;
}

.duo-btn-lg {
  padding: 16px 32px;
  font-size: 16px;
}

/* ========================================================
   TAB 1: DUOLINGO SECTION BANNER & LEARNING PATH
   ======================================================== */
.section-banner-card {
  background: linear-gradient(135deg, #58cc02 0%, #46a302 100%);
  color: #ffffff;
  border-radius: var(--border-radius-lg);
  padding: 24px;
  margin-bottom: 40px;
  box-shadow: 0 8px 0 #368102, 0 16px 24px rgba(70, 163, 2, 0.2);
  position: relative;
  overflow: hidden;
}

.section-banner-card::before {
  content: '🏆';
  position: absolute;
  right: 16px;
  bottom: -10px;
  font-size: 110px;
  opacity: 0.18;
  transform: rotate(15deg);
  pointer-events: none;
}

.section-tag {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  background: rgba(0, 0, 0, 0.15);
  padding: 4px 12px;
  border-radius: 999px;
  display: inline-block;
  margin-bottom: 8px;
}

.section-title {
  font-size: 28px;
  font-weight: 900;
  margin-bottom: 6px;
}

.section-subtitle {
  font-size: 15px;
  opacity: 0.95;
  margin-bottom: 20px;
}

.section-progress-container {
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(4px);
  border-radius: 16px;
  padding: 12px 16px;
}

.progress-labels {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  font-weight: 800;
  margin-bottom: 8px;
}

.progress-percent-badge {
  background: #ffffff;
  color: var(--duo-green-dark);
  padding: 2px 10px;
  border-radius: 999px;
  font-weight: 900;
}

.duo-progress-bar-outer {
  height: 16px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 999px;
  overflow: hidden;
  position: relative;
}

.duo-progress-bar-inner {
  height: 100%;
  background: linear-gradient(90deg, #ffc800 0%, #ffdf6d 100%);
  border-radius: 999px;
  transition: width 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
}

.duo-progress-bar-inner::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 6px;
  right: 6px;
  height: 4px;
  background: rgba(255, 255, 255, 0.4);
  border-radius: 999px;
}

/* ========================================================
   THE ISLAND PATH (Serpentine Winding Map)
   ======================================================== */
.path-container {
  position: relative;
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  padding: 20px 0 80px 0;
  min-height: 850px;
}

.path-svg-lines {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

.island-nodes-wrapper {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 52px;
}

/* Single Island Row */
.island-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
  user-select: none;
}

/* Serpentine offsets */
.island-step[data-pos="left"] {
  transform: translateX(-90px);
}
.island-step[data-pos="center"] {
  transform: translateX(0);
}
.island-step[data-pos="right"] {
  transform: translateX(90px);
}

.island-step:hover {
  filter: brightness(1.06);
}

.island-step[data-pos="left"]:hover {
  transform: translateX(-90px) scale(1.05);
}
.island-step[data-pos="center"]:hover {
  transform: translateX(0) scale(1.05);
}
.island-step[data-pos="right"]:hover {
  transform: translateX(90px) scale(1.05);
}

/* 3D Tactile Island Button */
.island-circle {
  width: 86px;
  height: 86px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  font-size: 38px;
  background-color: var(--duo-green);
  border: 4px solid #ffffff;
  box-shadow: 0 10px 0 var(--duo-green-dark), 0 14px 20px rgba(0, 0, 0, 0.15);
  transition: all 0.1s ease;
}

.island-step:active .island-circle {
  transform: translateY(6px);
  box-shadow: 0 4px 0 var(--duo-green-dark);
}

/* Type variations */
.island-circle.type-cardio_core {
  background: #1cb0f6;
  box-shadow: 0 10px 0 #1480b3, 0 14px 20px rgba(28, 176, 246, 0.25);
}
.island-step:active .island-circle.type-cardio_core {
  box-shadow: 0 4px 0 #1480b3;
}

.island-circle.type-strength {
  background: #ff9600;
  box-shadow: 0 10px 0 #bd7000, 0 14px 20px rgba(255, 150, 0, 0.25);
}
.island-step:active .island-circle.type-strength {
  box-shadow: 0 4px 0 #bd7000;
}

.island-circle.type-running {
  background: #58cc02;
  box-shadow: 0 10px 0 #3d8f02, 0 14px 20px rgba(88, 204, 2, 0.25);
}
.island-step:active .island-circle.type-running {
  box-shadow: 0 4px 0 #3d8f02;
}

.island-circle.type-hiit {
  background: #ff4b4b;
  box-shadow: 0 10px 0 #b83232, 0 14px 20px rgba(255, 75, 75, 0.25);
}
.island-step:active .island-circle.type-hiit {
  box-shadow: 0 4px 0 #b83232;
}

.island-circle.type-recovery {
  background: #ce82ff;
  box-shadow: 0 10px 0 #9753c4, 0 14px 20px rgba(206, 130, 255, 0.25);
}
.island-step:active .island-circle.type-recovery {
  box-shadow: 0 4px 0 #9753c4;
}

/* Completed Island state */
.island-step.completed .island-circle {
  background: #ffc800;
  box-shadow: 0 10px 0 #b38c00, 0 14px 20px rgba(255, 200, 0, 0.3);
}

.island-step.completed .island-circle::after {
  content: '⭐';
  position: absolute;
  top: -8px;
  right: -8px;
  font-size: 24px;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
  animation: starTwinkle 2s infinite ease-in-out;
}

/* Active / Current Island state */
.island-step.is-current .island-circle {
  animation: pulseNode 2s infinite ease-in-out;
}

.island-current-badge {
  position: absolute;
  top: -36px;
  background: #ffffff;
  color: var(--duo-gray-900);
  border: 2px solid var(--duo-green);
  box-shadow: 0 4px 0 var(--duo-green-dark);
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.8px;
  white-space: nowrap;
  animation: bounceBadge 1.5s infinite ease-in-out;
  display: flex;
  align-items: center;
  gap: 4px;
}

.island-current-badge::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 50%;
  transform: translateX(-50%);
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-top: 6px solid var(--duo-green);
}

/* Floating Banner label below island */
.island-info-card {
  margin-top: 14px;
  background: #ffffff;
  border: 2px solid var(--duo-gray-200);
  border-radius: 14px;
  padding: 6px 14px;
  box-shadow: 0 3px 0 var(--duo-gray-200);
  text-align: center;
  max-width: 200px;
  pointer-events: none;
}

.island-info-day {
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  color: var(--duo-gray-500);
  letter-spacing: 0.8px;
  display: block;
}

.island-info-title {
  font-size: 13px;
  font-weight: 800;
  color: var(--duo-gray-900);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}

.island-info-status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 800;
  margin-top: 2px;
}

.island-info-status.done {
  color: #388e3c;
}
.island-info-status.open {
  color: var(--duo-blue-dark);
}

/* Coach Duo Speech Bubble Widget below Path */
.duo-coach-speech-bubble {
  display: flex;
  align-items: center;
  gap: 16px;
  background: #ffffff;
  border: 2px solid var(--duo-gray-200);
  box-shadow: 0 6px 0 var(--duo-gray-200);
  border-radius: 20px;
  padding: 16px 20px;
  max-width: 520px;
  margin: 30px auto 0 auto;
}

.duo-speech-mascot {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--duo-green);
  flex-shrink: 0;
}

.speech-content p {
  font-size: 15px;
  font-weight: 700;
  color: var(--duo-gray-800);
  margin-bottom: 4px;
}

.speech-author {
  font-size: 12px;
  font-weight: 800;
  color: var(--duo-green-dark);
}

/* ========================================================
   TAB 2: GEWICHT & BMI TRACKER
   ======================================================== */
.weight-dashboard {
  max-width: 780px;
  margin: 0 auto;
}

.page-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 16px;
}

.page-title-row h2 {
  font-size: 26px;
  font-weight: 900;
}

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

.metric-card {
  background: #ffffff;
  border: 2px solid var(--duo-gray-200);
  border-radius: var(--border-radius-base);
  padding: 16px;
  box-shadow: 0 4px 0 var(--duo-gray-200);
}

.metric-card-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.card-icon-circle {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.bg-green { background: var(--duo-green-light); color: var(--duo-green-dark); }
.bg-blue { background: var(--duo-blue-light); color: var(--duo-blue-dark); }
.bg-yellow { background: #fff2bf; color: #b8860b; }
.bg-orange { background: var(--duo-orange-light); color: var(--duo-orange-dark); }

.card-title {
  font-size: 12px;
  font-weight: 800;
  color: var(--duo-gray-500);
  text-transform: uppercase;
}

.metric-big-num {
  font-size: 28px;
  font-weight: 900;
  color: var(--duo-gray-900);
  margin-bottom: 4px;
}

.metric-big-num small {
  font-size: 16px;
  font-weight: 700;
  color: var(--duo-gray-500);
  margin-left: 2px;
}

.metric-diff {
  font-size: 12px;
  font-weight: 700;
  color: var(--duo-gray-500);
}

.bmi-category-badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--duo-gray-100);
  color: var(--duo-gray-800);
}

.bmi-category-badge.normal {
  background: var(--duo-green-light);
  color: var(--duo-green-dark);
}

.bmi-category-badge.underweight {
  background: var(--duo-blue-light);
  color: var(--duo-blue-dark);
}

.bmi-category-badge.overweight {
  background: var(--duo-orange-light);
  color: var(--duo-orange-dark);
}

.bmi-category-badge.obese {
  background: var(--duo-red-light);
  color: var(--duo-red-dark);
}

/* BMI SPEEDOMETER GAUGE */
.bmi-gauge-card {
  background: #ffffff;
  border: 2px solid var(--duo-gray-200);
  border-radius: var(--border-radius-base);
  padding: 20px;
  box-shadow: 0 4px 0 var(--duo-gray-200);
  margin-bottom: 24px;
}

.bmi-gauge-card h3 {
  font-size: 18px;
  font-weight: 900;
  margin-bottom: 4px;
}

.bmi-gauge-card p {
  font-size: 13px;
  color: var(--duo-gray-500);
  margin-bottom: 24px;
}

.bmi-bar-wrapper {
  position: relative;
  margin-top: 10px;
  margin-bottom: 30px;
}

.bmi-bar-segments {
  display: flex;
  height: 38px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.1);
}

.bmi-seg {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #ffffff;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.2;
  padding: 0 4px;
}

.seg-underweight { background-color: #1cb0f6; }
.seg-normal { background-color: #58cc02; }
.seg-overweight { background-color: #ff9600; }
.seg-obese { background-color: #ff4b4b; }

.bmi-marker {
  position: absolute;
  top: -8px;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: left 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
  pointer-events: none;
}

.bmi-marker-pin {
  width: 14px;
  height: 52px;
  background: var(--duo-gray-900);
  border: 2px solid #ffffff;
  border-radius: 7px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.4);
}

.bmi-marker-label {
  margin-top: 4px;
  background: var(--duo-gray-900);
  color: #ffffff;
  font-size: 12px;
  font-weight: 900;
  padding: 3px 8px;
  border-radius: 8px;
  white-space: nowrap;
}

/* CHART CARD */
.chart-card {
  background: #ffffff;
  border: 2px solid var(--duo-gray-200);
  border-radius: var(--border-radius-base);
  padding: 20px;
  box-shadow: 0 4px 0 var(--duo-gray-200);
  margin-bottom: 24px;
}

.chart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.chart-header h3 {
  font-size: 18px;
  font-weight: 900;
}

.chart-actions {
  display: flex;
  gap: 8px;
}

.pill-btn {
  background: var(--duo-gray-100);
  border: 2px solid var(--duo-gray-200);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  color: var(--duo-gray-500);
  transition: all 0.15s ease;
}

.pill-btn.active {
  background: var(--duo-blue-light);
  border-color: var(--duo-blue);
  color: var(--duo-blue-dark);
}

.chart-canvas-container {
  position: relative;
  width: 100%;
  height: 260px;
}

#weight-chart-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

/* HISTORY TABLE */
.history-table-card {
  background: #ffffff;
  border: 2px solid var(--duo-gray-200);
  border-radius: var(--border-radius-base);
  padding: 20px;
  box-shadow: 0 4px 0 var(--duo-gray-200);
}

.history-table-card h3 {
  font-size: 18px;
  font-weight: 900;
  margin-bottom: 16px;
}

.table-responsive {
  overflow-x: auto;
}

.duo-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  text-align: left;
}

.duo-table th {
  padding: 10px 12px;
  font-weight: 800;
  color: var(--duo-gray-500);
  text-transform: uppercase;
  font-size: 12px;
  border-bottom: 2px solid var(--duo-gray-200);
}

.duo-table td {
  padding: 12px;
  border-bottom: 1px solid var(--duo-gray-200);
  font-weight: 600;
}

.duo-table tr:hover td {
  background-color: var(--duo-gray-100);
}

.diff-green { color: #2e7d32; font-weight: 800; }
.diff-red { color: #c62828; font-weight: 800; }
.diff-neutral { color: var(--duo-gray-400); font-weight: 800; }

.table-delete-btn {
  background: none;
  border: none;
  color: var(--duo-gray-400);
  font-size: 16px;
  cursor: pointer;
  padding: 4px;
  border-radius: 6px;
}

.table-delete-btn:hover {
  color: var(--duo-red-dark);
  background: var(--duo-red-light);
}

/* ========================================================
   TAB 3: QUESTS & ERFOLGE
   ======================================================== */
.quests-dashboard {
  max-width: 780px;
  margin: 0 auto;
}

.quests-grid {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 20px;
}

.quest-card {
  display: flex;
  align-items: center;
  gap: 16px;
  background: #ffffff;
  border: 2px solid var(--duo-gray-200);
  border-radius: var(--border-radius-base);
  padding: 16px;
  box-shadow: 0 4px 0 var(--duo-gray-200);
}

.quest-icon {
  font-size: 36px;
  width: 56px;
  height: 56px;
  background: var(--duo-gray-100);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.quest-info {
  flex: 1;
}

.quest-title {
  font-size: 16px;
  font-weight: 800;
  color: var(--duo-gray-900);
  margin-bottom: 2px;
}

.quest-desc {
  font-size: 13px;
  color: var(--duo-gray-500);
  margin-bottom: 8px;
}

.quest-reward {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 900;
  color: var(--duo-yellow-dark);
}

.badges-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.badge-card {
  background: #ffffff;
  border: 2px solid var(--duo-gray-200);
  border-radius: var(--border-radius-base);
  padding: 16px;
  text-align: center;
  box-shadow: 0 4px 0 var(--duo-gray-200);
}

.badge-card.unlocked {
  border-color: #ffd859;
  background: #fffdf5;
  box-shadow: 0 4px 0 #ffd859;
}

.badge-icon {
  font-size: 40px;
  margin-bottom: 8px;
  display: inline-block;
}

.badge-card.locked .badge-icon {
  filter: grayscale(1) opacity(0.4);
}

.badge-name {
  font-size: 15px;
  font-weight: 800;
  margin-bottom: 4px;
}

.badge-desc {
  font-size: 12px;
  color: var(--duo-gray-500);
}

/* ========================================================
   TAB 4: TRAININGSHISTORIE
   ======================================================== */
.workout-history-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 20px;
}

.history-item-card {
  background: #ffffff;
  border: 2px solid var(--duo-gray-200);
  border-radius: var(--border-radius-base);
  padding: 18px;
  box-shadow: 0 4px 0 var(--duo-gray-200);
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.history-item-icon {
  font-size: 32px;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--duo-green-light);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.history-item-content {
  flex: 1;
}

.history-header-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}

.history-title {
  font-size: 16px;
  font-weight: 800;
  color: var(--duo-gray-900);
}

.history-date {
  font-size: 12px;
  font-weight: 700;
  color: var(--duo-gray-500);
}

.history-details-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.history-pill {
  background: var(--duo-gray-100);
  border: 1px solid var(--duo-gray-200);
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  color: var(--duo-gray-800);
}

.empty-state-card {
  background: #ffffff;
  border: 2px dashed var(--duo-gray-300);
  border-radius: var(--border-radius-base);
  padding: 48px 24px;
  text-align: center;
  color: var(--duo-gray-500);
}

.empty-state-icon {
  font-size: 48px;
  margin-bottom: 12px;
}

/* ========================================================
   TAB 5: EINSTELLUNGEN & PROFIL
   ======================================================== */
.settings-card {
  max-width: 640px;
  margin: 0 auto;
  background: #ffffff;
  border: 2px solid var(--duo-gray-200);
  border-radius: var(--border-radius-base);
  padding: 24px;
  box-shadow: 0 4px 0 var(--duo-gray-200);
}

.duo-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 13px;
  font-weight: 800;
  color: var(--duo-gray-800);
}

.duo-input {
  font-family: var(--font-family);
  font-size: 15px;
  font-weight: 700;
  padding: 12px 16px;
  border-radius: 12px;
  border: 2px solid var(--duo-gray-200);
  background: var(--duo-gray-100);
  color: var(--duo-gray-900);
  outline: none;
  transition: all 0.15s ease;
}

.duo-input:focus {
  background: #ffffff;
  border-color: var(--duo-blue);
  box-shadow: 0 0 0 3px rgba(28, 176, 246, 0.2);
}

.form-hint {
  font-size: 11px;
  color: var(--duo-gray-500);
}

.settings-divider {
  height: 2px;
  background: var(--duo-gray-200);
  margin: 32px 0;
}

.data-actions-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 16px;
}

/* ========================================================
   MODALS (Duolingo Bouncy Glassmorphic Popups)
   ======================================================== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.modal-overlay.active {
  display: flex;
}

.modal-window {
  background: #ffffff;
  border-radius: var(--border-radius-lg);
  border: 3px solid var(--duo-gray-200);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  animation: modalBouncyPop 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  overflow: hidden;
}

.workout-modal-content {
  max-width: 680px;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 20px 24px;
  border-bottom: 2px solid var(--duo-gray-200);
}

.modal-day-badge {
  font-size: 12px;
  font-weight: 900;
  color: var(--duo-green-dark);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  display: block;
  margin-bottom: 4px;
}

.modal-workout-title {
  font-size: 22px;
  font-weight: 900;
  color: var(--duo-gray-900);
  margin-bottom: 6px;
}

.modal-workout-meta {
  display: flex;
  gap: 8px;
}

.meta-tag {
  font-size: 12px;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--duo-gray-100);
}

.type-tag {
  background: var(--duo-blue-light);
  color: var(--duo-blue-dark);
}

.duration-tag {
  background: #fff8d6;
  color: #a87100;
}

.modal-close-btn {
  background: var(--duo-gray-100);
  border: 2px solid var(--duo-gray-200);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 18px;
  font-weight: 900;
  color: var(--duo-gray-500);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.1s ease;
}

.modal-close-btn:hover {
  background: var(--duo-gray-200);
  color: var(--duo-gray-900);
}

.modal-progress-wrap {
  padding: 12px 24px;
  background: var(--duo-gray-100);
  border-bottom: 2px solid var(--duo-gray-200);
}

.modal-progress-labels {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  font-weight: 800;
  margin-bottom: 6px;
  color: var(--duo-gray-800);
}

.modal-body {
  padding: 24px;
  overflow-y: auto;
  flex: 1;
}

.modal-footer {
  padding: 16px 24px;
  border-top: 2px solid var(--duo-gray-200);
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  background: #ffffff;
}

/* TIMER WIDGET */
.workout-timer-box {
  background: var(--duo-blue-light);
  border: 2px solid #bce5fd;
  border-radius: var(--border-radius-base);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 12px;
}

.timer-display {
  font-size: 28px;
  font-weight: 900;
  color: var(--duo-blue-dark);
  font-variant-numeric: tabular-nums;
}

.timer-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.timer-presets {
  display: flex;
  gap: 4px;
  margin-left: 8px;
}

.timer-preset-btn {
  background: #ffffff;
  border: 2px solid #bce5fd;
  border-radius: 8px;
  padding: 4px 8px;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
  color: var(--duo-blue-dark);
}

.timer-preset-btn.active {
  background: var(--duo-blue);
  color: #ffffff;
}

/* EXERCISE CHECKLIST */
.exercise-section-title {
  font-size: 16px;
  font-weight: 900;
  margin-bottom: 12px;
}

.exercise-checklist {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 24px;
}

.exercise-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: #ffffff;
  border: 2px solid var(--duo-gray-200);
  border-radius: var(--border-radius-base);
  padding: 14px 16px;
  box-shadow: 0 3px 0 var(--duo-gray-200);
  transition: all 0.15s ease;
  cursor: pointer;
}

.exercise-item:hover {
  border-color: var(--duo-green);
}

.exercise-item.checked {
  background: var(--duo-green-pale);
  border-color: var(--duo-green);
  box-shadow: 0 3px 0 var(--duo-green-dark);
}

.exercise-checkbox-wrap {
  margin-top: 2px;
}

.exercise-checkbox {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  border: 2px solid var(--duo-gray-300);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: #ffffff;
  transition: all 0.1s ease;
}

.exercise-item.checked .exercise-checkbox {
  background: var(--duo-green);
  border-color: var(--duo-green);
}

.exercise-info {
  flex: 1;
}

.exercise-name {
  font-size: 15px;
  font-weight: 800;
  color: var(--duo-gray-900);
  margin-bottom: 2px;
}

.exercise-meta-row {
  display: flex;
  gap: 10px;
  font-size: 12px;
  font-weight: 800;
  color: var(--duo-blue-dark);
  margin-bottom: 4px;
}

.exercise-instruction {
  font-size: 13px;
  color: var(--duo-gray-500);
}

/* DYNAMIC USER INPUTS CARD */
.workout-user-inputs-card {
  background: var(--duo-gray-100);
  border: 2px solid var(--duo-gray-200);
  border-radius: var(--border-radius-base);
  padding: 16px;
}

.workout-user-inputs-card h3 {
  font-size: 15px;
  font-weight: 900;
  margin-bottom: 2px;
}

.hint-text {
  font-size: 12px;
  color: var(--duo-gray-500);
  margin-bottom: 12px;
}

.dynamic-inputs-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

/* LIVE BMI PREVIEW IN WEIGHT MODAL */
.live-bmi-preview {
  background: var(--duo-blue-light);
  border: 2px solid #bce5fd;
  border-radius: 12px;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
}

.preview-title {
  font-size: 13px;
  font-weight: 800;
  color: var(--duo-blue-dark);
}

.preview-value {
  font-size: 20px;
  font-weight: 900;
  color: var(--duo-blue-dark);
}

.preview-badge {
  font-size: 12px;
  font-weight: 900;
  padding: 2px 10px;
  border-radius: 999px;
  background: #ffffff;
  color: var(--duo-blue-dark);
}

/* ========================================================
   CELEBRATION MODAL (Duolingo Fanfare)
   ======================================================== */
.celebration-modal-content {
  text-align: center;
  padding: 32px 24px;
  max-width: 440px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.celebration-badge-burst {
  position: relative;
  margin-bottom: 16px;
}

.celebration-mascot {
  width: 130px;
  height: 130px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--duo-green);
  box-shadow: 0 8px 24px rgba(88, 204, 2, 0.4);
  animation: duoBounce 1s infinite alternate ease-in-out;
}

.celebration-stars {
  font-size: 28px;
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  animation: starTwinkle 1.2s infinite ease-in-out;
}

.celebration-title {
  font-size: 32px;
  font-weight: 900;
  color: var(--duo-green-dark);
  margin-bottom: 4px;
}

.celebration-subtitle {
  font-size: 15px;
  color: var(--duo-gray-500);
  margin-bottom: 24px;
}

.celebration-rewards-row {
  display: flex;
  justify-content: center;
  gap: 12px;
  width: 100%;
  margin-bottom: 28px;
}

.reward-pill {
  flex: 1;
  background: var(--duo-gray-100);
  border: 2px solid var(--duo-gray-200);
  border-radius: 16px;
  padding: 12px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.reward-icon {
  font-size: 24px;
}

.reward-amount {
  font-size: 16px;
  font-weight: 900;
  color: var(--duo-gray-900);
}

.reward-label {
  font-size: 11px;
  font-weight: 700;
  color: var(--duo-gray-500);
}

.xp-reward { background: #fff9e6; border-color: #ffe494; }
.xp-reward .reward-amount { color: #b8860b; }

.streak-reward { background: var(--duo-orange-light); border-color: #ffd187; }
.streak-reward .reward-amount { color: var(--duo-orange-dark); }

.gem-reward { background: var(--duo-blue-light); border-color: #bce5fd; }
.gem-reward .reward-amount { color: var(--duo-blue-dark); }

/* Confetti canvas */
#confetti-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 2000;
}

/* ========================================================
   KEYFRAME ANIMATIONS
   ======================================================== */
@keyframes duoBounce {
  0% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
  100% { transform: translateY(0); }
}

@keyframes duoFloat {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-6px) rotate(2deg); }
}

@keyframes flameFlicker {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 2px rgba(255, 150, 0, 0.4)); }
  50% { transform: scale(1.15) rotate(-3deg); filter: drop-shadow(0 0 8px rgba(255, 150, 0, 0.8)); }
}

@keyframes starTwinkle {
  0%, 100% { transform: scale(1) rotate(0deg); opacity: 1; }
  50% { transform: scale(1.2) rotate(15deg); opacity: 0.8; }
}

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

@keyframes pulseNode {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(88, 204, 2, 0.6), 0 10px 0 var(--duo-green-dark);
  }
  50% {
    box-shadow: 0 0 0 12px rgba(88, 204, 2, 0), 0 10px 0 var(--duo-green-dark);
  }
}

@keyframes modalBouncyPop {
  0% {
    opacity: 0;
    transform: scale(0.85) translateY(20px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ========================================================
   RESPONSIVE DESIGN
   ======================================================== */
@media (max-width: 1180px) {
  .duo-right-panel {
    display: none;
  }
}

@media (max-width: 820px) {
  .duo-sidebar {
    position: fixed;
    left: -280px;
    transition: left 0.25s ease-in-out;
  }
  .duo-sidebar.open {
    left: 0;
    box-shadow: 10px 0 30px rgba(0,0,0,0.2);
  }
  .mobile-menu-btn {
    display: block;
  }
  .form-row {
    grid-template-columns: 1fr;
  }
  .path-container {
    padding: 10px 0;
  }
  .island-step[data-pos="left"] { transform: translateX(-60px); }
  .island-step[data-pos="right"] { transform: translateX(60px); }
  .island-step[data-pos="left"]:hover { transform: translateX(-60px) scale(1.05); }
  .island-step[data-pos="right"]:hover { transform: translateX(60px) scale(1.05); }
}

@media (max-width: 480px) {
  .duo-topbar {
    padding: 12px 16px;
  }
  .metric-pill {
    padding: 4px 10px;
    font-size: 13px;
  }
  .island-circle {
    width: 72px;
    height: 72px;
    font-size: 30px;
  }
  .island-info-card {
    max-width: 150px;
    padding: 4px 8px;
  }
  .island-step[data-pos="left"] { transform: translateX(-40px); }
  .island-step[data-pos="right"] { transform: translateX(40px); }
}

/* ========================================================
   SQLITE PLAN UPLOAD & MANAGEMENT STYLES
   ======================================================== */
.section-header-badge-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.sqlite-status-badge {
  background: rgba(0, 0, 0, 0.25);
  color: #ffffff;
  padding: 3px 12px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.plan-actions-banner-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}

.plan-select-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
}

.plan-select-label {
  font-size: 13px;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.9);
}

.plan-select-dropdown {
  font-family: var(--font-family);
  font-size: 13px;
  font-weight: 800;
  padding: 6px 12px;
  border-radius: 10px;
  border: 2px solid rgba(255, 255, 255, 0.4);
  background: #ffffff;
  color: var(--duo-gray-900);
  cursor: pointer;
  outline: none;
}

.plan-modal-content {
  max-width: 640px;
}

.plan-dropzone {
  border: 3px dashed var(--duo-gray-300);
  border-radius: 16px;
  padding: 28px 20px;
  text-align: center;
  background: var(--duo-gray-100);
  cursor: pointer;
  transition: all 0.2s ease;
}

.plan-dropzone:hover, .plan-dropzone.dragover {
  border-color: var(--duo-green);
  background: var(--duo-green-pale);
}

.dropzone-icon {
  font-size: 44px;
  margin-bottom: 6px;
}

.plan-dropzone h3 {
  font-size: 16px;
  font-weight: 900;
  margin-bottom: 4px;
}

.plan-dropzone p {
  font-size: 13px;
  color: var(--duo-gray-500);
}

.plan-preview-card {
  margin-top: 18px;
  border: 2px solid var(--duo-green-light);
  background: var(--duo-green-pale);
  border-radius: 16px;
  padding: 16px;
  animation: fadeIn 0.2s ease;
}

.preview-badge-status {
  display: inline-block;
  background: var(--duo-green);
  color: #ffffff;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 900;
  margin-bottom: 6px;
}

#preview-plan-title {
  font-size: 17px;
  font-weight: 900;
  color: var(--duo-gray-900);
  margin-bottom: 4px;
}

.preview-plan-meta {
  font-size: 13px;
  color: var(--duo-gray-500);
  margin-bottom: 12px;
}

.preview-days-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-height: 140px;
  overflow-y: auto;
  margin-bottom: 12px;
}

.preview-day-pill {
  background: #ffffff;
  border: 1.5px solid var(--duo-green-light);
  border-radius: 10px;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 800;
  color: var(--duo-gray-800);
}

.plan-options-row {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--duo-green-light);
}

.duo-checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 800;
  color: var(--duo-gray-800);
  cursor: pointer;
}

.duo-checkbox-label input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--duo-green);
}

.stored-plans-section {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 2px solid var(--duo-gray-200);
}

.stored-plans-section h3 {
  font-size: 15px;
  font-weight: 900;
  margin-bottom: 10px;
  color: var(--duo-gray-900);
}

.stored-plans-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 180px;
  overflow-y: auto;
}

.stored-plan-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: var(--duo-gray-100);
  border: 2px solid var(--duo-gray-200);
  border-radius: 12px;
  font-size: 13px;
}

.stored-plan-row.active {
  border-color: var(--duo-green);
  background: var(--duo-green-pale);
}

.plan-row-info strong {
  display: block;
  font-size: 14px;
  color: var(--duo-gray-900);
}

.plan-row-info span {
  font-size: 11px;
  color: var(--duo-gray-500);
}

.plan-row-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ========================================================
   CYCLE COMPLETED & FLEXIBLE PROGRESSION STYLES
   ======================================================== */
.island-current-badge.completed-badge {
  background: #ffc800;
  color: #ffffff;
  border-color: #d4a000;
  box-shadow: 0 4px 0 #b38600;
}

.island-current-badge.completed-badge::after {
  border-top-color: #d4a000;
}

.cycle-completed-card {
  background: linear-gradient(135deg, #fff9e6 0%, #fff2bf 100%);
  border: 3px solid #ffc800;
  border-radius: var(--border-radius-base);
  padding: 20px 24px;
  box-shadow: 0 8px 0 #e5a800, 0 14px 20px rgba(255, 200, 0, 0.2);
  display: flex;
  align-items: center;
  gap: 18px;
  max-width: 520px;
  margin: 30px auto 10px auto;
  animation: duoBounce 2s infinite ease-in-out;
  flex-wrap: wrap;
}

.cycle-trophy-icon {
  font-size: 42px;
}

.cycle-text {
  flex: 1;
}

.cycle-text strong {
  display: block;
  font-size: 16px;
  color: #7a5400;
  margin-bottom: 2px;
}

.cycle-text p {
  font-size: 13px;
  color: #946802;
  margin-bottom: 8px;
}


