/* ==========================================================================
   PNP Affiliate Hub — PNP Brand Theme v0.1.1
   Scoped to #pnp-affiliate-hub to avoid theme collisions.
   Matches practicallynatty.com / existing /affiliate-account/ palette:
     dark navy-black + muted gold + garnet CTAs + warm off-white text.
   Colors audited from the live site (homepage + affiliate area).
   ========================================================================== */

/* ── Google Fonts (DM Sans matches existing SliceWP affiliate dark theme) ── */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&display=swap');

/* ── Design tokens (DARK is default — matches PNP brand) ─────────────────── */
#pnp-affiliate-hub {
  /* Surfaces — deep navy-black like /affiliate-account/ */
  --bg:               #0f1117;
  --bg-elevated:      #1a1d27;
  --bg-subtle:        #222535;

  /* Text — warm off-white from affiliate area */
  --text:             #f0ede8;
  --text-soft:        #c4bfb6;
  --text-muted:       #9a9585;

  /* Borders — translucent gold from affiliate area */
  --border:           rgba(187, 150, 95, 0.18);
  --border-strong:    rgba(187, 150, 95, 0.32);
  --shadow-sm:        0 2px 10px rgba(0, 0, 0, 0.35);
  --shadow-md:        0 10px 30px rgba(0, 0, 0, 0.45);

  /* Gold accent - matches the banner bronze #BB965F sampled from the PNP LABS artwork */
  --accent-gold:        #BB965F;
  --accent-gold-hover:  #D8BC92;
  --accent-gold-soft:   rgba(187, 150, 95, 0.12);
  --accent-gold-dim:    #8F7248;

  /* Garnet — primary CTA color matching affiliate area */
  --accent-garnet:        #7c1c2e;
  --accent-garnet-deep:   #5a1220;
  --accent-garnet-soft:   rgba(124, 28, 46, 0.20);
  --accent-garnet-glow:   rgba(124, 28, 46, 0.30);

  /* Status pills */
  --status-pending:   #e8b32b;
  --status-approved:  #34d399;
  --status-paid:      #60a5fa;
  --status-rejected:  #6b7280;

  /* Backwards-compat coral aliases (very few callsites; map to gold) */
  --accent-coral:      #BB965F;
  --accent-coral-soft: rgba(187, 150, 95, 0.12);

  /* Spacing — 4-pt grid */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-16: 64px;
  --space-20: 80px;

  /* Radii — affiliate area uses 8–12px not pill-everywhere */
  --radius-sm:   8px;
  --radius-md:   12px;
  --radius-lg:   16px;
  --radius-xl:   24px;
  --radius-pill: 9999px;

  /* Motion */
  --ease-out:       cubic-bezier(0.16, 1, 0.3, 1);
  --ease-celebrate: cubic-bezier(0.34, 1.56, 0.64, 1);
  --dur-fast:      150ms;
  --dur-base:      250ms;
  --dur-slow:      400ms;
  --dur-celebrate: 600ms;

  /* Typography — DM Sans matches the existing affiliate dark theme */
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 15px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ── Light mode — opt-in via toggle (PNP brand is dark-first) ─────────────── */
#pnp-affiliate-hub[data-theme="light"] {
  --bg:               #f7f4eb;
  --bg-elevated:      #ffffff;
  --bg-subtle:        #efeae0;
  --text:             #1a1714;
  --text-soft:        #4a443c;
  --text-muted:       #7a7368;
  --border:           rgba(124, 92, 36, 0.16);
  --border-strong:    rgba(124, 92, 36, 0.28);
  --shadow-sm:        0 2px 8px rgba(26, 23, 20, 0.06);
  --shadow-md:        0 10px 26px rgba(26, 23, 20, 0.10);
  --accent-gold:      #8F7248;
  --accent-gold-hover:#BB965F;
  --accent-gold-soft: rgba(187, 150, 95, 0.16);
  --accent-garnet-soft: rgba(124, 28, 46, 0.12);
  --status-pending:   #b45309;
  --status-approved:  #047857;
  --status-paid:      #0369a1;
  --status-rejected:  #6b7280;
}

