/* ==========================================================================
   Yayasan Jarak Bali - Master Design System & Stylesheet (Vibrant & Compact Edition)
   Punchy Colors, Crisp Typography, Tight & Compact Layout Rhythm
   ========================================================================== */

:root {
  /* Vibrant Brand Colors */
  --primary: #059669;        /* Saturated Emerald Green */
  --primary-dark: #047857;   /* Rich Deep Emerald */
  --primary-darker: #064e3b;
  --primary-light: #d1fae5;  /* Vibrant Mint Tint */
  --primary-glow: rgba(5, 150, 105, 0.35);
  
  --secondary: #2563eb;      /* Vivid Royal Blue */
  --secondary-dark: #1d4ed8;
  --secondary-light: #dbeafe;
  
  --accent: #f59e0b;         /* Amber Accent */
  --accent-light: #fef3c7;
  
  /* High-Contrast Neutral Palette */
  --bg-color: #f8fafc;       /* Crisp light slate */
  --card-bg: #ffffff;
  --text-main: #0f172a;      /* Deep Slate 900 for punchy headers */
  --text-body: #1e293b;      /* Slate 800 - crisp, strong contrast */
  --text-muted: #64748b;     /* Slate 500 */
  --border-color: #e2e8f0;
  --border-card: rgba(226, 232, 240, 0.95);

  /* Vivid Glassmorphism */
  --glass-bg: rgba(255, 255, 255, 0.92);
  --glass-border: rgba(255, 255, 255, 0.85);
  
  /* Modern Clean Fonts */
  --font-heading: 'Outfit', 'Plus Jakarta Sans', system-ui, sans-serif;
  --font-body: 'Plus Jakarta Sans', 'Inter', system-ui, sans-serif;

  /* Shadows */
  --shadow-sm: 0 4px 14px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 10px 25px rgba(0, 0, 0, 0.09);
  --shadow-lg: 0 16px 36px rgba(5, 150, 105, 0.2);
  --shadow-hover: 0 14px 28px rgba(5, 150, 105, 0.18), 0 6px 12px rgba(0, 0, 0, 0.06);

  /* Transitions */
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Base Setup */
*, *::before, *::after {
  box-sizing: border-box;
}

body {
  font-family: var(--font-body);
  color: var(--text-body);
  background-color: var(--bg-color);
  overflow-x: hidden;
  padding-top: 74px;
  line-height: 1.6;
  font-size: 0.975rem;
  -webkit-font-smoothing: antialiased;
}

/* Headings: Tight & Bold */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
  font-family: var(--font-heading);
  color: var(--text-main);
  font-weight: 800;
  letter-spacing: -0.025em;
  margin-top: 0;
  line-height: 1.25;
}

h1, .h1 {
  font-size: clamp(2.2rem, 3.8vw, 3rem);
  font-weight: 800;
  line-height: 1.15;
}

h2, .h2 {
  font-size: clamp(1.65rem, 2.6vw, 2.2rem);
  font-weight: 800;
  line-height: 1.22;
}

h3, .h3 {
  font-size: 1.4rem;
  font-weight: 700;
  line-height: 1.3;
}

h4, .h4 {
  font-size: 1.15rem;
  font-weight: 700;
}

h5, .h5 {
  font-size: 1.025rem;
  font-weight: 700;
}

p {
  margin-bottom: 1rem;
  line-height: 1.62;
}

p:last-child {
  margin-bottom: 0;
}

.lead {
  font-size: 1.075rem;
  line-height: 1.65;
  color: #475569;
  font-weight: 400;
}

/* Badges: Rich Vibrant Accents */
.badge {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.825rem;
  letter-spacing: 0.02em;
  padding: 6px 14px;
  border-radius: 50px;
}

.badge.bg-primary.bg-opacity-10 {
  background-color: #ecfdf5 !important;
  color: #047857 !important;
  border: 1.5px solid #a7f3d0 !important;
  font-weight: 700;
}

/* ==========================================================================
   Navigation Bar (Vibrant Glass)
   ========================================================================== */
.navbar-custom {
  background: var(--glass-bg);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1.5px solid rgba(5, 150, 105, 0.12);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
  transition: var(--transition);
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1050;
  padding: 10px 0;
}

