/* report.css — Liquid Glass LIGHT styles for Big Report page */

/* ─── Flatpickr: кликабельное название месяца ─── */
.flatpickr-current-month .cur-month {
  cursor: pointer;
  border-radius: 4px;
  padding: 0 4px;
  transition: background 0.15s, color 0.15s;
}
.flatpickr-current-month .cur-month:hover {
  background: rgba(0, 122, 255, 0.12);
  color: #007aff;
}

/* ─── Треугольник-кнопка для списка месяцев ─── */
.cm-month-dropdown-toggle {
  cursor: pointer;
  font-size: 14px;
  color: #888;
  margin-left: 2px;
  padding: 0 4px;
  border-radius: 4px;
  transition: color 0.15s, background 0.15s;
  user-select: none;
}
.cm-month-dropdown-toggle:hover {
  color: #007aff;
  background: rgba(0, 122, 255, 0.1);
}

/* ─── Выпадающий список месяцев ─── */
.cm-month-dropdown {
  position: absolute;
  top: 38px;
  left: 0;
  right: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 6px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.12);
  z-index: 10;
}
.cm-month-item {
  padding: 6px 4px;
  text-align: center;
  font-size: 13px;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
}
.cm-month-item:hover {
  background: rgba(0, 122, 255, 0.1);
  color: #007aff;
}
.cm-month-item.active {
  background: #007aff;
  color: #fff;
  font-weight: 600;
}
.cm-month-item.disabled {
  color: #ccc;
  cursor: default;
  pointer-events: none;
}

/* ─── Full-width override for report (same as overview) ─── */
.app-content:has(#report-page.active) {
  max-width: none;
  padding: var(--space-md) var(--space-lg);
}

/* ── Filter bar ──────────────────────────────────────────────────── */
.report-filters {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: var(--space-md) 0;
}

/* Category select — glass style */
.report-select {
  padding: 8px 32px 8px 14px;
  font-size: 0.9rem;
  border: none;
  border-radius: var(--glass-radius-xs);
  background: rgba(255, 255, 255, 0.55);
  color: var(--text-primary);
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg width='10' height='6' viewBox='0 0 10 6' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%23666' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  min-width: 150px;
  transition: all var(--transition-fast);
  backdrop-filter: blur(20px) saturate(1.8);
  -webkit-backdrop-filter: blur(20px) saturate(1.8);
  box-shadow:
    0 1px 6px rgba(0, 0, 0, 0.06),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.report-select:focus {
  outline: none;
  box-shadow:
    0 0 0 3px var(--brand-color-dim),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.55);
}

.report-select:hover {
  background: rgba(255, 255, 255, 0.70);
  box-shadow:
    0 2px 8px rgba(0, 0, 0, 0.08),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.60),
    inset 0 1px 0 rgba(255, 255, 255, 0.80);
}

/* Date button — glass style */
.report-date-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  font-size: 0.9rem;
  border: none;
  border-radius: var(--glass-radius-xs);
  background: rgba(255, 255, 255, 0.55);
  color: var(--text-primary);
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--transition-fast);
  backdrop-filter: blur(20px) saturate(1.8);
  -webkit-backdrop-filter: blur(20px) saturate(1.8);
  box-shadow:
    0 1px 6px rgba(0, 0, 0, 0.06),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.report-date-btn:hover {
  background: rgba(255, 255, 255, 0.70);
  box-shadow:
    0 2px 8px rgba(0, 0, 0, 0.08),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.60),
    inset 0 1px 0 rgba(255, 255, 255, 0.80);
}

/* ── Presets container — Glass Capsule style ────────────────────── */
.report-presets {
  display: flex;
  align-items: stretch;
  background: rgba(0, 0, 0, 0.05);
  border: none;
  border-radius: 10px;
  overflow: visible;
  position: relative;
  padding: 2px;
}

/* Sliding glass capsule for presets */
.preset-slider {
  position: absolute;
  top: 2px;
  left: 2px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(20px) saturate(1.8);
  -webkit-backdrop-filter: blur(20px) saturate(1.8);
  box-shadow:
    0 1px 6px rgba(0, 0, 0, 0.07),
    0 0.5px 1px rgba(0, 0, 0, 0.04),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.75);
  z-index: 0;
  pointer-events: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform, width;
}

