/* ==========================================================================
   MyFeed Modern Design System & Theme Styles
   Color Palette: Deep Blue (#0F2C61) & Accent Orange (#FF7A00)
   Typography: Plus Jakarta Sans (Compact, Crisp, Modern)
   ========================================================================== */

:root {
  --myfeed-blue-900: #0F2C61; /* Primary - Biru Tua Utama */
  --myfeed-blue-800: #153878; 
  --myfeed-blue-700: #1E4A8A; /* Hover & Mid Blue */
  --myfeed-blue-100: #EBF2FA; /* Background soft biru */
  --myfeed-blue-50:  #F4F8FC; 
  --myfeed-orange-500: #FF7A00; /* Accent - Oranye Utama */
  --myfeed-orange-600: #E66E00; /* Hover Oranye */
  --myfeed-orange-100: #FFF3E8; /* Background soft oranye */
  --myfeed-bg: #F8FAFD;       /* Background Halaman */
  --myfeed-card-bg: #FFFFFF;
  --myfeed-border: #E5EAF2;   /* Modern crisp border */
  --myfeed-text: #1E293B;     /* Teks Utama (Slate 800) */
  --myfeed-text-muted: #64748B; /* Teks Sekunder (Slate 500) */
}

/* Base Body & Typography */
body {
  background-color: var(--myfeed-bg);
  color: var(--myfeed-text);
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 0.875rem; /* 14px modern base */
  line-height: 1.5;
  letter-spacing: -0.011em;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

main {
  flex: 1 0 auto;
}

footer {
  flex-shrink: 0;
  background-color: var(--myfeed-blue-900);
  color: #fff;
  font-size: 0.8125rem;
}

/* Headings Typography Scale */
h1, .h1 {
  font-size: 1.65rem;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.025em;
  color: var(--myfeed-blue-900);
}

h2, .h2 {
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -0.02em;
  color: var(--myfeed-blue-900);
}

h3, .h3 {
  font-size: 1.15rem;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: -0.015em;
  color: var(--myfeed-blue-900);
}

h4, .h4 {
  font-size: 1.0rem;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: -0.01em;
  color: var(--myfeed-blue-900);
}

h5, .h5 {
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.45;
  color: var(--myfeed-blue-900);
}

h6, .h6 {
  font-size: 0.8125rem;
  font-weight: 600;
  line-height: 1.45;
  color: var(--myfeed-text-muted);
}

small, .small {
  font-size: 0.775rem;
  letter-spacing: -0.005em;
}

/* Backgrounds & Text Colors */
.bg-primary-myfeed { background-color: var(--myfeed-blue-900) !important; color: #fff !important; }
.bg-primary-light { background-color: var(--myfeed-blue-100) !important; }
.bg-accent-soft { background-color: var(--myfeed-orange-100) !important; }
.text-primary-myfeed { color: var(--myfeed-blue-900) !important; }
.text-accent-myfeed { color: var(--myfeed-orange-500) !important; }
.text-muted { color: var(--myfeed-text-muted) !important; }

/* Navbar */
.navbar-myfeed {
  background-color: var(--myfeed-blue-900);
  box-shadow: 0 1px 3px rgba(15, 44, 97, 0.12), 0 4px 12px rgba(15, 44, 97, 0.08);
  padding-top: 0.45rem;
  padding-bottom: 0.45rem;
}

.navbar-myfeed .navbar-brand {
  display: flex;
  align-items: center;
  margin-right: 1.5rem;
}

.myfeed-navbar-logo {
  height: 34px;
  width: 34px;
  object-fit: contain;
  transition: transform 0.2s ease;
  display: block;
}

.myfeed-navbar-logo:hover {
  transform: scale(1.06);
}

.navbar-myfeed .nav-link {
  color: rgba(255, 255, 255, 0.85) !important;
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  padding: 0.4rem 0.75rem !important;
  border-radius: 6px;
  transition: all 0.15s ease-in-out;
}

.navbar-myfeed .nav-link:hover,
.navbar-myfeed .nav-link.active {
  color: #fff !important;
  background-color: rgba(255, 255, 255, 0.12);
}

.navbar-myfeed .badge {
  font-size: 0.7rem;
  font-weight: 600;
}

/* Modern Compact Buttons */
.btn {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  padding: 0.42rem 0.95rem;
  border-radius: 7px;
  transition: all 0.15s ease-in-out;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

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

.btn-sm {
  font-size: 0.75rem;
  padding: 0.3rem 0.7rem;
  border-radius: 5px;
}

.btn-lg {
  font-size: 0.875rem;
  padding: 0.55rem 1.25rem;
  border-radius: 8px;
}

.btn-primary {
  background-color: var(--myfeed-blue-900);
  border-color: var(--myfeed-blue-900);
  color: #fff;
}

.btn-primary:hover, .btn-primary:focus {
  background-color: var(--myfeed-blue-700);
  border-color: var(--myfeed-blue-700);
  color: #fff;
}

.btn-accent {
  background-color: var(--myfeed-orange-500);
  border-color: var(--myfeed-orange-500);
  color: #fff;
}

.btn-accent:hover, .btn-accent:focus {
  background-color: var(--myfeed-orange-600);
  border-color: var(--myfeed-orange-600);
  color: #fff;
}

.btn-outline-primary {
  color: var(--myfeed-blue-900);
  border-color: var(--myfeed-blue-900);
  background-color: transparent;
}

.btn-outline-primary:hover {
  background-color: var(--myfeed-blue-900);
  color: #fff;
}

.btn-outline-accent {
  color: var(--myfeed-orange-500);
  border-color: var(--myfeed-orange-500);
  background-color: transparent;
}

.btn-outline-accent:hover {
  background-color: var(--myfeed-orange-500);
  color: #fff;
}

.btn-outline-light:hover {
  background-color: rgba(255, 255, 255, 0.15);
  color: #fff;
  border-color: #fff;
}

/* Badges */
.badge {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.28rem 0.55rem;
  border-radius: 5px;
  letter-spacing: -0.005em;
}

.badge-pill {
  border-radius: 12px;
  padding-left: 0.65rem;
  padding-right: 0.65rem;
}

.badge-plan-trial { background-color: var(--myfeed-blue-100); color: var(--myfeed-blue-900); }
.badge-plan-basic { background-color: #E2E8F0; color: #334155; }
.badge-plan-premium { background-color: var(--myfeed-orange-100); color: var(--myfeed-orange-600); border: 1px solid rgba(255, 122, 0, 0.25); }

.badge-status-active { background-color: #DEF7EC; color: #03543F; font-weight: 600; }
.badge-status-inactive { background-color: #F1F5F9; color: #475569; font-weight: 600; }
.badge-status-archived { background-color: #FDE8E8; color: #9B1C1C; font-weight: 600; }

/* Cards */
.card-myfeed {
  background: var(--myfeed-card-bg);
  border: 1px solid var(--myfeed-border);
  border-radius: 10px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04), 0 2px 8px rgba(15, 23, 42, 0.02);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.card-myfeed:hover {
  box-shadow: 0 6px 18px rgba(15, 44, 97, 0.08);
  border-color: #CBD5E1;
  transform: translateY(-2px);
}

.card-product {
  overflow: hidden;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.card-product .product-img-wrapper {
  position: relative;
  height: 175px;
  background-color: #F1F5F9;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.card-product img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.25s ease;
}

.card-product:hover img {
  transform: scale(1.04);
}

/* Product Discount Gimmick & Best Price Guarantee */
.product-discount-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  background-color: #fee8e8;
  color: #ee4d2d;
  border: 1px solid #fca5a5;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 3px;
  line-height: 1.2;
  z-index: 2;
  box-shadow: 0 1px 3px rgba(238, 77, 45, 0.15);
}

.badge-garansi-harga {
  display: inline-flex;
  align-items: center;
  border: 1px solid #ee4d2d;
  color: #ee4d2d;
  background-color: #fff;
  font-size: 0.68rem;
  font-weight: 600;
  padding: 1px 5px;
  border-radius: 2px;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

.text-price-red {
  color: #ee4d2d !important;
  font-weight: 700;
}

.price-original-strikethrough {
  color: #94a3b8;
  text-decoration: line-through;
  font-size: 0.75rem;
  font-weight: 500;
}

/* Hero Carousel (Modern & Compact) */
.hero-slider-wrapper {
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(15, 44, 97, 0.1);
}

.hero-slider-item {
  height: 380px;
  position: relative;
  background-size: cover;
  background-position: center;
}

.hero-slider-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, rgba(15, 44, 97, 0.92) 0%, rgba(15, 44, 97, 0.72) 55%, rgba(15, 44, 97, 0.25) 100%);
  display: flex;
  align-items: center;
  padding: 2rem 3rem;
}

.hero-slider-content {
  max-width: 580px;
  color: #fff;
}

.hero-slider-content h1 {
  font-size: 1.65rem;
  font-weight: 700;
  line-height: 1.28;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
  color: #fff;
}

.hero-slider-content p {
  font-size: 0.875rem;
  line-height: 1.5;
  opacity: 0.92;
  margin-bottom: 1.25rem;
  color: rgba(255, 255, 255, 0.9);
}

/* Modern Carousel Indicators */
.carousel-indicators li {
  width: 22px;
  height: 4px;
  border-radius: 2px;
  margin-right: 5px;
  margin-left: 5px;
  background-color: rgba(255, 255, 255, 0.4);
  border: none;
  transition: all 0.25s ease;
}

.carousel-indicators li.active {
  width: 34px;
  background-color: var(--myfeed-orange-500);
}

/* Compact Glassmorphism Carousel Nav Controls */
.carousel-control-prev,
.carousel-control-next {
  width: 44px;
  height: 44px;
  top: 50%;
  transform: translateY(-50%);
  border-radius: 50%;
  background: rgba(15, 44, 97, 0.35);
  backdrop-filter: blur(4px);
  margin: 0 1rem;
  opacity: 0.7;
  transition: all 0.2s ease;
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
  background: rgba(15, 44, 97, 0.75);
  opacity: 1;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
  width: 16px;
  height: 16px;
}

@media (max-width: 768px) {
  .hero-slider-item { height: 320px; }
  .hero-slider-overlay { padding: 1.25rem; }
  .hero-slider-content h1 { font-size: 1.35rem; }
  .hero-slider-content p { font-size: 0.8rem; }
}

/* Pricing Cards */
.pricing-card {
  border: 1px solid var(--myfeed-border);
  border-radius: 12px;
  transition: all 0.2s ease;
  position: relative;
  background: #fff;
}

.pricing-card.recommended {
  border: 2px solid var(--myfeed-orange-500);
  box-shadow: 0 6px 20px rgba(255, 122, 0, 0.12);
}

.pricing-ribbon {
  position: absolute;
  top: -10px;
  right: 16px;
  background-color: var(--myfeed-orange-500);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 10px;
  border-radius: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Calculator Table & Nutrient Grid */
.nutrient-badge-card {
  background-color: #fff;
  border: 1px solid var(--myfeed-border);
  border-radius: 8px;
  padding: 8px 10px;
  text-align: center;
  box-shadow: 0 1px 2px rgba(0,0,0,0.03);
}

.nutrient-badge-card .nutrient-value {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--myfeed-blue-900);
}

.nutrient-badge-card .nutrient-label {
  font-size: 0.72rem;
  color: var(--myfeed-text-muted);
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.02em;
}

/* Admin Layout & Sidebar */
.admin-wrapper {
  display: flex;
  min-height: calc(100vh - 52px);
}

.admin-sidebar {
  width: 230px;
  background-color: var(--myfeed-blue-900);
  color: #fff;
  flex-shrink: 0;
  padding: 1.25rem 0;
}

.admin-sidebar .sidebar-heading {
  padding: 0.45rem 1.25rem;
  font-size: 0.68rem;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
  font-weight: 700;
  letter-spacing: 0.05em;
}

.admin-sidebar .nav-link {
  color: rgba(255, 255, 255, 0.8);
  padding: 0.55rem 1.25rem;
  display: flex;
  align-items: center;
  font-size: 0.8125rem;
  font-weight: 500;
  transition: all 0.15s ease;
}

.admin-sidebar .nav-link:hover,
.admin-sidebar .nav-link.active {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.08);
  border-left: 3px solid var(--myfeed-orange-500);
}

.admin-content {
  flex: 1;
  padding: 1.75rem;
  background-color: #F8FAFD;
}

/* Forms & Tables */
.form-control, .custom-select {
  font-size: 0.8125rem;
  border-radius: 6px;
  border-color: var(--myfeed-border);
  padding: 0.42rem 0.75rem;
  height: calc(1.5em + 0.84rem + 2px);
}

.form-control:focus, .custom-select:focus {
  border-color: var(--myfeed-blue-700);
  box-shadow: 0 0 0 0.18rem rgba(15, 44, 97, 0.15);
}

.table-myfeed {
  font-size: 0.8125rem;
}

.table-myfeed th {
  background-color: var(--myfeed-blue-900);
  color: #fff;
  font-weight: 600;
  font-size: 0.775rem;
  letter-spacing: 0.01em;
  border-top: none;
  padding: 0.65rem 0.75rem;
}

.table-myfeed td {
  padding: 0.65rem 0.75rem;
  vertical-align: middle;
}

/* ==========================================================================
   3-Step Calculator Wizard & POS Design System
   ========================================================================== */

/* Step Progress Indicator */
.wizard-steps-nav {
  display: flex;
  justify-content: space-between;
  position: relative;
  margin-bottom: 2rem;
}

.wizard-steps-nav::before {
  content: '';
  position: absolute;
  top: 24px;
  left: 10%;
  right: 10%;
  height: 3px;
  background-color: var(--myfeed-border);
  z-index: 1;
}

.wizard-step-item {
  position: relative;
  z-index: 2;
  text-align: center;
  flex: 1;
  cursor: pointer;
}

.wizard-step-circle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background-color: #fff;
  border: 3px solid var(--myfeed-border);
  color: var(--myfeed-text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 0.5rem auto;
  font-weight: 700;
  font-size: 1rem;
  transition: all 0.25s ease;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.wizard-step-item.active .wizard-step-circle {
  background-color: var(--myfeed-blue-900);
  border-color: var(--myfeed-orange-500);
  color: #fff;
  box-shadow: 0 4px 12px rgba(15, 44, 97, 0.25);
  transform: scale(1.08);
}

.wizard-step-item.completed .wizard-step-circle {
  background-color: #10B981;
  border-color: #10B981;
  color: #fff;
}

.wizard-step-title {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--myfeed-text-muted);
  margin-bottom: 0.15rem;
}

.wizard-step-item.active .wizard-step-title {
  color: var(--myfeed-blue-900);
  font-weight: 700;
}

.wizard-step-desc {
  font-size: 0.725rem;
  color: var(--myfeed-text-muted);
}

/* Step 1: Animal Widget Grid */
.animal-widget-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1.25rem;
}

.animal-widget-card {
  background: #fff;
  border: 2px solid var(--myfeed-border);
  border-radius: 12px;
  padding: 1rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.animal-widget-card:hover {
  transform: translateY(-4px);
  border-color: var(--myfeed-blue-700);
  box-shadow: 0 8px 20px rgba(15, 44, 97, 0.12);
}

.animal-widget-card.selected {
  border-color: var(--myfeed-orange-500);
  background-color: var(--myfeed-blue-50);
  box-shadow: 0 6px 18px rgba(255, 122, 0, 0.2);
}

.animal-widget-card.selected::after {
  content: '✓';
  position: absolute;
  top: 10px;
  right: 10px;
  width: 24px;
  height: 24px;
  background-color: var(--myfeed-orange-500);
  color: #fff;
  border-radius: 50%;
  font-size: 0.75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.animal-widget-img {
  width: 90px;
  height: 90px;
  object-fit: cover;
  border-radius: 50%;
  margin: 0 auto 0.75rem auto;
  border: 3px solid #fff;
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
  display: block;
}

.animal-widget-name {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--myfeed-blue-900);
  margin-bottom: 0.25rem;
}

.animal-widget-badge {
  font-size: 0.725rem;
  padding: 0.2rem 0.6rem;
  border-radius: 20px;
  background-color: var(--myfeed-blue-100);
  color: var(--myfeed-blue-900);
  font-weight: 600;
}

/* Step 2: POS Interface */
.pos-component-card {
  background: #fff;
  border: 1px solid var(--myfeed-border);
  border-radius: 8px;
  padding: 0.75rem 0.9rem;
  cursor: pointer;
  transition: all 0.15s ease;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.6rem;
}

.pos-component-card:hover {
  background-color: var(--myfeed-blue-50);
  border-color: var(--myfeed-blue-700);
  transform: translateX(3px);
}

.pos-component-card.in-cart {
  border-color: var(--myfeed-orange-500);
  background-color: var(--myfeed-orange-100);
}

.pos-cart-panel {
  background: #fff;
  border: 2px solid var(--myfeed-blue-900);
  border-radius: 12px;
  padding: 1.25rem;
  box-shadow: 0 4px 16px rgba(15, 44, 97, 0.08);
}

.pos-qty-control {
  display: flex;
  align-items: center;
  background: #F1F5F9;
  border-radius: 6px;
  padding: 2px;
}

.pos-qty-btn {
  width: 28px;
  height: 28px;
  border: none;
  background: #fff;
  border-radius: 4px;
  font-weight: 700;
  color: var(--myfeed-blue-900);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  transition: background-color 0.1s;
}

.pos-qty-btn:hover {
  background-color: var(--myfeed-orange-500);
  color: #fff;
}

.pos-qty-input {
  width: 46px;
  text-align: center;
  border: none;
  background: transparent;
  font-weight: 700;
  font-size: 0.875rem;
  color: var(--myfeed-blue-900);
}

.pos-qty-input:focus {
  outline: none;
}

/* Step 3: Result & Validation Badges */
.badge-status-valid {
  background-color: #DEF7EC;
  color: #03543F;
  border: 1px solid #BCF0DA;
  padding: 0.35rem 0.65rem;
  border-radius: 6px;
  font-weight: 700;
  font-size: 0.75rem;
}

.badge-status-warning {
  background-color: #FDE8E8;
  color: #9B1C1C;
  border: 1px solid #FBD5D5;
  padding: 0.35rem 0.65rem;
  border-radius: 6px;
  font-weight: 700;
  font-size: 0.75rem;
}

.kpi-stat-card {
  background: #fff;
  border: 1px solid var(--myfeed-border);
  border-radius: 10px;
  padding: 1rem;
  text-align: center;
  border-top: 4px solid var(--myfeed-blue-900);
}

.kpi-stat-card.accent {
  border-top-color: var(--myfeed-orange-500);
}

.kpi-stat-value {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--myfeed-blue-900);
  line-height: 1.2;
}

.kpi-stat-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--myfeed-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-top: 0.25rem;
}

/* Lock Status Screen */
.calc-locked-screen {
  background: #fff;
  border: 2px dashed #EF4444;
  border-radius: 14px;
  padding: 3rem 2rem;
  text-align: center;
  margin: 2rem 0;
}

.calc-locked-icon {
  width: 72px;
  height: 72px;
  background-color: #FEE2E2;
  color: #EF4444;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin: 0 auto 1.25rem auto;
}

/* ==========================================================================
   NOTIFICATION SYSTEM & CHAT TIMELINE STYLES
   ========================================================================== */

/* Notification Timeline Cards */
.notif-card {
  transition: all 0.2s ease-in-out;
  border-radius: 12px;
}

.notif-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(15, 34, 64, 0.08) !important;
}

.border-left-unread {
  border-left: 5px solid var(--myfeed-orange-500) !important;
}

.border-left-read {
  border-left: 5px solid #E2E8F0 !important;
}

.bg-unread-soft {
  background-color: #F8FAFC !important;
}

.notif-icon-box {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background-color: #EDF2F7;
  display: flex;
  align-items: center;
  justify-content: center;
}

.notif-message-text {
  font-size: 0.925rem;
  line-height: 1.6;
}

/* User Directory in Admin Console */
.user-inbox-list .user-item-link {
  transition: background 0.15s ease;
  border-left: 4px solid transparent;
}

.user-inbox-list .user-item-link:hover {
  background-color: #F8FAFC;
}

.user-inbox-list .active-user-item {
  background-color: #EFF6FF !important;
  border-left-color: var(--myfeed-blue-900) !important;
}

/* Chat Stream in Admin Console */
.chat-stream {
  scroll-behavior: smooth;
}

.chat-bubble-wrapper {
  display: flex;
  flex-direction: column;
}

.chat-from-admin .chat-bubble {
  background-color: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-left: 4px solid var(--myfeed-blue-900);
}

.chat-from-system .chat-bubble {
  background-color: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-left: 4px solid var(--myfeed-orange-500);
}

/* Navbar Bell Badge */
.notif-nav-badge {
  box-shadow: 0 0 0 2px var(--myfeed-blue-900);
  animation: pulse-badge 2s infinite;
}

@keyframes pulse-badge {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

.notif-dropdown-menu {
  border-radius: 12px;
  overflow: hidden;
}

.notif-dropdown-list .dropdown-item {
  white-space: normal !important;
  transition: background 0.15s ease;
}

.notif-dropdown-list .dropdown-item:hover {
  background-color: #F1F5F9;
}

/* ==========================================================================
   SignalR Interactive Chat & Conference Module Styles (MyFeed Modern Theme)
   ========================================================================== */
.chat-page-wrapper {
  margin-top: -0.25rem;
  padding-bottom: 0;
  height: calc(100vh - 80px);
  height: calc(100dvh - 76px);
  display: flex;
  flex-direction: column;
}

.chat-page-wrapper .container-fluid {
  flex: 1 1 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.chat-app-container {
  flex: 1 1 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  border-radius: 16px;
  border: 1px solid var(--myfeed-border);
  box-shadow: 0 10px 30px rgba(15, 44, 97, 0.08);
  overflow: hidden;
  background-color: #FFFFFF;
}

.chat-app-container > .row {
  height: 100%;
  min-height: 0;
  flex: 1 1 0px;
  flex-wrap: nowrap;
  overflow: hidden;
}

@media (max-width: 767.98px) {
  .chat-app-container {
    border-radius: 12px;
  }
  .chat-app-container > .row {
    flex-wrap: wrap;
  }
}

/* --- SIDEBAR --- */
.chat-sidebar {
  background-color: #F8FAFC;
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.chat-sidebar-header {
  flex-shrink: 0;
  background-color: #FFFFFF;
  border-bottom: 1px solid var(--myfeed-border);
}

.chat-user-profile-badge {
  background-color: var(--myfeed-blue-50);
  border: 1px solid #DBEAFE;
  padding: 0.45rem 0.75rem;
  border-radius: 10px;
}

.chat-search-box {
  background-color: #F1F5F9;
  border: 1px solid #E2E8F0;
  border-radius: 20px;
  transition: all 0.2s ease;
}

.chat-search-box:focus-within {
  background-color: #FFFFFF;
  border-color: var(--myfeed-blue-700);
  box-shadow: 0 0 0 3px rgba(15, 44, 97, 0.1);
}

.chat-search-box input {
  background: transparent;
  font-size: 0.82rem;
}

.chat-search-box input:focus {
  background: transparent;
}

.chat-filter-tabs {
  background-color: #F1F5F9;
  border-radius: 10px;
  padding: 3px;
  gap: 2px;
}

.chat-filter-tabs .nav-link {
  color: var(--myfeed-text-muted);
  font-size: 0.76rem;
  font-weight: 600;
  border-radius: 8px;
  padding: 0.35rem 0.5rem;
  transition: all 0.2s ease;
  border: none;
}

.chat-filter-tabs .nav-link:hover {
  color: var(--myfeed-blue-900);
}

.chat-filter-tabs .nav-link.active {
  background-color: var(--myfeed-blue-900);
  color: #FFFFFF !important;
  box-shadow: 0 2px 6px rgba(15, 44, 97, 0.2);
}

.chat-room-list {
  flex: 1 1 0px;
  min-height: 0;
  scrollbar-width: thin;
  scrollbar-color: #CBD5E1 transparent;
  overflow-y: auto;
}

.chat-room-list::-webkit-scrollbar {
  width: 5px;
}

.chat-room-list::-webkit-scrollbar-thumb {
  background-color: #CBD5E1;
  border-radius: 4px;
}

/* Room Items */
.room-item {
  transition: all 0.18s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid transparent;
  border-left: 3px solid transparent;
  border-radius: 10px;
  margin-bottom: 4px;
  background-color: #FFFFFF;
  cursor: pointer;
}

.room-item:hover {
  background-color: #F1F5F9;
  border-color: #E2E8F0;
  transform: translateX(2px);
}

.room-item.active {
  background-color: #EBF4FF;
  border-color: #BFDBFE;
  border-left: 3px solid var(--myfeed-blue-900);
  box-shadow: 0 2px 8px rgba(15, 44, 97, 0.06);
}

.chat-avatar-sm {
  width: 34px;
  height: 34px;
  font-size: 0.85rem;
  flex-shrink: 0;
  border-radius: 50%;
}

.chat-avatar-md {
  width: 44px;
  height: 44px;
  font-size: 1.1rem;
  flex-shrink: 0;
  border-radius: 50%;
}

.avatar-conference {
  background: linear-gradient(135deg, #1E4A8A 0%, #0F2C61 100%);
  color: #FFFFFF;
  box-shadow: 0 2px 6px rgba(15, 44, 97, 0.25);
}

.avatar-admin {
  background: linear-gradient(135deg, #EF4444 0%, #DC2626 100%);
  color: #FFFFFF;
  box-shadow: 0 2px 6px rgba(220, 38, 38, 0.25);
}

.avatar-user {
  background: linear-gradient(135deg, #0D9488 0%, #059669 100%);
  color: #FFFFFF;
  box-shadow: 0 2px 6px rgba(13, 148, 136, 0.25);
}

.room-item .unread-badge {
  background: linear-gradient(135deg, #FF7A00 0%, #EA580C 100%);
  color: #FFFFFF;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(255, 122, 0, 0.35);
}

/* --- MAIN CHAT PANEL --- */
.chat-main {
  background-color: #FFFFFF;
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
}

#activeChatView {
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
}

.chat-header {
  flex-shrink: 0;
  background-color: #FFFFFF;
  border-bottom: 1px solid var(--myfeed-border);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

#roomTopicBanner {
  flex-shrink: 0;
}

.chat-messages {
  flex: 1 1 0px;
  min-height: 0;
  overflow-y: auto !important;
  overflow-x: hidden;
  background-color: #F8FAFD;
  background-image: radial-gradient(#E2E8F0 0.75px, transparent 0.75px);
  background-size: 16px 16px;
  scrollbar-width: thin;
  scrollbar-color: #CBD5E1 transparent;
  position: relative;
  /* Ensure padding at bottom so last message is fully visible */
  padding-bottom: 1rem !important;
}

.chat-messages::-webkit-scrollbar {
  width: 6px;
}

.chat-messages::-webkit-scrollbar-thumb {
  background-color: #CBD5E1;
  border-radius: 4px;
}

/* Message Bubbles */
.chat-message-row {
  animation: fadeInMsg 0.25s ease-out;
}

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

.chat-bubble-mine {
  background: linear-gradient(135deg, #0F2C61 0%, #1E4A8A 100%);
  color: #FFFFFF;
  border-radius: 16px 16px 3px 16px !important;
  box-shadow: 0 3px 12px rgba(15, 44, 97, 0.18);
}

.chat-bubble-mine .chat-bubble-text {
  color: #FFFFFF;
  font-size: 0.9rem;
  line-height: 1.5;
}

.chat-bubble-mine .chat-bubble-meta {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.7rem;
}

.chat-bubble-other {
  background-color: #FFFFFF;
  color: #1E293B;
  border: 1px solid #E2E8F0;
  border-radius: 16px 16px 16px 3px !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.chat-bubble-other .chat-bubble-text {
  color: #334155;
  font-size: 0.9rem;
  line-height: 1.5;
}

.chat-bubble-other .chat-bubble-meta {
  color: #94A3B8;
  font-size: 0.7rem;
}

/* Date Dividers */
.chat-date-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 1.25rem 0;
  position: relative;
}

.chat-date-divider::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
  background-color: #E2E8F0;
  z-index: 1;
}

.chat-date-pill {
  position: relative;
  z-index: 2;
  background-color: #F1F5F9;
  color: #64748B;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.25rem 0.85rem;
  border-radius: 14px;
  border: 1px solid #E2E8F0;
  letter-spacing: 0.02em;
}

/* System Message */
.chat-system-pill {
  background-color: #F8FAFC;
  color: #64748B;
  border: 1px solid #E2E8F0;
  border-radius: 20px;
  font-size: 0.75rem;
  padding: 0.35rem 1rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

/* Quick Suggestion Chips */
.chat-suggestion-chips {
  flex-shrink: 0;
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 0.4rem 0.85rem;
  scrollbar-width: none;
  background-color: #FFFFFF;
  border-top: 1px solid #F1F5F9;
}

.chat-suggestion-chips::-webkit-scrollbar {
  display: none;
}

.suggestion-chip {
  background-color: #F8FAFC;
  color: #475569;
  border: 1px solid #E2E8F0;
  border-radius: 16px;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.15s ease;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}

.suggestion-chip:hover {
  background-color: #EBF4FF;
  border-color: #BFDBFE;
  color: var(--myfeed-blue-900);
  transform: translateY(-1px);
}

/* Input Area */
.chat-input-area {
  flex-shrink: 0;
  background-color: #FFFFFF;
  border-top: 1px solid var(--myfeed-border);
  position: relative;
  z-index: 10;
  box-shadow: 0 -2px 10px rgba(15, 44, 97, 0.04);
}

.chat-input-field {
  border-radius: 20px !important;
  border: 1px solid #CBD5E1;
  padding: 0.55rem 1.15rem;
  font-size: 0.88rem;
  line-height: 1.45;
  min-height: 42px;
  max-height: 120px;
  resize: none;
  overflow-y: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  scrollbar-width: thin;
  scrollbar-color: #CBD5E1 transparent;
}

.chat-input-field::-webkit-scrollbar {
  width: 5px;
}

.chat-input-field::-webkit-scrollbar-thumb {
  background-color: #CBD5E1;
  border-radius: 4px;
}

.chat-input-field:focus {
  border-color: var(--myfeed-blue-700);
  box-shadow: 0 0 0 3px rgba(15, 44, 97, 0.12);
  outline: none;
}

.btn-chat-send {
  width: 42px;
  height: 42px;
  min-width: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--myfeed-blue-900) 0%, var(--myfeed-blue-700) 100%);
  color: #FFFFFF;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 3px 10px rgba(15, 44, 97, 0.25);
  transition: all 0.18s ease;
  margin-bottom: 0;
}

.btn-chat-send:hover {
  background: linear-gradient(135deg, var(--myfeed-orange-500) 0%, var(--myfeed-orange-600) 100%);
  color: #FFFFFF;
  transform: scale(1.05);
  box-shadow: 0 4px 14px rgba(255, 122, 0, 0.35);
}

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

/* Scroll to Bottom Floating Button */
.btn-scroll-bottom {
  position: absolute;
  bottom: 125px;
  right: 22px;
  z-index: 20;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background-color: #FFFFFF;
  border: 1px solid #CBD5E1;
  color: var(--myfeed-blue-900);
  box-shadow: 0 4px 14px rgba(15, 44, 97, 0.16);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  cursor: pointer;
}

.btn-scroll-bottom:hover {
  background-color: var(--myfeed-blue-900);
  color: #FFFFFF;
  border-color: var(--myfeed-blue-900);
  transform: translateY(-2px);
}

/* Empty State Styling */
.chat-empty-hero {
  max-width: 520px;
}

.chat-feature-card {
  background-color: #FFFFFF;
  border: 1px solid var(--myfeed-border);
  border-radius: 12px;
  padding: 0.85rem;
  transition: all 0.2s ease;
  text-align: left;
}

.chat-feature-card:hover {
  border-color: #BFDBFE;
  box-shadow: 0 4px 12px rgba(15, 44, 97, 0.06);
  transform: translateY(-2px);
}

/* Live Pulse Indicator */
.pulse-indicator {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  animation: pulse-ring 1.8s infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(0.9); opacity: 1; }
  50% { transform: scale(1.35); opacity: 0.5; }
  100% { transform: scale(0.9); opacity: 1; }
}

/* Typing animated dots */
.typing-dots span {
  display: inline-block;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background-color: var(--myfeed-blue-700);
  margin-right: 3px;
  animation: typing 1.4s infinite ease-in-out;
}

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

@keyframes typing {
  0%, 60%, 100% { transform: translateY(0); }
  30% { transform: translateY(-5px); }
}

.hover-bg-light:hover {
  background-color: #F8FAFC;
}

.cursor-pointer {
  cursor: pointer;
}

/* Mobile Responsiveness */
@media (max-width: 767.98px) {
  .chat-app-container {
    height: calc(100vh - 100px);
    border-radius: 10px;
  }
  .mobile-view-hidden {
    display: none !important;
  }
}