.tablecode-wrapper {
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.tablecode-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: white;
    border-radius: 8px;
    overflow: hidden;
}

.tablecode-table th {
    background: var(--main-color, #0a0d35);
    padding: 15px;
    text-align: left;
    font-weight: 600;
    color: white;
    text-transform: uppercase;
    font-size: 14px;
    letter-spacing: 0.5px;
}

.tablecode-table td {
    padding: 15px;
    border-bottom: 1px solid #dee2e6;
    vertical-align: middle;
}

.tablecode-table tr {
    background: white;
    transition: background-color 0.3s ease;
}

.tablecode-table tbody tr:hover {
    background: #f8f9fa;
}

.tablecode-thumbnail {
    width: 120px;
    height: auto;
    border-radius: 6px;
    overflow: hidden;
}

.tablecode-thumbnail img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
}

.tablecode-product-title {
    color: #343a40;
    text-decoration: none;
    font-weight: 500;
    display: block;
    margin-bottom: 5px;
    font-size: 16px;
}

.tablecode-product-title:hover {
    color: var(--main-color, #0a0d35);
}

.tablecode-category {
    display: inline-block;
    padding: 4px 8px;
    background: #f0f0f0;
    border-radius: 4px;
    font-size: 12px;
    color: #666;
}

.tablecode-date {
    color: #666;
    font-size: 14px;
}

/* Generic Buy button */
.tablecode-buy-button {
    display: inline-block !important;
    padding: 10px 14px !important;
    width: auto !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
    color: #ffffff !important;
    text-decoration: none !important;
    text-align: center !important;
    background: var(--main-color, #0a0d35) !important;
    border: 1px solid var(--main-color, #0a0d35) !important;
    border-radius: 4px !important;
    box-shadow: none !important;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease !important;
    margin-left: 10px;
}

.tablecode-buy-button:hover {
    background: #ffffff !important;
    color: var(--main-color, #0a0d35) !important;
    border-color: var(--main-color, #0a0d35) !important;
}

.tablecode-action-buttons {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.tablecode-pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
    padding: 20px 0;
}

.tablecode-pagination .page-numbers {
    padding: 8px 16px;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    color: var(--main-color, #0a0d35);
    text-decoration: none;
    transition: all 0.2s;
}

.tablecode-pagination .current {
    background: var(--main-color, #0a0d35);
    color: white;
    border-color: var(--main-color, #0a0d35);
}

.tablecode-load-more {
    display: block;
    margin: 20px auto;
    padding: 12px 24px;
    background: var(--main-color, #0a0d35);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
}

.tablecode-load-more:hover {
    background: #0d1245;
}

.tablecode-spinner {
    display: none;
    width: 30px;
    height: 30px;
    margin: 20px auto;
    border: 3px solid rgba(0,0,0,0.1);
    border-radius: 50%;
    border-top-color: var(--main-color, #0a0d35);
    animation: spin 1s ease-in-out infinite;
}

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

@media (max-width: 768px) {
    .tablecode-table {
        display: block;
        overflow-x: auto;
    }
    
    @media (max-width: 576px) {
        .tablecode-table thead {
            display: none;
        }
        
        .tablecode-table tbody tr {
            display: block;
            margin-bottom: 20px;
            border: 1px solid #dee2e6;
            border-radius: 8px;
        }
        
        .tablecode-table tbody td {
            display: block;
            text-align: right;
            position: relative;
            padding-left: 130px;
            min-height: 30px;
        }
        
        .tablecode-table tbody td:before {
            content: attr(data-label);
            position: absolute;
            left: 15px;
            top: 50%;
            transform: translateY(-50%);
            font-weight: 600;
            color: var(--main-color, #0a0d35);
            text-align: left;
        }
        
        .tablecode-table td:last-child {
            text-align: center;
            padding-left: 15px;
        }
        
        .tablecode-thumbnail {
            width: 100%;
            max-width: 200px;
            margin: 0 auto;
        }

        .tablecode-action-buttons {
            justify-content: center;
        }
    }
}