/* =========================================================================
   MoneyCashe – Conversion / UX Optimization Layer  (v7.4)
   -------------------------------------------------------------------------
   Additive styles only. Nothing in the site's existing stylesheets is
   overridden except:
     - .sticky-cta is hidden (superseded by the richer .mc-bottombar)
     - a handful of pre-existing floating buttons are nudged upward on
       mobile so they don't overlap the new bottom bar
   ========================================================================= */

/* ---- Supersede the old single-button mobile CTA bar ----
   Replaced by the 3-button .mc-bottombar below. Hidden, not deleted,
   so nothing else that references it breaks. */
.sticky-cta { display: none !important; }

/* ---- Keep pre-existing floating buttons clear of the new bottom bar ---- */
@media (max-width: 768px) {
  body { padding-bottom: 78px !important; }
  .whatsapp-float   { bottom: 92px  !important; }
  .back-to-top      { bottom: 168px !important; }
  .contact-rail     { bottom: 158px !important; }
}
@media (max-width: 480px) {
  .whatsapp-float   { bottom: 86px  !important; }
  .back-to-top      { bottom: 156px !important; }
  .contact-rail     { bottom: 146px !important; }
}

/* =========================================================================
   1. Mobile Bottom Bar
   ========================================================================= */
.mc-bottombar {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 210;
  display: none;
  gap: 6px;
  padding: 9px 10px calc(9px + env(safe-area-inset-bottom, 0px));
  background: rgba(255,255,255,0.98);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  backdrop-filter: saturate(180%) blur(14px);
  border-top-left-radius: 20px;
  border-top-right-radius: 20px;
  box-shadow: 0 -8px 28px rgba(10,22,40,0.16);
}
@media (max-width: 768px) {
  .mc-bottombar { display: flex; }
}
.mc-bb-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 8px 4px;
  border-radius: 14px;
  text-decoration: none;
  font-family: 'Manrope', 'Inter', Arial, sans-serif;
  font-weight: 700;
  font-size: 11.5px;
  line-height: 1.2;
  transition: transform .15s ease;
  -webkit-tap-highlight-color: transparent;
}
.mc-bb-item:active { transform: scale(0.93); }
.mc-bb-icon { font-size: 19px; line-height: 1; }
.mc-bb-call     { color: #059669; background: #ECFDF5; }
.mc-bb-whatsapp { color: #0EA35A; background: #E8FBF0; }
.mc-bb-apply {
  color: #fff;
  background: linear-gradient(135deg, #2563EB, #1E4FC2);
  box-shadow: 0 6px 16px rgba(37,99,235,0.35);
}

/* =========================================================================
   2. Sticky Desktop "Apply Now" CTA
   ========================================================================= */
.mc-desktop-apply {
  position: fixed;
  right: 0;
  top: 55%;
  transform: translateY(-50%);
  z-index: 150;
  display: none;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, #2563EB, #1E4FC2);
  color: #fff;
  padding: 15px 22px 15px 20px;
  border-radius: 50px 0 0 50px;
  text-decoration: none;
  font-family: 'Manrope', 'Inter', Arial, sans-serif;
  font-weight: 800;
  font-size: 14px;
  letter-spacing: -0.01em;
  box-shadow: 0 10px 28px rgba(37,99,235,0.38);
  animation: mcSlideIn .6s ease .5s both, mcFloatPulse 2.8s ease-in-out 1.3s infinite;
}
@media (min-width: 900px) {
  .mc-desktop-apply { display: inline-flex; }
}
.mc-desktop-apply:hover {
  transform: translateY(-50%) translateX(-4px);
  box-shadow: 0 14px 34px rgba(37,99,235,0.5);
}
.mc-da-icon { font-size: 17px; }
@keyframes mcSlideIn {
  from { transform: translateY(-50%) translateX(110px); opacity: 0; }
  to   { transform: translateY(-50%) translateX(0);     opacity: 1; }
}
@keyframes mcFloatPulse {
  0%, 100% { box-shadow: 0 10px 28px rgba(37,99,235,0.38); }
  50%      { box-shadow: 0 14px 36px rgba(37,99,235,0.58); }
}

/* =========================================================================
   3. Exit Intent Popup (desktop only)
   ========================================================================= */
.mc-exit-overlay {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(10,22,40,0.62);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
  padding: 20px;
}
.mc-exit-overlay.mc-exit-open { display: flex; animation: mcFadeIn .25s ease; }
@keyframes mcFadeIn { from { opacity: 0; } to { opacity: 1; } }

.mc-exit-modal {
  background: #fff;
  border-radius: 20px;
  max-width: 420px;
  width: 100%;
  padding: 38px 32px 28px;
  position: relative;
  text-align: center;
  box-shadow: 0 30px 80px rgba(10,22,40,0.35);
  animation: mcPopIn .35s cubic-bezier(.34,1.56,.64,1);
  font-family: 'Inter', Arial, sans-serif;
}
@keyframes mcPopIn {
  from { transform: scale(0.92); opacity: 0; }
  to   { transform: scale(1);    opacity: 1; }
}
.mc-exit-close {
  position: absolute;
  top: 14px; right: 14px;
  width: 30px; height: 30px;
  border-radius: 50%;
  border: none;
  background: #F1F5F9;
  color: #475569;
  font-size: 15px;
  line-height: 1;
  cursor: pointer;
}
.mc-exit-close:hover { background: #E2E8F0; }
.mc-exit-badge {
  display: inline-block;
  background: #FEF3C7;
  color: #92400E;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: 14px;
}
.mc-exit-modal h3 {
  font-family: 'Manrope', 'Inter', Arial, sans-serif;
  font-size: 23px;
  font-weight: 800;
  color: #0A1628;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}
.mc-exit-sub { font-size: 14.5px; color: #475569; margin: 0 0 22px; line-height: 1.5; }
.mc-exit-form { display: flex; flex-direction: column; gap: 12px; text-align: left; }
.mc-exit-form input {
  width: 100%;
  padding: 13px 14px;
  border: 1.5px solid #E2E8F0;
  border-radius: 10px;
  font-size: 14px;
  font-family: inherit;
  box-sizing: border-box;
  background: #F8FAFC;
}
.mc-exit-form input:focus { outline: none; border-color: #2563EB; background: #fff; }
.mc-exit-error {
  color: #DC2626;
  font-size: 12px;
  margin: -4px 0 0;
  display: none;
  text-align: left;
}
.mc-exit-error.show { display: block; }
.mc-exit-btn {
  margin-top: 4px;
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 50px;
  background: linear-gradient(135deg, #2563EB, #1E4FC2);
  color: #fff;
  font-weight: 800;
  font-size: 15px;
  cursor: pointer;
  font-family: 'Manrope', 'Inter', Arial, sans-serif;
  transition: background .2s ease;
}
.mc-exit-btn:hover { background: #1A3A6B; }
.mc-exit-btn:disabled { opacity: 0.7; cursor: not-allowed; }
.mc-exit-privacy { margin: 16px 0 0; font-size: 11.5px; color: #94A3B8; }

/* =========================================================================
   4. Bank / Lending Partner Logo Grid
   ========================================================================= */
.mc-partners { padding: 56px 5%; background: #fff; }
.mc-partners-inner { max-width: 1100px; margin: 0 auto; text-align: center; }
.mc-partner-grid {
  margin-top: 30px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
@media (max-width: 900px) { .mc-partner-grid { grid-template-columns: repeat(2, 1fr); } }
.mc-partner-chip {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 74px;
  border-radius: 14px;
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  font-family: 'Manrope', 'Inter', Arial, sans-serif;
  font-weight: 800;
  font-size: 14px;
  color: #0A1628;
  padding: 10px 14px;
  text-align: center;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.mc-partner-chip:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 24px rgba(10,22,40,0.10);
  border-color: #BFDBFE;
}
.mc-partner-disclaimer {
  margin: 26px auto 0;
  max-width: 720px;
  font-size: 12.5px;
  color: #475569;
  line-height: 1.6;
}

/* =========================================================================
   5. Trust Section (4 cards)
   ========================================================================= */
.mc-trust { padding: 52px 5% 8px; background: #F8FAFC; }
.mc-trust-inner { max-width: 1100px; margin: 0 auto; }
.mc-trust-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 8px;
}
@media (max-width: 900px) { .mc-trust-grid { grid-template-columns: repeat(2, 1fr); } }
.mc-trust-card {
  background: #fff;
  border-radius: 16px;
  padding: 26px 18px;
  text-align: center;
  border: 1px solid #E2E8F0;
  box-shadow: 0 4px 20px rgba(10,22,40,0.06);
}
.mc-trust-icon { font-size: 27px; margin-bottom: 10px; }
.mc-trust-card h4 {
  font-family: 'Manrope', 'Inter', Arial, sans-serif;
  font-size: 15px;
  color: #0A1628;
  margin: 0 0 6px;
}
.mc-trust-card p { font-size: 12.5px; color: #475569; margin: 0; line-height: 1.5; }

@media (max-width: 480px) {
  .mc-partner-grid, .mc-trust-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .mc-partner-chip { min-height: 64px; font-size: 12.5px; }
}

/* Accessibility utility: visually hidden but available to screen readers / SEO structure */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
