/* =========================================================
   Taskly — design system
   blou / wit, professioneel, skerp hoeke (geen rondings)
   ========================================================= */

:root {
  /* brand kleure */
  --navy-900: #0b1e3f;
  --navy-800: #0f2a5a;
  --navy-700: #14336e;
  --blue-700: #1e40af;
  --blue-600: #2563eb;
  --blue-500: #3b82f6;
  --blue-100: #dbeafe;
  --blue-50:  #eff6ff;
  --sky:      #0ea5e9;

  /* neutrale kleure */
  --white:    #ffffff;
  --bg:       #f4f6fb;
  --bg-alt:   #eef2f8;
  --surface:  #ffffff;
  --line:     #d8dee9;
  --line-soft:#e4e9f1;
  --ink:      #0b1e3f;
  --ink-soft: #1f2d4a;
  --muted:    #5a6b85;
  --muted-2:  #8595ad;

  /* status kleure */
  --danger:   #b3261e;
  --danger-bg:#fdecea;
  --warn:     #a16207;
  --warn-bg:  #fef3c7;
  --ok:       #15803d;
  --ok-bg:    #dcfce7;

  /* layout */
  --container: 1180px;
  --radius: 0;             /* geen rondings nêrens */
  --shadow-sm: 0 1px 0 rgba(11,30,63,0.04), 0 1px 2px rgba(11,30,63,0.05);
  --shadow-md: 0 1px 0 rgba(11,30,63,0.04), 0 4px 14px rgba(11,30,63,0.07);
  --shadow-lg: 0 1px 0 rgba(11,30,63,0.04), 0 14px 36px rgba(11,30,63,0.12);

  /* fonts — system fonts: geen netwerk nodig, vinnig op stadige lyne */
  --font-sans: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* ---------- reset / basis ---------- */

*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink-soft);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* druk footer grond toe op kort pages */
body > main,
body > .auth-shell {
  flex: 1 0 auto;
}
body > .topbar,
body > .hero,
body > .site-footer { flex-shrink: 0; }

img, video { max-width: 100%; display: block; }

a { color: var(--blue-700); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  margin: 0 0 12px;
  color: var(--ink);
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.25;
}

h1 { font-size: clamp(1.6rem, 2.4vw, 2rem); }
h2 { font-size: 1.35rem; }
h3 { font-size: 1.05rem; }

p { margin: 0 0 12px; }

.muted { color: var(--muted); font-size: 0.92rem; }

ol, ul { padding-left: 20px; margin: 0 0 12px; }
ol li, ul li { margin: 6px 0; color: var(--ink-soft); }

::selection { background: var(--blue-100); color: var(--navy-900); }

/* ---------- layout boustene ---------- */

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 28px;
}

.page { padding: 36px 0 72px; }

.section + .section { margin-top: 32px; }

.eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--blue-700);
  background: var(--blue-50);
  padding: 4px 10px;
  border: 1px solid var(--blue-100);
  margin-bottom: 12px;
}

.divider {
  height: 1px;
  background: var(--line-soft);
  margin: 28px 0;
}

/* ---------- top bar ---------- */

.topbar {
  background: var(--white);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 50;
}

.topbar-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 28px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--navy-900);
  letter-spacing: 0.01em;
  text-decoration: none;
}

.brand:hover { text-decoration: none; }

.brand-mark {
  width: 28px;
  height: 28px;
  display: inline-grid;
  place-items: center;
  background: linear-gradient(180deg, var(--blue-600), var(--navy-800));
  color: white;
  font-weight: 800;
  font-size: 0.85rem;
  letter-spacing: 0.02em;
}

.brand-name { line-height: 1; }
.brand-suffix {
  display: block;
  font-size: 0.62rem;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-top: 3px;
}

.nav-links {
  display: flex;
  gap: 4px;
  align-items: center;
}

