/* premium-pitch.css — Pin + Mid-card shared styles. pp- namespace.
 * See docs/superpowers/specs/2026-04-14-premium-pin-and-midcard-design.md
 * Ported from mockup: .superpowers/brainstorm/74800-1776213579/content/option-a-v3.html
 */

/* Tokens not defined in homepage-v7.css — scoped fallbacks for premium-pitch.
 * Inherits from homepage-v7.css: --parchment, --parchment-dk, --forest, --forest-dk,
 * --gold, --ink, --r-sm, --r-md, --r-lg, --r-full, --shadow-sm, --shadow-md, --shadow-lg.
 */
:root {
  --pp-parchment-warm: #f6edd5;
  --pp-forest-lt: #e8f0eb;
  --pp-forest-wash: #f1f6f3;
  --pp-forest-wash-warm: #f3f6ef;
  --pp-gold-dk: #b8874e;
  --pp-ink-80: rgba(27,25,24,0.80);
  --pp-ink-60: rgba(27,25,24,0.60);
  --pp-ink-40: rgba(27,25,24,0.40);
  --pp-ink-20: rgba(27,25,24,0.12);
  --pp-rule: rgba(27,25,24,0.08);
}

/* ============================================
   PIN — inline rich pitch, #1 match spotlight
   ============================================ */
.pp-pin {
  background: linear-gradient(135deg, var(--parchment) 0%, var(--pp-parchment-warm) 100%);
  border: 2px solid var(--forest);
  border-radius: var(--r-lg);
  padding: 22px 24px 0;
  margin-bottom: 20px;
  box-shadow: 0 4px 24px rgba(13,79,60,0.13);
  position: relative;
  overflow: hidden;
  opacity: 0;
  transform: translateY(12px) scale(0.985);
  animation: pinEnter 0.5s cubic-bezier(0.2, 0.9, 0.3, 1.1) 1.2s forwards;
}
@keyframes pinEnter {
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.pp-pin::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--forest) 0%, var(--gold) 50%, var(--forest) 100%);
}

.pp-head-row {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  margin-bottom: 14px;
}
.pp-flag {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--forest); color: var(--parchment);
  padding: 5px 10px 5px 8px; border-radius: var(--r-full);
  font-size: 10px; font-weight: 700; letter-spacing: 0.07em; text-transform: uppercase;
}
.pp-flag-gem {
  width: 14px; height: 14px; background: var(--gold); border-radius: 3px;
  display: flex; align-items: center; justify-content: center;
  font-size: 9px; color: var(--forest-dk);
}
.pp-flag-sep { opacity: 0.5; margin: 0 2px; }
.pp-flag-sub { opacity: 0.85; font-weight: 600; }

.pp-close {
  background: transparent; border: none; color: var(--pp-ink-40);
  font-size: 22px; cursor: pointer; padding: 4px; line-height: 1;
  transition: color 0.15s;
}
.pp-close:hover { color: var(--ink); }

.pp-subhead {
  font-size: 12px; color: var(--pp-ink-60);
  margin-bottom: 14px; letter-spacing: -0.005em; font-weight: 500;
}

.pp-top {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 14px;
  padding-bottom: 14px; border-bottom: 1px solid rgba(13,79,60,0.14);
}
.pp-top > .pp-top-info { min-width: 0; flex: 1; }
.pp-title { font-size: 19px; font-weight: 700; letter-spacing: -0.02em; color: var(--ink); margin-bottom: 3px; line-height: 1.25; }
.pp-org { font-size: 12px; color: var(--pp-ink-60); }
.pp-amount-big {
  background: var(--forest); color: var(--parchment);
  padding: 8px 14px; border-radius: var(--r-sm);
  font-size: 15px; font-weight: 700; white-space: nowrap;
  flex-shrink: 0;
}