.navbar-brand {
  font-family: var(--font-heading);
  font-weight: 800;
  color: var(--primary) !important;
  font-size: 1.35rem;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  min-width: 0;
}

/* Base Logo Classes */
.site-logo {
  object-fit: contain;
  width: auto;
  height: auto;
  display: block;
}

/* Header Navbar Logo */
.nav-logo,
.nav-logo-icon {
  height: 42px;
  max-height: 42px;
  width: 42px;
  max-width: 42px;
  object-fit: contain;
  flex-shrink: 0;
}

.nav-logo-full {
  height: auto;
  max-height: 46px;
  width: auto;
  max-width: 240px;
  object-fit: contain;
  flex-shrink: 0;
}

.site-name-text {
  font-family: var(--font-heading);
  font-weight: 800;
  color: var(--primary);
  font-size: 1.25rem;
  letter-spacing: -0.01em;
  line-height: 1.2;
  white-space: nowrap;
}

/* Footer Logo */
.footer-logo-icon {
  height: 48px;
  max-height: 48px;
  width: 48px;
  max-width: 48px;
  object-fit: contain;
  flex-shrink: 0;
}

.footer-logo-full {
  height: auto;
  max-height: 60px;
  width: auto;
  max-width: 260px;
  object-fit: contain;
  flex-shrink: 0;
}

.footer-brand-text {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  letter-spacing: -0.01em;
  line-height: 1.2;
}

.nav-link {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-main) !important;
  margin: 0 6px;
  padding: 6px 12px !important;
  position: relative;
  transition: color 0.2s ease;
}

.nav-link:hover, .nav-item.active .nav-link {
  color: var(--primary) !important;
}

.nav-link::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2.5px;
  bottom: 0;
  left: 50%;
  background-color: var(--primary);
  transition: var(--transition);
  transform: translateX(-50%);
  border-radius: 4px;
}

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

/* ==========================================================================
   Navbar Donation Button
   ========================================================================== */
.btn-nav-donate {
  background: linear-gradient(135deg, #059669 0%, #047857 40%, #2563eb 100%);
  color: #ffffff !important;
  border: none;
  border-radius: 50px;
  padding: 8px 18px;
  font-size: 0.885rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(5, 150, 105, 0.35);
  transition: var(--transition);
  white-space: nowrap;
}

.btn-nav-donate i {
  font-size: 0.85rem;
  color: #ffffff;
  transition: transform 0.2s ease;
}

.btn-nav-donate:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(5, 150, 105, 0.48);
  color: #ffffff !important;
}

.btn-nav-donate:hover i {
  transform: scale(1.15);
}

.btn-nav-donate:active {
  transform: translateY(0);
}

/* ==========================================================================
   Vivid Gradient Buttons
   ========================================================================== */
.btn-custom {
  background: linear-gradient(135deg, #059669 0%, #047857 40%, #2563eb 100%);
  color: white !important;
  border: none;
  border-radius: 50px;
  padding: 9px 24px;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  transition: var(--transition);
  box-shadow: 0 4px 14px rgba(5, 150, 105, 0.35);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  cursor: pointer;
}

.btn-custom:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(5, 150, 105, 0.45);
  color: white !important;
}

.btn-outline-custom {
  border: 2px solid var(--primary);
  color: var(--primary) !important;
  background: #ffffff;
  border-radius: 50px;
  padding: 8px 22px;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  box-shadow: 0 2px 8px rgba(5, 150, 105, 0.1);
}

.btn-outline-custom:hover {
  background: var(--primary);
  color: white !important;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(5, 150, 105, 0.3);
}

/* ==========================================================================
   Cards & Glassmorphism (Vibrant & Crisp)
   ========================================================================== */
.glass-card {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: 20px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
  transition: var(--transition);
}

.glass-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

/* Compact Section Padding (Tighter Rhythm) */
section.py-5 {
  padding-top: 3.5rem !important;
  padding-bottom: 3.5rem !important;
}

/* ==========================================================================
   Hero Section (Vibrant Gradient Background)
   ========================================================================== */