.nav-links a, .nav-links button {
  color: var(--ink-soft);
  text-decoration: none;
  background: transparent;
  border: 0;
  font: inherit;
  font-weight: 500;
  font-size: 0.92rem;
  cursor: pointer;
  padding: 8px 14px;
  transition: color .12s, background .12s;
}

.nav-links a:hover, .nav-links button:hover {
  color: var(--navy-900);
  background: var(--bg-alt);
  text-decoration: none;
}

.nav-links a.active {
  color: var(--navy-900);
  background: var(--blue-50);
}

.nav-cta { margin-left: 8px; }

.profile-menu {
  position: relative;
  margin-left: 8px;
}

.profile-toggle {
  list-style: none;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: linear-gradient(180deg, var(--blue-600), var(--navy-800));
  color: var(--white);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  cursor: pointer;
  user-select: none;
}

.profile-toggle::-webkit-details-marker { display: none; }

.profile-toggle:hover {
  filter: brightness(1.05);
}

.profile-toggle:focus-visible {
  outline: 2px solid var(--blue-600);
  outline-offset: 2px;
}

.profile-popover {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 240px;
  background: var(--white);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-md);
  padding: 14px;
  z-index: 90;
}

.profile-popover::before {
  content: "";
  position: absolute;
  top: -7px;
  right: 12px;
  width: 12px;
  height: 12px;
  background: var(--white);
  border-left: 1px solid var(--line);
  border-top: 1px solid var(--line);
  transform: rotate(45deg);
}

.profile-name {
  margin: 0 0 2px;
  color: var(--ink);
  font-weight: 700;
  font-size: 0.95rem;
}

.profile-meta {
  margin: 0;
  color: var(--muted);
  font-size: 0.84rem;
}

.profile-meta + .profile-meta {
  margin-top: 2px;
}

.profile-edit-btn {
  width: 100%;
  margin-top: 12px;
  text-align: center;
}

/* ---------- kaarte & vlakke ---------- */

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 28px;
  margin-bottom: 20px;
  box-shadow: var(--shadow-sm);
}

.card.tight { padding: 20px; }

.card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line-soft);
}

.card-header h1, .card-header h2 { margin: 0; }

.card-title-block .muted { margin-top: 4px; }

/* ---------- knoppies ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--blue-700);
  color: var(--white);
  border: 1px solid var(--blue-700);
  padding: 11px 22px;
  cursor: pointer;
  font: inherit;
  font-weight: 600;
  font-size: 0.92rem;
  letter-spacing: 0.01em;
  text-decoration: none;
  transition: background .14s, border-color .14s, color .14s, transform .04s;
  min-height: 42px;
}

.btn:hover { background: var(--navy-800); border-color: var(--navy-800); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }

.btn-secondary {
  background: var(--white);
  color: var(--navy-800);
  border-color: var(--line);
}
.btn-secondary:hover { background: var(--bg-alt); color: var(--navy-900); border-color: var(--navy-800); }

.btn-ghost {
  background: transparent;
  color: var(--blue-700);
  border-color: transparent;
}
.btn-ghost:hover { background: var(--blue-50); color: var(--navy-800); border-color: transparent; }

.btn-danger { background: var(--danger); border-color: var(--danger); }
.btn-danger:hover { background: #8e1414; border-color: #8e1414; }

.btn-warn { background: var(--warn); border-color: var(--warn); }
.btn-warn:hover { background: #7a4a06; border-color: #7a4a06; }

.btn-lg { padding: 14px 26px; font-size: 0.98rem; min-height: 48px; }
.btn-block { width: 100%; }

.btn-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 22px; }

/* ---------- forms ---------- */

.form-grid { display: grid; gap: 14px; }

label {
  display: block;
  margin-top: 14px;
  font-weight: 600;
  font-size: 0.82rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

input, select, textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--ink);
  font: inherit;
  font-size: 0.95rem;
  margin-top: 6px;
  transition: border-color .12s, box-shadow .12s;
  border-radius: var(--radius);
}

