/* ================================
   Stock Market Table
   ================================ */

.stock-data-wrapper {
    width: 100%;
    margin: 0;
    padding: 20px;
    box-sizing: border-box;
    font-family: Arial, "Noto Sans Lao", sans-serif;
}

.container {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
}

/* Title */
.title {
    margin: 0 0 20px;
    font-size: 24px;
    font-weight: 600;
    color: #222;
}


/* ================================
   Filters
   ================================ */

.filters {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.filter-group label {
    font-size: 14px;
    color: #333;
}

.select-box {
    min-width: 110px;
    padding: 7px 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background: #fff;
    font-size: 14px;
    color: #333;
    cursor: pointer;
}


/* ================================
   Table Container
   ================================ */

.table-container {
    width: 100%;
    overflow-x: auto;
    background: #fff;
}


/* ================================
   Table
   ================================ */

#stockTable {
    width: 100%;
    border-collapse: collapse;
    table-layout: auto;
    font-size: 14px;
    color: #333;
}


/* Header */

#stockTable thead th {
    padding: 10px 8px;
    text-align: right;
    font-weight: 500;
    color: #333;
    background: #fff;
    border-bottom: 1px solid #d6d6d6;
    white-space: nowrap;
}


/* First column */

#stockTable thead th:first-child,
#stockTable tbody td:first-child {
    text-align: left;
}


/* Body cells */

#stockTable tbody td {
    padding: 9px 8px;
    text-align: right;
    white-space: nowrap;
    border-bottom: 1px solid #ddd;
    font-size: 14px;
}


/* ================================
   Zebra Rows
   ================================ */

#stockTable tbody tr:nth-child(odd) {
    background-color: #f7f7f7;
}

#stockTable tbody tr:nth-child(even) {
    background-color: #ffffff;
}


/* Hover */

#stockTable tbody tr:hover {
    background-color: #eeeeee;
}


/* ================================
   Change Values
   ================================ */

.change-up {
    color: #008000;
    font-weight: 500;
}

.change-down {
    color: #e00000;
    font-weight: 500;
}

.change-neutral {
    color: #333;
}


/* ================================
   Loading
   ================================ */

.loading {
    text-align: center !important;
    padding: 20px !important;
    color: #777;
}

/* ================================
   Responsive
   ================================ */

@media (max-width: 768px) {

    .stock-data-wrapper {
        padding: 10px;
    }

    .title {
        font-size: 20px;
    }

    .filters {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    #stockTable {
        font-size: 13px;
    }

    #stockTable thead th,
    #stockTable tbody td {
        padding: 8px 6px;
    }
}


/* =================================
   Pagination
   ================================= */

.pagination {
    display: flex;
    justify-content: center;
    gap: 16px;
    align-items: center;

    margin-top: 20px;
    margin-bottom: 20px;
}

.pagination-button {
    padding: 8px 16px;

    border: 1px solid #ddd;
    border-radius: 4px;

    background: #fff;

    color: #333;

    font-size: 14px;

    cursor: pointer;

    transition: background 0.2s;
}

.pagination-button:hover:not(:disabled) {
    background: #f2f2f2;
}

.pagination-button:disabled {
    color: #aaa;
    background: #f5f5f5;

    cursor: not-allowed;
}