/* ── Reduced motion ────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  #pnp-affiliate-hub * {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}

/* ── Layout container ──────────────────────────────────────────────────── */
.pnp-hub-container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 var(--space-6);
}

@media (max-width: 767px) {
  .pnp-hub-container { padding: 0 var(--space-4); }
}

@media (max-width: 374px) {
  .pnp-hub-container { padding: 0 12px; }
  #pnp-affiliate-hub { font-size: 14px; }
}

/* ── Sticky Header ─────────────────────────────────────────────────────── */
.pnp-hub-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: 56px;
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border);
  transition: box-shadow var(--dur-fast) var(--ease-out);
  display: flex;
  align-items: center;
}

.pnp-hub-header.scrolled {
  box-shadow: var(--shadow-sm);
}

.pnp-hub-header-inner {
  display: flex;
  align-items: center;
  /* logo removed - space-between would park the controls on the LEFT */
  justify-content: flex-end;
  width: 100%;
}

.pnp-hub-logo {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.01em;
}

.pnp-hub-logo span {
  color: var(--accent-gold);
}

.pnp-hub-header-right {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.pnp-hub-theme-toggle {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-soft);
  padding: var(--space-2);
  border-radius: var(--radius-sm);
  font-size: 18px;
  line-height: 1;
  transition: color var(--dur-fast);
}

.pnp-hub-theme-toggle:hover { color: var(--accent-gold); }
.pnp-hub-theme-toggle:focus-visible {
  outline: 2px solid var(--accent-gold);
  outline-offset: 2px;
}

.pnp-hub-greeting {
  position: relative;
  cursor: pointer;
}

.pnp-hub-greeting-btn {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  transition: background var(--dur-fast);
}

.pnp-hub-greeting-btn:hover { background: var(--bg-subtle); }

.pnp-hub-greeting-dropdown {
  display: none;
  position: absolute;
  right: 0;
  top: 100%;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  min-width: 160px;
  overflow: hidden;
  z-index: 200;
}

.pnp-hub-greeting.open .pnp-hub-greeting-dropdown { display: block; }

.pnp-hub-greeting-dropdown a,
.pnp-hub-greeting-dropdown button {
  display: block;
  width: 100%;
  text-align: left;
  padding: var(--space-3) var(--space-4);
  font-size: 14px;
  color: var(--text);
  background: none;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background var(--dur-fast);
}

.pnp-hub-greeting-dropdown a:hover,
.pnp-hub-greeting-dropdown button:hover {
  background: var(--bg-subtle);
}

@media (max-width: 767px) {
  .pnp-hub-header { height: 52px; }
}

/* ── Tab nav ───────────────────────────────────────────────────────────── */
.pnp-hub-tabs {
  position: sticky;
  top: 56px;
  z-index: 90;
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border);
}

.pnp-hub-tabs-inner {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.pnp-hub-tabs-inner::-webkit-scrollbar { display: none; }

.pnp-hub-tab {
  flex-shrink: 0;
  scroll-snap-align: start;
  padding: var(--space-3) var(--space-5);
  font-size: 15px;
  font-weight: 500;
  color: var(--text-soft);
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  cursor: pointer;
  transition: color var(--dur-fast), border-color var(--dur-fast);
  white-space: nowrap;
}

.pnp-hub-tab:hover { color: var(--text); }
.pnp-hub-tab.active {
  color: var(--accent-gold);
  border-bottom-color: var(--accent-gold);
  font-weight: 600;
}

.pnp-hub-tab:focus-visible {
  outline: 2px solid var(--accent-gold);
  outline-offset: -2px;
}

@media (max-width: 767px) {
  .pnp-hub-tabs { top: 52px; }
}

/* ── Tab panels ────────────────────────────────────────────────────────── */
.pnp-hub-panel {
  display: none;
  animation: pnp-fade-in var(--dur-fast) var(--ease-out);
  padding: var(--space-6) 0;
}

.pnp-hub-panel.active { display: block; }

@keyframes pnp-fade-in {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Block stacking ────────────────────────────────────────────────────── */
.pnp-hub-block {
  margin-bottom: var(--space-6);
}

/* ── Card ──────────────────────────────────────────────────────────────── */
.pnp-hub-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--dur-fast) var(--ease-out);
}

