/* MudBlazor-style tables specifically for ContentViewer */
.ayra-content table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    margin: 1rem 0;
    font-size: 0.875rem;
    animation: tableSlideIn 0.3s ease-out;
}

.ayra-content table thead {
    background: linear-gradient(135deg, var(--bg-tertiary), var(--bg-secondary));
}

.ayra-content table th {
    background: transparent;
    color: var(--text-primary);
    font-weight: 600;
    font-size: 0.875rem;
    padding: 1rem 0.75rem;
    text-align: left;
    border-bottom: 2px solid var(--accent-primary);
    position: relative;
}

.ayra-content table th:first-child {
    border-top-left-radius: 8px;
}

.ayra-content table th:last-child {
    border-top-right-radius: 8px;
}

.ayra-content table th::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg,
            transparent 0%,
            var(--accent-primary) 20%,
            var(--accent-primary) 80%,
            transparent 100%);
}

.ayra-content table td {
    padding: 0.875rem 0.75rem;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-color);
    vertical-align: top;
    line-height: 1.5;
}

.ayra-content table tbody tr {
    transition: background-color 0.2s ease;
}

.ayra-content table tbody tr:hover {
    background-color: rgba(156, 163, 175, 0.05);
}

.ayra-content table tbody tr:last-child td {
    border-bottom: none;
}

.ayra-content table tbody tr:last-child td:first-child {
    border-bottom-left-radius: 8px;
}

.ayra-content table tbody tr:last-child td:last-child {
    border-bottom-right-radius: 8px;
}

/* Alternating row colors for better readability */
.ayra-content table tbody tr:nth-child(even) {
    background-color: rgba(156, 163, 175, 0.02);
}

.ayra-content table tbody tr:nth-child(even):hover {
    background-color: rgba(156, 163, 175, 0.08);
}

/* Table container responsiveness */
.ayra-content .table-container {
    overflow-x: auto;
    margin: 1rem 0;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Responsive table styling */
@media (max-width: 768px) {
    .ayra-content table {
        font-size: 0.8rem;
    }

    .ayra-content table th,
    .ayra-content table td {
        padding: 0.75rem 0.5rem;
    }

    .ayra-content table th {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .ayra-content table {
        font-size: 0.75rem;
    }

    .ayra-content table th,
    .ayra-content table td {
        padding: 0.5rem 0.375rem;
    }

    .ayra-content table th {
        font-size: 0.75rem;
    }
}

/* Specific styling for different table types that might be generated */
.ayra-content table.full-width {
    width: 100%;
    margin: 1rem 0;
}

.ayra-content table.auto-width {
    width: auto;
    margin: 1rem auto;
}

/* Enhanced table header styling for better distinction */
.ayra-content table th {
    position: relative;
    background: linear-gradient(135deg,
            rgba(156, 163, 175, 0.1) 0%,
            rgba(156, 163, 175, 0.05) 100%);
}

/* Striped pattern for better readability */
.ayra-content table.striped tbody tr:nth-child(odd) {
    background-color: rgba(255, 255, 255, 0.01);
}

.ayra-content table.striped tbody tr:nth-child(even) {
    background-color: rgba(255, 255, 255, 0.03);
}

/* Bordered variant */
.ayra-content table.bordered th,
.ayra-content table.bordered td {
    border-right: 1px solid var(--border-color);
}

.ayra-content table.bordered th:last-child,
.ayra-content table.bordered td:last-child {
    border-right: none;
}

/* Compact variant */
.ayra-content table.compact th,
.ayra-content table.compact td {
    padding: 0.5rem 0.375rem;
}

/* Animation for table reveal */
@keyframes tableSlideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}