/* Amazon Seller Dashboard Styles */

/* ============================================
   SELLER FILTERS
   ============================================ */
.seller-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: flex-end;
    padding: 1.25rem;
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    margin-bottom: 1.5rem;
}

.seller-filters .filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.seller-filters .filter-group label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #999;
    font-weight: 600;
}

.seller-filters .filter-group select,
.seller-filters .filter-group input {
    padding: 0.6rem 1rem;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    background: #fff;
    font-size: 0.85rem;
    color: #333;
    transition: all 0.2s ease;
}

.seller-filters .filter-group select:hover,
.seller-filters .filter-group select:focus,
.seller-filters .filter-group input:hover,
.seller-filters .filter-group input:focus {
    border-color: #000;
    outline: none;
}

.seller-filters .date-range-inputs {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.seller-filters .date-range-inputs span {
    color: #999;
    font-size: 0.85rem;
}

.seller-filters .date-range-inputs input {
    width: 130px;
}

.seller-filters .refresh-button {
    padding: 0.6rem 1.2rem;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    background: #fff;
    font-size: 0.85rem;
    font-weight: 600;
    color: #000;
    cursor: pointer;
    transition: all 0.2s ease;
}

.seller-filters .refresh-button:hover {
    background: #f5f5f5;
    border-color: #d0d0d0;
}

/* ============================================
   SELLER API STATUS
   ============================================ */
.seller-api-status {
    padding: 1.25rem;
    margin-bottom: 1.5rem;
    border-radius: 10px;
    text-align: center;
}

.seller-success-full {
    background: linear-gradient(135deg, #f4fff5 0%, #fff 100%);
    border: 1px solid #d8e8e0;
    color: #5cb060;
    font-weight: 600;
    font-size: 1rem;
}

.seller-error-full {
    background: linear-gradient(135deg, #fff8f8 0%, #fff 100%);
    border: 1px solid #e8d8d8;
    color: #d44;
    font-weight: 500;
}

.seller-error-full h3 {
    margin: 0 0 0.75rem 0;
    font-size: 1.1rem;
}

.seller-error-full p {
    margin: 0.5rem 0;
    font-size: 0.9rem;
    color: #666;
}

.seller-error-full ul {
    margin: 0.75rem 0;
    padding-left: 1.5rem;
    font-size: 0.9rem;
    color: #666;
}

.seller-error-full li {
    margin: 0.25rem 0;
    font-family: monospace;
    background: #f5f5f5;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    display: inline-block;
}

/* ============================================
   SELLER SUMMARY CARDS
   ============================================ */
.seller-summary-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.seller-kpi-card {
    padding: 1.5rem 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    transition: all 0.3s ease;
}

.seller-kpi-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    border-color: #d0d0d0;
}

.seller-kpi-card.sales {
    border-left: 3px solid #000;
}

.seller-kpi-card.orders {
    border-left: 3px solid #333;
}

.seller-kpi-card.units {
    border-left: 3px solid #666;
}

.seller-kpi-card.revenue {
    border-left: 3px solid #888;
}

.seller-kpi-card.returns {
    border-left: 3px solid #d44;
}

.seller-kpi-card.inventory {
    border-left: 3px solid #5cb060;
}

.seller-kpi-card span {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #999;
    font-weight: 600;
}

.seller-kpi-card strong {
    font-size: 1.8rem;
    font-weight: 700;
    color: #000;
}

.seller-kpi-card small {
    font-size: 0.75rem;
    color: #aaa;
}

/* ============================================
   SELLER CHARTS
   ============================================ */
.seller-charts-section {
    margin-bottom: 1.5rem;
}

.chart-controls {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
}

.chart-controls h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    color: #000;
}

.chart-toggles {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.toggle-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: #333;
    cursor: pointer;
    transition: all 0.2s ease;
}

.toggle-label:hover {
    color: #000;
}

.toggle-label input {
    cursor: pointer;
    width: 18px;
    height: 18px;
}

.toggle-label span {
    font-weight: 500;
}

.seller-charts-section .chart-card {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    padding: 1.25rem;
}

.seller-charts-section .chart-container {
    position: relative;
    height: 350px;
}

/* ============================================
   SELLER TABS
   ============================================ */
.seller-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    border-bottom: 2px solid #e5e5e5;
    padding-bottom: 0;
}

