/*
 * This file is part of TREB.
 *
 * TREB is free software: you can redistribute it and/or modify it under the 
 * terms of the GNU General Public License as published by the Free Software 
 * Foundation, either version 3 of the License, or (at your option) any 
 * later version.
 *
 * TREB is distributed in the hope that it will be useful, but WITHOUT ANY 
 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 
 * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more 
 * details.
 *
 * You should have received a copy of the GNU General Public License along 
 * with TREB. If not, see <https://www.gnu.org/licenses/>. 
 *
 * Copyright 2022-2026 trebco, llc. 
 * info@treb.app
 * 
 */

/**
 * we'll add dark theme, and auto support, but not automatically.
 */

@mixin dark {
  --treb-autocomplete-background: #333;
  --treb-autocomplete-border-color: #fff;
  --treb-autocomplete-entry-color: #fff;
  --treb-autocomplete-selected-entry-background: darkred;
  --treb-autocomplete-tooltip-background: darkred;
  --treb-autocomplete-tooltip-border-color: #fff;
  --treb-autocomplete-tooltip-color: #fff;
  --treb-chart-background: #000;
  --treb-chart-grid-color: #976;
  --treb-chart-grid-zero-color: #fdd;
  --treb-chart-text-color: #fff;
  --treb-dialog-background: #000;
  --treb-dialog-color: #fff;
  --treb-dropdown-background: #000;
  --treb-dropdown-border-color: #fff;
  --treb-dropdown-caret-active-background: darkred;
  --treb-dropdown-caret-background: #444;
  --treb-dropdown-caret-border-color: #fff;
  --treb-dropdown-caret-color: #fff;
  --treb-dropdown-color: #fff;
  --treb-dropdown-selected-background: darkred;
  --treb-grid-background: #000;
  --treb-grid-default-color: #fff;
  --treb-grid-grid-color: #444;
  --treb-grid-header-background: #444;
  --treb-grid-header-grid-color: #000;
  --treb-note-background: #333;
  --treb-note-border-color: #aaa;
  --treb-note-color: #fff;
  --treb-note-marker-color: pink;
  --treb-resize-tooltip-background: #fff;
  --treb-resize-tooltip-color: #000;
  --treb-scale-slider-accent-color: #fff;
  --treb-scale-slider-background: #333;
  --treb-scale-slider-border-color: #aaa;
  --treb-selection-color: yellow;
  --treb-selection-fill-opacity: .2;
  --treb-sidebar-button-background: #000;
  --treb-sidebar-button-border-color: #888;
  --treb-stats-value-background: #223;
  --treb-tab-bar-active-tab-background: #444;
  --treb-tab-bar-tab-background: #000;
  --treb-tab-bar-tab-color: #fff;
  --treb-theme-color-1: #222;
  --treb-theme-color-2: #ddd;
  --treb-toolbar-active-button-background: #555;
  --treb-toolbar-button-background: #000;
  --treb-toolbar-hover-button-background: #444;
  --treb-ui-color: #fff;
  --treb-table-header-background: #334; // DarkSlateGray;
  --treb-table-odd-background: #122;
  --treb-table-header-font-weight: 700;
  --treb-table-header-border-top: #889;
  --treb-table-header-border-bottom: #889;
  --treb-table-footer-border-bottom: #889;
  --treb-table-odd-border-top: #889;
  --treb-table-odd-border-bottom: #889;
  --treb-table-even-border-top: #889;
  --treb-table-even-border-bottom: #889;
  --treb-table-total-border-top: #889;
  --treb-table-total-border-bottom: #889;
  --treb-table-total-background: #334;
  --treb-table-total-font-weight: 700;
  --treb-color-scheme: dark;
  --treb-resize-handle-color: lightblue;
  --treb-resize-frame-color: lightblue;
  --treb-formula-bar-locked-background: #234;

  // updates

  --treb-grid-background: rgb(30,30,30);
  --treb-grid-header-background: rgb(86,86,86);
  --treb-grid-header-color: rgb(221,221,221);
  --treb-tab-bar-active-tab-background: #444;
  --treb-tab-bar-tab-background: transparent;
  --treb-tab-bar-tab-border-color: #444;
  --treb-ui-border-color: #aaa;

  // we should split toolbar buttons and menus

  --treb-toolbar-button-background: rgb(86,86,86);
  --treb-toolbar-button-background: rgb(33,33,33);
  --treb-toolbar-border-color: rgb(67,67,67);

  --treb-toolbar-color: rgb(221,221,221);
  
  --treb-spill-border-color: pink;
  --treb-spill-border-filter: drop-shadow( 3px 3px 2px rgba(255, 255, 255, .95));
  // --treb-spill-border-dasharray: 4 2;
  // --treb-spill-border-width: 2px;

}

.treb-dark-theme {
  @include dark;
}

@media (prefers-color-scheme: dark) {
  .treb-light-dark-theme {
    @include dark;
  }
}