/* Copy of Adwaita colors for _drawing.scss */

$base_color: if($variant == 'light', #ffffff, lighten(desaturate(#241f31, 100%), 2%));
$fg_color: if($variant == 'light', #2e3436, #eeeeec);
$bg_color: if($variant == 'light', #f6f5f4, darken(desaturate(#3d3846, 100%), 4%));
$selected_fg_color: #ffffff;
$selected_bg_color: if($variant == 'light', #3584e4, darken(#3584e4, 20%));
$borders_color: if($variant == 'light', darken($bg_color, 18%), darken($bg_color, 10%));
$borders_edge: if($variant == 'light', transparentize(white, 0.2), transparentize($fg_color, 0.07));
$backdrop_borders_color: mix($borders_color, $bg_color, 80%);
$shadow_color: transparentize(black, 0.9);
$top_hilight: $borders_edge;
$error_color: #cc0000;

@if $high_contrast {
  $fg_color: if($variant == 'light', darken($fg_color, 3%), lighten($fg_color, 2%));
  $bg_color: if($variant == 'light', lighten($bg_color, 3%), darken($bg_color, 2%));
  $selected_bg_color: darken($selected_bg_color,10%);
  $borders_color: if($variant == 'light', darken($borders_color, 30%), lighten($borders_color, 30%));
}

$backdrop_transition: 200ms ease-out;

/* Helpers */

@function themecolor($s) {
  @return unquote("@" + "#{$s}");
}

@function gtkalpha($c,$a) {
  @return unquote("alpha(#{$c},#{$a})");
}
