/* Product search embedded in the app's Product tab. */
.imart-product-search-portal {
  position: relative;
  width: 100%;
  height: calc(100dvh - 152px);
  min-height: calc(100dvh - 152px);
  overflow: hidden;
  background: #f5f9fd;
}

.imart-product-search-frame {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 100%;
  border: 0;
  background: #f5f9fd;
}

.branch-open-header-button { animation: branch-header-glow 3.2s ease-in-out infinite; }

/* Homepage: twelve care-led product categories. */
.home-category-panel {
  margin: 0 0 18px;
  padding: 18px 14px 20px;
  border: 1px solid #dbe8f5;
  border-radius: 22px;
  background: linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
  box-shadow: 0 12px 30px rgba(26, 70, 110, .09);
}

.home-category-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 17px;
}

.home-category-heading span {
  display: block;
  color: #f97316;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .05em;
}

.home-category-heading h3 {
  margin: 3px 0 0;
  color: #173e67;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.25;
}

.home-category-heading button {
  flex: 0 0 auto;
  padding: 8px 11px;
  border: 0;
  border-radius: 999px;
  background: #eaf3fc;
  color: #174b7e;
  font: 800 10px/1.2 "Prompt", sans-serif;
}

.home-category-viewport {
  position: relative;
  margin: 0 -14px;
  overflow: hidden;
}

.home-category-viewport::before,
.home-category-viewport::after {
  content: "";
  position: absolute;
  z-index: 2;
  top: 0;
  bottom: 0;
  width: 18px;
  pointer-events: none;
}

