/* Modern Sidebar Filter Styles */
.page-wrapper {
  display: flex;
  gap: 16px;
  width: 100%;
  align-items: flex-start;
  transition: all 0.3s ease;
}

.sidebar-filter {
  width: 260px;
  flex-shrink: 0;
  background: #ffffff;
  border: 1px solid #e1e1e1;
  border-radius: 10px;
  padding: 16px 14px;
  height: fit-content;
  position: sticky;
  top: 20px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
  transition: transform 0.3s ease, opacity 0.3s ease;
  transform: translateX(0);
  opacity: 1;
}

.sidebar-filter.collapsed {
  transform: translateX(-100%);
  opacity: 0;
  pointer-events: none;
  position: absolute;
  left: -280px;
}

.main-content {
  flex: 1;
  min-width: 0;
  transition: all 0.3s ease;
}

.sidebar-filter h3 {
  color: #1e1e1e;
  font-family: var(--base-font-family);
  font-size: 16px;
  font-weight: 600;
  margin: 0 0 14px 0;
  padding-bottom: 10px;
  border-bottom: 2px solid #e5eef9;
}

.filter-group {
  margin-bottom: 16px;
}

.filter-group:last-child {
  margin-bottom: 0;
}

.filter-label {
  display: block;
  color: #1e1e1e;
  font-family: var(--base-font-family);
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 6px;
  letter-spacing: -0.2px;
}

.filter-input {
  width: 100%;
  border-radius: 5px;
  border: 1px solid #b9cce5;
  background: #fff;
  padding: 7px 10px;
  font-size: 12px;
  font-family: var(--base-font-family);
  color: #1e1e1e;
  transition: border-color 0.2s;
}

.filter-input:focus {
  outline: none;
  border-color: #255ea9;
  box-shadow: 0 0 0 3px rgba(37, 94, 169, 0.1);
}

.filter-input::placeholder {
  color: #aaa;
  font-size: 12px;
}

/* Custom Multi-Select Dropdown */
.custom-select-wrapper {
  position: relative;
  width: 100%;
}

.custom-select-trigger {
  width: 100%;
  border-radius: 5px;
  border: 1px solid #b9cce5;
  background: #fff;
  padding: 6px 28px 6px 10px;
  font-size: 12px;
  font-family: var(--base-font-family);
  color: #1e1e1e;
  cursor: pointer;
  user-select: none;
  transition: border-color 0.2s;
  min-height: 32px;
  display: flex;
  align-items: center;
  position: relative;
}

.custom-select-trigger:hover {
  border-color: #255ea9;
}

.custom-select-trigger.active {
  border-color: #255ea9;
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
}

.custom-select-trigger::after {
  content: "▼";
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 10px;
  color: #666;
  transition: transform 0.2s;
}

.custom-select-trigger.active::after {
  transform: translateY(-50%) rotate(180deg);
}

.custom-select-placeholder {
  color: #aaa;
  font-size: 12px;
}

.selected-items {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
}

.selected-item {
  background: #e5eef9;
  color: #255ea9;
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 10px;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.selected-item-remove {
  cursor: pointer;
  font-weight: bold;
  color: #255ea9;
  font-size: 12px;
  line-height: 1;
}

.selected-item-remove:hover {
  color: #0b3873;
}

.custom-select-options {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: #fff;
  border: 1px solid #255ea9;
  border-top: none;
  border-radius: 0 0 5px 5px;
  max-height: 180px;
  overflow-y: auto;
  z-index: 1000;
  display: none;
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.1);
}

.custom-select-options.show {
  display: block;
}

.custom-select-option {
  padding: 6px 10px;
  cursor: pointer;
  font-size: 11px;
  font-family: var(--base-font-family);
  color: #1e1e1e;
  transition: background-color 0.15s;
  display: flex;
  align-items: center;
  gap: 6px;
}

.custom-select-option:hover {
  background: #f5f9ff;
}

.custom-select-option.selected {
  background: #e5eef9;
  color: #255ea9;
  font-weight: 500;
}

.custom-select-option input[type="checkbox"] {
  margin: 0;
  cursor: pointer;
}

/* Date Range Filter */
.date-range-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.date-input-wrapper {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.date-input-label {
  font-size: 10px;
  color: #666;
  font-weight: 500;
}

/* Filter Actions */
.filter-actions {
  display: flex;
  gap: 6px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid #e1e1e1;
}

.filter-btn {
  flex: 1;
  padding: 8px 12px;
  border-radius: 5px;
  font-size: 12px;
  font-family: var(--base-font-family);
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.filter-btn-primary {
  background: #255ea9;
  color: #fff;
}

.filter-btn-primary:hover {
  background: #1d4a85;
}

.filter-btn-secondary {
  background: #fff;
  color: #666;
  border: 1px solid #b9cce5;
}

.filter-btn-secondary:hover {
  background: #f5f9ff;
  border-color: #255ea9;
  color: #255ea9;
}

.filter-btn img {
  width: 14px;
  height: 14px;
}

/* Filter Note */
.filter-note {
  font-size: 9px;
  color: #9d4700;
  font-style: italic;
  margin-top: 4px;
  line-height: 1.3;
}

/* Table Headers - Smaller and Bold */
.bill-table thead tr th {
  font-size: 12px !important;
  font-weight: 600 !important;
  padding: 12px 16px 11px !important;
}

/* Table Body - Add padding for content */
.bill-table tbody tr td {
  padding: 10px 16px !important;
}

/* Scrollbar for dropdowns */
.custom-select-options::-webkit-scrollbar {
  width: 6px;
}

.custom-select-options::-webkit-scrollbar-track {
  background: #f5f9ff;
}

.custom-select-options::-webkit-scrollbar-thumb {
  background-color: #b9cce5;
  border-radius: 3px;
}

/* Responsive */
@media (max-width: 1200px) {
  .page-wrapper {
    flex-direction: column;
  }
  
  .sidebar-filter {
    width: 100%;
    position: relative;
    top: 0;
  }
}

/* Hide Show Filter button only */
.filter_sub_head .left_sec .sfilter_btn {
  display: none !important;
}

/* Adjust container for new layout */
.home_page .container {
  max-width: 1400px;
}

/* Smaller, standard sort indicators */
.sort-indicator {
  font-size: 10px !important;
  opacity: 0.4;
}

.sort-indicator.active {
  opacity: 0.9;
}

.sort-asc::before {
  content: "▲";
  font-size: 9px;
}

.sort-desc::before {
  content: "▼";
  font-size: 9px;
}

.sort-none::before {
  content: "⇅";
  font-size: 11px;
  opacity: 0.3;
}
