/* ==========================================================
   PAGINATION BAR (celý řádek)
   ========================================================== */
.dg-pagination-bar {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 14px;
    padding: 0.5rem 0;
    color: #333;
    flex-wrap: wrap;         /* podporuje zalomení při malém prostoru */
    background-color: #FBF9F7;
    border-top: 1px solid#e6e6e6;
    border-bottom: 1px solid#e6e6e6;
}

/* Separator " | " */
.dg-sep {
    display: inline-flex;
    align-items: center;
    padding: 0 4px;
    color: #888;
    opacity: 0.7;
    user-select: none;
    font-size: 14px;
}


/* ==========================================================
   1) PAGINATION
   ========================================================== */
.dg-pagination {
    display: flex;
    align-items: center;
    gap: 0.2rem;            /* menší mezery mezi stránkami */
    flex-wrap: wrap;
}

.dg-page {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 26px;
    height: 26px;
    padding: 0 6px;
    font-size: 13px;
    border-radius: 4px;
    border: 1px solid transparent;
    text-decoration: none;
    color: #333;
    cursor: pointer;
}

.dg-page:hover {
    background: #f0f0f0;
    border-color: #ccc;
}
/* aktuální stránka */
.dg-page.dg-current {
    background: #333;
    color: #fff !important;
    border-color: #333;
    cursor: default;
}

/* disabled / ellipsis */
.dg-page.dg-ellipsis {
    cursor: default;
    color: #777;
    border: none;
}

/* šipky */
.dg-page.dg-first,
.dg-page.dg-prev,
.dg-page.dg-next,
.dg-page.dg-last {
    font-weight: bold;
    padding: 0 8px;
}


/* -----------------------------------------
   Hláška: Žádné záznamy nenalezeny
------------------------------------------*/
.dg-no-results {
    font-size: 13px;
    color: #888;
    padding: 0 6px;
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
}


/* ==========================================================
   2) PER PAGE SELECT
   ========================================================== */
.dg-per-page {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* label – zarovnání na střed */
.dg-per-page label {
    display: flex;
    align-items: center;
    height: 28px;
    line-height: 28px;
    padding: 0;
    margin: 0;
    font-size: 13px;
    color: #555;
}

/* select – jednotná výška */
.dg-per-page select {
    height: 28px;
    line-height: 28px;
    padding: 0 6px;
    font-size: 13px;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 4px;
}


/* ==========================================================
   3) TOTAL COUNT
   ========================================================== */
.dg-total-count {
    font-size: 13px;
    color: #555;
    display: flex;
    align-items: center;
}


/* ==========================================================
   4) SORT FILTR
   ========================================================== */
.dg-sort-select {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.dg-sort-select label {
    display: flex;
    align-items: center;
    height: 28px;
    line-height: 28px;
    font-size: 13px;
    color: #555;
    margin: 0;
    padding: 0;
}

.dg-sort-select select {
    height: 28px;
    line-height: 28px;
    padding: 0 6px;
    font-size: 13px;
    border-radius: 4px;
    border: 1px solid #ccc;
    background: #fff;
}


/* ==========================================================
   GLOBÁLNÍ ZAROVNÁNÍ VŠECH PRVKŮ TOOLBARU
   ========================================================== */
.dg-pagination-bar > * {
    display: flex;
    align-items: center;
}

/* ==========================================================
   MICRO SPINNER U sort a perPage formu
   ========================================================== */

.dg-spinner {
    display: none;
    width: 14px;
    height: 14px;
    border: 2px solid #ccc;
    border-top-color: #333;
    border-radius: 50%;
    margin-left: 6px;
    animation: dg-spin 0.6s linear infinite;
}

@keyframes dg-spin {
    to { transform: rotate(360deg); }
}


/* ==========================================================
   RESPONSIVITA
   ========================================================== */
@media (max-width: 800px) {
    .dg-pagination-bar {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }
}

@media (max-width: 480px) {
    .dg-page {
        min-width: 22px;
        height: 22px;
        font-size: 11px;
    }

    .dg-per-page select,
    .dg-sort-select select {
        font-size: 12px;
    }

    .dg-total-count,
    .dg-no-results {
        font-size: 12px;
    }
}
