/* ============================================================
   PAYWALL — Full-screen App Store style
   ============================================================ */

.paywall-fullscreen {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: none;
  flex-direction: column;
  background: #0A0A0A;
  opacity: 0;
  transition: opacity 0.3s ease;
  overflow: hidden;
}

.paywall-fullscreen::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 40% at 50% -10%, rgba(25,230,57,0.18) 0%, transparent 70%),
    radial-gradient(ellipse 50% 30% at 10% 60%,  rgba(25,230,57,0.07) 0%, transparent 60%),
    radial-gradient(ellipse 40% 25% at 90% 80%,  rgba(25,230,57,0.06) 0%, transparent 60%);
  z-index: 0;
}

.paywall-fullscreen > * {
  position: relative;
  z-index: 1;
}

.paywall-fullscreen.active {
  display: flex;
  opacity: 1;
}

/* Slide-in from bottom variant */
.paywall-fullscreen.paywall-slide-bottom {
  transform: translateY(100%);
  transition: opacity 0.3s ease, transform 0.38s cubic-bezier(0.32,0.72,0,1);
}

.paywall-fullscreen.paywall-slide-bottom.active {
  transform: translateY(0);
  opacity: 1;
}

.paywall-open {
  overflow: hidden !important;
}

/* ── Header ─────────────────────────────────────────────────── */

.pw-header {
  flex-shrink: 0;
  text-align: center;
  padding: 20px 24px 16px;
  position: relative;
}

.pw-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.08);
  border: none;
  border-radius: 50%;
  color: #888;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.pw-close:active {
  background: rgba(255, 255, 255, 0.15);
}

.pw-logo {
  margin-bottom: 12px;
}

.pw-title {
  font-family: "Rajdhani", sans-serif;
  font-size: 1.8rem;
  font-weight: 700;
  color: #19E639;
  margin: 0 0 4px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
}

.pw-subtitle {
  font-size: 0.9rem;
  color: #A3A39E;
  margin: 0;
}

/* ── Scrollable area ────────────────────────────────────────── */

.pw-scroll {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 0 24px 24px;
}

/* ── Features ───────────────────────────────────────────────── */

.pw-features {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 28px;
}

.pw-feature {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 14px;
}

.pw-feature-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(204, 180, 180, 0.05);
  border-radius: 10px;
}

.pw-feature-text {
  flex: 1;
  min-width: 0;
}

.pw-feature-title {
  font-weight: 700;
  font-size: 0.9rem;
  color: #F5F5F0;
  margin-bottom: 2px;
}

.pw-feature-desc {
  font-size: 0.78rem;
  color: #888;
  line-height: 1.3;
}

/* ── Pricing Cards ─────────────────────────────────────────── */

.pw-pricing-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 28px;
}

.pw-plan-card {
  position: relative;
  padding: 20px 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  -webkit-tap-highlight-color: transparent;
}

.pw-plan-card.pw-plan-selected,
.pw-plan-card:active {
  border-color: #19E639;
  background: rgba(25, 230, 57, 0.05);
}

.pw-plan-recommended {
  border-color: rgba(25, 230, 57, 0.4);
}