.preset-btn {
  padding: 7px 14px;
  font-size: 0.85rem;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.25s ease;
  border-right: none;
  border-radius: 8px;
  position: relative;
}

.preset-btn:hover {
  background: rgba(255, 255, 255, 0.35);
  color: var(--text-primary);
}

.preset-btn.active {
  background: transparent;
  color: var(--brand-color);
  font-weight: 600;
  position: relative;
  z-index: 1;
}

/* Dropdown wrapper */
.preset-dropdown-wrap {
  position: relative;
}

.preset-more-btn {
  padding: 7px 12px;
  font-size: 0.8rem;
}

.preset-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(20px) saturate(1.4);
  -webkit-backdrop-filter: blur(20px) saturate(1.4);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: var(--glass-radius-sm);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.10);
  z-index: 100;
  min-width: 180px;
  overflow: hidden;
}

.preset-dropdown.open {
  display: block;
}

.preset-dropdown-item {
  display: block;
  width: 100%;
  text-align: left;
  padding: 10px 14px;
  font-size: 0.85rem;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.preset-dropdown-item:hover {
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(16px) saturate(1.6);
  -webkit-backdrop-filter: blur(16px) saturate(1.6);
  color: var(--text-primary);
}

.preset-dropdown-item.active {
  background: rgba(255, 255, 255, 0.50);
  backdrop-filter: blur(16px) saturate(1.6);
  -webkit-backdrop-filter: blur(16px) saturate(1.6);
  color: var(--brand-color);
  font-weight: 600;
}

/* ── Groupings button — glass style ─────────────────────────────── */
.report-groupings-btn {
  margin-left: 12px;
  padding: 8px 16px;
  font-size: 0.85rem;
  font-weight: 500;
  border: none;
  border-radius: var(--glass-radius-xs);
  background: rgba(255, 255, 255, 0.55);
  color: var(--text-primary);
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--transition-fast);
  backdrop-filter: blur(20px) saturate(1.8);
  -webkit-backdrop-filter: blur(20px) saturate(1.8);
  box-shadow:
    0 1px 6px rgba(0, 0, 0, 0.06),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.report-groupings-btn:hover {
  background: rgba(255, 255, 255, 0.70);
  box-shadow:
    0 2px 8px rgba(0, 0, 0, 0.08),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.60),
    inset 0 1px 0 rgba(255, 255, 255, 0.80);
}

/* ── Report table ────────────────────────────────────────────────── */
#report-table-area {
  margin-top: var(--space-sm);
}

.rt-wrap {
  overflow-x: auto;
  padding-bottom: var(--space-sm);
}

.rt-table {
  table-layout: fixed;
  border-collapse: collapse;
  font-size: 0.85rem;
  line-height: 1.4;
  white-space: nowrap;
}

.rt-th {
  padding: 6px 8px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--brand-color);
  cursor: pointer;
  user-select: none;
  border-bottom: 2px solid rgba(201, 164, 108, 0.15);
  transition: color var(--transition-fast);
  background: rgba(201, 164, 108, 0.03);
  overflow: hidden;
  text-overflow: ellipsis;
}

.rt-th:hover {
  color: var(--brand-color);
}

.rt-th-active {
  color: var(--text-primary);
}

