import red from '@material-ui/core/colors/red';
import { createMuiTheme } from '@material-ui/core/styles';

const theme = createMuiTheme({
  palette: {
    primary: {
      main: '#0090df',
    },
    secondary: {
      main: '#599646',
    },
    error: {
      main: red.A400,
    },
    background: {
      default: '#fff',
    },
  },

  overrides: {
    MuiSwitch: {
      switchBase: {
        color: '#008000',
        '&$checked': {
          color: '#0090df',
        },
        '&$checked + $track': {
          backgroundColor: '#0090df',
        },
      },
      checked: {},
      track: {
        backgroundColor: '#008000',
      },
    },
    MuiTabs: {
      indicator: {
        backgroundColor: '#a9a9a9',
      },
    },
    MuiTextField: {
      root: {
        '& label.Mui-focused': {
          color: '#575757',
        },
        '& .MuiInput-underline:after': {
          borderBottomColor: '#a9a9a9',
        },
        '&.Mui-focused fieldset': {
          borderColor: '#a9a9a9',
        },
        '& .MuiOutlinedInput-root': {
          '&.Mui-focused fieldset': {
            borderColor: '#a9a9a9',
          },
        },
        backgroundColor: '#ffffff',
      },
    },
  },
});

export default theme;