.community-section2 {
    position: relative;
    width: 100%;
    height: 420px;
    background:
        linear-gradient(rgba(0,0,0,0.25), rgba(0,0,0,0.25)),
        url('../images/description.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;

    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}
.community-section2 h2 {
    color: white;
    font-size: 65px;
    font-weight: 700;
    line-height: 1.5;
}

/* DOWNLOADS SECTION */
.downloads-section {
    width: 100%;
    background: #ffffff;
    padding: 0 35px 60px;
    font-family: 'Noto Sans Sinhala', sans-serif;
}

.downloads-container {
    max-width: 1280px;
    margin: 0 auto;
    border: 1px solid #26344e;
    border-radius: 12px;
    overflow: hidden;
}

/* TOP BAR */
.downloads-topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding: 10px;
    background: #ffffff;
}

.display-control,
.search-control {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 14px;
}

.display-control select {
    background: #1d293e;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 12px 10px;
    font-size: 12px;
    cursor: pointer;
}

.search-control input {
    width: 220px;
    height: 45px;
    padding: 10px;
    border: 3px solid #dce5f2;
    border-radius: 6px;
    background: #1d293e;
    color: white;
    outline: none;
}

.search-control input:focus {
    border-color: #4b82ff;
}

/* TABLE */
.downloads-table-wrapper {
    width: 100%;
    overflow-x: auto;
}

.downloads-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}

.downloads-table th,
.downloads-table td {
    border: 2px solid #dfe4e8;
    padding: 6px 10px;
    vertical-align: middle;
}

.downloads-table th {
    background: #f1f3f5;
    color: #c4d1e2;
    font-size: 12px;
    font-weight: 700;
    text-align: center;
    height: 38px;
}

.downloads-table th:nth-child(1) {
    width: 57%;
}

.downloads-table th:nth-child(2) {
    width: 15%;
}

.downloads-table th:nth-child(3) {
    width: 15%;
}

.downloads-table th:nth-child(4) {
    width: 13%;
}

.downloads-table tbody tr:nth-child(odd) {
    background: #fafafa;
}

.downloads-table tbody tr:nth-child(even) {
    background: #ffffff;
}

.downloads-table tbody tr:hover {
    background: #f5f7fa;
}

.downloads-table td {
    font-size: 12px;
    color: #111111;
}

/* DOCUMENT TITLE */
.document-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.pdf-icon {
    width: 30px;
    min-width: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #d84343;
}

.pdf-icon i {
    font-size: 24px;
}

.pdf-icon span {
    background: #d84343;
    color: white;
    font-size: 9px;
    padding: 1px 4px;
}

.document-title {
    display: block;
    color: #245482;
    text-decoration: none;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.5;
}

.document-title:hover {
    color: #dda66c;
}

.download-count {
    color: #111111;
    font-size: 11px;
    margin-top: 2px;
}

/* CATEGORY */
.category-link {
    color: #4b82ff;
    font-size: 12px;
}

/* DOWNLOAD BUTTON */
.download-btn {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 100%;
    min-height: 38px;
    background: #dda66c;
    border: 1px solid #a97849;
    border-radius: 4px;

    color: white;
    font-size: 11px;
    text-decoration: none;
    transition: 0.3s;
}

.download-btn:hover {
    background: #c58d52;
}

/* FOOTER */
.downloads-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    padding: 10px;
    background: white;
}

.downloads-footer p {
    font-size: 14px;
    color: #1d293e;
}

/* PAGINATION */
.pagination {
    display: flex;
    align-items: center;
    gap: 5px;
}

#pageNumbers {
    display: flex;
    gap: 5px;
}

.pagination button {
    padding: 9px 12px;
    background: white;
    border: 1px solid #dce5f2;
    border-radius: 6px;
    color: #8c9ab5;
    cursor: pointer;
    font-size: 14px;
}

.pagination button.active {
    background: #4b82ff;
    color: white;
    border-color: #4b82ff;
}

.pagination button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* TABLET */
@media (max-width: 768px) {
    .downloads-section {
        padding: 20px 15px;
    }

    .downloads-topbar {
        flex-wrap: wrap;
    }

    .downloads-table {
        min-width: 800px;
    }

    .downloads-footer {
        flex-wrap: wrap;
    }
}

/* MOBILE */
@media (max-width: 480px) {
    .search-control input {
        width: 160px;
    }

    .downloads-footer {
        flex-direction: column;
        align-items: flex-start;
    }
}