.rt-td {
  padding: 6px 8px;
  border-bottom: 1px solid var(--table-border);
  vertical-align: middle;
  color: var(--text-primary);
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Row height */
.rt-table tbody tr,
.rt-table thead tr {
  height: 34px;
}

/* Row hover */
.rt-table tbody tr:hover .rt-td {
  background: var(--table-row-hover);
}

/* Drillable cells */
.rt-td-drill {
  color: var(--brand-color);
  cursor: pointer;
  text-decoration: underline;
  text-decoration-style: dotted;
  text-underline-offset: 2px;
}

.rt-td-drill:hover {
  color: var(--brand-color-hover);
  text-decoration-style: solid;
}

/* Totals row */
.rt-td-total {
  font-weight: 700;
  background: rgba(201, 164, 108, 0.10);
  border-bottom: none;
  border-top: 2px solid rgba(201, 164, 108, 0.25);
  color: #5C4A24;
}

/* Inactive rows */
.rt-row-inactive .rt-td {
  color: var(--text-tertiary);
  background: rgba(0, 0, 0, 0.015);
}

/* Sticky first column */
.rt-th-sticky, .rt-td-sticky {
  position: sticky;
  left: 0;
  z-index: 2;
  background: #f3f5f7;
  box-shadow: 2px 0 4px rgba(0,0,0,0.06);
}
.rt-th-sticky {
  z-index: 3;
  background: #f0f4f2;
}
.rt-table tbody tr:hover .rt-td-sticky {
  background: #eaf0ed;
}
.rt-row-inactive .rt-td-sticky {
  background: #f0f1f2;
}

/* Archived/deleted rows — red text */
.rt-row-archived .rt-td {
  color: #c0392b;
  background: rgba(192, 57, 43, 0.03);
}
.rt-row-archived .rt-td-sticky {
  background: #fdf2f1;
}

.rt-td-total.rt-td-sticky {
  background: #eef2ef;
}

/* Label column — default width */
.rt-th:first-child,
.rt-td:first-child {
  text-align: left;
  width: 200px;
  min-width: 60px;
}

/* Numeric columns */
.rt-th:not(:first-child),
.rt-td:not(:first-child) {
  text-align: right;
  width: 90px;
}

/* ── Drill-down popup ───────────────────────────────────────────── */
#report-drill-area {
  margin-top: 12px;
}

.drill-popup {
  border: 1px solid rgba(255, 255, 255, 0.60);
  border-radius: var(--glass-radius);
  background: rgba(255, 255, 255, 0.70);
  backdrop-filter: blur(24px) saturate(1.4);
  -webkit-backdrop-filter: blur(24px) saturate(1.4);
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.08),
    0 1px 3px rgba(0, 0, 0, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  overflow: hidden;
  position: relative;
}

.drill-popup::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg,
    transparent,
    rgba(255, 255, 255, 0.9) 20%,
    rgba(255, 255, 255, 1) 50%,
    rgba(255, 255, 255, 0.9) 80%,
    transparent
  );
  pointer-events: none;
  z-index: 1;
}

.drill-header {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  background: rgba(255, 255, 255, 0.50);
}
.drill-title { flex: 1; }
.drill-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.drill-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
}

.drill-dot {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
}

.drill-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: none;
  background: transparent;
  color: var(--text-tertiary);
  font-size: 1.3rem;
  cursor: pointer;
  border-radius: 6px;
  transition: background var(--transition-fast), color var(--transition-fast);
  line-height: 1;
}

.drill-close:hover {
  background: rgba(0, 0, 0, 0.05);
  color: var(--text-primary);
}

.drill-body {
  padding: 12px 16px 16px;
}

.drill-table-wrap {
  overflow-x: auto;
}

.drill-table {
  width: auto;
  border-collapse: collapse;
  font-size: 0.9rem;
  line-height: 1.4;
}

.drill-th {
  padding: 6px 12px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  white-space: nowrap;
  cursor: pointer;
  user-select: none;
  border-bottom: 2px solid rgba(0, 0, 0, 0.06);
  transition: color var(--transition-fast);
}

.drill-th:hover {
  color: var(--brand-color);
}

.drill-th-active {
  color: var(--text-primary);
}

.drill-td {
  padding: 6px 12px;
  white-space: nowrap;
  border-bottom: 1px solid var(--table-border);
  vertical-align: middle;
  color: var(--text-primary);
}

.drill-dot-sm {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 6px;
  vertical-align: middle;
  flex-shrink: 0;
}

.drill-link {
  color: var(--brand-color);
  text-decoration: none;
  font-weight: 500;
}

.drill-link:hover {
  text-decoration: underline;
}


.drill-count {
  margin-top: 8px;
  font-size: 0.82rem;
  color: var(--text-tertiary);
}

