/* Card Container */
.card-data-table-container {
    border: 1px solid #E5E7EB;
    border-radius: 8px !important;
    background-color: #FFFFFF;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

/* Card Header Layout */
.card-data-table-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid #E5E7EB;
    background-color: #FFFFFF;
    flex-wrap: wrap; /* Allow wrapping on smaller screens */
}

.card-header-left, .card-header-right {
    display: flex;
    align-items: center;
    gap: 16px;
    width: 100%;
    flex-wrap: wrap;
}

#complianceAudioDescriptionsPanel > div > div > div.card-data-table-header.compliance-card-header > div > div.react-text-field-container,
#complianceChaptersPanel > div > div > div.card-data-table-header.compliance-card-header > div > div.react-text-field-container,
#complianceCaptionsPanel > div > div > div.card-data-table-header.compliance-card-header > div > div.react-text-field-container{
	display: flex;
    align-items: center;
    position: relative;
    width: 30%;
    min-width: 300px;
}

/* Inline Tabs Container */
.card-tabs-inline {
    display: flex;
    align-items: center;
    min-width: 250px;
}

#complianceAudioDescriptionsPanel > div > div > div.card-data-table-header.compliance-card-header > div > div.selectedFilterBadge{
	margin: 0px !important;
}

/* Tab Option with Badge - for dropdown items */
.card-tab-option-with-badge {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 12px;
}

.card-tab-option-label {
    flex: 1;
    text-align: left;
}

.card-tab-option-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 20px;
    padding: 2px 8px;
    background-color: #F3F4F6;
    color: #6B7280;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
}

/* Selection Badge */
.card-selection-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    background-color: #EEF2FF;
    border: 1px solid #C7D2FE;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    color: #4338CA;
}

.selection-badge-text {
    line-height: 1;
    white-space: nowrap;
}

.selection-badge-clear {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    padding: 0;
    margin: 0;
    background-color: #4338CA;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.selection-badge-clear:hover {
    background-color: #3730A3;
}

.selection-badge-clear:focus {
    outline: 2px solid #4338CA;
    outline-offset: 2px;
}

.selection-badge-clear-icon {
    color: #FFFFFF;
    font-size: 14px;
    font-weight: bold;
    line-height: 1;
}

/* Search Input */
.card-search-wrapper {
    display: flex;
    align-items: center;
    border: 1px solid #9CA3AF;
    border-radius: 4px;
    padding: 6px 12px;
    width: 300px;
    background: #FFFFFF;
}

.card-search-wrapper .search-icon {
    width: 16px;
    height: 16px;
    margin-right: 8px;
    opacity: 0.5;
}

.card-search-input {
    border: none;
    outline: none;
    width: 100%;
    font-size: 14px;
    color: #374151;
}

/* Bulk Actions Button */
.card-bulk-actions-btn {
    border: 1px solid #311B58; /* Match your deep purple */
    background: #FFFFFF;
    color: #311B58;
    padding: 6px 16px;
    border-radius: 4px;
    font-weight: 500;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s;
}

.card-bulk-actions-btn:hover {
    background: #F3F4F6;
}

/* Toggle Tabs */
.card-filter-tabs {
    display: flex;
    border: 1px solid #E5E7EB;
    border-radius: 6px;
    overflow: hidden;
}

.card-filter-tab {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: #FFFFFF;
    border: none;
    border-right: 1px solid #E5E7EB;
    font-size: 14px;
    font-weight: 600;
    color: #4B5563;
    cursor: pointer;
    transition: all 0.2s;
}

.card-filter-tab:last-child {
    border-right: none;
}

/* Active Tab (Matches the "Needs Attention" styling) */
.card-filter-tab.active {
    background: #4A3B72; /* Deep purple background */
    color: #FFFFFF;
}

.card-filter-tab .tab-icon {
    width: 16px;
    height: 16px;
}

/* Table Body — horizontal scroll when the table's min-width exceeds the container */
.card-data-table-body {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch; /* smooth momentum scroll on iOS */
}

/* Table Body Reset */
.card-data-table-body .table-wrapper {
    border: none; /* Removes double border since the card has one */
    box-shadow: none;
    border-bottom: 1px solid rgba(224, 224, 224, 1);
}

@media screen and (max-width:1000px) {
	.compliance-card-header{
		flex-direction: column;
		align-items: flex-start;
		gap: 10px;
	}
}

@media screen and (max-width:600px) {
	.compliance-card-header-left{
		flex-direction: column;
		align-items: flex-start;
		gap: 10px;
	}
	.compliance-card-header-left > div:not(.selectedFilterBadge){
		width: 100% !important;
		max-width: none !important;
	}
}