/* =====================================================================
   Vibrant Innovations — promotions: pop-up and side banner
   Uses the site's --vi-* colour tokens, so light and dark mode follow.
   ===================================================================== */

.vip-modal, .vip-side { --vip-radius: 20px; --vip-spring: cubic-bezier(.34, 1.56, .64, 1); --vip-ease: cubic-bezier(.4, 0, .2, 1); font-family: var(--default-font, system-ui, sans-serif); }
.vip-modal *, .vip-side * { box-sizing: border-box; }

/* ── Pop-up ────────────────────────────────────────────────────────── */
.vip-modal { position: fixed; inset: 0; z-index: 100010; display: grid; place-items: center; padding: 20px; }
.vip-modal[hidden] { display: none; }
.vip-backdrop { position: absolute; inset: 0; background: rgba(10, 16, 13, .55); backdrop-filter: blur(4px); animation: vip-fade .3s var(--vip-ease) both; }
.vip-card {
  position: relative; width: min(460px, 100%); max-height: calc(100dvh - 40px); overflow: auto;
  background: var(--vi-surface, #fff); color: var(--vi-text, #3d4a42); border-radius: var(--vip-radius);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .35); animation: vip-pop .5s var(--vip-spring) both;
  overscroll-behavior: contain;
}
.vip-modal.is-closing .vip-card { animation: vip-out .22s var(--vip-ease) both; }
.vip-modal.is-closing .vip-backdrop { animation: vip-fade .22s var(--vip-ease) reverse both; }

.vip-close {
  position: absolute; top: 12px; right: 12px; z-index: 2; width: 36px; height: 36px; border-radius: 50%; border: 0;
  display: grid; place-items: center; cursor: pointer; font-size: 1rem;
  background: rgba(255, 255, 255, .88); color: #1c2620; box-shadow: 0 2px 10px rgba(0, 0, 0, .15);
  transition: transform .2s var(--vip-spring), background .2s;
}
.vip-close:hover { transform: rotate(90deg) scale(1.06); }
.vip-close:focus-visible, .vip-btn:focus-visible, .vip-chip:focus-visible, .vip-copy:focus-visible, .vip-link:focus-visible { outline: 2px solid var(--vi-accent-strong, #7fb28b); outline-offset: 2px; }

/* The image container keeps a steady shape whatever image is uploaded. */
.vip-media { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: linear-gradient(135deg, var(--vi-accent-soft, #eef6f0), var(--vi-raised, #f6f8f6)); }
.vip-media img { width: 100%; height: 100%; object-fit: cover; display: block; transform: scale(1.04); animation: vip-zoom 1.2s var(--vip-ease) .1s both; }
.vip-media.is-empty { aspect-ratio: auto; height: 86px; background: radial-gradient(120% 140% at 10% 0%, #e2f4e7 0%, #a8d4b2 45%, #5f9670 100%); }
.vip-media.is-empty::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(135deg, rgba(255,255,255,.12) 0 12px, transparent 12px 24px); }
.vip-badge {
  position: absolute; left: 14px; bottom: 14px; z-index: 1; padding: 6px 12px; border-radius: 999px;
  background: #1c2620; color: #fff; font-size: .78rem; font-weight: 700; letter-spacing: .02em; box-shadow: 0 6px 18px rgba(0, 0, 0, .25);
  animation: vip-badge .6s var(--vip-spring) .25s both;
}

.vip-content { padding: 22px 24px 22px; }
.vip-eyebrow { margin: 0 0 6px; font-size: .74rem; font-weight: 600; text-transform: uppercase; letter-spacing: .1em; color: var(--vi-accent-strong, #7fb28b); }
.vip-title { margin: 0 0 8px; font-family: var(--heading-font, "Raleway", sans-serif); font-weight: 800; font-size: clamp(1.3rem, 4.6vw, 1.6rem); line-height: 1.2; color: var(--vi-heading, #1c2620); }
.vip-body { margin: 0 0 16px; font-size: .96rem; line-height: 1.55; }

.vip-code { display: flex; align-items: center; gap: 8px; margin: 0 0 16px; padding: 8px 8px 8px 14px; border: 1.5px dashed var(--vi-accent-strong, #7fb28b); border-radius: 12px; background: var(--vi-accent-soft, #eef6f0); }
.vip-code code { flex: 1; font-size: 1rem; font-weight: 700; letter-spacing: .08em; color: var(--vi-heading, #1c2620); background: none; padding: 0; }
.vip-copy { border: 0; border-radius: 9px; padding: 7px 12px; background: var(--vi-surface, #fff); color: var(--vi-heading, #1c2620); font-size: .82rem; font-weight: 600; cursor: pointer; }

.vip-actions { display: grid; gap: 8px; }
.vip-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 48px; padding: 12px 18px;
  border: 0; border-radius: 999px; cursor: pointer; font-weight: 600; font-size: 1rem; text-decoration: none;
  background: var(--vi-accent, #a0cba9); color: #10231a; box-shadow: 0 8px 22px rgba(95, 150, 112, .35);
  transition: transform .25s var(--vip-spring), box-shadow .25s, background .2s;
}
.vip-btn:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgba(95, 150, 112, .42); color: #10231a; }
.vip-btn:active { transform: scale(.97); }
.vip-link { justify-self: center; border: 0; background: none; color: var(--vi-muted, #6b7a71); font-size: .88rem; padding: 6px 10px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }

/* Company size question */
.vip-sizes { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 8px; margin: 4px 0 12px; }
.vip-chip {
  display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 10px 14px; border-radius: 14px; text-align: left; cursor: pointer;
  border: 1px solid var(--vi-line, rgba(16,24,20,.1)); background: var(--vi-raised, #f6f8f6); color: var(--vi-heading, #1c2620); font-size: .92rem; font-weight: 500;
  transition: transform .25s var(--vip-spring), border-color .2s, background .2s; animation: vip-rise .45s var(--vip-spring) both;
}
.vip-chip i { color: var(--vi-accent-strong, #7fb28b); font-size: 1.1rem; }
.vip-chip:hover { border-color: var(--vi-accent-strong, #7fb28b); transform: translateY(-2px); }
.vip-chip:active, .vip-chip.is-picked { transform: scale(.96); background: var(--vi-accent-soft, #eef6f0); border-color: var(--vi-accent-strong, #7fb28b); }
.vip-step { animation: vip-rise .4s var(--vip-ease) both; }

/* ── A fixed price, and what it covers ─────────────────────────────── */
.vip-price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px; margin: 0 0 10px; }
.vip-price-now { font-family: var(--heading-font, "Raleway", sans-serif); font-size: clamp(1.6rem, 6vw, 2.1rem); font-weight: 800; line-height: 1; color: var(--vi-heading, #1c2620); }
.vip-price-was { font-size: 1rem; color: var(--vi-muted, #6b7a71); text-decoration-thickness: 2px; }
.vip-price-note { flex-basis: 100%; font-size: .8rem; color: var(--vi-muted, #6b7a71); }
.vip-items { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 2px; border-top: 1px solid var(--vi-line, rgba(16,24,20,.1)); padding-top: 8px; }
.vip-items li { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; padding: 4px 0; font-size: .9rem; }
.vip-items li span { position: relative; padding-left: 18px; color: var(--vi-text, #3d4a42); }
.vip-items li span::before { content: "✓"; position: absolute; left: 0; color: var(--vi-accent-strong, #7fb28b); font-weight: 700; }
.vip-items li b { white-space: nowrap; color: var(--vi-heading, #1c2620); font-variant-numeric: tabular-nums; }
.vip-items li b.is-included { font-weight: 500; color: var(--vi-muted, #6b7a71); }

/* ── Side banner ───────────────────────────────────────────────────── */
/* Up to three stack above each other, newest at the bottom. */
.vip-side-stack { position: fixed; left: 20px; bottom: 20px; z-index: 99990; display: grid; gap: 12px; justify-items: start; max-height: calc(100dvh - 40px); }
.vip-side {
  position: relative; width: 300px;
  background: var(--vi-surface, #fff); color: var(--vi-text, #3d4a42); border-radius: 18px; overflow: hidden;
  border: 1px solid var(--vi-line, rgba(16,24,20,.1)); box-shadow: var(--vi-shadow-lg, 0 12px 32px rgba(16,24,20,.18));
  animation: vip-slide .6s var(--vip-spring) both;
}
.vip-side[hidden] { display: none; }
.vip-side.is-closing { animation: vip-slide-out .3s var(--vip-ease) both; }
.vip-side .vip-close { top: 8px; right: 8px; width: 30px; height: 30px; font-size: .85rem; }
.vip-side .vip-badge { left: 10px; bottom: 10px; padding: 4px 10px; font-size: .72rem; }
.vip-side-body { padding: 14px 16px 16px; }
.vip-side .vip-title { font-size: 1.08rem; margin-bottom: 4px; }
.vip-side .vip-price { margin-bottom: 8px; }
/* Two or three at once: compact cards, so the page stays visible */
.vip-side-stack[data-count="2"] .vip-side, .vip-side-stack[data-count="3"] .vip-side { width: 272px; }
.vip-side-stack[data-count="2"] .vip-media, .vip-side-stack[data-count="3"] .vip-media { aspect-ratio: 21 / 6; }
.vip-side-stack[data-count="2"] .vip-media.is-empty, .vip-side-stack[data-count="3"] .vip-media.is-empty { height: 34px; }
.vip-side-stack[data-count="2"] .vip-body, .vip-side-stack[data-count="3"] .vip-body,
.vip-side-stack[data-count="2"] .vip-items, .vip-side-stack[data-count="3"] .vip-items { display: none; }
.vip-side-stack[data-count="2"] .vip-side-body, .vip-side-stack[data-count="3"] .vip-side-body { padding: 10px 14px 12px; }
.vip-side-stack[data-count="2"] .vip-price-now, .vip-side-stack[data-count="3"] .vip-price-now { font-size: 1.25rem; }
.vip-side-stack[data-count="2"] .vip-btn, .vip-side-stack[data-count="3"] .vip-btn { min-height: 34px; font-size: .84rem; }
.vip-side .vip-price-now { font-size: 1.5rem; }
.vip-side .vip-items { margin-bottom: 10px; font-size: .82rem; }
.vip-side .vip-items li { padding: 2px 0; }
.vip-side .vip-body { font-size: .86rem; margin-bottom: 12px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.vip-side .vip-code { margin-bottom: 10px; padding: 5px 5px 5px 10px; }
.vip-side .vip-code code { font-size: .88rem; }
.vip-side .vip-btn { min-height: 40px; padding: 8px 14px; font-size: .9rem; }

@media (max-width: 767px) {
  .vip-modal { align-items: end; padding: 0; }
  .vip-card { width: 100%; max-height: 92dvh; border-radius: 24px 24px 0 0; animation: vip-sheet .5s var(--vip-spring) both; padding-bottom: env(safe-area-inset-bottom); }
  .vip-modal.is-closing .vip-card { animation: vip-sheet-out .25s var(--vip-ease) both; }
  .vip-card::before { content: ""; position: absolute; top: 8px; left: 50%; width: 40px; height: 4px; margin-left: -20px; border-radius: 4px; background: rgba(255,255,255,.8); z-index: 3; }
  .vip-sizes { grid-template-columns: 1fr 1fr; }
  .vip-chip { font-size: .86rem; padding: 10px 12px; }

  /* Compact bar that leaves room for the chat button on the right */
  .vip-side-stack { left: 10px; right: 90px; bottom: 14px; justify-items: stretch; }
  .vip-side { width: auto; display: grid; grid-template-columns: 72px 1fr; border-radius: 16px; }
  .vip-side .vip-items { display: none; }
  .vip-side .vip-price { margin: 2px 0 0; gap: 6px; }
  .vip-side .vip-price-now { font-size: 1.05rem; }
  .vip-side .vip-price-was { font-size: .8rem; }
  .vip-side .vip-price-note { display: none; }
  .vip-side .vip-media { aspect-ratio: auto; height: 100%; min-height: 76px; }
  .vip-side .vip-media.is-empty { height: auto; }
  .vip-side .vip-badge, .vip-side .vip-body, .vip-side .vip-code { display: none; }
  .vip-side-body { padding: 10px 34px 10px 12px; display: flex; flex-direction: column; justify-content: center; gap: 6px; }
  .vip-side .vip-title { font-size: .92rem; margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .vip-side .vip-btn { min-height: 32px; width: auto; justify-self: start; align-self: flex-start; padding: 6px 12px; font-size: .8rem; box-shadow: none; }
  .vip-side .vip-close { top: 6px; right: 6px; width: 26px; height: 26px; }
  html.vip-lock, html.vip-lock body { overflow: hidden; }
}

@keyframes vip-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes vip-pop { from { opacity: 0; transform: translateY(24px) scale(.92); } to { opacity: 1; transform: none; } }
@keyframes vip-out { to { opacity: 0; transform: translateY(12px) scale(.96); } }
@keyframes vip-sheet { from { transform: translateY(100%); } to { transform: none; } }
@keyframes vip-sheet-out { to { transform: translateY(100%); } }
@keyframes vip-zoom { from { transform: scale(1.15); } to { transform: scale(1.04); } }
@keyframes vip-badge { from { opacity: 0; transform: translateY(10px) scale(.8); } to { opacity: 1; transform: none; } }
@keyframes vip-rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes vip-slide { from { opacity: 0; transform: translateX(-120%); } to { opacity: 1; transform: none; } }
@keyframes vip-slide-out { to { opacity: 0; transform: translateX(-120%); } }

@media (prefers-reduced-motion: reduce) {
  .vip-modal *, .vip-side, .vip-side * { animation-duration: .01ms !important; animation-delay: 0s !important; transition: none !important; }
}