.home-category-viewport::before {
  left: 0;
  background: linear-gradient(90deg, #f9fcff, rgba(249, 252, 255, 0));
}

.home-category-viewport::after {
  right: 0;
  background: linear-gradient(270deg, #f9fcff, rgba(249, 252, 255, 0));
}

.home-category-rail {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scroll-snap-type: x mandatory;
  touch-action: pan-x pan-y pinch-zoom;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 2px 18px 7px;
}

.home-category-rail::-webkit-scrollbar { display: none; }

.home-category-rail > button {
  flex: 0 0 78px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #375471;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  text-align: center;
  font: 800 10px/1.28 "Prompt", sans-serif;
  scroll-snap-align: start;
}

.home-category-icon {
  width: 58px;
  height: 58px;
  border: 1px solid #cfe1f4;
  border-radius: 50%;
  background: linear-gradient(145deg, #ffffff, #e8f3ff);
  display: grid;
  place-items: center;
  box-shadow: 0 7px 17px rgba(24, 77, 126, .14);
  font-size: 26px;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.home-category-rail > button:hover .home-category-icon,
.home-category-rail > button:focus-visible .home-category-icon {
  transform: translateY(-2px);
  border-color: #f59a5e;
  box-shadow: 0 10px 22px rgba(24, 77, 126, .2);
}

.home-category-hint {
  margin: 8px 0 0;
  color: #7890a8;
  text-align: center;
  font-size: 9px;
  font-weight: 700;
}

.home-category-hint span {
  margin-right: 4px;
  color: #f97316;
  font-size: 12px;
}

.home-product-guide-cta {
  width: 100%;
  margin: 0 0 22px;
  padding: 17px;
  border: 1.5px solid #93c5fd;
  border-radius: 21px;
  background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 50%, #0284c7 100%);
  color: #ffffff;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 13px;
  text-align: left;
  font-family: "Prompt", sans-serif;
  box-shadow: 0 10px 26px rgba(37, 99, 235, 0.22);
  transition: transform .2s ease, box-shadow .2s ease;
}

.home-product-guide-cta:hover,
.home-product-guide-cta:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 17px 36px rgba(14, 59, 104, .3);
}

.home-guide-icon {
  width: 50px;
  height: 50px;
  border-radius: 16px;
  background: #ffffff;
  color: #173e67;
  display: grid;
  place-items: center;
  font-size: 25px;
  box-shadow: 0 6px 15px rgba(5, 26, 52, .2);
}

.home-product-guide-cta small,
.home-product-guide-cta strong,
.home-product-guide-cta em { display: block; }
.home-product-guide-cta small { color: #ffbd83; font-size: 10px; font-weight: 900; }
.home-product-guide-cta strong { margin-top: 2px; font-size: 16px; font-weight: 900; line-height: 1.25; }
.home-product-guide-cta em { margin-top: 3px; color: #d8eafa; font-size: 10px; font-style: normal; font-weight: 600; line-height: 1.35; }
.home-guide-arrow { font-size: 22px; font-weight: 900; }

@keyframes branch-header-glow {
  0%, 100% { box-shadow: 0 3px 8px rgba(249, 115, 22, .3), 0 0 0 0 rgba(249, 115, 22, .18); }
  50% { box-shadow: 0 4px 14px rgba(249, 115, 22, .48), 0 0 0 5px rgba(249, 115, 22, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .branch-open-header-button { animation: none; }
  .home-category-icon,
  .home-product-guide-cta { transition: none; }
}

@media (max-width: 360px) {
  .home-category-rail > button { flex-basis: 74px; }
  .home-category-icon { width: 56px; height: 56px; }
}

/* =========================================================================
   ✨ BLINKING WELLNESS AUDIT (Top Glowing Card + Floating Pill)
   ========================================================================= */

/* --- 1. Top Card Blinking & Glow Animations --- */
@keyframes wellness-glow-pulse {
  0%, 100% {
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.14), 0 2px 8px rgba(249, 115, 22, 0.08);
    border-color: #6ee7b7;
    transform: translateY(0);
  }
  50% {
    box-shadow: 0 10px 28px rgba(16, 185, 129, 0.26), 0 4px 14px rgba(249, 115, 22, 0.16);
    border-color: #34d399;
    transform: translateY(-2px);
  }
}

@keyframes wellness-blink-beacon {
  0%, 100% {
    opacity: 1;
    transform: scale(1.15);
    box-shadow: 0 0 8px #10b981, 0 0 16px #10b981;
    background: #10b981;
  }
  50% {
    opacity: 0.35;
    transform: scale(0.75);
    box-shadow: none;
    background: #059669;
  }
}

@keyframes wellness-beacon-ripple {
  0% {
    transform: scale(1);
    opacity: 0.85;
  }
  100% {
    transform: scale(3.2);
    opacity: 0;
  }
}

@keyframes wellness-shimmer-sweep {
  0% { transform: translateX(-150%) skewX(-20deg); }
  25%, 100% { transform: translateX(250%) skewX(-20deg); }
}

@keyframes cta-btn-blink {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 4px 14px rgba(255, 107, 0, 0.4);
    filter: brightness(1);
  }
  50% {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(255, 107, 0, 0.65), 0 0 12px rgba(254, 215, 170, 0.6);
    filter: brightness(1.12);
  }
}

@keyframes icon-box-pulse {
  0%, 100% {
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.32);
    transform: scale(1);
  }
  50% {
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.65), 0 0 10px #6ee7b7;
    transform: scale(1.07);
  }
}

@keyframes icon-wiggle {
  0%, 100% { transform: scale(1) rotate(0deg); }
  10% { transform: scale(1.25) rotate(-15deg); }
  20% { transform: scale(1.25) rotate(15deg); }
  30% { transform: scale(1.15) rotate(0deg); }
}

.home-wellness-top-wrapper {
  margin: 4px 0 18px;
  width: 100%;
}

.home-wellness-top-card {
  width: 100%;
  padding: 13px 15px;
  border: 1.5px solid #6ee7b7;
  border-radius: 18px;
  background: linear-gradient(135deg, #ffffff 0%, #f0fdf4 48%, #fff7ed 100%);
  color: #0f172a;
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: left;
  font-family: "Prompt", sans-serif;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  animation: wellness-glow-pulse 2.2s infinite ease-in-out;
  transition: transform .2s ease;
  box-sizing: border-box;
  outline: none;
}

.home-wellness-top-card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 60px;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.8), transparent);
  pointer-events: none;
  animation: wellness-shimmer-sweep 3s infinite ease-in-out;
}

.home-wellness-top-card:hover {
  transform: translateY(-2px);
}

.wellness-top-badge-row {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #dcfce7;
  border: 1px solid #a7f3d0;
  border-radius: 999px;
  padding: 3px 10px;
  width: fit-content;
}

.wellness-beacon-container {
  position: relative;
  width: 10px;
  height: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.wellness-blink-beacon {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  animation: wellness-blink-beacon 1s infinite ease-in-out;
}

.wellness-beacon-ripple {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 1.5px solid #10b981;
  animation: wellness-beacon-ripple 1.2s infinite cubic-bezier(0, 0.2, 0.8, 1);
}

.wellness-top-badge-text {
  font-size: 11px;
  font-weight: 800;
  color: #047857;
  letter-spacing: 0.2px;
}

.wellness-top-main-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.wellness-top-icon-box {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: linear-gradient(135deg, #0284c7 0%, #10b981 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 4px 14px rgba(2, 132, 199, 0.28);
  animation: icon-box-pulse 1.8s infinite ease-in-out;
}

.wellness-top-icon {
  font-size: 23px;
  animation: icon-wiggle 3s infinite ease-in-out;
  display: inline-block;
}

.wellness-top-text-box {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.wellness-top-title {
  font-size: 15px;
  font-weight: 900;
  line-height: 1.25;
  color: #0f172a;
}

.wellness-top-desc {
  font-size: 11px;
  color: #475569;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.wellness-top-cta-pill {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: linear-gradient(135deg, #ff6b00 0%, #ff8e3c 100%);
  border: none;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  color: #ffffff;
  white-space: nowrap;
  animation: cta-btn-blink 1.6s infinite ease-in-out;
  box-shadow: 0 4px 14px rgba(255, 107, 0, 0.42), 0 1px 3px rgba(0, 0, 0, 0.08);
  transition: transform .18s ease;
}

.wellness-top-arrow {
  transition: transform .2s ease;
  font-weight: 900;
}

.home-wellness-top-card:hover .wellness-top-arrow {
  transform: translateX(3px);
}

/* --- 2. Floating Blinking Pill Animations (Scrolls with user) --- */
@keyframes compact-pill-glow {
  0%, 100% {
    box-shadow: 0 3px 12px rgba(255, 107, 0, 0.45), 0 0 0 0 rgba(255, 107, 0, 0.4);
    transform: translateY(0);
  }
  50% {
    box-shadow: 0 6px 18px rgba(255, 107, 0, 0.7), 0 0 0 4px rgba(255, 107, 0, 0);
    transform: translateY(-1px);
  }
}

@keyframes compact-beacon-blink {
  0%, 100% {
    opacity: 1;
    transform: scale(1.15);
    box-shadow: 0 0 6px #22c55e, 0 0 12px #22c55e;
  }
  50% {
    opacity: 0.25;
    transform: scale(0.75);
    box-shadow: none;
  }
}

@keyframes compact-icon-bounce {
  0%, 100% { transform: scale(1) rotate(0deg); }
  15% { transform: scale(1.2) rotate(-12deg); }
  30% { transform: scale(1.2) rotate(12deg); }
  45% { transform: scale(1.1) rotate(0deg); }
}

@keyframes compact-ring-pulse {
  0% {
    transform: scale(0.96);
    opacity: 0.85;
  }
  100% {
    transform: scale(1.35);
    opacity: 0;
  }
}

.home-wellness-floating-pill {
  position: absolute;
  bottom: 72px;
  right: 12px;
  z-index: 10005;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 11px;
  height: 29px;
  background: linear-gradient(135deg, #ff6b00 0%, #ff8e3c 100%);
  border: 1.5px solid #ffffff;
  border-radius: 999px;
  color: #ffffff;
  font-family: "Prompt", sans-serif;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0.2px;
  cursor: pointer;
  animation: compact-pill-glow 2s infinite ease-in-out;
  transition: transform .15s ease, filter .15s ease, bottom .25s ease;
  white-space: nowrap;
  outline: none;
  -webkit-tap-highlight-color: transparent;
  box-sizing: border-box;
  box-shadow: 0 4px 14px rgba(255, 107, 0, 0.45);
}

body:has(#pwaInstallBanner[style*="display: block"]) .home-wellness-floating-pill,
body:has(#pwaInstallBanner[style*="display:block"]) .home-wellness-floating-pill {
  bottom: 160px;
}

.home-wellness-floating-pill:hover {
  transform: scale(1.06);
  filter: brightness(1.1);
}

.home-wellness-floating-pill:active {
  transform: scale(0.96);
}

.pill-pulse-ring {
  position: absolute;
  inset: -2px;
  border-radius: 999px;
  border: 1.5px solid rgba(249, 115, 22, 0.7);
  pointer-events: none;
  animation: compact-ring-pulse 2s infinite cubic-bezier(0.25, 1, 0.5, 1);
}

.pill-beacon-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #22c55e;
  animation: compact-beacon-blink 1.1s infinite ease-in-out;
  flex-shrink: 0;
}

.pill-icon {
  font-size: 11px;
  animation: compact-icon-bounce 3s infinite ease-in-out;
  display: inline-block;
  line-height: 1;
}

.pill-text {
  font-size: 11px;
  font-weight: 800;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
  line-height: 1;
}

@media (max-width: 480px) {
  .wellness-top-title { font-size: 14px; }
  .wellness-top-desc { font-size: 10px; }
  .wellness-top-cta-pill { padding: 6px 12px; font-size: 11px; }
}