.hero-section {
  position: relative;
  padding: 65px 0 50px;
  background: linear-gradient(135deg, #d1fae5 0%, #ecfdf5 40%, #ffffff 100%);
  overflow: hidden;
}

.hero-shape {
  position: absolute;
  top: -15%;
  right: -5%;
  width: 50%;
  height: 130%;
  background: linear-gradient(135deg, rgba(5, 150, 105, 0.12) 0%, rgba(37, 99, 235, 0.08) 100%);
  border-radius: 50px 0 0 50px;
  transform: rotate(-8deg);
  z-index: 0;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero-title {
  font-size: clamp(2.3rem, 4.2vw, 3.2rem);
  font-weight: 800;
  line-height: 1.16;
  letter-spacing: -0.03em;
  margin-top: 0.75rem;
  margin-bottom: 1rem;
  color: var(--text-main);
}

.hero-title span {
  color: var(--primary);
  text-shadow: 0 2px 10px rgba(5, 150, 105, 0.15);
}

.hero-subtitle {
  font-size: 1.1rem;
  color: #475569;
  line-height: 1.65;
  margin-bottom: 1.75rem;
  max-width: 540px;
}

.hero-image {
  border-radius: 20px;
  box-shadow: var(--shadow-lg);
  max-height: 380px;
  width: auto;
  transition: transform 0.4s ease;
}

.hero-image:hover {
  transform: scale(1.02);
}

/* ==========================================================================
   Page Header (Rich Color Saturation)
   ========================================================================== */
.page-header {
  background: linear-gradient(135deg, #047857 0%, #059669 50%, #2563eb 100%);
  padding: 55px 0 45px;
  color: white;
  text-align: center;
  border-radius: 0 0 32px 32px;
  margin-bottom: 35px;
  box-shadow: 0 10px 25px rgba(5, 150, 105, 0.22);
}

.page-title {
  font-weight: 800;
  font-size: clamp(2.2rem, 3.5vw, 2.8rem);
  margin-bottom: 8px;
  color: #ffffff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.page-header .lead {
  color: rgba(255, 255, 255, 0.95);
  font-size: 1.1rem;
  max-width: 650px;
  margin: 0 auto;
}

/* ==========================================================================
   Activity Cards
   ========================================================================== */
.activity-card {
  border: 1px solid var(--border-card);
  border-radius: 18px;
  overflow: hidden;
  transition: var(--transition);
  height: 100%;
  background: #ffffff;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
}

.activity-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(5, 150, 105, 0.35);
}

.activity-img {
  height: 210px;
  object-fit: cover;
  width: 100%;
  transition: transform 0.4s ease;
}

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

.activity-card .card-body {
  padding: 20px 22px 22px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.activity-card .card-title {
  font-weight: 700;
  font-size: 1.18rem;
  line-height: 1.35;
  margin-bottom: 8px;
  color: var(--text-main);
  transition: color 0.2s ease;
}

.activity-card:hover .card-title {
  color: var(--primary);
}

.activity-card .card-text {
  color: var(--text-muted);
  font-size: 0.925rem;
  line-height: 1.58;
  margin-bottom: 1rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ==========================================================================
   Campaign Cards
   ========================================================================== */
.campaign-card, .card-custom {
  border: 1px solid var(--border-card);
  border-radius: 18px;
  overflow: hidden;
  transition: var(--transition);
  height: 100%;
  background: #ffffff;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
}

.campaign-card:hover, .card-custom:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(5, 150, 105, 0.35);
}

.campaign-img, .card-custom .card-img-top {
  height: 210px;
  object-fit: cover;
  width: 100%;
  transition: transform 0.4s ease;
}

.campaign-card:hover .campaign-img,
.card-custom:hover .card-img-top {
  transform: scale(1.04);
}

.campaign-card .card-body, .card-custom .card-body {
  padding: 20px 22px;
}

.campaign-card .card-title, .card-custom .card-title {
  font-weight: 700;
  font-size: 1.18rem;
  line-height: 1.35;
  margin-bottom: 8px;
  color: var(--text-main);
}

.progress {
  background-color: #e2e8f0;
  border-radius: 10px;
  height: 8px;
  overflow: hidden;
}

.progress-bar {
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  transition: width 1s ease-in-out;
  border-radius: 10px;
}

/* ==========================================================================
   Call to Action (CTA) Section (Vibrant Accent)
   ========================================================================== */
.cta-section {
  background: linear-gradient(135deg, #059669 0%, #047857 50%, #2563eb 100%);
  color: white;
  border-radius: 24px;
  padding: 48px 32px;
  text-align: center;
  box-shadow: 0 16px 36px rgba(5, 150, 105, 0.28);
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: -40%;
  left: -10%;
  width: 280px;
  height: 280px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  pointer-events: none;
}

.cta-section h2 {
  color: white;
  font-size: clamp(1.8rem, 3.2vw, 2.3rem);
  font-weight: 800;
  margin-bottom: 10px;
}

.cta-section .lead {
  color: rgba(255, 255, 255, 0.95);
}

/* ==========================================================================
   Contact Cards
   ========================================================================== */
.contact-info-card {
  background: linear-gradient(135deg, #047857 0%, #059669 100%);
  color: white;
  border-radius: 20px;
  padding: 32px;
  height: 100%;
  box-shadow: 0 10px 25px rgba(5, 150, 105, 0.22);
}

.contact-form-card {
  background: white;
  border: 1px solid var(--border-card);
  border-radius: 20px;
  padding: 32px;
  height: 100%;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}

/* Preset Donation Buttons */
.preset-btn {
  background: #f1f5f9;
  border: 1.5px solid #cbd5e1;
  border-radius: 50px;
  padding: 6px 15px;
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--text-main);
  cursor: pointer;
  transition: var(--transition);
}

.preset-btn:hover, .preset-btn.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  box-shadow: 0 4px 10px rgba(5, 150, 105, 0.3);
  transform: translateY(-1px);
}

/* Payment Method Selectors */
.payment-method-item {
  transition: var(--transition);
  background: #ffffff;
  border: 1.5px solid #e2e8f0 !important;
  border-radius: 12px !important;
  padding: 12px 16px !important;
}

.payment-method-item:hover {
  border-color: var(--primary) !important;
  background: #ecfdf5;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(5, 150, 105, 0.12);
}

/* ==========================================================================
   FAQ Accordion Customization
   ========================================================================== */
.accordion-custom .accordion-item {
  background: #ffffff;
  border-bottom: 1px solid #e2e8f0 !important;
  transition: var(--transition);
}

.accordion-custom .accordion-item:last-child {
  border-bottom: none !important;
}

.accordion-custom .accordion-button {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--text-main);
  background: #ffffff;
  padding: 1.25rem 1.5rem;
  box-shadow: none !important;
  transition: var(--transition);
}

.accordion-custom .accordion-button:not(.collapsed) {
  color: var(--primary);
  background: #f0fdf4;
}

.accordion-custom .accordion-button::after {
  background-size: 1.1rem;
  transition: transform 0.25s ease;
}

.accordion-custom .accordion-body {
  background: #ffffff;
  color: var(--text-muted);
  line-height: 1.8;
  padding: 0.5rem 1.75rem 1.5rem 4rem;
}

@media (max-width: 767.98px) {
  .accordion-custom .accordion-body {
    padding-left: 1.5rem;
  }
}

/* ==========================================================================
   Footer (High Contrast Dark Slate)
   ========================================================================== */
footer {
  background: #0f172a;
  color: #94a3b8;
  padding: 55px 0 0;
  margin-top: 60px;
  position: relative;
}

footer::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(90deg, #059669, #2563eb);
}

footer h5 {
  color: #ffffff;
  margin-bottom: 1.2rem;
  font-family: var(--font-heading);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.9rem;
}

footer .footer-link {
  display: block;
  margin-bottom: 0.55rem;
  color: #94a3b8;
  text-decoration: none;
  font-size: 0.925rem;
  line-height: 1.7;
  transition: var(--transition);
}

footer .footer-link:hover {
  color: #34d399;
  padding-left: 5px;
}

.footer-info-item {
  display: flex;
  gap: 12px;
  margin-bottom: 0.9rem;
  font-size: 0.925rem;
}

.footer-info-item i {
  font-size: 1.15rem;
  color: #10b981;
  margin-top: 2px;
  flex-shrink: 0;
}

.social-icons a {
  display: inline-flex;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.1);
  align-items: center;
  justify-content: center;
  color: white;
  margin-right: 8px;
  transition: var(--transition);
  font-size: 1.1rem;
  text-decoration: none;
}

.social-icons a:hover {
  background: var(--primary);
  color: white;
  transform: translateY(-3px);
  box-shadow: 0 6px 14px rgba(5, 150, 105, 0.4);
}

.footer-bottom {
  background: #020617;
  padding: 18px 0;
  margin-top: 40px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.85rem;
}

/* Toast alert notification */
#toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 2000;
}

