/*  body {
            font-family: Arial, sans-serif;
            background-color: #f7f7f7;
            margin: 0;
            padding: 20px;
        }
*/

body {
           
            background-color: white;
            
        }
        .category-container {
            max-width: 1200px;
            margin: 0 auto;
            background: #fff;
            padding: 10px;
            border-radius: 10px;
            box-shadow: 0 2px 10px rgba(0,0,0,0.1);
        }

        .category-title {
            color: #2c3e50;
            border-bottom: 2px solid #007acc;
            padding-bottom: 10px;
            margin-bottom: 15px;
            font-size: 1.5em;
        }

        .search-container {
            margin-bottom: 20px;
        }

        #postSearch {
            width: 100%;
            max-width: 500px;
            padding: 12px 15px;
            border: 1px solid #ddd;
            border-radius: 4px;
            font-size: 16px;
            box-sizing: border-box;
        }

        .posts-table {
            table-layout: fixed;
            width: 100%;
            border-collapse: collapse;
            margin-top: 20px;
            border-left: none;
        }
        
        .posts-table th:nth-child(1),
        .posts-table td:nth-child(1) {
            width: 80%;
        }

        .posts-table th:nth-child(2),
        .posts-table td:nth-child(2) {
            width: 20%;
            min-width: 120px;
        }

        .posts-table th {
            background-color: #f5f5f5;
            padding: 12px 15px;
            text-align: left;
            font-weight: 600;
            border-bottom: 2px solid #ddd;
            border-left: 2px solid #ddd;
        }

        .posts-table td {
            padding: 12px 15px;
            border-bottom: 1px solid #eee;
            border-right: none;
            border-left: none;
            vertical-align: top;
        }

        .posts-table tr:hover td {
            background-color: #f9f9f9;
        }

        .post-link {
            text-decoration: none;
            color: #2c3e50;
            font-weight: 500;
        }

        .post-link:hover {
            color: #007acc;
            text-decoration: underline;
        }

        .post-date {
            color: #666;
            font-size: 0.9em;
            white-space: nowrap;
        }

        .error-message {
            color: #dc3545;
            font-style: italic;
            padding: 20px;
            text-align: center;
        }

        .loading {
            color: #6c757d;
            font-style: italic;
            padding: 20px;
            text-align: center;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .no-results {
            color: #6c757d;
            font-style: italic;
            padding: 20px;
            text-align: center;
            display: none;
        }

        .loading-spinner {
            display: inline-block;
            width: 20px;
            height: 20px;
            border: 3px solid rgba(0,0,0,.1);
            border-radius: 50%;
            border-top-color: #007acc;
            animation: spin 1s ease-in-out infinite;
            margin-right: 10px;
        }

        .pagination {
            display: flex;
            justify-content: center;
            margin-top: 20px;
            gap: 5px;
        }

        .pagination button {
            padding: 8px 12px;
            border: 1px solid #ddd;
            background-color: #fff;
            color: #495057; /* Dark gray text */
            border-radius: 4px;
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .pagination button:hover:not(:disabled) {
            background-color: blue;
            color: white;
            border-color: #0d6efd;
        }

        .pagination button.active {
            background-color: #007acc;
            color: white;
            border-color: #007acc;
        }

        .pagination button:disabled {
            opacity: 0.5;
            cursor: not-allowed;
        }

        @keyframes spin {
            to { transform: rotate(360deg); }
        }

        @media (max-width: 500px) {
    .category-container {
        overflow-x: auto;
        padding: 10px 5px;
    }
    
    .posts-table {
        min-width: 600px; /* Ensure table has minimum width */
        display: table; /* Override any block display */
    }
    
    .posts-table thead {
        display: table-header-group; /* Show headers */
    }
    
    .posts-table tr {
        display: table-row; /* Show as normal rows */
        margin-bottom: 0;
        border: none;
    }
    
    .posts-table td {
        display: table-cell; /* Show as normal cells */
        text-align: left;
        padding-left: 15px;
        padding-right: 15px;
        position: static;
    }
    
    .posts-table td::before {
        display: none; /* Remove the data-label pseudo-elements */
    }
    
    .pagination {
        overflow-x: auto;
        justify-content: flex-start;
        padding-bottom: 10px;
    }
    
    .pagination button {
        min-width: 36px;
    }
  }
