/* ════════════════════════════════════════════════════════════════════════
 * Pairing Path · shell.css — header, footer, asides, tiles, simulator
 * ════════════════════════════════════════════════════════════════════════ */

/* ─── Light/Dark base via class ─── */
html { background: var(--pp-ink-950); color: #e2e8f0; }
html.light { background: #f7f5ff; color: #11111f; }
html.light body { color: #11111f; }

/* ─── Page container ─── */
.pp-container { width: 100%; max-width: 1180px; margin-inline: auto; padding-inline: 1.25rem; }

/* ─── Header ─── */
.pp-header {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(11,11,24,0.65);
  border-bottom: 1px solid rgba(139,92,246,0.12);
}
html.light .pp-header { background: rgba(255,255,255,0.85); border-bottom-color: rgba(139,92,246,0.18); }
.pp-header-inner {
  display: flex; align-items: center; gap: 1rem;
  max-width: 1180px; margin-inline: auto; padding: .85rem 1.25rem;
}
.pp-brand { display: inline-flex; align-items: center; gap: .65rem; text-decoration: none; color: inherit; }
.pp-brand-mark { width: 36px; height: 36px; flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center;
  border-radius: .65rem;
  background: linear-gradient(135deg, rgba(139,92,246,.2), rgba(6,182,212,.15));
  border: 1px solid rgba(139,92,246,0.35); }
.pp-brand-mark svg { width: 24px; height: 24px; }
.pp-brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.pp-brand-name { font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 1.05rem; letter-spacing: -.01em; }
.pp-brand-tag  { font-size: .68rem; color: #94a3b8; }

.pp-nav { display: none; gap: .25rem; margin-inline: auto; }
@media (min-width: 960px) { .pp-nav { display: inline-flex; } }
.pp-navlink {
  padding: .45rem .75rem; border-radius: .55rem; font-size: .85rem; font-weight: 600;
  color: #cbd5e1; text-decoration: none; transition: background .2s, color .2s;
}
.pp-navlink:hover { background: rgba(139,92,246,.10); color: #e9d5ff; }
.pp-navlink.is-active { background: rgba(139,92,246,.18); color: #f5f3ff; }
html.light .pp-navlink { color: #475569; }
html.light .pp-navlink:hover { color: #6d28d9; }
html.light .pp-navlink.is-active { color: #6d28d9; background: rgba(139,92,246,.10); }

.pp-header-tools { display: inline-flex; align-items: center; gap: .5rem; }
.pp-icon-btn {
  width: 2.25rem; height: 2.25rem; min-width: 2.25rem;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: .55rem;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(148,163,184,0.18);
  color: #cbd5e1; cursor: pointer;
  transition: background .2s, border-color .2s, transform .2s;
  gap: .35rem; padding: 0 .55rem;
}
.pp-icon-btn:hover { background: rgba(139,92,246,.12); border-color: rgba(139,92,246,.45); transform: translateY(-1px); }
.pp-icon-btn svg { width: 18px; height: 18px; }
.pp-lang-code { font-size: .72rem; font-weight: 700; letter-spacing: .04em; }
html.light .pp-icon-btn { color: #475569; background: #fff; border-color: rgba(139,92,246,.2); }

.pp-theme-sun  { display: none; }
html.light .pp-theme-moon { display: none; }
html.light .pp-theme-sun  { display: inline-block; }

.pp-cta {
  display: inline-flex; align-items: center; padding: .55rem 1rem;
  border-radius: .65rem; font-weight: 700; font-size: .85rem;
  background: linear-gradient(135deg, #8b5cf6, #06b6d4);
  color: #fff !important; text-decoration: none;
  box-shadow: 0 6px 18px -8px rgba(139,92,246,.6);
  transition: transform .2s, box-shadow .2s;
}
.pp-cta:hover { transform: translateY(-1px); box-shadow: 0 10px 24px -8px rgba(139,92,246,.8); }

.pp-mobile-toggle { display: inline-flex; }
@media (min-width: 960px) { .pp-mobile-toggle { display: none; } }

/* Mobile menu — hidden by default everywhere, only visible when .is-open AND on mobile */
.pp-mobile-menu {
  display: none;
  flex-direction: column; gap: .25rem;
  padding: .75rem 1.25rem 1.25rem;
  border-top: 1px solid rgba(148,163,184,0.10);
}
.pp-mobile-menu.is-open { display: flex; }
@media (min-width: 960px) {
  .pp-mobile-menu, .pp-mobile-menu.is-open { display: none !important; }
}
.pp-mobile-menu a {
  padding: .65rem .8rem; border-radius: .5rem; font-weight: 600;
  text-decoration: none; color: #cbd5e1;
}
.pp-mobile-menu a:hover { background: rgba(139,92,246,.10); color: #fff; }
.pp-mobile-cta { background: linear-gradient(135deg, #8b5cf6, #06b6d4); color: #fff !important; text-align: center; margin-top: .5rem; }

/* Aside body wrapper */
.pp-aside-body { padding: 0 0 1rem; overflow-y: auto; flex: 1; }

/* Lang text wrap */
.pp-lang-text { display: flex; flex-direction: column; line-height: 1.15; flex: 1; }

/* Blacklist card */
.pp-lang-blacklist { padding: 1.25rem 1.25rem 0; }
.pp-lang-blacklist h4 { font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #f43f5e; margin-bottom: .55rem; }
.pp-blacklist-card {
  background: rgba(244,63,94,.08);
  border: 1px solid rgba(244,63,94,.3);
  border-radius: .75rem;
  padding: 1rem;
}
.pp-blacklist-head { display: flex; align-items: center; gap: .5rem; margin-bottom: .55rem; }
.pp-blacklist-flag { font-size: 1.2rem; }
.pp-blacklist-reason { font-size: .85rem; color: #fda4af; line-height: 1.55; }

/* Aside backdrop & visibility */
.pp-aside-backdrop {
  display: none;
  position: fixed; inset: 0;
  background: rgba(7,7,17,0.6);
  z-index: 60;
  backdrop-filter: blur(6px);
}
.pp-aside-backdrop.is-open { display: block; }
.pp-aside { display: flex; }
.pp-aside:not(.is-open) {
  transform: translateX(105%); opacity: 0; pointer-events: none;
}
html[dir="rtl"] .pp-aside:not(.is-open) { transform: translateX(-105%); }

/* ─── Footer ─── */
.pp-footer {
  margin-top: 6rem; padding: 3rem 0 2rem;
  border-top: 1px solid rgba(148,163,184,0.10);
  background: linear-gradient(180deg, transparent, rgba(139,92,246,.05));
}
.pp-footer-inner {
  display: grid; grid-template-columns: 1fr; gap: 2rem;
  max-width: 1180px; margin-inline: auto; padding-inline: 1.25rem;
}
@media (min-width: 720px) { .pp-footer-inner { grid-template-columns: 1.4fr 1fr 1fr 1fr; } }
.pp-footer-col { display: flex; flex-direction: column; gap: .55rem; }
.pp-footer-h { font-weight: 700; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; color: #a78bfa; margin-bottom: .25rem; }
.pp-footer-col a { color: #cbd5e1; text-decoration: none; font-size: .9rem; }
.pp-footer-col a:hover { color: #c4b5fd; }
.pp-footer-intro { color: #94a3b8; font-size: .9rem; max-width: 38ch; }
.pp-footer-credit { color: #94a3b8; font-size: .8rem; }
.pp-footer-rights { color: #64748b; font-size: .75rem; margin-top: .35rem; }

html.light .pp-footer { background: #fbfaff; }
html.light .pp-footer-col a { color: #475569; }
html.light .pp-footer-intro, html.light .pp-footer-credit { color: #64748b; }

/* ─── Aside header / body normalisation ─── */
.pp-aside-header { display: flex; align-items: center; justify-content: space-between;
  padding: 1.1rem 1.25rem; border-bottom: 1px solid rgba(148,163,184,.12); }
.pp-aside-header h3 { font-family: 'Space Grotesk', sans-serif; font-size: 1.05rem; font-weight: 700; }
.pp-aside-help { padding: 0 1.25rem; color: #94a3b8; font-size: .85rem; margin: 1rem 0 .75rem; }
.pp-aside-note { padding: 1rem 1.25rem 1.25rem; color: #64748b; font-size: .75rem; }
.pp-aside .pp-lang-grid { padding: 0 1.25rem 1.25rem; }
.pp-views-rows { padding: 0 1.25rem; display: flex; flex-direction: column; gap: .5rem; }
.pp-views-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: .85rem 1rem;
  background: rgba(139,92,246,.08); border: 1px solid rgba(139,92,246,.2);
  border-radius: .65rem; font-weight: 600;
}
.pp-views-row strong { font-variant-numeric: tabular-nums; font-size: 1.1rem; color: #c4b5fd; }

/* ─── Lang flag ─── */
.pp-lang-flag { font-size: 1.35rem; }
.pp-lang-native { font-weight: 700; flex: 1; }
.pp-lang-name { font-size: .75rem; color: #94a3b8; }

/* ─── Hero / orbs / grid bg helpers ─── */
.pp-hero { position: relative; padding: 5rem 0 4rem; overflow: hidden; }
.pp-hero-grid {
  position: absolute; inset: 0; pointer-events: none; opacity: .35;
  background-image:
    linear-gradient(rgba(139,92,246,.10) 1px, transparent 1px),
    linear-gradient(90deg, rgba(139,92,246,.10) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: radial-gradient(ellipse at center, black 30%, transparent 75%);
}
.pp-orb {
  position: absolute; border-radius: 9999px; filter: blur(80px); opacity: .55;
  pointer-events: none;
}
.pp-orb-1 { width: 420px; height: 420px; background: radial-gradient(circle, #8b5cf6, transparent 70%); top: -100px; left: -80px; }
.pp-orb-2 { width: 380px; height: 380px; background: radial-gradient(circle, #06b6d4, transparent 70%); top: 80px; right: -100px; }
.pp-orb-3 { width: 320px; height: 320px; background: radial-gradient(circle, #ec4899, transparent 70%); bottom: -120px; left: 40%; }

.pp-chip {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .35rem .85rem; border-radius: 999px;
  background: rgba(139,92,246,.12); border: 1px solid rgba(139,92,246,.3);
  color: #c4b5fd; font-size: .78rem; font-weight: 600;
}
.pp-chip::before {
  content: ""; width: 6px; height: 6px; border-radius: 9999px;
  background: #06b6d4; box-shadow: 0 0 8px #06b6d4;
}

/* ─── Glass card ─── */
.glass {
  background: rgba(17,17,31,0.55);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(148,163,184,.12);
  border-radius: 1rem;
}
html.light .glass { background: rgba(255,255,255,.7); border-color: rgba(139,92,246,.18); }

/* ─── Buttons ─── */
.btn-primary {
  display: inline-flex; align-items: center; gap: .55rem;
  padding: .8rem 1.4rem; border-radius: .75rem; font-weight: 700; font-size: .92rem;
  background: linear-gradient(135deg, #8b5cf6, #06b6d4);
  color: #fff; text-decoration: none; border: 0; cursor: pointer;
  box-shadow: 0 14px 30px -10px rgba(139,92,246,.55);
  transition: transform .2s, box-shadow .2s;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 18px 40px -10px rgba(139,92,246,.8); }
.btn-ghost {
  display: inline-flex; align-items: center; gap: .55rem;
  padding: .8rem 1.4rem; border-radius: .75rem; font-weight: 700; font-size: .92rem;
  background: rgba(255,255,255,.04); border: 1px solid rgba(139,92,246,.35);
  color: inherit; text-decoration: none; cursor: pointer;
  transition: background .2s, border-color .2s, transform .2s;
}
.btn-ghost:hover { background: rgba(139,92,246,.1); border-color: rgba(139,92,246,.55); transform: translateY(-1px); }

/* ─── Tiles (snapshot) ─── */
.pp-tile {
  padding: 1.1rem 1.25rem; display: flex; flex-direction: column; gap: .25rem;
  min-height: 92px;
}
.pp-tile-v { font-family: 'Space Grotesk', sans-serif; font-size: 1.5rem; font-weight: 700;
  background: linear-gradient(135deg, #8b5cf6, #06b6d4); -webkit-background-clip: text; background-clip: text; color: transparent;
  font-variant-numeric: tabular-nums;
}
.pp-tile-k { font-size: .78rem; color: #94a3b8; }

/* ─── Slot grid ─── */
.pp-slot {
  padding: 1rem; display: flex; flex-direction: column; gap: .15rem;
  text-align: center; transition: transform .2s, border-color .2s;
}
.pp-slot:hover { transform: translateY(-2px); border-color: rgba(139,92,246,.5); }
.pp-slot-n { font-size: .72rem; color: #a78bfa; font-weight: 700; letter-spacing: .08em; }
.pp-slot-amount { font-family: 'Space Grotesk', sans-serif; font-size: 1.4rem; font-weight: 700; color: #67e8f9; }
.pp-slot-rev { font-size: .75rem; color: #94a3b8; }
.pp-slot-net { color: #6ee7b7; font-size: .9rem; margin-top: .35rem; }
.pp-slot-aff { font-size: .72rem; color: #f9a8d4; }

/* ─── Reveal on scroll ─── */
[data-rv] { opacity: 0; transform: translateY(20px); transition: opacity .8s ease, transform .8s cubic-bezier(.2,.8,.2,1);
  transition-delay: var(--d, 0ms); }
[data-rv="zoom"] { transform: scale(.92); }
[data-rv="left"] { transform: translateX(-30px); }
[data-rv="right"]{ transform: translateX(30px); }
[data-rv].rv-in { opacity: 1; transform: none; }

/* ─── Misc ─── */
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .78rem; color: #94a3b8; }
.pp-mute { color: #94a3b8; }
.small { font-size: .8rem; }
.db-scroll { overflow-x: auto; max-width: 100%; }
.db-scroll .db-table { min-width: 720px; }

/* ─── Section helpers ─── */
.pp-section { padding: 4rem 0; }
.pp-section-eyebrow { color: #a78bfa; font-size: .8rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.pp-h1 { font-family: 'Space Grotesk', sans-serif; font-size: clamp(2.2rem, 5vw, 3.6rem); font-weight: 700; letter-spacing: -.02em; line-height: 1.05; }
.pp-h2 { font-family: 'Space Grotesk', sans-serif; font-size: clamp(1.6rem, 3vw, 2.4rem); font-weight: 700; letter-spacing: -.015em; line-height: 1.15; }
.pp-h3 { font-family: 'Space Grotesk', sans-serif; font-size: 1.2rem; font-weight: 700; }
.pp-lead { font-size: 1.05rem; color: #cbd5e1; max-width: 60ch; }
html.light .pp-lead { color: #475569; }

/* ─── Stagger reveal helper ─── */
.stagger > * { transition-delay: 0ms; }
.stagger > *:nth-child(1){ transition-delay: 60ms; }
.stagger > *:nth-child(2){ transition-delay: 120ms; }
.stagger > *:nth-child(3){ transition-delay: 180ms; }
.stagger > *:nth-child(4){ transition-delay: 240ms; }
.stagger > *:nth-child(5){ transition-delay: 300ms; }
.stagger > *:nth-child(6){ transition-delay: 360ms; }

/* ─── Simulator ─── */
.pp-sim-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: .75rem; margin-bottom: 1rem; }
@media (min-width: 720px) { .pp-sim-stats { grid-template-columns: repeat(4, 1fr); } }

/* ─── RTL flip nav order ─── */
html[dir="rtl"] .pp-header-inner { flex-direction: row-reverse; }
html[dir="rtl"] .pp-mobile-menu { text-align: right; }