/* ── Metrics Panel ──────────────────────────────────────────────── */
.mp-panel {
  background: rgba(255, 255, 255, 0.65);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: var(--glass-radius);
  padding: 20px;
  margin-bottom: var(--space-md);
  box-shadow: var(--glass-shadow);
  position: relative;
  overflow: hidden;
}

.mp-panel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.9) 20%, rgba(255, 255, 255, 1) 50%, rgba(255, 255, 255, 0.9) 80%, transparent);
  pointer-events: none;
}

.mp-columns {
  display: flex;
  gap: 32px;
}

.mp-left {
  flex: 0 0 auto;
  min-width: 160px;
}

.mp-right {
  flex: 1 1 auto;
  min-width: 0;
}

.mp-section-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 10px;
}

.mp-hint {
  font-weight: 400;
  color: var(--text-tertiary);
  font-size: 0.8rem;
}

/* ── Grouping chips ─────────────────────────────────────────────── */
.mp-groupings {
  display: flex;
  flex-direction: column;
  gap: 6px;
  position: relative;
}

/* Sliding glass capsule for groupings */
.mp-group-slider {
  position: absolute;
  top: 0;
  left: 0;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(20px) saturate(1.8);
  -webkit-backdrop-filter: blur(20px) saturate(1.8);
  box-shadow:
    0 1px 6px rgba(0, 0, 0, 0.07),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.75);
  z-index: 0;
  pointer-events: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform, width, height;
}

.mp-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  font-size: 0.85rem;
  border-radius: 20px;
  border: 1px solid rgba(0, 0, 0, 0.10);
  background: rgba(255, 255, 255, 0.60);
  color: var(--text-secondary);
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--transition-fast);
  user-select: none;
}

.mp-chip:hover {
  border-color: rgba(0, 0, 0, 0.15);
  background: rgba(255, 255, 255, 0.80);
  color: var(--text-primary);
}

.mp-chip-active {
  background: transparent;
  color: var(--brand-color);
  font-weight: 600;
  border-color: transparent;
  position: relative;
  z-index: 1;
}

.mp-chip-active:hover {
  background: transparent;
  border-color: transparent;
  color: var(--brand-color);
}

/* ── Active metric chips ────────────────────────────────────────── */
.mp-active-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-height: 40px;
  padding: 8px;
  border: 1px dashed rgba(0, 0, 0, 0.10);
  border-radius: var(--glass-radius-sm);
  background: rgba(255, 255, 255, 0.40);
  margin-bottom: var(--space-md);
}

.mp-metric-chip {
  background: var(--brand-color-dim);
  border-color: rgba(201, 164, 108, 0.20);
  color: #007a46;
  padding: 5px 10px 5px 8px;
  cursor: grab;
}

.mp-metric-chip:active {
  cursor: grabbing;
}

.mp-metric-chip:hover {
  background: rgba(201, 164, 108, 0.15);
  border-color: rgba(201, 164, 108, 0.30);
  color: var(--brand-color);
}

.mp-chip-grip {
  font-size: 0.75rem;
  color: rgba(201, 164, 108, 0.35);
  cursor: grab;
  line-height: 1;
}

.mp-chip-remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border: none;
  background: rgba(201, 164, 108, 0.12);
  color: #007a46;
  border-radius: 50%;
  font-size: 0.85rem;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  transition: background var(--transition-fast);
}

.mp-chip-remove:hover {
  background: rgba(201, 164, 108, 0.25);
}

/* SortableJS ghost/chosen */
.mp-chip-ghost {
  opacity: 0.4;
}

.mp-chip-chosen {
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.12);
}

/* ── Pool sections ──────────────────────────────────────────────── */
.mp-pool-section {
  margin-bottom: 12px;
}

