/* ==========================================================================
   Email to Customer User Dialog Modal Styles (emu-*)
   ========================================================================== */

.emu-dialog-card {
    width: 1040px;
    max-width: 95vw;
    max-height: 90vh;
    background-color: #FFFFFF;
    border-radius: 14px;
    box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.25), 0 0 0 1px rgba(226, 232, 240, 0.85);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
    box-sizing: border-box;
}

.emu-dialog-card::before {
    content: "";
    display: block;
    height: 3px;
    width: 100%;
    background: linear-gradient(90deg, rgba(220, 38, 38, 0.85) 0%, rgba(220, 38, 38, 0.25) 30%, transparent 80%);
    flex-shrink: 0;
}

.emu-dialog-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px;
    border-bottom: 1px solid #F1F5F9;
    background-color: #FAFCFF;
    box-sizing: border-box;
}

.emu-dialog-title {
    margin: 0;
    font-size: 17px;
    font-weight: 700;
    color: #0F172A;
    letter-spacing: -0.01em;
}

.emu-dialog-close-btn {
    background: #F8FAFC;
    border: 1px solid #E2E8F0;
    font-size: 18px;
    line-height: 1;
    color: #64748B;
    cursor: pointer;
    width: 32px;
    height: 32px;
    padding: 0;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.emu-dialog-close-btn:hover {
    color: var(--primary-color, #DC2626);
    background-color: var(--primary-bg, #FFE5E5);
    border-color: var(--primary-color, #DC2626);
    transform: rotate(90deg) scale(1.08);
}

.emu-dialog-body {
    padding: 20px 24px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
    box-sizing: border-box;
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 #f8fafc;
}

.emu-table-wrapper {
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 #f8fafc;
}

.emu-dialog-body::-webkit-scrollbar,
.emu-table-wrapper::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

.emu-dialog-body::-webkit-scrollbar-thumb,
.emu-table-wrapper::-webkit-scrollbar-thumb {
    background-color: #cbd5e1 !important;
    border-radius: 3px !important;
}

.emu-dialog-body::-webkit-scrollbar-thumb:hover,
.emu-table-wrapper::-webkit-scrollbar-thumb:hover {
    background-color: #94a3b8 !important;
}

.emu-dialog-body::-webkit-scrollbar-track,
.emu-table-wrapper::-webkit-scrollbar-track {
    background-color: #f8fafc !important;
}

/* 4 Filter Dropdowns Row */
.emu-filter-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    box-sizing: border-box;
}

.emu-filter-item {
    position: relative;
    width: 100%;
}

.emu-filter-select {
    width: 100%;
    height: 36px;
    padding: 0 28px 0 12px;
    font-size: 12px;
    color: #888888;
    background-color: #FFFFFF;
    border: 1px solid #E1E5EA;
    border-radius: 6px;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    box-sizing: border-box;
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
}

.emu-filter-select:focus {
    outline: none;
    border-color: #9CA3AF;
    box-shadow: 0 0 0 2px rgba(108, 117, 125, 0.2);
}

.emu-filter-chevron {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    display: flex;
    align-items: center;
    color: #999999;
}

.emu-filter-chevron svg {
    width: 14px;
    height: 14px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
}

/* Data Table */
.emu-table-wrapper {
    border: 1px solid #E1E5EA;
    border-radius: 6px;
    overflow-x: auto;
    background-color: #FFFFFF;
}

.emu-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.emu-table th {
    background-color: #F8FAFC;
    color: #808080;
    font-weight: 500;
    padding: 10px 12px;
    border-bottom: 1px solid #E1E5EA;
    white-space: nowrap;
    height: 42px;
    box-sizing: border-box;
    font-size: 11.5px;
}

.emu-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #F1F5F9;
    color: #151515;
    white-space: nowrap;
    vertical-align: middle;
    height: 46px;
    box-sizing: border-box;
    font-weight: 400;
}

.emu-table th.text-center,
.emu-table td.text-center {
    text-align: center;
}

.emu-table tr:last-child td {
    border-bottom: none;
}

.emu-checkbox {
    width: 16px;
    height: 16px;
    cursor: pointer;
    accent-color: #0405AB;
}

.emu-product-link {
    color: #151515;
    text-decoration: underline;
    font-weight: 400;
    cursor: pointer;
}

.emu-product-link:hover {
    color: #0405AB;
}

/* Pricing Status Tags */
.emu-pricing-status {
    font-size: 12px;
    font-weight: 500;
    color: #151515;
}

/* Footer Actions */
.emu-dialog-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    padding: 14px 24px;
    border-top: 1px solid #E1E5EA;
    background-color: #FFFFFF;
    box-sizing: border-box;
}

.emu-btn-cancel {
    height: 38px;
    padding: 0 20px;
    background-color: #FFFFFF;
    border: 1px solid #D0D5DD;
    border-radius: 6px;
    color: #344054;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.15s;
}

.emu-btn-cancel:hover {
    background-color: #F8FAFC;
}

.emu-btn-submit {
    height: 38px;
    padding: 0 24px;
    background-color: #0405AB;
    border: none;
    border-radius: 6px;
    color: #FFFFFF;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.15s;
}

.emu-btn-submit:hover {
    opacity: 0.9;
}

/* Radzen Filter Dropdown Design Preservation */
.emu-filter-select-radzen {
    width: 100% !important;
    height: 36px !important;
    background-color: #FFFFFF !important;
    border: 1px solid #E1E5EA !important;
    border-radius: 6px !important;
    box-sizing: border-box !important;
    box-shadow: none !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    position: relative !important;
    padding: 0 !important;
}

.emu-filter-select-radzen:hover,
.emu-filter-select-radzen:focus,
.emu-filter-select-radzen.rz-state-focus {
    border-color: #CBD5E1 !important;
    box-shadow: none !important;
}

.emu-filter-select-radzen .rz-dropdown-label-container {
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: flex-start !important;
    width: 100% !important;
    height: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
}

/* Dropdown label (placeholder or selected value) */
.emu-filter-select-radzen .rz-dropdown-label {
    flex: 1 1 auto !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    font-size: 12px !important;
    color: #151515 !important;
    text-align: left !important;
    padding: 0 28px 0 12px !important;
    line-height: 1.4 !important;
    height: auto !important;
    display: block !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    margin: 0 !important;
    border: none !important;
    background: transparent !important;
    box-sizing: border-box !important;
}

.emu-filter-select-radzen.rz-dropdown:has(.rz-dropdown-clear-icon) .rz-dropdown-label,
.emu-filter-select-radzen .rz-dropdown-label:not(.rz-placeholder) {
    padding-right: 50px !important;
}

/* Dropdown placeholder styling */
.emu-filter-select-radzen .rz-dropdown-label.rz-placeholder {
    color: #888888 !important;
    padding-right: 28px !important;
}

/* Radzen dropdown trigger (arrow container on far right) */
.emu-filter-select-radzen .rz-dropdown-trigger {
    position: absolute !important;
    right: 10px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    height: 16px !important;
    width: 16px !important;
    background: transparent !important;
    border: none !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
    pointer-events: none !important;
    z-index: 1 !important;
}

.emu-filter-select-radzen .rz-dropdown-trigger .rz-dropdown-icon {
    font-size: 11px !important;
    color: #4b5563 !important;
    font-family: 'rzi' !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 1 !important;
}

/* Clear icon (rendered when a value is selected) */
.emu-filter-select-radzen .rz-dropdown-clear-icon,
.emu-filter-select-radzen .rz-clear-icon {
    position: absolute !important;
    right: 30px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    font-size: 0 !important;
    color: transparent !important;
    cursor: pointer !important;
    pointer-events: auto !important;
    z-index: 10 !important;
    margin: 0 !important;
    padding: 0 !important;
    width: 16px !important;
    height: 16px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    background-color: transparent !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234b5563' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cline x1='18' y1='6' x2='6' y2='18'%3E%3C/line%3E%3Cline x1='6' y1='6' x2='18' y2='18'%3E%3C/line%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
    background-size: 13px 13px !important;
    transition: opacity 0.15s ease, transform 0.15s ease !important;
}

.emu-filter-select-radzen .rz-dropdown-clear-icon::before,
.emu-filter-select-radzen .rz-clear-icon::before {
    display: none !important;
    content: "" !important;
}

.emu-filter-select-radzen .rz-dropdown-clear-icon:hover,
.emu-filter-select-radzen .rz-clear-icon:hover {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23111827' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cline x1='18' y1='6' x2='6' y2='18'%3E%3C/line%3E%3Cline x1='6' y1='6' x2='18' y2='18'%3E%3C/line%3E%3C/svg%3E") !important;
}

/* Dropdown Panel Popup Styling */
.rz-dropdown-panel {
    border: 1px solid #E1E5EA !important;
    border-radius: 6px !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
    background-color: #FFFFFF !important;
    z-index: 999999 !important;
}

.rz-dropdown-panel .rz-dropdown-filter-container {
    padding: 6px 8px !important;
    border-bottom: 1px solid #F1F5F9 !important;
}

.rz-dropdown-panel .rz-dropdown-filter {
    font-size: 12px !important;
    height: 30px !important;
    border-radius: 4px !important;
    border: 1px solid #E1E5EA !important;
    padding: 0 8px !important;
}

.rz-dropdown-panel .rz-dropdown-items {
    padding: 4px 0 !important;
    max-height: 200px !important;
    overflow-y: auto !important;
}

.rz-dropdown-panel .rz-dropdown-item {
    font-size: 12px !important;
    padding: 6px 12px !important;
    color: #151515 !important;
}

.rz-dropdown-panel .rz-dropdown-item.rz-state-highlight,
.rz-dropdown-panel .rz-dropdown-item:hover {
    background-color: #F8FAFC !important;
    color: #0405AB !important;
}

.emu-dialog-card .rz-dropdown{
    flex-direction : row-reverse;
}

/*email to customer user dialog dropdown placeholder*/

.dialog-card .rz-dropdown {
    flex-direction: row-reverse;
}