/***********
 * Dialogs *
 ***********/
messagedialog { // Message Dialog styling
  .titlebar:not(headerbar) {
    background-color: transparentize(if($variant=='light', $headerbar_color, $bg_color), 0.05);
  }
  .titlebar {
    min-height: 20px;
    background-image: none;
    background-color: transparentize(if($variant=='light', $headerbar_color, $bg_color), 0.05);
    border-style: none;
    border-top-left-radius: 4px;
    border-top-right-radius: 4px;
  }

  &.csd { // rounded bottom border styling for csd version
    &.background {
      background-color: transparentize(if($variant=='light', $headerbar_color, $bg_color), 0.05);
      color: if($variant=='light', $headerbar_fg_color, $fg_color);

      // bigger radius for better antialiasing
      border-bottom-left-radius: 5px;
      border-bottom-right-radius: 5px;
    }

    .dialog-action-area button {
      padding: 10px 14px; // labels are not vertically centered on message dialog, this is a workaround
      border-radius: 0;
      border-left-style: solid;
      border-right-style: none;
      border-bottom-style: none;
      background-color: transparent;
      color: if($variant=='light', $headerbar_fg_color, $fg_color);
      box-shadow: none;

      &:hover {
        background-color: transparentize($selected_bg_color, 0.1);
        color: white;
      }

      &:first-child{
        border-left-style: none;
        border-bottom-left-radius: 4px;
      }

      &:last-child {
        border-bottom-right-radius: 4px;
      }
      &.destructive-action, &.suggested-action{
        color:white;
      }
    }
  }
}

filechooser {
  .dialog-action-box {
    border-top: 1px solid $borders_color;

    &:backdrop { border-top-color: $backdrop_borders_color; }
  }

  #pathbarbox { border-bottom: 1px solid $bg_color; }
}

filechooserbutton:drop(active) {
  box-shadow: none;
  border-color: transparent;
}