.mp-pool-title {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-tertiary);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.mp-pool {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.mp-pool-chip {
  background: transparent;
  border: 1px dashed rgba(0, 0, 0, 0.12);
  color: var(--text-tertiary);
  font-size: 0.82rem;
  padding: 4px 12px;
  border-radius: 20px;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.mp-pool-chip:hover {
  background: var(--brand-color-dim);
  border-color: var(--brand-color);
  color: var(--brand-color);
  border-style: solid;
}

.mp-pool-empty {
  font-size: 0.8rem;
  color: var(--text-tertiary);
  font-style: italic;
}

/* ── Extra options (checkboxes) ────────────────────────────────── */
.mp-extra-options {
  margin-top: var(--space-md);
  padding-top: var(--space-md);
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}
.mp-checkbox-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: var(--text-secondary);
  cursor: pointer;
  user-select: none;
}
.mp-checkbox-label input[type="checkbox"] {
  margin: 0;
  cursor: pointer;
}

/* ── Actions ────────────────────────────────────────────────────── */
.mp-actions {
  display: flex;
  gap: 10px;
  margin-top: var(--space-md);
  padding-top: var(--space-md);
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.mp-apply-btn {
  padding: 8px 24px;
  font-size: 0.9rem;
  font-weight: 600;
  border: none;
  border-radius: var(--glass-radius-xs);
  background: var(--brand-color);
  color: #fff;
  cursor: pointer;
  transition: background var(--transition-fast);
}

.mp-apply-btn:hover {
  background: var(--brand-color-hover);
}

.mp-cancel-btn {
  padding: 8px 18px;
  font-size: 0.85rem;
  border: 1px solid rgba(0, 0, 0, 0.10);
  border-radius: var(--glass-radius-xs);
  background: rgba(255, 255, 255, 0.60);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.mp-cancel-btn:hover {
  background: rgba(255, 255, 255, 0.85);
  color: var(--text-primary);
}

.mp-reset-btn {
  padding: 8px 18px;
  font-size: 0.85rem;
  border: none;
  border-radius: var(--glass-radius-xs);
  background: transparent;
  color: var(--text-tertiary);
  cursor: pointer;
  transition: color var(--transition-fast);
  margin-left: auto;
}

.mp-reset-btn:hover {
  color: var(--text-secondary);
}

/* ── Filter button ─────────────────────────────────────────────── */
.report-filter-btn {
  padding: 8px 16px;
  font-size: 0.85rem;
  font-weight: 500;
  border: none;
  border-radius: var(--glass-radius-xs);
  background: rgba(255, 255, 255, 0.55);
  color: var(--text-primary);
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--transition-fast);
  backdrop-filter: blur(20px) saturate(1.8);
  -webkit-backdrop-filter: blur(20px) saturate(1.8);
  box-shadow:
    0 1px 6px rgba(0, 0, 0, 0.06),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.report-filter-btn:hover {
  background: rgba(255, 255, 255, 0.70);
  box-shadow:
    0 2px 8px rgba(0, 0, 0, 0.08),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.60),
    inset 0 1px 0 rgba(255, 255, 255, 0.80);
}

.fp-btn-active {
  background: rgba(201, 164, 108, 0.15);
  color: #8B7340;
  font-weight: 600;
  box-shadow: 0 1px 6px rgba(201, 164, 108, 0.15), inset 0 0 0 1px rgba(201, 164, 108, 0.25);
}

/* ── Filter panel ──────────────────────────────────────────────── */
.fp-panel {
  background: rgba(255, 255, 255, 0.65);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: var(--glass-radius);
  padding: 20px;
  margin-bottom: var(--space-md);
  box-shadow: var(--glass-shadow);
  position: relative;
  overflow: hidden;
}

.fp-panel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.9) 20%, rgba(255, 255, 255, 1) 50%, rgba(255, 255, 255, 0.9) 80%, transparent);
  pointer-events: none;
}

.fp-columns {
  display: flex;
  gap: 32px;
}

.fp-left {
  flex: 0 0 280px;
  display: flex;
  flex-direction: column;
}

.fp-right {
  flex: 1 1 auto;
  min-width: 0;
}

.fp-section-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 10px;
}

/* Search */
.fp-search {
  width: 100%;
  padding: 7px 12px;
  font-size: 0.85rem;
  border: 1px solid rgba(0, 0, 0, 0.10);
  border-radius: var(--glass-radius-xs);
  background: rgba(255, 255, 255, 0.60);
  color: var(--text-primary);
  outline: none;
  transition: all var(--transition-fast);
  box-sizing: border-box;
}

.fp-search:focus {
  border-color: var(--brand-color);
  box-shadow: 0 0 0 3px var(--brand-color-dim);
}