.pnp-hub-card:hover { box-shadow: var(--shadow-md); }

@media (max-width: 767px) {
  .pnp-hub-card { padding: var(--space-4); border-radius: var(--radius-md); }
}

/* ── Hero block ────────────────────────────────────────────────────────── */
.pnp-hub-hero {
  animation: pnp-hero-in var(--dur-base) var(--ease-out);
}

@keyframes pnp-hero-in {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.pnp-hub-hero-greeting {
  font-family: 'Inter Display', 'Inter', sans-serif;
  font-size: 32px;
  font-weight: 700;
  line-height: 40px;
  color: var(--text);
  margin: 0 0 var(--space-3);
}

.pnp-hub-hero-number {
  font-family: 'Inter Display', 'Inter', sans-serif;
  font-size: 64px;
  font-weight: 700;
  line-height: 64px;
  color: var(--accent-gold);
  font-variant-numeric: tabular-nums;
  margin: 0;
}

.pnp-hub-hero-number-unit {
  font-size: 20px;
  font-weight: 400;
  color: var(--text-soft);
  vertical-align: super;
}

.pnp-hub-hero-sub {
  font-size: 16px;
  color: var(--text-soft);
  margin: var(--space-2) 0 0;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-wrap: wrap;
}

.pnp-hub-trend-up   { color: var(--status-approved); }
.pnp-hub-trend-down { color: var(--accent-coral); }

@media (max-width: 767px) {
  .pnp-hub-hero-greeting { font-size: 24px; line-height: 32px; }
  .pnp-hub-hero-number   { font-size: 48px; line-height: 48px; }
}

/* ── Quick stats row ───────────────────────────────────────────────────── */
.pnp-hub-stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);
}

@media (max-width: 767px) {
  .pnp-hub-stats-row {
    grid-template-columns: 1fr;
    gap: var(--space-3);
  }
}

.pnp-hub-stat-card {
  text-align: left;
}

.pnp-hub-stat-caption {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0 0 var(--space-2);
}

.pnp-hub-stat-value {
  font-size: 32px;
  font-weight: 700;
  line-height: 38px;
  color: var(--accent-gold);
  font-variant-numeric: tabular-nums;
  margin: 0;
}

.pnp-hub-stat-sub {
  font-size: 14px;
  color: var(--text-soft);
  margin: var(--space-1) 0 0;
}

/* ── Section heading ───────────────────────────────────────────────────── */
.pnp-hub-section-heading {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0 0 var(--space-4);
}

/* ── Activity feed ─────────────────────────────────────────────────────── */
.pnp-hub-activity-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.pnp-hub-activity-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--border);
}

.pnp-hub-activity-item:last-child { border-bottom: none; }

.pnp-hub-avatar {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
}

.pnp-hub-activity-content { flex: 1; min-width: 0; }

.pnp-hub-activity-headline {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pnp-hub-activity-sub {
  font-size: 13px;
  color: var(--text-soft);
  margin: 2px 0 0;
}

.pnp-hub-activity-meta {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
}

/* ── Next action cards ─────────────────────────────────────────────────── */
.pnp-hub-next-actions {
  display: flex;
  gap: var(--space-4);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: var(--space-2);
}

.pnp-hub-action-card {
  flex-shrink: 0;
  scroll-snap-align: start;
  min-width: 260px;
  max-width: 320px;
}

.pnp-hub-action-icon {
  font-size: 28px;
  margin-bottom: var(--space-2);
}

.pnp-hub-action-title {
  font-size: 16px;
  font-weight: 600;
  margin: 0 0 var(--space-2);
  color: var(--text);
}

.pnp-hub-action-desc {
  font-size: 14px;
  color: var(--text-soft);
  margin: 0 0 var(--space-4);
}

/* ── Buttons ───────────────────────────────────────────────────────────── */
/* Buttons — PNP affiliate-area garnet primary + gold ghost. */
.pnp-hub-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 10px 18px;
  border-radius: var(--radius-sm); /* 8px to match affiliate-area submit buttons */
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background var(--dur-fast), transform var(--dur-fast), box-shadow var(--dur-fast);
  text-decoration: none;
}