/* Hierarchical grid: 1 unlocked hero + 3 locked companions */
.pp-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 10px;
  margin-bottom: 16px;
}
.pp-cell {
  background: rgba(255,255,255,0.65);
  border: 1px solid var(--pp-rule);
  border-radius: var(--r-sm);
  padding: 11px 13px;
  position: relative;
  min-height: 64px;
}
.pp-cell.unlocked {
  background: #fff;
  border: 2px solid var(--forest);
  box-shadow: 0 2px 8px rgba(13,79,60,0.12);
}
.pp-cell.unlocked::before {
  content: '✓';
  position: absolute; top: -8px; right: -8px;
  width: 20px; height: 20px;
  background: var(--forest); color: var(--parchment);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700;
  box-shadow: 0 2px 6px rgba(13,79,60,0.25);
}
.pp-cell-lbl {
  font-size: 10px; color: var(--pp-ink-60); text-transform: uppercase;
  letter-spacing: 0.06em; font-weight: 600; margin-bottom: 4px;
}
.pp-cell.unlocked .pp-cell-lbl { color: var(--forest); }
.pp-cell-val { font-size: 15px; font-weight: 700; color: var(--ink); letter-spacing: -0.01em; }
.pp-cell-val .pp-cell-mini { font-size: 11px; font-weight: 500; color: var(--pp-ink-60); margin-left: 4px; }
.pp-cell.locked .pp-cell-val { filter: blur(5px); user-select: none; opacity: 0.7; }
/* Dot meter inside locked cells — visible shape through blur adds perceived value */
.pp-cell .vd-meter { display: flex; gap: 3px; margin-top: 4px; }
.pp-cell .vd-dot { width: 6px; height: 6px; border-radius: 50%; background: rgba(0,0,0,0.12); }
.pp-cell .vd-dot--green { background: var(--forest, #2d6a4f); }
.pp-cell .vd-dot--amber { background: #d97706; }
.pp-cell .vd-dot--red { background: #dc2626; }
.pp-cell.locked {
  position: relative;
  overflow: hidden;
  max-height: 72px;
}
.pp-cell.locked::after {
  content: '🔒';
  position: absolute; top: 50%; right: 10px;
  transform: translateY(-50%);
  font-size: 13px;
  opacity: 0.65;
}
/* Subtle shimmer on locked cells */
.pp-cell.locked .pp-shimmer {
  position: absolute; inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(13,79,60,0.08) 50%, transparent 70%);
  animation: shimmer 3s ease-in-out 2;
  pointer-events: none;
}
@keyframes shimmer {
  0%, 100% { transform: translateX(-100%); }
  50% { transform: translateX(100%); }
}
.pp-cell.locked:nth-of-type(3) .pp-shimmer { animation-delay: 0.8s; }
.pp-cell.locked:nth-of-type(4) .pp-shimmer { animation-delay: 1.6s; }

/* Score visual (small bar inside unlocked cell) */
.pp-score-bar {
  margin-top: 6px;
  height: 4px;
  background: rgba(13,79,60,0.12);
  border-radius: 2px;
  overflow: hidden;
}
.pp-score-bar-fill {
  height: 100%;
  width: 94%;
  background: var(--forest);
  border-radius: 2px;
}

.pp-cta-row {
  background: var(--forest); color: var(--parchment);
  margin: 0 -24px; padding: 16px 24px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  border-radius: 0 0 var(--r-lg) var(--r-lg);
}
.pp-cta-copy { font-size: 13px; font-weight: 600; line-height: 1.4; flex: 1; }
.pp-cta-copy .pp-cta-sub { font-size: 11px; opacity: 0.78; font-weight: 500; display: block; margin-top: 3px; }
.pp-cta-btn {
  background: var(--parchment); color: var(--forest-dk);
  padding: 12px 20px; border-radius: var(--r-full);
  font-weight: 700; font-size: 13px; white-space: nowrap;
  border: none; cursor: pointer; font-family: inherit;
  transition: all 0.2s;
  box-shadow: 0 2px 0 rgba(0,0,0,0.06);
}
.pp-cta-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.18);
}
.pp-cta-btn:active { transform: translateY(0); }

/* Mobile trust line (hidden on desktop) */
.pp-cta-mobile-trust { display: none; }

/* Pin interstitial — confirmation overlay on card body click */
.pp-interstitial {
  position: absolute; inset: 0; z-index: 10;
  background: rgba(13,79,60,0.92);
  border-radius: var(--r-lg);
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
  animation: ppFadeIn 0.2s ease-out;
}
@keyframes ppFadeIn { from { opacity: 0; } to { opacity: 1; } }
.pp-interstitial-card {
  text-align: center; max-width: 340px; color: var(--parchment);
}
.pp-interstitial-head {
  font-size: 18px; font-weight: 700; margin-bottom: 10px; letter-spacing: -0.02em;
}
.pp-interstitial-body {
  font-size: 14px; line-height: 1.55; opacity: 1; color: rgba(255,255,255,0.95); margin: 0 0 12px;
}
.pp-interstitial-price {
  font-size: 12px; opacity: 0.85; margin-bottom: 16px; font-weight: 500;
}
.pp-interstitial-go {
  display: block; width: 100%;
  background: var(--parchment); color: var(--forest-dk);
  padding: 13px 20px; border-radius: var(--r-full);
  font-weight: 700; font-size: 14px;
  border: none; cursor: pointer; font-family: inherit;
  margin-bottom: 10px;
  transition: transform 0.15s, box-shadow 0.15s;
}
.pp-interstitial-go:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}
.pp-interstitial-back {
  background: transparent; border: none; color: var(--parchment);
  font-size: 13px; cursor: pointer; opacity: 0.75;
  font-family: inherit; padding: 6px 12px;
  transition: opacity 0.15s;
}
.pp-interstitial-back:hover { opacity: 1; }

/* ============================================
   MID-CARD — between Top Picks and Also Explore
   ============================================ */
