/* frontend/static/css/integration.css */

.integration-container {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.integration-header {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    color: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.integration-header h1 {
    margin: 0 0 10px 0;
    font-size: 28px;
}

.integration-header p {
    margin: 0;
    font-size: 16px;
    color: #e2e8f0;
    max-width: 80%;
}

.datasets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
}

.dataset-card {
    background: white;
    border-radius: 12px;
    border: 2px solid #e2e8f0;
    padding: 24px;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
}

.dataset-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(102, 126, 234, 0.15);
    border-color: #667eea;
}

.card-title {
    font-size: 20px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 56px; /* 2 lines of text */
}

.card-meta {
    font-size: 13px;
    color: #64748b;
    margin-bottom: 20px;
    border-top: 1px solid #f1f5f9;
    padding-top: 15px;
}

.card-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-top: auto; /* Pushes stats to the bottom */
    margin-bottom: 20px;
}

.stat {
    background: #f8fafc;
    padding: 12px;
    border-radius: 8px;
    text-align: center;
}

.stat-value {
    font-size: 24px;
    font-weight: 700;
    color: #2563eb;
}

.stat-label {
    font-size: 11px;
    color: #64748b;
    text-transform: uppercase;
    font-weight: 600;
}

.empty-state {
    grid-column: 1 / -1; /* Span all columns */
    text-align: center;
    padding: 60px 20px;
    color: #94a3b8;
    font-size: 16px;
    background: #f8fafc;
    border-radius: 8px;
    border: 2px dashed #e2e8f0;
}

/* Modal for details */
.modal-content.large {
    max-width: 90vw;
    width: 1200px;
}

.modal-body-grid {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 30px;
    max-height: 70vh;
}

.schema-panel {
    background: #f8fafc;
    border-radius: 8px;
    padding: 20px;
    overflow-y: auto;
    border: 1px solid #e2e8f0;
}

.schema-panel h4 {
    margin: 0 0 15px 0;
    color: #1e293b;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 10px;
}

.schema-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.schema-item {
    font-family: monospace;
    font-size: 13px;
    background: white;
    padding: 6px 10px;
    border-radius: 4px;
    border: 1px solid #e2e8f0;
    color: #475569;
}

.data-preview-panel {
    overflow-y: auto;
}

.data-preview-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.data-preview-table th {
    background: #f1f5f9;
    padding: 10px;
    text-align: left;
    font-weight: 600;
    color: #475569;
    border-bottom: 2px solid #e2e8f0;
    position: sticky;
    top: 0;
}

.data-preview-table td {
    padding: 10px;
    border-bottom: 1px solid #f1f5f9;
    color: #334155;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 200px;
}