/* === DIAGRAMM-KATEGORIEN === */
.diagram-categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 24px;
    margin: 40px 0;
}

.diagram-category-card {
    display: block;
    padding: 24px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    text-align: center;
    text-decoration: none;
    transition: all 0.25s ease;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.diagram-category-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.12);
    border-color: #00af8c;
}

.cat-name {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: #1e293b;
}

.cat-count {
    font-size: 0.95rem;
    color: #64748b;
}

/* === DIAGRAMM-KARTEN === */
.diagrams-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 32px;
    margin-top: 20px;
}

.diagram-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    border: 1px solid #f1f5f9;
    transition: all 0.25s ease;
    display: flex;
    flex-direction: column;
}

.diagram-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
}

.diagram-card a {
    display: block;
}

.diagram-thumb-placeholder {
    width: 100%;
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8fafc;
    color: #94a3b8;
    font-size: 0.9rem;
    text-align: center;
    padding: 0 10px;
}

.diagram-thumb {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

.card-content {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.diagram-title {
    margin: 0 0 12px;
    font-size: 1.2rem;
}

.diagram-title a {
    color: #0f172a;
    text-decoration: none;
}

.diagram-title a:hover {
    color: #00af8c;
}

.diagram-excerpt {
    color: #64748b;
    line-height: 1.6;
    font-size: 0.95rem;
    flex: 1;
    margin-top: auto;
}

.no-content-message {
    text-align: center;
    padding: 60px 20px;
    grid-column: 1 / -1;
    color: #94a3b8;
}

/* Suchhinweis */
.search-query-info {
    background: #f0fdf4;
    border-left: 4px solid #00af8c;
    padding: 12px 20px;
    margin: 20px 0;
    color: #065f46;
    font-weight: 500;
}

/* Suchformular */
.search-container {
    max-width: 700px;
    margin: 30px auto 40px;
}

.category-search-form {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
}

.category-search-form input[type="text"] {
    flex: 1;
    padding: 14px 20px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.2s ease;
    background: white;
}

.category-search-form input[type="text"]:focus {
    outline: none;
    border-color: #00af8c;
    box-shadow: 0 0 0 3px rgba(0, 175, 140, 0.1);
}

.category-search-form button {
    background: #00af8c;
    color: white;
    border: none;
    padding: 14px 32px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.2s ease;
}

.category-search-form button:hover {
    background: #008f73;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 175, 140, 0.3);
}

.search-suggestions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
    font-size: 0.9rem;
    color: #64748b;
    display: none;
}

.search-suggestions span {
    margin-right: 4px;
}

.search-suggestion-tag {
    background: #f1f5f9;
    padding: 6px 14px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid #e2e8f0;
}

.search-suggestion-tag:hover {
    background: #e0f2fe;
    border-color: #00af8c;
    color: #00af8c;
}

/* === Kategorie-Schnellfilter === */
.page-header {
    position: relative;
}

.diagram-filter-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 20px 0 30px;
    justify-content: flex-end;
}

.filter-btn {
    background: #f1f5f9;
    color: #1e293b;
    padding: 6px 16px;
    border-radius: 20px;
    text-decoration: none;
    font-size: 0.92rem;
    border: 1px solid #e2e8f0;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.filter-btn:hover,
.filter-btn:focus {
    background: #00af8c;
    color: white;
    border-color: #00af8c;
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

/* === PAGINATION === */
.pagination-wrapper {
    display: flex;
    justify-content: center;
    margin: 50px 0 30px;
}

.pagination-wrapper .page-numbers {
    display: flex;
    gap: 8px;
    align-items: center;
    list-style: none;
    padding: 0;
    margin: 0;
}

.pagination-wrapper .page-numbers li {
    list-style: none;
    margin: 0;
    padding: 0;
}

.page-numbers a,
.page-numbers span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    color: #475569;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
}

.page-numbers a:hover {
    background: #00af8c;
    color: white;
    border-color: #00af8c;
    transform: translateY(-2px);
}

.page-numbers .current {
    background: #00af8c;
    color: white;
    border-color: #00af8c;
}

.page-numbers .dots {
    border: none;
    background: transparent;
    color: #94a3b8;
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
    .diagram-categories-grid,
    .diagrams-grid {
        grid-template-columns: 1fr;
    }
    .category-search-form {
        flex-direction: column;
    }
    .diagram-filter-buttons {
        justify-content: center;
    }
}