textarea { min-height: 120px; resize: vertical; }

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--blue-600);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.18);
}

input::placeholder, textarea::placeholder { color: var(--muted-2); }

/* wagwoordveld met 'n wys/versteek knoppie binne-in. die houer en knoppie
   word deur auth.js gebou, sodat die veld 'n gewone wagwoordveld bly as JS
   nie laai nie */
.pw-veld { position: relative; }

/* maak plek vir die knoppie sodat lang wagwoorde nie daaronder inskuif nie */
.pw-veld input { padding-right: 92px; }

.pw-toggle {
  position: absolute;
  top: 7px;   /* die input het margin-top: 6px plus 1px rand */
  right: 1px;
  bottom: 1px;
  padding: 0 13px;
  border: 0;
  background: transparent;
  color: var(--blue-700);
  font: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  cursor: pointer;
}

.pw-toggle:hover { color: var(--blue-600); }

.pw-toggle:focus-visible {
  outline: 2px solid var(--blue-600);
  outline-offset: -2px;
}

/* die reels onder die wagwoordveld, sodat 'n mens dit vooraf sien en nie
   eers wanneer die vorm weier nie */
.pw-wenk {
  display: block;
  margin-top: 6px;
  font-size: 0.78rem;
  line-height: 1.4;
}

/* file input — hou dit native, gee net spasie */
input[type="file"] {
  padding: 8px;
  background: var(--bg-alt);
  border-style: dashed;
  cursor: pointer;
}

/* ---------- alerts ---------- */

.error, .success, .info {
  padding: 12px 14px;
  margin: 14px 0;
  font-size: 0.92rem;
  border: 1px solid transparent;
  border-left-width: 4px;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.error  { background: var(--danger-bg); color: var(--danger); border-color: #f5c7c2; border-left-color: var(--danger); }
.success{ background: var(--ok-bg);     color: var(--ok);     border-color: #b6e2c4; border-left-color: var(--ok); }
.info   { background: var(--blue-50);   color: var(--navy-800); border-color: var(--blue-100); border-left-color: var(--blue-600); }

/* ---------- betaalstappe ---------- */

.pay-steps {
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
  counter-reset: pay-step;
}

.pay-steps li {
  position: relative;
  counter-increment: pay-step;
  padding: 0 0 14px 40px;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.5;
}

.pay-steps li::before {
  content: counter(pay-step);
  position: absolute;
  left: 0;
  top: 0;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--navy-900);
  color: white;
  font-size: 0.8rem;
  font-weight: 700;
}

.pay-steps li:last-child { padding-bottom: 0; }

.pay-steps strong { color: var(--navy-900); }

/* ---------- badges en chips ---------- */

.balance-pill {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  background: var(--navy-900);
  color: white;
  padding: 6px 14px;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.02em;
}
.balance-pill .label {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--blue-100);
}

.status-badge {
  display: inline-block;
  padding: 3px 10px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  border: 1px solid transparent;
}

.status-aktief    { background: var(--ok-bg);   color: var(--ok);     border-color: #a6d8b9; }
.status-gepauseer { background: var(--warn-bg); color: var(--warn);   border-color: #f0d68a; }

.tag {
  display: inline-block;
  padding: 2px 8px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  background: var(--blue-50);
  color: var(--navy-800);
  border: 1px solid var(--blue-100);
  text-transform: uppercase;
}

/* ---------- grids ---------- */

.grid { display: grid; gap: 20px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

@media (max-width: 860px) {
  .grid-3 { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  .grid-2 { grid-template-columns: 1fr; }
}

/* ---------- stat teëls ---------- */

.stat {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  position: relative;
  overflow: hidden;
}
.stat::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--blue-600), var(--sky));
}
.stat .label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}
.stat .value {
  font-size: 2rem;
  font-weight: 800;
  color: var(--navy-900);
  line-height: 1.1;
  letter-spacing: -0.02em;
}
.stat .hint {
  font-size: 0.85rem;
  color: var(--muted);
}

/* ---------- aksie teël ---------- */

.action-tile {
  display: block;
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 24px;
  text-decoration: none;
  color: inherit;
  position: relative;
  transition: border-color .15s, box-shadow .15s, transform .15s;
}
.action-tile:hover {
  border-color: var(--navy-800);
  box-shadow: var(--shadow-md);
  text-decoration: none;
  transform: translateY(-1px);
}
.action-tile h3 { color: var(--navy-900); margin-bottom: 6px; }
.action-tile .muted { margin-bottom: 16px; }
.action-tile .arrow {
  font-weight: 700;
  color: var(--blue-700);
  letter-spacing: 0.02em;
}
.action-tile:hover .arrow { color: var(--navy-900); }

/* ---------- pakket kaarte ---------- */

.package-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 860px) { .package-grid { grid-template-columns: 1fr; } }

