/* ============================================
   KLEINE NATUUR - HOOFDSTIJLEN
   Bewaar dit bestand als: css/style.css
   ============================================ */

:root {
    --primary-color: #2c5e2e;
    --secondary-color: #8fbc8f;
    --bg-color: #f4f7f4;
    --text-color: #333;
    --white: #ffffff;
    --accent: #d4a017;
}

/* Basis Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
}

/* ============================================
   HEADER & NAVIGATIE (GEUPDATE MET CONTAINER)
   ============================================ */

header {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 1rem 0; /* Geen padding links/rechts, alleen boven/onder */
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

nav {
    display: flex;
    justify-content: space-between; /* Logo links, Menu rechts */
    align-items: center;
    max-width: 1200px; /* ← DE CONTAINER BREEDTE */
    margin: 0 auto;    /* ← CENTREERT DE CONTAINER OP HET SCHERM */
    padding: 0 20px;   /* ← Veilige marge aan beide kanten */
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    flex-shrink: 0;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 25px; /* Ruimte tussen menu-items */
    margin: 0;
    padding: 0;
    /* Geen margin-left: auto meer nodig! */
}

/* ... (rest van de CSS voor dropdowns, hamburger, etc. blijft hetzelfde) ... */

.nav-links a {
    color: var(--white);
    text-decoration: none;
    font-weight: 500;
    padding: 10px;
    transition: background 0.3s;
}

.nav-links a:hover {
    background-color: rgba(255,255,255,0.2);
    border-radius: 4px;
}

.hamburger {
    display: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
}

.bar {
    width: 25px;
    height: 3px;
    background-color: var(--white);
    transition: 0.3s;
}

/* ============================================
   BREADCRUMBS
   ============================================ */

.breadcrumbs {
    background-color: #e8f5e9;
    padding: 1rem 20px;
    font-size: 0.9rem;
    max-width: 1200px; /* ← GELIJK AAN NAV */
    margin: 0 auto;    /* ← CENTREERT DE BREADCRUMBS */
}

.breadcrumbs a {
    color: var(--primary-color);
    text-decoration: none;
}

.breadcrumbs span {
    color: #666;
    margin: 0 5px;
}

/* ============================================
   MAIN CONTENT
   ============================================ */

main {
    max-width: 1200px; /* ← GELIJK AAN NAV */
    margin: 2rem auto; /* ← CENTREERT DE INHOUD */
    padding: 0 20px;   /* ← GELIJK AAN NAV */
}

.category-intro {
    background: var(--white);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
    border-left: 5px solid var(--primary-color);
}

.sub-category {
    margin: 2rem 0;
    padding: 1.5rem;
    background: var(--white);
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.sub-category h2 {
    color: var(--primary-color);
    margin-top: 0;
    border-bottom: 2px solid var(--secondary-color);
    padding-bottom: 0.5rem;
}

.sub-category h2 a {
    color: var(--primary-color);
    text-decoration: none;
}

.species-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 15px;
    margin-top: 1rem;
}

.species-item {
    background: var(--white);
    padding: 1rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.2s;
}

.species-item:hover {
    transform: translateX(5px);
}

.species-item a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1rem;
}

.species-item .latin {
    font-style: italic;
    color: #666;
    font-size: 0.9rem;
    display: block;
    margin-top: 0.3rem;
}

/* ============================================
   SOORT PAGINA (ENTRY CARD)
   ============================================ */

.back-button {
    display: inline-block;
    background-color: var(--secondary-color);
    color: var(--white);
    padding: 0.8rem 1.5rem;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    margin-bottom: 2rem;
    transition: background 0.3s;
}

.back-button:hover {
    background-color: var(--primary-color);
}

.entry-card {
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
    display: flex;
    flex-direction: column;
    border-left: 5px solid var(--primary-color);
}

@media (min-width: 768px) {
    .entry-card {
        flex-direction: row;
    }
}

.entry-image {
    flex: 1;
    min-height: 300px;
    background-color: #ddd;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.entry-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    cursor: pointer;
}

.entry-details {
    flex: 1;
    padding: 2rem;
}

.entry-header h1,
.entry-header h2 {
    margin-top: 0;
    color: var(--primary-color);
    font-size: 2rem;
}

.latin-name {
    font-style: italic;
    color: #666;
    font-size: 1.2rem;
    margin-bottom: 1rem;
    display: block;
    border-bottom: 1px solid #eee;
    padding-bottom: 0.5rem;
}

.meta-info {
    background-color: #f9f9f9;
    padding: 1rem;
    border-left: 4px solid var(--accent);
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}

.meta-info p {
    margin: 0.3rem 0;
}

.meta-info strong {
    color: var(--primary-color);
    min-width: 100px;
    display: inline-block;
}

.description {
    font-size: 1rem;
    color: #444;
}

/* ============================================
   HOME PAGE GRID
   ============================================ */

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 2rem;
}

.category-card {
    background: var(--white);
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
    border-top: 4px solid var(--primary-color);
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 12px rgba(0,0,0,0.15);
}

.category-card h3 {
    margin-top: 0;
    color: var(--primary-color);
}

.category-card a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: bold;
}

.intro-text {
    background: var(--white);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

/* ============================================
   FOOTER
   ============================================ */

footer {
    text-align: center;
    padding: 2rem 20px; /* ← GELIJK AAN NAV */
    background-color: var(--primary-color);
    color: var(--white);
    margin-top: 3rem;
    font-size: 0.9rem;
    max-width: 1200px; /* ← GELIJK AAN NAV */
    margin-left: auto;
    margin-right: auto;
}

/* ============================================
   RESPONSIVE / MOBIEL (768px en kleiner)
   ============================================ */

@media (max-width: 768px) {
    /* Hamburger menu zichtbaar maken */
    .hamburger {
        display: flex;
    }

    /* Header op mobiel: space-between voor ruimte tussen logo en hamburger */
    nav {
        justify-content: space-between;  /* ← Belangrijk: ruimte tussen logo en hamburger */
        gap: 0;  /* Geen gap op mobiel, space-between regelt dat */
    }

    /* Menu verborgen standaard, getoond bij active class */
    .nav-links {
        display: none;
        flex-direction: column;
        width: 100%;
        position: absolute;
        top: 100%;
        left: 0;
        background-color: var(--primary-color);
        padding: 1rem 0;
        gap: 0;
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links li {
        width: 100%;
        text-align: center;
    }

    .nav-links a {
        display: block;
        padding: 12px 20px;
    }

    /* Grids op mobiel: één kolom */
    .category-grid {
        grid-template-columns: 1fr;
    }

    .species-list {
        grid-template-columns: 1fr;
    }

    /* Entry card op mobiel: kolom in plaats van rij */
    .entry-card {
        flex-direction: column;
    }
}