/* Select all */
.fp-select-all {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin: 8px 0 4px;
  cursor: pointer;
  font-weight: 600;
}

/* Bundle list */
.fp-bundle-list {
  max-height: 220px;
  overflow-y: auto;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: var(--glass-radius-xs);
  background: rgba(255, 255, 255, 0.40);
  padding: 4px;
}

.fp-bundle-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 8px;
  font-size: 0.85rem;
  color: var(--text-primary);
  cursor: pointer;
  border-radius: 6px;
  transition: background var(--transition-fast);
}

.fp-bundle-item:hover {
  background: rgba(255, 255, 255, 0.55);
}

.fp-bundle-item input[type="checkbox"] {
  accent-color: var(--brand-color);
}

.fp-empty {
  font-size: 0.82rem;
  color: var(--text-tertiary);
  font-style: italic;
  padding: 8px;
}

/* Numeric filters */
.fp-num-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.fp-num-metric,
.fp-num-op {
  padding: 7px 10px;
  font-size: 0.85rem;
  border: 1px solid rgba(0, 0, 0, 0.10);
  border-radius: var(--glass-radius-xs);
  background: rgba(255, 255, 255, 0.60);
  color: var(--text-primary);
  cursor: pointer;
  outline: none;
}

.fp-num-metric:focus,
.fp-num-op:focus {
  border-color: var(--brand-color);
}

.fp-num-value {
  width: 90px;
  padding: 7px 10px;
  font-size: 0.85rem;
  border: 1px solid rgba(0, 0, 0, 0.10);
  border-radius: var(--glass-radius-xs);
  background: rgba(255, 255, 255, 0.60);
  color: var(--text-primary);
  outline: none;
}

.fp-num-value:focus {
  border-color: var(--brand-color);
  box-shadow: 0 0 0 3px var(--brand-color-dim);
}

.fp-num-remove {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: none;
  background: rgba(239, 68, 68, 0.08);
  color: #EF4444;
  border-radius: 50%;
  font-size: 1.1rem;
  cursor: pointer;
  transition: background var(--transition-fast);
  flex-shrink: 0;
}

.fp-num-remove:hover {
  background: rgba(239, 68, 68, 0.18);
}

.fp-add-filter {
  padding: 6px 14px;
  font-size: 0.82rem;
  border: 1px dashed rgba(0, 0, 0, 0.12);
  border-radius: 20px;
  background: transparent;
  color: var(--text-tertiary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.fp-add-filter:hover {
  background: var(--brand-color-dim);
  border-color: var(--brand-color);
  color: var(--brand-color);
  border-style: solid;
}

/* Actions */
.fp-actions {
  display: flex;
  gap: 10px;
  margin-top: var(--space-md);
  padding-top: var(--space-md);
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.fp-apply-btn {
  padding: 8px 24px;
  font-size: 0.9rem;
  font-weight: 600;
  border: none;
  border-radius: var(--glass-radius-xs);
  background: var(--brand-color);
  color: #fff;
  cursor: pointer;
  transition: background var(--transition-fast);
}

.fp-apply-btn:hover {
  background: var(--brand-color-hover);
}

.fp-reset-btn {
  padding: 8px 18px;
  font-size: 0.85rem;
  border: 1px solid rgba(0, 0, 0, 0.10);
  border-radius: var(--glass-radius-xs);
  background: rgba(255, 255, 255, 0.60);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.fp-reset-btn:hover {
  background: rgba(255, 255, 255, 0.85);
  color: var(--text-primary);
}

/* ── Report export button (reuses ov-export-btn from overview) ── */
.report-filters .ov-export-btn {
  margin-left: 6px;
}

/* ── Drill export button (small, next to close) ─────────────── */
.drill-export-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: none;
  background: var(--brand-color);
  color: #1f1d1d;
  cursor: pointer;
  border-radius: 6px;
  transition: all var(--transition-fast);
  line-height: 1;
  flex-shrink: 0;
}
.drill-export-btn:hover {
  background: var(--brand-color-hover);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
}
.drill-export-btn:active {
  transform: scale(0.95);
}