/* Responsive adjustments */
@media (max-width: 991.98px) {
  .hero-section {
    text-align: center;
    padding: 45px 0 35px;
  }
  .hero-subtitle {
    margin-left: auto;
    margin-right: auto;
  }
  .nav-logo-full {
    max-width: 195px;
    max-height: 40px;
  }
  .site-name-text {
    font-size: 1.15rem;
  }
}

@media (max-width: 767.98px) {
  .hero-title {
    font-size: 2.1rem;
  }
  .page-title {
    font-size: 2rem;
  }
  .nav-logo-icon {
    height: 36px;
    max-height: 36px;
    width: 36px;
    max-width: 36px;
  }
  .nav-logo-full {
    max-width: 170px;
    max-height: 38px;
  }
  .site-name-text {
    font-size: 1.05rem;
  }
  .footer-logo-full {
    max-width: 220px;
    max-height: 52px;
  }
  #mobileLangBtn {
    font-size: 0.8rem;
    padding: 4px 10px;
    line-height: 1.4;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
  }
}

@media (max-width: 390px) {
  .nav-logo-full {
    max-width: 145px;
    max-height: 34px;
  }
  .site-name-text {
    font-size: 0.92rem;
  }
  #mobileLangBtn {
    font-size: 0.74rem;
    padding: 3px 7px;
  }
}

