/* css/style.css - Centrale Styling Kennisbank */

:root {
  --primary: #23285e;
  --cta: #DE1B51;
  --tertiary: #494573;
  --bg: #e5e3ec;
  --white: #ffffff;
  --surface: #f4f3f8;
  --border: #d4d2e0;
  --text: #1a1c3a;
  --text-muted: #7b789a;
  --success: #1a7a4a;
  --success-bg: #d4f0e2;
  --warning: #8a5a00;
  --warning-bg: #fff6d6;
  --danger: #b81040;
  --danger-bg: #fde0e8;
  --info: #1a4a8a;
  --info-bg: #ddeeff;
  --shadow: 0 2px 12px rgba(35,40,94,0.08);
  --shadow-lg: 0 8px 32px rgba(35,40,94,0.13);
  --radius: 10px;
  --radius-sm: 6px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'DM Sans', sans-serif; background: var(--bg); color: var(--text); font-size: 14px; min-height: 100vh; }

/* TOPBAR */
.topbar { background: var(--primary); height: 58px; display: flex; align-items: center; padding: 0 28px; gap: 32px; position: sticky; top: 0; z-index: 100; box-shadow: 0 2px 16px rgba(35,40,94,0.22); }
.topbar-logo { font-size: 18px; font-weight: 700; color: white; letter-spacing: -0.3px; display: flex; align-items: center; gap: 10px; text-decoration: none; }
.topbar-logo span { background: var(--cta); color: white; font-size: 11px; font-weight: 600; padding: 2px 7px; border-radius: 4px; letter-spacing: 0.5px; text-transform: uppercase; }
.topbar-nav { display: flex; gap: 4px; flex: 1; }
.avatar { width: 32px; height: 32px; background: var(--tertiary); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; color: white; }
.topbar-user { display: flex; align-items: center; gap: 9px; color: rgba(255,255,255,0.85); font-size: 13px; }

/* LAYOUT & SIDEBAR */
.layout { display: flex; min-height: calc(100vh - 58px); }
.sidebar { width: 220px; background: var(--white); border-right: 1px solid var(--border); padding: 20px 0; flex-shrink: 0; }
.sidebar-section { margin-bottom: 24px; }
.sidebar-label { font-size: 10px; font-weight: 700; letter-spacing: 1.2px; text-transform: uppercase; color: var(--text-muted); padding: 0 18px; margin-bottom: 6px; }
.sidebar-item { display: flex; align-items: center; gap: 10px; padding: 8px 18px; color: var(--text-muted); font-size: 13.5px; font-weight: 500; cursor: pointer; border-left: 3px solid transparent; transition: all 0.15s; text-decoration: none; }
.sidebar-item:hover { background: var(--surface); color: var(--primary); }
.sidebar-item.active { background: #ebe9f5; color: var(--primary); border-left-color: var(--cta); font-weight: 600; }
.sidebar-item .icon { font-size: 16px; width: 18px; text-align: center; }

/* MAIN CONTENT */
.main { flex: 1; padding: 28px 32px; overflow: auto; }
.page-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; }
.page-title { font-size: 22px; font-weight: 700; color: var(--primary); letter-spacing: -0.4px; }
.page-subtitle { font-size: 13px; color: var(--text-muted); margin-top: 2px; }

