/* GeoShahr global pagination. Served from public; no Vite build required. */
.gh-pagination {
    width: 100%;
    margin: 2rem auto 0;
    color: #315b40;
    font-family: inherit;
}

.gh-pagination--public {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .65rem;
}

.gh-load-more {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .8rem;
    min-width: 245px;
    max-width: 100%;
    padding: .85rem 1.35rem;
    border: 1px solid #b9d2bf;
    border-radius: 999px;
    background: linear-gradient(135deg, #fff 0%, #f0f8f1 100%);
    color: #234d35;
    text-decoration: none;
    box-shadow: 0 5px 18px rgba(35, 77, 53, .09);
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.gh-load-more:hover {
    transform: translateY(-2px);
    border-color: #79a789;
    box-shadow: 0 9px 24px rgba(35, 77, 53, .14);
}

.gh-load-more:focus-visible,
.gh-page-button:focus-visible,
.gh-page-number:focus-visible {
    outline: 3px solid #e9b62c;
    outline-offset: 3px;
}

.gh-load-more[aria-busy="true"] {
    cursor: progress;
    opacity: .8;
    pointer-events: none;
}

.gh-load-more__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.2rem;
    height: 2.2rem;
    flex: 0 0 2.2rem;
    border-radius: 50%;
    background: #e1efe4;
    color: #2e6843;
}

.gh-load-more__icon svg {
    display: block;
    width: 1.15rem;
    height: 1.15rem;
    transition: transform .2s ease;
}

.gh-load-more:hover .gh-load-more__icon svg {
    transform: translateY(2px);
}

.gh-load-more__text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: .12rem;
    text-align: right;
}

.gh-load-more__text strong {
    color: #234d35;
    font-size: .92rem;
    line-height: 1.6;
}

.gh-load-more__text small {
    color: #6b8874;
    font-size: .72rem;
    line-height: 1.5;
}

.gh-load-more__spinner {
    display: none;
    width: 1.1rem;
    height: 1.1rem;
    border: 2px solid #cbded0;
    border-top-color: #2e6843;
    border-radius: 50%;
    animation: gh-pagination-spin .7s linear infinite;
}

.gh-load-more[aria-busy="true"] .gh-load-more__spinner {
    display: block;
}

.gh-load-more[aria-busy="true"] .gh-load-more__icon {
    display: none;
}

.gh-load-more__hint {
    margin: 0;
    color: #8ba293;
    font-size: .72rem;
    line-height: 1.8;
    text-align: center;
}

.gh-pagination__complete {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .55rem;
    max-width: 100%;
    padding: .75rem 1.15rem;
    border: 1px solid #deebe0;
    border-radius: 999px;
    background: #f6fbf7;
    color: #63816c;
    font-size: .8rem;
    line-height: 1.8;
    text-align: center;
}

.gh-pagination__complete > span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.35rem;
    height: 1.35rem;
    border-radius: 50%;
    background: #dceee0;
    color: #2e6843;
    font-weight: 800;
}

/* Admin: retain direct page navigation for data tables and management lists. */
.gh-pagination--admin {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: .85rem;
    padding: .85rem 1rem;
    border: 1px solid #e1ece3;
    border-radius: 1rem;
    background: #fff;
    box-shadow: 0 3px 14px rgba(35, 77, 53, .05);
}

.gh-pagination__admin-summary {
    color: #6f8977;
    font-size: .8rem;
}

.gh-pagination__admin-summary strong {
    color: #234d35;
}

.gh-pagination__admin-summary span {
    margin: 0 .35rem;
    color: #b3c7b8;
}

.gh-pagination__admin-pages {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: .35rem;
}

.gh-page-button,
.gh-page-number {
    display: inline-flex;
    min-width: 2.15rem;
    min-height: 2.15rem;
    align-items: center;
    justify-content: center;
    padding: .35rem .65rem;
    border: 1px solid #dce9df;
    border-radius: .7rem;
    background: #fff;
    color: #3e674b;
    font-size: .8rem;
    text-decoration: none;
    transition: background .15s ease, border-color .15s ease, color .15s ease;
}

.gh-page-button:hover,
.gh-page-number:hover {
    border-color: #9dc0a5;
    background: #f1f8f2;
}

.gh-page-number.is-current {
    border-color: #245638;
    background: #245638;
    color: #fff;
    font-weight: 800;
}

.gh-page-button.is-disabled {
    cursor: not-allowed;
    opacity: .4;
}

.gh-page-ellipsis {
    padding: 0 .2rem;
    color: #91a899;
}

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

@media (max-width: 640px) {
    .gh-load-more {
        width: 100%;
        min-width: 0;
        padding: .75rem 1rem;
    }

    .gh-pagination--admin {
        justify-content: center;
        padding: .7rem;
    }

    .gh-pagination__admin-summary {
        width: 100%;
        text-align: center;
    }

    .gh-pagination__admin-pages {
        gap: .25rem;
    }

    .gh-page-button,
    .gh-page-number {
        min-width: 1.9rem;
        min-height: 1.9rem;
        padding: .25rem .45rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .gh-load-more,
    .gh-load-more__icon svg,
    .gh-page-button,
    .gh-page-number {
        transition: none;
    }

    .gh-load-more__spinner {
        animation-duration: 1.8s;
    }
}
