/* Modern Pagination Styles for Amiran System */

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin: 30px 0;
    flex-wrap: wrap;
}

.pagination .page-item {
    list-style: none;
}

.pagination .page-link {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    background: white;
    color: #334155;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.pagination .page-link:hover {
    background: #eff6ff;
    border-color: #2563eb;
    color: #2563eb;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.15);
}

.pagination .page-item.active .page-link {
    background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
    border-color: #2563eb;
    color: white;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.pagination .page-item.disabled .page-link {
    background: #f8f9fa;
    border-color: #e2e8f0;
    color: #94a3b8;
    cursor: not-allowed;
    opacity: 0.5;
}

.pagination .page-item.disabled .page-link:hover {
    transform: none;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

/* SVG Icons in Pagination */
.pagination .page-link svg {
    width: 16px !important;
    height: 16px !important;
    display: inline-block;
    vertical-align: middle;
}

/* First and Last page arrows */
.pagination .page-item:first-child .page-link,
.pagination .page-item:last-child .page-link {
    min-width: 40px;
}

/* Previous and Next with text */
.pagination .page-link svg + span,
.pagination .page-link span + svg {
    margin: 0 4px;
}

/* Responsive */
@media (max-width: 576px) {
    .pagination .page-link {
        min-width: 36px;
        height: 36px;
        padding: 6px 10px;
        font-size: 0.9rem;
    }
    
    .pagination .page-link svg {
        width: 14px !important;
        height: 14px !important;
    }
}

/* Pagination Container */
.pagination-wrapper {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
    margin: 20px 0;
}

/* Laravel Default Pagination Classes Override */
.pagination > li > a,
.pagination > li > span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    background: white;
    color: #334155;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    margin: 0 4px;
}

.pagination > li > a:hover {
    background: #eff6ff;
    border-color: #2563eb;
    color: #2563eb;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.15);
}

.pagination > .active > span,
.pagination > .active > a {
    background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%) !important;
    border-color: #2563eb !important;
    color: white !important;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.pagination > .disabled > span,
.pagination > .disabled > a {
    background: #f8f9fa;
    border-color: #e2e8f0;
    color: #94a3b8;
    cursor: not-allowed;
    opacity: 0.5;
}

.pagination > .disabled > span:hover,
.pagination > .disabled > a:hover {
    transform: none;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    background: #f8f9fa;
}

/* Fix SVG size in all pagination links */
.pagination svg,
.pagination > li svg,
.pagination > li > a svg,
.pagination > li > span svg {
    width: 16px !important;
    height: 16px !important;
    max-width: 16px !important;
    max-height: 16px !important;
    display: inline-block !important;
    vertical-align: middle !important;
}

/* Tailwind w-5 h-5 override - CRITICAL FIX */
.w-5 {
    width: 1.25rem !important;
    max-width: 1.25rem !important;
}

.h-5 {
    height: 1.25rem !important;
    max-height: 1.25rem !important;
}

svg.w-5 {
    width: 1.25rem !important;
    max-width: 1.25rem !important;
}

svg.h-5 {
    height: 1.25rem !important;
    max-height: 1.25rem !important;
}

/* More specific overrides */
.pagination svg.w-5,
.pagination svg.h-5,
nav svg.w-5,
nav svg.h-5,
[role="navigation"] svg.w-5,
[role="navigation"] svg.h-5 {
    width: 1.25rem !important;
    height: 1.25rem !important;
    max-width: 1.25rem !important;
    max-height: 1.25rem !important;
}

/* Fix inline-flex container */
.relative.inline-flex svg {
    width: 1.25rem !important;
    height: 1.25rem !important;
}

/* Tailwind button classes override */
.relative.inline-flex.items-center {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-width: 40px !important;
    height: 40px !important;
}

