/* Minimal Contrast Design system */
.circulars-control-panel {
    background: transparent;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 16px;
}

.search-input-wrapper input {
    border-color: #cbd5e1;
    background-color: #ffffff;
    color: #1e293b;
    transition: all 0.2s ease;
    font-size: 14px;
}

.search-input-wrapper input:focus {
    border-color: #ff7900;
    box-shadow: 0 0 0 2px rgba(255, 121, 0, 0.1);
    outline: none;
}

/* Modern Flat Year Tabs */
.year-tabs-container {
    display: flex;
    gap: 8px;
    padding: 4px 2px;
}

.year-tab {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    color: #001055 !important; /* Inactive tabs use navy blue for theme combination */
    padding: 6px 14px;
    font-size: 13px;
    font-weight: 500;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    flex-shrink: 0; /* Prevents text warping or squeezing on mobile devices */
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1.2;
}

.year-tab:hover {
    border-color: #ff7900;
    color: #ff7900 !important;
    background-color: rgba(255, 121, 0, 0.02);
}

.year-tab.active {
    background-color: #ff7900 !important; /* Active tab uses Accent Orange */
    color: #ffffff !important;
    border-color: #ff7900 !important;
    font-weight: 600;
    box-shadow: 0 2px 6px rgba(255, 121, 0, 0.2);
}

/* Table Design - Minimal Contrast */
.custom-table-card {
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    background: #ffffff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02) !important;
}

.circulars-table {
    margin: 0;
}

.circulars-table thead {
    background-color: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

.circulars-table thead th {
    font-weight: 600;
    color: #475569;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 14px 20px;
}

.circulars-table td.Date-cell {
    white-space: nowrap;
}

.circulars-table tbody tr {
    transition: background-color 0.15s ease;
    border-bottom: 1px solid #f1f5f9;
}

.circulars-table tbody tr:last-child {
    border-bottom: none;
}

.circulars-table tbody tr:hover {
    background-color: #f8fafc !important;
}

/* Minimalist View PDF Button */
.btn-view-pdf {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    color: #475569;
    padding: 6px 14px;
    font-size: 13px;
    font-weight: 500;
    border-radius: 6px;
    transition: all 0.15s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none !important;
}

.btn-view-pdf:hover {
    background: #f1f5f9;
    border-color: #cbd5e1;
    color: #0f172a;
}

.btn-view-pdf i {
    color: #ef4444; /* standard red for PDF */
}

/* Local overrides for badge elements to bypass global styles */
.badge-year {
    background-color: #ff7900 !important;
    color: #ffffff !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    padding: 4px 10px !important;
    line-height: 1.2 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.badge-new {
    background-color: rgba(239, 68, 68, 0.08) !important;
    color: #ef4444 !important;
    border: 1px solid rgba(239, 68, 68, 0.25) !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    padding: 4px 10px !important;
    line-height: 1.2 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

/* Pagination - Minimal styling */
.pagination-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 20px;
    padding: 12px 16px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: #ffffff;
}

.pagination-pages {
    display: flex !important;
    gap: 6px !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: center !important;
}

#pageNumbers {
    display: flex !important;
    gap: 4px !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
}

.page-btn {
    height: 34px;
    padding: 0 12px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    color: #475569;
    font-size: 13px;
    font-weight: 500;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.15s ease;
}

.page-btn:hover:not(:disabled) {
    border-color: #cbd5e1;
    background-color: #f8fafc;
    color: #0f172a;
}

.page-btn.active {
    background-color: #f1f5f9;
    border-color: #cbd5e1;
    color: #0f172a;
    font-weight: 600;
}

.page-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.scrollable-tabs-wrapper {
    overflow-x: auto;
    display: flex;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none; /* Firefox */
}

.scrollable-tabs-wrapper::-webkit-scrollbar {
    display: none; /* Safari and Chrome */
}

/* Mobile layout adaptations */
@media (max-width: 768px) {
    .circulars-table thead {
        display: none;
    }
    
    .circulars-table tbody tr {
        display: block;
        padding: 16px 12px;
        border-bottom: 1px solid #f1f5f9;
    }
    
    .circulars-table tbody tr:hover {
        background-color: transparent !important;
    }
    
    .circulars-table td {
        display: block;
        width: 100% !important;
        padding: 0 !important;
        border: none;
    }
    
    .circulars-table td.Date-cell {
        margin-bottom: 8px;
    }
    
    .circulars-table td.title-cell {
        margin-bottom: 12px;
    }
    
    .circulars-table td.action-cell {
        text-align: left !important;
    }
    
    .circulars-table td.action-cell .btn-view-pdf {
        width: 100%;
        padding: 8px 0;
        background-color: #f8fafc;
    }
    
    .pagination-container {
        flex-direction: column;
        gap: 12px;
        align-items: center;
        padding: 16px;
    }
    
    .pagination-pages {
        width: 100% !important;
        justify-content: center !important;
        display: flex !important;
        flex-wrap: nowrap !important;
    }
}

@media (max-width: 576px) {
    .page-btn {
        min-width: 32px !important;
        height: 32px !important;
        font-size: 12px !important;
        padding: 0 6px !important;
    }
    .pagination-pages {
        gap: 4px !important;
    }
    #pageNumbers {
        gap: 3px !important;
    }
}
