/* Chrome for CcTable.razor: the toolbar buttons, search box, pager and mobile row layout that the
   component's own markup names in class attributes, plus the pill and link styles its consumers use
   inside column render fragments.

   Relies on the --cc-* custom properties from ccThemeVariables.css. */

/* -- toolbar ------------------------------------------------------------------------------------ */

.custom-outline-button {
    color: var(--cc-gray-medium) !important;
    border-color: var(--cc-gray-medium) !important;
    min-width: 143px !important;
}

.custom-outline-button:hover {
    color: var(--cc-primary-purple) !important;
    border-color: var(--cc-primary-purple) !important;
}

.custom-outline-button:hover .gray-darkest-text {
    color: var(--cc-primary-purple);
}

.gray-darkest-text {
    color: var(--cc-gray-darkest);
}

.search-input .mud-input {
    max-width: 331px;
    background-color: var(--cc-gray-lightest);
    border-radius: 3px;
}

@media (max-width: 585px) {
    .search-input .mud-input {
        width: 100%;
        max-width: unset;
    }
}

/* Pinned to the bottom of a MudSelect's popover, so a long option list can still be cleared. */
.select-clear-filter-button {
    border-top: 1px solid var(--cc-gray-lighter);
    background-color: var(--cc-white);
    position: sticky;
    bottom: 0;
    padding: 5px;
}

/* MudSelect renders its ChildContent both inline and in the popover; without this the clear button
   appears twice. */
.select-clear-filter-button:not(.mud-popover .select-clear-filter-button) {
    display: none;
}

/* -- pager -------------------------------------------------------------------------------------- */

.custom-pager-text {
    font-size: 16px;
    color: var(--cc-gray-darker);
    margin-left: 10px;
    margin-right: 10px;
}

.pagination-button {
    border-color: var(--cc-gray-dark) !important;
    color: var(--cc-gray-dark) !important;
}

.pagination-button:hover {
    color: var(--cc-primary-purple) !important;
}

/* -- mobile rows -------------------------------------------------------------------------------- */

.table-mobile-dropdown-preview-container {
    display: flex;
    flex-direction: row;
    width: 220px;
    overflow: hidden;
    justify-items: center;
    align-items: center;
}

.table-mobile-dropdown-preview-title {
    font-size: 16px;
    color: var(--cc-gray-darkest);
    font-weight: 700;
    width: 220px;
    display: inline-block; /* Ensures the span behaves like a block for truncation */
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.table-mobile-dropdown-header-text {
    font-size: 12px;
    color: var(--cc-gray-darker);
}

.table-mobile-dropdown-content-text {
    font-size: 16px;
    color: var(--cc-gray-darkest);
}

/* -- cell content ------------------------------------------------------------------------------- */

.primary-column-text {
    font-weight: bold;
    font-size: 16px;
    color: var(--cc-gray-darkest) !important;
}

.primary-column-text:hover {
    color: var(--cc-primary-purple) !important;
    cursor: pointer;
}

.green-pill-text {
    font-size: 12px !important;
    font-weight: bold;
    color: var(--cc-gray-darkest);
    background: var(--cc-light-green);
    border-radius: 10px;
    text-align: center;
    padding: 3px 10px 3px 10px;
}

.red-pill-text {
    font-size: 12px !important;
    font-weight: bold;
    color: var(--cc-red);
    background: var(--cc-light-red);
    border-radius: 10px;
    text-align: center;
    padding: 3px 10px 3px 10px;
}

.orange-pill-text {
    font-size: 12px !important;
    font-weight: bold;
    color: var(--cc-orange);
    background: var(--cc-light-orange);
    border-radius: 10px;
    text-align: center;
    padding: 3px 10px 3px 10px;
}

.blue-pill-text {
    font-size: 12px !important;
    font-weight: bold;
    color: var(--cc-bright-blue);
    background: var(--cc-light-blue);
    border-radius: 10px;
    text-align: center;
    padding: 3px 10px 3px 10px;
}

.gray-pill-text {
    font-size: 12px !important;
    font-weight: bold;
    color: var(--cc-gray-darkest);
    background: var(--cc-gray-lighter);
    border-radius: 10px;
    text-align: center;
    padding: 3px 10px 3px 10px;
}