.pnp-hub-btn:focus-visible {
  outline: 2px solid var(--accent-gold);
  outline-offset: 2px;
}

/* Primary — garnet gradient matching the affiliate-area submit button. */
.pnp-hub-btn-primary {
  background: linear-gradient(135deg, var(--accent-garnet), var(--accent-garnet-deep));
  color: #fff;
  border-color: var(--border-strong);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.pnp-hub-btn-primary:hover {
  background: linear-gradient(135deg, #8a2334, var(--accent-garnet));
  transform: translateY(-1px);
  box-shadow: 0 6px 20px var(--accent-garnet-glow);
  color: #fff;
}

/* Ghost — gold-outlined for secondary actions (Copy your link, Download). */
.pnp-hub-btn-ghost {
  background: transparent;
  color: var(--accent-gold);
  border-color: var(--border-strong);
}

.pnp-hub-btn-ghost:hover {
  background: var(--accent-gold-soft);
  color: var(--accent-gold-hover);
  border-color: var(--accent-gold);
}

.pnp-hub-btn:active { transform: scale(0.97); }

/* ── Filter bar ────────────────────────────────────────────────────────── */
.pnp-hub-filter-bar {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-wrap: wrap;
  margin-bottom: var(--space-4);
}

.pnp-hub-filter-group {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.pnp-hub-filter-label {
  font-size: 13px;
  color: var(--text-soft);
  white-space: nowrap;
}

.pnp-hub-select {
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-elevated);
  color: var(--text);
  font-size: 14px;
  font-family: inherit;
  cursor: pointer;
}

.pnp-hub-filter-summary {
  font-size: 14px;
  color: var(--text-soft);
  margin-bottom: var(--space-4);
}

/* ── Order card ────────────────────────────────────────────────────────── */
.pnp-hub-order-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.pnp-hub-order-card {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  animation: pnp-fade-in var(--dur-base) var(--ease-out) both;
}

.pnp-hub-order-card:nth-child(1) { animation-delay: 0ms; }
.pnp-hub-order-card:nth-child(2) { animation-delay: 50ms; }
.pnp-hub-order-card:nth-child(3) { animation-delay: 100ms; }
.pnp-hub-order-card:nth-child(4) { animation-delay: 150ms; }
.pnp-hub-order-card:nth-child(5) { animation-delay: 200ms; }

.pnp-hub-order-main { flex: 1; min-width: 0; }

.pnp-hub-order-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  margin: 0;
}

.pnp-hub-order-sub {
  font-size: 14px;
  color: var(--text-soft);
  margin: 2px 0 0;
}

.pnp-hub-order-meta {
  font-size: 12px;
  color: var(--text-muted);
  margin: 2px 0 0;
}

.pnp-hub-order-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: var(--space-1);
  flex-shrink: 0;
}

/* ── Status pills ──────────────────────────────────────────────────────── */
.pnp-hub-pill {
  display: inline-flex;
  align-items: center;
  padding: 2px var(--space-3);
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 500;
}

.pnp-hub-pill-pending  { background: rgba(217, 119,  6, 0.1); color: var(--status-pending);  }
.pnp-hub-pill-approved { background: rgba(  5, 150, 105, 0.1); color: var(--status-approved); }
.pnp-hub-pill-paid     { background: rgba( 14, 165, 233, 0.1); color: var(--status-paid);     }
.pnp-hub-pill-rejected { background: rgba(156, 163, 175, 0.1); color: var(--status-rejected); }

/* ── Commission badge ──────────────────────────────────────────────────── */
.pnp-hub-amount-badge {
  font-size: 16px;
  font-weight: 700;
  color: var(--accent-gold);
  font-variant-numeric: tabular-nums;
}

/* ── Pagination ────────────────────────────────────────────────────────── */
.pnp-hub-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  padding: var(--space-5) 0;
}

