/* ============================================================
   wannabegeek.net — site.css
   Shared stylesheet for all pages.
   All pages import:
     Bootstrap 5 (CDN)  →  base grid / components
     Nunito + Share Tech Mono (Google Fonts)  →  typography
     site.css (this file)  →  design tokens + all shared UI
   ============================================================ */

/* ── Design tokens ────────────────────────────────────────── */
:root {
  --clr-bg:      #1b1b1b;
  --clr-surface: #242424;
  --clr-card:    #2a2a2a;
  --clr-border:  #363636;
  --clr-green:   #39d98a;
  --clr-red:     #e5534b;
  --clr-amber:   #f0a500;
  --clr-blue:    #4d9de0;
  --clr-text:    #e0e0e0;
  --clr-muted:   #7a7a8a;
  --font-ui:     'Nunito', sans-serif;
  --font-mono:   'Share Tech Mono', monospace;
}

/* ── Reset / base ─────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--clr-bg);
  color: var(--clr-text);
  font-family: var(--font-ui);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { flex: 1; }

a { color: var(--clr-blue); }
a:hover { color: var(--clr-green); }

code {
  background: rgba(255,255,255,0.08);
  padding: 0.1em 0.35em;
  border-radius: 3px;
  font-family: var(--font-mono);
  font-size: 0.85em;
  color: var(--clr-amber);
}

/* ── Navbar ───────────────────────────────────────────────── */
.wbg-nav {
  background: #111111 !important;
  border-bottom: 1px solid var(--clr-border);
  padding: 0.55rem 0;
  z-index: 1030;
}
.wbg-nav .navbar-brand {
  font-family: var(--font-ui);
  font-weight: 900;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
  color: #ffffff !important;
  text-decoration: none;
}
.wbg-nav .navbar-brand span { color: var(--clr-green); }
.wbg-nav .nav-link {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: lowercase;
  letter-spacing: 0.05em;
  color: rgba(255,255,255,0.5) !important;
  padding: 0.3rem 0.75rem !important;
  text-decoration: none;
  transition: color 0.2s;
}
.wbg-nav .nav-link:hover  { color: #ffffff !important; }
.wbg-nav .nav-link.active { color: #ffffff !important; font-weight: 800; }

/* ── Page hero ────────────────────────────────────────────── */
.page-hero {
  background: #111;
  border-bottom: 1px solid var(--clr-border);
  padding: 3.5rem 0 3rem;
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(57,217,138,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(57,217,138,0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
}
.page-hero .eyebrow {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--clr-green);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 0.6rem;
}
.page-hero h1 {
  font-size: clamp(1.9rem, 5vw, 3rem);
  font-weight: 900;
  color: #fff;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 0;
}
.page-hero h1 em {
  font-style: normal;
  color: var(--clr-green);
}
.page-hero .lead {
  font-size: 0.95rem;
  color: var(--clr-muted);
  max-width: 560px;
  margin-top: 0.85rem;
  line-height: 1.7;
}

/* ── Card shared ──────────────────────────────────────────── */
.wbg-card {
  background: var(--clr-card);
  border: 1px solid var(--clr-border);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 2px 16px rgba(0,0,0,0.4);
  opacity: 0;
  animation: cardIn 0.45s ease forwards;
}
@keyframes cardIn {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}
.wbg-card:nth-child(1)  { animation-delay: 0.04s; }
.wbg-card:nth-child(2)  { animation-delay: 0.10s; }
.wbg-card:nth-child(3)  { animation-delay: 0.16s; }
.wbg-card:nth-child(4)  { animation-delay: 0.22s; }
.wbg-card:nth-child(5)  { animation-delay: 0.28s; }
.wbg-card:nth-child(6)  { animation-delay: 0.34s; }
.wbg-card:nth-child(7)  { animation-delay: 0.40s; }
.wbg-card:nth-child(8)  { animation-delay: 0.46s; }
.wbg-card:nth-child(9)  { animation-delay: 0.52s; }

/* Card banner (image-top, same pattern as Mobirise mbr.jpg blocks) */
.card-banner {
  width: 100%;
  height: 130px;
  display: flex;
  align-items: flex-end;
  padding: 1rem 1.5rem;
  position: relative;
  overflow: hidden;
}
.card-banner::before {           /* dot-grid texture */
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(255,255,255,0.06) 1px, transparent 1px);
  background-size: 18px 18px;
}
.card-banner::after {            /* bottom fade so text stays readable */
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.72) 0%, transparent 65%);
}
.banner-content {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.banner-icon {
  font-size: 1.8rem;
  line-height: 1;
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.6));
}
.banner-eyebrow {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.5);
  line-height: 1;
  margin-bottom: 0.18rem;
}
.banner-h4 {
  font-size: 1.05rem;
  font-weight: 800;
  color: #fff;
  margin: 0;
  line-height: 1.2;
  text-shadow: 0 1px 4px rgba(0,0,0,0.5);
}
.banner-badge {
  margin-left: auto;
  position: relative;
  z-index: 2;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.08em;
  padding: 0.22rem 0.55rem;
  border-radius: 3px;
  align-self: flex-end;
  white-space: nowrap;
}
.badge-high { background: rgba(229,83,75,0.22);  color: #ff7b73; border: 1px solid rgba(229,83,75,0.4); }
.badge-med  { background: rgba(240,165,0,0.18);  color: #f0c060; border: 1px solid rgba(240,165,0,0.35); }
.badge-info { background: rgba(77,157,224,0.18); color: #7dc4f0; border: 1px solid rgba(77,157,224,0.35); }
.badge-ok   { background: rgba(57,217,138,0.15); color: #5decaf; border: 1px solid rgba(57,217,138,0.3); }

/* Collapse toggle strip */
.card-toggle-bar {
  display: flex;
  align-items: center;
  padding: 0.55rem 1.4rem;
  background: rgba(0,0,0,0.2);
  border-bottom: 1px solid var(--clr-border);
  cursor: pointer;
  user-select: none;
  font-size: 0.75rem;
  color: var(--clr-muted);
  transition: background 0.15s;
}
.card-toggle-bar:hover { background: rgba(255,255,255,0.04); }
.card-toggle-bar .toggle-label { flex: 1; }
.toggle-arrow { font-size: 0.6rem; transition: transform 0.22s; }
.wbg-card.collapsed .toggle-arrow { transform: rotate(-90deg); }
.card-body-inner { padding: 1.4rem; }
.wbg-card.collapsed .card-body-inner { display: none; }

/* ── Banner gradient presets (one per section) ────────────── */
.banner-cookies     { background: linear-gradient(135deg, #0f1924 0%, #1a3a5c 40%, #2d1f42 100%); }
.banner-fingerprint { background: linear-gradient(135deg, #0a0f1e 0%, #122040 40%, #0e2a38 100%); }
.banner-vpn         { background: linear-gradient(135deg, #0a1e14 0%, #0d3324 40%, #12261a 100%); }
.banner-headers     { background: linear-gradient(135deg, #1e1000 0%, #3a1f00 40%, #2a1200 100%); }
.banner-hardware    { background: linear-gradient(135deg, #0a1022 0%, #0e1f42 40%, #181030 100%); }
.banner-permissions { background: linear-gradient(135deg, #200a10 0%, #3a0f1e 40%, #2a0a10 100%); }
.banner-behaviour   { background: linear-gradient(135deg, #0a1e1e 0%, #0d3030 40%, #102222 100%); }
.banner-score       { background: linear-gradient(135deg, #181400 0%, #302800 40%, #221e00 100%); }
.banner-protect     { background: linear-gradient(135deg, #0a1c0a 0%, #0f3018 40%, #0e2012 100%); }
.banner-contact     { background: linear-gradient(135deg, #0a0f1e 0%, #122040 40%, #1a1030 100%); }
.banner-home        { background: linear-gradient(135deg, #0a1e14 0%, #111 40%, #0e1a2e 100%); }

/* ── Data rows (whoami page) ──────────────────────────────── */
.data-row {
  display: grid;
  grid-template-columns: 195px 1fr auto;
  gap: 0.4rem 1rem;
  align-items: baseline;
  padding: 0.55rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  font-size: 0.82rem;
}
.data-row:last-of-type { border-bottom: none; }
.data-label { font-weight: 700; color: var(--clr-muted); white-space: nowrap; }
.data-label::after { content: ':'; }
.data-value {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--clr-green);
  word-break: break-all;
}
.data-value.loading { color: var(--clr-muted); animation: blink 1s step-end infinite; }
@keyframes blink { 50% { opacity: 0; } }
.data-risk { font-family: var(--font-mono); font-size: 0.62rem; white-space: nowrap; }
.risk-high { color: var(--clr-red); }
.risk-med  { color: var(--clr-amber); }
.risk-low  { color: var(--clr-green); }

/* ── Why it matters block ─────────────────────────────────── */
.why-matters {
  margin-top: 1.1rem;
  padding: 0.8rem 1rem;
  background: rgba(229,83,75,0.07);
  border-left: 3px solid var(--clr-red);
  border-radius: 0 4px 4px 0;
  font-size: 0.8rem;
  color: #bbb;
  line-height: 1.65;
}
.why-matters strong { color: #f08080; }

/* ── Header note (blue, informational) ───────────────────── */
.header-note {
  font-size: 0.78rem;
  color: var(--clr-muted);
  margin-bottom: 0.85rem;
  padding: 0.6rem 0.85rem;
  background: rgba(77,157,224,0.07);
  border-left: 3px solid var(--clr-blue);
  border-radius: 0 4px 4px 0;
  line-height: 1.6;
}

/* ── Misc shared utilities ────────────────────────────────── */
hr.subtle { border: none; border-top: 1px solid var(--clr-border); margin: 0.75rem 0; }
.tracker-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--clr-muted);
  margin-top: 0.9rem;
  margin-bottom: 0.35rem;
}

/* ── Footer ───────────────────────────────────────────────── */
.wbg-footer {
  background: #111;
  border-top: 1px solid var(--clr-border);
  padding: 1.5rem 0;
  text-align: center;
  font-size: 0.78rem;
  color: var(--clr-muted);
  margin-top: auto;
}
.wbg-footer a { color: var(--clr-muted); text-decoration: none; margin: 0 0.5rem; }
.wbg-footer a:hover { color: var(--clr-text); }
.wbg-footer .footer-sub { margin-top: 0.5rem; font-size: 0.7rem; }

/* ── Responsive tweaks ────────────────────────────────────── */
@media (max-width: 600px) {
  .data-row { grid-template-columns: 1fr 1fr; }
  .data-risk { display: none; }
}


/* ============================================================
   CONSENT BANNER & MODAL
   Injected by assets/js/consent.js
   ============================================================ */

/* ── Banner ─────────────────────────────────────────────── */
#wbg-consent-banner {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 9999;
  background: #1a1a1a;
  border-top: 1px solid #3a3a3a;
  box-shadow: 0 -4px 24px rgba(0,0,0,0.5);
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.4,0,0.2,1);
  padding: 1rem 0;
}
#wbg-consent-banner.wbg-cb-visible { transform: translateY(0); }

.wbg-cb-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}
.wbg-cb-text {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  flex: 1;
  font-size: 0.82rem;
  color: #ccc;
  line-height: 1.6;
  min-width: 200px;
}
.wbg-cb-icon { font-size: 1.4rem; flex-shrink: 0; margin-top: 0.05rem; }
.wbg-cb-link { color: #39d98a; text-decoration: none; }
.wbg-cb-link:hover { text-decoration: underline; }
.wbg-cb-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
  flex-shrink: 0;
}

/* ── Shared button styles ───────────────────────────────── */
.wbg-btn {
  font-family: 'Nunito', system-ui, sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  border-radius: 4px;
  padding: 0.5rem 1rem;
  cursor: pointer;
  border: none;
  transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.1s;
  white-space: nowrap;
  line-height: 1;
}
.wbg-btn:active { transform: scale(0.97); }

.wbg-btn-accept {
  background: #39d98a;
  color: #111;
}
.wbg-btn-accept:hover { background: #4ff5a6; }

.wbg-btn-ghost {
  background: transparent;
  color: #e0e0e0;
  border: 1px solid #4a4a4a;
}
.wbg-btn-ghost:hover { border-color: #aaa; color: #fff; }

.wbg-btn-text {
  background: transparent;
  color: #7a7a8a;
  border: none;
  padding: 0.5rem 0.5rem;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.wbg-btn-text:hover { color: #e0e0e0; }

/* ── Preferences modal ──────────────────────────────────── */
#wbg-consent-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}
#wbg-consent-modal.wbg-cm-visible {
  opacity: 1;
  pointer-events: all;
}

.wbg-cm-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.7);
}

.wbg-cm-box {
  position: relative;
  z-index: 1;
  background: #242424;
  border: 1px solid #363636;
  border-radius: 8px;
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 8px 48px rgba(0,0,0,0.6);
  transform: translateY(12px);
  transition: transform 0.3s;
}
#wbg-consent-modal.wbg-cm-visible .wbg-cm-box { transform: translateY(0); }

.wbg-cm-header {
  display: flex;
  align-items: center;
  padding: 1.1rem 1.4rem;
  border-bottom: 1px solid #363636;
  position: sticky;
  top: 0;
  background: #242424;
  z-index: 1;
}
.wbg-cm-title {
  font-family: 'Nunito', system-ui, sans-serif;
  font-weight: 800;
  font-size: 1rem;
  color: #fff;
  flex: 1;
}
.wbg-cm-close {
  background: none;
  border: none;
  color: #7a7a8a;
  font-size: 1.4rem;
  cursor: pointer;
  line-height: 1;
  padding: 0.1rem 0.3rem;
  border-radius: 3px;
  transition: color 0.2s, background 0.2s;
}
.wbg-cm-close:hover { color: #fff; background: rgba(255,255,255,0.08); }

.wbg-cm-body { padding: 1rem 1.4rem; }

.wbg-cm-cat {
  padding: 1rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.wbg-cm-cat:last-child { border-bottom: none; }

.wbg-cm-cat-header {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 0.75rem;
}
.wbg-cm-cat-name {
  font-family: 'Nunito', system-ui, sans-serif;
  font-weight: 800;
  font-size: 0.9rem;
  color: #fff;
  margin-bottom: 0.25rem;
}
.wbg-cm-cat-desc {
  font-size: 0.76rem;
  color: #7a7a8a;
  line-height: 1.55;
}
.wbg-cm-always {
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.65rem;
  color: #39d98a;
  border: 1px solid rgba(57,217,138,0.35);
  border-radius: 3px;
  padding: 0.2rem 0.5rem;
  white-space: nowrap;
  flex-shrink: 0;
  margin-top: 0.15rem;
}

/* Toggle switch */
.wbg-toggle {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
  margin-top: 0.1rem;
  cursor: pointer;
}
.wbg-toggle input { opacity: 0; width: 0; height: 0; }
.wbg-toggle-slider {
  position: absolute;
  inset: 0;
  background: #3a3a3a;
  border-radius: 24px;
  transition: background 0.2s;
  border: 1px solid #4a4a4a;
}
.wbg-toggle-slider::before {
  content: '';
  position: absolute;
  width: 16px; height: 16px;
  left: 3px; bottom: 3px;
  background: #7a7a8a;
  border-radius: 50%;
  transition: transform 0.2s, background 0.2s;
}
.wbg-toggle input:checked + .wbg-toggle-slider { background: rgba(57,217,138,0.2); border-color: rgba(57,217,138,0.5); }
.wbg-toggle input:checked + .wbg-toggle-slider::before { transform: translateX(20px); background: #39d98a; }
.wbg-toggle input:focus-visible + .wbg-toggle-slider { outline: 2px solid #39d98a; outline-offset: 2px; }

/* Cookie detail table */
.wbg-cm-table {
  width: 100%;
  border-collapse: collapse;
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.68rem;
}
.wbg-cm-table th {
  text-align: left;
  padding: 0.3rem 0.5rem;
  color: #7a7a8a;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.6rem;
}
.wbg-cm-table td {
  padding: 0.3rem 0.5rem;
  color: #b0b0b0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.wbg-cm-table td:first-child { color: #f0a500; }

.wbg-cm-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.4rem;
  border-top: 1px solid #363636;
  flex-wrap: wrap;
  gap: 0.75rem;
  position: sticky;
  bottom: 0;
  background: #242424;
}
.wbg-cm-link { font-size: 0.78rem; color: #39d98a; text-decoration: none; }
.wbg-cm-link:hover { text-decoration: underline; }
.wbg-cm-footer-btns { display: flex; gap: 0.6rem; }

/* ── "Cookie Settings" trigger link in footer ───────────── */
.wbg-cookie-settings-btn {
  background: none;
  border: none;
  color: var(--clr-muted, #7a7a8a);
  font-size: 0.78rem;
  font-family: inherit;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.2s;
}
.wbg-cookie-settings-btn:hover { color: #e0e0e0; }

@media (max-width: 600px) {
  .wbg-cb-inner  { flex-direction: column; gap: 1rem; }
  .wbg-cb-actions{ width: 100%; justify-content: flex-start; }
  .wbg-cm-footer { flex-direction: column; align-items: flex-start; }
}