.pw-plan-badge-rec {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  padding: 3px 10px;
  background: linear-gradient(135deg, #19E639, #0fba2d);
  color: #0f0f1a;
  font-size: 0.65rem;
  font-weight: 800;
  border-radius: 20px;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

.pw-plan-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: #A3A39E;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.pw-plan-old {
  font-size: 0.75rem;
  color: #FF4444;
  text-decoration: line-through;
  margin-bottom: 2px;
}

/* --- Price strike animation --- */
.pw-price-anim-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.pw-price-old-anim {
  font-size: 1rem;
  color: #FF4444;
  position: relative;
  display: inline-block;
}

.pw-price-old-anim::after {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  height: 2px;
  width: 0;
  background: #FF4444;
  transform: translateY(-50%);
}

.pw-price-new-anim {
  opacity: 0;
  transform: scale(0.7);
  transition: opacity 0.15s ease, transform 0.15s ease;
}

@keyframes pw-shake {
  0%, 100% { transform: translateX(0); }
  20%       { transform: translateX(-4px); }
  40%       { transform: translateX(4px); }
  60%       { transform: translateX(-3px); }
  80%       { transform: translateX(3px); }
}

@keyframes pw-strike {
  from { width: 0; }
  to   { width: 100%; }
}

.pw-price-old-anim.shaking {
  animation: pw-shake 0.35s ease;
}

.pw-price-old-anim.struck::after {
  animation: pw-strike 0.25s ease forwards;
}

.pw-price-new-anim.visible {
  opacity: 1;
  transform: scale(1);
  color: #19E639;
}

.pw-plan-price {
  font-family: "Rajdhani", sans-serif;
  font-size: 1.6rem;
  font-weight: 700;
  color: #F5F5F0;
  line-height: 1.2;
}

.pw-plan-period {
  font-size: 0.85rem;
  font-weight: 400;
  color: #A3A39E;
}

.pw-plan-note {
  font-size: 0.72rem;
  color: #666;
  margin-top: 6px;
}

/* ── Reviews marquee ────────────────────────────────────────── */

.pw-reviews-section {
  margin-bottom: 20px;
}

.pw-reviews-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: #A3A39E;
  text-align: center;
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.pw-reviews-track {
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent 0%, #000 10%, #000 90%, transparent 100%);
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 10%, #000 90%, transparent 100%);
}

.pw-reviews-scroll {
  display: flex;
  gap: 12px;
  animation: pwMarquee 30s linear infinite;
  width: max-content;
}

.pw-reviews-scroll:hover {
  animation-play-state: paused;
}

@keyframes pwMarquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.pw-review-card {
  flex-shrink: 0;
  width: 220px;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
}

.pw-review-stars {
  font-size: 0.75rem;
  color: #19E639;
  margin-bottom: 6px;
  letter-spacing: 1px;
}

.pw-review-text {
  font-size: 0.78rem;
  color: #ccc;
  line-height: 1.4;
  margin-bottom: 6px;
}

.pw-review-name {
  font-size: 0.7rem;
  color: #666;
  font-weight: 600;
}

/* ── Legal ──────────────────────────────────────────────────── */

.pw-legal {
  font-size: 0.7rem;
  color: #555;
  text-align: center;
  line-height: 1.5;
  padding-bottom: 8px;
}

.pw-legal p {
  margin: 0 0 10px;
}

.pw-legal-links {
  margin-top: 8px;
}

.pw-legal-links a {
  color: #888;
  text-decoration: underline;
}

/* ── CTA sticky bottom ──────────────────────────────────────── */

.pw-cta-container {
  flex-shrink: 0;
  padding: 16px 24px;
  padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  background: linear-gradient(0deg, #0A0A0A 70%, transparent 100%);
  text-align: center;
}

.pw-cta-btn {
  width: 100%;
  padding: 16px 24px;
  background: linear-gradient(135deg, #19E639 0%, #0fba2d 100%);
  color: #0f0f1a;
  font-family: "Rajdhani", sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  border: none;
  border-radius: 14px;
  cursor: pointer;
  box-shadow: 0 4px 24px rgba(25, 230, 57, 0.3);
  transition: transform 0.15s, box-shadow 0.15s;
  -webkit-tap-highlight-color: transparent;
}

.pw-cta-btn:active {
  transform: scale(0.97);
  box-shadow: 0 2px 12px rgba(25, 230, 57, 0.2);
}

.pw-restore {
  display: block;
  width: 100%;
  padding: 10px;
  margin-top: 8px;
  background: none;
  border: none;
  color: #666;
  font-size: 0.8rem;
  cursor: pointer;
  text-decoration: underline;
  -webkit-tap-highlight-color: transparent;
}

/* ── Premium badge (used on locked features elsewhere) ────── */

.premium-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  background: linear-gradient(135deg, rgba(25, 230, 57, 0.15), rgba(15, 186, 45, 0.08));
  border: 1px solid rgba(25, 230, 57, 0.35);
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 600;
  color: #19E639;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
}

.premium-badge::before {
  content: "";
  display: inline-block;
  width: 10px;
  height: 10px;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='currentColor'%3E%3Cpolygon points='13 2 3 14 12 14 11 22 21 10 12 10 13 2'/%3E%3C/svg%3E") center/contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='currentColor'%3E%3Cpolygon points='13 2 3 14 12 14 11 22 21 10 12 10 13 2'/%3E%3C/svg%3E") center/contain no-repeat;
}

/* Lock overlay for premium sections */
.premium-locked {
  position: relative;
  pointer-events: none;
  opacity: 0.4;
  filter: blur(2px);
}

.premium-locked::after {
  content: "";
  position: absolute;
  inset: 0;
  background: transparent;
  pointer-events: all;
  cursor: pointer;
  z-index: 5;
}

/* ── Exit-Intent Promo ─────────────────────────────────────── */

.pw-exit-promo {
  position: fixed;
  inset: 0;
  z-index: 10001;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  padding: 24px;
}

.pw-exit-promo.active {
  display: flex;
}

.pw-exit-promo-card {
  width: 100%;
  max-width: 320px;
  padding: 32px 24px;
  background: #0A0A0A;
  border: 1px solid rgba(25, 230, 57, 0.35);
  border-radius: 20px;
  text-align: center;
  box-shadow: 0 0 40px rgba(25,230,57,0.12), inset 0 0 30px rgba(25,230,57,0.04);
}

.pw-exit-promo-title {
  font-family: "Rajdhani", sans-serif;
  font-size: 1.8rem;
  font-weight: 700;
  color: #19E639;
  margin-bottom: 8px;
}

.pw-exit-promo-subtitle {
  font-size: 0.9rem;
  color: #A3A39E;
  margin-bottom: 20px;
}

.pw-exit-promo-price {
  margin-bottom: 8px;
}

.pw-exit-promo-old {
  font-size: 1rem;
  color: #FF4444;
  text-decoration: line-through;
  margin-right: 10px;
}

.pw-exit-promo-new {
  font-family: "Rajdhani", sans-serif;
  font-size: 2.2rem;
  font-weight: 700;
  color: #19E639;
}

.pw-exit-promo-savings {
  font-size: 0.8rem;
  color: #19E639;
  margin-bottom: 24px;
  font-weight: 600;
}

.pw-exit-promo-cta {
  margin-bottom: 12px;
}

.pw-exit-promo-dismiss {
  display: block;
  width: 100%;
  padding: 10px;
  background: none;
  border: none;
  color: #666;
  font-size: 0.8rem;
  cursor: pointer;
  text-decoration: underline;
  -webkit-tap-highlight-color: transparent;
}