.pnp-hub-pagination button {
  min-width: 44px;
  min-height: 44px;
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-elevated);
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
  transition: background var(--dur-fast);
}

.pnp-hub-pagination button:hover:not(:disabled) { background: var(--bg-subtle); }
.pnp-hub-pagination button:disabled { opacity: 0.4; cursor: not-allowed; }

.pnp-hub-pagination span { font-size: 14px; color: var(--text-soft); }

/* ── Share tab ─────────────────────────────────────────────────────────── */
.pnp-hub-coupon-code {
  font-size: 32px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--accent-gold);
  letter-spacing: 0.05em;
  font-family: 'Inter Display', 'Inter', sans-serif;
}

.pnp-hub-link-url {
  font-size: 16px;
  font-weight: 500;
  color: var(--text);
  word-break: break-all;
}

.pnp-hub-copy-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin: var(--space-3) 0;
}

.pnp-hub-share-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-top: var(--space-4);
  flex-wrap: wrap;
}

.pnp-hub-share-row-label {
  font-size: 14px;
  color: var(--text-muted);
}

.pnp-hub-share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  font-size: 18px;
  cursor: pointer;
  text-decoration: none;
  transition: background var(--dur-fast), transform var(--dur-fast);
}

.pnp-hub-share-btn:hover {
  background: var(--accent-gold-soft);
  transform: scale(1.05);
}

/* P2: “Copy for IG” button uses same circle styling as share anchors. */
button.pnp-hub-share-btn {
  font-family: inherit;
  color: inherit;
  padding: 0;
  margin: 0;
  line-height: 1;
}

/* ── QR block ──────────────────────────────────────────────────────────── */
.pnp-hub-qr-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-6);
}

@media (max-width: 767px) {
  .pnp-hub-qr-grid { grid-template-columns: 1fr; }
}

.pnp-hub-qr-card {
  text-align: center;
}

.pnp-hub-qr-img {
  width: 180px;
  height: 180px;
  margin: var(--space-4) auto;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  display: block;
}

.pnp-hub-qr-buttons {
  display: flex;
  gap: var(--space-3);
  justify-content: center;
  flex-wrap: wrap;
}

/* ── FAQ accordion ─────────────────────────────────────────────────────── */
.pnp-hub-faq-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.pnp-hub-faq-item {
  border-bottom: 1px solid var(--border);
}

.pnp-hub-faq-item:last-child { border-bottom: none; }

.pnp-hub-faq-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: var(--space-4) 0;
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  gap: var(--space-3);
}

.pnp-hub-faq-trigger:focus-visible {
  outline: 2px solid var(--accent-gold);
  outline-offset: 2px;
}

.pnp-hub-faq-chevron {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  transition: transform var(--dur-base) var(--ease-out);
  color: var(--text-muted);
}

.pnp-hub-faq-item.open .pnp-hub-faq-chevron { transform: rotate(180deg); }

.pnp-hub-faq-body {
  overflow: hidden;
  height: 0;
  transition: height var(--dur-base) var(--ease-out);
}

.pnp-hub-faq-body-inner {
  padding: 0 0 var(--space-4);
  font-size: 15px;
  color: var(--text-soft);
  line-height: 24px;
}

/* ── Catalog ───────────────────────────────────────────────────────────── */
.pnp-hub-catalog-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.pnp-hub-catalog-item {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  padding: var(--space-4);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.pnp-hub-catalog-img {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background: var(--bg-subtle);
  flex-shrink: 0;
}

.pnp-hub-catalog-info { flex: 1; }

.pnp-hub-catalog-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 var(--space-1);
}

.pnp-hub-catalog-price {
  font-size: 14px;
  color: var(--text-soft);
}

/* ── Account forms ─────────────────────────────────────────────────────── */
.pnp-hub-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-4);
}

@media (max-width: 767px) {
  .pnp-hub-form-grid { grid-template-columns: 1fr; }
}

.pnp-hub-form-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.pnp-hub-form-label {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-soft);
}

