/* Grid Layout */
.pending-posts-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    padding: 20px;
    max-width: 1600px;
    margin: 0 auto;
}

/* Card Styles */
.post-card {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    border-top: 4px solid #ccc;
    overflow: hidden;
}

.post-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

/* Post Type Colors */
.egp-card { border-color: #1e88e5; }
.news-card { border-color: #ff9800; }
.mpeople-card { border-color: #4caf50; }
.article-card { border-color: #9c27b0; }
.pha-card { border-color: #f44336; }
.dgallery-card { border-color: #795548; }
.department-card { border-color: #607d8b; }
.complaint-card { border-color: #e91e63; }

/* Card Content */
.post-card-content {
    padding: 20px;
}

.post-title {
    margin: 0 0 15px 0;
    font-size: 18px;
    line-height: 1.4;
    font-weight: 500;
}

.post-title a {
    color: #333;
    text-decoration: none;
    transition: color 0.2s ease;
}

.post-title a:hover {
    color: #1e88e5;
}

/* Meta Information */
.post-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    font-size: 14px;
    color: #666;
}

.post-type {
    background: #f5f5f5;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
}

.post-date {
    color: #888;
}

/* Approve Button */
.approve-button {
    width: 100%;
    padding: 12px;
    background: #1e88e5;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.approve-button:hover {
    background: #1565c0;
}

.approve-button:active {
    transform: scale(0.98);
}

.approve-button:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Skeleton Loading */
.skeleton-loader {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    padding: 20px;
    max-width: 1600px;
    margin: 0 auto;
}

.skeleton-card {
    background: #fff;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.skeleton-title,
.skeleton-meta,
.skeleton-button {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
    border-radius: 4px;
}

.skeleton-title {
    height: 24px;
    margin-bottom: 15px;
}

.skeleton-meta {
    height: 16px;
    margin-bottom: 15px;
    width: 70%;
}

.skeleton-button {
    height: 40px;
    width: 100%;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Empty State */
.no-posts-message {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px;
    background: #f5f5f5;
    border-radius: 8px;
    color: #666;
}

/* Responsive Design */
@media (max-width: 1400px) {
    .pending-posts-grid,
    .skeleton-loader {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 1024px) {
    .pending-posts-grid,
    .skeleton-loader {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .pending-posts-grid,
    .skeleton-loader {
        grid-template-columns: 1fr;
        padding: 10px;
    }
    
    .post-title {
        font-size: 16px;
    }
    
    .post-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    
    .approve-button {
        padding: 10px;
        font-size: 14px;
    }
    .filter-group {
        flex-direction: column;
        align-items: stretch;
    }

    .filter-select,
    .search-input {
        width: 100%;
    }
}

/* Print Styles */
@media print {
    .pending-posts-grid {
        display: block;
    }
    
    .post-card {
        page-break-inside: avoid;
        margin-bottom: 20px;
        box-shadow: none;
        border: 1px solid #ddd;
    }
    
    .approve-button {
        display: none;
    }
}


/* Pagination Styles */
.pagination {
    margin-top: 30px;
    margin-bottom: 30px;
}

.pagination-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.pagination-button {
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    border: 1px solid #e0e0e0;
    background: #fff;
    color: #333;
    border-radius: 8px;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pagination-button:hover {
    background: #f5f5f5;
    border-color: #1e88e5;
    color: #1e88e5;
}

.pagination-button.active {
    background: #1e88e5;
    border-color: #1e88e5;
    color: white;
}

.pagination-button:disabled {
    background: #f5f5f5;
    border-color: #e0e0e0;
    color: #999;
    cursor: not-allowed;
}

.pagination-ellipsis {
    color: #666;
    padding: 0 4px;
}

/* Grid Layout Update */
.pending-posts-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    padding: 20px;
    max-width: 1600px;
    margin: 0 auto;
}

/* Responsive Pagination */
@media (max-width: 768px) {
    .pagination-container {
        gap: 4px;
    }

    .pagination-button {
        min-width: 36px;
        height: 36px;
        padding: 0 8px;
        font-size: 14px;
    }

    .pagination-ellipsis {
        display: none;
    }
}

/* Skeleton Loading Update */
.skeleton-loader {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

@media (max-width: 1400px) {
    .pending-posts-grid,
    .skeleton-loader {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 1024px) {
    .pending-posts-grid,
    .skeleton-loader {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .pending-posts-grid,
    .skeleton-loader {
        grid-template-columns: 1fr;
    }
}


/* Filter Controls */
.filter-controls {
    margin-bottom: 20px;
    background: #fff;
    max-width: 600px;
    margin: 0 auto 20px;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
}

.filter-select {
    width: 100%;
    max-width: 500px;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: #fff;
    font-size: 14px;
    color: #333;
    cursor: pointer;
    transition: all 0.2s ease;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 16px;
    padding-right: 32px;
}

.filter-select:hover,
.filter-select:focus {
    border-color: #1e88e5;
    outline: none;
}

.search-input {
    width: 100%;
    max-width: 500px;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    color: #333;
    transition: all 0.2s ease;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3ccircle cx='11' cy='11' r='8'%3e%3c/circle%3e%3cline x1='21' y1='21' x2='16.65' y2='16.65'%3e%3c/line%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 16px;
    padding-right: 32px;
}

.search-input:hover,
.search-input:focus {
    border-color: #1e88e5;
    outline: none;
    box-shadow: 0 0 0 2px rgba(30,136,229,0.1);
}

.search-input::placeholder {
    color: #999;
}

/* Responsive Filters */
@media (max-width: 768px) {
    .filter-group {
        flex-direction: column;
    }

    .filter-controls {
        padding: 10px;
    }

    .filter-select,
    .search-input {
        max-width: 100%;
    }
}

/* Loading State */
.filter-controls.loading {
    opacity: 0.7;
    pointer-events: none;
}

/* Empty State */
.no-results {
    text-align: center;
    padding: 40px;
    background: #f5f5f5;
    border-radius: 8px;
    color: #666;
    margin-top: 20px;
}

/* Filter Active Indicators */
.filter-active {
    background-color: #e3f2fd;
    border-color: #1e88e5;
}