.dt-button-background {
    display: none !important;
}

.filter-popup {
    position: absolute;
    background: #fff;
    border: 1px solid #ccc;
    top: 200px;
    z-index: 999;
    padding: 8px;
    max-height: 200px;
    overflow-y: auto;
    min-width: 250px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    border-radius: 4px;

}

.col-resizer {
    position: absolute;
    top: 0;
    right: 0;
    width: 8px;
    height: 100%;
    z-index: 99;
    cursor: col-resize;
    touch-action: none;
}

.info-popup {
    word-break: break-word;
    max-width: 200px;
    visibility: hidden;
    position: absolute;
    left: 0;
    background-color: white;
    border: 1px solid #ccc;
    padding: 10px;
    z-index: 1000;
    border-radius: 4px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    max-height: 300px;
    overflow: auto;
}

.dropdown-item-custom:hover {
    background-color: #f8f9fa;
}

.dropdown-item-custom.bg-primary {
    background-color: #7337FF !important;
}

/* Outlier highlighting styles */
.outlier-high {
    color: #007bff !important;
    font-weight: bold !important;
}

.outlier-low {
    color: #dc3545 !important;
    font-weight: bold !important;
}

/* Column Manager Tab Styles */
.tab-content {
    margin-top: 20px;
}

.nav-tabs .nav-link {
    cursor: pointer;
}

.calendar-grid {
    display: grid;
    gap: 5px;
    overflow-y: auto;
}

.calendar-grid.yearly {
    grid-template-columns: repeat(4, 1fr);
}

.calendar-grid.monthly {
    grid-template-columns: repeat(4, 1fr);
}

.calendar-grid.daily {
    grid-template-columns: repeat(7, 1fr);
}

.calendar-item {
    padding: 8px;
    text-align: center;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.2s ease;
}

.calendar-item:hover {
    background-color: #f8f9fa;
    border-color: #adb5bd;
}

.calendar-item.available {
    background-color: #f0ebff;
    border-color: #7337FF;
    color: #7337FF;
}

.calendar-item.available:hover {
    background-color: #e6d9ff;
}

.calendar-item.selected {
    background-color: #7337FF;
    color: white;
    border-color: #7337FF;
}

.calendar-item.current-period {
    background-color: #e3f2fd;
    border-color: #2196f3;
    color: #1565c0;
    font-weight: bold;
}

.calendar-item.disabled {
    background-color: #f8f9fa;
    color: #6c757d;
    cursor: not-allowed;
    opacity: 0.5;
}

.calendar-item.disabled:hover {
    background-color: #f8f9fa;
    border-color: #dee2e6;
}

#select-outliers, #select-outliers-label, #select-blank-setting, #select-blank-setting-label, #select-highlight-outliers, #select-highlight-outliers-label {
    cursor: pointer;
    font-size: 14px;
}


#columnCalculatorModal .bg-white {
    border: 1px solid #dee2e6;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

#columnCalculatorModal .form-control:focus,
#columnCalculatorModal .form-select:focus {
    border-color: #7337FF;
    box-shadow: 0 0 0 0.2rem rgba(115, 55, 255, 0.25);
}

#columnCalculatorModal .btn-primary {
    background-color: #7337FF;
    border-color: #7337FF;
}

#columnCalculatorModal .btn-primary:hover {
    background-color: #5a2acc;
    border-color: #5a2acc;
}

#columnCalculatorModal .column-btn {
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    color: #495057;
    font-size: 12px;
    padding: 2px 6px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
}

#columnCalculatorModal .column-btn:hover {
    background-color: #e9ecef;
    border-color: #adb5bd;
}

#columnCalculatorModal #formulaInput:focus {
    border-color: #7337FF;
    box-shadow: 0 0 0 0.2rem rgba(115, 55, 255, 0.25);
}

#columnCalculatorModal .action-card {
    background: #fff;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 1rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}

#columnCalculatorModal .action-card:hover {
    border-color: #7337FF;
    background-color: #f8f9ff;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(115, 55, 255, 0.15);
}

#columnCalculatorModal .action-card.active {
    border-color: #7337FF;
    background-color: #7337FF;
    color: white;
    box-shadow: 0 4px 12px rgba(115, 55, 255, 0.3);
}

#columnCalculatorModal .action-card-icon {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

#columnCalculatorModal .action-card.active .action-card-icon {
    color: white;
}

#columnCalculatorModal .action-card-text {
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.2;
}

#columnCalculatorModal .action-card.active .action-card-text {
    color: white;
}
#myTable {
    margin: 0;
    vertical-align: middle;
    min-width: 100%;
    min-height: 360px;
}

#myTable a {
    text-decoration: underline;
}

#myTable a:hover {
    color: #7337FF;
}

#summaryTable {
    min-width: 100%;
    vertical-align: middle;
}

#myTable .dt-empty {
    vertical-align: middle;
}

#myTable th {
    position: relative;
}

#myTable th.no-order-temp {
    pointer-events: none;
}

.table-wrapper {
    width: 100%;
    overflow-x: auto;
}

table {
    font-size: 14px;
    border-collapse: collapse;
    table-layout: auto;
    width: max-content !important;
}