.pnp-hub-input {
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-subtle);
  color: var(--text);
  font-size: 15px;
  font-family: inherit;
  transition: border-color var(--dur-fast), box-shadow var(--dur-fast);
}

.pnp-hub-input:focus {
  outline: none;
  border-color: var(--accent-gold);
  box-shadow: 0 0 0 3px rgba(212, 162, 74, 0.2);
}

.pnp-hub-input:read-only {
  opacity: 0.6;
  cursor: not-allowed;
}

.pnp-hub-form-footer {
  display: flex;
  justify-content: flex-end;
  margin-top: var(--space-5);
}

/* ── Notifications / toggles ───────────────────────────────────────────── */
.pnp-hub-toggle-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.pnp-hub-toggle-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.pnp-hub-toggle-checkbox {
  width: 20px;
  height: 20px;
  accent-color: var(--accent-gold);
  cursor: pointer;
}

.pnp-hub-toggle-label {
  font-size: 15px;
  color: var(--text);
  cursor: pointer;
}

/* ── Payout history ────────────────────────────────────────────────────── */
.pnp-hub-payout-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.pnp-hub-payout-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) 0;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
  color: var(--text);
  flex-wrap: wrap;
}

.pnp-hub-payout-row:last-child { border-bottom: none; }

.pnp-hub-payout-footer {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: var(--space-3);
}

/* ── Earn tab placeholder ─────────────────────────────────────────────── */
.pnp-hub-coming-soon {
  text-align: center;
  padding: var(--space-16) var(--space-8);
}

.pnp-hub-coming-soon-icon { font-size: 48px; margin-bottom: var(--space-4); }

.pnp-hub-coming-soon h3 {
  font-size: 22px;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 var(--space-3);
}

.pnp-hub-coming-soon p {
  font-size: 16px;
  color: var(--text-soft);
  max-width: 480px;
  margin: 0 auto;
}

/* ── Terms card ────────────────────────────────────────────────────────── */
.pnp-hub-terms-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.pnp-hub-terms-item {
  display: flex;
  gap: var(--space-3);
}

.pnp-hub-terms-bullet {
  flex-shrink: 0;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-gold);
  margin-top: 8px;
}

.pnp-hub-terms-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-soft);
  min-width: 160px;
}

.pnp-hub-terms-value {
  font-size: 15px;
  color: var(--text);
  line-height: 22px;
}

/* ── Empty states ──────────────────────────────────────────────────────── */
.pnp-hub-empty {
  text-align: center;
  padding: var(--space-12) var(--space-8);
}

.pnp-hub-empty-icon { font-size: 36px; margin-bottom: var(--space-3); }

.pnp-hub-empty p {
  font-size: 16px;
  color: var(--text-soft);
  margin: 0 0 var(--space-4);
  max-width: 360px;
  margin-left: auto;
  margin-right: auto;
}

/* ── Skeleton ──────────────────────────────────────────────────────────── */
.pnp-hub-skeleton {
  background: linear-gradient(
    90deg,
    var(--bg-subtle) 25%,
    var(--border) 50%,
    var(--bg-subtle) 75%
  );
  background-size: 200% 100%;
  animation: pnp-shimmer 1.4s ease infinite;
  border-radius: var(--radius-md);
}

@keyframes pnp-shimmer {
  from { background-position: 200% 0; }
  to   { background-position: -200% 0; }
}

.pnp-hub-skeleton-row {
  height: 72px;
  margin-bottom: var(--space-3);
}

/* ── Toast ─────────────────────────────────────────────────────────────── */
.pnp-hub-toast {
  position: fixed;
  bottom: var(--space-6);
  left: 50%;
  transform: translateX(-50%) translateY(100%);
  background: var(--accent-coral);
  color: #fff;
  padding: var(--space-3) var(--space-6);
  border-radius: var(--radius-pill);
  font-size: 14px;
  font-weight: 600;
  box-shadow: var(--shadow-md);
  z-index: 9999;
  /* 2026-08-25: hiding by transform alone left the toast permanently visible as a
     stray bronze pill over the content. translateY(100%) only moves the element down
     by its OWN height (24px), not past its `bottom` offset — so it parked itself at
     the bottom edge, on top of the last card, at z-index 9999. Hide it properly. */
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: transform var(--dur-fast) var(--ease-out),
              opacity var(--dur-fast) var(--ease-out),
              visibility 0s linear var(--dur-fast);
}

