:root {
    --primary:   #2c3e50;
    --accent:    #e74c3c;
    --light-bg:  #f8f9fa;
    --border:    #dee2e6;
    --text-muted:#6c757d;
}

body {
    font-family: 'Segoe UI', system-ui, sans-serif;
    background: var(--light-bg);
    color: #212529;
}

/* Navbar */
.navbar {
    background: var(--primary) !important;
    box-shadow: 0 2px 8px rgba(0,0,0,.3);
}
.navbar-brand {
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: .5px;
    color: #fff !important;
}
.navbar .nav-link { color: rgba(255,255,255,.75) !important; }
.navbar .nav-link:hover { color: #fff !important; }
.navbar .nav-link.active {
    color: #fff !important;
    font-weight: 600;
    border-bottom: 2px solid var(--accent);
    padding-bottom: 2px;
}

/* Hamburger icoon wit maken */
.navbar-toggler { border-color: rgba(255,255,255,.3); }
.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255,255,255,.75%29' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* Dropdown menu */
.navbar .dropdown-menu {
    background: #fff;
    border: none;
    box-shadow: 0 8px 24px rgba(0,0,0,.15);
    border-radius: 10px;
    min-width: 200px;
    padding: .4rem 0;
    margin-top: .4rem;
}
.navbar .dropdown-item {
    color: #2c3e50;
    font-size: .9rem;
    padding: .45rem 1.1rem;
    border-radius: 6px;
    margin: 1px 4px;
    transition: background .12s;
}
.navbar .dropdown-item:hover,
.navbar .dropdown-item:focus  { background: #f0f4f8; color: #2c3e50; }
.navbar .dropdown-item.active  { background: #e8edf2; font-weight: 600; color: #2c3e50; }
.navbar .dropdown-item.text-danger       { color: #dc3545 !important; }
.navbar .dropdown-item.text-danger:hover { background: #fff5f5; }
.navbar .dropdown-header {
    color: #999;
    font-size: .72rem;
    text-transform: uppercase;
    letter-spacing: .06em;
    padding: .5rem 1.1rem .2rem;
}
.navbar .dropdown-divider { margin: .3rem .6rem; border-color: #eee; }

/* Cards */
.card {
    border: none;
    box-shadow: 0 1px 4px rgba(0,0,0,.1);
    border-radius: 8px;
}
.card-header {
    background: var(--primary);
    color: #fff;
    border-radius: 8px 8px 0 0 !important;
    font-weight: 600;
}

/* Zoekbalk */
.search-hero {
    background: linear-gradient(135deg, var(--primary), #34495e);
    padding: 2.5rem 0 2rem;
    color: #fff;
    margin-bottom: 1.5rem;
}
.search-hero h1 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
}
.search-hero .form-control {
    border: none;
    border-radius: 30px 0 0 30px;
    padding: .7rem 1.2rem;
    font-size: 1rem;
}
.search-hero .btn-search {
    border-radius: 0 30px 30px 0;
    background: var(--accent);
    border: none;
    color: #fff;
    padding: .7rem 1.4rem;
    font-weight: 600;
}
.search-hero .btn-search:hover { background: #c0392b; }
.search-hero .btn-search-clear {
    border-radius: 0 30px 30px 0;
    background: rgba(255,255,255,.2);
    border-left: 1px solid rgba(255,255,255,.3);
    color: #fff;
    padding: .7rem 1rem;
    font-size: .95rem;
    cursor: pointer;
    text-decoration: none;
    display: flex;
    align-items: center;
}
.search-hero .btn-search-clear:hover { background: rgba(255,255,255,.35); color: #fff; }

/* Letter navigatie */
.letter-nav {
    background: #fff;
    border-radius: 8px;
    padding: .4rem .5rem;
    box-shadow: 0 1px 4px rgba(0,0,0,.08);
    margin-bottom: 1.2rem;
    display: flex;
    flex-wrap: wrap;
    gap: .2rem;
    align-items: center;
}
.letter-nav a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 30px;
    padding: 0 .4rem;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: .85rem;
    color: var(--primary);
    transition: background .12s, color .12s;
    white-space: nowrap;
}
.letter-nav a:hover,
.letter-nav a.active {
    background: var(--primary);
    color: #fff;
}
@media (max-width: 576px) {
    .letter-nav a { min-width: 28px; height: 28px; font-size: .8rem; }
}

/* Boeken tabel */
.books-table th {
    background: var(--primary);
    color: #fff;
    font-weight: 600;
    white-space: nowrap;
}
.books-table tbody tr:hover { background: #f1f5f9; }
.books-table td { vertical-align: middle; }

.badge-genre {
    background: #eef2ff;
    color: #3730a3;
    border-radius: 20px;
    padding: .25em .7em;
    font-size: .78rem;
    font-weight: 500;
}
.badge-ext {
    background: #fef3c7;
    color: #92400e;
    border-radius: 20px;
    padding: .25em .7em;
    font-size: .78rem;
    font-weight: 500;
    text-transform: uppercase;
}

.btn-download {
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: 20px;
    padding: .3rem .9rem;
    font-size: .85rem;
    transition: background .15s;
}
.btn-download:hover { background: #c0392b; color: #fff; }

/* Paginering */
.pagination .page-link {
    color: var(--primary);
    border-color: var(--border);
}
.pagination .page-item.active .page-link {
    background: var(--primary);
    border-color: var(--primary);
}

/* Login pagina */
.login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary) 0%, #1a252f 100%);
}
.login-box {
    width: 100%;
    max-width: 400px;
    background: #fff;
    border-radius: 12px;
    padding: 2.5rem;
    box-shadow: 0 10px 40px rgba(0,0,0,.3);
}
.login-box h2 {
    text-align: center;
    color: var(--primary);
    font-weight: 700;
    margin-bottom: 1.5rem;
}
.login-box .book-icon {
    font-size: 3rem;
    text-align: center;
    display: block;
    margin-bottom: .5rem;
}

/* Admin */
.stat-card {
    background: #fff;
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 1px 4px rgba(0,0,0,.1);
}
.stat-card .stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
}
.stat-card .stat-label {
    color: var(--text-muted);
    font-size: .9rem;
}

/* Sidebar genre */
.genre-list a {
    display: block;
    padding: .3rem .5rem;
    text-decoration: none;
    color: var(--primary);
    border-radius: 5px;
    font-size: .9rem;
    transition: background .1s;
}
.genre-list a:hover, .genre-list a.active {
    background: #e8edf2;
    font-weight: 600;
}
