/* ==========================================================================
   lesSouq pop-up campaigns — self-contained (storefront + admin live preview)
   layouts: center · sheet · corner · bar      themes: light · dark · brand · sunset
   ========================================================================== */
.lp-pop {
  --lp-bg: #fff; --lp-ink: #1d1d1f; --lp-text: #515154; --lp-muted: #86868b; --lp-accent: #0071e3; --lp-accent-ink: #fff;
  --lp-chip: #f5f5f7; --lp-line: rgba(0,0,0,.08);
  position: fixed; z-index: 1085; font-family: inherit; color: var(--lp-ink);
}
.lp-pop[hidden] { display: none !important; }
.lp-t-dark   { --lp-bg: #1c1c1e; --lp-ink: #f5f5f7; --lp-text: #c7c7cc; --lp-muted: #8e8e93; --lp-accent: #fff; --lp-accent-ink: #000; --lp-chip: #2c2c2e; --lp-line: rgba(255,255,255,.12); }
.lp-t-brand  { --lp-bg: linear-gradient(150deg, #0a2a5e 0%, #0071e3 100%); --lp-ink: #fff; --lp-text: rgba(255,255,255,.86); --lp-muted: rgba(255,255,255,.65); --lp-accent: #fff; --lp-accent-ink: #0a2a5e; --lp-chip: rgba(255,255,255,.14); --lp-line: rgba(255,255,255,.22); }
.lp-t-sunset { --lp-bg: linear-gradient(150deg, #ff7a18 0%, #ff3d77 100%); --lp-ink: #fff; --lp-text: rgba(255,255,255,.9); --lp-muted: rgba(255,255,255,.72); --lp-accent: #fff; --lp-accent-ink: #c2185b; --lp-chip: rgba(255,255,255,.18); --lp-line: rgba(255,255,255,.28); }

.lp-card { position: relative; background: var(--lp-bg); color: var(--lp-ink); box-shadow: 0 30px 80px rgba(0,0,0,.28); overflow: hidden; }
.lp-body { padding: 28px 26px 20px; text-align: center; }
.lp-eyebrow { display: inline-block; padding: 5px 11px; margin-bottom: 10px; border-radius: 999px; background: var(--lp-chip); font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--lp-ink); }
.lp-title { margin: 0 0 8px; font-size: 26px; line-height: 1.15; font-weight: 700; letter-spacing: -.02em; color: var(--lp-ink); }
.lp-text { margin: 0 0 16px; font-size: 15px; line-height: 1.55; color: var(--lp-text); }
.lp-x { position: absolute; top: 12px; inset-inline-end: 12px; z-index: 2; width: 34px; height: 34px; border: 0; border-radius: 50%; display: grid; place-items: center;
  background: rgba(0,0,0,.06); color: var(--lp-ink); cursor: pointer; font-size: 15px; backdrop-filter: blur(8px); }
.lp-t-dark .lp-x, .lp-t-brand .lp-x, .lp-t-sunset .lp-x { background: rgba(255,255,255,.16); }
.lp-actions { display: grid; gap: 10px; }
.lp-btn { display: flex; align-items: center; justify-content: center; min-height: 50px; padding: 0 22px; border: 0; border-radius: 14px;
  background: var(--lp-accent); color: var(--lp-accent-ink); font-size: 16px; font-weight: 600; text-decoration: none; cursor: pointer; transition: transform .15s, opacity .15s; }
.lp-btn:hover { opacity: .92; color: var(--lp-accent-ink); }
.lp-btn:active { transform: scale(.98); }
.lp-code { display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; min-height: 54px; padding: 0 8px 0 18px; border-radius: 14px;
  border: 1.5px dashed var(--lp-line); background: var(--lp-chip); color: var(--lp-ink); cursor: pointer; font: inherit; }
.lp-code span { font: 700 19px/1 ui-monospace, Menlo, Consolas, monospace; letter-spacing: .08em; }
.lp-code em { font-style: normal; font-size: 13px; font-weight: 600; padding: 8px 12px; border-radius: 10px; background: var(--lp-bg); color: var(--lp-ink); }
.lp-t-light .lp-code { border-color: #f59e0b; background: #fffbeb; }
.lp-t-light .lp-code em { background: #fff; }
.lp-code.is-copied { border-style: solid; border-color: #34c759; }
.lp-form { display: flex; gap: 8px; }
.lp-form input { flex: 1; min-width: 0; height: 50px; padding: 0 16px; border-radius: 14px; border: 1px solid var(--lp-line); background: var(--lp-chip); color: var(--lp-ink); font-size: 16px; outline: 0; }
.lp-t-light .lp-form input { background: #fff; border-color: rgba(0,0,0,.14); }
.lp-form input::placeholder { color: var(--lp-muted); }
.lp-form input:focus { border-color: var(--lp-accent); box-shadow: 0 0 0 4px rgba(0,113,227,.15); }
.lp-form .lp-btn { flex: 0 0 auto; }
.lp-fine { margin: 2px 0 0; font-size: 12px; color: var(--lp-muted); }
.lp-success { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 50px; border-radius: 14px; background: rgba(52,199,89,.14); color: #1f7a3a; font-weight: 600; }
.lp-t-dark .lp-success, .lp-t-brand .lp-success, .lp-t-sunset .lp-success { background: rgba(255,255,255,.18); color: #fff; }
.lp-dismiss { margin-top: 12px; border: 0; background: none; color: var(--lp-muted); font-size: 13.5px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.lp-timer { display: flex; justify-content: center; gap: 8px; margin: 0 0 16px; }
.lp-timer span { min-width: 58px; padding: 8px 6px; border-radius: 12px; background: var(--lp-chip); display: flex; flex-direction: column; align-items: center; }
.lp-timer b { font-size: 22px; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.1; color: var(--lp-ink); }
.lp-timer small { font-size: 10.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--lp-muted); }
.lp-media { background: #f5f5f7; }
.lp-media img { display: block; width: 100%; height: 100%; object-fit: cover; }

/* ---------- center (modal) ---------- */
.lp-center, .lp-sheet { inset: 0; display: grid; place-items: center; padding: 20px; background: rgba(0,0,0,.45); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.lp-center .lp-card { width: min(440px, 100%); border-radius: 28px; }
.lp-center.has-media .lp-card { width: min(780px, 100%); display: grid; grid-template-columns: 1fr 1fr; }
.lp-center.has-media .lp-media { min-height: 100%; }
.lp-center.has-media .lp-body { display: flex; flex-direction: column; justify-content: center; padding: 40px 32px 26px; }
/* ---------- sheet (bottom sheet) ---------- */
.lp-sheet { place-items: end center; padding: 0; }
.lp-sheet .lp-card { width: min(560px, 100%); border-radius: 28px 28px 0 0; padding-bottom: env(safe-area-inset-bottom); }
.lp-sheet .lp-card::before { content: ""; display: block; width: 40px; height: 5px; margin: 10px auto 0; border-radius: 3px; background: var(--lp-line); }
.lp-sheet.has-media .lp-media { height: 170px; }
/* ---------- corner (slide-in, no backdrop) ---------- */
.lp-corner { bottom: 22px; inset-inline-end: 22px; width: min(360px, calc(100vw - 32px)); }
.lp-corner .lp-card { border-radius: 22px; box-shadow: 0 18px 50px rgba(0,0,0,.22); }
.lp-corner .lp-body { padding: 22px 20px 14px; text-align: start; }
.lp-corner .lp-title { font-size: 20px; padding-inline-end: 30px; }
.lp-corner .lp-text { font-size: 14px; margin-bottom: 12px; }
.lp-corner.has-media .lp-media { height: 140px; }
.lp-corner .lp-timer { justify-content: flex-start; }
.lp-corner .lp-timer span { min-width: 50px; }
/* ---------- bar (top announcement strip) ---------- */
.lp-bar { top: 0; left: 0; right: 0; }
.lp-bar .lp-card { border-radius: 0; box-shadow: 0 6px 24px rgba(0,0,0,.14); }
.lp-bar .lp-body { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 6px 16px; padding: 10px 56px; text-align: start; }
.lp-bar .lp-title { font-size: 15px; margin: 0; }
.lp-bar .lp-text { font-size: 13.5px; margin: 0; }
.lp-bar .lp-actions { display: flex; gap: 8px; align-items: center; }
.lp-bar .lp-btn { min-height: 36px; padding: 0 16px; border-radius: 10px; font-size: 14px; }
.lp-bar .lp-code { min-height: 36px; width: auto; padding: 0 4px 0 12px; border-radius: 10px; }
.lp-bar .lp-code span { font-size: 14px; }
.lp-bar .lp-code em { padding: 5px 9px; font-size: 12px; }
.lp-bar .lp-timer { margin: 0; gap: 4px; }
.lp-bar .lp-timer span { min-width: 40px; padding: 3px 4px; border-radius: 8px; }
.lp-bar .lp-timer b { font-size: 14px; }
.lp-bar .lp-timer small { font-size: 8.5px; }
.lp-bar .lp-x { top: 50%; margin-top: -15px; width: 30px; height: 30px; }
.lp-bar .lp-form input, .lp-bar .lp-form .lp-btn { height: 36px; min-height: 36px; }

/* ---------- motion ---------- */
.lp-pop.is-open.lp-center, .lp-pop.is-open.lp-sheet { animation: lpFade .25s ease both; }
.lp-pop.is-open.lp-center .lp-card { animation: lpPop .35s cubic-bezier(.2,.9,.3,1.2) both; }
.lp-pop.is-open.lp-sheet .lp-card { animation: lpUp .35s cubic-bezier(.2,.8,.2,1) both; }
.lp-pop.is-open.lp-corner { animation: lpSlide .4s cubic-bezier(.2,.8,.2,1) both; }
.lp-pop.is-open.lp-bar { animation: lpDown .35s ease both; }
.lp-pop.is-closing { animation: lpFade .2s ease reverse both !important; }
@keyframes lpFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes lpPop { from { opacity: 0; transform: scale(.92) translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes lpUp { from { transform: translateY(100%); } to { transform: none; } }
@keyframes lpSlide { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: none; } }
@keyframes lpDown { from { transform: translateY(-100%); } to { transform: none; } }
@media (prefers-reduced-motion: reduce) { .lp-pop, .lp-pop .lp-card { animation: none !important; } }

/* ---------- phones ---------- */
@media (max-width: 575px) {
  .lp-center { place-items: end center; padding: 0; }
  .lp-center .lp-card, .lp-center.has-media .lp-card { width: 100%; border-radius: 26px 26px 0 0; display: block; padding-bottom: env(safe-area-inset-bottom); max-height: 92vh; overflow-y: auto; }
  .lp-center.has-media .lp-media { height: 180px; }
  .lp-center.has-media .lp-body { padding: 24px 20px 18px; }
  .lp-pop.is-open.lp-center .lp-card { animation-name: lpUp; }
  .lp-body { padding: 24px 20px 16px; }
  .lp-title { font-size: 23px; }
  .lp-form { flex-direction: column; }
  .lp-corner { inset-inline: 12px; width: auto; bottom: calc(76px + env(safe-area-inset-bottom)); }
  .lp-bar .lp-body { padding: 10px 46px 10px 14px; justify-content: flex-start; }
  [dir="rtl"] .lp-bar .lp-body { padding: 10px 14px 10px 46px; }
  .lp-bar .lp-text { display: none; }
}

/* the honeypot field on checkout — invisible to people, filled by bots */
.op-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }

/* stacking: modals above the mobile bottom nav (1200); bar above the sticky header */
.lp-center, .lp-sheet { z-index: 1300; }
.lp-bar { z-index: 1250; }
.lp-corner { z-index: 1150; }

/* phones: keep the top bar to one tidy row — title + code/button, no timer */
@media (max-width: 575px) {
  .lp-bar .lp-timer { display: none; }
  .lp-bar .lp-body { flex-wrap: nowrap; gap: 8px; }
  .lp-bar .lp-title { font-size: 13px; line-height: 1.3; flex: 1 1 auto; min-width: 0; }
  .lp-bar .lp-actions { flex: 0 0 auto; }
  .lp-bar .lp-code em { display: none; }
  .lp-bar .lp-code { padding: 0 10px; }
  .lp-bar .lp-code + .lp-btn { display: none; }
  .lp-bar .lp-btn { padding: 0 12px; font-size: 13px; }
}

/* ---------- polish v2: spacing, badge, balanced title, consistent controls ---------- */
.lp-card:focus { outline: none; }
.lp-center .lp-card { width: min(460px, 100%); }
.lp-center:not(.has-media) .lp-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: linear-gradient(90deg, #0071e3, #5e5ce6 55%, #bf5af2); }
.lp-t-dark .lp-card::before, .lp-t-brand .lp-card::before, .lp-t-sunset .lp-card::before { display: none; }
.lp-center .lp-body, .lp-sheet .lp-body { padding: 34px 32px 22px; }
.lp-x { top: 14px; inset-inline-end: 14px; width: 36px; height: 36px; font-size: 16px; color: var(--lp-muted); background: rgba(0,0,0,.05); transition: background .15s, color .15s; }
.lp-x:hover { background: rgba(0,0,0,.09); color: var(--lp-ink); }
.lp-x:focus { outline: none; }
.lp-x:focus-visible, .lp-btn:focus-visible, .lp-dismiss:focus-visible, .lp-code:focus-visible { outline: 2px solid var(--lp-accent); outline-offset: 2px; }
.lp-t-light .lp-x:focus-visible { outline-color: #0071e3; }
.lp-badge { width: 58px; height: 58px; margin: 0 auto 14px; border-radius: 18px; display: grid; place-items: center; font-size: 24px;
  color: #0071e3; background: linear-gradient(145deg, rgba(0,113,227,.12), rgba(94,92,230,.14)); }
.lp-t-dark .lp-badge, .lp-t-brand .lp-badge, .lp-t-sunset .lp-badge { color: #fff; background: rgba(255,255,255,.16); }
.lp-title { font-size: clamp(22px, 2.4vw + 10px, 28px); line-height: 1.18; letter-spacing: -.025em; text-wrap: balance; padding-inline: 22px; }
.lp-center:not(.has-media) .lp-title, .lp-sheet .lp-title { padding-inline: 26px; }   /* never runs under the ✕ */
.lp-text { max-width: 34ch; margin-inline: auto; margin-bottom: 20px; text-wrap: pretty; }
.lp-corner .lp-text, .lp-bar .lp-text { max-width: none; }
.lp-form input, .lp-form .lp-btn { height: 52px; min-height: 52px; }
.lp-form input { font-size: 15.5px; }
.lp-btn { gap: 8px; white-space: nowrap; font-weight: 650; }
.lp-btn i { font-size: 14px; transition: transform .2s; }
.lp-btn:hover i { transform: translateX(3px); }
[dir="rtl"] .lp-btn:hover i { transform: translateX(-3px); }
.lp-fine { margin: 12px 0 0; font-size: 12.5px; color: var(--lp-muted); display: flex; align-items: center; justify-content: center; gap: 6px; }
.lp-fine i { font-size: 11px; opacity: .8; }
.lp-corner .lp-fine { justify-content: flex-start; }
.lp-dismiss { margin-top: 14px; text-decoration: none; font-weight: 500; padding: 4px 8px; border-radius: 8px; }
.lp-dismiss:hover { text-decoration: underline; color: var(--lp-text); }
@media (max-width: 575px) {
  .lp-center .lp-body, .lp-sheet .lp-body { padding: 30px 20px 18px; }
  .lp-badge { width: 52px; height: 52px; font-size: 21px; margin-bottom: 12px; }
  .lp-title { font-size: 23px; }
  .lp-form .lp-btn { width: 100%; }
}
.lp-fine { display: block; text-align: center; text-wrap: balance; }
.lp-fine i { margin-inline-end: 4px; }
.lp-corner .lp-fine { text-align: start; }
