/* Catatan Kehamilan - Modern Mobile-First Stylesheet */
:root {
  --primary: #f06292;
  --primary-dark: #d81b60;
  --primary-light: #fce4ec;
  --primary-subtle: #fff5f8;
  --secondary: #8e24aa;
  --accent: #26a69a;
  --accent-light: #e0f2f1;
  --warning: #fb8c00;
  --warning-light: #fff3e0;
  --info: #039be5;
  --info-light: #e1f5fe;
  --success: #43a047;
  --success-light: #e8f5e9;
  
  --bg-main: #f8fafc;
  --bg-card: #ffffff;
  --text-main: #1e293b;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  --border-color: #f1f5f9;
  
  --shadow-sm: 0 2px 6px rgba(220, 80, 120, 0.05);
  --shadow-md: 0 6px 18px rgba(220, 80, 120, 0.08);
  --shadow-lg: 0 12px 28px rgba(220, 80, 120, 0.12);
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

body {
  background-color: var(--bg-main);
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding-bottom: 0;
}

/* App Container */
.app-container {
  width: 100%;
  max-width: 540px;
  min-height: 100vh;
  background: var(--bg-main);
  position: relative;
  overflow-x: hidden;
}

/* Header */
.app-header {
  background: linear-gradient(155deg, #fb7185 0%, #f43f5e 40%, #e11d48 85%, #be123c 100%);
  color: white;
  padding-top: max(calc(env(safe-area-inset-top, 0px) + 36px), 38px);
  padding-left: 20px;
  padding-right: 20px;
  padding-bottom: 24px;
  border-bottom-left-radius: 32px;
  border-bottom-right-radius: 32px;
  box-shadow: 0 10px 30px rgba(225, 29, 72, 0.2);
  position: relative;
}

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

.header-title-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}

.header-icon {
  width: 44px;
  height: 44px;
  background: rgba(255, 255, 255, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  flex-shrink: 0;
  animation: headerHeartbeat 3s ease-in-out infinite;
  transform-origin: center center;
}

@keyframes headerHeartbeat {
  0%, 100% { transform: scale(1); }
  12% { transform: scale(1.1); }
  24% { transform: scale(1); }
  36% { transform: scale(1.06); }
  60% { transform: scale(1); }
}

.header-title {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.4px;
  color: #ffffff;
  line-height: 1.15;
}

.header-subtitle {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.92);
  font-weight: 500;
}

.header-actions-wrap {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-shrink: 0;
}

.btn-icon-header {
  background: rgba(255, 255, 255, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: white;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.06);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  -webkit-tap-highlight-color: transparent;
  flex-shrink: 0;
  padding: 0;
}

.btn-icon-header svg {
  display: block;
}

.btn-icon-header:hover {
  background: rgba(255, 255, 255, 0.32);
  border-color: rgba(255, 255, 255, 0.5);
  transform: translateY(-1px);
}

.btn-icon-header:active {
  transform: scale(0.92);
  background: rgba(255, 255, 255, 0.4);
}

/* ==========================================================================
   PREGNANCY HERO CARD REDESIGN (Aesthetic, Engaging, Modern, Animated)
   ========================================================================== */
.pregnancy-hero-card {
  position: relative;
  background: radial-gradient(135% 120% at 90% 0%, #fff1f2 0%, #ffffff 52%, #fdf2f8 100%);
  color: var(--text-main);
  border-radius: 26px;
  padding: 16px 14px 18px;
  box-shadow: 0 16px 36px -10px rgba(225, 29, 72, 0.12), 0 4px 16px rgba(0, 0, 0, 0.03), inset 0 1px 1px rgba(255, 255, 255, 0.95);
  border: 1.5px solid rgba(254, 205, 211, 0.85);
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  animation: heroCardEntrance 0.55s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes heroCardEntrance {
  0% {
    opacity: 0;
    transform: translateY(16px) scale(0.98);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.hero-card-glow {
  position: absolute;
  top: -40px;
  right: -30px;
  width: 170px;
  height: 170px;
  background: radial-gradient(circle, rgba(251, 113, 133, 0.22) 0%, rgba(251, 113, 133, 0) 70%);
  border-radius: 50%;
  pointer-events: none;
  animation: auraBreathe 6s ease-in-out infinite alternate;
}

@keyframes auraBreathe {
  0% { transform: scale(0.85) translate(0, 0); opacity: 0.5; }
  100% { transform: scale(1.25) translate(-10px, 12px); opacity: 0.95; }
}

.hero-stats-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  position: relative;
  z-index: 2;
  gap: 8px;
}

.hero-week-badge {
  background: linear-gradient(135deg, #f43f5e 0%, #e11d48 100%);
  color: white;
  padding: 4px 11px;
  border-radius: 999px;
  font-weight: 750;
  font-size: 0.75rem;
  letter-spacing: -0.1px;
  box-shadow: 0 4px 12px rgba(225, 29, 72, 0.25);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}

.hero-week-badge .badge-sparkle {
  display: inline-block;
  animation: sparkleRotate 4s ease-in-out infinite;
}

@keyframes sparkleRotate {
  0%, 100% { transform: rotate(0deg) scale(1); }
  50% { transform: rotate(18deg) scale(1.18); }
}

.hero-countdown-pill {
  font-size: 0.71rem;
  color: #92400e;
  font-weight: 750;
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
  border: 1px solid rgba(245, 158, 11, 0.35);
  padding: 4.5px 10px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  box-shadow: 0 2px 6px rgba(217, 119, 6, 0.1);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 65%;
}

.hero-countdown-pill .countdown-icon {
  display: inline-block;
  animation: hourglassTilt 5s ease-in-out infinite;
}

@keyframes hourglassTilt {
  0%, 88%, 100% { transform: rotate(0deg); }
  44% { transform: rotate(180deg); }
}

.hero-main-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  position: relative;
  z-index: 2;
  gap: 8px;
}

.hero-week-box,
.hero-week-display {
  display: flex;
  flex-direction: column;
  gap: 4px;
  border-radius: 12px;
  padding: 2px 2px;
  transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

.hero-week-box:active,
.hero-week-display:active {
  transform: scale(0.97);
}

.hero-week-title-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: nowrap;
}

.hero-week-num {
  font-size: 2.2rem;
  font-weight: 850;
  background: linear-gradient(135deg, #0f172a 20%, #be185d 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -0.8px;
  line-height: 1.05;
  white-space: nowrap;
}

.hero-week-days {
  font-size: 0.8rem;
  color: #475569;
  font-weight: 750;
  background: rgba(241, 245, 249, 0.95);
  border: 1px solid rgba(226, 232, 240, 0.9);
  padding: 2px 8px;
  border-radius: 999px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
  white-space: nowrap;
  display: inline-block;
}

.hero-edit-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.72rem;
  color: #be185d;
  font-weight: 750;
  background: #fdf2f8;
  border: 1px solid #fbcfe8;
  padding: 2px 8px;
  border-radius: 999px;
  width: fit-content;
  box-shadow: 0 1px 2px rgba(190, 24, 93, 0.04);
  transition: all 0.2s ease;
}

.hero-week-box:hover .hero-edit-link,
.hero-week-display:hover .hero-edit-link {
  background: #fce7f3;
  border-color: #f472b6;
}

.hero-edit-pen {
  font-size: 0.72rem;
  display: inline-block;
  transition: transform 0.2s ease;
}

.hero-week-box:hover .hero-edit-pen,
.hero-week-display:hover .hero-edit-pen {
  transform: rotate(-15deg);
}

.hero-edit-arrow {
  font-size: 0.82rem;
  line-height: 1;
  color: #e11d48;
}

.hero-completion-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: linear-gradient(135deg, #fff1f2 0%, #ffe4e6 100%);
  border: 1.5px solid #fecdd3;
  color: #be123c;
  font-weight: 800;
  font-size: 0.76rem;
  padding: 5px 12px;
  border-radius: 999px;
  box-shadow: 0 2px 8px rgba(225, 29, 72, 0.08);
  white-space: nowrap;
  flex-shrink: 0;
}

.hero-completion-pill .pill-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #f43f5e;
  position: relative;
  flex-shrink: 0;
  animation: radarPulse 2s infinite ease-out;
}

@keyframes radarPulse {
  0% {
    transform: scale(0.9);
    box-shadow: 0 0 0 0 rgba(244, 63, 94, 0.7);
  }
  70% {
    transform: scale(1.05);
    box-shadow: 0 0 0 6px rgba(244, 63, 94, 0);
  }
  100% {
    transform: scale(0.9);
    box-shadow: 0 0 0 0 rgba(244, 63, 94, 0);
  }
}

/* Fetal Visual Interactive Card */
.hero-fetal-visual {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 14px;
  background: #ffffff;
  padding: 12px 14px;
  border-radius: 20px;
  border: 1.5px solid #fecdd3;
  position: relative;
  box-shadow: 0 4px 14px rgba(225, 29, 72, 0.05);
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  -webkit-tap-highlight-color: transparent;
  z-index: 2;
}

.hero-fetal-visual:hover {
  border-color: #f43f5e;
  box-shadow: 0 8px 24px rgba(225, 29, 72, 0.12);
  transform: translateY(-2px);
}

.hero-fetal-visual:active {
  transform: scale(0.98);
}

.fetal-icon-wrapper {
  position: relative;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.fetal-icon-large {
  font-size: 2.4rem;
  line-height: 1;
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, #ffffff 0%, #fff1f2 100%);
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 18px rgba(225, 29, 72, 0.14), 0 0 0 1.5px rgba(255, 228, 230, 0.9);
  animation: floatFruitCute 3.6s ease-in-out infinite;
  z-index: 2;
}

@keyframes floatFruitCute {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
  }
  50% {
    transform: translateY(-5px) rotate(3deg) scale(1.04);
  }
}

.fetal-icon-shadow {
  width: 36px;
  height: 6px;
  background: radial-gradient(ellipse at center, rgba(225, 29, 72, 0.22) 0%, rgba(225, 29, 72, 0) 70%);
  border-radius: 50%;
  margin-top: 3px;
  animation: shadowScale 3.6s ease-in-out infinite;
}

@keyframes shadowScale {
  0%, 100% {
    transform: scale(1);
    opacity: 0.6;
  }
  50% {
    transform: scale(0.72);
    opacity: 0.25;
  }
}

.fetal-info-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.fetal-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2px;
}

.fetal-tag-pill {
  font-size: 0.65rem;
  font-weight: 800;
  color: #9f1239;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  background: rgba(255, 228, 230, 0.75);
  padding: 1px 7px;
  border-radius: 6px;
}

.fetal-explore-chip {
  font-size: 0.68rem;
  font-weight: 800;
  color: #be185d;
  background: #fce7f3;
  padding: 2px 8px;
  border-radius: 999px;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  transition: all 0.2s ease;
}

.hero-fetal-visual:hover .fetal-explore-chip {
  background: #fbcfe8;
  transform: translateX(2px);
}

.fetal-fruit-title {
  font-size: 1.05rem;
  color: #881337;
  font-weight: 850;
  margin: 1px 0 4px;
  letter-spacing: -0.2px;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.fetal-pills-row {
  display: flex;
  gap: 6px;
  margin-bottom: 5px;
  flex-wrap: wrap;
}

.fetal-metric-pill {
  font-size: 0.72rem;
  font-weight: 750;
  color: #475569;
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid #fecdd3;
  padding: 2px 8px;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
}

.fetal-snippet-text {
  font-size: 0.75rem;
  color: #64748b;
  line-height: 1.38;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Gestational 40-Week Progress Bar with Baby Pin */
.progress-container {
  margin-top: 4px;
  position: relative;
  z-index: 2;
}

.progress-header-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.71rem;
  color: #64748b;
  font-weight: 700;
  margin-bottom: 10px;
}

.progress-bar-track-wrap {
  position: relative;
  padding: 8px 0 6px;
}

.progress-bar-track {
  width: 100%;
  height: 11px;
  background: #f1f5f9;
  border-radius: 999px;
  overflow: hidden;
  position: relative;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.06);
}

.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #fb7185 0%, #f43f5e 50%, #e11d48 100%);
  border-radius: 999px;
  transition: width 0.9s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
}

.progress-shimmer {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.7) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  animation: shimmer-sweep 2.5s infinite linear;
}