.package-card {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  position: relative;
  transition: box-shadow .18s, border-color .18s, transform .18s;
}
.package-card:hover {
  border-color: var(--navy-800);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.package-card.featured {
  border-color: var(--navy-800);
  background: linear-gradient(180deg, var(--navy-900) 0%, var(--navy-800) 100%);
  color: white;
  box-shadow: var(--shadow-lg);
}
.package-card.featured .package-name,
.package-card.featured .package-clicks { color: rgba(255,255,255,0.78); }
.package-card.featured .package-price { color: white; }
.package-card.featured .package-feature { color: rgba(255,255,255,0.86); }
.package-card.featured .package-feature::before {
  background: var(--sky);
  color: var(--navy-900);
}
.package-card.featured .btn { background: white; color: var(--navy-900); border-color: white; }
.package-card.featured .btn:hover { background: var(--blue-100); border-color: var(--blue-100); color: var(--navy-900); }

.featured-flag {
  position: absolute;
  top: 0; right: 24px;
  transform: translateY(-50%);
  background: var(--sky);
  color: var(--navy-900);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 5px 10px;
}

.package-name {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted);
}

.package-price {
  font-size: 2.6rem;
  color: var(--navy-900);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.05;
  margin: 4px 0 0;
}
.package-price .currency { font-size: 1.2rem; vertical-align: top; margin-right: 2px; font-weight: 700; }
.package-price .unit {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0.06em;
  margin-top: 4px;
  text-transform: uppercase;
}

.package-clicks {
  margin-top: 10px;
  font-size: 1rem;
  color: var(--ink-soft);
  font-weight: 600;
}