#myTable.dataTable.row-border > tbody > tr.selected + tr.selected > td, #myTable.dataTable.display > tbody > tr.selected + tr.selected > td {
    border-top-color: #7337FF88 !important;
}

#myTable.dataTable > tbody > tr.selected > *, #myTable.dataTable > tbody > tr.selected:hover > * {
    box-shadow: inset 0 0 0 9999px #7337FFBB !important;
}

th, td {
    word-break: break-all;
}

#myTable th:first-child, #myTable td:first-child {
    cursor: auto;
    width: 50px;
}

.dt-buttons-bar {
    text-align: right;
    margin-bottom: 0.5rem;
}

/* length + search 줄: 좌우 정렬 */
.dt-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.dt-info {
    text-align: left !important;
    margin-top: 10px;
    margin-bottom: 10px;
    opacity: 0.75;
    font-size: 14px;
}

.select-info {
    margin-left: 8px !important;
}

.dt-length {
    display: flex;
}

.dt-paging {
    text-align: center;
}

.dt-buttons {
    width: auto !important;
    margin-left: 0.5rem;
    margin-bottom: 0 !important;
}

th {
    text-align: center;
}

#select-all {
    cursor: pointer;
    accent-color: #7337FF;
}

#myTable th:first-child, #myTable td:first-child {
    cursor: pointer;
}

th .dt-column-header:first-child {
    gap: 0 !important;
}

#myTable.dataTable th:not(:first-child) .dt-column-header {
    min-width: max-content;
    width: 100%;
    display: flex;
    align-items: center;
}

#myTable.dataTable th:not(:first-child) .dt-column-header .dt-column-title {
    min-width: max-content;
    margin-right: 8px;
    text-align: left !important;
}

table.dataTable th.dt-type-numeric div.dt-column-header, table.dataTable th.dt-type-numeric div.dt-column-footer, table.dataTable th.dt-type-date div.dt-column-header, table.dataTable th.dt-type-date div.dt-column-footer, table.dataTable td.dt-type-numeric div.dt-column-header, table.dataTable td.dt-type-numeric div.dt-column-footer, table.dataTable td.dt-type-date div.dt-column-header, table.dataTable td.dt-type-date div.dt-column-footer {
    flex-direction: row;
}

div.dt-container .dt-paging .dt-paging-button {
    background: transparent !important;
    border: none !important;
    color: inherit !important;
    text-decoration: none !important;
    box-shadow: none !important;
    padding: 5px !important;
}

.dropdown-toggle::after {
    display: none !important;
}

.dt-search {
    float: right;
    display: flex !important;
    align-items: center;
    justify-content: end;
}

div.dt-container div.dt-search input {
    width: 100% !important;
}

.buttons-colvis {
    background: white !important;
    border-radius: 0.25rem !important;
    border: 1px solid #ced4da;
}

.cursor-pointer {
    cursor: pointer;
}

.grouping-menu .dropdown-item-custom:hover {
    background-color: #f8f9fa;
}

/* Chart Calendar Styles */
.chart-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
    overflow-y: auto;
    max-height: 280px;
}

.chart-calendar-grid .calendar-item {
    padding: 8px;
    text-align: center;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.2s ease;
}

.chart-calendar-grid .calendar-item:hover {
    background-color: #f8f9fa;
    border-color: #adb5bd;
}

.chart-calendar-grid .calendar-item.available {
    background-color: #f0ebff;
    border-color: #7337FF;
    color: #7337FF;
}

.chart-calendar-grid .calendar-item.available:hover {
    background-color: #e6d9ff;
}

.chart-calendar-grid .calendar-item.selected {
    background-color: #7337FF;
    color: white;
    border-color: #7337FF;
}

.chart-calendar-grid .calendar-item.range-start {
    background-color: #7337FF;
    color: white;
    border-color: #7337FF;
    border-radius: 4px 0 0 4px;
}

.chart-calendar-grid .calendar-item.range-end {
    background-color: #7337FF;
    color: white;
    border-color: #7337FF;
    border-radius: 0 4px 4px 0;
}

.chart-calendar-grid .calendar-item.range-between {
    background-color: #e6d9ff;
    color: #7337FF;
    border-color: #7337FF;
    border-radius: 0;
}

.chart-calendar-grid .calendar-item.disabled {
    background-color: #f8f9fa;
    color: #6c757d;
    cursor: not-allowed;
    opacity: 0.5;
}

.chart-calendar-grid .calendar-item.disabled:hover {
    background-color: #f8f9fa;
    border-color: #dee2e6;
}

/* Chart Calendar Grid Layouts */
.chart-calendar-grid.yearly {
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
}

.chart-calendar-grid.monthly {
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.chart-calendar-grid.daily {
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
}

.chart-wrapper{
    min-height: 250px;
}

@media (min-width: 992px) {
    .chart-container {
        height: 60vh;
        min-height: 480px;
        width: 100%;
    }
}

/* Table row highlight for scroll-to-row functionality */
.table-row-highlight {
    background-color: #ffeaa7 !important;
    box-shadow: 0 0 10px rgba(253, 203, 110, 0.6) !important;
    transition: all 0.3s ease-out;
}