@keyframes shimmer-sweep {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

/* Sliding Baby Pin */
.progress-baby-pin {
  position: absolute;
  top: 0px;
  transform: translateX(-50%);
  transition: left 0.9s cubic-bezier(0.34, 1.56, 0.64, 1);
  pointer-events: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 5;
}

.baby-pin-avatar {
  width: 28px;
  height: 28px;
  background: #ffffff;
  border: 2.2px solid #e11d48;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  box-shadow: 0 4px 12px rgba(225, 29, 72, 0.35), 0 0 0 3px rgba(254, 205, 211, 0.6);
  animation: babyPinBounce 3s ease-in-out infinite;
}

@keyframes babyPinBounce {
  0%, 100% {
    transform: translateY(0) scale(1);
  }
  20% {
    transform: translateY(-4px) scale(1.08) rotate(-6deg);
  }
  40% {
    transform: translateY(0) scale(1) rotate(0deg);
  }
  60% {
    transform: translateY(-2px) scale(1.04) rotate(6deg);
  }
  80% {
    transform: translateY(0) scale(1) rotate(0deg);
  }
}

.trimester-markers {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin-top: 10px;
}

.trim-mark {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 5px 3px;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  text-align: center;
  transition: all 0.25s ease;
  user-select: none;
}

.trim-mark .trim-title {
  font-size: 0.72rem;
  font-weight: 800;
  color: #64748b;
  line-height: 1.2;
  white-space: nowrap;
}

.trim-mark .trim-sub {
  font-size: 0.62rem;
  font-weight: 700;
  color: #94a3b8;
  line-height: 1.2;
  margin-top: 2px;
  white-space: nowrap;
}

.trim-mark.active {
  background: linear-gradient(135deg, #fff1f2 0%, #ffe4e6 100%);
  border-color: #fecdd3;
  box-shadow: 0 2px 6px rgba(225, 29, 72, 0.07);
}

.trim-mark.active .trim-title {
  color: #be123c;
}

.trim-mark.active .trim-sub {
  color: #e11d48;
}

/* Main Content Views */
.main-content {
  padding: 16px 16px calc(85px + env(safe-area-inset-bottom, 24px));
}

.tab-view {
  display: none;
}

.tab-view.active {
  display: block;
  animation: tab-enter 0.32s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes tab-enter {
  0% {
    opacity: 0;
    transform: translateY(12px) scale(0.985);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.tab-view.active .card-section {
  animation: card-appear 0.38s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.tab-view.active .card-section:nth-child(1) { animation-delay: 0.03s; }
.tab-view.active .card-section:nth-child(2) { animation-delay: 0.07s; }
.tab-view.active .card-section:nth-child(3) { animation-delay: 0.11s; }
.tab-view.active .card-section:nth-child(4) { animation-delay: 0.15s; }
.tab-view.active .card-section:nth-child(5) { animation-delay: 0.19s; }

@keyframes card-appear {
  0% {
    opacity: 0;
    transform: translateY(14px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Cards */
.card-section {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 18px 16px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 16px;
  border: 1px solid rgba(240, 98, 146, 0.12);
}

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

.section-title {
  font-size: 1rem;
  font-weight: 700;
  color: #374151;
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-title .badge-icon {
  display: inline-flex;
  font-size: 1.1rem;
}

/* Quick Action Buttons */
.quick-actions-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 18px;
}

.btn-action-card {
  background: white;
  border: 1px solid #ffd4df;
  border-radius: 16px;
  padding: 14px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 3px 8px rgba(238, 111, 140, 0.08);
}

.btn-action-card:active {
  transform: translateY(2px);
  background: #fff5f8;
}

.action-icon-circle {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
}

.btn-action-card span {
  font-size: 0.78rem;
  font-weight: 600;
  color: #4b5563;
  line-height: 1.2;
}

.color-usg { background: #fce4ec; color: #c2185b; }
.color-clinic { background: #e0f2f1; color: #00796b; }
.color-voice { background: #fff3e0; color: #e65100; }
.color-birth { background: #ede7f6; color: #512da8; }

/* Buttons */
.btn-primary {
  background: linear-gradient(135deg, #f06292, #e91e63);
  color: white;
  border: none;
  padding: 12px 20px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 14px rgba(233, 30, 99, 0.3);
  transition: all 0.2s;
  width: 100%;
}

.btn-primary:active {
  transform: scale(0.98);
}

.btn-secondary {
  background: #fce4ec;
  color: #c2185b;
  border: 1px solid #f8bbd0;
  padding: 10px 18px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s;
}

.btn-secondary:active {
  background: #f8bbd0;
}

.btn-outline {
  background: transparent;
  color: #6b7280;
  border: 1px solid #d1d5db;
  padding: 9px 14px;
  border-radius: 10px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 0.78rem;
  border-radius: 8px;
}

/* USG Scanner Feature Styles */
.usg-upload-box {
  border: 2px dashed #f06292;
  border-radius: 18px;
  background: #fff8fa;
  padding: 24px 16px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  position: relative;
  overflow: hidden;
}

.usg-upload-box:hover, .usg-upload-box.dragover {
  background: #fce4ec;
  border-color: #d81b60;
}

.usg-upload-icon {
  font-size: 2.8rem;
  margin-bottom: 10px;
  color: #f06292;
}

.usg-preview-wrap {
  position: relative;
  width: 100%;
  max-height: 280px;
  border-radius: 14px;
  overflow: hidden;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  box-shadow: inset 0 0 10px rgba(0,0,0,0.5);
}

.usg-preview-img {
  max-width: 100%;
  max-height: 280px;
  object-fit: contain;
  display: block;
}

.ocr-scanning-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.65);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: white;
  gap: 12px;
  backdrop-filter: blur(2px);
  z-index: 10;
}

.scan-laser-line {
  position: absolute;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, transparent, #00e676, transparent);
  box-shadow: 0 0 12px #00e676;
  animation: scanLaser 2s linear infinite alternate;
}

@keyframes scanLaser {
  0% { top: 5%; }
  100% { top: 95%; }
}

.spinner {
  width: 38px;
  height: 38px;
  border: 4px solid rgba(255, 255, 255, 0.25);
  border-top-color: #f06292;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Hasil Penjelasan USG - Grid & Cards */
.usg-interpretation-card {
  background: white;
  border-radius: 16px;
  border: 1px solid #ffd4df;
  overflow: hidden;
  margin-top: 16px;
}

.usg-summary-banner {
  background: linear-gradient(135deg, #fce4ec, #f8bbd0);
  padding: 14px 16px;
  border-bottom: 1px solid #f48fb1;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.usg-summary-banner h3 {
  font-size: 0.95rem;
  color: #880e4f;
  font-weight: 700;
}

.usg-badge-normal {
  background: #e8f5e9;
  color: #2e7d32;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.usg-metrics-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  padding: 14px;
}

.metric-item-box {
  background: #fff8fa;
  border: 1px solid #f8bbd0;
  border-radius: 12px;
  padding: 10px 12px;
  position: relative;
}

.metric-code {
  font-size: 0.72rem;
  font-weight: 800;
  color: #c2185b;
  letter-spacing: 0.5px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.metric-value {
  font-size: 1.15rem;
  font-weight: 700;
  color: #1f2937;
  margin: 2px 0;
}

.metric-meaning {
  font-size: 0.7rem;
  color: #6b7280;
  line-height: 1.25;
}

.metric-status {
  font-size: 0.65rem;
  font-weight: 600;
  color: #2e7d32;
  margin-top: 4px;
  display: inline-block;
  background: #e8f5e9;
  padding: 1px 6px;
  border-radius: 6px;
}

.usg-explanation-box {
  padding: 14px 16px;
  background: #fdfbf7;
  border-top: 1px dashed #eedbcf;
}

.usg-explanation-box h4 {
  font-size: 0.85rem;
  color: #8d4f0d;
  font-weight: 700;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.usg-explanation-box p {
  font-size: 0.78rem;
  color: #555;
  line-height: 1.45;
  margin-bottom: 8px;
}

.usg-explanation-box ul {
  padding-left: 18px;
  font-size: 0.76rem;
  color: #555;
  line-height: 1.5;
}

/* History USG Grid */
.usg-history-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.usg-history-item {
  background: white;
  border: 1px solid #ffe0e9;
  border-radius: 14px;
  padding: 12px;
  display: flex;
  gap: 12px;
  align-items: center;
  box-shadow: var(--shadow-sm);
}

.usg-history-thumb {
  width: 70px;
  height: 70px;
  border-radius: 10px;
  object-fit: cover;
  background: #222;
  flex-shrink: 0;
}

.usg-history-meta {
  flex: 1;
  min-width: 0;
}

.usg-history-date {
  font-size: 0.72rem;
  color: #9ca3af;
  font-weight: 600;
}

.usg-history-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: #1f2937;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.usg-history-summary {
  font-size: 0.74rem;
  color: #6b7280;
  margin-top: 2px;
}

/* Form Styles */
.form-group {
  margin-bottom: 14px;
}

.form-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: #4b5563;
  margin-bottom: 5px;
}

.form-control {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid #d1d5db;
  border-radius: 10px;
  font-size: 0.88rem;
  color: #1f2937;
  background: #fff;
  outline: none;
  transition: border-color 0.2s;
}

.form-control:focus {
  border-color: #f06292;
  box-shadow: 0 0 0 3px rgba(240, 98, 146, 0.15);
}

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

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

/* Modals */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(3px);
  display: none;
  align-items: flex-end;
  justify-content: center;
  z-index: 1000;
}

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

.modal-card {
  background: white;
  width: 100%;
  max-width: 540px;
  max-height: 90vh;
  border-top-left-radius: 24px;
  border-top-right-radius: 24px;
  overflow-y: auto;
  padding: 20px 18px calc(24px + env(safe-area-inset-bottom, 20px));
  animation: slideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 12px;
  border-bottom: 1px solid #f3f4f6;
  margin-bottom: 16px;
}

.modal-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #1f2937;
}

.btn-close-modal {
  background: #f3f4f6;
  border: none;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6b7280;
}

/* Bottom Navigation Bar - Floating Frosted Glass Dock (Modern & Engaging) */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 520px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(28px) saturate(200%);
  -webkit-backdrop-filter: blur(28px) saturate(200%);
  border-top: 1.5px solid rgba(254, 205, 211, 0.85);
  border-top-left-radius: 26px;
  border-top-right-radius: 26px;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  padding: 8px 8px max(env(safe-area-inset-bottom, 18px), 18px);
  z-index: 900;
  box-shadow: 0 -10px 36px rgba(225, 29, 72, 0.1), 0 -2px 8px rgba(0, 0, 0, 0.03);
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  cursor: pointer;
  color: #64748b;
  padding: 4px 0 2px;
  gap: 3px;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  -webkit-tap-highlight-color: transparent !important;
  outline: none !important;
  position: relative;
  user-select: none;
}

.nav-item .nav-icon {
  width: 44px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 16px;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
}

.nav-item .nav-icon svg {
  width: 24px;
  height: 24px;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  overflow: visible;
}

.nav-item .nav-label {
  font-size: 0.67rem;
  font-weight: 650;
  letter-spacing: -0.2px;
  color: #64748b;
  transition: all 0.2s ease;
  white-space: nowrap;
}

/* Inactive Duotone Accents */
.nav-item:not(.active) .icon-heart {
  color: #fb7185;
}

.nav-item:not(.active) .icon-pulse {
  color: #38bdf8;
}

.nav-item:not(.active) .icon-sparkle {
  color: #f59e0b;
}

.nav-item:not(.active) .icon-sparkle-sm {
  color: #fbbf24;
}

.nav-item:not(.active) .icon-clip {
  color: #f43f5e;
  opacity: 0.75;
}

.nav-item:not(.active) .icon-ecg {
  color: #e11d48;
}

.nav-item:not(.active) .icon-stroller-wheel {
  color: #94a3b8;
}

.nav-item:hover {
  color: #be185d;
}

.nav-item:active {
  transform: scale(0.92);
}

/* Active Icon States */
.nav-item.active {
  color: #be123c;
}

.nav-item.active .nav-icon {
  background: linear-gradient(135deg, #ffe4e6 0%, #fff1f2 100%);
  box-shadow: 0 4px 14px rgba(225, 29, 72, 0.22);
  border: 1.5px solid rgba(254, 205, 211, 0.95);
  transform: translateY(-4px);
  animation: nav-icon-pop 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.nav-item.active .nav-icon svg {
  color: #e11d48;
  transform: scale(1.08);
}

/* Fill effect on active icons */
.nav-item.active .icon-outline {
  fill: rgba(244, 63, 94, 0.12);
}

.nav-item.active .icon-heart {
  color: #e11d48;
  animation: heart-beat 1.6s ease-in-out infinite;
}

.nav-item.active .icon-lens-ring {
  fill: rgba(244, 63, 94, 0.18);
}

.nav-item.active .icon-pulse {
  color: #e11d48;
}

.nav-item.active .icon-sparkle {
  color: #f59e0b;
  animation: sparkle-spin 2.2s ease-in-out infinite;
}

.nav-item.active .icon-clip {
  color: #e11d48;
  opacity: 0.9;
}

.nav-item.active .icon-ecg {
  color: #be123c;
}

.nav-item.active .icon-stroller-canopy {
  fill: rgba(244, 63, 94, 0.15);
}

.nav-item.active .icon-stroller-body {
  fill: rgba(244, 63, 94, 0.1);
}

.nav-item.active .icon-stroller-wheel {
  color: #be123c;
}

.nav-item.active .nav-label {
  font-weight: 800;
  color: #be123c;
  transform: scale(1.02);
}

/* Glowing active dot */
.nav-item.active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: #e11d48;
  box-shadow: 0 0 10px rgba(225, 29, 72, 0.9);
  animation: pulse-dot 1.8s ease-in-out infinite;
}

@keyframes nav-icon-pop {
  0% { transform: scale(0.8) translateY(0); }
  60% { transform: scale(1.18) translateY(-6px); }
  100% { transform: scale(1) translateY(-4px); }
}

@keyframes heart-beat {
  0%, 100% { transform: scale(1); }
  15% { transform: scale(1.22); }
  30% { transform: scale(1); }
  45% { transform: scale(1.15); }
}

@keyframes sparkle-spin {
  0%, 100% { transform: rotate(0deg) scale(1); }
  50% { transform: rotate(15deg) scale(1.25); }
}

/* List Items / Pemeriksaan Cards - Upgraded Medical Standard */
.record-item-card {
  background: #ffffff;
  border-radius: 18px;
  border: 1px solid #fed7aa;
  border-left: 4px solid #f43f5e;
  padding: 16px;
  margin-bottom: 12px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.record-item-card:hover {
  box-shadow: 0 4px 16px rgba(244, 63, 94, 0.08);
  transform: translateY(-1px);
}

.record-top-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.record-week-tag {
  background: linear-gradient(135deg, #fff1f2, #ffe4e6);
  color: #be123c;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid #fecdd3;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.record-vitals-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  background: #f8fafc;
  border: 1px solid #f1f5f9;
  padding: 8px 10px;
  border-radius: 12px;
  font-size: 0.76rem;
  margin-bottom: 10px;
}

.vital-tag {
  display: flex;
  flex-direction: column;
  text-align: center;
}

.vital-lbl {
  color: #64748b;
  font-size: 0.65rem;
  font-weight: 700;
  margin-bottom: 2px;
}

.vital-val {
  font-weight: 800;
  color: #1e293b;
  font-size: 0.78rem;
}

.record-notes-box {
  background: #fdf2f8;
  border: 1px solid #fbcfe8;
  border-radius: 10px;
  padding: 8px 10px;
  font-size: 0.76rem;
  color: #831843;
  line-height: 1.45;
  margin-bottom: 6px;
  display: flex;
  align-items: flex-start;
  gap: 6px;
}

.record-meds-box {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 10px;
  padding: 8px 10px;
  font-size: 0.76rem;
  color: #14532d;
  line-height: 1.45;
  margin-bottom: 6px;
  display: flex;
  align-items: flex-start;
  gap: 6px;
}

.record-footer-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 8px;
  padding-top: 6px;
  border-top: 1px solid #f8fafc;
}

/* Checklist Bersalin & Birth Plan */
.checklist-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-bottom: 1px solid #f3f4f6;
  font-size: 0.82rem;
}

.checklist-item:last-child {
  border-bottom: none;
}

.checklist-item input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: #e91e63;
  cursor: pointer;
}

.checklist-item.done span {
  text-decoration: line-through;
  color: #9ca3af;
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 28px 16px;
  color: #9ca3af;
}

.empty-icon {
  font-size: 2.8rem;
  margin-bottom: 8px;
  opacity: 0.8;
}

.empty-state p {
  font-size: 0.85rem;
  color: #6b7280;
}

/* Toast Notification */
.toast {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: #1f2937;
  color: white;
  padding: 10px 18px;
  border-radius: 30px;
  font-size: 0.82rem;
  box-shadow: 0 4px 14px rgba(0,0,0,0.25);
  opacity: 0;
  visibility: hidden;
  transition: all 0.25s ease;
  z-index: 2000;
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.toast.show {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

/* ==========================================================================
   BUNDASEHAT FASE 2, 3, 4 ENHANCEMENTS
   (5-Tab Nav, Nutrisi & Asisten AI, Crop Tool, Biometrik/PIN, Ayah Siaga, PWA)
   ========================================================================== */

/* 5-Tab Navigation consolidated in main section */

/* Badges Status Keamanan Makanan & Medis */
.badge-safe {
  background: #dcfce7;
  color: #15803d;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.badge-caution {
  background: #fef3c7;
  color: #b45309;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.badge-danger {
  background: #fee2e2;
  color: #b91c1c;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* Tab Nutrisi: Search & Chips */
.search-box-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  border: 1.5px solid #fbcfe8;
  border-radius: 14px;
  padding: 8px 14px;
  margin-bottom: 12px;
  box-shadow: var(--shadow-sm);
  transition: border-color 0.2s;
}

.search-box-wrap:focus-within {
  border-color: #d81b60;
  box-shadow: 0 0 0 3px rgba(216, 27, 96, 0.12);
}

.search-box-wrap input {
  border: none;
  background: transparent;
  outline: none;
  font-size: 0.88rem;
  width: 100%;
  color: #1f2937;
}

.chips-scroll-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 6px;
  margin-bottom: 12px;
  scrollbar-width: none;
}
.chips-scroll-row::-webkit-scrollbar { display: none; }

.chip-btn {
  background: #ffffff;
  border: 1px solid #fbcfe8;
  color: #6b7280;
  font-size: 0.74rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 20px;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.2s;
}

.chip-btn.active, .chip-btn:hover {
  background: #fce4ec;
  color: #be185d;
  border-color: #f472b6;
  font-weight: 700;
}

/* Banner Kamera Scan Makanan Multimodal */
.camera-banner {
  background: linear-gradient(135deg, #fff1f2, #ffe4e6);
  border: 2px dashed #fb7185;
  border-radius: 16px;
  padding: 16px;
  text-align: center;
  cursor: pointer;
  margin-bottom: 14px;
  transition: transform 0.15s, background-color 0.2s;
}

.camera-banner:active {
  transform: scale(0.98);
  background: #fed7aa;
}

.camera-banner .cam-icon {
  font-size: 2.2rem;
  margin-bottom: 4px;
}

.camera-banner h4 {
  font-size: 0.95rem;
  color: #9f1239;
  font-weight: 800;
  margin-bottom: 2px;
}

.camera-banner p {
  font-size: 0.75rem;
  color: #4b5563;
}

/* Chat Asisten Kehamilan */
.chat-container {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 300px;
  max-height: 480px;
  overflow-y: auto;
  padding: 14px 10px;
  margin-bottom: 12px;
  background: #fffbfa;
  border: 1px solid #fce7f3;
  border-radius: 18px;
  scroll-behavior: smooth;
}

.chat-bubble-ai {
  background: #ffffff;
  border: 1px solid #fbcfe8;
  border-radius: 20px 20px 20px 6px;
  padding: 14px 16px;
  font-size: 0.85rem;
  line-height: 1.6;
  color: #1f2937;
  max-width: 95%;
  align-self: flex-start;
  box-shadow: 0 3px 12px rgba(244, 114, 182, 0.08);
  word-break: break-word;
}

.chat-bubble-ai .ai-msg-h {
  font-size: 0.95rem;
  font-weight: 700;
  color: #9d174d;
  margin: 12px 0 6px 0;
  display: flex;
  align-items: center;
  gap: 6px;
}
.chat-bubble-ai .ai-msg-h:first-child {
  margin-top: 0;
}

.chat-bubble-ai .ai-msg-bold {
  font-weight: 700;
  color: #831843;
}

.chat-bubble-ai .ai-msg-bullet {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 6px 0;
  line-height: 1.5;
}

.chat-bubble-ai .ai-bullet-dot {
  flex-shrink: 0;
  font-size: 0.85rem;
  line-height: 1.4;
}

.chat-bubble-ai .ai-num-dot {
  flex-shrink: 0;
  background: #fce4ec;
  color: #be185d;
  font-weight: 700;
  font-size: 0.72rem;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
}

.chat-bubble-ai .ai-bullet-text {
  flex: 1;
}

.chat-bubble-ai .ai-msg-gap {
  height: 8px;
}

.status-badge-inline {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.75rem;
  margin: 4px 0;
}
.status-safe {
  background: #dcfce7;
  color: #15803d;
  border: 1px solid #bbf7d0;
}
.status-warn {
  background: #fef9c3;
  color: #a16207;
  border: 1px solid #fef08a;
}
.status-danger {
  background: #fee2e2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}

.chat-bubble-user {
  background: linear-gradient(135deg, #d81b60, #be185d);
  color: white;
  border-radius: 20px 20px 6px 20px;
  padding: 10px 16px;
  font-size: 0.85rem;
  line-height: 1.45;
  max-width: 88%;
  align-self: flex-end;
  margin-left: auto;
  box-shadow: 0 4px 12px rgba(190, 24, 93, 0.2);
}

.quick-prompts-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 6px;
  margin-bottom: 10px;
  scrollbar-width: none;
}
.quick-prompts-row::-webkit-scrollbar { display: none; }

.btn-quick-prompt {
  background: #fff5f8;
  border: 1px solid #fbcfe8;
  color: #9d174d;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 7px 12px;
  border-radius: 14px;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.15s;
}

.btn-quick-prompt:hover, .btn-quick-prompt:active {
  background: #fce4ec;
  border-color: #f472b6;
  color: #831843;
}

/* Chat Input Bar Modern (Gaya iOS / WhatsApp) */
.chat-input-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  border: 1.5px solid #f472b6;
  border-radius: 28px;
  padding: 4px 6px 4px 14px;
  box-shadow: 0 4px 14px rgba(244, 114, 182, 0.12);
  width: 100%;
  box-sizing: border-box;
}

.chat-input-field {
  flex: 1;
  min-width: 0;
  border: none !important;
  outline: none !important;
  background: transparent !important;
  font-size: 0.85rem;
  color: #1f2937;
  padding: 8px 0 !important;
  box-shadow: none !important;
}

.chat-input-field::placeholder {
  color: #9ca3af;
  font-size: 0.82rem;
}

.btn-chat-send {
  width: 38px;
  height: 38px;
  min-width: 38px;
  border-radius: 50%;
  background: linear-gradient(135deg, #f06292, #d81b60);
  color: white;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 3px 10px rgba(216, 27, 96, 0.35);
  transition: transform 0.15s, box-shadow 0.15s;
}

.btn-chat-send:active {
  transform: scale(0.92);
}

.btn-clean-chat {
  background: #fff1f2;
  border: 1px solid #fecdd3;
  color: #be123c;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 5px 10px;
  border-radius: 14px;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}
.btn-clean-chat:hover, .btn-clean-chat:active {
  background: #ffe4e6;
}

/* Crop Tool Box Interaktif USG */
.crop-modal-canvas-wrap {
  position: relative;
  background: #090a0f;
  border-radius: 14px;
  overflow: hidden;
  max-height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}

.crop-overlay-rect {
  position: absolute;
  top: 10%;
  right: 5%;
  width: 48%;
  height: 75%;
  border: 2px dashed #00e676;
  box-shadow: 0 0 0 1000px rgba(0, 0, 0, 0.55);
  border-radius: 8px;
  cursor: move;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 6px;
  box-sizing: border-box;
}

.crop-tag-badge {
  background: #00e676;
  color: #000;
  font-size: 0.6rem;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 4px;
  align-self: flex-start;
}

.crop-hint-text {
  color: #ffffff;
  font-size: 0.62rem;
  text-align: right;
  text-shadow: 0 1px 3px #000;
}

/* Lockscreen & Numpad Overlay */
.lockscreen-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: #fff5f8;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 2200;
  padding: 24px;
  text-align: center;
}

.lockscreen-overlay.active {
  display: flex !important;
}

.pin-display {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin: 16px 0;
}

.pin-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid #be185d;
  background: transparent;
  transition: all 0.2s;
}

.pin-dot.filled {
  background: #be185d;
  transform: scale(1.18);
}

.numpad-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  max-width: 270px;
  margin: 0 auto;
}

.numpad-key {
  background: #ffffff;
  border: 1.5px solid #fbcfe8;
  border-radius: 16px;
  padding: 14px;
  font-size: 1.25rem;
  font-weight: 800;
  color: #1e293b;
  cursor: pointer;
  user-select: none;
  box-shadow: 0 2px 6px rgba(0,0,0,0.04);
  transition: background 0.15s, transform 0.1s;
}

.numpad-key:active {
  background: #fce4ec;
  transform: scale(0.95);
  color: #be185d;
}

/* Onboarding Wizard 3-Langkah */
.onboarding-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2300;
  padding: 16px;
  overflow-y: auto;
}

.onboarding-overlay.active {
  display: flex !important;
}

.onboarding-card {
  background: #ffffff;
  width: 100%;
  max-width: 410px;
  border-radius: 26px;
  padding: 24px 20px;
  box-shadow: 0 20px 45px rgba(216, 27, 96, 0.22);
  border: 1px solid #fce4ec;
  position: relative;
}

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

.onboarding-steps-indicator {
  display: flex;
  gap: 6px;
}

.step-dot {
  width: 24px;
  height: 6px;
  background: #f1f5f9;
  border-radius: 4px;
  transition: all 0.3s;
}

.step-dot.active {
  background: linear-gradient(135deg, #f06292, #be185d);
  width: 34px;
}

.step-dot.passed {
  background: #10b981;
}

.btn-skip-ob {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
}

.onboarding-step {
  display: none;
  flex-direction: column;
}

.onboarding-step.active {
  display: flex !important;
}

.ob-icon-wrapper {
  width: 58px;
  height: 58px;
  border-radius: 18px;
  background: #fce4ec;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  font-size: 1.8rem;
}

.ob-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: #1f2937;
  margin-bottom: 6px;
  line-height: 1.3;
}

.ob-desc {
  font-size: 0.78rem;
  color: #64748b;
  line-height: 1.45;
  margin-bottom: 16px;
}

.ob-calc-toggle {
  display: flex;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 4px;
  margin-bottom: 14px;
  gap: 4px;
}

.ob-toggle-btn {
  flex: 1;
  background: transparent;
  border: none;
  padding: 8px;
  font-size: 0.74rem;
  font-weight: 600;
  color: #64748b;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}

.ob-toggle-btn.active {
  background: white;
  color: #be185d;
  font-weight: 800;
  box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}

.ob-result-card {
  background: #fff8fa;
  border: 1.5px solid #fbcfe8;
  border-radius: 14px;
  padding: 12px;
  margin-bottom: 16px;
}

.ob-privacy-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
  margin-bottom: 16px;
}

/* Banner PWA Install Prompt */
.pwa-install-banner {
  background: linear-gradient(135deg, #fdf2f8, #fce4ec);
  border: 1px solid #fbcfe8;
  border-radius: 14px;
  padding: 12px 14px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.pwa-install-banner .pwa-text h5 {
  font-size: 0.82rem;
  font-weight: 800;
  color: #be185d;
  margin-bottom: 2px;
}

.pwa-install-banner .pwa-text p {
  font-size: 0.72rem;
  color: #6b7280;
}

.btn-pwa-install {
  background: #d81b60;
  color: white;
  border: none;
  font-size: 0.74rem;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 10px;
  white-space: nowrap;
  cursor: pointer;
}

/* Soft Reminder Banner Onboarding */
.soft-reminder-banner {
  background: #fffbeb;
  border: 1px solid #fef3c7;
  color: #92400e;
  border-radius: 14px;
  padding: 10px 14px;
  font-size: 0.78rem;
  margin-bottom: 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

/* ==========================================================================
   BUNDASEHAT ADVANCED CLINICAL, EMOTIONAL & BONDING FEATURES
   (Charts, Bump Gallery, Baby Names, Audio Relaxation, TT Vaccine, Nudge, Cost)
   ========================================================================== */

/* Nudge Sayang Ayah Siaga Row */
.nudge-buttons-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}

.btn-nudge {
  background: #ffffff;
  border: 1px solid #fbcfe8;
  border-radius: 12px;
  padding: 8px 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  transition: transform 0.15s, background-color 0.15s;
}

.btn-nudge:active {
  transform: scale(0.95);
  background: #fdf2f8;
}

.btn-nudge .nudge-icon {
  font-size: 1.4rem;
}

.btn-nudge span {
  font-size: 0.65rem;
  font-weight: 700;
  color: #831843;
  text-align: center;
}

/* Audio Player Widget Relaksasi Detak Jantung */
.audio-player-card {
  background: linear-gradient(135deg, #fdf4ff 0%, #fae8ff 100%);
  border: 1.5px solid #e9d5ff;
  border-radius: 18px;
  padding: 16px;
  margin-bottom: 14px;
}

.audio-controls-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
}

.btn-audio-play {
  background: linear-gradient(135deg, #a855f7, #7e22ce);
  color: white;
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(168, 85, 247, 0.35);
  transition: transform 0.15s;
}

.btn-audio-play.playing {
  animation: pulse 1.5s infinite;
  background: linear-gradient(135deg, #ef4444, #b91c1c);
}

/* Canvas Medical Charts */
.chart-container-card {
  background: white;
  border-radius: 16px;
  border: 1px solid #f3e8ee;
  padding: 14px;
  margin-bottom: 14px;
  box-shadow: var(--shadow-sm);
}

.chart-canvas-box {
  width: 100%;
  height: 180px;
  margin-top: 8px;
  position: relative;
}

.chart-canvas-box canvas {
  width: 100% !important;
  height: 100% !important;
  display: block;
}

/* Bump Gallery (Foto Perut Bulanan) */
.bump-gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 12px;
}

.bump-slot {
  background: #ffffff;
  border: 1.5px solid #f1f5f9;
  border-radius: 18px;
  height: 125px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  overflow: hidden;
  position: relative;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
}

.bump-slot:active {
  transform: scale(0.97);
}

.bump-slot:hover {
  border-color: #f43f5e;
  box-shadow: 0 4px 14px rgba(244, 63, 94, 0.12);
}

.bump-slot.has-photo {
  border-color: transparent;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

.bump-slot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.bump-slot:hover img {
  transform: scale(1.05);
}

.bump-slot-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  background: rgba(15, 23, 42, 0.72);
  color: #ffffff;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 8px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 2;
  letter-spacing: -0.2px;
}

.bump-slot-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: #fafaf9;
}

.bump-slot-icon-wrap {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #fff1f2;
  color: #e11d48;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.bump-slot:hover .bump-slot-icon-wrap {
  background: #e11d48;
  color: #ffffff;
  transform: scale(1.08);
}

.bump-slot-add-text {
  font-size: 0.7rem;
  font-weight: 700;
  color: #64748b;
  letter-spacing: -0.2px;
}

.bump-slot-edit-overlay {
  position: absolute;
  bottom: 8px;
  right: 8px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: #0f172a;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
  backdrop-filter: blur(4px);
}

/* Imunisasi Tetanus Toksoid (TT) Cards */
.tt-item-card {
  background: white;
  border: 1px solid #f3e8ee;
  border-radius: 12px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.tt-item-card.done {
  background: #f0fdf4;
  border-color: #bbf7d0;
}

/* Wishlist & Inspirasi Nama Bayi */
.baby-name-card {
  background: white;
  border: 1px solid #f3e8ee;
  border-radius: 14px;
  padding: 12px 14px;
  margin-bottom: 10px;
  box-shadow: var(--shadow-sm);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
}

.btn-wishlist {
  background: #fff1f2;
  border: 1px solid #fecdd3;
  color: #e11d48;
  font-size: 1rem;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.btn-wishlist.active {
  background: #e11d48;
  color: white;
}


/* ==========================================================================
   KICK COUNTER WIDGET (HOME & MODAL)
   ========================================================================== */
.kick-widget-card {
  background: linear-gradient(135deg, #ffffff 0%, #fff1f2 100%);
  border: 1px solid #ffe4e6;
  border-radius: 20px;
  box-shadow: 0 4px 18px rgba(225, 29, 72, 0.04);
  padding: 18px 20px;
  transition: all 0.2s ease;
}

.kick-widget-card:hover {
  border-color: #fecdd3;
  transform: translateY(-1px);
}

.kick-widget-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.kick-widget-left {
  flex: 1;
}

.kick-widget-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #e11d48;
  margin-bottom: 4px;
}

.kick-widget-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: #0f172a;
  margin: 2px 0 4px;
  line-height: 1.25;
}

.kick-widget-desc {
  font-size: 0.78rem;
  color: #64748b;
  line-height: 1.4;
  margin: 0;
}

.btn-kick-action {
  background: #e11d48;
  color: #ffffff;
  border: none;
  font-weight: 700;
  font-size: 0.82rem;
  border-radius: 999px;
  padding: 8px 16px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  box-shadow: 0 3px 10px rgba(225, 29, 72, 0.25);
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-kick-action:active {
  transform: scale(0.95);
}

.kick-counter-display-card {
  background: linear-gradient(135deg, #fff1f2 0%, #ffe4e6 100%);
  border: 1px solid #fecdd3;
  border-radius: 24px;
  padding: 24px 16px;
  margin-bottom: 20px;
  box-shadow: 0 4px 18px rgba(225, 29, 72, 0.06);
}

.kick-count-number {
  font-size: 4rem;
  font-weight: 800;
  color: #e11d48;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.kick-count-target {
  font-size: 0.88rem;
  font-weight: 700;
  color: #475569;
  margin-top: 4px;
}

.kick-timer-badge {
  font-size: 0.78rem;
  font-weight: 600;
  color: #64748b;
  margin-top: 8px;
  display: inline-block;
  background: rgba(255, 255, 255, 0.8);
  padding: 4px 12px;
  border-radius: 999px;
  border: 1px solid #fecdd3;
}

/* ==========================================================================
   FETAL & MATERNAL WEEKLY DEVELOPMENT HUB (HOME TAB - TIDY & REFINED)
   ========================================================================== */
.fetal-weekly-section {
  position: relative;
  overflow: hidden;
}

.weekly-mini-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: linear-gradient(135deg, #fff1f2 0%, #ffe4e6 100%);
  border: 1px solid #fecdd3;
  border-radius: 14px;
  padding: 9px 12px;
  margin-bottom: 12px;
}

.weekly-mini-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.weekly-mini-fruit-icon {
  font-size: 1.5rem;
  line-height: 1;
}

.weekly-mini-text h5 {
  font-size: 0.84rem;
  font-weight: 850;
  color: #9f1239;
  margin: 0 0 2px 0;
}

.weekly-mini-text p {
  font-size: 0.7rem;
  color: #64748b;
  margin: 0;
  font-weight: 600;
}

.weekly-trimester-tag {
  font-size: 0.68rem;
  font-weight: 800;
  color: #be185d;
  background: rgba(255, 255, 255, 0.9);
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid #fbcfe8;
  white-space: nowrap;
}

/* Category Segmented Tabs */
.weekly-category-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 12px;
  background: #f1f5f9;
  padding: 4px;
  border-radius: 14px;
}

.weekly-tab-btn {
  flex: 1;
  padding: 7px 8px;
  border-radius: 10px;
  background: transparent;
  border: none;
  color: #64748b;
  font-size: 0.74rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
}

.weekly-tab-btn.active {
  background: #ffffff;
  color: #be123c;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

/* Card Content Body */
.fetal-weekly-card {
  background: #ffffff;
  border: 1px solid #fce7f3;
  border-radius: 16px;
  padding: 16px;
  box-shadow: 0 4px 16px -2px rgba(225, 29, 72, 0.04);
  position: relative;
}

.weekly-tab-panel {
  display: none;
  animation: fadeIn 0.25s ease;
}

.weekly-tab-panel.active {
  display: block;
}

.weekly-subhead {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  font-weight: 800;
  color: #be185d;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  margin-bottom: 8px;
}

.weekly-body-text {
  font-size: 0.86rem;
  color: #334155;
  line-height: 1.6;
  margin: 0 0 12px 0;
}

/* Clean Callout Boxes */
.weekly-callout {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 0.78rem;
  line-height: 1.45;
}

.callout-baby {
  background: #fff7ed;
  border: 1px solid #ffedd5;
  color: #9a3412;
}

.callout-mom {
  background: #fdf2f8;
  border: 1px solid #fce7f3;
  color: #9d174d;
}

.callout-nutri {
  background: #f0fdf4;
  border: 1px solid #dcfce7;
  color: #166534;
}

.callout-icon {
  font-size: 1rem;
  flex-shrink: 0;
  margin-top: 1px;
}

.weekly-nutrient-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.nutrient-tag {
  font-size: 0.7rem;
  font-weight: 700;
  color: #15803d;
  background: #dcfce7;
  border: 1px solid #bbf7d0;
  padding: 3px 8px;
  border-radius: 8px;
}

/* Stepper Footer - Modern, No-Wrap & Touch Friendly */
.weekly-stepper-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #f1f5f9;
  width: 100%;
  box-sizing: border-box;
}

.btn-stepper {
  background: #ffffff;
  border: 1.5px solid #e2e8f0;
  color: #334155;
  font-size: 0.74rem;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  white-space: nowrap !important;
  word-break: keep-all !important;
  user-select: none;
  -webkit-tap-highlight-color: transparent !important;
  outline: none !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  flex-shrink: 0;
}

.btn-stepper:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
  color: #0f172a;
}

.btn-stepper:active {
  transform: scale(0.95);
  background: #f1f5f9;
}

.btn-stepper:focus {
  outline: none !important;
}

.btn-stepper:focus-visible {
  outline: 2px solid #f43f5e !important;
  outline-offset: 1px;
}

.stepper-week-indicator {
  font-size: 0.78rem;
  font-weight: 800;
  color: #be185d;
  background: #fff1f2;
  border: 1.5px solid #fecdd3;
  padding: 7px 14px;
  border-radius: 999px;
  cursor: pointer;
  white-space: nowrap !important;
  word-break: keep-all !important;
  text-align: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  user-select: none;
  -webkit-tap-highlight-color: transparent !important;
  outline: none !important;
  transition: all 0.2s ease;
  box-shadow: 0 1px 3px rgba(225, 29, 72, 0.08);
  flex-shrink: 0;
}

.stepper-week-indicator:hover {
  background: #ffe4e6;
  border-color: #fda4af;
}

.stepper-week-indicator:active {
  transform: scale(0.95);
  background: #fecdd3;
}

.stepper-label-short {
  display: none;
}
.stepper-label-full {
  display: inline;
}

@media (max-width: 410px) {
  .weekly-stepper-footer {
    gap: 6px;
  }
  .btn-stepper {
    padding: 7px 9px;
    font-size: 0.72rem;
    gap: 4px;
  }
  .stepper-label-full {
    display: none;
  }
  .stepper-label-short {
    display: inline;
  }
  .stepper-week-indicator {
    padding: 6px 10px;
    font-size: 0.74rem;
  }
}

@media (max-width: 340px) {
  .btn-stepper {
    padding: 6px 7px;
    font-size: 0.68rem;
    gap: 2px;
  }
  .stepper-week-indicator {
    padding: 5px 8px;
    font-size: 0.7rem;
  }
}

/* ==========================================================================
   CONTRACTION TIMER & LABOR TAB (MEDICAL STANDARD)
   ========================================================================== */
.contraction-timer-card {
  background: #ffffff;
  border: 1px solid #fecdd3;
  border-radius: 24px;
  padding: 24px 20px;
  box-shadow: 0 8px 30px rgba(225, 29, 72, 0.05);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-top: 8px;
  position: relative;
  overflow: hidden;
}

.contraction-timer-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #fb7185, #e11d48, #be123c);
}

.contraction-timer-display {
  font-size: 3.5rem;
  font-weight: 800;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Plus Jakarta Sans", sans-serif;
  font-variant-numeric: tabular-nums;
  letter-spacing: 2px;
  color: #0f172a;
  line-height: 1;
  margin: 12px 0 8px;
}

.contraction-state-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #64748b;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  padding: 6px 16px;
  border-radius: 999px;
  margin-bottom: 20px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.btn-contraction-action {
  width: 100%;
  max-width: 320px;
  height: 56px;
  border-radius: 999px;
  border: none;
  font-size: 1.05rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  -webkit-tap-highlight-color: transparent;
  box-sizing: border-box;
}

.btn-contraction-start {
  background: linear-gradient(135deg, #f43f5e 0%, #e11d48 100%);
  color: #ffffff;
  box-shadow: 0 6px 20px rgba(225, 29, 72, 0.35);
}

.btn-contraction-start:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 25px rgba(225, 29, 72, 0.45);
}

.btn-contraction-start:active {
  transform: scale(0.98);
}

.btn-contraction-stop {
  background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
  color: #ffffff;
  box-shadow: 0 6px 20px rgba(15, 23, 42, 0.3);
  animation: pulse-ring 2s infinite cubic-bezier(0.45, 0, 0.55, 1);
}

@keyframes pulse-ring {
  0% {
    box-shadow: 0 0 0 0 rgba(225, 29, 72, 0.6);
  }
  70% {
    box-shadow: 0 0 0 14px rgba(225, 29, 72, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(225, 29, 72, 0);
  }
}

.contraction-metrics-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  width: 100%;
  margin-top: 24px;
}

.c-metric-item {
  background: #f8fafc;
  border: 1px solid #f1f5f9;
  border-radius: 14px;
  padding: 12px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.c-metric-item .c-lbl {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: #64748b;
}

.c-metric-item .c-val {
  font-size: 1.15rem;
  font-weight: 800;
  color: #0f172a;
}

.contraction-alert-box {
  width: 100%;
  border-radius: 16px;
  padding: 14px 16px;
  font-size: 0.8rem;
  line-height: 1.5;
  margin-top: 18px;
  text-align: left;
  box-sizing: border-box;
}

.contraction-alert-box.alert-normal {
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-left: 4px solid #f59e0b;
  color: #92400e;
}

.contraction-alert-box.alert-warning {
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-left: 4px solid #ef4444;
  color: #991b1b;
  animation: pulse-subtle 2s infinite ease-in-out;
}

.contraction-history-item {
  background: #ffffff;
  border: 1px solid #f1f5f9;
  border-radius: 14px;
  padding: 12px 16px;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.82rem;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.02);
}


/* ==========================================================================
   ADVANCED MOTION & DELIGHT SYSTEM (ANIMATIONS & MICRO-INTERACTIONS)
   ========================================================================== */

/* 1. Audio Equalizer Soundwave Animation */
.sound-equalizer-bars {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  width: 22px;
  height: 20px;
  padding: 1px;
}

.eq-bar {
  width: 3.5px;
  background: linear-gradient(180deg, #a855f7 0%, #7e22ce 100%);
  border-radius: 999px;
  height: 4px;
  transition: height 0.25s ease;
}

.sound-equalizer-bars.active .bar-1 {
  animation: eq-bounce 0.8s infinite ease-in-out alternate;
}
.sound-equalizer-bars.active .bar-2 {
  animation: eq-bounce 1.1s infinite ease-in-out alternate 0.2s;
}
.sound-equalizer-bars.active .bar-3 {
  animation: eq-bounce 0.9s infinite ease-in-out alternate 0.4s;
}
.sound-equalizer-bars.active .bar-4 {
  animation: eq-bounce 1.2s infinite ease-in-out alternate 0.1s;
}

@keyframes eq-bounce {
  0% { height: 4px; }
  100% { height: 18px; }
}

/* 2. Kick Dots Track on Home Widget */
.kick-dots-track {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 10px;
}

.kick-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #f1f5f9;
  border: 1px solid #fecdd3;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.kick-dot.done {
  background: linear-gradient(135deg, #fb7185, #e11d48);
  border-color: #e11d48;
  transform: scale(1.18);
  box-shadow: 0 0 8px rgba(225, 29, 72, 0.4);
}

/* 3. Floating Particles & Confetti */
.floating-kick-particle {
  position: fixed;
  font-size: 1.25rem;
  font-weight: 800;
  color: #e11d48;
  pointer-events: none;
  z-index: 9999;
  text-shadow: 0 2px 10px rgba(225, 29, 72, 0.35);
  animation: floatUpAndFade 0.85s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes floatUpAndFade {
  0% {
    opacity: 1;
    transform: translateY(0) scale(0.8) rotate(0deg);
  }
  50% {
    opacity: 0.95;
    transform: translateY(-45px) scale(1.25) rotate(-6deg);
  }
  100% {
    opacity: 0;
    transform: translateY(-90px) scale(1) rotate(6deg);
  }
}

.celebration-confetti-particle {
  position: fixed;
  font-size: 1.8rem;
  pointer-events: none;
  z-index: 10000;
  animation: confettiExplode 1.4s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

@keyframes confettiExplode {
  0% {
    opacity: 0;
    transform: scale(0.3) translateY(20px);
  }
  20% {
    opacity: 1;
    transform: scale(1.35) translateY(-25px);
  }
  100% {
    opacity: 0;
    transform: scale(0.9) translateY(65px);
  }
}

/* 4. Contraction Live Recording & Radar Waves */
.contraction-timer-card.is-counting {
  border-color: #f43f5e;
  box-shadow: 0 12px 36px rgba(225, 29, 72, 0.12);
}

.contraction-timer-card.is-counting .contraction-timer-display {
  color: #e11d48;
  animation: clock-glow 2s infinite ease-in-out;
}

@keyframes clock-glow {
  0% {
    text-shadow: 0 0 10px rgba(225, 29, 72, 0.15);
    transform: scale(1);
  }
  50% {
    text-shadow: 0 0 24px rgba(225, 29, 72, 0.4);
    transform: scale(1.02);
  }
  100% {
    text-shadow: 0 0 10px rgba(225, 29, 72, 0.15);
    transform: scale(1);
  }
}

.live-rec-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ef4444;
  display: inline-block;
  margin-right: 6px;
  animation: rec-blink 1s infinite alternate;
}

@keyframes rec-blink {
  0% { opacity: 1; transform: scale(1); }
  100% { opacity: 0.2; transform: scale(0.7); }
}

.btn-contraction-stop {
  position: relative;
  background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
  color: #ffffff;
  box-shadow: 0 6px 20px rgba(15, 23, 42, 0.3);
}

.btn-contraction-stop::before {
  content: '';
  position: absolute;
  top: -4px;
  left: -4px;
  right: -4px;
  bottom: -4px;
  border-radius: 999px;
  border: 2px solid #e11d48;
  animation: radar-wave 1.8s infinite cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}

@keyframes radar-wave {
  0% { transform: scale(0.98); opacity: 0.9; }
  100% { transform: scale(1.18); opacity: 0; }
}

.count-pop-anim {
  animation: count-spring 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes count-spring {
  0% { transform: scale(1); }
  45% { transform: scale(1.3) rotate(-3deg); color: #be123c; }
  80% { transform: scale(0.95); }
  100% { transform: scale(1); }
}

.heartbeat-active-pulse {
  animation: heartbeat-pop 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes heartbeat-pop {
  0% { transform: scale(1); }
  40% { transform: scale(1.3) rotate(6deg); }
  75% { transform: scale(0.92); }
  100% { transform: scale(1); }
}

/* 5. Tactile Springs for Interactive Cards */
.btn-action-card {
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn-action-card:active {
  transform: scale(0.93);
}

.btn-action-card:hover {
  transform: translateY(-2px);
  border-color: #fecdd3;
  box-shadow: 0 6px 18px rgba(225, 29, 72, 0.08);
}

.btn-nudge {
  transition: all 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn-nudge:active {
  transform: scale(0.92);
}

.btn-nudge:hover {
  transform: translateY(-2px);
  border-color: #f43f5e;
  box-shadow: 0 4px 14px rgba(244, 63, 94, 0.12);
}

.nudge-icon {
  font-size: 1.5rem;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn-nudge:hover .nudge-icon {
  transform: scale(1.18) rotate(6deg);
}

/* 6. Accessibility Reduce Motion Safeguard */
@media (prefers-reduced-motion: reduce) {
  *, ::before, ::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}


/* ==========================================================================
   SMART NUTRITION & FOOD SAFETY REDESIGN (MEDICAL GRADE)
   ========================================================================== */

/* Sub-tab segmented bar */
.nutrition-segmented-bar {
  display: flex;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 4px;
  margin-bottom: 16px;
  gap: 4px;
}

.seg-btn {
  flex: 1;
  border: none;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  background: transparent;
  color: #64748b;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  -webkit-tap-highlight-color: transparent;
}

.seg-btn.active {
  background: #ffffff;
  color: #e11d48;
  font-weight: 800;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.06);
}

/* Scanner Card */
.smart-food-scanner-card {
  background: linear-gradient(135deg, #fff1f2 0%, #ffe4e6 50%, #fef2f2 100%);
  border: 1.5px solid #fecdd3;
  border-radius: 22px;
  padding: 16px 18px;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(225, 29, 72, 0.05);
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.smart-food-scanner-card:active {
  transform: scale(0.97);
}

.smart-food-scanner-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(225, 29, 72, 0.12);
  border-color: #f43f5e;
}

.scanner-icon-bubble {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: #ffffff;
  color: #e11d48;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(225, 29, 72, 0.12);
  position: relative;
  flex-shrink: 0;
}

.scan-sparkle {
  position: absolute;
  top: -4px;
  right: -4px;
  font-size: 0.9rem;
  animation: sparkle-float 1.8s infinite ease-in-out;
}

.scanner-text-content {
  flex: 1;
}

.scanner-badge-pill {
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.6px;
  color: #be123c;
  background: rgba(225, 29, 72, 0.1);
  padding: 2px 8px;
  border-radius: 999px;
  display: inline-block;
  margin-bottom: 4px;
}

.scanner-text-content h4 {
  font-size: 0.94rem;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 2px 0;
  line-height: 1.25;
}

.scanner-text-content p {
  font-size: 0.74rem;
  color: #64748b;
  margin: 0;
  line-height: 1.35;
}

.btn-scan-action {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #ffffff;
  color: #e11d48;
  border: 1px solid #fecdd3;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0,0,0,0.04);
}

/* Search bar */
.smart-search-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #ffffff;
  border: 1.5px solid #e2e8f0;
  border-radius: 18px;
  padding: 8px 14px;
  margin-bottom: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
  transition: all 0.2s ease;
}

.smart-search-wrap:focus-within {
  border-color: #f43f5e;
  box-shadow: 0 0 0 3px rgba(244, 63, 94, 0.12);
}

.search-icon-left {
  color: #94a3b8;
  display: flex;
  align-items: center;
}

.smart-search-input {
  border: none;
  background: transparent;
  outline: none;
  font-size: 0.9rem;
  font-weight: 500;
  width: 100%;
  color: #0f172a;
  font-family: inherit;
}

.smart-search-input::placeholder {
  color: #94a3b8;
  font-weight: 400;
}

.btn-clear-search {
  border: none;
  background: #f1f5f9;
  color: #64748b;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  font-size: 0.75rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-search-camera-shortcut {
  border: none;
  background: #fff1f2;
  color: #e11d48;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.15s;
}

.btn-search-camera-shortcut:active {
  transform: scale(0.9);
  background: #e11d48;
  color: #ffffff;
}

/* Quick search tags */
.quick-food-tags-row {
  display: flex;
  align-items: center;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  margin-bottom: 14px;
  padding: 2px 0;
}
.quick-food-tags-row::-webkit-scrollbar { display: none; }

.quick-tag-label {
  font-size: 0.7rem;
  font-weight: 700;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  white-space: nowrap;
}

.quick-tag-btn {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 0.72rem;
  font-weight: 600;
  color: #475569;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s;
}

.quick-tag-btn:hover {
  background: #fff1f2;
  border-color: #fecdd3;
  color: #e11d48;
}

/* Filter Section Labels */
.filter-header-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #64748b;
  margin: 10px 0 6px;
}

.chip-status-btn {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  color: #475569;
  font-size: 0.74rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 999px;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 1px 3px rgba(0,0,0,0.02);
}

.chip-status-btn.active {
  background: #1e293b;
  color: #ffffff;
  border-color: #1e293b;
  font-weight: 700;
}

.chip-status-btn.chip-safe.active {
  background: #059669;
  border-color: #059669;
}

.chip-status-btn.chip-caution.active {
  background: #d97706;
  border-color: #d97706;
}

.chip-status-btn.chip-danger.active {
  background: #dc2626;
  border-color: #dc2626;
}

.chip-status-btn.chip-trimester.active {
  background: linear-gradient(135deg, #e11d48, #be123c);
  border-color: #e11d48;
}

/* Meta row count */
.food-results-meta-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.74rem;
  font-weight: 600;
  color: #64748b;
  margin: 12px 0 10px;
}

.offline-ready-badge {
  font-size: 0.68rem;
  font-weight: 700;
  background: #f1f5f9;
  color: #475569;
  padding: 3px 8px;
  border-radius: 8px;
}

/* Smart Food Cards */
.food-results-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.smart-food-card {
  background: #ffffff;
  border: 1px solid #f1f5f9;
  border-radius: 18px;
  padding: 16px;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.03);
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  overflow: hidden;
}

.smart-food-card.status-safe {
  border-left: 5px solid #10b981;
}

.smart-food-card.status-caution {
  border-left: 5px solid #f59e0b;
}

.smart-food-card.status-danger {
  border-left: 5px solid #ef4444;
}

.smart-food-header {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 10px;
}

.food-avatar-wrap {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.03);
}

.food-avatar-wrap.cat-buah { background: #fdf2f8; }
.food-avatar-wrap.cat-lauk { background: #fff7ed; }
.food-avatar-wrap.cat-sayur { background: #f0fdf4; }
.food-avatar-wrap.cat-minuman { background: #f0fdfa; }
.food-avatar-wrap.cat-obat { background: #ede9fe; }

.food-main-meta {
  flex: 1;
}

.food-title-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 4px;
}

.food-name {
  font-size: 0.98rem;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.3px;
  margin: 0;
  line-height: 1.25;
}

.food-status-pill {
  font-size: 0.68rem;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 999px;
  white-space: nowrap;
  letter-spacing: -0.1px;
}

.food-status-pill.status-safe {
  background: #ecfdf5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}

.food-status-pill.status-caution {
  background: #fffbeb;
  color: #92400e;
  border: 1px solid #fde68a;
}

.food-status-pill.status-danger {
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.food-tags-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px;
}

.food-cat-chip {
  font-size: 0.65rem;
  font-weight: 700;
  background: #f8fafc;
  color: #64748b;
  padding: 2px 7px;
  border-radius: 6px;
  text-transform: uppercase;
}

.food-trim-chip {
  font-size: 0.65rem;
  font-weight: 600;
  background: #f1f5f9;
  color: #475569;
  padding: 2px 7px;
  border-radius: 6px;
}

.tag-trim-danger {
  font-size: 0.65rem;
  font-weight: 700;
  background: #fee2e2;
  color: #b91c1c;
  padding: 2px 8px;
  border-radius: 6px;
  animation: pulse-subtle 1.5s infinite;
}

.tag-trim-safe {
  font-size: 0.65rem;
  font-weight: 700;
  background: #dcfce7;
  color: #15803d;
  padding: 2px 8px;
  border-radius: 6px;
}

.food-desc-text {
  font-size: 0.8rem;
  color: #334155;
  line-height: 1.5;
  margin: 0 0 10px 0;
}

/* Accordion Drawer */
.food-card-footer {
  border-top: 1px solid #f1f5f9;
  padding-top: 10px;
  margin-top: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  user-select: none;
}

.footer-expand-lbl {
  font-size: 0.75rem;
  font-weight: 700;
  color: #e11d48;
  transition: color 0.15s;
}

.clinical-details-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 12px 14px;
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  animation: slide-in-top 0.25s ease-out;
}

.clinical-point {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.point-lbl {
  font-size: 0.7rem;
  font-weight: 700;
  color: #475569;
}

.point-val {
  font-size: 0.78rem;
  color: #1e293b;
  line-height: 1.45;
}

.clinical-ai-action-row {
  margin-top: 6px;
  padding-top: 8px;
  border-top: 1px dashed #cbd5e1;
}

.btn-ask-ai-food {
  background: linear-gradient(135deg, #fff1f2, #ffe4e6);
  border: 1px solid #fecdd3;
  color: #be123c;
  font-size: 0.74rem;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
}

.btn-ask-ai-food:hover {
  background: #e11d48;
  color: #ffffff;
  border-color: #e11d48;
}

/* Smart Custom AI Food Card */
.smart-ai-custom-food-card {
  background: linear-gradient(135deg, #fff7ed 0%, #fff1f2 100%);
  border: 1.5px solid #fed7aa;
  border-radius: 18px;
  padding: 16px;
  margin-bottom: 14px;
  box-shadow: 0 4px 16px rgba(234, 88, 12, 0.08);
}

.ai-custom-food-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.ai-sparkle-avatar {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: linear-gradient(135deg, #f97316, #e11d48);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  box-shadow: 0 3px 8px rgba(249, 115, 22, 0.3);
}

.btn-ai-analyze-custom {
  width: 100%;
  background: linear-gradient(135deg, #ea580c 0%, #e11d48 100%);
  color: white;
  border: none;
  font-size: 0.84rem;
  font-weight: 700;
  padding: 10px 14px;
  border-radius: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 14px rgba(225, 29, 72, 0.25);
  transition: all 0.2s;
}

.btn-ai-analyze-custom:active {
  transform: scale(0.98);
}

.ai-custom-food-result {
  margin-top: 12px;
  animation: slide-in-top 0.3s ease-out;
}

.ai-custom-analysis-card {
  background: #ffffff;
  border-radius: 14px;
  padding: 14px;
  border: 1.5px solid #fed7aa;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}


/* ==========================================================================
   SMART PREGNANCY VITAMIN CHECKLIST & TRACKER (V13)
   ========================================================================== */

/* Home Screen Quick Vitamin Widget */
.home-vitamin-widget-card {
  background: linear-gradient(135deg, #ffffff 0%, #fff5f7 60%, #ffe4e6 100%);
  border: 1.5px solid #fecdd3;
  border-radius: 20px;
  padding: 16px;
  box-shadow: 0 4px 18px rgba(225, 29, 72, 0.07);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.home-vitamin-widget-card::before {
  content: "";
  position: absolute;
  top: -40px;
  right: -40px;
  width: 100px;
  height: 100px;
  background: radial-gradient(circle, rgba(251, 113, 133, 0.15) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.home-vitamin-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
}

.home-vitamin-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #fff;
  border: 1px solid #fbcfe8;
  color: #be185d;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  margin-bottom: 6px;
  box-shadow: 0 2px 6px rgba(225, 29, 72, 0.05);
}

.home-vitamin-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: #1e293b;
  margin: 0 0 2px 0;
}

.home-vitamin-sub {
  font-size: 0.75rem;
  color: #64748b;
  margin: 0;
  line-height: 1.35;
}

.btn-vitamin-goto {
  display: flex;
  align-items: center;
  gap: 4px;
  background: #ffffff;
  color: #e11d48;
  border: 1.5px solid #fecdd3;
  padding: 6px 12px;
  border-radius: 12px;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(225, 29, 72, 0.06);
  transition: all 0.2s;
}

.btn-vitamin-goto:active {
  transform: scale(0.96);
  background: #fff1f2;
}

.home-vitamin-progress-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.home-vitamin-progress-bar {
  flex: 1;
  height: 8px;
  background: #f1f5f9;
  border-radius: 999px;
  overflow: hidden;
  position: relative;
}

.home-vitamin-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #fb7185, #e11d48);
  border-radius: 999px;
  transition: width 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
}

.home-vitamin-progress-fill::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  animation: shimmer-sweep 2s infinite;
}

.home-vitamin-progress-text {
  font-size: 0.74rem;
  font-weight: 800;
  color: #be185d;
  white-space: nowrap;
}

/* Home mini list */
.home-vitamin-checklist {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.home-vit-mini-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #ffffff;
  border: 1px solid #fed7aa;
  border-left: 4px solid #f97316;
  border-radius: 12px;
  padding: 8px 12px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02);
  transition: all 0.2s ease;
  cursor: pointer;
}

.home-vit-mini-item.checked {
  background: #f0fdf4;
  border-color: #bbf7d0;
  border-left-color: #10b981;
}

.home-vit-mini-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.home-vit-mini-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: #1e293b;
}

.home-vit-mini-item.checked .home-vit-mini-name {
  color: #15803d;
  text-decoration: line-through;
}

.home-vit-mini-badge {
  font-size: 0.68rem;
  padding: 2px 6px;
  border-radius: 6px;
  font-weight: 600;
  display: inline-block;
}

/* Check bubble button */
.vitamin-check-bubble {
  width: 32px;
  height: 32px;
  min-width: 32px;
  border-radius: 50%;
  border: 2px solid #cbd5e1;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  -webkit-tap-highlight-color: transparent;
  color: transparent;
}

.vitamin-check-bubble.checked {
  border-color: #10b981;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #ffffff;
  box-shadow: 0 3px 10px rgba(16, 185, 129, 0.35);
  animation: check-bounce 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes check-bounce {
  0% { transform: scale(0.7); }
  50% { transform: scale(1.18); }
  100% { transform: scale(1); }
}

/* ==========================================================================
   Full Vitamin Tracker Subpage Styles
   ========================================================================== */

/* Daily Tracker Hero Card */
.vitamin-hero-card {
  background: linear-gradient(135deg, #fff1f2 0%, #fef2f2 50%, #ffffff 100%);
  border: 1.5px solid #fecdd3;
  border-radius: 20px;
  padding: 16px;
  margin-bottom: 16px;
  box-shadow: 0 4px 16px rgba(225, 29, 72, 0.05);
}

.vitamin-hero-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.vitamin-date-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.74rem;
  font-weight: 700;
  color: #be185d;
  background: #ffffff;
  border: 1px solid #fbcfe8;
  padding: 4px 10px;
  border-radius: 20px;
}

.vitamin-streak-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.74rem;
  font-weight: 800;
  color: #d97706;
  background: #fef3c7;
  border: 1px solid #fde68a;
  padding: 4px 10px;
  border-radius: 20px;
}

.vitamin-hero-status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.vitamin-hero-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: #1e293b;
  margin: 0;
}

.vitamin-hero-ratio {
  font-size: 1.25rem;
  font-weight: 900;
  color: #e11d48;
}

.vitamin-hero-bar {
  height: 12px;
  background: #e2e8f0;
  border-radius: 999px;
  overflow: hidden;
  position: relative;
  margin-bottom: 10px;
}

.vitamin-hero-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #f43f5e 0%, #be185d 100%);
  border-radius: 999px;
  transition: width 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
}

.vitamin-hero-bar-fill.all-done {
  background: linear-gradient(90deg, #10b981 0%, #059669 100%);
}

.vitamin-hero-bar-fill::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.45), transparent);
  animation: shimmer-sweep 2s infinite;
}

.vitamin-hero-motto {
  font-size: 0.78rem;
  color: #475569;
  line-height: 1.4;
  margin: 0;
}

/* All Done Celebratory Banner */
.vitamin-celebration-banner {
  background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
  border: 1.5px solid #a7f3d0;
  border-radius: 14px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  animation: slide-in-top 0.35s ease-out;
}

.celebration-icon {
  font-size: 1.6rem;
  animation: heart-pulse 1.2s infinite;
}

.celebration-text h5 {
  font-size: 0.86rem;
  font-weight: 800;
  color: #065f46;
  margin: 0 0 2px 0;
}

.celebration-text p {
  font-size: 0.74rem;
  color: #047857;
  margin: 0;
}

/* Action Buttons Bar */
.vitamin-actions-row {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}

.btn-add-vitamin-primary {
  flex: 2;
  background: linear-gradient(135deg, #f43f5e 0%, #e11d48 100%);
  color: #ffffff;
  border: none;
  padding: 12px 16px;
  border-radius: 14px;
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 14px rgba(225, 29, 72, 0.25);
  transition: all 0.2s;
}

.btn-add-vitamin-primary:active {
  transform: scale(0.98);
}

.btn-scan-vitamin-sec {
  flex: 1;
  background: #ffffff;
  color: #be185d;
  border: 1.5px solid #fecdd3;
  padding: 12px;
  border-radius: 14px;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s;
}

.btn-scan-vitamin-sec:active {
  background: #fff1f2;
}

/* Preset Chips Bar */
.preset-vitamin-chips-scroll {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 6px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.preset-vitamin-chips-scroll::-webkit-scrollbar {
  display: none;
}

.preset-vit-chip {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  color: #334155;
  font-size: 0.74rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 20px;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.2s;
}

.preset-vit-chip:hover,
.preset-vit-chip:active {
  background: #fff1f2;
  border-color: #fecdd3;
  color: #e11d48;
}

/* Time Groups (Pagi, Siang, Malam) */
.vitamin-group-section {
  margin-bottom: 18px;
}

.vitamin-group-header {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.84rem;
  font-weight: 800;
  color: #334155;
  margin-bottom: 10px;
  padding-bottom: 4px;
  border-bottom: 1.5px solid #f1f5f9;
}

.vitamin-group-count {
  font-size: 0.7rem;
  color: #94a3b8;
  font-weight: 600;
}

/* Vitamin Item Card */
.vitamin-item-card {
  background: #ffffff;
  border: 1.5px solid #e2e8f0;
  border-radius: 16px;
  padding: 14px;
  margin-bottom: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.vitamin-item-card.checked {
  background: #fbfdfc;
  border-color: #bbf7d0;
  box-shadow: 0 3px 10px rgba(16, 185, 129, 0.06);
}

.vitamin-item-main-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.vitamin-item-info {
  flex: 1;
}

.vitamin-name-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
}

.vitamin-name-text {
  font-size: 0.94rem;
  font-weight: 800;
  color: #0f172a;
  margin: 0;
}

.vitamin-item-card.checked .vitamin-name-text {
  color: #15803d;
}

.vitamin-item-menu-btn {
  background: transparent;
  border: none;
  color: #94a3b8;
  font-size: 1rem;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 6px;
}

.vitamin-item-menu-btn:hover {
  background: #f1f5f9;
  color: #475569;
}

/* Badges Row */
.vitamin-badges-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

.badge-timing-sesudah {
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.badge-timing-sebelum-tidur {
  background: #eef2ff;
  color: #4338ca;
  border: 1px solid #c7d2fe;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.badge-timing-sebelum-makan {
  background: #fffbeb;
  color: #b45309;
  border: 1px solid #fde68a;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.badge-dose-pill {
  background: #f8fafc;
  color: #64748b;
  border: 1px solid #e2e8f0;
  font-size: 0.68rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 8px;
}

/* Auto-Read Details Box */
.vitamin-auto-info-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 10px 12px;
  margin-top: 8px;
  font-size: 0.75rem;
  line-height: 1.45;
}

.auto-info-title {
  font-weight: 700;
  color: #334155;
  margin-bottom: 3px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.auto-purpose-p {
  color: #475569;
  margin: 0 0 6px 0;
}

.auto-rule-alert {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  color: #9a3412;
  padding: 6px 8px;
  border-radius: 8px;
  font-size: 0.72rem;
  margin: 0;
}

/* Checked timestamp */
.vitamin-checked-timestamp {
  font-size: 0.72rem;
  font-weight: 700;
  color: #10b981;
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 6px;
}

/* Golden Rules Education Card */
.vitamin-golden-rules-card {
  background: linear-gradient(135deg, #f0fdfa 0%, #e6fffa 100%);
  border: 1.5px solid #99f6e4;
  border-radius: 18px;
  padding: 16px;
  margin-top: 20px;
}

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

.rules-head h4 {
  font-size: 0.92rem;
  font-weight: 800;
  color: #0f766e;
  margin: 0;
}

.rule-item-row {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
  font-size: 0.76rem;
  line-height: 1.4;
  color: #134e4a;
}

.rule-item-row:last-child {
  margin-bottom: 0;
}

.rule-num {
  width: 22px;
  height: 22px;
  min-width: 22px;
  border-radius: 50%;
  background: #0d9488;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 800;
}

/* Modal Add Vitamin Styles */
.smart-input-btn-group {
  display: flex;
  gap: 6px;
  align-items: stretch;
}

.smart-input-btn-group input {
  flex: 1;
}

.btn-input-scan,
.btn-input-ai {
  border: 1.5px solid #fbcfe8;
  background: #ffffff;
  color: #be185d;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0 12px;
  border-radius: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: all 0.2s;
  white-space: nowrap;
}

.btn-input-ai {
  background: linear-gradient(135deg, #f43f5e, #be185d);
  color: #ffffff;
  border: none;
}

.btn-input-scan:active,
.btn-input-ai:active {
  transform: scale(0.96);
}

.vitamin-auto-detect-box {
  background: linear-gradient(135deg, #fff8fa 0%, #fff1f2 100%);
  border: 1.5px solid #fecdd3;
  border-radius: 14px;
  padding: 12px;
  margin-bottom: 14px;
  animation: slide-in-top 0.3s ease-out;
}

.auto-detect-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.auto-detect-badge {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.72rem;
  font-weight: 800;
  color: #be185d;
}

.auto-detect-cat-label {
  font-size: 0.68rem;
  background: #ffffff;
  border: 1px solid #fbcfe8;
  color: #e11d48;
  padding: 2px 8px;
  border-radius: 10px;
  font-weight: 700;
}

.auto-purpose-text {
  font-size: 0.75rem;
  color: #334155;
  margin: 2px 0 0 0;
  line-height: 1.4;
}

.auto-rule-text {
  font-size: 0.72rem;
  color: #991b1b;
  background: #fef2f2;
  border-left: 3px solid #ef4444;
  padding: 4px 8px;
  border-radius: 6px;
  margin: 2px 0 0 0;
  line-height: 1.35;
}

.auto-label {
  font-size: 0.7rem;
  font-weight: 800;
  color: #64748b;
  display: inline-block;
  min-width: 90px;
}


/* ==========================================================================
   KAMUS SINGKATAN MEDIS USG (Pintar, Rapi, & Estetik)
   ========================================================================== */
.usg-dict-card-section {
  background: #ffffff;
  border-radius: 20px;
  border: 1px solid #f1f5f9;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.03);
}

.usg-dict-search-wrap {
  position: relative;
  margin-bottom: 10px;
}

.usg-dict-search-input {
  width: 100%;
  padding: 10px 14px 10px 38px;
  background: #f8fafc;
  border: 1.5px solid #e2e8f0;
  border-radius: 14px;
  font-size: 0.8rem;
  color: #1e293b;
  outline: none;
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.usg-dict-search-input:focus {
  background: #ffffff;
  border-color: #fb7185;
  box-shadow: 0 0 0 3px rgba(251, 113, 133, 0.15);
}

.usg-dict-search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  display: flex;
  align-items: center;
  pointer-events: none;
}

.usg-dict-chips-row {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 6px;
  margin-bottom: 12px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.usg-dict-chips-row::-webkit-scrollbar {
  display: none;
}

.usg-dict-chip {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  color: #64748b;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 20px;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.usg-dict-chip:hover {
  background: #f1f5f9;
  color: #334155;
}

.usg-dict-chip.active {
  background: #fff1f2;
  border-color: #fecdd3;
  color: #e11d48;
  font-weight: 800;
  box-shadow: 0 2px 6px rgba(225, 29, 72, 0.08);
}

.usg-dict-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.usg-dict-card {
  background: #ffffff;
  border: 1.5px solid #f1f5f9;
  border-radius: 14px;
  padding: 12px 14px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.02);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.usg-dict-card:hover {
  border-color: #fecdd3;
  box-shadow: 0 4px 12px rgba(225, 29, 72, 0.05);
  transform: translateY(-1px);
}

.usg-dict-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.usg-dict-badge-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.usg-acronym-badge {
  min-width: 48px;
  height: 26px;
  padding: 0 8px;
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.badge-cat-head {
  background: #ffe4e6;
  color: #be185d;
  border: 1px solid #fbcfe8;
}

.badge-cat-body {
  background: #e0f2fe;
  color: #0369a1;
  border: 1px solid #bae6fd;
}

.badge-cat-heart {
  background: #fce7f3;
  color: #db2777;
  border: 1px solid #fbcfe8;
}

.badge-cat-fluid {
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
}

.badge-cat-early {
  background: #fef3c7;
  color: #b45309;
  border: 1px solid #fde68a;
}

.usg-dict-fullname {
  font-size: 0.84rem;
  font-weight: 800;
  color: #1e293b;
  margin: 0;
}

.usg-normal-range-pill {
  font-size: 0.68rem;
  font-weight: 800;
  color: #059669;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  padding: 3px 8px;
  border-radius: 12px;
  white-space: nowrap;
}

.usg-dict-desc-text {
  font-size: 0.76rem;
  color: #475569;
  line-height: 1.45;
  margin: 0;
  padding-left: 2px;
}


/* ==========================================================================
   OFFICIAL KIA PRINT MEDICAL BANNER
   ========================================================================== */
.kia-print-card {
  margin-top: 16px;
  background: linear-gradient(135deg, #ffffff 0%, #fff7ed 60%, #ffedd5 100%);
  border: 1.5px solid #fed7aa;
  border-radius: 18px;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: 0 8px 24px -4px rgba(234, 88, 12, 0.12);
  cursor: pointer;
  transition: all 0.25s ease;
  -webkit-tap-highlight-color: transparent;
}

.kia-print-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px -4px rgba(234, 88, 12, 0.18);
  border-color: #fb923c;
}

.kia-print-card:active {
  transform: scale(0.98);
}

.kia-print-icon {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: linear-gradient(135deg, #f97316 0%, #ea580c 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  box-shadow: 0 4px 12px rgba(234, 88, 12, 0.25);
  flex-shrink: 0;
}

.kia-print-body {
  flex: 1;
  min-width: 0;
}

.kia-print-tag {
  font-size: 0.65rem;
  font-weight: 800;
  text-transform: uppercase;
  color: #c2410c;
  letter-spacing: 0.4px;
  margin-bottom: 2px;
}

.kia-print-title {
  font-size: 0.92rem;
  font-weight: 800;
  color: #7c2d12;
  margin: 0 0 3px 0;
  line-height: 1.3;
}

.kia-print-sub {
  font-size: 0.72rem;
  color: #9a3412;
  margin: 0;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.btn-kia-action {
  background: linear-gradient(135deg, #ea580c, #c2410c);
  color: white;
  border: none;
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 0.75rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 4px 12px rgba(194, 65, 12, 0.25);
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
}

/* ==========================================================================
   WEEKLY MILESTONE EXPLORER MODAL (1-42 WEEKS - TIDY & OPAQUE)
   ========================================================================== */
.milestone-modal-sheet {
  background: #ffffff !important;
  width: 100% !important;
  max-width: 520px !important;
  max-height: 90vh !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  border-top-left-radius: 24px;
  border-top-right-radius: 24px;
  padding: 20px 16px calc(24px + env(safe-area-inset-bottom, 20px)) !important;
  box-sizing: border-box !important;
  animation: slideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.15);
}

.milestone-scroller-wrap {
  overflow-x: auto;
  white-space: nowrap;
  padding: 4px 2px 14px;
  display: flex;
  gap: 8px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
  -webkit-overflow-scrolling: touch;
}

.week-chip-btn {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 56px;
  padding: 8px 6px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  outline: none;
}

.week-chip-btn .chip-wk {
  font-size: 0.64rem;
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
}

.week-chip-btn .chip-num {
  font-size: 1.15rem;
  font-weight: 850;
  color: #1e293b;
  line-height: 1.1;
}

.week-chip-btn .chip-icon {
  font-size: 0.95rem;
  margin-top: 2px;
}

.week-chip-btn.active {
  background: linear-gradient(135deg, #f43f5e, #be123c);
  border-color: #be123c;
  color: white;
  box-shadow: 0 4px 14px rgba(225, 29, 72, 0.3);
  transform: scale(1.05);
}

.week-chip-btn.active .chip-wk,
.week-chip-btn.active .chip-num {
  color: white;
}

.milestone-spotlight-card {
  background: radial-gradient(circle at 50% 0%, #fff1f2 0%, #ffffff 70%);
  border-radius: 20px;
  border: 1.5px solid #fecdd3;
  padding: 18px 14px;
  text-align: center;
  margin-bottom: 14px;
  box-shadow: 0 4px 16px rgba(225, 29, 72, 0.05);
  box-sizing: border-box;
}

.milestone-giant-icon {
  font-size: 3.5rem;
  line-height: 1;
  margin-bottom: 6px;
  display: inline-block;
  animation: floatFruit 3.5s ease-in-out infinite;
}

.milestone-title-text {
  font-size: 1.15rem;
  font-weight: 850;
  color: #9f1239;
  margin: 0 0 6px;
  letter-spacing: -0.2px;
}

.milestone-stats-pills {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.milestone-pill-badge {
  font-size: 0.74rem;
  font-weight: 700;
  color: #881337;
  background: #ffe4e6;
  border: 1px solid #fecdd3;
  padding: 4px 10px;
  border-radius: 999px;
}

.milestone-detail-card {
  background: #ffffff;
  border: 1px solid #fed7aa;
  border-radius: 16px;
  padding: 14px 16px;
  margin-bottom: 10px;
  text-align: left;
  width: 100%;
  box-sizing: border-box;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
}

.milestone-detail-head {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 850;
  color: #1e293b;
  margin-bottom: 6px;
}

.milestone-detail-body {
  font-size: 0.82rem;
  color: #334155;
  line-height: 1.6;
  margin: 0;
  word-break: break-word;
  overflow-wrap: break-word;
}

.milestone-footer-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid #f1f5f9;
  width: 100%;
  box-sizing: border-box;
}

.milestone-footer-actions button {
  font-weight: 700;
  user-select: none;
  -webkit-tap-highlight-color: transparent !important;
  outline: none !important;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.milestone-footer-actions button:active {
  transform: scale(0.97);
}

/* ==========================================================================
   CUSTOM CONFIRMATION DIALOG MODAL (REPLACES BROWSER CONFIRM)
   ========================================================================== */
.confirm-dialog-box {
  max-width: 360px;
  width: 90%;
  border-radius: 24px;
  padding: 24px 20px 20px;
  text-align: center;
  background: #ffffff;
  box-shadow: 0 24px 48px -12px rgba(0, 0, 0, 0.2);
  animation: confirm-pop 0.28s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes confirm-pop {
  0% { transform: scale(0.85); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

.confirm-icon-wrap {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #fee2e2;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  margin: 0 auto 14px;
  box-shadow: 0 6px 16px rgba(239, 68, 68, 0.15);
}

.confirm-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: #1e293b;
  margin: 0 0 8px;
}

.confirm-message {
  font-size: 0.85rem;
  color: #64748b;
  line-height: 1.5;
  margin: 0 0 20px;
}

.confirm-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.confirm-actions .btn-secondary,
.confirm-actions .btn-primary {
  width: 100%;
  padding: 12px;
  font-size: 0.88rem;
  border-radius: 14px;
  font-weight: 700;
}

/* ==========================================================================
   CUSTOM DROPDOWN SELECT PICKER (REFINED, ROUNDED, & TIDY)
   ========================================================================== */
.custom-select-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #ffffff;
  border: 1.5px solid #fed7aa;
  border-radius: 12px;
  padding: 10px 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  min-height: 42px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.custom-select-trigger:hover,
.custom-select-trigger:focus {
  border-color: #fb923c;
  box-shadow: 0 0 0 3px rgba(251, 146, 60, 0.15);
}

.custom-select-trigger.active {
  border-color: #f43f5e;
  box-shadow: 0 0 0 3px rgba(244, 63, 94, 0.15);
}

.trigger-label {
  font-size: 0.8rem;
  font-weight: 700;
  color: #1e293b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  padding-right: 4px;
}

.trigger-arrow {
  font-size: 0.75rem;
  color: #94a3b8;
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.custom-select-trigger.active .trigger-arrow {
  transform: rotate(180deg);
  color: #f43f5e;
}

.custom-select-menu {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  z-index: 10005;
  background: #ffffff;
  border: 1.5px solid #ffe4e6;
  border-radius: 16px;
  padding: 6px;
  box-shadow: 0 14px 36px -4px rgba(225, 29, 72, 0.14), 0 4px 12px rgba(0, 0, 0, 0.04);
  min-width: 200px;
  max-width: 260px;
  animation: dropdown-pop 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.custom-select-menu.active {
  display: block;
}

.menu-align-left {
  left: 0;
  right: auto;
}

.menu-align-right {
  right: 0;
  left: auto;
}

@keyframes dropdown-pop {
  0% { opacity: 0; transform: translateY(-6px) scale(0.97); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

.custom-select-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: 10px;
  font-size: 0.8rem;
  font-weight: 700;
  color: #334155;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
  margin-bottom: 2px;
}

.custom-select-option:last-child {
  margin-bottom: 0;
}

.custom-select-option:hover,
.custom-select-option:active {
  background: #fff1f2;
  color: #be123c;
}

.custom-select-option.selected {
  background: linear-gradient(135deg, #fff1f2 0%, #ffe4e6 100%);
  color: #be123c;
  font-weight: 800;
}

.custom-select-option .option-icon {
  font-size: 1rem;
  flex-shrink: 0;
}

.custom-select-option .option-text {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.custom-select-option .option-check {
  font-size: 0.85rem;
  color: #e11d48;
  font-weight: 800;
  opacity: 0;
  transition: opacity 0.15s ease;
}

.custom-select-option.selected .option-check {
  opacity: 1;
}

/* ==========================================================================
   OFFICIAL KIA MEDICAL DOCUMENT PRINT STYLES (A4 KEMENKES STANDARD)
   ========================================================================== */
#kiaPrintContainer {
  display: none !important;
}

@media print {
  /* 1. Hide all web app UI, modals, overlays, navbars */
  body > *:not(#kiaPrintContainer) {
    display: none !important;
  }

  /* 2. Configure page & body for clean print */
  @page {
    size: A4 portrait;
    margin: 12mm 15mm;
  }

  html, body {
    margin: 0 !important;
    padding: 0 !important;
    background: #ffffff !important;
    color: #1e293b !important;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif !important;
    font-size: 9.5pt !important;
    line-height: 1.45 !important;
    height: auto !important;
    overflow: visible !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  /* 3. Display print container */
  #kiaPrintContainer {
    display: block !important;
    position: static !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    background: #ffffff !important;
    visibility: visible !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  #kiaPrintContainer * {
    visibility: visible !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
    box-sizing: border-box !important;
  }

  #kiaPrintContainer .kop-wrap {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding-bottom: 10px !important;
    border-bottom: 2.5px solid #be185d !important;
    margin-bottom: 12px !important;
    gap: 12px !important;
  }

  #kiaPrintContainer .kop-left {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
  }

  #kiaPrintContainer .kop-emblem {
    width: 40px !important;
    height: 40px !important;
    border-radius: 8px !important;
    background: #be185d !important;
    color: #ffffff !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 1.2rem !important;
  }

  #kiaPrintContainer .kop-text h2 {
    font-size: 7.2pt !important;
    font-weight: 700 !important;
    color: #64748b !important;
    margin: 0 !important;
    text-transform: uppercase !important;
  }

  #kiaPrintContainer .kop-text h1 {
    font-size: 12.5pt !important;
    font-weight: 900 !important;
    color: #880e4f !important;
    margin: 2px 0 0 !important;
  }

  #kiaPrintContainer .kop-text p {
    font-size: 7.6pt !important;
    color: #475569 !important;
    margin: 2px 0 0 !important;
  }

  #kiaPrintContainer .kop-meta {
    text-align: right !important;
    font-size: 7.5pt !important;
    color: #64748b !important;
    white-space: nowrap !important;
  }

  #kiaPrintContainer .patient-card {
    background: #fff8fa !important;
    border: 1px solid #fbcfe8 !important;
    border-radius: 8px !important;
    padding: 10px 12px !important;
    margin-bottom: 12px !important;
  }

  #kiaPrintContainer .patient-card-title {
    font-size: 7.5pt !important;
    font-weight: 800 !important;
    color: #9d174d !important;
    text-transform: uppercase !important;
    margin-bottom: 6px !important;
  }

  #kiaPrintContainer .patient-grid {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 6px 14px !important;
    font-size: 8.5pt !important;
  }

  #kiaPrintContainer .p-label {
    display: block !important;
    font-size: 6.8pt !important;
    font-weight: 700 !important;
    color: #831843 !important;
    text-transform: uppercase !important;
    margin-bottom: 1px !important;
  }

  #kiaPrintContainer .p-val {
    color: #1e293b !important;
    font-weight: 600 !important;
  }

  #kiaPrintContainer .section-header {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    margin: 12px 0 5px !important;
  }

  #kiaPrintContainer .section-title,
  #kiaPrintContainer h3 {
    font-size: 8.8pt !important;
    font-weight: 800 !important;
    color: #880e4f !important;
    margin: 0 !important;
  }

  #kiaPrintContainer .section-badge,
  #kiaPrintContainer .scroll-badge {
    display: none !important;
  }

  #kiaPrintContainer .table-responsive {
    overflow: visible !important;
    border: 1px solid #cbd5e1 !important;
    width: 100% !important;
    margin-bottom: 12px !important;
    border-radius: 6px !important;
  }

  #kiaPrintContainer table,
  #kiaPrintContainer .kia-table {
    width: 100% !important;
    min-width: 100% !important;
    border-collapse: collapse !important;
    margin-bottom: 0 !important;
    font-size: 7.8pt !important;
    page-break-inside: auto !important;
  }

  #kiaPrintContainer tr {
    page-break-inside: avoid !important;
    page-break-after: auto !important;
  }

  #kiaPrintContainer th, #kiaPrintContainer td {
    border: 1px solid #cbd5e1 !important;
    padding: 5px 7px !important;
    text-align: left !important;
  }

  #kiaPrintContainer th {
    background: #f8fafc !important;
    color: #475569 !important;
    font-weight: 700 !important;
    font-size: 7.2pt !important;
  }

  #kiaPrintContainer tr:nth-child(even) td {
    background: #fafafa !important;
  }

  #kiaPrintContainer .badge-complete {
    background: #ecfdf5 !important;
    color: #065f46 !important;
    border: 1px solid #a7f3d0 !important;
    padding: 1px 6px !important;
    border-radius: 9999px !important;
    font-size: 7pt !important;
    font-weight: 700 !important;
  }

  #kiaPrintContainer .doc-footer {
    display: flex !important;
    justify-content: space-between !important;
    align-items: flex-end !important;
    margin-top: 16px !important;
    padding-top: 8px !important;
    border-top: 1px dashed #cbd5e1 !important;
    font-size: 7.2pt !important;
    page-break-inside: avoid !important;
  }

  #kiaPrintContainer .doc-notes {
    flex: 1 !important;
    color: #64748b !important;
  }

  #kiaPrintContainer .doc-sign-box {
    text-align: center !important;
    width: 200px !important;
  }

  .no-print {
    display: none !important;
  }
}

/* ==========================================================================
   UNIFIED SELECT DROPDOWNS (ELEGANT, NO UGLY ARROWS, TOUCH-FRIENDLY)
   ========================================================================== */
select,
select.form-control {
  appearance: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  background-color: #ffffff !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23e11d48' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 14px center !important;
  background-size: 16px 16px !important;
  padding-right: 42px !important;
  padding-left: 14px !important;
  height: 44px !important;
  border-radius: 14px !important;
  border: 1.5px solid #e2e8f0 !important;
  font-size: 0.88rem !important;
  font-weight: 600 !important;
  color: #1e293b !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03) !important;
  cursor: pointer !important;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
  outline: none !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

select:hover,
select.form-control:hover {
  border-color: #cbd5e1 !important;
  background-color: #f8fafc !important;
}

select:focus,
select.form-control:focus {
  border-color: #f43f5e !important;
  box-shadow: 0 0 0 3px rgba(244, 63, 94, 0.15) !important;
  background-color: #ffffff !important;
}

/* Audio Timer Specific Pill Dropdown */
.audio-timer-select {
  appearance: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  background-color: #ffffff !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%237e22ce' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 10px center !important;
  background-size: 12px 12px !important;
  padding: 5px 28px 5px 12px !important;
  border-radius: 999px !important;
  border: 1.5px solid #d8b4fe !important;
  font-size: 0.72rem !important;
  font-weight: 750 !important;
  color: #7e22ce !important;
  cursor: pointer !important;
  height: 32px !important;
  width: auto !important;
  box-shadow: 0 1px 2px rgba(126, 34, 206, 0.08) !important;
  outline: none !important;
}

.audio-timer-select:focus {
  border-color: #9333ea !important;
  box-shadow: 0 0 0 3px rgba(147, 51, 234, 0.15) !important;
}

/* Audio Volume Slider */
.audio-volume-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px solid #f3e8ff;
}

.audio-volume-slider {
  flex: 1;
  accent-color: #9333ea;
  height: 5px;
  border-radius: 999px;
  cursor: pointer;
  background: #e9d5ff;
  outline: none;
}

/* ==========================================================================
   CLINIC HERO DASHBOARD & METRICS GRID (BUKU KIA DIGITAL)
   ========================================================================== */
.clinic-hero-dashboard {
  background: linear-gradient(135deg, #fff1f2 0%, #ffffff 60%, #fff7ed 100%);
  border: 1.5px solid #fecdd3;
  border-radius: 22px;
  padding: 18px 16px;
  box-shadow: 0 4px 20px rgba(225, 29, 72, 0.06);
  margin-bottom: 14px;
}

.clinic-hero-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.clinic-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #ffe4e6;
  border: 1px solid #fecdd3;
  color: #9f1239;
  font-size: 0.68rem;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: 999px;
  letter-spacing: 0.3px;
}

.clinic-print-pill {
  font-weight: 750 !important;
  color: #be185d !important;
  border-color: #fbcfe8 !important;
  background: #ffffff !important;
  padding: 4px 10px !important;
  font-size: 0.72rem !important;
  border-radius: 999px !important;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}

.clinic-hero-title {
  font-size: 1.05rem;
  font-weight: 850;
  color: #1e293b;
  margin: 4px 0 2px;
  letter-spacing: -0.2px;
}

.clinic-hero-desc {
  font-size: 0.74rem;
  color: #64748b;
  line-height: 1.4;
  margin: 0 0 12px;
}

.clinic-stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}

.c-stat-pill {
  background: #ffffff;
  border: 1px solid #fed7aa;
  border-radius: 14px;
  padding: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
}

.c-stat-icon {
  font-size: 1.35rem;
  line-height: 1;
}

.c-stat-info {
  display: flex;
  flex-direction: column;
}

.c-stat-label {
  font-size: 0.65rem;
  font-weight: 700;
  color: #64748b;
}

.c-stat-val {
  font-size: 0.85rem;
  font-weight: 850;
  color: #0f172a;
  line-height: 1.2;
}

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

/* ==========================================================================
   KIA DIGITAL E-BOOK MODAL & READER (Official Kemenkes Format)
   ========================================================================== */
.kia-ebook-modal-card {
  max-width: 960px;
  width: 100%;
  height: 95vh;
  max-height: 95vh;
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow: hidden;
  border-radius: 24px 24px 0 0;
  background: #ffffff;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.25);
  transition: max-width 0.3s ease, height 0.3s ease, border-radius 0.3s ease;
}

.kia-ebook-modal-card.fullscreen-mode {
  max-width: 100vw;
  width: 100vw;
  height: 100vh;
  max-height: 100vh;
  border-radius: 0;
}

/* Compact Modal Header */
.kia-ebook-header {
  padding: 10px 14px;
  background: linear-gradient(135deg, #fff1f2 0%, #ffffff 100%);
  border-bottom: 1px solid #fecdd3;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-shrink: 0;
}

.kia-ebook-header-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.kia-ebook-emblem {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: linear-gradient(135deg, #f43f5e, #be123c);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  box-shadow: 0 3px 8px rgba(225, 29, 72, 0.2);
  flex-shrink: 0;
}

.kia-ebook-title-box {
  min-width: 0;
}

.kia-ebook-title-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.kia-ebook-title-box h3 {
  font-size: 0.95rem;
  font-weight: 850;
  color: #1e293b;
  margin: 0;
  line-height: 1.2;
}

.kia-edition-badge {
  font-size: 0.58rem;
  background: #be185d;
  color: white;
  padding: 2px 5px;
  border-radius: 4px;
  font-weight: 800;
  letter-spacing: 0.3px;
}

.kia-ebook-title-box p {
  font-size: 0.68rem;
  color: #be185d;
  font-weight: 600;
  margin: 1px 0 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.kia-ebook-header-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.btn-kia-pdf-icon {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #fff1f2;
  color: #be123c;
  border: 1px solid #fecdd3;
  padding: 4px 9px;
  border-radius: 8px;
  font-size: 0.72rem;
  font-weight: 750;
  text-decoration: none;
  transition: all 0.15s ease;
}

.btn-kia-pdf-icon:hover {
  background: #ffe4e6;
  border-color: #f43f5e;
}

/* ==========================================================================
   SLIDER BUKU ASLI KIA (INTERACTIVE FLIP READER)
   ========================================================================== */
.kia-slider-view {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: #0a0f1d;
  overflow: hidden;
  position: relative;
}

/* Top bar: Dropdown bab luas + Zoom reset */
.kia-slider-top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 10px;
  background: #0f172a;
  border-bottom: 1px solid #1e293b;
  gap: 8px;
  flex-shrink: 0;
  z-index: 10;
}

.kia-select-wrap {
  position: relative;
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
}

.kia-select-icon {
  position: absolute;
  left: 8px;
  font-size: 0.8rem;
  pointer-events: none;
}

.kia-chapter-select {
  width: 100%;
  padding: 5px 8px 5px 28px;
  background: #1e293b;
  color: #f8fafc;
  border: 1px solid #334155;
  border-radius: 8px;
  font-size: 0.76rem;
  font-weight: 650;
  cursor: pointer;
  outline: none;
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
}

.kia-chapter-select:focus {
  border-color: #f43f5e;
}

.kia-zoom-toolbar {
  display: flex;
  align-items: center;
  gap: 3px;
  background: #1e293b;
  border: 1px solid #334155;
  border-radius: 8px;
  padding: 2px 4px;
  flex-shrink: 0;
}

.btn-zoom-tool {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 0.78rem;
  font-weight: 700;
  width: 25px;
  height: 25px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-zoom-tool:hover {
  background: #334155;
  color: #ffffff;
}

.kia-zoom-indicator {
  font-size: 0.68rem;
  font-weight: 700;
  color: #e2e8f0;
  padding: 0 4px;
  min-width: 36px;
  text-align: center;
  cursor: pointer;
  user-select: none;
}

.kia-zoom-indicator:hover {
  color: #fda4af;
}

/* Stage Viewport (Panggung Lembar Buku - Lega & Proporsional) */
.kia-stage-viewport {
  flex: 1;
  min-height: 0;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 6px;
  background: radial-gradient(circle at center, #1e293b 0%, #080c14 100%);
  user-select: none;
  touch-action: pan-y pinch-zoom;
  perspective: 1200px;
}

.kia-sheet-frame {
  position: relative;
  height: 100%;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  transform-origin: center center;
  transform-style: preserve-3d;
}

.kia-current-page-img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.75), 0 0 0 1px rgba(255, 255, 255, 0.08);
  transition: transform 0.25s cubic-bezier(0.2, 0.9, 0.3, 1), opacity 0.25s ease;
  will-change: transform, opacity;
  cursor: zoom-in;
}

.kia-sheet-frame.is-zoomed .kia-current-page-img {
  cursor: zoom-out;
}

/* Animasi Slide Lembar Halaman Realistis */
.kia-current-page-img.slide-next {
  animation: bookSlideNext 0.3s cubic-bezier(0.2, 0.9, 0.3, 1) both;
}

.kia-current-page-img.slide-prev {
  animation: bookSlidePrev 0.3s cubic-bezier(0.2, 0.9, 0.3, 1) both;
}

@keyframes bookSlideNext {
  0% {
    opacity: 0.25;
    transform: translateX(40px) rotateY(-8deg) scale(0.96);
    filter: drop-shadow(-8px 0 12px rgba(0,0,0,0.5));
  }
  60% {
    opacity: 0.95;
    transform: translateX(-3px) rotateY(1deg) scale(1.005);
  }
  100% {
    opacity: 1;
    transform: translateX(0) rotateY(0deg) scale(1);
    filter: drop-shadow(0 10px 20px rgba(0,0,0,0.4));
  }
}

@keyframes bookSlidePrev {
  0% {
    opacity: 0.25;
    transform: translateX(-40px) rotateY(8deg) scale(0.96);
    filter: drop-shadow(8px 0 12px rgba(0,0,0,0.5));
  }
  60% {
    opacity: 0.95;
    transform: translateX(3px) rotateY(-1deg) scale(1.005);
  }
  100% {
    opacity: 1;
    transform: translateX(0) rotateY(0deg) scale(1);
    filter: drop-shadow(0 10px 20px rgba(0,0,0,0.4));
  }
}

/* Navigasi Panah Melayang (Floating Semi-Transparent Pill Nav) */
.btn-kia-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: #ffffff;
  font-size: 1.1rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 20;
  transition: all 0.2s ease;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
}

.btn-kia-nav:hover {
  background: rgba(225, 29, 72, 0.9);
  border-color: #f43f5e;
  transform: translateY(-50%) scale(1.08);
}

.btn-kia-nav:active {
  transform: translateY(-50%) scale(0.94);
}

.btn-kia-nav.prev {
  left: 8px;
}

.btn-kia-nav.next {
  right: 8px;
}

.btn-kia-nav:disabled {
  opacity: 0.2;
  cursor: not-allowed;
  pointer-events: none;
}

/* Subtle Floating Gesture Hint Badge */
.kia-swipe-hint-badge {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #cbd5e1;
  font-size: 0.65rem;
  font-weight: 650;
  padding: 3px 12px;
  border-radius: 999px;
  pointer-events: none;
  z-index: 15;
  white-space: nowrap;
  animation: hintFadeIn 0.3s ease;
}

@keyframes hintFadeIn {
  from { opacity: 0; transform: translate(-50%, 6px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

/* Compact Bottom Controller Bar */
.kia-slider-bottom-bar {
  padding: 6px 12px 8px;
  background: #0f172a;
  border-top: 1px solid #1e293b;
  display: flex;
  flex-direction: column;
  gap: 5px;
  flex-shrink: 0;
}

.kia-slider-info-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.kia-badge-group {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.kia-badge-side {
  font-size: 0.62rem;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 5px;
  background: #be185d;
  color: white;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.kia-badge-side.side-anak {
  background: #0284c7;
}

.kia-badge-page-count {
  font-size: 0.72rem;
  font-weight: 750;
  color: #cbd5e1;
}

.kia-slider-title {
  font-size: 0.74rem;
  font-weight: 700;
  color: #f8fafc;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: right;
  flex: 1;
}

/* Scrubber Row diapit panah mundur & maju */
.kia-scrubber-row {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
}

.btn-scrub-step {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: #1e293b;
  border: 1px solid #334155;
  color: #f8fafc;
  font-size: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.15s ease;
}

.btn-scrub-step:hover {
  background: #f43f5e;
  border-color: #f43f5e;
}

.btn-scrub-step:active {
  transform: scale(0.92);
}

.kia-page-scrubber {
  flex: 1;
  -webkit-appearance: none;
  appearance: none;
  height: 6px;
  border-radius: 999px;
  background: #334155;
  outline: none;
  cursor: pointer;
  transition: background 0.15s ease;
}

.kia-page-scrubber::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #f43f5e;
  border: 2px solid #ffffff;
  box-shadow: 0 2px 8px rgba(244, 63, 94, 0.5);
  cursor: grab;
  transition: transform 0.15s ease;
}

.kia-page-scrubber::-webkit-slider-thumb:active {
  transform: scale(1.25);
  cursor: grabbing;
}

.kia-page-scrubber::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #f43f5e;
  border: 2px solid #ffffff;
  box-shadow: 0 2px 8px rgba(244, 63, 94, 0.5);
  cursor: grab;
}

/* Spinner */
.kia-sheet-spinner {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: rgba(10, 15, 29, 0.75);
  color: #cbd5e1;
  font-size: 0.72rem;
  gap: 6px;
  z-index: 5;
  border-radius: 6px;
}

.kia-spinner-circle {
  width: 24px;
  height: 24px;
  border: 2.5px solid rgba(255, 255, 255, 0.15);
  border-top-color: #f43f5e;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

/* Responsive Mobile Layout */
@media (max-width: 640px) {
  .kia-ebook-modal-card {
    height: 98vh;
    max-height: 98vh;
    border-radius: 20px 20px 0 0;
  }
  .btn-kia-nav {
    width: 34px;
    height: 34px;
    font-size: 0.95rem;
  }
  .btn-kia-nav.prev { left: 4px; }
  .btn-kia-nav.next { right: 4px; }
  .kia-slider-bottom-bar {
    padding: 5px 10px 8px;
  }
}

/* Side Switcher (Ibu vs Anak - Flip Book Concept) */
.kia-side-switcher {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 8px 14px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  flex-shrink: 0;
}

.btn-kia-side {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 12px;
  border-radius: 12px;
  border: 1.5px solid transparent;
  background: white;
  color: #64748b;
  font-weight: 700;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.btn-kia-side.active-ibu {
  background: linear-gradient(135deg, #fff1f2, #ffe4e6);
  border-color: #f43f5e;
  color: #be123c;
  box-shadow: 0 3px 8px rgba(225, 29, 72, 0.15);
}

.btn-kia-side.active-anak {
  background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
  border-color: #0284c7;
  color: #0369a1;
  box-shadow: 0 3px 8px rgba(2, 132, 199, 0.15);
}

/* Search Bar & Font Sizer Bar */
.kia-toolbar {
  padding: 8px 14px;
  background: #ffffff;
  border-bottom: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.kia-search-input-wrap {
  position: relative;
  flex: 1;
}

.kia-search-input {
  width: 100%;
  padding: 8px 30px 8px 34px;
  font-size: 0.8rem;
  border-radius: 10px;
  border: 1px solid #cbd5e1;
  background: #f8fafc;
  color: #1e293b;
  outline: none;
  transition: all 0.2s ease;
}

.kia-search-input:focus {
  border-color: #f43f5e;
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(244, 63, 94, 0.15);
}

.kia-search-icon {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.85rem;
  color: #94a3b8;
  pointer-events: none;
}

.kia-search-clear {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 0.85rem;
  cursor: pointer;
  padding: 2px;
}

.kia-font-ctrls {
  display: flex;
  align-items: center;
  gap: 4px;
  background: #f1f5f9;
  border-radius: 8px;
  padding: 2px 4px;
}

.btn-font-scale {
  background: none;
  border: none;
  font-size: 0.75rem;
  font-weight: 800;
  color: #475569;
  padding: 4px 6px;
  cursor: pointer;
  border-radius: 6px;
  line-height: 1;
}

.btn-font-scale:hover, .btn-font-scale:active {
  background: white;
  color: #be185d;
}

/* Category Filter Chips */
.kia-category-chips {
  display: flex;
  gap: 6px;
  padding: 8px 14px;
  overflow-x: auto;
  white-space: nowrap;
  background: #ffffff;
  border-bottom: 1px solid #f1f5f9;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  flex-shrink: 0;
}

.kia-category-chips::-webkit-scrollbar {
  display: none;
}

.kia-chip {
  padding: 4px 10px;
  font-size: 0.72rem;
  font-weight: 700;
  border-radius: 999px;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  color: #64748b;
  cursor: pointer;
  transition: all 0.2s ease;
}

.kia-chip.active {
  background: #be185d;
  color: white;
  border-color: #be185d;
  box-shadow: 0 2px 6px rgba(190, 24, 93, 0.2);
}

.kia-chip.active.chip-blue {
  background: #0284c7;
  border-color: #0284c7;
  box-shadow: 0 2px 6px rgba(2, 132, 199, 0.2);
}

/* Content Reader Body */
.kia-ebook-body {
  flex: 1;
  overflow-y: auto;
  padding: 14px;
  background: #f8fafc;
  -webkit-overflow-scrolling: touch;
}

.kia-ebook-font-normal { font-size: 0.85rem; }
.kia-ebook-font-large { font-size: 0.94rem; }
.kia-ebook-font-xlarge { font-size: 1.04rem; }

/* Chapter Accordion Card */
.kia-chapter-card {
  background: #ffffff;
  border-radius: 18px;
  border: 1px solid #e2e8f0;
  margin-bottom: 12px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
  transition: all 0.25s ease;
}

.kia-chapter-card.open {
  border-color: #fbcfe8;
  box-shadow: 0 6px 20px rgba(225, 29, 72, 0.08);
}

.kia-chapter-header {
  padding: 14px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.kia-chapter-left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  min-width: 0;
}

.kia-chapter-icon {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: #fff1f2;
  color: #be123c;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}

.kia-chapter-meta {
  flex: 1;
  min-width: 0;
}

.kia-chapter-tag {
  font-size: 0.65rem;
  font-weight: 800;
  color: #be185d;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  margin-bottom: 2px;
  display: block;
}

.kia-chapter-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: #0f172a;
  margin: 0;
  line-height: 1.3;
}

.kia-chapter-chevron {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  color: #64748b;
  flex-shrink: 0;
  transition: transform 0.25s ease;
}

.kia-chapter-card.open .kia-chapter-chevron {
  transform: rotate(180deg);
  background: #ffe4e6;
  color: #be185d;
}

.kia-chapter-content {
  padding: 0 16px 16px;
  display: none;
  border-top: 1px dashed #f1f5f9;
  line-height: 1.6;
  color: #334155;
  animation: fadeIn 0.3s ease;
}

.kia-chapter-card.open .kia-chapter-content {
  display: block;
  padding-top: 14px;
}

.kia-ch-block {
  margin-bottom: 16px;
}

.kia-ch-block:last-child {
  margin-bottom: 0;
}

.kia-ch-sub {
  font-size: 0.9rem;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 6px;
}

.kia-ch-list {
  padding-left: 18px;
  margin: 6px 0;
}

.kia-ch-list li {
  margin-bottom: 4px;
}

/* Tips and Danger Highlight Boxes */
.kia-tip-box {
  padding: 12px 14px;
  border-radius: 12px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 10px 0;
  font-size: 0.8rem;
  line-height: 1.45;
}

.kia-tip-icon {
  font-size: 1.25rem;
  line-height: 1;
  flex-shrink: 0;
}

.tip-info {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e40af;
}

.tip-danger {
  background: #fef2f2;
  border: 1.5px solid #fecaca;
  color: #991b1b;
}

.tip-success {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
}

/* Danger Grid */
.kia-danger-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.danger-card {
  display: flex;
  gap: 10px;
  padding: 10px 12px;
  background: #fff1f2;
  border: 1px solid #fecdd3;
  border-radius: 12px;
}

.d-num {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #e11d48;
  color: white;
  font-weight: 800;
  font-size: 0.72rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.d-title {
  font-size: 0.82rem;
  font-weight: 800;
  color: #9f1239;
  margin: 0 0 2px;
}

.d-desc {
  font-size: 0.75rem;
  color: #475569;
  margin: 0;
  line-height: 1.35;
}

/* ANC Timeline */
.anc-timeline-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.anc-item {
  padding: 12px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
}

.anc-item.highlight-doc {
  background: #fff1f2;
  border: 1.5px solid #f43f5e;
}

.anc-badge {
  font-size: 0.78rem;
  font-weight: 850;
  color: #be185d;
  margin-bottom: 2px;
}

.anc-who {
  font-size: 0.76rem;
  font-weight: 750;
  color: #0f172a;
  margin-bottom: 4px;
}

.anc-desc {
  font-size: 0.75rem;
  color: #475569;
  margin: 0;
  line-height: 1.4;
}

/* Vaccine Grid */
.vax-schedule-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.vax-card {
  padding: 10px 12px;
  background: white;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
}

.vax-card.highlight-new {
  border-color: #38bdf8;
  background: #f0f9ff;
}

.vax-age {
  font-size: 0.78rem;
  font-weight: 850;
  color: #0284c7;
  margin-bottom: 4px;
}

.vax-names {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 4px;
}

.vax-pill {
  font-size: 0.7rem;
  font-weight: 750;
  background: #e0f2fe;
  color: #0369a1;
  padding: 2px 7px;
  border-radius: 6px;
}

.vax-pill.new-tag {
  background: #dcfce7;
  color: #15803d;
  border: 1px solid #86efac;
}

.vax-desc {
  font-size: 0.72rem;
  color: #64748b;
  margin: 0;
  line-height: 1.35;
}

/* MPASI Stages */
.mpasi-stages-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.stage-item {
  padding: 10px 12px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  font-size: 0.76rem;
  line-height: 1.4;
}

.stage-badge {
  font-size: 0.8rem;
  font-weight: 850;
  color: #0284c7;
  margin-bottom: 3px;
}

/* Footer PDF Link Banner */
.kia-ebook-footer {
  padding: 10px 16px;
  background: #ffffff;
  border-top: 1px solid #e2e8f0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.btn-pdf-kemkes {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.76rem;
  font-weight: 750;
  color: #0284c7;
  background: #f0f9ff;
  border: 1px solid #bae6fd;
  padding: 7px 12px;
  border-radius: 10px;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-pdf-kemkes:hover {
  background: #e0f2fe;
}

/* Home Promo Banner Card */
.kia-ebook-promo-card {
  background: linear-gradient(135deg, #fff1f2 0%, #ffffff 50%, #fdf2f8 100%);
  border: 1.5px solid #fecdd3;
  border-radius: 20px;
  padding: 14px 16px;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(225, 29, 72, 0.08);
  transition: all 0.25s ease;
  -webkit-tap-highlight-color: transparent;
}

.kia-ebook-promo-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(225, 29, 72, 0.14);
}

.kia-ebook-promo-card:active {
  transform: scale(0.98);
}

.kia-promo-icon {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: linear-gradient(135deg, #f43f5e, #be123c);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.45rem;
  box-shadow: 0 4px 12px rgba(225, 29, 72, 0.25);
  flex-shrink: 0;
  animation: floatFruitCute 4s ease-in-out infinite;
}

.kia-promo-text {
  flex: 1;
  min-width: 0;
}

.kia-promo-text h4 {
  font-size: 0.92rem;
  font-weight: 850;
  color: #881337;
  margin: 0 0 2px;
  line-height: 1.25;
}

.kia-promo-text p {
  font-size: 0.72rem;
  color: #64748b;
  margin: 0;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.kia-promo-btn {
  font-size: 0.72rem;
  font-weight: 800;
  color: #be185d;
  background: #fce7f3;
  padding: 4px 10px;
  border-radius: 999px;
  white-space: nowrap;
  flex-shrink: 0;
}

/* ==========================================================================
   KIA DIGITAL E-BOOK - VISUAL INFOGRAPHICS & ANIMATIONS
   ========================================================================== */

/* Keyframe Animations */
@keyframes kiaFloat {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-4px); }
  100% { transform: translateY(0px); }
}

@keyframes beaconPulse {
  0% { box-shadow: 0 0 0 0 rgba(225, 29, 72, 0.6); }
  70% { box-shadow: 0 0 0 10px rgba(225, 29, 72, 0); }
  100% { box-shadow: 0 0 0 0 rgba(225, 29, 72, 0); }
}

@keyframes beaconPulseGreen {
  0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.6); }
  70% { box-shadow: 0 0 0 10px rgba(16, 185, 129, 0); }
  100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

@keyframes shimmerKemenkes {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

@keyframes kiaUnfold {
  0% { opacity: 0; transform: translateY(-8px); }
  100% { opacity: 1; transform: translateY(0); }
}

@keyframes pulseGlowSoft {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.03); }
}

/* Active Floating Chapter Icon */
.kia-chapter-card.open .kia-chapter-icon {
  animation: kiaFloat 2.6s ease-in-out infinite;
  box-shadow: 0 4px 14px rgba(225, 29, 72, 0.2);
}

.kia-chapter-card.open .kia-chapter-content {
  animation: kiaUnfold 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* 1. Infografis Diagram "Isi Piringku Bumil" */
.kia-plate-visual-box {
  background: linear-gradient(145deg, #ffffff 0%, #fffbf5 100%);
  border: 1.5px solid #fde68a;
  border-radius: 18px;
  padding: 14px;
  margin: 12px 0;
  box-shadow: 0 4px 16px rgba(245, 158, 11, 0.08);
}

.kia-plate-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px dashed #fef08a;
}

.kia-plate-badge {
  font-size: 0.68rem;
  font-weight: 850;
  background: #f59e0b;
  color: white;
  padding: 3px 8px;
  border-radius: 999px;
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.kia-plate-diagram {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: center;
}

@media (min-width: 500px) {
  .kia-plate-diagram {
    flex-direction: row;
    align-items: stretch;
  }
}

.kia-plate-circle-wrapper {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.kia-plate-circle {
  width: 170px;
  height: 170px;
  border-radius: 50%;
  background: #ffffff;
  border: 8px solid #f1f5f9;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08), inset 0 2px 6px rgba(0, 0, 0, 0.04);
  position: relative;
  overflow: hidden;
  transition: transform 0.3s ease;
}

.kia-plate-circle:hover {
  transform: scale(1.03);
}

.plate-slice {
  position: absolute;
  width: 100%;
  height: 100%;
  clip-path: polygon(50% 50%, 0 0, 100% 0);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 10px;
}

.slice-carbo {
  background: linear-gradient(135deg, #fef3c7, #fde68a);
  clip-path: polygon(50% 50%, 0% 0%, 50% 0%, 100% 0%, 100% 50%, 50% 50%);
  transform: rotate(0deg);
}

.slice-protein {
  background: linear-gradient(135deg, #ffe4e6, #fecdd3);
  clip-path: polygon(50% 50%, 100% 50%, 100% 100%, 35% 100%, 50% 50%);
}

.slice-veggie {
  background: linear-gradient(135deg, #d1fae5, #a7f3d0);
  clip-path: polygon(50% 50%, 35% 100%, 0% 100%, 0% 0%, 50% 50%);
}

.plate-center-hub {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: white;
  border: 3px solid #f59e0b;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
  z-index: 5;
}

.plate-center-hub span {
  font-size: 0.62rem;
  font-weight: 850;
  color: #b45309;
  line-height: 1;
}

.kia-plate-labels-grid {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  justify-content: center;
}

.plate-legend-card {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 12px;
  background: white;
  border: 1px solid #f1f5f9;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02);
  transition: transform 0.2s ease;
}

.plate-legend-card:hover {
  transform: translateX(3px);
}

.legend-dot {
  width: 14px;
  height: 14px;
  border-radius: 4px;
  flex-shrink: 0;
  margin-top: 2px;
}

.legend-dot.carbo { background: #f59e0b; }
.legend-dot.protein { background: #e11d48; }
.legend-dot.veggie { background: #10b981; }

.legend-text h5 {
  font-size: 0.78rem;
  font-weight: 800;
  margin: 0 0 2px;
  color: #1e293b;
  display: flex;
  align-items: center;
  gap: 6px;
}

.legend-text p {
  font-size: 0.72rem;
  color: #64748b;
  margin: 0;
  line-height: 1.35;
}

.plate-bonus-row {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.plate-bonus-item {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 9px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 10px;
  font-size: 0.72rem;
  font-weight: 750;
  color: #166534;
}

.plate-bonus-item.water {
  background: #eff6ff;
  border-color: #bfdbfe;
  color: #1e40af;
}

/* 2. Visual Posisi Tidur Miring Kiri */
.kia-sleep-card {
  background: linear-gradient(135deg, #fdf4ff 0%, #ffffff 100%);
  border: 1.5px solid #f0abfc;
  border-radius: 16px;
  padding: 12px 14px;
  margin: 12px 0;
}

.kia-sleep-layout {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sleep-illustration {
  width: 58px;
  height: 58px;
  border-radius: 16px;
  background: #fae8ff;
  color: #a21caf;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(162, 28, 175, 0.12);
}

.sleep-details h5 {
  font-size: 0.84rem;
  font-weight: 850;
  color: #86198f;
  margin: 0 0 3px;
}

.sleep-details p {
  font-size: 0.73rem;
  color: #475569;
  margin: 0;
  line-height: 1.4;
}

.sleep-benefits-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 6px;
  padding: 3px 8px;
  border-radius: 999px;
  background: #fdf2f8;
  border: 1px solid #fbcfe8;
  font-size: 0.67rem;
  font-weight: 800;
  color: #be185d;
}

/* 3. Visual 10 Tanda Bahaya Kehamilan & Beacon */
.kia-danger-header-beacon {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: linear-gradient(135deg, #ffe4e6 0%, #fee2e2 100%);
  border: 1.5px solid #fda4af;
  border-radius: 14px;
  margin-bottom: 12px;
}

.beacon-radar {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #e11d48;
  animation: beaconPulse 1.8s infinite;
  flex-shrink: 0;
}

.kia-danger-grid-v2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

@media (min-width: 540px) {
  .kia-danger-grid-v2 {
    grid-template-columns: 1fr 1fr;
  }
}

.danger-card-v2 {
  display: flex;
  gap: 10px;
  padding: 10px 12px;
  background: #ffffff;
  border: 1.5px solid #fecdd3;
  border-left: 4px solid #e11d48;
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(225, 29, 72, 0.04);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.danger-card-v2:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(225, 29, 72, 0.12);
}

.danger-icon-badge {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: #ffe4e6;
  color: #be123c;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.danger-content-v2 {
  flex: 1;
  min-width: 0;
}

.danger-title-v2 {
  font-size: 0.8rem;
  font-weight: 850;
  color: #9f1239;
  margin: 0 0 2px;
  line-height: 1.25;
}

.danger-desc-v2 {
  font-size: 0.72rem;
  color: #475569;
  margin: 0;
  line-height: 1.35;
}

/* 4. Visual Stepper Linimasa ANC K1–K6 */
.anc-stepper-v2 {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-left: 28px;
  margin: 14px 0;
}

.anc-stepper-v2::before {
  content: "";
  position: absolute;
  top: 14px;
  bottom: 24px;
  left: 11px;
  width: 3px;
  background: linear-gradient(180deg, #f43f5e 0%, #ec4899 50%, #0ea5e9 100%);
  border-radius: 3px;
}

.anc-step-card {
  position: relative;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 12px 14px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.03);
  transition: all 0.2s ease;
}

.anc-step-card.highlight-doctor {
  border: 1.5px solid #f43f5e;
  background: linear-gradient(145deg, #fff1f2 0%, #ffffff 100%);
  box-shadow: 0 4px 14px rgba(244, 63, 94, 0.12);
}

.anc-step-node {
  position: absolute;
  left: -28px;
  top: 14px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #ffffff;
  border: 3px solid #be185d;
  color: #be185d;
  font-size: 0.68rem;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  z-index: 2;
}

.anc-step-card.highlight-doctor .anc-step-node {
  background: #f43f5e;
  border-color: #fda4af;
  color: #ffffff;
  animation: pulseGlowSoft 2.5s infinite;
}

.anc-step-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
  flex-wrap: wrap;
  gap: 4px;
}

.anc-step-tag {
  font-size: 0.72rem;
  font-weight: 850;
  color: #be185d;
}

.anc-step-badge-doc {
  font-size: 0.65rem;
  font-weight: 800;
  background: linear-gradient(90deg, #f43f5e, #fb7185, #f43f5e);
  background-size: 200% 100%;
  color: white;
  padding: 2px 7px;
  border-radius: 999px;
  animation: shimmerKemenkes 3s infinite linear;
}

.anc-step-provider {
  font-size: 0.74rem;
  font-weight: 750;
  color: #0f172a;
  margin-bottom: 4px;
}

.anc-step-checklist {
  font-size: 0.72rem;
  color: #475569;
  line-height: 1.4;
  margin: 0;
}

/* Standar 10 T Visual Cards */
.ten-t-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 6px;
  margin-top: 8px;
}

@media (min-width: 500px) {
  .ten-t-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

.ten-t-item {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 7px 6px;
  text-align: center;
  transition: transform 0.2s ease;
}

.ten-t-item:hover {
  transform: translateY(-2px);
  background: #eff6ff;
  border-color: #bfdbfe;
}

.ten-t-icon {
  font-size: 1.1rem;
  display: block;
  margin-bottom: 2px;
}

.ten-t-title {
  font-size: 0.66rem;
  font-weight: 800;
  color: #1e293b;
  line-height: 1.2;
}

/* 5. Visual Stiker P4K Kemenkes RI */
.p4k-sticker-card {
  background: #ffffff;
  border: 2.5px solid #dc2626;
  border-radius: 14px;
  padding: 12px 14px;
  margin: 12px 0;
  position: relative;
  box-shadow: 0 4px 14px rgba(220, 38, 38, 0.1);
  background-image: repeating-linear-gradient(45deg, rgba(220, 38, 38, 0.03), rgba(220, 38, 38, 0.03) 10px, transparent 10px, transparent 20px);
}

.p4k-top-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 2px solid #fee2e2;
  padding-bottom: 8px;
  margin-bottom: 10px;
}

.p4k-logo-text {
  font-size: 0.78rem;
  font-weight: 900;
  color: #b91c1c;
  letter-spacing: 0.5px;
}

.p4k-fields-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

@media (min-width: 480px) {
  .p4k-fields-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.p4k-field {
  background: white;
  border: 1px solid #fecaca;
  border-radius: 8px;
  padding: 6px 8px;
}

.p4k-field label {
  font-size: 0.62rem;
  font-weight: 800;
  color: #991b1b;
  text-transform: uppercase;
  display: block;
  margin-bottom: 2px;
}

.p4k-field span {
  font-size: 0.74rem;
  font-weight: 700;
  color: #1e293b;
}

/* Tas Siaga Persalinan Visual */
.hospital-bag-tabs {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin-top: 10px;
}

@media (min-width: 500px) {
  .hospital-bag-tabs {
    grid-template-columns: repeat(3, 1fr);
  }
}

.bag-tab-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 10px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02);
}

.bag-tab-title {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  font-weight: 850;
  color: #0f172a;
  margin-bottom: 6px;
}

.bag-tab-items {
  font-size: 0.7rem;
  color: #475569;
  line-height: 1.35;
  padding-left: 14px;
  margin: 0;
}

/* 6. Visual 4 Tindakan Bayi Baru Lahir */
.newborn-actions-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin: 10px 0;
}

@media (min-width: 500px) {
  .newborn-actions-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.newborn-action-card {
  background: #ffffff;
  border: 1px solid #bae6fd;
  border-radius: 12px;
  padding: 10px 12px;
  display: flex;
  gap: 10px;
  box-shadow: 0 2px 6px rgba(2, 132, 199, 0.05);
  transition: transform 0.2s ease;
}

.newborn-action-card:hover {
  transform: translateY(-2px);
  border-color: #38bdf8;
}

.action-step-num {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #0284c7;
  color: white;
  font-size: 0.72rem;
  font-weight: 850;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.action-step-body h5 {
  font-size: 0.78rem;
  font-weight: 850;
  color: #0369a1;
  margin: 0 0 2px;
}

.action-step-body p {
  font-size: 0.7rem;
  color: #475569;
  margin: 0;
  line-height: 1.35;
}

/* 7. Visual 3 Mangkuk MPASI Tekstur */
.mpasi-bowls-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin: 12px 0;
}

@media (min-width: 520px) {
  .mpasi-bowls-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.mpasi-bowl-card {
  background: #ffffff;
  border: 1.5px solid #fed7aa;
  border-radius: 14px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  position: relative;
  box-shadow: 0 2px 8px rgba(249, 115, 22, 0.06);
  transition: all 0.2s ease;
}

.mpasi-bowl-card:hover {
  transform: translateY(-2px);
  border-color: #f97316;
  box-shadow: 0 6px 16px rgba(249, 115, 22, 0.12);
}

.bowl-badge-age {
  font-size: 0.72rem;
  font-weight: 850;
  color: #ea580c;
  background: #ffedd5;
  padding: 2px 8px;
  border-radius: 999px;
  align-self: flex-start;
}

.bowl-icon-large {
  font-size: 2.2rem;
  text-align: center;
  margin: 4px 0;
  animation: kiaFloat 3s ease-in-out infinite;
}

.bowl-title {
  font-size: 0.8rem;
  font-weight: 850;
  color: #1e293b;
  margin: 0;
}

.bowl-texture-meter {
  height: 6px;
  background: #f1f5f9;
  border-radius: 3px;
  overflow: hidden;
  margin: 4px 0;
}

.texture-fill {
  height: 100%;
  border-radius: 3px;
  background: linear-gradient(90deg, #fb923c, #f97316);
}

.texture-fill.stage-1 { width: 35%; }
.texture-fill.stage-2 { width: 68%; }
.texture-fill.stage-3 { width: 100%; }

.bowl-desc {
  font-size: 0.7rem;
  color: #64748b;
  line-height: 1.35;
  margin: 0;
}

/* 8. Visual Grafik KMS Posyandu */
.kms-visual-card {
  background: #ffffff;
  border: 1.5px solid #cbd5e1;
  border-radius: 16px;
  padding: 14px;
  margin: 12px 0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

.kms-zones-display {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 10px 0;
}

.kms-zone-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  border-radius: 10px;
  font-size: 0.72rem;
  font-weight: 800;
}

.zone-green {
  background: #dcfce7;
  color: #15803d;
  border: 1px solid #86efac;
}

.zone-yellow {
  background: #fef9c3;
  color: #854d0e;
  border: 1px solid #fde047;
}

.zone-red {
  background: #fee2e2;
  color: #991b1b;
  border: 1px solid #fca5a5;
  animation: pulseGlowSoft 2.8s infinite;
}

.kms-rules-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 10px;
}

.kms-rule-item {
  padding: 8px 10px;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

.rule-n {
  border-left: 4px solid #16a34a;
}

.rule-t {
  border-left: 4px solid #dc2626;
}

.kms-rule-item h6 {
  font-size: 0.74rem;
  font-weight: 850;
  margin: 0 0 2px;
}

.rule-n h6 { color: #16a34a; }
.rule-t h6 { color: #dc2626; }

.kms-rule-item p {
  font-size: 0.68rem;
  color: #64748b;
  margin: 0;
  line-height: 1.35;
}

/* 9. Visual Milestone Anak Stepper */
.milestone-stepper {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 10px 0;
}

.milestone-chip-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  background: #f0f9ff;
  border: 1px solid #bae6fd;
  border-radius: 12px;
  transition: transform 0.2s ease;
}

.milestone-chip-item:hover {
  transform: translateX(3px);
  background: #e0f2fe;
}

.milestone-age-tag {
  font-size: 0.72rem;
  font-weight: 900;
  color: #0369a1;
  background: #bae6fd;
  padding: 3px 8px;
  border-radius: 8px;
  white-space: nowrap;
  flex-shrink: 0;
}

.milestone-chip-desc {
  font-size: 0.72rem;
  color: #334155;
  margin: 0;
  line-height: 1.35;
}

/* ==========================================================================
   BUKU KIA 2024 RESMI - ILUSTRASI VISUAL GAMBAR & ANIMASI INTERAKTIF
   ========================================================================== */
.kia-illustration-card {
  background: #ffffff;
  border: 1.5px solid #fed7aa;
  border-radius: 18px;
  padding: 12px;
  margin: 14px 0;
  box-shadow: 0 4px 16px rgba(234, 88, 12, 0.06);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.kia-illustration-card.theme-ibu {
  border-color: #fecdd3;
  box-shadow: 0 4px 16px rgba(225, 29, 72, 0.06);
}

.kia-illustration-card.theme-anak {
  border-color: #bae6fd;
  box-shadow: 0 4px 16px rgba(2, 132, 199, 0.06);
}

.kia-illustration-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.kia-ill-badge {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  padding-bottom: 6px;
  border-bottom: 1px dashed #e2e8f0;
}

.kia-ill-badge-title {
  font-size: 0.7rem;
  font-weight: 850;
  color: #c2410c;
  display: flex;
  align-items: center;
  gap: 5px;
}

.theme-ibu .kia-ill-badge-title {
  color: #be185d;
}

.theme-anak .kia-ill-badge-title {
  color: #0369a1;
}

.ill-page-tag {
  font-size: 0.62rem;
  font-weight: 800;
  background: #f1f5f9;
  color: #475569;
  padding: 2px 7px;
  border-radius: 6px;
  letter-spacing: 0.2px;
}

.kia-ill-img-wrap {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  background: #f8fafc;
  cursor: zoom-in;
  border: 1px solid #e2e8f0;
}

.kia-book-img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.35s ease;
}

.kia-ill-img-wrap:hover .kia-book-img {
  transform: scale(1.02);
}

.ill-zoom-hint {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  color: #ffffff;
  font-size: 0.64rem;
  font-weight: 750;
  padding: 3px 9px;
  border-radius: 999px;
  pointer-events: none;
  display: flex;
  align-items: center;
  gap: 4px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  transition: background 0.2s ease;
}

.kia-ill-img-wrap:hover .ill-zoom-hint {
  background: rgba(225, 29, 72, 0.9);
}

/* Lightbox Modal for Fullscreen Image Zoom */
.modal-kia-lightbox {
  position: fixed;
  inset: 0;
  z-index: 10005;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.modal-kia-lightbox.active {
  display: flex;
  opacity: 1;
}

.lightbox-content-box {
  position: relative;
  max-width: 95vw;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: zoomLightIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes zoomLightIn {
  from { transform: scale(0.92); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.lightbox-img {
  max-width: 100%;
  max-height: 84vh;
  object-fit: contain;
  border-radius: 14px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.lightbox-close-btn {
  position: absolute;
  top: -12px;
  right: -12px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #ffffff;
  color: #0f172a;
  border: none;
  font-size: 1.2rem;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
  z-index: 10;
  transition: transform 0.2s ease;
}

.lightbox-close-btn:active {
  transform: scale(0.9);
}

/* ==========================================================================
   PENJELAJAH JANIN MINGGUAN (INTERACTIVE FETAL EXPLORER)
   ========================================================================== */
.milestone-trimester-tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  white-space: nowrap;
  padding: 2px 0 10px;
  -webkit-overflow-scrolling: touch;
}

.btn-trimester-tab {
  flex: 1;
  min-width: 120px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  color: #64748b;
  font-size: 0.74rem;
  font-weight: 750;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
}

.btn-trimester-tab.active {
  background: linear-gradient(135deg, #f43f5e, #be123c);
  color: #ffffff;
  border-color: #be123c;
  box-shadow: 0 3px 10px rgba(225, 29, 72, 0.25);
}

.milestone-local-compare-pill {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 800;
  color: #b45309;
  background: #fef3c7;
  border: 1px solid #fde68a;
  border-radius: 999px;
  padding: 4px 12px;
  margin: 4px 0 8px;
}

.btn-milestone-audio {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: #fff1f2;
  border: 1.5px solid #fecdd3;
  color: #be123c;
  font-weight: 800;
  font-size: 0.78rem;
  padding: 8px 16px;
  border-radius: 999px;
  margin-top: 10px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 2px 8px rgba(225, 29, 72, 0.08);
}

.btn-milestone-audio:active {
  transform: scale(0.96);
}

.btn-milestone-audio.playing {
  background: linear-gradient(135deg, #e11d48, #9f1239);
  color: white;
  border-color: #be123c;
  box-shadow: 0 4px 14px rgba(225, 29, 72, 0.35);
  animation: pulseAudio 1.5s infinite;
}

@keyframes pulseAudio {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.03); }
}

.milestone-organ-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

.organ-chip-pill {
  display: inline-flex;
  align-items: center;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1d4ed8;
  font-size: 0.74rem;
  font-weight: 750;
  padding: 4px 10px;
  border-radius: 8px;
}

/* ==========================================================================
   KALKULATOR KENAIKAN BERAT BADAN IDEAL (IOM & KEMENKES RI)
   ========================================================================== */
.weight-calc-card {
  background: #ffffff;
  border: 1.5px solid #fed7aa;
  border-radius: 20px;
  padding: 16px;
  box-shadow: 0 4px 16px rgba(251, 146, 60, 0.06);
  margin-bottom: 16px;
}

.weight-calc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}

.w-calc-field label {
  font-size: 0.72rem;
  font-weight: 750;
  color: #475569;
  margin-bottom: 4px;
  display: block;
  white-space: nowrap;
}

.w-calc-field input {
  text-align: center;
  font-weight: 850;
  font-size: 0.95rem;
  padding: 9px 4px;
  border-radius: 12px;
  background: #f8fafc;
}

.weight-calc-result-box {
  background: linear-gradient(135deg, #fffaf5 0%, #fef3c7 100%);
  border: 1.5px solid #fde68a;
  border-radius: 16px;
  padding: 14px;
  box-sizing: border-box;
}

.w-result-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding-bottom: 12px;
  border-bottom: 1px dashed #fcd34d;
}

.w-res-label {
  font-size: 0.72rem;
  color: #78350f;
  font-weight: 700;
  display: block;
  margin-bottom: 2px;
}

.w-res-val-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.w-res-bmi-num {
  font-size: 1.35rem;
  font-weight: 900;
  color: #1e293b;
}

.w-res-bmi-pill {
  font-size: 0.72rem;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 8px;
  background: #dcfce7;
  color: #15803d;
  border: 1px solid #86efac;
}

.w-res-target-wrap {
  text-align: right;
}

.w-res-target-val {
  font-size: 0.98rem;
  font-weight: 850;
  color: #0369a1;
}

.w-week-diagnosis-card {
  margin-top: 12px;
  background: #ffffff;
  border-radius: 14px;
  padding: 12px;
  border: 1px solid #fde68a;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
}

.w-diag-status-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

.w-diag-tag {
  font-size: 0.78rem;
  font-weight: 850;
  padding: 4px 10px;
  border-radius: 8px;
  background: #f0fdf4;
  color: #166534;
  border: 1px solid #bbf7d0;
}

.w-diag-tag.status-kurang {
  background: #fefce8;
  color: #854d0e;
  border-color: #fef08a;
}

.w-diag-tag.status-lebih {
  background: #fff1f2;
  color: #9f1239;
  border-color: #fecdd3;
}

.w-diag-nums {
  font-size: 0.74rem;
  color: #475569;
  font-weight: 650;
}

.w-diag-dot {
  margin: 0 4px;
  color: #cbd5e1;
}

.w-gauge-track-wrap {
  margin: 14px 4px 8px;
}

.w-gauge-track {
  height: 12px;
  border-radius: 999px;
  overflow: visible;
  display: flex;
  position: relative;
  background: #e2e8f0;
}

.w-gauge-segment.zone-under {
  flex: 1.2;
  background: #facc15;
  border-top-left-radius: 999px;
  border-bottom-left-radius: 999px;
}

.w-gauge-segment.zone-ideal {
  flex: 2;
  background: #22c55e;
}

.w-gauge-segment.zone-over {
  flex: 1.2;
  background: #f43f5e;
  border-top-right-radius: 999px;
  border-bottom-right-radius: 999px;
}

.w-gauge-needle {
  position: absolute;
  top: -18px;
  transform: translateX(-50%);
  transition: left 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 2;
}

.needle-pin {
  font-size: 1.1rem;
  line-height: 1;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.35));
}

.w-gauge-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.68rem;
  color: #64748b;
  font-weight: 700;
  margin-top: 6px;
}

.w-gauge-labels .lbl-ideal {
  color: #16a34a;
  font-weight: 850;
}

.w-diag-advice {
  font-size: 0.76rem;
  color: #334155;
  line-height: 1.5;
  margin: 10px 0 0;
  padding-top: 8px;
  border-top: 1px dashed #e2e8f0;
}

/* ============================================================
   1. JURNAL KELUHAN HARIAN & SOLUSI ALAMI BUMIL
   ============================================================ */
.symptom-tracker-card {
  border: 1px solid #ffe4e6;
  background: linear-gradient(180deg, #fff 0%, #fffbfb 100%);
  position: relative;
  overflow: hidden;
}

.symptom-live-badge {
  font-size: 0.68rem;
  font-weight: 800;
  color: #e11d48;
  background: #ffe4e6;
  padding: 3px 8px;
  border-radius: 999px;
  letter-spacing: 0.2px;
}

.symptom-chips-scroll {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 4px 2px 10px;
  margin: 0 -2px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.symptom-chips-scroll::-webkit-scrollbar {
  display: none;
}

.symptom-chip-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  background: #ffffff;
  border: 1.5px solid #f1f5f9;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 700;
  color: #334155;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
}

.symptom-chip-btn:hover {
  border-color: #fbcfe8;
  background: #fff5f7;
  transform: translateY(-1px);
}

.symptom-chip-btn.active {
  background: #be185d;
  color: #ffffff;
  border-color: #be185d;
  box-shadow: 0 3px 10px rgba(190, 24, 93, 0.28);
}

.symptom-chip-icon {
  font-size: 0.95rem;
  line-height: 1;
}

.symptom-quick-solution-box {
  background: #ffffff;
  border: 1px solid #fbcfe8;
  border-radius: 14px;
  padding: 12px 14px;
  margin-bottom: 12px;
  box-shadow: 0 4px 14px rgba(225, 29, 72, 0.06);
  animation: fadeInDown 0.25s ease-out;
}

.sym-quick-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 8px;
}

.sym-quick-title {
  font-size: 0.86rem;
  font-weight: 850;
  color: #881337;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 6px;
}

.sym-quick-badge {
  font-size: 0.65rem;
  background: #fdf2f8;
  color: #9d174d;
  font-weight: 750;
  padding: 2px 7px;
  border-radius: 6px;
  border: 1px solid #fce7f3;
}

.sym-quick-remedy {
  font-size: 0.78rem;
  line-height: 1.5;
  color: #1e293b;
  margin-bottom: 10px;
}

.sym-quick-remedy b {
  color: #047857;
}

.sym-quick-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.btn-sym-detail-open {
  flex: 1;
  background: #fdf2f8;
  border: 1px solid #fbcfe8;
  color: #be185d;
  font-weight: 750;
  font-size: 0.74rem;
  padding: 6px 10px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-sym-detail-open:hover {
  background: #fce7f3;
}

.btn-sym-record {
  background: #be185d;
  color: #ffffff;
  border: none;
  font-weight: 800;
  font-size: 0.74rem;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(190, 24, 93, 0.25);
  transition: all 0.2s;
}
.btn-sym-record:hover {
  background: #9d174d;
}

.symptom-recent-history-wrap {
  padding-top: 10px;
  border-top: 1px dashed #f1f5f9;
}

.symptom-history-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-height: 28px;
}

.sym-history-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 3px 8px;
  font-size: 0.7rem;
  color: #334155;
  font-weight: 600;
}

.sym-history-tag .tag-date {
  color: #64748b;
  font-weight: 500;
  font-size: 0.65rem;
}

.sym-history-del-btn {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 0.85rem;
  cursor: pointer;
  padding: 0 2px;
  line-height: 1;
}
.sym-history-del-btn:hover {
  color: #ef4444;
}

/* Modal Symptom Sheet */
.modal-symptom-sheet {
  max-width: 520px;
  border-radius: 20px;
}

.symptom-modal-head-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.symptom-modal-icon {
  font-size: 1.8rem;
  line-height: 1;
}

.symptom-modal-head-title h3 {
  font-size: 1.05rem;
  font-weight: 850;
  color: #1e293b;
  margin: 0;
}

.symptom-trimester-tag {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 750;
  color: #be185d;
  background: #fdf2f8;
  border: 1px solid #fce7f3;
  padding: 2px 7px;
  border-radius: 6px;
  margin-top: 2px;
}

.sym-card-box {
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 12px;
  font-size: 0.78rem;
  line-height: 1.55;
}

.sym-box-head {
  font-size: 0.8rem;
  font-weight: 850;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.sym-medical-fact {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
}
.sym-medical-fact p {
  margin: 0;
  color: #14532d;
}

.sym-remedy-box {
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
}
.sym-remedy-box div {
  color: #78350f;
}

.sym-redflag-box {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
}
.sym-redflag-box p {
  margin: 0;
  color: #7f1d1d;
  font-weight: 600;
}

.sym-log-form-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 12px;
}

/* ============================================================
   2. PANDUAN POSISI TIDUR & ERGONOMI BUMIL
   ============================================================ */
.ergonomic-sleep-promo-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background: linear-gradient(135deg, #f0fdfa 0%, #e6fffa 100%);
  border: 1px solid #ccfbf1;
  border-radius: 16px;
  padding: 12px 14px;
  margin-bottom: 16px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 2px 8px rgba(13, 148, 136, 0.08);
}
.ergonomic-sleep-promo-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(13, 148, 136, 0.15);
  border-color: #99f6e4;
}

.ergo-promo-icon-circle {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.45rem;
  box-shadow: 0 2px 6px rgba(13, 148, 136, 0.15);
  flex-shrink: 0;
}

.ergo-promo-info {
  flex: 1;
}

.ergo-promo-tag {
  font-size: 0.65rem;
  font-weight: 800;
  color: #0f766e;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  margin-bottom: 2px;
}

.ergo-promo-info h4 {
  font-size: 0.88rem;
  font-weight: 850;
  color: #115e59;
  margin: 0 0 2px;
  line-height: 1.25;
}

.ergo-promo-info p {
  font-size: 0.72rem;
  color: #475569;
  margin: 0;
  line-height: 1.35;
}

.btn-ergo-promo-action {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #0d9488;
  color: #ffffff;
  border: none;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 6px 10px;
  border-radius: 999px;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(13, 148, 136, 0.25);
}

.modal-ergonomic-sheet {
  max-width: 600px;
  border-radius: 20px;
}

.ergo-tabs-bar {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 4px 16px 8px;
  border-bottom: 1px solid #f1f5f9;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.ergo-tabs-bar::-webkit-scrollbar {
  display: none;
}

.ergo-tab-btn {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 0.74rem;
  font-weight: 750;
  color: #475569;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
}
.ergo-tab-btn:hover {
  background: #f1f5f9;
  color: #0f766e;
}
.ergo-tab-btn.active {
  background: #0d9488;
  color: #ffffff;
  border-color: #0d9488;
  box-shadow: 0 3px 8px rgba(13, 148, 136, 0.28);
}

.ergo-hero-card {
  background: linear-gradient(135deg, #f0fdfa, #ccfbf1);
  border-radius: 14px;
  padding: 12px 14px;
  margin-bottom: 12px;
}

.ergo-badge-pill {
  display: inline-block;
  background: #0f766e;
  color: #ffffff;
  font-size: 0.62rem;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  padding: 2px 7px;
  border-radius: 999px;
  margin-bottom: 6px;
}

.ergo-title {
  font-size: 0.94rem;
  font-weight: 850;
  color: #115e59;
  margin: 0 0 4px;
}

.ergo-desc {
  font-size: 0.76rem;
  color: #334155;
  margin: 0;
  line-height: 1.45;
}

.ergo-points-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ergo-point-item {
  display: flex;
  gap: 10px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 10px 12px;
  font-size: 0.77rem;
  line-height: 1.5;
  color: #334155;
}

.ergo-point-item b {
  color: #0f172a;
  display: block;
  margin-bottom: 2px;
  font-size: 0.8rem;
}

.ergo-point-item p {
  margin: 0;
  color: #475569;
}

.ergo-point-icon {
  font-size: 1.2rem;
  line-height: 1;
  flex-shrink: 0;
  margin-top: 2px;
}

.ergo-point-item.danger-warning {
  background: #fff1f2;
  border-color: #fecdd3;
}
.ergo-point-item.danger-warning b {
  color: #be185d;
}
.ergo-point-item.danger-warning p {
  color: #881337;
}

/* ============================================================
   3. PEMERIKSA INTERAKSI SUPLEMEN PINTAR
   ============================================================ */
.supplement-interaction-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 14px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.interact-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.interact-card-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.88rem;
  font-weight: 850;
  color: #1e293b;
  margin: 0;
}

.interact-badge-status {
  font-size: 0.65rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
.interact-badge-status.safe {
  background: #dcfce7;
  color: #15803d;
}
.interact-badge-status.warning {
  background: #fee2e2;
  color: #b91c1c;
}

.interact-alert-box {
  display: flex;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 0.76rem;
  line-height: 1.5;
  margin-bottom: 8px;
}

.interact-alert-box b {
  display: block;
  font-size: 0.79rem;
  margin-bottom: 2px;
}

.interact-alert-box p {
  margin: 0;
}

.interact-alert-box.alert-conflict {
  background: #fff1f2;
  border: 1.5px solid #fecdd3;
  color: #9f1239;
}

.interact-alert-box.alert-ok {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
}

.interact-alert-box.alert-tip {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e40af;
}

.btn-auto-schedule {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  background: linear-gradient(135deg, #0d9488, #0f766e);
  color: #ffffff;
  border: none;
  border-radius: 10px;
  padding: 9px 12px;
  font-size: 0.77rem;
  font-weight: 800;
  cursor: pointer;
  margin-top: 10px;
  box-shadow: 0 3px 8px rgba(13, 148, 136, 0.22);
  transition: all 0.2s;
}
.btn-auto-schedule:hover {
  background: linear-gradient(135deg, #0f766e, #115e59);
  transform: translateY(-1px);
}

/* ============================================================
   4. CLINIC SYMPTOMS SUMMARY LIST
   ============================================================ */
.clinic-symptom-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  margin-bottom: 6px;
  font-size: 0.76rem;
}

.clinic-sym-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.clinic-sym-date {
  font-size: 0.68rem;
  font-weight: 700;
  color: #64748b;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  padding: 2px 6px;
  border-radius: 6px;
}