.pnp-hub-toast.visible {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: transform var(--dur-fast) var(--ease-out),
              opacity var(--dur-fast) var(--ease-out),
              visibility 0s;
}

/* ── Help bar ──────────────────────────────────────────────────────────── */
.pnp-hub-help-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--bg-elevated);
  border-top: 1px solid var(--border);
  padding: var(--space-3) var(--space-6);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  color: var(--text-soft);
  z-index: 80;
  transition: transform var(--dur-fast) var(--ease-out);
}

.pnp-hub-help-bar.hidden { transform: translateY(100%); }

.pnp-hub-help-dismiss {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  padding: var(--space-1) var(--space-2);
  font-size: 16px;
  line-height: 1;
}

/* Pad main content above help bar */
.pnp-hub-main { padding-bottom: 56px; }
.pnp-hub-main.help-dismissed { padding-bottom: 0; }

/* ── Error banner ──────────────────────────────────────────────────────── */
.pnp-hub-error-banner {
  padding: var(--space-4);
  background: var(--accent-coral-soft);
  border: 1px solid rgba(232, 117, 95, 0.2);
  border-radius: var(--radius-lg);
  color: var(--text);
  font-size: 15px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
}

/* ── Copy button animation ─────────────────────────────────────────────── */
@keyframes pnp-btn-pulse {
  0%   { transform: scale(1); }
  50%  { transform: scale(1.05); }
  100% { transform: scale(1); }
}

.pnp-hub-btn.copying {
  animation: pnp-btn-pulse var(--dur-base) var(--ease-celebrate);
}

/* ── Loading spinner ────────────────────────────────────────────────────── */
.pnp-hub-spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid var(--border);
  border-top-color: var(--accent-gold);
  border-radius: 50%;
  animation: pnp-spin 0.7s linear infinite;
}

@keyframes pnp-spin { to { transform: rotate(360deg); } }

/* ── Earn tab: leaderboard + tier stepper + team rows (v0.3.7) ─────────────
   These classes are emitted by hub.js (buildLeaderboardCard / buildTierCard /
   buildTeamCard) but were never styled — the lists rendered as raw bulleted
   <ul>s. Styled here to match the card/avatar/pill system. */

.pnp-hub-leaderboard-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.pnp-hub-leaderboard-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background: var(--bg-subtle);
}
.pnp-hub-leaderboard-row--you {
  background: var(--accent-gold-soft);
  box-shadow: inset 0 0 0 1px var(--border-strong);
}
.pnp-hub-leaderboard-rank {
  flex-shrink: 0;
  min-width: 28px;
  text-align: center;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-muted);
}
.pnp-hub-leaderboard-name {
  flex: 1;
  min-width: 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pnp-hub-leaderboard-earnings {
  flex-shrink: 0;
  font-size: 15px;
  font-weight: 700;
  color: var(--accent-gold);
}

.pnp-hub-tier-stepper {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.pnp-hub-tier-step {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background: var(--bg-subtle);
  opacity: 0.65;
}
.pnp-hub-tier-step--reached { opacity: 1; }
.pnp-hub-tier-step--current {
  opacity: 1;
  background: var(--accent-gold-soft);
  box-shadow: inset 0 0 0 1px var(--border-strong);
}
.pnp-hub-tier-step-dot {
  flex-shrink: 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--text-muted);
}
.pnp-hub-tier-step--reached .pnp-hub-tier-step-dot { background: var(--accent-gold-dim); }
.pnp-hub-tier-step--current .pnp-hub-tier-step-dot {
  background: var(--accent-gold);
  box-shadow: 0 0 0 4px var(--accent-gold-soft);
}
.pnp-hub-tier-step-label {
  flex-shrink: 0;
  min-width: 84px;
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
}
.pnp-hub-tier-step-detail {
  font-size: 14px;
  color: var(--text-soft);
}