.package-features {
  list-style: none;
  padding: 0;
  margin: 18px 0 22px;
  display: grid;
  gap: 8px;
}
.package-feature {
  font-size: 0.9rem;
  color: var(--ink-soft);
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.package-feature::before {
  content: "✓";
  background: var(--blue-50);
  color: var(--blue-700);
  font-weight: 800;
  font-size: 0.78rem;
  width: 18px;
  height: 18px;
  display: inline-grid;
  place-items: center;
  flex-shrink: 0;
  margin-top: 2px;
}

/* ---------- ad kaarte ---------- */

.ad-card {
  display: grid;
  grid-template-columns: 200px 1fr auto;
  gap: 22px;
  align-items: center;
  padding: 18px;
  border: 1px solid var(--line);
  margin-bottom: 14px;
  background: white;
  box-shadow: var(--shadow-sm);
  transition: box-shadow .14s, border-color .14s;
}
.ad-card:hover { box-shadow: var(--shadow-md); border-color: var(--navy-800); }

.ad-thumb {
  width: 200px;
  height: 124px;
  object-fit: cover;
  background: var(--navy-900);
  border: 1px solid var(--line-soft);
}

.ad-info h3 { margin: 0 0 6px; font-size: 1.05rem; color: var(--navy-900); }
.ad-meta { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 4px; font-size: 0.85rem; color: var(--muted); }
.ad-meta .dot { color: var(--muted-2); }

.ad-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* Debug / visibility helpers: force ads to be visible in case global layout
  rules hide them in production. These are subtle and can be removed once
  the issue is diagnosed. */
.ads-grid { display: block !important; }
.ads-grid .ad-card { outline: 1px solid rgba(0,0,0,0.06) !important; }

@media (max-width: 720px) {
  .ad-card { grid-template-columns: 1fr; }
  .ad-thumb { width: 100%; height: 180px; }
  .ad-actions { justify-content: flex-start; }
}

/* ---------- hero (landing) ---------- */

/* golden hour konstruksie-toneel. die navy gradient bly as fallback sodat die
   hero nooit ongestileerd wys terwyl die foto laai (of as dit misluk) nie.
   foto: Roman Chukhin, Unsplash — sien /img/CREDITS.txt */
.hero {
  position: relative;
  background-color: var(--navy-900);
  background-image: url('/img/hero-konstruksie.jpg');
  background-size: cover;
  background-position: center 62%;
  background-repeat: no-repeat;
  color: white;
  padding: 92px 32px 100px;
  text-align: left;
  border-bottom: 1px solid var(--navy-900);
  overflow: hidden;
}

/* donker skerm oor die foto — sterker links waar die teks sit, ligter regs
   sodat die hyskrane en die sonsondergang sigbaar bly */
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      90deg,
      rgba(11,30,63,0.88) 0%,
      rgba(11,30,63,0.72) 34%,
      rgba(11,30,63,0.30) 60%,
      rgba(11,30,63,0.06) 100%
    ),
    linear-gradient(
      180deg,
      rgba(11,30,63,0.45) 0%,
      rgba(11,30,63,0.00) 40%,
      rgba(11,30,63,0.30) 100%
    );
  pointer-events: none;
}

.hero-inner {
  max-width: var(--container);
  margin: 0 auto;
  position: relative;
  z-index: 1;
  display: grid;
  /* een kolom sedert die analise-mock verwyder is. die teks bly links beperk
     sodat die konstruksie-foto regs kan asemhaal */
  grid-template-columns: minmax(0, 660px);
  gap: 48px;
  align-items: center;
}

.hero .eyebrow {
  background: rgba(255,255,255,0.08);
  color: #b8d2ff;
  border-color: rgba(255,255,255,0.18);
}

.hero h1 {
  color: white;
  font-size: clamp(2rem, 4.4vw, 3.2rem);
  margin-bottom: 18px;
  letter-spacing: -0.025em;
  line-height: 1.08;
}

.hero p.lead {
  font-size: 1.1rem;
  max-width: 560px;
  margin: 0 0 28px;
  color: rgba(255,255,255,0.86);
}

.hero .btn-row { margin-top: 8px; }

.hero .btn {
  background: white;
  color: var(--navy-900);
  border-color: white;
}
.hero .btn:hover { background: var(--blue-100); border-color: var(--blue-100); color: var(--navy-900); }

.hero .btn-secondary {
  background: transparent;
  color: white;
  border-color: rgba(255,255,255,0.4);
}
.hero .btn-secondary:hover { background: rgba(255,255,255,0.1); color: white; border-color: white; }

.hero-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 36px;
  max-width: 480px;
}
.hero-stat {
  border-left: 2px solid rgba(255,255,255,0.3);
  padding-left: 14px;
}
.hero-stat .num { font-size: 1.5rem; font-weight: 800; color: white; letter-spacing: -0.01em; }
.hero-stat .lbl { font-size: 0.78rem; color: rgba(255,255,255,0.7); text-transform: uppercase; letter-spacing: 0.12em; }

.hero-card {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.18);
  padding: 26px;
  color: white;
}
.hero-card .label {
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.7);
  margin-bottom: 10px;
}
.hero-card-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid rgba(255,255,255,0.12);
  font-size: 0.92rem;
}
.hero-card-row:last-child { border-bottom: 0; }
.hero-card-row .k { color: rgba(255,255,255,0.78); }
.hero-card-row .v { color: white; font-weight: 700; }

