/* Luxin Interactive Table Styles */

.luxin-container {
    display: flex;
    gap: 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    position: relative;
    width: 100%;
    max-width: 100%;
    min-height: 400px;
    overflow: visible;
}

.main-table-container {
    flex: 1;
    min-width: 0;
    transition: margin-right 0.3s ease, width 0.3s ease;
}

.luxin-container:has(.detail-panel.open) .main-table-container {
    margin-right: 620px;
}

.main-table-container h3 {
    margin-top: 0;
    margin-bottom: 15px;
    color: #333;
    font-size: 18px;
}

.table-wrapper {
    overflow-x: auto;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.luxin-container table {
    border-collapse: collapse;
    width: 100%;
    background: white;
}

.luxin-container thead {
    background-color: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
}

.luxin-container th {
    padding: 12px;
    text-align: left;
    font-weight: 600;
    color: #495057;
    border-bottom: 1px solid #dee2e6;
}

.luxin-container td {
    padding: 10px 12px;
    border-bottom: 1px solid #f0f0f0;
    color: #333;
}

.luxin-container tbody tr {
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.luxin-container tbody tr:hover {
    background-color: #f8f9fa;
}

.luxin-container tbody tr.selected {
    background-color: #e7f3ff;
}

.detail-panel {
    position: absolute;
    right: -600px;
    top: 0;
    width: 600px;
    min-height: 100%;
    max-height: 600px;
    background: white;
    border-left: 1px solid #ddd;
    box-shadow: -2px 0 8px rgba(0,0,0,0.1);
    transition: right 0.3s ease;
    z-index: 1000;
    overflow-y: auto;
}

.detail-panel.open {
    right: 0;
}

.detail-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #ddd;
    position: sticky;
    top: 0;
    background: white;
    z-index: 1;
}

.detail-panel-header h3 {
    margin: 0;
    color: #333;
    font-size: 18px;
}

.close-button {
    background: none;
    border: none;
    font-size: 28px;
    color: #666;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: background-color 0.15s ease;
}

.close-button:hover {
    background-color: #f0f0f0;
    color: #333;
}

.detail-content {
    padding: 20px;
}

.detail-placeholder {
    color: #999;
    text-align: center;
    padding: 40px 20px;
}

.detail-content table {
    font-size: 14px;
}

.detail-content td,
.detail-content th {
    padding: 8px 10px;
}

/* Loading state */
.detail-content.loading::after {
    content: "Loading...";
    display: block;
    text-align: center;
    color: #999;
    padding: 40px 20px;
}

/* Responsive design */
@media (max-width: 768px) {
    .detail-panel {
        width: 100%;
        right: -100%;
    }
}

