/* Mpiece Admin — eigen layout bovenop Bootstrap + brand. */

.admin-body {
  background: #f6f7fb;
  min-height: 100vh;
}

.admin-sidebar {
  position: fixed;
  inset-block: 0;
  inset-inline-start: 0;
  width: 240px;
  background: #fff;
  border-right: 1px solid var(--mp-border);
  display: flex;
  flex-direction: column;
  z-index: 50;
}

.admin-nav {
  display: flex;
  flex-direction: column;
  padding: 0.5rem;
  gap: 0.15rem;
}

.admin-nav-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.6rem 0.85rem;
  border-radius: 8px;
  color: var(--mp-text);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
}

.admin-nav-item:hover {
  background: rgba(72, 56, 138, 0.06);
  color: var(--mp-purple);
  text-decoration: none;
}

.admin-nav-item.active {
  background: var(--mp-purple);
  color: #fff;
}

.admin-main {
  margin-inline-start: 240px;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.admin-topbar {
  position: sticky;
  top: 0;
  background: #fff;
  border-bottom: 1px solid var(--mp-border);
  padding: 0.75rem 1.5rem;
  z-index: 10;
  display: flex;
  align-items: center;
}

.admin-content {
  padding: 1.5rem;
  flex-grow: 1;
}

.admin-page-title {
  color: var(--mp-purple);
}

.admin-card {
  background: #fff;
  border: 1px solid var(--mp-border);
  border-radius: 10px;
  padding: 1.25rem;
  margin-bottom: 1.25rem;
}

.admin-stat {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.admin-stat-value {
  font-size: 2rem;
  font-weight: 700;
  color: var(--mp-purple);
  line-height: 1;
}

.admin-stat-label {
  font-size: 0.85rem;
  color: var(--mp-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.admin-table {
  font-size: 0.92rem;
}

.admin-table thead th {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--mp-text-muted);
  border-bottom: 2px solid var(--mp-border);
}

.admin-table tbody tr:hover {
  background: rgba(72, 56, 138, 0.04);
}

.admin-status-badge {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.status-publish, .status-new      { background: #dcfce7; color: #166534; }
.status-offline, .status-rejected { background: #fee2e2; color: #991b1b; }
.status-reviewing                 { background: #fef9c3; color: #854d0e; }
.status-contacted                 { background: #dbeafe; color: #1e40af; }
.status-hired                     { background: #ede9fe; color: var(--mp-purple-darker); }

.admin-login-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 1rem;
  background: linear-gradient(135deg, #ede4d2 0%, #c5b8e6 100%);
}

.admin-login-card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.12);
  padding: 2.5rem;
  width: 100%;
  max-width: 420px;
}

@media (max-width: 767.98px) {
  .admin-sidebar {
    position: relative;
    width: 100%;
    flex-direction: row;
    overflow-x: auto;
    z-index: 10;
  }
  .admin-nav {
    flex-direction: row;
    flex: 1;
    overflow-x: auto;
  }
  .admin-main {
    margin-inline-start: 0;
  }
}

/* ── Hero-image picker ──────────────────────────────────────────────── */
.hero-picker {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.75rem;
  margin-top: 0.25rem;
}
.hero-picker-item {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0.35rem;
  background: #fff;
  border: 2px solid #e6e6ea;
  border-radius: 0.5rem;
  cursor: pointer;
  text-align: center;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.05s ease;
}
.hero-picker-item:hover {
  border-color: #b5a8de;
}
.hero-picker-item:active {
  transform: scale(0.98);
}
.hero-picker-item.is-selected {
  border-color: #48388a;
  box-shadow: 0 0 0 3px rgba(72, 56, 138, 0.15);
}
.hero-picker-item.is-match:not(.is-selected) {
  border-color: #2eaa50;
  box-shadow: 0 0 0 2px rgba(46, 170, 80, 0.18);
}
.hero-picker-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 0.35rem;
  background: #f4f3f7;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-picker-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.hero-picker-match-badge {
  position: absolute;
  top: 0.25rem;
  right: 0.25rem;
  background: #2eaa50;
  color: #fff;
  font-size: 0.75rem;
  line-height: 1;
  padding: 0.15rem 0.35rem;
  border-radius: 0.6rem;
  font-weight: 700;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
}
.hero-picker-empty {
  border: 2px dashed #cfcad6;
}
.hero-picker-label {
  font-size: 0.78rem;
  color: #555;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hero-picker-item.is-selected .hero-picker-label {
  color: #48388a;
  font-weight: 600;
}

/* ──────────────────────────────────────────────────────────────────────────
 * Utility-classes — vervangers voor voorheen inline style="..." attributen.
 * Toegevoegd toen we strikte nonce-CSP gingen draaien (geen unsafe-inline).
 * ─────────────────────────────────────────────────────────────────────── */

/* 16:9-container voor hero-image preview */
.mp-aspect-16x9 { aspect-ratio: 16/9; overflow: hidden; background: #f3f3f3; }
.mp-img-cover   { width: 100%; height: 100%; object-fit: cover; display: block; }

/* TOTP-code input — monospace + grote letterspacing */
.mp-code-input        { font-family: monospace; letter-spacing: 0.3em; }
.mp-code-input.lg     { font-size: 1.6rem; letter-spacing: 0.4em; }
.mp-code-input.md     { font-size: 1.4rem; max-width: 200px; }

/* Inkomende mail-body */
.mp-mail-body {
  white-space: pre-wrap;
  background: #f8f6ef;
  padding: 12px;
  border-radius: 4px;
  max-height: 600px;
  overflow-y: auto;
}

/* AI-blok in applications/view */
.mp-ai-card     { border-left: 4px solid #48388a; }
.mp-score-min   { min-width: 90px; }
.mp-label-eyebrow { font-size: 0.7rem; letter-spacing: 0.1em; }

/* Application red-flag row */
.mp-warn        { color: #c34; }

/* Application meta-table label-column */
.mp-col-160     { width: 160px; }

/* Entity / social form */
.mp-input-upper { text-transform: uppercase; }

/* Emoji-sizes */
.mp-emoji-md    { font-size: 1.2rem; }
.mp-emoji-lg    { font-size: 1.4rem; }
.mp-emoji-xxl   { font-size: 2rem; }
.mp-flag-cell   { font-size: 1.4rem; line-height: 1; }

/* Entity social-table column widths */
.mp-col-18 { width: 18%; }
.mp-col-8  { width: 8%; }
.mp-col-10 { width: 10%; }

/* ──────────────────────────────────────────────────────────────────────────
 * Analytics chart-blokken (statische delen; dynamische kleur/breedte via
 * per-request nonced <style> block in pages/analytics/index.php).
 * ─────────────────────────────────────────────────────────────────────── */
.mp-chart-card  { background: linear-gradient(180deg, #fff, #fafafb); }
.mp-sparkline-v2 { width: 100%; height: 110px; }

/* Heatmap-grid */
.mp-heatmap { display: flex; flex-direction: column; gap: 2px; font-family: -apple-system, BlinkMacSystemFont, sans-serif; }
.mp-heatmap-header,
.mp-heatmap-row { display: grid; grid-template-columns: 38px repeat(24, 1fr); gap: 2px; }
.mp-heatmap-corner,
.mp-heatmap-day { font-size: 0.7rem; color: #777; display: flex; align-items: center; justify-content: flex-end; padding-right: 6px; }
.mp-heatmap-hour { font-size: 0.65rem; color: #aaa; text-align: center; }
.mp-heatmap-cell { aspect-ratio: 1 / 1; min-height: 14px; border-radius: 2px; }
.mp-heatmap-cell:hover { outline: 1.5px solid #48388a; }

/* Funnel */
.mp-funnel-bar-track { background: #f1eff7; height: 22px; border-radius: 4px; overflow: hidden; }
.mp-funnel-bar { height: 100%; border-radius: 4px; transition: width 0.6s ease-out; }