.seller-tab {
    padding: 0.75rem 1.5rem;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    font-size: 0.9rem;
    font-weight: 600;
    color: #666;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.seller-tab:hover {
    color: #333;
    background: #f9f9f9;
}

.seller-tab.active {
    color: #000;
    border-bottom-color: #000;
}

.seller-tab .tab-icon {
    font-size: 1.1rem;
}

/* ============================================
   SELLER DATA SECTIONS
   ============================================ */
.seller-data-section {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    padding: 1.25rem;
    margin-bottom: 1.5rem;
}

.seller-data-section .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.seller-data-section .section-header h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    color: #000;
}

.seller-data-section .data-count {
    font-size: 0.85rem;
    color: #888;
    font-weight: 500;
}

.seller-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}

.seller-table thead {
    border-bottom: 2px solid #e5e5e5;
}

.seller-table th {
    padding: 0.75rem 0.5rem;
    text-align: left;
    font-weight: 700;
    color: #000;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: all 0.2s ease;
}

.seller-table th:hover {
    background: #f5f5f5;
}

.seller-table th.sort-asc::after {
    content: " ↑";
}

.seller-table th.sort-desc::after {
    content: " ↓";
}

.seller-table tbody tr {
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.2s ease;
}

.seller-table tbody tr:hover {
    background: #fafafa;
}

.seller-table td {
    padding: 0.75rem 0.5rem;
    color: #333;
}

.seller-table .no-data {
    text-align: center;
    padding: 2rem;
    color: #999;
    font-style: italic;
}

/* ============================================
   STATUS BADGES
   ============================================ */
.status-badge {
    display: inline-block;
    padding: 0.3rem 0.6rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.status-badge.status-shipped {
    background: #e8f5e9;
    color: #2e7d32;
}

.status-badge.status-pending {
    background: #fff8e1;
    color: #f57c00;
}

.status-badge.status-delivered {
    background: #e8f5e9;
    color: #2e7d32;
}

.status-badge.status-cancelled {
    background: #ffe8e8;
    color: #d44;
}

.status-badge.status-instock {
    background: #e8f5e9;
    color: #2e7d32;
}

.status-badge.status-lowstock {
    background: #fff8e1;
    color: #f57c00;
}

.status-badge.status-outofstock {
    background: #ffe8e8;
    color: #d44;
}

/* ============================================
   TABLE HIGHLIGHTING
   ============================================ */
.seller-row td.low-stock {
    color: #f57c00;
    font-weight: 600;
}

.seller-row td.out-of-stock {
    color: #d44;
    font-weight: 600;
}

/* ============================================
   PAGINATION
   ============================================ */
.table-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
    margin-top: 1rem;
}

.pagination-button {
    padding: 0.5rem 1rem;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    background: #fff;
    font-size: 0.85rem;
    font-weight: 500;
    color: #333;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pagination-button:hover:not(:disabled) {
    background: #f5f5f5;
    border-color: #d0d0d0;
}

.pagination-button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */
@media (max-width: 1200px) {
    .seller-summary-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .seller-summary-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .seller-filters {
        flex-direction: column;
        align-items: stretch;
    }

    .seller-filters .date-range-inputs {
        flex-direction: column;
    }

    .seller-filters .date-range-inputs input {
        width: 100%;
    }

    .seller-filters .filter-group select,
    .seller-filters .filter-group input {
        width: 100%;
    }

    .seller-filters .refresh-button {
        width: 100%;
        justify-content: center;
    }

    .chart-controls {
        flex-direction: column;
        gap: 0.75rem;
    }

    .chart-toggles {
        justify-content: flex-start;
    }
}

@media (max-width: 600px) {
    .seller-summary-grid {
        grid-template-columns: 1fr;
    }

    .seller-kpi-card {
        padding: 1.25rem 1rem;
    }

    .seller-kpi-card strong {
        font-size: 1.5rem;
    }

    .seller-tabs {
        flex-wrap: wrap;
    }

    .chart-container {
        height: 280px;
    }

    .seller-table {
        font-size: 0.75rem;
    }

    .seller-table th,
    .seller-table td {
        padding: 0.5rem 0.3rem;
    }

    .table-pagination {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
}