/* ==========================================================================
   YAYASAN JARAK BALI — CHATBOT & AUTO WELCOME UI
   ========================================================================== */
.yjb-chatbot-container {
  position: relative;
  z-index: 1050;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Floating Action Button */
.yjb-chatbot-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, #059669 0%, #047857 100%);
  color: #ffffff;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.45rem;
  box-shadow: 0 8px 24px rgba(5, 150, 105, 0.38);
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  z-index: 1051;
}

.yjb-chatbot-btn:hover {
  transform: translateY(-3px) scale(1.04);
  box-shadow: 0 12px 28px rgba(5, 150, 105, 0.48);
  color: #ffffff;
}

.yjb-chatbot-btn:active {
  transform: translateY(-1px) scale(0.98);
}

.yjb-chatbot-btn:focus-visible {
  outline: 3px solid #a7f3d0;
  outline-offset: 3px;
}

.yjb-pulse-dot {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 12px;
  height: 12px;
  background-color: #22c55e;
  border: 2px solid #ffffff;
  border-radius: 50%;
  animation: yjbPulse 2s infinite;
}

@keyframes yjbPulse {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 8px rgba(34, 197, 94, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

/* Auto Welcome Greeting Bubble */
.yjb-chatbot-bubble {
  position: fixed;
  bottom: 92px;
  right: 24px;
  max-width: 320px;
  background: #ffffff;
  border: 1px solid rgba(5, 150, 105, 0.22);
  border-radius: 18px;
  padding: 14px 16px;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.12);
  z-index: 1050;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.yjb-bubble-icon {
  width: 34px;
  height: 34px;
  background: #ecfdf5;
  color: #059669;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.yjb-bubble-title {
  font-size: 0.84rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 2px;
}

.yjb-bubble-text {
  font-size: 0.81rem;
  color: #475569;
  line-height: 1.4;
}

.yjb-bubble-close {
  background: transparent;
  border: none;
  color: #94a3b8;
  font-size: 1.25rem;
  line-height: 1;
  padding: 0 4px;
  cursor: pointer;
  transition: color 0.2s;
  flex-shrink: 0;
}

.yjb-bubble-close:hover {
  color: #ef4444;
}

.yjb-bubble-tail {
  position: absolute;
  bottom: -8px;
  right: 24px;
  width: 16px;
  height: 16px;
  background: #ffffff;
  border-right: 1px solid rgba(5, 150, 105, 0.22);
  border-bottom: 1px solid rgba(5, 150, 105, 0.22);
  transform: rotate(45deg);
}

/* Chat Window */
.yjb-chatbot-window {
  position: fixed;
  bottom: 92px;
  right: 24px;
  width: 380px;
  max-width: calc(100vw - 32px);
  height: 520px;
  max-height: calc(100vh - 120px);
  background: #ffffff;
  border-radius: 20px;
  box-shadow: 0 20px 48px rgba(15, 23, 42, 0.18);
  border: 1px solid rgba(226, 232, 240, 0.9);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  z-index: 1050;
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1), transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Header */
.yjb-chat-header {
  background: linear-gradient(135deg, #059669 0%, #047857 60%, #065f46 100%);
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}

.yjb-chat-avatar {
  width: 36px;
  height: 36px;
  background: #ffffff;
  border-radius: 50%;
  padding: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.yjb-chat-avatar img {
  max-height: 24px;
  max-width: 24px;
  object-fit: contain;
}

.yjb-online-badge {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 9px;
  height: 9px;
  background-color: #22c55e;
  border: 2px solid #ffffff;
  border-radius: 50%;
}

.yjb-chat-header-title {
  font-family: 'Outfit', sans-serif;
  font-size: 0.95rem;
  letter-spacing: -0.2px;
}

.yjb-chat-header-sub {
  font-size: 0.75rem;
  display: flex;
  align-items: center;
  gap: 5px;
}

.yjb-chat-close {
  background: rgba(255, 255, 255, 0.15);
  border: none;
  color: #ffffff;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  cursor: pointer;
  transition: background-color 0.2s, transform 0.2s;
}

.yjb-chat-close:hover {
  background: rgba(255, 255, 255, 0.28);
  transform: rotate(90deg);
}

/* Chat Body / Messages */
.yjb-chat-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  background: #f8fafc;
  display: flex;
  flex-direction: column;
  gap: 12px;
  scroll-behavior: smooth;
}

.yjb-msg-item {
  display: flex;
  flex-direction: column;
  max-width: 85%;
}

.yjb-msg-bot {
  align-self: flex-start;
}

.yjb-msg-user {
  align-self: flex-end;
}

.yjb-msg-bubble {
  padding: 10px 14px;
  font-size: 0.875rem;
  line-height: 1.45;
  word-break: break-word;
}

.yjb-msg-bot .yjb-msg-bubble {
  background: #ffffff;
  color: #1e293b;
  border-radius: 16px 16px 16px 4px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.03);
}

.yjb-msg-user .yjb-msg-bubble {
  background: linear-gradient(135deg, #059669 0%, #047857 100%);
  color: #ffffff;
  border-radius: 16px 16px 4px 16px;
  box-shadow: 0 3px 10px rgba(5, 150, 105, 0.25);
}

.yjb-msg-time {
  font-size: 0.68rem;
  color: #94a3b8;
  margin-top: 3px;
  padding: 0 4px;
}

.yjb-msg-user .yjb-msg-time {
  text-align: right;
}

.yjb-msg-cta {
  background: #ecfdf5;
  color: #059669;
  border: 1px solid #a7f3d0;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}

.yjb-msg-cta:hover {
  background: #059669;
  color: #ffffff;
  border-color: #059669;
}

/* Quick Replies */
.yjb-quick-replies-wrap {
  background: #ffffff;
  border-top: 1px solid #f1f5f9;
  padding: 8px 12px;
  flex-shrink: 0;
}

.yjb-quick-replies-scroll {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: thin;
}

.yjb-quick-replies-scroll::-webkit-scrollbar {
  height: 4px;
}

.yjb-quick-replies-scroll::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

.yjb-quick-pill {
  background: #f1f5f9;
  color: #334155;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  padding: 5px 12px;
  font-size: 0.78rem;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.yjb-quick-pill:hover {
  background: #ecfdf5;
  color: #059669;
  border-color: #059669;
  transform: translateY(-1px);
}

/* Footer / Input Area */
.yjb-chat-footer {
  padding: 10px 14px;
  background: #ffffff;
  border-top: 1px solid #e2e8f0;
  flex-shrink: 0;
}

.yjb-chat-input {
  border-radius: 999px !important;
  font-size: 0.875rem;
  padding: 8px 16px;
  border: 1px solid #cbd5e1;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.yjb-chat-input:focus {
  border-color: #059669;
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.15);
}

.yjb-chat-send-btn {
  border-radius: 999px !important;
  background: #059669;
  color: #ffffff;
  border: none;
  width: 40px;
  height: 40px;
  margin-left: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s, transform 0.2s;
}

.yjb-chat-send-btn:hover {
  background: #047857;
  color: #ffffff;
  transform: scale(1.05);
}

/* Animations */
.yjb-animate-pop {
  animation: yjbPop 0.35s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.yjb-animate-slideup {
  animation: yjbSlideUp 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.yjb-animate-fadein {
  animation: yjbFadeIn 0.25s ease-out forwards;
}

@keyframes yjbPop {
  0% { opacity: 0; transform: scale(0.8) translateY(10px); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}

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

@keyframes yjbFadeIn {
  0% { opacity: 0; transform: translateY(6px); }
  100% { opacity: 1; transform: translateY(0); }
}

/* Responsive Overrides */
@media (max-width: 480px) {
  .yjb-chatbot-btn {
    bottom: 18px;
    right: 18px;
    width: 52px;
    height: 52px;
    font-size: 1.35rem;
  }
  .yjb-chatbot-bubble {
    bottom: 78px;
    right: 16px;
    left: 16px;
    max-width: none;
  }
  .yjb-bubble-tail {
    right: 20px;
  }
  .yjb-chatbot-window {
    bottom: 78px;
    right: 12px;
    left: 12px;
    width: auto;
    height: calc(100vh - 100px);
    max-height: 540px;
  }
}

/* Accessibility: Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  .yjb-chatbot-btn,
  .yjb-chatbot-bubble,
  .yjb-chatbot-window,
  .yjb-pulse-dot {
    animation: none !important;
    transition: none !important;
  }
}

/* ==========================================================================
   DONATION PAGE — MOBILE RESPONSIVE REFINEMENTS
   Scope locked strictly to .donation-page and its children
   ========================================================================== */
.donation-page-title {
  font-size: 2.5rem;
  line-height: 1.2;
}

@media (max-width: 767.98px) {
  /* Section Spacing */
  .donation-page {
    padding-top: 1.75rem !important;
    padding-bottom: 2.5rem !important;
    overflow-x: hidden;
  }

  .donation-page .donation-header-wrap {
    margin-bottom: 1.5rem !important;
  }

  .donation-page .donation-header-wrap .badge {
    font-size: 0.78rem !important;
    padding: 0.35rem 0.8rem !important;
    margin-bottom: 0.6rem !important;
  }

  .donation-page-title {
    font-size: 1.75rem !important;
    line-height: 1.25 !important;
    margin-bottom: 0.5rem !important;
    letter-spacing: -0.01em;
  }

  .donation-page .lead {
    font-size: 0.92rem !important;
    line-height: 1.45 !important;
    padding: 0 0.5rem;
    margin-bottom: 0 !important;
  }

  /* Card Container */
  .donation-card {
    padding: 1.25rem 1rem !important;
    border-radius: 18px !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06) !important;
  }

  /* Form Labels & Controls */
  .donation-page .form-label {
    font-size: 0.86rem !important;
    margin-bottom: 0.35rem !important;
    color: var(--text-main);
  }

  .donation-page .form-select,
  .donation-page .form-control {
    min-height: 44px;
    font-size: 0.92rem !important;
    border-radius: 10px !important;
  }

  /* Currency Switcher & Amount Header */
  .donation-amount-header {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 0.5rem !important;
  }

  .donation-currency-wrap {
    width: 100% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 8px !important;
  }

  .donation-currency-wrap .btn-group {
    flex: 1 !important;
    display: flex !important;
  }

  .donation-currency-wrap .btn-group .btn {
    flex: 1 !important;
    padding: 6px 12px !important;
    font-size: 0.8rem !important;
    min-height: 36px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 50px !important;
  }

  /* Amount Input */
  .donation-page .input-group-lg .input-group-text {
    font-size: 1.15rem !important;
    padding: 0.5rem 0.85rem !important;
    min-height: 48px;
  }

  .donation-page .input-group-lg .form-control {
    font-size: 1.25rem !important;
    height: 48px !important;
    font-weight: 700 !important;
  }

  /* Notices */
  .donation-notices {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 2px !important;
    margin-top: 6px !important;
  }

  .donation-notices small {
    font-size: 0.75rem !important;
    line-height: 1.35 !important;
  }

  /* Nominal Preset Buttons — Balanced 3-column Grid */
  .donation-page #presetButtonsContainer {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 8px !important;
    margin-top: 10px !important;
  }

  .donation-page .preset-btn {
    width: 100% !important;
    min-height: 42px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 8px 4px !important;
    font-size: 0.86rem !important;
    font-weight: 700 !important;
    border-radius: 10px !important;
    border-width: 1.5px !important;
    text-align: center !important;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }

  /* Payment Method Items */
  .donation-page .payment-methods-grid {
    gap: 8px !important;
  }

  .donation-page .payment-method-item {
    padding: 10px 12px !important;
    gap: 10px !important;
    border-radius: 12px !important;
    min-height: 58px !important;
    align-items: center !important;
    cursor: pointer;
  }

  .donation-page .payment-method-item .form-check-input {
    width: 1.15rem !important;
    height: 1.15rem !important;
    margin-top: 0 !important;
    flex-shrink: 0 !important;
  }

  .donation-page .payment-method-item i[class*="bi-"] {
    font-size: 1.3rem !important;
    flex-shrink: 0 !important;
    width: 24px !important;
    text-align: center !important;
  }

  .donation-page .payment-method-item .flex-grow-1 {
    min-width: 0 !important;
  }

  .donation-page .payment-method-item .fw-bold {
    font-size: 0.88rem !important;
    line-height: 1.25 !important;
  }

  .donation-page .payment-method-item small.text-muted {
    font-size: 0.74rem !important;
    line-height: 1.3 !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
  }

  .donation-page .payment-method-item .badge {
    font-size: 0.68rem !important;
    padding: 3px 6px !important;
    flex-shrink: 0 !important;
    align-self: center !important;
  }

  .donation-page #paypalUsdBadge,
  .donation-page #stripeUsdBadge {
    font-size: 0.68rem !important;
    padding: 2px 6px !important;
    white-space: normal !important;
    display: inline-block !important;
  }

  /* Anonymous Checkbox */
  .donation-page .form-check {
    min-height: 24px;
    padding-left: 1.75rem;
    margin-top: 0.5rem;
  }

  .donation-page .form-check-input {
    width: 1.1rem;
    height: 1.1rem;
    margin-top: 0.15rem;
  }

  .donation-page .form-check-label {
    font-size: 0.82rem !important;
    line-height: 1.35 !important;
  }

  /* Submit Button */
  .donation-page .btn-custom.btn-lg {
    min-height: 48px !important;
    padding: 12px 20px !important;
    font-size: 0.98rem !important;
    font-weight: 700 !important;
    border-radius: 50px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    touch-action: manipulation;
  }
}

@media (max-width: 480px) {
  .donation-page-title {
    font-size: 1.6rem !important;
  }

  .donation-card {
    padding: 1.15rem 0.85rem !important;
  }

  .donation-page .preset-btn {
    font-size: 0.82rem !important;
    min-height: 40px !important;
  }
}

@media (max-width: 375px) {
  .donation-page {
    padding-top: 1.25rem !important;
  }

  .donation-page-title {
    font-size: 1.45rem !important;
  }

  .donation-card {
    padding: 1rem 0.75rem !important;
    border-radius: 14px !important;
  }

  .donation-currency-wrap span.small {
    display: none !important; /* Save space so currency buttons occupy 100% cleanly */
  }

  .donation-currency-wrap .btn-group .btn {
    font-size: 0.75rem !important;
    padding: 5px 8px !important;
    min-height: 34px !important;
  }

  .donation-page .preset-btn {
    font-size: 0.78rem !important;
    min-height: 38px !important;
    padding: 6px 2px !important;
  }

  .donation-page .payment-method-item {
    padding: 8px 10px !important;
    gap: 8px !important;
  }

  .donation-page .payment-method-item i[class*="bi-"] {
    font-size: 1.15rem !important;
    width: 20px !important;
  }

  .donation-page .payment-method-item .badge {
    font-size: 0.62rem !important;
    padding: 2px 4px !important;
  }
}