@media (max-width: 900px) {
  .hero { padding: 64px 24px 72px; }
  .hero-inner { grid-template-columns: 1fr; gap: 32px; }
  .hero-card { display: none; }
}


/* ---------- feature ry ---------- */

.feature {
  padding: 22px;
  background: white;
  border: 1px solid var(--line);
}
.feature .num {
  display: inline-grid;
  place-items: center;
  width: 32px;
  height: 32px;
  background: var(--navy-900);
  color: white;
  font-weight: 800;
  font-size: 0.92rem;
  margin-bottom: 12px;
}
.feature h3 { color: var(--navy-900); margin-bottom: 6px; }
.feature p { color: var(--muted); margin: 0; font-size: 0.93rem; }

/* ---------- auth pages ---------- */

.auth-shell {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  min-height: calc(100vh - 64px);
}

.auth-form-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 56px 32px;
  background: white;
}

.auth-card {
  width: 100%;
  max-width: 460px;
  background: transparent;
  border: none;
  padding: 36px;
  box-shadow: none;
}

.auth-card h1 { margin-bottom: 6px; }
.auth-card .muted { margin-bottom: 22px; }

.auth-aside {
  background: linear-gradient(160deg, var(--navy-900) 0%, var(--navy-700) 60%, var(--navy-800) 100%);
  color: white;
  padding: 60px 48px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
.auth-aside h2 { color: white; font-size: 1.8rem; max-width: 420px; line-height: 1.2; }
.auth-aside p { color: rgba(255,255,255,0.82); max-width: 420px; }
.auth-aside ul { list-style: none; padding: 0; margin-top: 22px; max-width: 420px; }
.auth-aside li {
  padding: 10px 0;
  border-top: 1px solid rgba(255,255,255,0.14);
  color: rgba(255,255,255,0.9);
  display: flex;
  gap: 10px;
}
.auth-aside li::before {
  content: "→";
  color: var(--sky);
  font-weight: 800;
}

@media (max-width: 900px) {
  .auth-shell { grid-template-columns: 1fr; }
  .auth-aside { display: none; }
}

/* ---------- page header (binne pages) ---------- */

.page-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
}
.page-header h1 { margin: 0; }
.page-header .muted { margin-top: 4px; }

/* ---------- leë state ---------- */

.empty {
  text-align: center;
  padding: 56px 24px;
  background: var(--surface);
  border: 1px dashed var(--line);
}
.empty h3 { color: var(--navy-900); }
.empty p { color: var(--muted); max-width: 420px; margin: 0 auto 20px; }

/* ---------- footer ---------- */

.site-footer {
  background: var(--navy-900);
  color: rgba(255,255,255,0.78);
  margin-top: 60px;
  padding: 32px 0;
  font-size: 0.88rem;
}
.site-footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.site-footer a { color: white; }

/* ---------- ander goed ---------- */

.center { text-align: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.gap-sm { gap: 8px; }

.kbd {
  background: var(--bg-alt);
  border: 1px solid var(--line);
  padding: 1px 6px;
  font-size: 0.82rem;
  color: var(--ink-soft);
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

/* ---------- analytics (grafieke) ---------- */

.chart-wrap { width: 100%; overflow-x: auto; }
.chart-wrap svg { width: 100%; height: auto; display: block; }

.chart-axis-text {
  font-size: 11px;
  fill: var(--muted);
  font-family: var(--font-sans);
}

.chart-bar { cursor: pointer; }
.chart-bar:hover { opacity: 0.85; }

.chart-legend {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.legend-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.85rem;
  color: var(--ink-soft);
  font-weight: 600;
}
.legend-swatch {
  width: 12px;
  height: 12px;
  display: inline-block;
  flex-shrink: 0;
}

.chart-tooltip {
  position: fixed;
  z-index: 200;
  background: var(--navy-900);
  color: white;
  font-size: 0.82rem;
  line-height: 1.45;
  padding: 8px 11px;
  pointer-events: none;
  box-shadow: var(--shadow-md);
  max-width: 260px;
}

.chart-table { margin-top: 14px; }
.chart-table summary {
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--blue-700);
  padding: 6px 0;
}
.chart-table table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 8px;
  font-size: 0.9rem;
}
.chart-table th, .chart-table td {
  text-align: left;
  padding: 7px 12px;
  border-bottom: 1px solid var(--line-soft);
}
.chart-table th {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
}
.chart-table td { font-variant-numeric: tabular-nums; color: var(--ink-soft); }

