/* Product List Page Styles */

.product-list-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

.api-key-section {
    margin-bottom: 20px;
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.api-key-section .form-group {
    display: flex;
    align-items: flex-end;
    gap: 15px;
    flex-wrap: wrap;
}

.api-key-section label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
    font-size: 14px;
    width: 100%;
}

.api-key-section input[type="text"] {
    flex: 1;
    min-width: 300px;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s ease;
    font-family: 'Courier New', monospace;
}

.api-key-section input[type="text"]:focus {
    outline: none;
    border-color: #667eea;
}

/* Button Styles */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    text-decoration: none;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

/* Loading Indicator */
.loading-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    padding: 20px;
    margin: 20px 0;
    background: #f8f9fa;
    border-radius: 4px;
}

.spinner {
    width: 24px;
    height: 24px;
    border: 3px solid #e0e0e0;
    border-top-color: #4a90e2;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading-indicator span {
    color: #666;
    font-size: 0.95em;
}

/* Error Message */
.error-message {
    padding: 15px 20px;
    margin: 20px 0;
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
}

/* Products Table */
.products-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.products-table thead {
    background: #f8f9fa;
}

.products-table th {
    padding: 12px 15px;
    text-align: left;
    font-weight: 600;
    color: #333;
    border-bottom: 2px solid #dee2e6;
    font-size: 0.9em;
}

.products-table td {
    padding: 12px 15px;
    border-bottom: 1px solid #dee2e6;
    font-size: 0.9em;
    color: #555;
}

.products-table tbody tr:hover {
    background: #f8f9fa;
}

.products-table tbody tr:last-child td {
    border-bottom: none;
}

/* Action Cell */
.action-cell {
    white-space: nowrap;
}

.action-cell .btn {
    padding: 6px 12px;
    border: none;
    border-radius: 4px;
    font-size: 0.85em;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    margin-right: 8px;
}

.action-cell .btn:last-child {
    margin-right: 0;
}

.btn-update {
    background: #4a90e2;
    color: white;
}

.btn-update:hover {
    background: #357abd;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(74, 144, 226, 0.3);
}

.btn-delete {
    background: #e74c3c;
    color: white;
}

.btn-delete:hover {
    background: #c0392b;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(231, 76, 60, 0.3);
}

/* No Products Message */
.no-products {
    padding: 40px;
    text-align: center;
    color: #888;
    font-size: 1.1em;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Responsive Design */
@media (max-width: 1200px) {
    .products-table {
        font-size: 0.85em;
    }
    
    .products-table th,
    .products-table td {
        padding: 10px 12px;
    }
}

@media (max-width: 768px) {
    .product-list-content {
        padding: 15px;
    }

    .api-key-section .form-group {
        flex-direction: column;
        align-items: stretch;
    }

    .api-key-section input[type="text"] {
        width: 100%;
        min-width: auto;
    }

    .api-key-section .btn {
        width: 100%;
        justify-content: center;
    }

    .products-table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }

    .action-cell .btn {
        padding: 8px 12px;
        font-size: 0.9em;
    }
}

