/* ==========================================================================
   Rishi's Branch-Specific Promotional Popups & Notification Drawer Stylesheet
   ========================================================================== */

:root {
  --rsp-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  --rsp-radius: 16px;
  --rsp-font: inherit;
}

/* ─── Backdrop Overlay ─── */
.rsp-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(6px);
  z-index: 999990;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  padding: 16px;
}

.rsp-overlay.rsp-active {
  opacity: 1;
  visibility: visible;
}

/* ─── Center Modal Popup ─── */
.rsp-modal-card {
  background: #ffffff;
  border-radius: var(--rsp-radius);
  max-width: 520px;
  width: 100%;
  position: relative;
  overflow: hidden;
  box-shadow: var(--rsp-shadow);
  transform: scale(0.9) translateY(20px);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.rsp-overlay.rsp-active .rsp-modal-card {
  transform: scale(1) translateY(0);
}

.rsp-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.4);
  color: #ffffff;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  cursor: pointer;
  z-index: 10;
  transition: background 0.2s ease, transform 0.2s ease;
}

.rsp-modal-close:hover {
  background: rgba(15, 23, 42, 0.8);
  transform: rotate(90deg);
}

.rsp-banner-img-wrap {
  width: 100%;
  max-height: 220px;
  overflow: hidden;
  position: relative;
  background: #f1f5f9;
}

.rsp-banner-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.rsp-modal-body {
  padding: 24px 28px 28px 28px;
  text-align: center;
}

.rsp-badge {
  display: inline-block;
  padding: 5px 14px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: 50px;
  margin-bottom: 12px;
}

.rsp-title {
  font-size: 22px;
  font-weight: 800;
  line-height: 1.3;
  margin: 0 0 10px 0;
}

.rsp-subtitle {
  font-size: 14px;
  line-height: 1.5;
  opacity: 0.85;
  margin: 0 0 18px 0;
}

/* ─── Coupon Code Box ─── */
.rsp-coupon-box {
  background: rgba(241, 245, 249, 0.6);
  border: 2px dashed rgba(203, 213, 225, 0.8);
  border-radius: 12px;
  padding: 12px 16px;
  margin: 0 0 18px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.rsp-coupon-code {
  font-family: monospace;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0.1em;
  color: #0f172a;
}

.rsp-copy-btn {
  background: #0f172a;
  color: #ffffff;
  border: none;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.rsp-copy-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.2);
}

/* ─── Countdown Clock ─── */
.rsp-countdown {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 20px;
}

.rsp-count-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 44px;
  background: rgba(15, 23, 42, 0.05);
  border-radius: 8px;
  padding: 6px 8px;
}

.rsp-count-num {
  font-size: 16px;
  font-weight: 800;
}

.rsp-count-label {
  font-size: 9px;
  text-transform: uppercase;
  opacity: 0.7;
}

/* ─── CTA Button ─── */
.rsp-cta-btn {
  display: inline-block;
  width: 100%;
  padding: 14px 24px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  border: none;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
}

.rsp-cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

/* ─── Sticky Top Announcement Bar ─── */
.rsp-top-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 999998;
  padding: 10px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
  transform: translateY(-100%);
  transition: transform 0.35s ease;
}

.rsp-top-bar.rsp-active {
  transform: translateY(0);
}

.rsp-top-bar-content {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  font-weight: 600;
  flex-wrap: wrap;
  justify-content: center;
}

.rsp-top-bar-close {
  background: transparent;
  border: none;
  color: inherit;
  font-size: 18px;
  cursor: pointer;
  opacity: 0.8;
  padding: 4px;
}

.rsp-top-bar-close:hover {
  opacity: 1;
}

/* ─── Bottom Toast Slide-In ─── */
.rsp-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 360px;
  max-width: calc(100vw - 32px);
  background: #ffffff;
  border-radius: 14px;
  box-shadow: var(--rsp-shadow);
  z-index: 999995;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transform: translateX(120%);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.rsp-toast.rsp-active {
  transform: translateX(0);
}

.rsp-toast-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* ─── Floating Offer Bell Button Widget ─── */
.rsp-offer-bell {
  position: fixed;
  bottom: 28px;
  left: 28px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #e11d48;
  color: #ffffff;
  border: none;
  box-shadow: 0 8px 24px rgba(225, 29, 72, 0.4);
  cursor: pointer;
  z-index: 999990;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  animation: rsp-pulse-bell 3s infinite;
}

.rsp-offer-bell:hover {
  transform: scale(1.1);
  box-shadow: 0 12px 30px rgba(225, 29, 72, 0.6);
}

@keyframes rsp-pulse-bell {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.06); }
}

.rsp-bell-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: #f59e0b;
  color: #0f172a;
  font-size: 11px;
  font-weight: 800;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #ffffff;
}

/* ─── Off-Canvas Offer Drawer ─── */
.rsp-drawer-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(4px);
  z-index: 999996;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.rsp-drawer-backdrop.rsp-active {
  opacity: 1;
  visibility: visible;
}

.rsp-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 400px;
  max-width: 100vw;
  height: 100vh;
  background: #ffffff;
  box-shadow: -10px 0 30px rgba(0,0,0,0.15);
  z-index: 999997;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.35s ease;
}

.rsp-drawer-backdrop.rsp-active .rsp-drawer {
  transform: translateX(0);
}

.rsp-drawer-header {
  padding: 20px 24px;
  background: #0f172a;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.rsp-drawer-title {
  font-size: 18px;
  font-weight: 700;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.rsp-drawer-close {
  background: transparent;
  border: none;
  color: #ffffff;
  font-size: 22px;
  cursor: pointer;
}

.rsp-drawer-body {
  padding: 20px;
  overflow-y: auto;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.rsp-drawer-item {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 16px;
  background: #f8fafc;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.rsp-drawer-item:hover {
  border-color: #cbd5e1;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

@media (max-width: 640px) {
  .rsp-modal-card {
    max-width: 100%;
  }
  .rsp-modal-body {
    padding: 18px 20px 22px 20px;
  }
  .rsp-offer-bell {
    bottom: 20px;
    left: 20px;
    width: 48px;
    height: 48px;
    font-size: 20px;
  }
}