/* horisontale bars: views per ad */
.hbar-row {
  display: grid;
  grid-template-columns: minmax(120px, 220px) 1fr 70px;
  align-items: center;
  gap: 14px;
  padding: 7px 0;
}
.hbar-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ink-soft);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hbar-track { background: var(--bg-alt); height: 18px; }
.hbar-fill { background: var(--blue-600); height: 100%; }
.hbar-value {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ink);
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* click meters */
.meter-row { padding: 12px 0; border-bottom: 1px solid var(--line-soft); }
.meter-row:last-child { border-bottom: 0; }
.meter-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}
.meter-title { font-weight: 600; color: var(--ink); font-size: 0.95rem; }
.meter-value { color: var(--muted); font-size: 0.88rem; font-variant-numeric: tabular-nums; }
.meter-track { background: var(--bg-alt); height: 10px; }
.meter-fill { height: 100%; }
.meter-ok { background: var(--ok); }
.meter-warn { background: var(--warn); }
.meter-danger { background: var(--danger); }
.meter-note { margin-top: 5px; font-size: 0.82rem; font-weight: 700; }
.meter-note-warn { color: var(--warn); }
.meter-note-danger { color: var(--danger); }

/* insight kaarte */
.insight-card { display: flex; flex-direction: column; align-items: flex-start; }
.insight-lift {
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--navy-900);
  letter-spacing: -0.02em;
  margin-top: 10px;
  line-height: 1.1;
}
.insight-flag {
  margin-top: auto;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 5px 10px;
  border: 1px solid transparent;
}
.insight-flag-ok { background: var(--ok-bg); color: var(--ok); border-color: #b6e2c4; }
.insight-flag-gap { background: var(--blue-50); color: var(--blue-700); border-color: var(--blue-100); text-decoration: none; }
.insight-flag-gap:hover { background: var(--blue-100); text-decoration: none; }

@media (max-width: 640px) {
  .hbar-row { grid-template-columns: 1fr; gap: 4px; }
  .hbar-value { text-align: left; }
}

/* ---------- klein skerms (ou en goedkoop fone) ---------- */

@media (max-width: 640px) {
  /* bar vou in twee rye: brand bo, links onder */
  .topbar-inner {
    flex-wrap: wrap;
    height: auto;
    padding: 10px 16px;
    row-gap: 4px;
  }
  .nav-links {
    flex-wrap: wrap;
    width: 100%;
    gap: 2px;
  }
  .profile-menu { margin-left: 0; }
  .nav-links a, .nav-links button {
    padding: 10px 12px;      /* groter tik area */
    font-size: 0.95rem;
  }
  .nav-cta { margin-left: 0; }

  .container { padding: 0 16px; }
  .page { padding: 24px 0 48px; }
  .card { padding: 18px; }

  .hero { padding: 48px 20px 56px; }
  .hero-stats { grid-template-columns: 1fr 1fr; gap: 12px; }

  .btn { min-height: 48px; }   /* maklik tikbaar met een duim, selfs op n gekraakte skerm */

  .auth-form-wrap { padding: 24px 12px; }
  .auth-card { padding: 20px 12px; }

  .site-footer .container { flex-direction: column; align-items: flex-start; }
}

/* ---------- advertensie-aanbeveling (analise) ---------- */

.rec-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line-soft);
}