.pp-midcard {
  background: linear-gradient(180deg, var(--pp-forest-wash) 0%, var(--pp-forest-wash-warm) 100%);
  border: 1px solid rgba(13,79,60,0.15);
  border-left: 4px solid var(--forest);
  border-radius: var(--r-md);
  padding: 26px 28px;
  margin: 22px 0 26px;
  position: relative;
  box-shadow: var(--shadow-sm);
}
.pp-midcard-head-row {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 12px;
}
.pp-midcard-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--forest); font-weight: 700; margin-bottom: 10px;
}
.pp-midcard-eyebrow::before {
  content: '';
  display: inline-block;
  width: 14px; height: 2px; background: var(--forest);
}
.pp-midcard-close {
  background: transparent; border: none; color: var(--pp-ink-40);
  font-size: 22px; cursor: pointer; padding: 4px; line-height: 1;
}
.pp-midcard-close:hover { color: var(--ink); }
.pp-midcard-h {
  font-size: 24px; font-weight: 700; letter-spacing: -0.02em;
  color: var(--ink); line-height: 1.18; margin-bottom: 10px;
  max-width: 560px;
}
.pp-midcard-body {
  font-size: 14px; color: var(--pp-ink-80); line-height: 1.55;
  margin-bottom: 20px; max-width: 580px;
}
.pp-midcard-list {
  list-style: none; padding: 0; margin: 0 0 22px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 14px 24px;
}
.pp-midcard-list li {
  display: flex; align-items: flex-start; gap: 12px;
}
.pp-midcard-icon {
  width: 32px; height: 32px;
  flex-shrink: 0;
  background: #fff;
  border: 1.5px solid var(--forest);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px;
  color: var(--forest);
}
.pp-midcard-bullet-hd {
  font-size: 13px; font-weight: 700; color: var(--ink); margin-bottom: 2px; letter-spacing: -0.005em;
}
.pp-midcard-bullet-sub {
  font-size: 12px; color: var(--pp-ink-60); line-height: 1.4;
}
.pp-midcard-anchor {
  background: rgba(212, 165, 116, 0.12);
  border: 1px solid rgba(212, 165, 116, 0.45);
  border-radius: var(--r-sm);
  padding: 12px 16px;
  font-size: 13px;
  color: var(--pp-ink-80);
  margin-bottom: 20px;
  display: flex; align-items: center; gap: 12px;
  line-height: 1.45;
}
.pp-midcard-anchor-ico {
  flex-shrink: 0;
  width: 28px; height: 28px;
  background: var(--gold); color: var(--forest-dk);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 800;
}
.pp-midcard-anchor strong { color: var(--forest-dk); font-weight: 800; }
.pp-midcard-cta-row {
  display: flex; align-items: center; gap: 16px;
}
.pp-midcard-cta-btn {
  background: var(--forest); color: var(--parchment);
  padding: 13px 24px; border-radius: var(--r-full);
  font-weight: 700; font-size: 14px; border: none; cursor: pointer; font-family: inherit;
  transition: all 0.2s;
  box-shadow: 0 2px 0 rgba(0,0,0,0.08);
}
.pp-midcard-cta-btn:hover {
  transform: translateY(-1px);
  background: var(--forest-dk);
  box-shadow: 0 6px 16px rgba(13,79,60,0.28);
}
.pp-midcard-cta-btn:active { transform: translateY(0); }
.pp-midcard-trust { font-size: 12px; color: var(--pp-ink-60); font-weight: 500; }

/* ============================================
   MOBILE (<= 680px)
   Mid-card hides entirely. Pin simplifies:
   drop subhead, shorten flag, trim org, 2-col grid, stacked CTA.
   ============================================ */
@media (max-width: 680px) {
  .pp-midcard { display: none; }

  .pp-pin { padding: 18px 16px 0; }
  .pp-head-row { margin-bottom: 10px; }

  .pp-subhead { display: none; }
  .pp-flag-sep, .pp-flag-sub { display: none; }
  .pp-org-ext { display: none; }

  .pp-top { margin-bottom: 10px; padding-bottom: 12px; }
  .pp-title { font-size: 17px; }
  .pp-amount-big { font-size: 13px; padding: 6px 10px; }

  /* Mobile grid: 1 hero + 2 locked cells (Competitiveness dropped) */
  .pp-grid {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "hero hero"
      "a b";
    gap: 8px;
    margin-bottom: 14px;
  }
  .pp-cell.unlocked { grid-area: hero; }
  .pp-cell-desktop-only { display: none !important; }
  .pp-cell.locked { padding: 10px 12px; min-height: 52px; }
  .pp-cell-lbl { font-size: 10px; letter-spacing: 0.05em; }
  .pp-cell-val { font-size: 13px; }
  .pp-cell.locked::after { font-size: 12px; right: 8px; }

  /* CTA row stacks vertically on mobile — trust line below the button */
  .pp-cta-row {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    gap: 10px;
    margin: 0 -16px;
    padding: 14px 16px 14px;
  }
  .pp-cta-copy { font-size: 13px; font-weight: 600; }
  .pp-cta-copy .pp-cta-sub { display: none; }
  .pp-cta-btn {
    width: 100%;
    padding: 14px 20px;
    font-size: 14px;
  }
  .pp-cta-mobile-trust {
    display: block;
    font-size: 11px;
    opacity: 0.78;
    font-weight: 500;
    margin-top: 2px;
  }
}

/* ============================================
   Reduced motion — disable entrance + shimmer
   ============================================ */
@media (prefers-reduced-motion: reduce) {
  .pp-pin {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
  .pp-shimmer {
    animation: none !important;
    display: none !important;
  }
}
