:root {
  --gold: #FFD700;
  --gold-dark: #c9a800;
  --orange: #FF6B35;
  --jungle-dark: #0d1f0f;
  --jungle-mid: #1a3a1c;
  --jungle-green: #2d5a27;
  --canopy: #3d7a35;
  --cream: #f4e4bc;
  --text-light: #f0ead6;
  --text-muted: #b8a87a;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: 'Nunito', sans-serif;
  background: var(--jungle-dark);
  color: var(--text-light);
  min-height: 100vh;
}

/* ── Nav ─────────────────────────────────────── */
.lib-nav {
  position: sticky; top: 0; z-index: 100;
  padding: 10px 32px;
  display: flex; align-items: center; justify-content: space-between;
  background: rgba(13,31,15,0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255,215,0,0.1);
}
.lib-nav-brand {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none;
}
.lib-nav-brand img { height: 52px; }
.lib-nav-brand span {
  font-family: 'Carter One', cursive; font-size: 1.25rem;
  color: var(--cream);
}
.lib-nav-links { display: flex; gap: 18px; align-items: center; }
.lib-nav-links a {
  color: var(--text-muted); text-decoration: none; font-size: 14px; font-weight: 600;
  transition: color 0.15s;
}
.lib-nav-links a:hover { color: var(--gold); }
.lib-nav-code {
  font-size: 13px; color: var(--text-muted); text-decoration: underline;
  cursor: pointer; background: none; border: none; font-family: inherit;
}
.lib-nav-code:hover { color: var(--gold); }

/* ── Header ──────────────────────────────────── */
.lib-header {
  text-align: center; padding: 48px 24px 24px;
}
.lib-header h1 {
  font-family: 'Carter One', cursive; font-size: 2rem;
  color: var(--gold); margin-bottom: 8px;
}
.lib-header p {
  font-size: 15px; color: var(--text-muted); max-width: 520px; margin: 0 auto;
}

/* ── Grid ────────────────────────────────────── */
.lib-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 22px; padding: 24px 32px 64px;
  max-width: 1100px; margin: 0 auto;
}

/* ── Card ────────────────────────────────────── */
.lib-card {
  border-radius: 18px; overflow: hidden;
  background: var(--jungle-mid);
  border: 1px solid rgba(255,215,0,0.12);
  transition: transform 0.2s, box-shadow 0.2s;
  display: flex; flex-direction: column;
}
.lib-card:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0,0,0,0.3); }
.lib-card.state-locked { opacity: 0.7; }
.lib-card.state-locked:hover { transform: none; box-shadow: none; }
.lib-card.state-coming_soon { opacity: 0.5; pointer-events: none; }

.lib-card-img {
  height: 140px; background: var(--jungle-green);
  position: relative; overflow: hidden;
}
.lib-card-hero {
  width: 100%; height: 100%; object-fit: cover; display: block;
}

/* Badge */
.lib-badge {
  position: absolute; top: 10px; right: 10px;
  font-family: 'Carter One', cursive; font-size: 0.7rem;
  padding: 3px 11px; border-radius: 20px;
}
.badge-free { background: var(--canopy); color: white; }
.badge-owned { background: rgba(104,211,145,0.2); color: #68d391; border: 1px solid rgba(104,211,145,0.4); }
.badge-member { background: rgba(96,165,250,0.15); color: #60a5fa; border: 1px solid rgba(96,165,250,0.35); }
.badge-locked { background: rgba(255,215,0,0.1); color: var(--gold); border: 1px solid var(--gold-dark); }
.badge-soon { background: rgba(255,255,255,0.08); color: var(--text-muted); }

.lib-card-body { padding: 14px 16px 16px; flex: 1; display: flex; flex-direction: column; }
.lib-card-title { font-weight: 800; font-size: 16px; margin-bottom: 4px; }
.lib-card-blurb { font-size: 13px; color: var(--text-muted); line-height: 1.4; margin-bottom: 10px; flex: 1; }

/* Target chips */
.lib-chips { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 12px; }
.lib-chip {
  font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px;
  padding: 2px 8px; border-radius: 10px;
  background: rgba(255,215,0,0.08); color: var(--gold-dark); border: 1px solid rgba(255,215,0,0.15);
}
.lib-chip-more {
  font-size: 10px; font-weight: 600; padding: 2px 8px; border-radius: 10px;
  color: var(--text-muted); background: none; border: 1px solid rgba(255,255,255,0.08);
}

/* CTA button area */
.lib-cta {
  display: block; width: 100%; text-align: center;
  padding: 10px; border-radius: 12px; font-weight: 700; font-size: 14px;
  text-decoration: none; border: none; cursor: pointer; font-family: inherit;
  transition: background 0.15s;
}
.cta-play { background: var(--canopy); color: white; }
.cta-play:hover { background: var(--jungle-green); }
.cta-owned { background: rgba(104,211,145,0.12); color: #68d391; border: 1px solid rgba(104,211,145,0.3); }
.cta-member { background: rgba(96,165,250,0.1); color: #60a5fa; border: 1px solid rgba(96,165,250,0.25); }
.cta-locked { background: rgba(255,215,0,0.08); color: var(--gold); border: 1px solid rgba(255,215,0,0.2); }
.cta-locked:hover { background: rgba(255,215,0,0.15); }
.cta-soon { background: rgba(255,255,255,0.04); color: var(--text-muted); cursor: default; }

/* Waitlist */
.lib-waitlist-label {
  font-size: 11px; color: var(--text-muted); text-align: center; margin-bottom: 6px;
}
.lib-waitlist-row input[type="email"] {
  display: block; width: 100%; padding: 8px 10px; border-radius: 10px;
  border: 1px solid rgba(255,215,0,0.2); background: rgba(0,0,0,0.3);
  color: var(--text-light); font-size: 13px; font-family: inherit;
  outline: none; margin-bottom: 6px;
}
.lib-waitlist-row input[type="email"]::placeholder { color: var(--text-muted); }
.lib-waitlist-row input[type="email"]:focus { border-color: var(--gold); }
.lib-waitlist-row button { width: 100%; padding: 8px 14px; }
.lib-waitlist-consent {
  display: flex; align-items: flex-start; gap: 6px; margin-top: 6px;
  font-size: 11px; color: var(--text-muted); cursor: pointer; line-height: 1.3;
}
.lib-waitlist-consent input[type="checkbox"] {
  margin-top: 1px; accent-color: var(--gold); flex-shrink: 0;
}
.lib-waitlist-done {
  text-align: center; font-size: 13px; color: #68d391; padding: 10px 0;
}

/* Loading */
.lib-loading { text-align: center; padding: 80px 24px; color: var(--text-muted); font-size: 15px; }
.lib-error { text-align: center; padding: 80px 24px; color: #fc8181; font-size: 15px; }