/* BUTTONS */
.btn { display: inline-flex; align-items: center; gap: 6px; padding: 8px 18px; border-radius: var(--radius-sm); font-family: 'DM Sans', sans-serif; font-size: 13.5px; font-weight: 600; cursor: pointer; border: none; transition: all 0.15s; text-decoration: none; }
.btn-primary { background: var(--cta); color: white; }
.btn-primary:hover { background: #c21645; box-shadow: 0 4px 14px rgba(222,27,81,0.35); }
.btn-secondary { background: var(--primary); color: white; }
.btn-secondary:hover { background: #1a1e4a; }
.btn-ghost { background: transparent; color: var(--primary); border: 1.5px solid var(--border); }
.btn-ghost:hover { border-color: var(--primary); background: #ebe9f5; }
.btn-sm { padding: 5px 12px; font-size: 12.5px; }
.btn-danger-ghost { background: transparent; color: var(--danger); border: 1.5px solid #f5a0b8; }
.btn-danger-ghost:hover { background: var(--danger-bg); }

/* STAT PILLS */
.stat-pills { display: flex; gap: 12px; margin-bottom: 24px; }
.stat-pill { background: white; border-radius: var(--radius-sm); padding: 12px 18px; box-shadow: var(--shadow); text-align: center; flex: 1; border-top: 3px solid var(--border); }
.stat-pill.p-blue { border-top-color: var(--primary); }
.stat-pill.p-green { border-top-color: var(--success); }
.stat-pill.p-red { border-top-color: var(--cta); }
.stat-num { font-size: 26px; font-weight: 700; font-family: 'DM Mono', monospace; color: var(--primary); }
.stat-lbl { font-size: 11.5px; color: var(--text-muted); font-weight: 600; text-transform: uppercase; letter-spacing: 0.4px; margin-top: 2px; }

/* TABS */
.tabs { display: flex; gap: 0; border-bottom: 2px solid var(--border); margin-bottom: 20px; }
.tab { padding: 10px 20px; font-size: 14px; font-weight: 600; color: var(--text-muted); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -2px; transition: all 0.15s; text-decoration: none; }
.tab:hover { color: var(--primary); }
.tab.active { color: var(--primary); border-bottom-color: var(--cta); }

/* TOOLBAR & SEARCH */
.toolbar { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.search-wrap { position: relative; flex: 1; max-width: 350px; }
.search-wrap input { width: 100%; padding: 8px 12px 8px 34px; border: 1.5px solid var(--border); border-radius: var(--radius-sm); font-family: 'DM Sans', sans-serif; font-size: 13px; background: var(--white); outline: none; transition: border-color 0.15s; }
.search-wrap input:focus { border-color: var(--primary); }
.search-icon { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); color: var(--text-muted); }

/* MESSAGES */
.msg { padding: 12px 16px; border-radius: var(--radius-sm); font-size: 13.5px; font-weight: 600; margin-bottom: 20px; display: flex; align-items: center; gap: 8px; }
.msg-success { background: var(--success-bg); color: var(--success); border: 1px solid #b3e6cb; }
.msg-warn { background: var(--warning-bg); color: var(--warning); border: 1px solid #ffe699; }
.msg-danger { background: var(--danger-bg); color: var(--danger); border: 1px solid #f5a0b8; }

/* TABLE */
.table-wrap { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; margin-bottom: 20px; }
table { width: 100%; border-collapse: collapse; }
thead th { background: var(--primary); color: rgba(255,255,255,0.9); font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.7px; padding: 12px 16px; text-align: left; white-space: nowrap; user-select: none; }
thead th a:hover { color: var(--cta) !important; }
thead th:first-child { padding-left: 20px; }
tbody tr { border-bottom: 1px solid var(--border); transition: background 0.1s; }
tbody tr:last-child { border-bottom: none; }
tbody tr:nth-child(even) { background: #fafafa; }
tbody tr:hover { background: #f0eff8; }
tbody td { padding: 11px 16px; font-size: 13.5px; vertical-align: middle; }
tbody td:first-child { padding-left: 20px; }
.td-mono { font-family: 'DM Mono', monospace; font-size: 12px; color: var(--tertiary); font-weight: 500; }
.td-muted { color: var(--text-muted); font-size: 13px; }
.actions { display: flex; gap: 6px; justify-content: flex-end; padding-right: 20px !important; }

/* BADGES */
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 3px 9px; border-radius: 20px; font-size: 11.5px; font-weight: 600; }
.badge-active { background: var(--success-bg); color: var(--success); }
.badge-inactive { background: var(--surface); color: var(--text-muted); border: 1px solid var(--border); }
.badge-type { background: var(--info-bg); color: var(--info); border: 1px solid #bce0fd; }

/* BULK ACTIONS BAR */
.bulk-actions { display: none; background: var(--info-bg); border: 1px solid #bce0fd; padding: 10px 20px; border-radius: var(--radius-sm); margin-bottom: 16px; align-items: center; justify-content: space-between; animation: slideDown 0.2s ease-out; }
@keyframes slideDown { from { opacity: 0; transform: translateY(-5px); } to { opacity: 1; transform: translateY(0); } }

/* PAGINATION */
.pagination { display: flex; align-items: center; justify-content: space-between; padding: 14px 20px; border-top: 1px solid var(--border); background: var(--white); }
.page-info { font-size: 13px; color: var(--text-muted); font-weight: 500; }
.page-btns { display: flex; gap: 4px; }
.page-btn { width: 30px; height: 30px; display: flex; align-items: center; justify-content: center; border: 1.5px solid var(--border); background: white; border-radius: var(--radius-sm); font-size: 12.5px; cursor: pointer; color: var(--text-muted); transition: all 0.15s; text-decoration: none; font-weight: 500; }
.page-btn:hover { border-color: var(--primary); color: var(--primary); }
.page-btn.active { background: var(--primary); border-color: var(--primary); color: white; }
.page-btn.disabled { opacity: 0.4; pointer-events: none; }

input[type="checkbox"] { width: 16px; height: 16px; cursor: pointer; accent-color: var(--cta); }