.rec-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted-2);
}

.rec-kategorie {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--ink);
  letter-spacing: -0.015em;
  margin: 6px 0 4px;
}

.rec-rede { margin: 0; max-width: 520px; }

.rec-akkuraat { text-align: right; flex-shrink: 0; }

.rec-akkuraat-waarde {
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--blue-700);
  line-height: 1;
  margin-bottom: 6px;
}

.rec-produkte { padding: 18px 0; border-bottom: 1px solid var(--line-soft); }

.rec-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.rec-chip {
  display: inline-block;
  padding: 6px 12px;
  background: var(--blue-50);
  border: 1px solid var(--blue-100);
  color: var(--navy-800);
  font-size: 0.86rem;
  font-weight: 600;
}

.rec-tabel {
  width: 100%;
  border-collapse: collapse;
  margin-top: 18px;
  font-size: 0.9rem;
}

.rec-tabel th {
  text-align: left;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted-2);
  padding: 0 12px 10px 0;
  border-bottom: 1px solid var(--line);
}

.rec-tabel td {
  padding: 11px 12px 11px 0;
  border-bottom: 1px solid var(--line-soft);
  color: var(--ink-soft);
}

.rec-tabel .num { text-align: right; padding-right: 0; }
.rec-tabel tr.is-beste td { font-weight: 700; color: var(--ink); }
.rec-tabel .op { color: var(--ok); font-weight: 700; }
.rec-tabel .af { color: var(--danger); font-weight: 700; }
.rec-tabel .swak { color: var(--muted-2); }

@media (max-width: 640px) {
  .rec-top { flex-direction: column; gap: 14px; }
  .rec-akkuraat { text-align: left; }
}

/* ---------- advertensie-analise: klikke per advertensie ---------- */

.klik-tabel {
  width: 100%;
  border-collapse: collapse;
  margin-top: 6px;
  font-size: 0.9rem;
}

.klik-tabel th {
  text-align: left;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted-2);
  padding: 0 12px 10px 0;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.klik-tabel td {
  padding: 13px 12px 13px 0;
  border-bottom: 1px solid var(--line-soft);
  color: var(--ink-soft);
  vertical-align: top;
}

.klik-tabel .num {
  text-align: right;
  padding-right: 0;
  font-variant-numeric: tabular-nums;
}

/* die totaalreel dra geen rand nie - dit is 'n opsomming, nie nog 'n ry nie */
.klik-tabel tfoot td {
  border-bottom: 0;
  border-top: 2px solid var(--line);
  font-weight: 700;
  color: var(--navy-900);
}

.klik-tabel .ad-naam {
  font-weight: 600;
  color: var(--navy-900);
}

.klik-tabel .klik-telling {
  font-weight: 700;
  color: var(--navy-900);
  font-size: 1.05rem;
  line-height: 1.2;
}

/* staaf relatief tot die beste advertensie, sodat die verskil sigbaar is
   sonder dat 'n mens die syfers hoef te vergelyk */
.klik-tabel .klik-staaf {
  margin-top: 5px;
  height: 4px;
  background: var(--line-soft);
  width: 100%;
  min-width: 70px;
}

.klik-tabel .klik-staaf span {
  display: block;
  height: 100%;
  background: var(--blue-600);
}

@media (max-width: 640px) {
  .klik-tabel { font-size: 0.82rem; }
  .klik-tabel th, .klik-tabel td { padding-right: 8px; }
}

/* die telling waarop die rangorde loop: verwagte ekstra take, gedemp deur
   die model se akkuraatheid. dit word gewys sodat die volgorde van die
   tabel verklaarbaar is - sonder dit lyk die rangorde arbitrer */
.rec-tabel .telling {
  font-weight: 700;
  color: var(--navy-900);
  font-variant-numeric: tabular-nums;
}
